|
|
@@ -433,6 +433,7 @@
|
|
|
<el-card class="box-card" style="margin-top: 10px;">
|
|
|
<div slot="header" class="clearfix">
|
|
|
<span style="font-weight: bold">企业资质</span>
|
|
|
+ <el-button style="float: right; padding: 3px 0" type="text" @click="showDialog('01')">添加</el-button>
|
|
|
</div>
|
|
|
<el-table :data="subfileList1" border>
|
|
|
<el-table-column label="操作" width="150" align="center" fixed>
|
|
|
@@ -486,24 +487,10 @@
|
|
|
</el-tab-pane>
|
|
|
|
|
|
<el-tab-pane label="基建类">
|
|
|
- <!--<el-card class="box-card">-->
|
|
|
- <!--<el-form :model="formData">-->
|
|
|
- <!--<el-col :span="8">-->
|
|
|
- <!--<el-form-item label="准入编码">-->
|
|
|
- <!--<el-input v-model="AccessCardNo2" :readonly="true" placeholder="请输入" style="width: 100%">-->
|
|
|
- <!--</el-input>-->
|
|
|
- <!--</el-form-item>-->
|
|
|
- <!--</el-col>-->
|
|
|
- <!--</el-form>-->
|
|
|
- <!--<el-table :data="businessList2" border>-->
|
|
|
- <!--<el-table-column prop="Code" label="分类编码" show-overflow-tooltip></el-table-column>-->
|
|
|
- <!--<el-table-column prop="Name" label="分类名称" show-overflow-tooltip></el-table-column>-->
|
|
|
- <!--<el-table-column prop="Remark" label="备注" show-overflow-tooltip></el-table-column>-->
|
|
|
- <!--</el-table>-->
|
|
|
- <!--</el-card>-->
|
|
|
<el-card class="box-card" style="margin-top: 10px;">
|
|
|
<div slot="header" class="clearfix">
|
|
|
<span style="font-weight: bold">企业资质</span>
|
|
|
+ <el-button style="float: right; padding: 3px 0" type="text" @click="showDialog('02')">添加</el-button>
|
|
|
</div>
|
|
|
<el-table :data="subfileList2" border>
|
|
|
<el-table-column label="操作" width="150" align="center" fixed>
|
|
|
@@ -511,6 +498,9 @@
|
|
|
<el-button type="primary" plain size="mini" title="文件变更" @click="openDialog(scope.row)"
|
|
|
:disabled="InfoStatus > 0 || butnab">
|
|
|
变更</el-button>
|
|
|
+ <el-button type="primary" plain size="mini" title="文件变更" @click="delFile(scope.row)"
|
|
|
+ :disabled="InfoStatus > 0 || butnab">
|
|
|
+ 删除</el-button>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column prop="NeedFileType" label="文件分类" show-overflow-tooltip></el-table-column>
|
|
|
@@ -545,24 +535,10 @@
|
|
|
</el-card>
|
|
|
</el-tab-pane>
|
|
|
<el-tab-pane label="技术服务类">
|
|
|
- <!--<el-card class="box-card">-->
|
|
|
- <!--<el-form :model="formData">-->
|
|
|
- <!--<el-col :span="8">-->
|
|
|
- <!--<el-form-item label="准入编码">-->
|
|
|
- <!--<el-input v-model="AccessCardNo3" :readonly="true" placeholder="请输入" style="width: 100%">-->
|
|
|
- <!--</el-input>-->
|
|
|
- <!--</el-form-item>-->
|
|
|
- <!--</el-col>-->
|
|
|
- <!--</el-form>-->
|
|
|
- <!--<el-table :data="businessList3" border>-->
|
|
|
- <!--<el-table-column prop="Code" label="分类编码" show-overflow-tooltip></el-table-column>-->
|
|
|
- <!--<el-table-column prop="Name" label="分类名称" show-overflow-tooltip></el-table-column>-->
|
|
|
- <!--<el-table-column prop="Remark" label="备注" show-overflow-tooltip></el-table-column>-->
|
|
|
- <!--</el-table>-->
|
|
|
- <!--</el-card>-->
|
|
|
<el-card class="box-card" style="margin-top: 10px;">
|
|
|
<div slot="header" class="clearfix">
|
|
|
<span style="font-weight: bold">企业资质</span>
|
|
|
+ <el-button style="float: right; padding: 3px 0" type="text" @click="showDialog('03')">添加</el-button>
|
|
|
</div>
|
|
|
<el-table :data="subfileList3" border>
|
|
|
<el-table-column label="操作" width="150" align="center" fixed>
|
|
|
@@ -606,20 +582,18 @@
|
|
|
</el-tabs>
|
|
|
</el-card>
|
|
|
<el-dialog :title="Title" :visible.sync="visible" top="5vh">
|
|
|
- <el-form :model="SubfileForm" label-width="100px">
|
|
|
+ <el-form ref="subfileForm" :model="SubfileForm" :rules="rules" label-width="100px">
|
|
|
<el-row>
|
|
|
<el-col :span="12">
|
|
|
- <el-form-item label="资质文件">
|
|
|
- <el-upload multiple style="margin-top: 10px;" action="" ref="refuploadattach"
|
|
|
- :http-request="uploadrequest" class="attach-uploader" :before-upload="beforeAvatarUpload">
|
|
|
- <i class="el-icon-plus attach-uploader-icon"></i>
|
|
|
- <div slot="tip" class="el-upload__tip" v-if="SubfileForm.NeedFileType !=yasuoname">大小为512KB-5MB
|
|
|
- </div>
|
|
|
- </el-upload>
|
|
|
+ <el-form-item label="资质名称" prop="NeedFileType">
|
|
|
+ <el-select v-model="SubfileForm.NeedFileType" placeholder="请输文件类型" size="medium" :disabled="IsMust">
|
|
|
+ <el-option v-for="item in dynamicTableColumns" :key="item.prop" :label="item.label" :value="item.label">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="12">
|
|
|
- <el-form-item label="有效日期" required>
|
|
|
+ <el-form-item label="有效日期" prop="EffectDate">
|
|
|
<el-date-picker style="width: 100%" v-model="SubfileForm.EffectDate" type="date" placeholder="请选择有效日期">
|
|
|
</el-date-picker>
|
|
|
</el-form-item>
|
|
|
@@ -629,6 +603,17 @@
|
|
|
<el-input v-model="SubfileForm.Remark" type="textarea" :rows=3 placeholder="请输入备注信息"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="资质文件">
|
|
|
+ <el-upload multiple style="margin-top: 10px;" action="" ref="refuploadattach"
|
|
|
+ :http-request="uploadrequest" class="attach-uploader" :before-upload="beforeAvatarUpload">
|
|
|
+ <i class="el-icon-plus attach-uploader-icon"></i>
|
|
|
+ <div slot="tip" class="el-upload__tip" v-if="SubfileForm.NeedFileType !=yasuoname">大小为512KB-5MB
|
|
|
+ </div>
|
|
|
+ </el-upload>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
</el-row>
|
|
|
</el-form>
|
|
|
<div slot="footer" class="dialog-footer" style="margin-top:-30px;">
|
|
|
@@ -743,6 +728,7 @@
|
|
|
import ChooseAuditor from '@/components/oilsupplier/chooseauditor'
|
|
|
import fileapi from '@/api/oilsupplier/supplierfile'
|
|
|
import ChooseAuditorFen from '@/components/oilsupplier/chooseauditorfenban'
|
|
|
+ import setapi from '@/api/oilsupplier/oilclassorgset'
|
|
|
export default {
|
|
|
components: {
|
|
|
WfMultiHistory,
|
|
|
@@ -864,6 +850,7 @@
|
|
|
}
|
|
|
}
|
|
|
return {
|
|
|
+ IsMust: false,
|
|
|
Grade: '',
|
|
|
size: 10,
|
|
|
sizeProject: 10,
|
|
|
@@ -877,6 +864,7 @@
|
|
|
userOptions: [],
|
|
|
waituploads: [], // 等待上传的附件列表
|
|
|
AccessCardNolist: [],
|
|
|
+ dynamicTableColumns: [],
|
|
|
AccessCardNo1: '',
|
|
|
AccessCardNo2: '',
|
|
|
AccessCardNo3: '',
|
|
|
@@ -1277,12 +1265,20 @@
|
|
|
message: '用户名',
|
|
|
trigger: 'blur'
|
|
|
}]
|
|
|
+ },
|
|
|
+ rules: {
|
|
|
+ NeedFileType: [
|
|
|
+ {required: true, message: '资质名称不能为空', trigger: 'blur'}
|
|
|
+ ],
|
|
|
+ EffectDate:
|
|
|
+ [{ required: true, message: '请选择有效日期', trigger: 'change' }]
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
created () {
|
|
|
this.serviceId = this.$route.params.opera
|
|
|
this.supplierId = this.serviceId
|
|
|
+ console.log(this.supplierId, this.serviceId)
|
|
|
this.InfoStatus = this.$route.query.InfoStatus
|
|
|
this.MInfoId = this.$route.query.infoId + ''
|
|
|
this.backhistroy.certId = this.MInfoId
|
|
|
@@ -1296,9 +1292,20 @@
|
|
|
// this.getbusList3()
|
|
|
this.getsubfile3()
|
|
|
this.getFileDictOptions()
|
|
|
+ this.initTableHeader()
|
|
|
// this.getAccessCardNo()
|
|
|
},
|
|
|
methods: {
|
|
|
+ delFile (row) {
|
|
|
+ this.$confirm('此操作将彻底删除该数据, 是否继续?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ })
|
|
|
+ .catch(() => {})
|
|
|
+ },
|
|
|
SubpEntity () {
|
|
|
if (this.UnitOrg === '') {
|
|
|
this.$message({
|
|
|
@@ -1420,6 +1427,7 @@
|
|
|
const params = {
|
|
|
SupplierId: this.supplierId,
|
|
|
SupplierTypeCode: '01',
|
|
|
+ MInfoId: this.MInfoId,
|
|
|
_currentPage: this.currentPageProject,
|
|
|
_size: this.sizeProject
|
|
|
}
|
|
|
@@ -1463,6 +1471,7 @@
|
|
|
const params = {
|
|
|
SupplierId: this.supplierId,
|
|
|
SupplierTypeCode: '02',
|
|
|
+ MInfoId: this.MInfoId,
|
|
|
_currentPage: 1,
|
|
|
_size: 1000
|
|
|
}
|
|
|
@@ -1506,6 +1515,7 @@
|
|
|
const params = {
|
|
|
SupplierId: this.supplierId,
|
|
|
SupplierTypeCode: '03',
|
|
|
+ MInfoId: this.MInfoId,
|
|
|
_currentPage: 1,
|
|
|
_size: 1000
|
|
|
}
|
|
|
@@ -1797,26 +1807,93 @@
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
- // 保存修改
|
|
|
makesure () {
|
|
|
- if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
|
|
|
- // 上传附件是否完成判断
|
|
|
- if (!this.attachissuccess()) {
|
|
|
- this.$message.error('有附件未成功上传!不能保存数据')
|
|
|
- return
|
|
|
+ let _this = this
|
|
|
+ _this.$refs['subfileForm'].validate((valid) => {
|
|
|
+ if (valid) {
|
|
|
+ if (_this.Title === '新增文件') {
|
|
|
+ if (_this.$refs.refuploadattach.uploadFiles && _this.$refs.refuploadattach.uploadFiles.length > 0) {
|
|
|
+ // 上传附件是否完成判断
|
|
|
+ if (!_this.attachissuccess()) {
|
|
|
+ _this.$message.error('有附件未成功上传!不能保存数据')
|
|
|
+ return
|
|
|
+ }
|
|
|
+ console.log(_this.SubfileForm, '===============')
|
|
|
+ _this.getattachissuccess()
|
|
|
+ _this.addqualchange()
|
|
|
+ } else {
|
|
|
+ _this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: '请上传文件!'
|
|
|
+ })
|
|
|
+ }
|
|
|
+ } else if (_this.Title === '资质变更') {
|
|
|
+ if (_this.$refs.refuploadattach.uploadFiles && _this.$refs.refuploadattach.uploadFiles.length > 0) {
|
|
|
+ // 上传附件是否完成判断
|
|
|
+ if (!_this.attachissuccess()) {
|
|
|
+ _this.$message.error('有附件未成功上传!不能保存数据')
|
|
|
+ return
|
|
|
+ }
|
|
|
+ _this.getattachissuccess()
|
|
|
+ _this.editqualchange()
|
|
|
+ } else {
|
|
|
+ _this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: '请上传文件!'
|
|
|
+ })
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
- this.getattachissuccess()
|
|
|
- this.editqualchange()
|
|
|
- } else {
|
|
|
- this.editqualchange()
|
|
|
- }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // // 保存修改
|
|
|
+ // makesure () {
|
|
|
+ // if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
|
|
|
+ // // 上传附件是否完成判断
|
|
|
+ // if (!this.attachissuccess()) {
|
|
|
+ // this.$message.error('有附件未成功上传!不能保存数据')
|
|
|
+ // return
|
|
|
+ // }
|
|
|
+ // this.getattachissuccess()
|
|
|
+ // this.editqualchange()
|
|
|
+ // } else {
|
|
|
+ // this.editqualchange()
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ addqualchange () {
|
|
|
+ let _this = this
|
|
|
+ _this.SubfileForm.SupplierId = parseInt(_this.SubfileForm.SupplierId)
|
|
|
+ _this.SubfileForm.SupplierCertSubId = parseInt(_this.SubfileForm.SupplierCertSubId)
|
|
|
+ _this.SubfileForm.SupplierCertId = parseInt(_this.SupplierCertId)
|
|
|
+ _this.$axios.post('/qualchange/addqualchange/' + this.MInfoId, _this.SubfileForm)
|
|
|
+ .then(res => {
|
|
|
+ if (res.data.code === 0) {
|
|
|
+ _this.$message({
|
|
|
+ type: 'success',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ this.visible = false
|
|
|
+ this.getsubfile1()
|
|
|
+ this.getsubfile2()
|
|
|
+ this.getsubfile3()
|
|
|
+ this.$refs.refuploadattach.uploadFiles = []
|
|
|
+ } else {
|
|
|
+ _this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .catch(err => {
|
|
|
+ console.error(err)
|
|
|
+ })
|
|
|
},
|
|
|
editqualchange () {
|
|
|
let _this = this
|
|
|
_this.SubfileForm.SupplierId = parseInt(_this.SubfileForm.SupplierId)
|
|
|
_this.SubfileForm.SupplierCertSubId = parseInt(_this.SubfileForm.SupplierCertSubId)
|
|
|
_this.SubfileForm.SupplierCertId = parseInt(_this.SupplierCertId)
|
|
|
- _this.$axios.put('/qualchange/editqualchange/' + _this.QualId, _this.SubfileForm)
|
|
|
+ _this.$axios.put('/qualchange/editqualchange/' + _this.MInfoId, _this.SubfileForm)
|
|
|
.then(res => {
|
|
|
if (res.data.code === 0) {
|
|
|
_this.$message({
|
|
|
@@ -1825,8 +1902,8 @@
|
|
|
})
|
|
|
this.visible = false
|
|
|
this.getsubfile1()
|
|
|
- // this.getsubfile2()
|
|
|
- // this.getsubfile3()
|
|
|
+ this.getsubfile2()
|
|
|
+ this.getsubfile3()
|
|
|
this.$refs.refuploadattach.uploadFiles = []
|
|
|
} else {
|
|
|
_this.$message({
|
|
|
@@ -1839,7 +1916,49 @@
|
|
|
console.error(err)
|
|
|
})
|
|
|
},
|
|
|
+ initTableHeader (code) {
|
|
|
+ if (code === '01') {
|
|
|
+ setapi.initGoodTableHeader(this.$axios).then(res => {
|
|
|
+ this.dynamicTableColumns = res.data.items
|
|
|
+ })
|
|
|
+ } else if (code === '02') {
|
|
|
+ setapi.initBbTableHeader(this.$axios).then(res => {
|
|
|
+ this.dynamicTableColumns = res.data.items
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ setapi.initTsTableHeader(this.$axios).then(res => {
|
|
|
+ this.dynamicTableColumns = res.data.items
|
|
|
+ })
|
|
|
+ }
|
|
|
+ console.log(this.dynamicTableColumns, 'this.dynamicTableColumns')
|
|
|
+ },
|
|
|
+ showDialog (code) {
|
|
|
+ this.initTableHeader(code)
|
|
|
+ this.IsMust = false
|
|
|
+ this.Title = '新增文件'
|
|
|
+ this.SubfileForm.Id = ''
|
|
|
+ this.SubfileForm.SupplierId = this.supplierId
|
|
|
+ this.SubfileForm.SupplierTypeCode = code
|
|
|
+ this.SubfileForm.SupplierCertSubId = ''
|
|
|
+ this.SubfileForm.CertSubName = ''
|
|
|
+ this.SubfileForm.NeedFileType = ''
|
|
|
+ this.SubfileForm.NeedFileCode = ''
|
|
|
+ this.SubfileForm.FileExt = ''
|
|
|
+ this.SubfileForm.FileType = ''
|
|
|
+ this.SubfileForm.FileName = ''
|
|
|
+ this.SubfileForm.EffectDate = null
|
|
|
+ this.SubfileForm.FileUrl = ''
|
|
|
+ this.SubfileForm.OtherRemark = ''
|
|
|
+ this.SubfileForm.Remark = ''
|
|
|
+ this.SubfileForm.IsDelete = 0
|
|
|
+ this.SubfileForm.OldFileName = ''
|
|
|
+ this.SubfileForm.OldEffectDate = null
|
|
|
+ this.SubfileForm.OldFileUrl = ''
|
|
|
+ console.log(this.SubfileForm, 'this.SubfileForm')
|
|
|
+ this.visible = true
|
|
|
+ },
|
|
|
openDialog (val) {
|
|
|
+ this.IsMust = true
|
|
|
this.Title = '资质变更'
|
|
|
this.waituploads = []
|
|
|
this.SubfileForm.Id = val.Id
|
|
|
@@ -2019,34 +2138,34 @@
|
|
|
},
|
|
|
// 保存信息变更数据
|
|
|
saveinfochange () {
|
|
|
- this.$refs['formData'].validate((valid) => {
|
|
|
- if (valid) {
|
|
|
+ this.$refs['formData'].validate((valid) => {
|
|
|
+ if (valid) {
|
|
|
let AllInfochangeItemList = {
|
|
|
- SupplierId: this.serviceId,
|
|
|
- MInfoId: this.MInfoId,
|
|
|
- InfochangeForm: this.infochangeItemList
|
|
|
- }
|
|
|
- // console.log('----', AllInfochangeItemList)
|
|
|
- // debugger
|
|
|
- api.addInfoChangeItemCh(AllInfochangeItemList, this.$axios).then(res => {
|
|
|
- if (res.data.code === 0) {
|
|
|
- // 保存成功后,初始化数据,变成修改
|
|
|
- this.initDatas()
|
|
|
- this.$message({
|
|
|
- type: 'success',
|
|
|
- message: res.data.message
|
|
|
- })
|
|
|
- } else {
|
|
|
- this.$message({
|
|
|
- type: 'warning',
|
|
|
- message: res.data.message
|
|
|
- })
|
|
|
+ SupplierId: this.serviceId,
|
|
|
+ MInfoId: this.MInfoId,
|
|
|
+ InfochangeForm: this.infochangeItemList
|
|
|
}
|
|
|
- }).catch(err => {
|
|
|
- console.error(err)
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
+ // console.log('----', AllInfochangeItemList)
|
|
|
+ // debugger
|
|
|
+ api.addInfoChangeItemCh(AllInfochangeItemList, this.$axios).then(res => {
|
|
|
+ if (res.data.code === 0) {
|
|
|
+ // 保存成功后,初始化数据,变成修改
|
|
|
+ this.initDatas()
|
|
|
+ this.$message({
|
|
|
+ type: 'success',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ }
|
|
|
+ }).catch(err => {
|
|
|
+ console.error(err)
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
},
|
|
|
chooseAuditorShow () {
|
|
|
this.$refs['chooseAuditor'].getorgtreelist()
|