|
@@ -181,10 +181,22 @@
|
|
</template>
|
|
</template>
|
|
<div class="hc-switch-tab-content">
|
|
<div class="hc-switch-tab-content">
|
|
<div class="h-full w-full">
|
|
<div class="h-full w-full">
|
|
- <div v-if="tableRowData[tabTypeKey]">
|
|
|
|
|
|
+ <div v-if="tableRowData[tabTypeKey]" style="text-align:center">
|
|
<iframe allow="display-capture" width='100%' height='100%' frameborder='1' :src="tableRowData[tabTypeKey]" style="height:500px;width:90%" v-if="tableRowData[tabTypeKey]&&ispdf!==-1"/>
|
|
<iframe allow="display-capture" width='100%' height='100%' frameborder='1' :src="tableRowData[tabTypeKey]" style="height:500px;width:90%" v-if="tableRowData[tabTypeKey]&&ispdf!==-1"/>
|
|
- <el-link type="primary" :href="tableRowData[tabTypeKey]" v-else>{{tableRowData[tabTypeKey]}}</el-link>
|
|
|
|
- <el-button type="primary" size="small" hc-btn @click="deleteFile" style="float:right">
|
|
|
|
|
|
+
|
|
|
|
+ <div class="hc-no-table-form" v-if="ispdf==-1">
|
|
|
|
+ <div class="table-form-no" style="margin-top:100px">
|
|
|
|
+ <!-- <img :src="notableform" alt=""/>
|
|
|
|
+ <div class="desc">暂无 PDF 数据,请上传</div> -->
|
|
|
|
+ <HcDragUpload autoUpload @progress="tableRowPdfProgress" @finished="tableRowPdfFinished" :action="'endpoint/put-file-attach'"
|
|
|
|
+ :accept="'image/png,image/jpg,image/jpeg,application/pdf,.doc,.docx,application/msword'"
|
|
|
|
+ :formatTip="':jpg/png/pdf/excel/word.pdf'"
|
|
|
|
+ />
|
|
|
|
+ <el-link type="primary" :href="tableRowData[tabTypeKey]" style="margin-top:10px">{{splitFileName(tableRowData[tabTypeKey])}}</el-link>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+
|
|
|
|
+ <el-button type="primary" size="small" hc-btn @click="deleteFile" >
|
|
<HcIcon name="delete-bin-2"/>
|
|
<HcIcon name="delete-bin-2"/>
|
|
<span>删除</span>
|
|
<span>删除</span>
|
|
</el-button>
|
|
</el-button>
|
|
@@ -194,10 +206,10 @@
|
|
<div class="hc-no-table-form" v-else>
|
|
<div class="hc-no-table-form" v-else>
|
|
<div class="table-form-no">
|
|
<div class="table-form-no">
|
|
<img :src="notableform" alt=""/>
|
|
<img :src="notableform" alt=""/>
|
|
- <div class="desc">暂无 PDF 数据,请上传</div>
|
|
|
|
|
|
+ <div class="desc">暂无 文件 数据,请上传</div>
|
|
<HcDragUpload autoUpload @progress="tableRowPdfProgress" @finished="tableRowPdfFinished" :action="'endpoint/put-file-attach'"
|
|
<HcDragUpload autoUpload @progress="tableRowPdfProgress" @finished="tableRowPdfFinished" :action="'endpoint/put-file-attach'"
|
|
:accept="'image/png,image/jpg,image/jpeg,application/pdf,.doc,.docx,application/msword'"
|
|
:accept="'image/png,image/jpg,image/jpeg,application/pdf,.doc,.docx,application/msword'"
|
|
- :formatTip="'.pdf'"
|
|
|
|
|
|
+ :formatTip="':jpg/png/pdf/excel/word.pdf'"
|
|
/>
|
|
/>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -649,7 +661,16 @@ const tabTypeChange = (item) => {
|
|
const row = tableRowData.value, key = tabTypeKey.value
|
|
const row = tableRowData.value, key = tabTypeKey.value
|
|
ispdf.value=getCaption( row[key])
|
|
ispdf.value=getCaption( row[key])
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+//截取文件名称
|
|
|
|
+const splitFileName=(str)=>{
|
|
|
|
+ if(str.indexOf("https://bladex-test-info.oss-cn-chengdu.aliyuncs.com//upload") != -1){
|
|
|
|
+ let a=str.split('//')[2].split('/')[2]
|
|
|
|
+ return a
|
|
|
|
+ }else{
|
|
|
|
+ return str
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+}
|
|
//上传进度
|
|
//上传进度
|
|
const tableRowPdfDisabled = ref(false)
|
|
const tableRowPdfDisabled = ref(false)
|
|
const tableRowPdfProgress = (res) => {
|
|
const tableRowPdfProgress = (res) => {
|