bug67205
This commit is contained in:
@@ -34,7 +34,7 @@
|
||||
|
||||
export default {
|
||||
name: 'file',
|
||||
props: ['disableds', 'disabled', 'thisFileUploadUrl', 'readonly', 'thisFileType', 'isUploadFile', 'isMultiple', 'restrictUploads', 'Uploadable'],
|
||||
props: ['disableds', 'disabled','acceptcode', 'thisFileUploadUrl', 'readonly', 'thisFileType', 'isUploadFile', 'isMultiple', 'restrictUploads', 'Uploadable'],
|
||||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
@@ -88,6 +88,16 @@
|
||||
// let thisFileType = this.thisFileType.replace(/\s+/g, "");
|
||||
console.log(file)
|
||||
this.fileTypeSatus = true
|
||||
//根据格式拦截
|
||||
if(this.acceptcode){
|
||||
let fileNames = file.name.split('.')
|
||||
let fileType = fileNames[fileNames.length - 1].toLocaleLowerCase()
|
||||
let extList = this.acceptcode.split(',')
|
||||
if (!extList.find((item) => item == fileType)) {
|
||||
this.$message.error(this.$t('uploadOnly') + this.acceptcode + this.$t('type'))
|
||||
return false
|
||||
}
|
||||
}
|
||||
if (this.isMultiple) {
|
||||
if ((this.myfileList && this.myfileList.length == 1) || this.myfileList && this.myfileList.length > 1) {
|
||||
this.$message.warning(this.$t('onlyOnefileUploaded'))
|
||||
|
||||
@@ -50,13 +50,13 @@
|
||||
</span>
|
||||
<!-- 技术参数-->
|
||||
<span slot="technicalparameters" slot-scope="text,record">
|
||||
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')" v-model="record.sjggcs" :max-length="500"></a-input>
|
||||
<a-input :placeholder="$t('ifNot')" :title="record.sjggcs ? record.sjggcs : $t('ifNot')" v-model="record.sjggcs" :max-length="500"></a-input>
|
||||
</span>
|
||||
<span slot="functiondescription" slot-scope="text,record">
|
||||
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')" v-model="record.gnms" :max-length="500"></a-input>
|
||||
<a-input :placeholder="$t('ifNot')" :title="record.gnms ? record.gnms:$t('ifNot')" v-model="record.gnms" :max-length="500"></a-input>
|
||||
</span>
|
||||
<span slot="applicationconditions" slot-scope="text,record">
|
||||
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')" v-model="record.sytj" :max-length="500"></a-input>
|
||||
<a-input :placeholder="$t('ifNot')" :title="record.sytj ? record.sytj:$t('ifNot')" v-model="record.sytj" :max-length="500"></a-input>
|
||||
</span>
|
||||
<span slot="functiondeelectronicscription" slot-scope="text,record">
|
||||
<a-input :placeholder="$t('pleaseEnter')" v-model="record.kzqmc" :max-length="500"></a-input>
|
||||
@@ -103,7 +103,7 @@
|
||||
<a-button type="primary" style='width: 73px;margin-right: 50px' @click='last'>{{$t('last')}}</a-button>
|
||||
<a-button type="primary" style='width: 73px' @click='next'>{{$t('next')}}</a-button>
|
||||
</div>
|
||||
<uploadFile ref="uploadFile" @uploadSuccess="uploadSuccess"></uploadFile>
|
||||
<uploadFile ref="uploadFile" :acceptcode="'doc,docx,pdf'" @uploadSuccess="uploadSuccess"></uploadFile>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
+1
-1
@@ -47,7 +47,7 @@
|
||||
<a-button type="primary" style='width: 73px;margin-right: 50px' @click='last'>{{$t('last')}}</a-button>
|
||||
<a-button type="primary" style='width: 73px' @click='next'>{{$t('next')}}</a-button>
|
||||
</div>
|
||||
<uploadFile ref="uploadFile" @uploadSuccess="uploadSuccess"></uploadFile>
|
||||
<uploadFile ref="uploadFile" :acceptcode="'doc,docx,pdf'" @uploadSuccess="uploadSuccess"></uploadFile>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
</span>
|
||||
<!-- 技术参数-->
|
||||
<span slot="technicalparameters" slot-scope="text,record">
|
||||
<a-input :placeholder="$t('ifNot')" :title="$t('ifNot')" v-model="record.sjbgcs" :max-length="500"></a-input>
|
||||
<a-input :placeholder="$t('ifNot')" :title="record.sjbgcs ? record.sjbgcs : $t('ifNot')" v-model="record.sjbgcs" :max-length="500"></a-input>
|
||||
</span>
|
||||
<!-- 上传附件-->
|
||||
<span slot="architecturetopologydiagram" slot-scope="text,record">
|
||||
@@ -99,7 +99,7 @@
|
||||
<a-button type="primary" style='width: 73px' @click='next'>{{$t('next')}}</a-button>
|
||||
</div>
|
||||
<uploadFile ref="uploadFile" @uploadSuccess="uploadSuccess"></uploadFile>
|
||||
<uploadFileOta ref="uploadFileOta" @uploadSuccess="uploadSuccessOta"></uploadFileOta>
|
||||
<uploadFileOta ref="uploadFileOta" :acceptcode="'doc,docx,pdf'" @uploadSuccess="uploadSuccessOta"></uploadFileOta>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -104,7 +104,7 @@
|
||||
{{ $t('datamaintenance') }}
|
||||
</div>
|
||||
<div v-has="'regulatoryAndTechnicalAssessment:batchDelete'" class="operator-text">
|
||||
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" />
|
||||
<ImportFile :url="url" :dummyInventoryBaseId="$route.query.id" :isTrue="true" :accept="'.zip'" @getList="getList"/>
|
||||
</div>
|
||||
<div @click="handleModule" v-has="'regulatoryAndTechnicalAssessment:batchDelete'" class="operator-text">
|
||||
<a-icon type="download" />
|
||||
|
||||
Reference in New Issue
Block a user