Jelajahi Sumber

年审资质变更

lining 5 tahun lalu
induk
melakukan
da4e79992d

+ 28 - 0
src/dashoo.cn/backend/api/business/oilsupplier/annualaudit/annualaudit.go

@@ -95,6 +95,34 @@ type Del_OilAnnualAudit struct {
 	DeleteDate     time.Time `xorm:"DATETIME"`
 }
 
+type OilAnnualChangeDetail struct {
+	Id                int       `xorm:"not null default 0 INT(10)"`
+	SupplierId        int       `xorm:"INT(10)"`
+	FileId            int       `xorm:"not null comment('资质文件Id') INT(10)"`
+	ParentId          int       `xorm:"not null default 0 comment('主表Id') INT(10)"`
+	SupplierTypeCode  string    `xorm:"not null default '0' comment('准入类别代码(01 物资类,02 基建类,03 技术服务类)') VARCHAR(5)"`
+	CertSubName       string    `xorm:"default '' comment('分类名称') VARCHAR(50)"`
+	NeedFileType      string    `xorm:"not null default '' comment('文件分类') VARCHAR(50)"`
+	NeedFileCode      string    `xorm:"not null default '' comment('文件分类编码') VARCHAR(20)"`
+	OldFileName       string    `xorm:"not null default '' comment('原文件名称') VARCHAR(2000)"`
+	FileName          string    `xorm:"not null default '' comment('文件名称') VARCHAR(2000)"`
+	FileExt           string    `xorm:"VARCHAR(10)"`
+	FileType          int       `xorm:"default 0 comment('0:不必要文件;1:必上传文件;') INT(10)"`
+	OldEffectDate     time.Time `xorm:"comment('原有效期') DATETIME"`
+	EffectDate        time.Time `xorm:"comment('有效期') DATETIME"`
+	OldFileUrl        string    `xorm:"VARCHAR(2000)"`
+	FileUrl           string    `xorm:"VARCHAR(2000)"`
+	OtherRemark       string    `xorm:"VARCHAR(500)"`
+	Remark            string    `xorm:"comment('备注') VARCHAR(500)"`
+	IsDelete          int       `xorm:"default 0 comment('删除状态,0正常,1已删除') INT(10)"`
+	CreateOn          time.Time `xorm:"DATETIME"`
+	CreateUserId      int       `xorm:"INT(10)"`
+	CreateBy          string    `xorm:"VARCHAR(50)"`
+	ModifiedOn        time.Time `xorm:"DATETIME"`
+	ModifiedUserId    int       `xorm:"INT(10)"`
+	ModifiedBy        string    `xorm:"VARCHAR(50)"`
+}
+
 type Suppliername struct {
 	Id           int
 	SupplierName string

+ 1 - 0
src/dashoo.cn/backend/api/controllers/base.go

@@ -280,6 +280,7 @@ var (
 	OilCatalogSubName                        string = "OilCatalogSub" // 目录提交审核的主表
 	OilAppendChangeItemName                  string = "OilAppendChangeItem" // 增项信息变更的表
 	OilAppendChangeDetailName                string = "OilAppendChangeDetail" // 增项资质变更
+	OilAnnualChangeDetailName                  string = "OilAnnualChangeDetail"             //年审资质变更表
 )
 
 //分页信息及数据

+ 233 - 0
src/dashoo.cn/backend/api/controllers/oilsupplier/annualaudit.go

@@ -6,7 +6,10 @@ import (
 	msg2 "dashoo.cn/backend/api/business/msg"
 	"dashoo.cn/backend/api/business/oilsupplier/infochange"
 	"dashoo.cn/backend/api/business/oilsupplier/oilcostmanage"
+	"dashoo.cn/backend/api/business/oilsupplier/qualchange"
 	"dashoo.cn/backend/api/business/oilsupplier/suppliercert"
+	"dashoo.cn/backend/api/business/oilsupplier/supplierfile"
+	"dashoo.cn/backend/api/business/oilsupplier/tableheader"
 	"dashoo.cn/backend/api/business/organize"
 	"dashoo.cn/backend/api/business/paymentinfo"
 	"dashoo.cn/backend/api/business/register"
@@ -847,6 +850,10 @@ func (this *AnnualAuditController) DeleteEntity() {
 	var entityempty annualaudit.OilAnnualAudit
 	svc := annualaudit.GetOilAnnualAuditService(utils.DBE)
 	opdesc := "删除-" + Id
+	// 删除变更的资质
+	wherefile := "ParentId=" + Id
+	svc.DeleteEntityBytbl(OilAnnualChangeDetailName, wherefile)
+
 	err := svc.DeleteOperationAndWriteLogBytbl(""+OilAnnualAuditName, BaseOperationLogName, Id, &model, &entityempty, utils.ToStr(this.User.Id), this.User.Username, opdesc, "", "钻井日报")
 	if err == nil {
 		errinfo.Message = "删除成功"
@@ -1039,6 +1046,20 @@ func (this *AnnualAuditController) AnnualAudit() {
 			} else {
 				auditmodel.Status = suppliercert.ALL_PASE_STATUS
 			}
+
+			var qualdetail []annualaudit.OilAnnualChangeDetail
+			where1 := "SupplierId = " + utils.ToStr(list.SupplierId) + " and ParentId=" + strconv.Itoa(list.Id)
+			svc.GetEntities(&qualdetail, where1)
+			if len(qualdetail) > 0 {
+				for i := 0; i < len(qualdetail); i++ {
+					var supfilemodel supplierfile.OilSupplierFile
+					supfilemodel.FileName = qualdetail[i].FileName
+					supfilemodel.FileUrl = qualdetail[i].FileUrl
+					supfilemodel.EffectDate = qualdetail[i].EffectDate
+					svc.UpdateEntityBytbl(OilSupplierFileName, qualdetail[i].FileId, &supfilemodel, []string{"FileName", "FileUrl", "EffectDate"})
+				}
+			}
+
 			var infoitems []infochange.OilAnnualChangeItem
 			where := "SupplierId = " + utils.ToStr(supplierEntity.Id) +" and InfoId = " +utils.ToStr(list.Id)
 			svc.GetEntities(&infoitems, where)
@@ -1255,4 +1276,216 @@ func (this *AnnualAuditController) updatesupplier(supname string, suppid int, in
 	}
 
 	return err
+}
+
+// @Title 资质文件
+// @Description get user by token
+// @Success 200 {object} models.Userblood
+// @router /filelist [get]
+func (this *AnnualAuditController) FileList() {
+	page := this.GetPageInfoForm()
+	var list []qualchange.OilQualChangeDetail
+	svc := qualchange.GetQualChangeService(utils.DBE)
+	where := " 1=1 and a.IsDelete = 0"
+	orderby := "a.Id"
+	asc := true
+	Order := this.GetString("Order")
+	Prop := this.GetString("Prop")
+	if Order != "" && Prop != "" {
+		orderby = Prop
+		if Order == "asc" {
+			asc = true
+		}
+	}
+	SupplierId := this.GetString("SupplierId")
+	MInfoId := this.GetString("MInfoId")
+	if SupplierId != "" {
+		where = where + " and a.SupplierId = '" + SupplierId + "'"
+	}
+	SupplierTypeCode := this.GetString("SupplierTypeCode")
+	if SupplierTypeCode != "" {
+		where = where + " and a.SupplierTypeCode in ( '000', '" + SupplierTypeCode + "')"
+	}
+	total := svc.GetQualPagingEntities(OilSupplierFileName, OilAnnualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	var datainfo DataInfo
+	datainfo.Items = list
+	datainfo.CurrentItemCount = total
+	this.Data["json"] = &datainfo
+	this.ServeJSON()
+}
+
+// @Title 添加资金
+// @Description 添加资金
+// @Success	200	{object}
+// @router /addqualchange/:id [post]
+func (this *AnnualAuditController) AddQualChange() {
+	id := this.Ctx.Input.Param(":id")
+	var errinfo ErrorInfo
+	if id == "" {
+		errinfo.Message = "操作失败!请求信息不完整"
+		errinfo.Code = -2
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+		return
+	}
+	var model annualaudit.OilAnnualChangeDetail
+	var jsonblob = this.Ctx.Input.RequestBody
+	json.Unmarshal(jsonblob, &model)
+
+	svc := qualchange.GetQualChangeService(utils.DBE)
+
+	var supplierfile supplierfile.OilSupplierFile
+	where := "SupplierId = '" + strconv.Itoa(model.SupplierId) + "' and NeedFileType='" + model.NeedFileType + "'"
+	has := svc.GetEntity(&supplierfile, where)
+
+	var tableHeader tableheader.BaseTableheader
+	where1 := "Name = '" + model.NeedFileType + "'"
+	svc.GetEntityByWhere(BaseTableHeader, where1, &tableHeader)
+
+	if has {
+		errinfo.Message = "操作失败!不能重复添加"
+		errinfo.Code = -1
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+		return
+	}
+
+	supplierfile.SupplierId = model.SupplierId
+	supplierfile.SupplierTypeCode = model.SupplierTypeCode
+	supplierfile.IsManuf = tableHeader.IsManuf
+	supplierfile.NeedFileType = model.NeedFileType
+	supplierfile.FileType = 1
+	supplierfile.SupType = 4
+	supplierfile.CreateOn = time.Now()
+	supplierfile.CreateUserId, _ = strconv.Atoi(this.User.Id)
+	supplierfile.CreateBy = this.User.Realname
+
+	svc.InsertEntity(&supplierfile)
+
+	model.ParentId, _ = strconv.Atoi(id)
+	model.FileId = supplierfile.Id
+	model.FileUrl = strings.Trim(model.FileUrl, "$")
+	model.FileName = strings.Trim(model.FileName, "$")
+
+	var err error
+	var qualdetaimodel []annualaudit.OilAnnualChangeDetail
+
+	qdwhere := " SupplierId = " + utils.ToStr(model.SupplierId) + " and FileId = " + utils.ToStr(supplierfile.Id) + " and ParentId=" + id
+	svc.GetEntitysByWhere(OilAnnualChangeDetailName, qdwhere, &qualdetaimodel)
+	if len(qualdetaimodel) == 0 {
+		model.CreateOn = time.Now()
+		model.CreateBy = this.User.Realname
+		model.CreateUserId, _ = utils.StrTo(this.User.Id).Int()
+		_, err = svc.InsertEntityBytbl(OilAnnualChangeDetailName, &model)
+	} else {
+		err = svc.UpdateEntityBywheretbl(OilAnnualChangeDetailName, &model, []string{"OldEffectDate", "FileUrl", "FileName", "OtherRemark"}, qdwhere)
+	}
+
+	if err == nil {
+		errinfo.Message = "操作成功!"
+		errinfo.Code = 0
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+	} else {
+		errinfo.Message = "操作失败!" + utils.AlertProcess(err.Error())
+		errinfo.Code = -1
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+	}
+}
+
+// @Title 资质文件变更上传
+// @Description 更新文件上传
+// @Param	id	path	string	true
+// @Success	200	{object}
+// @router /editqualchange/:id [put]
+func (this *AnnualAuditController) EditQualChange() {
+	id := this.Ctx.Input.Param(":id")
+	var errinfo ErrorInfo
+	if id == "" {
+		errinfo.Message = "操作失败!请求信息不完整"
+		errinfo.Code = -2
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+		return
+	}
+	var model annualaudit.OilAnnualChangeDetail
+	var jsonblob = this.Ctx.Input.RequestBody
+	svc := qualchange.GetQualChangeService(utils.DBE)
+	json.Unmarshal(jsonblob, &model)
+	model.FileUrl = strings.Trim(model.FileUrl, "$")
+	model.FileName = strings.Trim(model.FileName, "$")
+	model.OldFileUrl = strings.Trim(model.OldFileUrl, "$")
+	model.OldFileName = strings.Trim(model.OldFileName, "$")
+	var err error
+	var entity annualaudit.OilAnnualChangeDetail
+	var qualdetaimodel []annualaudit.OilAnnualChangeDetail
+	var mainentirt qualchange.OilQualChangeMain
+	var qualmain []qualchange.OilQualChangeMain
+	qmwhere := " SupplierId = " + utils.ToStr(model.SupplierId)
+	svc.GetEntitysByWhere(OilQualChangeMainName, qmwhere, &qualmain)
+	mainentirt.Status = "0"
+	mainentirt.Step = 1
+	err = svc.UpdateEntityBywheretbl(OilQualChangeMainName, &mainentirt, []string{"SupplierCertId", "Status", "Step"}, qmwhere)
+
+	qdwhere := " SupplierId = " + utils.ToStr(model.SupplierId) + " and FileId = " + utils.ToStr(model.Id) + " and ParentId=" + id
+	svc.GetEntitysByWhere(OilAnnualChangeDetailName, qdwhere, &qualdetaimodel)
+	entity = model
+	entity.Id = 0
+	entity.ParentId, _ = strconv.Atoi(id)
+	entity.FileId = model.Id
+	if len(qualdetaimodel) == 0 {
+		entity.CreateOn = time.Now()
+		entity.CreateBy = this.User.Realname
+		entity.CreateUserId, _ = utils.StrTo(this.User.Id).Int()
+		_, err = svc.InsertEntityBytbl(OilAnnualChangeDetailName, &entity)
+	} else {
+		err = svc.UpdateEntityBywheretbl(OilAnnualChangeDetailName, &entity, []string{"EffectDate", "FileUrl", "FileName", "OtherRemark"}, qdwhere)
+	}
+
+	if err == nil {
+		errinfo.Message = "操作成功!"
+		errinfo.Code = 0
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+	} else {
+		errinfo.Message = "操作失败!" + utils.AlertProcess(err.Error())
+		errinfo.Code = -1
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+	}
+}
+
+// @Title 删除新上传的资质
+// @Description
+// @Success 200 {object} ErrorInfo
+// @Failure 403 :id 为空
+// @router /deletenewfile/:Id [delete]
+func (this *AnnualAuditController) DeleteNewFile() {
+	Id := this.Ctx.Input.Param(":Id")
+	var errinfo ErrorInfo
+	if Id == "" {
+		errinfo.Message = "操作失败!请求信息不完整"
+		errinfo.Code = -2
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+		return
+	}
+
+	svc := infochange.GetInfoChangeService(utils.DBE)
+
+	where := "FileId=" + Id
+	err := svc.DeleteEntityBytbl(OilAnnualChangeDetailName, where)
+
+	if err == nil {
+		errinfo.Message = "删除成功"
+		errinfo.Code = 0
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+	} else {
+		errinfo.Message = "删除失败!" + utils.AlertProcess(err.Error())
+		errinfo.Code = -1
+		this.Data["json"] = &errinfo
+		this.ServeJSON()
+	}
 }

+ 1 - 1
src/dashoo.cn/backend/api/controllers/oilsupplier/supplierfile.go

@@ -129,7 +129,7 @@ func (this *SupplierfileController) FileList() {
 		//needFileType = paramSvc.GetBaseparameterMessage("GFGL", "paramset", "CooperationFile")
 		where = where + " and NeedFileType not like  '%战略%' "
 	}
-	where = where + " and SupType != 2"
+	where = where + " and SupType not in (2, 4)"
 
 	SubClassIds := this.GetString("SubClassIds")
 	if SubClassIds!=""{

+ 6 - 0
src/dashoo.cn/frontend_web/src/api/oilsupplier/annualaudit.js

@@ -134,5 +134,11 @@ export default {
       url: '/annualaudit/auditget/' + entityId,
       method: 'GET'
     })
+  },
+  deleteNewFile (Id, myAxios) {
+    return myAxios({
+      url: '/annualaudit/deletenewfile/' + Id,
+      method: 'delete'
+    })
   }
 }

+ 114 - 7
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/auditoperation.vue

@@ -678,8 +678,60 @@
         </el-tab-pane>
 
         <el-tab-pane label="企业资质" :disabled="!certId">
-          <subfile-list ref="subfileList" :data.sync="subfileList" :canadd="false" height="360px"
-            style="margin-top: 20px"></subfile-list>
+          <!--<subfile-list ref="subfileList" :data.sync="subfileList" :canadd="false" height="360px"-->
+            <!--style="margin-top: 20px"></subfile-list>-->
+          <el-card class="box-card" style="margin-top: 10px;">
+            <div slot="header" class="clearfix">
+              <span style="font-weight: bold">企业资质</span>
+            </div>
+            <el-table :data="subfileList" border>
+              <!--<el-table-column label="操作" width="150" align="center" fixed>-->
+                <!--<template slot-scope="scope">-->
+                  <!--<el-button type="primary" plain size="mini" title="文件变更" @click="openDialog(scope.row)">-->
+                    <!--变更</el-button>-->
+                <!--</template>-->
+              <!--</el-table-column>-->
+              <el-table-column prop="NeedFileType" label="文件分类" show-overflow-tooltip></el-table-column>
+              <el-table-column prop="OldFileUrlList" label="原文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.OldFileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.OldFileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.OldFileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="OldEffectDate" label="原有效日期" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.OldEffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="FileUrlList" label="变更后文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.FileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.FileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.FileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="EffectDate" label="变更后有效日期" show-overflow-tooltip >
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.EffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="Remark" label="描述" show-overflow-tooltip></el-table-column>
+            </el-table>
+
+            <el-pagination small
+                           @size-change="handleProjectSizeChange"
+                           @current-change="handleProjectCurrentChange"
+                           :current-page="currentPageProject"
+                           :page-sizes="[10, 20, 30]"
+                           :page-size="sizeProject"
+                           layout="total, sizes, prev, pager, next,jumper"
+                           :total="currentItemCountProject"
+                           style="margin: 5px;">
+            </el-pagination>
+          </el-card>
         </el-tab-pane>
 
 
@@ -818,7 +870,7 @@
   import BusinessList from '@/components/oilsupplier/businesslist'
   import TechInfo from '@/components/oilsupplier/techinfo'
   import AuditbusList from '@/components/oilsupplier/auditbuslist'
-  import SubfileList from '@/components/oilsupplier/subfilelist'
+  // import SubfileList from '@/components/oilsupplier/subfilelist'
   import WfHistory from '@/components/workflow/wfmultihistory.vue'
   import ChooseAuditor from '@/components/oilsupplier/chooseauditor'
   import _ from 'lodash'
@@ -833,7 +885,7 @@
       SupplierFileTable,
       WfHistory,
       SupplierCertEdit,
-      SubfileList, // 选择企业资质
+      // SubfileList, // 选择企业资质
       EquipmentList, // 企业主要设备
       PerformanceList, // 近三年主要业绩列表
       PatentList, // 专利及专有技术列表
@@ -955,6 +1007,9 @@
         }
       }
       return {
+        sizeProject: 10,
+        currentPageProject: 1,
+        currentItemCountProject: 0,
         InfoData: [],
         CurrencyOptions: [],
         CompanyTypeOptions: [],
@@ -1329,8 +1384,22 @@
       this.getannualdata()
       // this.getorgtreelistbydeptid()
       // this.orgtreeChange(this.majorDept)
+      this.getsubfile()
     },
     methods: {
+      // ======
+      fileurlcut (val, index) {
+        let fileurlall = val.split('$')[index]
+        let fileurl = fileurlall.split('|')
+        let retUrl = fileurl[0]
+        // 内网服务器专用
+        if (process.client && retUrl.indexOf('/upfile') === 0) {
+          const myDomain = window.location.host
+          retUrl = myDomain + '/' + retUrl
+        }
+        return retUrl
+      },
+
       fenbanBtn () {
         this.shenheForm.AnnualId = parseInt(this.annualId)
         this.addshow = true
@@ -1566,7 +1635,7 @@
             this.$refs['patentList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
             this.$refs['winningList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
             this.$refs['businessList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
-            this.$refs['subfileList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
+            // this.$refs['subfileList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
             if (this.certId && this.WorkflowId) {
               this.$refs['WfHistory'].getHistoryTask() /*  刷新工作流 */
             }
@@ -1629,8 +1698,35 @@
           console.error(err)
         })
       },
-      getbuslist () {
-        this.$refs['subfileList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
+      // getbuslist () {
+      //   this.$refs['subfileList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
+      // },
+      getsubfile () {
+        // this.$refs['subfileList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
+        let _this = this
+        const params = {
+          SupplierId: this.formData.Id,
+          SupplierTypeCode: '01',
+          MInfoId: this.annualId,
+          _currentPage: this.currentPageProject,
+          _size: this.sizeProject
+        }
+        _this.$axios.get('annualaudit/filelist', {
+          params
+        })
+          .then(res => {
+            _this.subfileList = res.data.items
+            _this.currentItemCountProject = res.data.currentItemCount
+            for (let idx in _this.subfileList) {
+              _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
+            }
+            for (let idx1 in _this.subfileList) {
+              _this.subfileList[idx1].OldFileUrlList = _this.subfileList[idx1].OldFileUrl.split('$')
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
       },
 
       getorgtreelist () {
@@ -2053,6 +2149,8 @@
       jstimehandle (val) {
         if (val === '') {
           return '----'
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return '----'
         } else if (val === '0001-01-01T08:00:00+08:00') {
           return '----'
         } else if (val === '5000-01-01T23:59:59+08:00') {
@@ -2073,6 +2171,15 @@
         var minute = date.getMinutes()
         minute = minute < 10 ? ('0' + minute) : minute
         return y + '-' + m + '-' + d + ' ' + h + ':' + minute
+      },
+      handleProjectSizeChange (value) {
+        this.sizeProject = value
+        this.currentPageProject = 1
+        this.getsubfile()
+      },
+      handleProjectCurrentChange (value) {
+        this.currentPageProject = value
+        this.getsubfile()
       }
     }
   }

+ 112 - 5
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/basicauditoperation.vue

@@ -599,8 +599,60 @@
         </el-tab-pane>
 
         <el-tab-pane label="企业资质" :disabled="!certId">
-          <subfile-list ref="subfileList" :data.sync="subfileList" :canadd="false" height="360px"
-            style="margin-top: 20px"></subfile-list>
+          <!--<subfile-list ref="subfileList" :data.sync="subfileList" :canadd="false" height="360px"-->
+            <!--style="margin-top: 20px"></subfile-list>-->
+          <el-card class="box-card" style="margin-top: 10px;">
+            <div slot="header" class="clearfix">
+              <span style="font-weight: bold">企业资质</span>
+            </div>
+            <el-table :data="subfileList" border>
+              <!--<el-table-column label="操作" width="150" align="center" fixed>-->
+              <!--<template slot-scope="scope">-->
+              <!--<el-button type="primary" plain size="mini" title="文件变更" @click="openDialog(scope.row)">-->
+              <!--变更</el-button>-->
+              <!--</template>-->
+              <!--</el-table-column>-->
+              <el-table-column prop="NeedFileType" label="文件分类" show-overflow-tooltip></el-table-column>
+              <el-table-column prop="OldFileUrlList" label="原文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.OldFileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.OldFileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.OldFileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="OldEffectDate" label="原有效日期" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.OldEffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="FileUrlList" label="变更后文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.FileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.FileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.FileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="EffectDate" label="变更后有效日期" show-overflow-tooltip >
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.EffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="Remark" label="描述" show-overflow-tooltip></el-table-column>
+            </el-table>
+
+            <el-pagination small
+                           @size-change="handleProjectSizeChange"
+                           @current-change="handleProjectCurrentChange"
+                           :current-page="currentPageProject"
+                           :page-sizes="[10, 20, 30]"
+                           :page-size="sizeProject"
+                           layout="total, sizes, prev, pager, next,jumper"
+                           :total="currentItemCountProject"
+                           style="margin: 5px;">
+            </el-pagination>
+          </el-card>
         </el-tab-pane>
 
 
@@ -739,7 +791,7 @@
   import BusinessList from '@/components/oilsupplier/businesslist'
   import TechInfo from '@/components/oilsupplier/techinfo'
   import AuditbusList from '@/components/oilsupplier/auditbuslist'
-  import SubfileList from '@/components/oilsupplier/subfilelist'
+  // import SubfileList from '@/components/oilsupplier/subfilelist'
   import WfHistory from '@/components/workflow/wfmultihistory.vue'
   import ChooseAuditor from '@/components/oilsupplier/chooseauditor'
   import _ from 'lodash'
@@ -754,7 +806,7 @@
       SupplierFileTable,
       WfHistory,
       SupplierCertEdit,
-      SubfileList, // 选择企业资质
+      // SubfileList, // 选择企业资质
       EquipmentList, // 企业主要设备
       PerformanceList, // 近三年主要业绩列表
       PatentList, // 专利及专有技术列表
@@ -876,6 +928,9 @@
         }
       }
       return {
+        sizeProject: 10,
+        currentPageProject: 1,
+        currentItemCountProject: 0,
         InfoData: [],
         CurrencyOptions: [],
         CompanyTypeOptions: [],
@@ -1258,8 +1313,58 @@
       this.getannualdata()
       // this.getorgtreelistbydeptid()
       // this.orgtreeChange(this.majorDept)
+      this.getsubfile()
     },
     methods: {
+      // ======
+      fileurlcut (val, index) {
+        let fileurlall = val.split('$')[index]
+        let fileurl = fileurlall.split('|')
+        let retUrl = fileurl[0]
+        // 内网服务器专用
+        if (process.client && retUrl.indexOf('/upfile') === 0) {
+          const myDomain = window.location.host
+          retUrl = myDomain + '/' + retUrl
+        }
+        return retUrl
+      },
+      getsubfile () {
+        // this.$refs['subfileList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
+        let _this = this
+        const params = {
+          SupplierId: this.formData.Id,
+          SupplierTypeCode: '02',
+          MInfoId: this.annualId,
+          _currentPage: this.currentPageProject,
+          _size: this.sizeProject
+        }
+        _this.$axios.get('annualaudit/filelist', {
+          params
+        })
+          .then(res => {
+            _this.subfileList = res.data.items
+            _this.currentItemCountProject = res.data.currentItemCount
+            for (let idx in _this.subfileList) {
+              _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
+            }
+            for (let idx1 in _this.subfileList) {
+              _this.subfileList[idx1].OldFileUrlList = _this.subfileList[idx1].OldFileUrl.split('$')
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
+      },
+      handleProjectSizeChange (value) {
+        this.sizeProject = value
+        this.currentPageProject = 1
+        this.getsubfile()
+      },
+      handleProjectCurrentChange (value) {
+        this.currentPageProject = value
+        this.getsubfile()
+      },
+
       fenbanBtn () {
         this.shenheForm.AnnualId = parseInt(this.annualId)
         this.addshow = true
@@ -1495,7 +1600,7 @@
             this.$refs['patentList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
             this.$refs['winningList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
             this.$refs['businessList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
-            this.$refs['subfileList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
+            // this.$refs['subfileList'].getvalue(this.formData.Id, this.formData.SupplierTypeCode, this.certId)
             if (this.certId && this.WorkflowId) {
               this.$refs['WfHistory'].getHistoryTask() /*  刷新工作流 */
             }
@@ -1985,6 +2090,8 @@
       jstimehandle (val) {
         if (val === '') {
           return '----'
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return '----'
         } else if (val === '0001-01-01T08:00:00+08:00') {
           return '----'
         } else if (val === '5000-01-01T23:59:59+08:00') {

+ 459 - 2
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/bassicoperation.vue

@@ -599,7 +599,67 @@
         </el-tab-pane>
 
         <el-tab-pane label="企业资质" :disabled="!certId">
-          <subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px" style="margin-top: 20px"></subfile-list>
+          <!--<subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px" style="margin-top: 20px"></subfile-list>-->
+          <el-card class="box-card" style="margin-top: 10px;">
+            <div slot="header" class="clearfix">
+              <span style="font-weight: bold">企业资质</span>
+            </div>
+            <el-table :data="subfileList" border>
+              <el-table-column label="操作" width="150" align="center" fixed v-if="Status <= 0">
+                <template slot-scope="scope">
+                  <el-button type="primary" plain size="mini" title="文件变更" @click="openDialog(scope.row)">
+                    变更</el-button>
+                </template>
+              </el-table-column>
+              <el-table-column prop="NeedFileType" label="文件分类" show-overflow-tooltip></el-table-column>
+              <el-table-column prop="OldFileUrlList" label="原文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.OldFileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.OldFileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.OldFileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="OldEffectDate" label="原有效日期" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.OldEffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="FileUrlList" label="变更后文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <el-row align="middle">
+                    <el-col :span="20">
+                      <div v-for="(tmpUrl, index) in scope.row.FileUrlList">
+                        <a :href="'http://'+fileurlcut(scope.row.FileUrl, index)" target="_blank"
+                           class="buttonText">{{scope.row.FileName.split('$')[index]}}
+                        </a>
+                      </div>
+                    </el-col>
+                    <el-col :span="4" v-if="scope.row.FileUrl != ''">
+                      <i class="el-icon-close" :style="{'float': 'right', 'height': '100%','line-height': lineheight(scope.row.FileUrlList.length)  + 'px',}" @click="iconclear(scope.row)"></i>
+                    </el-col>
+                  </el-row>
+                </template>
+              </el-table-column>
+              <el-table-column prop="EffectDate" label="变更后有效日期" show-overflow-tooltip >
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.EffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="Remark" label="描述" show-overflow-tooltip></el-table-column>
+            </el-table>
+
+            <el-pagination small
+                           @size-change="handleProjectSizeChange"
+                           @current-change="handleProjectCurrentChange"
+                           :current-page="currentPageProject"
+                           :page-sizes="[10, 20, 30]"
+                           :page-size="sizeProject"
+                           layout="total, sizes, prev, pager, next,jumper"
+                           :total="currentItemCountProject"
+                           style="margin: 5px;">
+            </el-pagination>
+          </el-card>
         </el-tab-pane>
 
         <el-tab-pane label="提交审批">
@@ -714,6 +774,47 @@
         <el-button size="mini" type="primary" @click="SubpEntity">确定</el-button>
       </span>
     </el-dialog>
+    <el-dialog :title="Title" :visible.sync="visible" top="5vh">
+      <el-form ref="subfileForm" :model="SubfileForm" :rules="filerules" label-width="100px">
+        <el-row>
+          <el-col :span="12">
+            <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-input v-model="SubfileForm.NeedFileType"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <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>
+          </el-col>
+          <el-col :span="24">
+            <el-form-item label="描述">
+              <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"
+                         :on-remove="filremove" :file-list="fileList" :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;">
+        <el-button @click="visible = false">取 消</el-button>
+        <el-button type="primary" @click="makesure()">确 定</el-button>
+      </div>
+    </el-dialog>
     <choose-auditor ref="chooseAuditor" @close="setAuditer" @hideChooseAuditer="chooseAuditorVisible=false"
       :visible="chooseAuditorVisible"></choose-auditor>
     <choose-auditor-fen ref="chooseAuditorFen" @close="setAuditerFen" @hideChooseAuditer="chooseAuditorVisibleFen=false"
@@ -743,6 +844,9 @@ import apiCert from '@/api/oilsupplier/suppliercert'
   import SubfileList from '@/components/oilsupplier/subfilelist'
   import ChooseAuditorFen from '@/components/oilsupplier/chooseauditorfenban'
   import _ from 'lodash'
+  import axios from 'axios'
+  import uploadajax from '@/assets/js//uploadajax.js'
+  import fileapi from '@/api/oilsupplier/supplierfile'
 
   export default {
     computed: {
@@ -876,6 +980,9 @@ import apiCert from '@/api/oilsupplier/suppliercert'
         }
       }
       return {
+        sizeProject: 10,
+        currentPageProject: 1,
+        currentItemCountProject: 0,
         canadd: false,
         InfoData: [],
         CurrencyOptions: [],
@@ -1261,6 +1368,42 @@ import apiCert from '@/api/oilsupplier/suppliercert'
             message: '请选择审批人',
             trigger: 'blur'
           }]
+        },
+        SubfileForm: {
+          Id: '',
+          SupplierId: '',
+          SupplierCertId: '',
+          SupplierTypeCode: '',
+          SupplierCertSubId: '',
+          CertSubName: '',
+          NeedFileType: '',
+          NeedFileCode: '',
+          FileType: '',
+          FileExt: '',
+          FileName: '',
+          EffectDate: new Date(),
+          FileUrl: '',
+          OldFileName: '',
+          OldEffectDate: new Date(),
+          OldFileUrl: '',
+          OtherRemark: '',
+          FileUrlList: [],
+          OldFileUrlList: [],
+          Remark: '',
+          IsDelete: 0
+        },
+        waituploads: [], // 等待上传的附件列表
+        fileList: [],
+        visible: false,
+        IsMust: false,
+        Title: '编辑',
+        yasuoname: '',
+        filerules: {
+          NeedFileType: [
+            {required: true, message: '资质名称不能为空', trigger: 'blur'}
+          ],
+          EffectDate:
+            [{ required: true, message: '请选择有效日期', trigger: 'change' }]
         }
       }
     },
@@ -1285,8 +1428,320 @@ import apiCert from '@/api/oilsupplier/suppliercert'
         this.add_flat = false
       }
       // this.orgtreeChange(this.majorDept)
+      this.getsubfile()
     },
     methods: {
+      // 资质变更相关
+      lineheight (list) {
+        return list * 23 + ''
+      },
+      fileurlcut (val, index) {
+        let fileurlall = val.split('$')[index]
+        let fileurl = fileurlall.split('|')
+        let retUrl = fileurl[0]
+        // 内网服务器专用
+        if (process.client && retUrl.indexOf('/upfile') === 0) {
+          const myDomain = window.location.host
+          retUrl = myDomain + '/' + retUrl
+        }
+        return retUrl
+      },
+      filremove (file, files) {
+        this.fileList = files
+      },
+      uploadrequest (option) {
+        let _this = this
+        if (process.client) {
+          const myDomain = window.location.host
+          axios.post(process.env.upfilehost, {})
+            .then(function (res) {
+              if (res.data && res.data.fid && res.data.fid !== '') {
+                if (res.data.publicUrl.indexOf('/upfile') === 0) {
+                  option.action = `http://${myDomain}/${res.data.publicUrl}/${res.data.fid}`
+                } else {
+                  option.action = `http://${res.data.publicUrl}/${res.data.fid}`
+                }
+                _this.waituploads.push({
+                  uid: option.file.uid,
+                  url: res.data.publicUrl,
+                  fid: res.data.fid
+                })
+                uploadajax(option)
+              } else {
+                _this.$message({
+                  type: 'warning',
+                  message: '未上传成功!请刷新界面重新上传!'
+                })
+              }
+            })
+            .catch(function (error) {
+              _this.$message({
+                type: 'warning',
+                message: '未上传成功!请重新上传!'
+              })
+            })
+        }
+      },
+      beforeAvatarUpload (file) {
+        /* let isLt512K = file.size / 1024 < 512
+        if (isLt512K) {
+          this.$message.error('上传文件大小不能小于 512KB!')
+          return false
+        } */
+        if (this.SubfileForm.NeedFileType !== this.yasuoname) {
+          let isLt50m = file.size / 1024 / 1024 / 5 < 1
+          if (!isLt50m) {
+            this.$message.error('上传文件大小不能超过 5MB!')
+            return false
+          }
+          return true
+        }
+      },
+      iconclear (row) {
+        this.$confirm('该操作将删除新上传的资质,是否继续?', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          annualapi.deleteNewFile(row.Id, this.$axios).then(res => {
+            if (res.data.code === 0) {
+              this.getsubfile()
+              this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+            } else {
+              this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          })
+        })
+      },
+      openDialog (val) {
+        this.IsMust = true
+        this.Title = '资质变更'
+        this.waituploads = []
+        this.SubfileForm.Id = val.Id
+        this.SubfileForm.SupplierId = val.SupplierId
+        this.SubfileForm.SupplierTypeCode = val.SupplierTypeCode
+        if (val.SupplierCertSubId === 0) {
+          this.SubfileForm.SupplierCertSubId = ''
+        } else {
+          this.SubfileForm.SupplierCertSubId = val.SupplierCertSubId
+        }
+        this.SubfileForm.CertSubName = val.CertSubName
+        this.SubfileForm.NeedFileType = val.NeedFileType
+        this.SubfileForm.NeedFileCode = val.NeedFileCode
+        this.SubfileForm.FileExt = val.FileExt
+        this.SubfileForm.FileType = val.FileType
+        this.SubfileForm.OldFileName = val.OldFileName
+        this.SubfileForm.OldEffectDate = new Date(val.OldEffectDate)
+        this.SubfileForm.EffectDate = (this.jsEffectDate(val.EffectDate))
+        this.SubfileForm.OldFileUrl = val.OldFileUrl
+        this.SubfileForm.OtherRemark = val.OtherRemark
+        this.SubfileForm.FileUrl = val.FileUrl
+        this.fileList = []
+        if (val.FileUrl !== '') {
+          this.getwendanginfo(val.FileUrl)
+        }
+        this.SubfileForm.Remark = val.Remark
+        this.SubfileForm.IsDelete = val.IsDelete
+        this.visible = true
+      },
+      getwendanginfo (iUrl) {
+        let _this = this
+        let urlArr = iUrl.split('$')
+        for (let idx in urlArr) {
+          let exArr = urlArr[idx].split('|')
+          let params = {
+            name: exArr[1],
+            url: exArr[0]
+          }
+          _this.fileList.push(params)
+        }
+      },
+      getFileDictOptions () {
+        fileapi.getDictList(this.$axios).then(res => {
+          this.yasuoname = res.data.items['YaSuoName']
+        }).catch(err => {
+          console.error(err)
+        })
+      },
+      jsEffectDate (val) {
+        if (val === '') {
+          return ''
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return ''
+        } else if (val === '0001-01-01T08:00:00+08:00') {
+          return ''
+        } else if (val === '5000-01-01T23:59:59+08:00') {
+          return ''
+        } else {
+          return val
+        }
+      },
+      makesure () {
+        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
+                }
+                _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: '请上传文件!'
+                })
+              }
+            }
+          }
+        })
+      },
+      // 判断附件是否上传成功
+      attachissuccess () {
+        if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
+          for (let i = 0; i < this.$refs.refuploadattach.uploadFiles.length; i++) {
+            if (this.$refs.refuploadattach.uploadFiles[i].status !== 'success') {
+              return false
+            }
+          }
+        }
+        return true
+      },
+      getattachissuccess () {
+        this.SubfileForm.FileUrl = ''
+        this.SubfileForm.FileName = ''
+        if (this.fileList != null && this.fileList.length > 0) {
+          for (let idx in this.fileList) {
+            this.SubfileForm.FileName += this.fileList[idx].name + '$'
+            this.SubfileForm.FileUrl += this.fileList[idx].url + '|' + this.fileList[idx].name + '$'
+          }
+        }
+        if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
+          for (let i = 0; i < this.$refs.refuploadattach.uploadFiles.length; i++) {
+            if (this.$refs.refuploadattach.uploadFiles[i].status === 'success') {
+              for (let j = 0; j < this.waituploads.length; j++) {
+                if (this.waituploads[j].uid === this.$refs.refuploadattach.uploadFiles[i].uid) {
+                  this.SubfileForm.FileUrl +=
+                    `${this.waituploads[j].url}/${this.waituploads[j].fid}|${this.$refs.refuploadattach.uploadFiles[i].name}$`
+                  this.SubfileForm.FileName += `${this.$refs.refuploadattach.uploadFiles[i].name}$`
+                }
+              }
+            }
+          }
+        }
+      },
+      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('/annualaudit/addqualchange/' + this.annualId, _this.SubfileForm)
+          .then(res => {
+            if (res.data.code === 0) {
+              _this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.visible = false
+              this.getsubfile()
+              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('/annualaudit/editqualchange/' + _this.annualId, _this.SubfileForm)
+          .then(res => {
+            if (res.data.code === 0) {
+              _this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.visible = false
+              this.getsubfile()
+              this.$refs.refuploadattach.uploadFiles = []
+            } else {
+              _this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
+      },
+      getsubfile () {
+        let _this = this
+        const params = {
+          SupplierId: this.formData.Id,
+          SupplierTypeCode: '02',
+          MInfoId: this.annualId,
+          _currentPage: this.currentPageProject,
+          _size: this.sizeProject
+        }
+        _this.$axios.get('annualaudit/filelist', {
+          params
+        })
+          .then(res => {
+            _this.subfileList = res.data.items
+            _this.currentItemCountProject = res.data.currentItemCount
+            for (let idx in _this.subfileList) {
+              _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
+            }
+            for (let idx1 in _this.subfileList) {
+              _this.subfileList[idx1].OldFileUrlList = _this.subfileList[idx1].OldFileUrl.split('$')
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
+      },
+      handleProjectSizeChange (value) {
+        this.sizeProject = value
+        this.currentPageProject = 1
+        this.getsubfile()
+      },
+      handleProjectCurrentChange (value) {
+        this.currentPageProject = value
+        this.getsubfile()
+      },
+
       SubpEntity () {
         if (this.UnitOrg === '') {
           this.$message({
@@ -1493,7 +1948,7 @@ import apiCert from '@/api/oilsupplier/suppliercert'
             this.$refs['patentList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
             this.$refs['winningList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
             this.$refs['businessList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
-            this.$refs['subfileList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
+            // this.$refs['subfileList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
             this.GetItemsDatas()
             this.GetChangeEntity(res.data.Id)
           }).catch(err => {
@@ -2104,6 +2559,8 @@ import apiCert from '@/api/oilsupplier/suppliercert'
       jstimehandle (val) {
         if (val === '') {
           return '----'
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return '----'
         } else if (val === '0001-01-01T08:00:00+08:00') {
           return '----'
         } else if (val === '5000-01-01T23:59:59+08:00') {

+ 461 - 7
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/goodsoperation.vue

@@ -682,7 +682,67 @@
         </el-tab-pane>
 
         <el-tab-pane label="企业资质" :disabled="!certId">
-          <subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px" style="margin-top: 20px"></subfile-list>
+          <!--<subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px" style="margin-top: 20px"></subfile-list>-->
+          <el-card class="box-card" style="margin-top: 10px;">
+            <div slot="header" class="clearfix">
+              <span style="font-weight: bold">企业资质</span>
+            </div>
+            <el-table :data="subfileList" border>
+              <el-table-column label="操作" width="150" align="center" fixed v-if="Status <= 0">
+                <template slot-scope="scope">
+                  <el-button type="primary" plain size="mini" title="文件变更" @click="openDialog(scope.row)">
+                    变更</el-button>
+                </template>
+              </el-table-column>
+              <el-table-column prop="NeedFileType" label="文件分类" show-overflow-tooltip></el-table-column>
+              <el-table-column prop="OldFileUrlList" label="原文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.OldFileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.OldFileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.OldFileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="OldEffectDate" label="原有效日期" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.OldEffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="FileUrlList" label="变更后文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <el-row align="middle">
+                    <el-col :span="20">
+                      <div v-for="(tmpUrl, index) in scope.row.FileUrlList">
+                        <a :href="'http://'+fileurlcut(scope.row.FileUrl, index)" target="_blank"
+                           class="buttonText">{{scope.row.FileName.split('$')[index]}}
+                        </a>
+                      </div>
+                    </el-col>
+                    <el-col :span="4" v-if="scope.row.FileUrl != ''">
+                      <i class="el-icon-close" :style="{'float': 'right', 'height': '100%','line-height': lineheight(scope.row.FileUrlList.length)  + 'px',}" @click="iconclear(scope.row)"></i>
+                    </el-col>
+                  </el-row>
+                </template>
+              </el-table-column>
+              <el-table-column prop="EffectDate" label="变更后有效日期" show-overflow-tooltip >
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.EffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="Remark" label="描述" show-overflow-tooltip></el-table-column>
+            </el-table>
+
+            <el-pagination small
+                           @size-change="handleProjectSizeChange"
+                           @current-change="handleProjectCurrentChange"
+                           :current-page="currentPageProject"
+                           :page-sizes="[10, 20, 30]"
+                           :page-size="sizeProject"
+                           layout="total, sizes, prev, pager, next,jumper"
+                           :total="currentItemCountProject"
+                           style="margin: 5px;">
+            </el-pagination>
+          </el-card>
         </el-tab-pane>
 
         <el-tab-pane label="提交审批">
@@ -797,6 +857,47 @@
         </el-table-column>
       </el-table>
     </el-dialog>
+    <el-dialog :title="Title" :visible.sync="visible" top="5vh">
+      <el-form ref="subfileForm" :model="SubfileForm" :rules="filerules" label-width="100px">
+        <el-row>
+          <el-col :span="12">
+            <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-input v-model="SubfileForm.NeedFileType"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <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>
+          </el-col>
+          <el-col :span="24">
+            <el-form-item label="描述">
+              <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"
+                         :on-remove="filremove" :file-list="fileList" :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;">
+        <el-button @click="visible = false">取 消</el-button>
+        <el-button type="primary" @click="makesure()">确 定</el-button>
+      </div>
+    </el-dialog>
     <choose-auditor ref="chooseAuditor" @close="setAuditer" @hideChooseAuditer="chooseAuditorVisible=false"
       :visible="chooseAuditorVisible"></choose-auditor>
     <choose-auditor-fen ref="chooseAuditorFen" @close="setAuditerFen" @hideChooseAuditer="chooseAuditorVisibleFen=false"
@@ -824,9 +925,12 @@
   import GoodsInfo from '@/components/oilsupplier/goodsinfo'
   import AuditbusList from '@/components/oilsupplier/auditbuslist'
   import ChooseAuditor from '@/components/oilsupplier/chooseauditor'
-  import SubfileList from '@/components/oilsupplier/subfilelist'
+  // import SubfileList from '@/components/oilsupplier/subfilelist'
   import ChooseAuditorFen from '@/components/oilsupplier/chooseauditorfenban'
   import _ from 'lodash'
+  import axios from 'axios'
+  import uploadajax from '@/assets/js//uploadajax.js'
+  import fileapi from '@/api/oilsupplier/supplierfile'
 
   export default {
     computed: {
@@ -839,7 +943,7 @@
       SupplierFileTable,
       WfHistory,
       SupplierCertEdit,
-      SubfileList, // 选择企业资质
+      // SubfileList, // 选择企业资质
       EquipmentList, // 企业主要装备情况
       PerformanceList, // 近三年主要工程业绩列表
       PatentList, // 专利及专有技术列表
@@ -974,6 +1078,9 @@
         }
       }
       return {
+        sizeProject: 10,
+        currentPageProject: 1,
+        currentItemCountProject: 0,
         canadd: false,
         newcanadd: false,
         InfoData: [],
@@ -1355,6 +1462,42 @@
             message: '请选择审批人',
             trigger: 'blur'
           }]
+        },
+        SubfileForm: {
+          Id: '',
+          SupplierId: '',
+          SupplierCertId: '',
+          SupplierTypeCode: '',
+          SupplierCertSubId: '',
+          CertSubName: '',
+          NeedFileType: '',
+          NeedFileCode: '',
+          FileType: '',
+          FileExt: '',
+          FileName: '',
+          EffectDate: new Date(),
+          FileUrl: '',
+          OldFileName: '',
+          OldEffectDate: new Date(),
+          OldFileUrl: '',
+          OtherRemark: '',
+          FileUrlList: [],
+          OldFileUrlList: [],
+          Remark: '',
+          IsDelete: 0
+        },
+        waituploads: [], // 等待上传的附件列表
+        fileList: [],
+        visible: false,
+        IsMust: false,
+        Title: '编辑',
+        yasuoname: '',
+        filerules: {
+          NeedFileType: [
+            {required: true, message: '资质名称不能为空', trigger: 'blur'}
+          ],
+          EffectDate:
+            [{ required: true, message: '请选择有效日期', trigger: 'change' }]
         }
       }
     },
@@ -1380,8 +1523,285 @@
         this.add_flat = false
       }
       this.orgtreeChange(this.majorDept)
+      this.getsubfile()
     },
     methods: {
+      // 资质变更相关
+      lineheight (list) {
+        return list * 23 + ''
+      },
+      fileurlcut (val, index) {
+        let fileurlall = val.split('$')[index]
+        let fileurl = fileurlall.split('|')
+        let retUrl = fileurl[0]
+        // 内网服务器专用
+        if (process.client && retUrl.indexOf('/upfile') === 0) {
+          const myDomain = window.location.host
+          retUrl = myDomain + '/' + retUrl
+        }
+        return retUrl
+      },
+      filremove (file, files) {
+        this.fileList = files
+      },
+      uploadrequest (option) {
+        let _this = this
+        if (process.client) {
+          const myDomain = window.location.host
+          axios.post(process.env.upfilehost, {})
+            .then(function (res) {
+              if (res.data && res.data.fid && res.data.fid !== '') {
+                if (res.data.publicUrl.indexOf('/upfile') === 0) {
+                  option.action = `http://${myDomain}/${res.data.publicUrl}/${res.data.fid}`
+                } else {
+                  option.action = `http://${res.data.publicUrl}/${res.data.fid}`
+                }
+                _this.waituploads.push({
+                  uid: option.file.uid,
+                  url: res.data.publicUrl,
+                  fid: res.data.fid
+                })
+                uploadajax(option)
+              } else {
+                _this.$message({
+                  type: 'warning',
+                  message: '未上传成功!请刷新界面重新上传!'
+                })
+              }
+            })
+            .catch(function (error) {
+              _this.$message({
+                type: 'warning',
+                message: '未上传成功!请重新上传!'
+              })
+            })
+        }
+      },
+      beforeAvatarUpload (file) {
+        /* let isLt512K = file.size / 1024 < 512
+        if (isLt512K) {
+          this.$message.error('上传文件大小不能小于 512KB!')
+          return false
+        } */
+        if (this.SubfileForm.NeedFileType !== this.yasuoname) {
+          let isLt50m = file.size / 1024 / 1024 / 5 < 1
+          if (!isLt50m) {
+            this.$message.error('上传文件大小不能超过 5MB!')
+            return false
+          }
+          return true
+        }
+      },
+      iconclear (row) {
+        this.$confirm('该操作将删除新上传的资质,是否继续?', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          annualapi.deleteNewFile(row.Id, this.$axios).then(res => {
+            if (res.data.code === 0) {
+              this.getsubfile()
+              this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+            } else {
+              this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          })
+        })
+      },
+      openDialog (val) {
+        this.IsMust = true
+        this.Title = '资质变更'
+        this.waituploads = []
+        this.SubfileForm.Id = val.Id
+        this.SubfileForm.SupplierId = val.SupplierId
+        this.SubfileForm.SupplierTypeCode = val.SupplierTypeCode
+        if (val.SupplierCertSubId === 0) {
+          this.SubfileForm.SupplierCertSubId = ''
+        } else {
+          this.SubfileForm.SupplierCertSubId = val.SupplierCertSubId
+        }
+        this.SubfileForm.CertSubName = val.CertSubName
+        this.SubfileForm.NeedFileType = val.NeedFileType
+        this.SubfileForm.NeedFileCode = val.NeedFileCode
+        this.SubfileForm.FileExt = val.FileExt
+        this.SubfileForm.FileType = val.FileType
+        this.SubfileForm.OldFileName = val.OldFileName
+        this.SubfileForm.OldEffectDate = new Date(val.OldEffectDate)
+        this.SubfileForm.EffectDate = (this.jsEffectDate(val.EffectDate))
+        this.SubfileForm.OldFileUrl = val.OldFileUrl
+        this.SubfileForm.OtherRemark = val.OtherRemark
+        this.SubfileForm.FileUrl = val.FileUrl
+        this.fileList = []
+        if (val.FileUrl !== '') {
+          this.getwendanginfo(val.FileUrl)
+        }
+        this.SubfileForm.Remark = val.Remark
+        this.SubfileForm.IsDelete = val.IsDelete
+        this.visible = true
+      },
+      getwendanginfo (iUrl) {
+        let _this = this
+        let urlArr = iUrl.split('$')
+        for (let idx in urlArr) {
+          let exArr = urlArr[idx].split('|')
+          let params = {
+            name: exArr[1],
+            url: exArr[0]
+          }
+          _this.fileList.push(params)
+        }
+      },
+      getFileDictOptions () {
+        fileapi.getDictList(this.$axios).then(res => {
+          this.yasuoname = res.data.items['YaSuoName']
+        }).catch(err => {
+          console.error(err)
+        })
+      },
+      jsEffectDate (val) {
+        if (val === '') {
+          return ''
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return ''
+        } else if (val === '0001-01-01T08:00:00+08:00') {
+          return ''
+        } else if (val === '5000-01-01T23:59:59+08:00') {
+          return ''
+        } else {
+          return val
+        }
+      },
+      makesure () {
+        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
+                }
+                _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: '请上传文件!'
+                })
+              }
+            }
+          }
+        })
+      },
+      // 判断附件是否上传成功
+      attachissuccess () {
+        if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
+          for (let i = 0; i < this.$refs.refuploadattach.uploadFiles.length; i++) {
+            if (this.$refs.refuploadattach.uploadFiles[i].status !== 'success') {
+              return false
+            }
+          }
+        }
+        return true
+      },
+      getattachissuccess () {
+        this.SubfileForm.FileUrl = ''
+        this.SubfileForm.FileName = ''
+        if (this.fileList != null && this.fileList.length > 0) {
+          for (let idx in this.fileList) {
+            this.SubfileForm.FileName += this.fileList[idx].name + '$'
+            this.SubfileForm.FileUrl += this.fileList[idx].url + '|' + this.fileList[idx].name + '$'
+          }
+        }
+        if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
+          for (let i = 0; i < this.$refs.refuploadattach.uploadFiles.length; i++) {
+            if (this.$refs.refuploadattach.uploadFiles[i].status === 'success') {
+              for (let j = 0; j < this.waituploads.length; j++) {
+                if (this.waituploads[j].uid === this.$refs.refuploadattach.uploadFiles[i].uid) {
+                  this.SubfileForm.FileUrl +=
+                    `${this.waituploads[j].url}/${this.waituploads[j].fid}|${this.$refs.refuploadattach.uploadFiles[i].name}$`
+                  this.SubfileForm.FileName += `${this.$refs.refuploadattach.uploadFiles[i].name}$`
+                }
+              }
+            }
+          }
+        }
+      },
+      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('/annualaudit/addqualchange/' + this.annualId, _this.SubfileForm)
+          .then(res => {
+            if (res.data.code === 0) {
+              _this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.visible = false
+              this.getsubfile()
+              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('/annualaudit/editqualchange/' + _this.annualId, _this.SubfileForm)
+          .then(res => {
+            if (res.data.code === 0) {
+              _this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.visible = false
+              this.getsubfile()
+              this.$refs.refuploadattach.uploadFiles = []
+            } else {
+              _this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
+      },
+
       SubpEntity () {
         if (this.UnitOrg === '') {
           this.$message({
@@ -1551,8 +1971,32 @@
         }
         return true
       },
-      getbuslist () {
-        this.$refs['subfileList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
+      getsubfile () {
+        // this.$refs['subfileList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
+        let _this = this
+        const params = {
+          SupplierId: this.formData.Id,
+          SupplierTypeCode: '01',
+          MInfoId: this.annualId,
+          _currentPage: this.currentPageProject,
+          _size: this.sizeProject
+        }
+        _this.$axios.get('annualaudit/filelist', {
+          params
+        })
+          .then(res => {
+            _this.subfileList = res.data.items
+            _this.currentItemCountProject = res.data.currentItemCount
+            for (let idx in _this.subfileList) {
+              _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
+            }
+            for (let idx1 in _this.subfileList) {
+              _this.subfileList[idx1].OldFileUrlList = _this.subfileList[idx1].OldFileUrl.split('$')
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
       },
 
       equipmentdialog () {
@@ -1599,7 +2043,7 @@
             this.$refs['patentList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
             this.$refs['winningList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
             this.$refs['businessList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
-            this.$refs['subfileList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
+            // this.$refs['subfileList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
             if (this.certId && this.WorkflowId) {
               this.$refs['WfHistory'].getHistoryTask() /* 刷新工作流 */
             }
@@ -2191,13 +2635,23 @@
           }
         })
       },
-
+      handleProjectSizeChange (value) {
+        this.sizeProject = value
+        this.currentPageProject = 1
+        this.getsubfile()
+      },
+      handleProjectCurrentChange (value) {
+        this.currentPageProject = value
+        this.getsubfile()
+      },
       nexStepCB () {
         this.Step += 1
       },
       jstimehandle (val) {
         if (val === '') {
           return '----'
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return '----'
         } else if (val === '0001-01-01T08:00:00+08:00') {
           return '----'
         } else if (val === '5000-01-01T23:59:59+08:00') {

+ 460 - 3
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/operation.vue

@@ -516,8 +516,68 @@
         </el-tab-pane>
 
         <el-tab-pane label="企业资质" :disabled="!certId">
-          <subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px"
-            style="margin-top: 20px"></subfile-list>
+          <!--<subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px"-->
+            <!--style="margin-top: 20px"></subfile-list>-->
+          <el-card class="box-card" style="margin-top: 10px;">
+            <div slot="header" class="clearfix">
+              <span style="font-weight: bold">企业资质</span>
+            </div>
+            <el-table :data="subfileList" border>
+              <el-table-column label="操作" width="150" align="center" fixed v-if="Status <= 0">
+                <template slot-scope="scope">
+                  <el-button type="primary" plain size="mini" title="文件变更" @click="openDialog(scope.row)">
+                    变更</el-button>
+                </template>
+              </el-table-column>
+              <el-table-column prop="NeedFileType" label="文件分类" show-overflow-tooltip></el-table-column>
+              <el-table-column prop="OldFileUrlList" label="原文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.OldFileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.OldFileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.OldFileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="OldEffectDate" label="原有效日期" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.OldEffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="FileUrlList" label="变更后文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <el-row align="middle">
+                    <el-col :span="20">
+                      <div v-for="(tmpUrl, index) in scope.row.FileUrlList">
+                        <a :href="'http://'+fileurlcut(scope.row.FileUrl, index)" target="_blank"
+                           class="buttonText">{{scope.row.FileName.split('$')[index]}}
+                        </a>
+                      </div>
+                    </el-col>
+                    <el-col :span="4" v-if="scope.row.FileUrl != ''">
+                      <i class="el-icon-close" :style="{'float': 'right', 'height': '100%','line-height': lineheight(scope.row.FileUrlList.length)  + 'px',}" @click="iconclear(scope.row)"></i>
+                    </el-col>
+                  </el-row>
+                </template>
+              </el-table-column>
+              <el-table-column prop="EffectDate" label="变更后有效日期" show-overflow-tooltip >
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.EffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="Remark" label="描述" show-overflow-tooltip></el-table-column>
+            </el-table>
+
+            <el-pagination small
+                           @size-change="handleProjectSizeChange"
+                           @current-change="handleProjectCurrentChange"
+                           :current-page="currentPageProject"
+                           :page-sizes="[10, 20, 30]"
+                           :page-size="sizeProject"
+                           layout="total, sizes, prev, pager, next,jumper"
+                           :total="currentItemCountProject"
+                           style="margin: 5px;">
+            </el-pagination>
+          </el-card>
         </el-tab-pane>
 
         <el-tab-pane label="提交审批">
@@ -630,6 +690,47 @@
         </el-table-column>
       </el-table>
     </el-dialog>
+    <el-dialog :title="Title" :visible.sync="visible" top="5vh">
+      <el-form ref="subfileForm" :model="SubfileForm" :rules="filerules" label-width="100px">
+        <el-row>
+          <el-col :span="12">
+            <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-input v-model="SubfileForm.NeedFileType"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <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>
+          </el-col>
+          <el-col :span="24">
+            <el-form-item label="描述">
+              <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"
+                         :on-remove="filremove" :file-list="fileList" :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;">
+        <el-button @click="visible = false">取 消</el-button>
+        <el-button type="primary" @click="makesure()">确 定</el-button>
+      </div>
+    </el-dialog>
     <choose-auditor ref="chooseAuditor" @close="setAuditer" @hideChooseAuditer="chooseAuditorVisible=false"
       :visible="chooseAuditorVisible"></choose-auditor>
     <choose-auditor-fen ref="chooseAuditorFen" @close="setAuditerFen" @hideChooseAuditer="chooseAuditorVisibleFen=false"
@@ -659,6 +760,9 @@
   import SubfileList from '@/components/oilsupplier/subfilelist'
   import ChooseAuditorFen from '@/components/oilsupplier/chooseauditorfenban'
   import _ from 'lodash'
+  import axios from 'axios'
+  import uploadajax from '@/assets/js//uploadajax.js'
+  import fileapi from '@/api/oilsupplier/supplierfile'
 
   export default {
     computed: {
@@ -794,6 +898,9 @@
       }
 
       return {
+        sizeProject: 10,
+        currentPageProject: 1,
+        currentItemCountProject: 0,
         canadd: false,
         AccessCardNo: '',
         InStyle: '',
@@ -1177,6 +1284,42 @@
             message: '请选择审批人',
             trigger: 'blur'
           }]
+        },
+        SubfileForm: {
+          Id: '',
+          SupplierId: '',
+          SupplierCertId: '',
+          SupplierTypeCode: '',
+          SupplierCertSubId: '',
+          CertSubName: '',
+          NeedFileType: '',
+          NeedFileCode: '',
+          FileType: '',
+          FileExt: '',
+          FileName: '',
+          EffectDate: new Date(),
+          FileUrl: '',
+          OldFileName: '',
+          OldEffectDate: new Date(),
+          OldFileUrl: '',
+          OtherRemark: '',
+          FileUrlList: [],
+          OldFileUrlList: [],
+          Remark: '',
+          IsDelete: 0
+        },
+        waituploads: [], // 等待上传的附件列表
+        fileList: [],
+        visible: false,
+        IsMust: false,
+        Title: '编辑',
+        yasuoname: '',
+        filerules: {
+          NeedFileType: [
+            {required: true, message: '资质名称不能为空', trigger: 'blur'}
+          ],
+          EffectDate:
+            [{ required: true, message: '请选择有效日期', trigger: 'change' }]
         }
       }
     },
@@ -1201,8 +1344,320 @@
         this.add_flat = false
       }
       // this.orgtreeChange(this.majorDept)
+      this.getsubfile()
     },
     methods: {
+      // 资质变更相关
+      lineheight (list) {
+        return list * 23 + ''
+      },
+      fileurlcut (val, index) {
+        let fileurlall = val.split('$')[index]
+        let fileurl = fileurlall.split('|')
+        let retUrl = fileurl[0]
+        // 内网服务器专用
+        if (process.client && retUrl.indexOf('/upfile') === 0) {
+          const myDomain = window.location.host
+          retUrl = myDomain + '/' + retUrl
+        }
+        return retUrl
+      },
+      filremove (file, files) {
+        this.fileList = files
+      },
+      uploadrequest (option) {
+        let _this = this
+        if (process.client) {
+          const myDomain = window.location.host
+          axios.post(process.env.upfilehost, {})
+            .then(function (res) {
+              if (res.data && res.data.fid && res.data.fid !== '') {
+                if (res.data.publicUrl.indexOf('/upfile') === 0) {
+                  option.action = `http://${myDomain}/${res.data.publicUrl}/${res.data.fid}`
+                } else {
+                  option.action = `http://${res.data.publicUrl}/${res.data.fid}`
+                }
+                _this.waituploads.push({
+                  uid: option.file.uid,
+                  url: res.data.publicUrl,
+                  fid: res.data.fid
+                })
+                uploadajax(option)
+              } else {
+                _this.$message({
+                  type: 'warning',
+                  message: '未上传成功!请刷新界面重新上传!'
+                })
+              }
+            })
+            .catch(function (error) {
+              _this.$message({
+                type: 'warning',
+                message: '未上传成功!请重新上传!'
+              })
+            })
+        }
+      },
+      beforeAvatarUpload (file) {
+        /* let isLt512K = file.size / 1024 < 512
+        if (isLt512K) {
+          this.$message.error('上传文件大小不能小于 512KB!')
+          return false
+        } */
+        if (this.SubfileForm.NeedFileType !== this.yasuoname) {
+          let isLt50m = file.size / 1024 / 1024 / 5 < 1
+          if (!isLt50m) {
+            this.$message.error('上传文件大小不能超过 5MB!')
+            return false
+          }
+          return true
+        }
+      },
+      iconclear (row) {
+        this.$confirm('该操作将删除新上传的资质,是否继续?', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          annualapi.deleteNewFile(row.Id, this.$axios).then(res => {
+            if (res.data.code === 0) {
+              this.getsubfile()
+              this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+            } else {
+              this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          })
+        })
+      },
+      openDialog (val) {
+        this.IsMust = true
+        this.Title = '资质变更'
+        this.waituploads = []
+        this.SubfileForm.Id = val.Id
+        this.SubfileForm.SupplierId = val.SupplierId
+        this.SubfileForm.SupplierTypeCode = val.SupplierTypeCode
+        if (val.SupplierCertSubId === 0) {
+          this.SubfileForm.SupplierCertSubId = ''
+        } else {
+          this.SubfileForm.SupplierCertSubId = val.SupplierCertSubId
+        }
+        this.SubfileForm.CertSubName = val.CertSubName
+        this.SubfileForm.NeedFileType = val.NeedFileType
+        this.SubfileForm.NeedFileCode = val.NeedFileCode
+        this.SubfileForm.FileExt = val.FileExt
+        this.SubfileForm.FileType = val.FileType
+        this.SubfileForm.OldFileName = val.OldFileName
+        this.SubfileForm.OldEffectDate = new Date(val.OldEffectDate)
+        this.SubfileForm.EffectDate = (this.jsEffectDate(val.EffectDate))
+        this.SubfileForm.OldFileUrl = val.OldFileUrl
+        this.SubfileForm.OtherRemark = val.OtherRemark
+        this.SubfileForm.FileUrl = val.FileUrl
+        this.fileList = []
+        if (val.FileUrl !== '') {
+          this.getwendanginfo(val.FileUrl)
+        }
+        this.SubfileForm.Remark = val.Remark
+        this.SubfileForm.IsDelete = val.IsDelete
+        this.visible = true
+      },
+      getwendanginfo (iUrl) {
+        let _this = this
+        let urlArr = iUrl.split('$')
+        for (let idx in urlArr) {
+          let exArr = urlArr[idx].split('|')
+          let params = {
+            name: exArr[1],
+            url: exArr[0]
+          }
+          _this.fileList.push(params)
+        }
+      },
+      getFileDictOptions () {
+        fileapi.getDictList(this.$axios).then(res => {
+          this.yasuoname = res.data.items['YaSuoName']
+        }).catch(err => {
+          console.error(err)
+        })
+      },
+      jsEffectDate (val) {
+        if (val === '') {
+          return ''
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return ''
+        } else if (val === '0001-01-01T08:00:00+08:00') {
+          return ''
+        } else if (val === '5000-01-01T23:59:59+08:00') {
+          return ''
+        } else {
+          return val
+        }
+      },
+      makesure () {
+        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
+                }
+                _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: '请上传文件!'
+                })
+              }
+            }
+          }
+        })
+      },
+      // 判断附件是否上传成功
+      attachissuccess () {
+        if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
+          for (let i = 0; i < this.$refs.refuploadattach.uploadFiles.length; i++) {
+            if (this.$refs.refuploadattach.uploadFiles[i].status !== 'success') {
+              return false
+            }
+          }
+        }
+        return true
+      },
+      getattachissuccess () {
+        this.SubfileForm.FileUrl = ''
+        this.SubfileForm.FileName = ''
+        if (this.fileList != null && this.fileList.length > 0) {
+          for (let idx in this.fileList) {
+            this.SubfileForm.FileName += this.fileList[idx].name + '$'
+            this.SubfileForm.FileUrl += this.fileList[idx].url + '|' + this.fileList[idx].name + '$'
+          }
+        }
+        if (this.$refs.refuploadattach.uploadFiles && this.$refs.refuploadattach.uploadFiles.length > 0) {
+          for (let i = 0; i < this.$refs.refuploadattach.uploadFiles.length; i++) {
+            if (this.$refs.refuploadattach.uploadFiles[i].status === 'success') {
+              for (let j = 0; j < this.waituploads.length; j++) {
+                if (this.waituploads[j].uid === this.$refs.refuploadattach.uploadFiles[i].uid) {
+                  this.SubfileForm.FileUrl +=
+                    `${this.waituploads[j].url}/${this.waituploads[j].fid}|${this.$refs.refuploadattach.uploadFiles[i].name}$`
+                  this.SubfileForm.FileName += `${this.$refs.refuploadattach.uploadFiles[i].name}$`
+                }
+              }
+            }
+          }
+        }
+      },
+      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('/annualaudit/addqualchange/' + this.annualId, _this.SubfileForm)
+          .then(res => {
+            if (res.data.code === 0) {
+              _this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.visible = false
+              this.getsubfile()
+              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('/annualaudit/editqualchange/' + _this.annualId, _this.SubfileForm)
+          .then(res => {
+            if (res.data.code === 0) {
+              _this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.visible = false
+              this.getsubfile()
+              this.$refs.refuploadattach.uploadFiles = []
+            } else {
+              _this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
+      },
+      getsubfile () {
+        let _this = this
+        const params = {
+          SupplierId: this.formData.Id,
+          SupplierTypeCode: '03',
+          MInfoId: this.annualId,
+          _currentPage: this.currentPageProject,
+          _size: this.sizeProject
+        }
+        _this.$axios.get('annualaudit/filelist', {
+          params
+        })
+          .then(res => {
+            _this.subfileList = res.data.items
+            _this.currentItemCountProject = res.data.currentItemCount
+            for (let idx in _this.subfileList) {
+              _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
+            }
+            for (let idx1 in _this.subfileList) {
+              _this.subfileList[idx1].OldFileUrlList = _this.subfileList[idx1].OldFileUrl.split('$')
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
+      },
+      handleProjectSizeChange (value) {
+        this.sizeProject = value
+        this.currentPageProject = 1
+        this.getsubfile()
+      },
+      handleProjectCurrentChange (value) {
+        this.currentPageProject = value
+        this.getsubfile()
+      },
+
       chooseAuditorShowFen () {
         this.$refs['chooseAuditorFen'].getorgtreelist('04')
         this.chooseAuditorVisibleFen = true
@@ -1409,7 +1864,7 @@
             this.$refs['patentList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
             this.$refs['winningList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
             this.$refs['businessList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
-            this.$refs['subfileList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
+            // this.$refs['subfileList'].getvalue(res.data.Id, this.SupplierTypeCode, this.certId)
             if (this.certId && this.WorkflowId) {
               this.$refs['WfHistory'].getHistoryTask() /* 刷新工作流*/
             }
@@ -2043,6 +2498,8 @@
       jstimehandle (val) {
         if (val === '') {
           return '----'
+        } else if (val === '0001-01-01T00:00:00Z') {
+          return '----'
         } else if (val === '0001-01-01T08:00:00+08:00') {
           return '----'
         } else if (val === '5000-01-01T23:59:59+08:00') {

+ 111 - 6
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/techoperation.vue

@@ -511,8 +511,60 @@
         </el-tab-pane>
 
         <el-tab-pane label="企业资质" :disabled="!certId">
-          <subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px"
-            style="margin-top: 20px"></subfile-list>
+          <!--<subfile-list ref="subfileList" :data.sync="subfileList" :canadd="canadd" height="360px"-->
+            <!--style="margin-top: 20px"></subfile-list>-->
+          <el-card class="box-card" style="margin-top: 10px;">
+            <div slot="header" class="clearfix">
+              <span style="font-weight: bold">企业资质</span>
+            </div>
+            <el-table :data="subfileList" border>
+              <!--<el-table-column label="操作" width="150" align="center" fixed>-->
+              <!--<template slot-scope="scope">-->
+              <!--<el-button type="primary" plain size="mini" title="文件变更" @click="openDialog(scope.row)">-->
+              <!--变更</el-button>-->
+              <!--</template>-->
+              <!--</el-table-column>-->
+              <el-table-column prop="NeedFileType" label="文件分类" show-overflow-tooltip></el-table-column>
+              <el-table-column prop="OldFileUrlList" label="原文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.OldFileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.OldFileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.OldFileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="OldEffectDate" label="原有效日期" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.OldEffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="FileUrlList" label="变更后文件" show-overflow-tooltip>
+                <template slot-scope="scope">
+                  <div v-for="(tmpUrl, index) in scope.row.FileUrlList">
+                    <a :href="'http://'+fileurlcut(scope.row.FileUrl, index)" target="_blank"
+                       class="buttonText">{{scope.row.FileName.split('$')[index]}}</a>
+                  </div>
+                </template>
+              </el-table-column>
+              <el-table-column prop="EffectDate" label="变更后有效日期" show-overflow-tooltip >
+                <template slot-scope="scope">
+                  {{ jstimehandle(scope.row.EffectDate+'') }}
+                </template>
+              </el-table-column>
+              <el-table-column prop="Remark" label="描述" show-overflow-tooltip></el-table-column>
+            </el-table>
+
+            <el-pagination small
+                           @size-change="handleProjectSizeChange"
+                           @current-change="handleProjectCurrentChange"
+                           :current-page="currentPageProject"
+                           :page-sizes="[10, 20, 30]"
+                           :page-size="sizeProject"
+                           layout="total, sizes, prev, pager, next,jumper"
+                           :total="currentItemCountProject"
+                           style="margin: 5px;">
+            </el-pagination>
+          </el-card>
         </el-tab-pane>
 
 
@@ -651,7 +703,7 @@
   import BusinessList from '@/components/oilsupplier/businesslist'
   import TechInfo from '@/components/oilsupplier/techinfo'
   import AuditbusList from '@/components/oilsupplier/auditbuslist'
-  import SubfileList from '@/components/oilsupplier/subfilelist'
+  // import SubfileList from '@/components/oilsupplier/subfilelist'
   import WfHistory from '@/components/workflow/wfmultihistory.vue'
   import ChooseAuditor from '@/components/oilsupplier/chooseauditor'
   import _ from 'lodash'
@@ -666,7 +718,7 @@
       SupplierFileTable,
       WfHistory,
       SupplierCertEdit,
-      SubfileList, // 选择企业资质
+      // SubfileList, // 选择企业资质
       EquipmentList, // 企业主要设备
       PerformanceList, // 近三年主要业绩列表
       PatentList, // 专利及专有技术列表
@@ -788,6 +840,9 @@
         }
       }
       return {
+        sizeProject: 10,
+        currentPageProject: 1,
+        currentItemCountProject: 0,
         canadd: false,
         AccessCardNo: '',
         InStyle: '',
@@ -1252,8 +1307,58 @@
       this.getannualdata()
       // this.getorgtreelistbydeptid()
       // this.orgtreeChange(this.majorDept)
+      this.getsubfile()
     },
     methods: {
+      // ======
+      fileurlcut (val, index) {
+        let fileurlall = val.split('$')[index]
+        let fileurl = fileurlall.split('|')
+        let retUrl = fileurl[0]
+        // 内网服务器专用
+        if (process.client && retUrl.indexOf('/upfile') === 0) {
+          const myDomain = window.location.host
+          retUrl = myDomain + '/' + retUrl
+        }
+        return retUrl
+      },
+      getsubfile () {
+        // this.$refs['subfileList'].getvalue(this.formData.Id, this.SupplierTypeCode, this.certId)
+        let _this = this
+        const params = {
+          SupplierId: this.formData.Id,
+          SupplierTypeCode: '03',
+          MInfoId: this.annualId,
+          _currentPage: this.currentPageProject,
+          _size: this.sizeProject
+        }
+        _this.$axios.get('annualaudit/filelist', {
+          params
+        })
+          .then(res => {
+            _this.subfileList = res.data.items
+            _this.currentItemCountProject = res.data.currentItemCount
+            for (let idx in _this.subfileList) {
+              _this.subfileList[idx].FileUrlList = _this.subfileList[idx].FileUrl.split('$')
+            }
+            for (let idx1 in _this.subfileList) {
+              _this.subfileList[idx1].OldFileUrlList = _this.subfileList[idx1].OldFileUrl.split('$')
+            }
+          })
+          .catch(err => {
+            console.error(err)
+          })
+      },
+      handleProjectSizeChange (value) {
+        this.sizeProject = value
+        this.currentPageProject = 1
+        this.getsubfile()
+      },
+      handleProjectCurrentChange (value) {
+        this.currentPageProject = value
+        this.getsubfile()
+      },
+
       fenbanBtn () {
         this.shenheForm.AnnualId = parseInt(this.annualId)
         this.addshow = true
@@ -1495,7 +1600,7 @@
             this.$refs['patentList'].getvalue(this.formDatacp.Id, this.formDatacp.SupplierTypeCode, this.certId)
             this.$refs['winningList'].getvalue(this.formDatacp.Id, this.formDatacp.SupplierTypeCode, this.certId)
             this.$refs['businessList'].getvalue(this.formDatacp.Id, this.formDatacp.SupplierTypeCode, this.certId)
-            this.$refs['subfileList'].getvalue(this.formDatacp.Id, this.formDatacp.SupplierTypeCode, this.certId)
+            // this.$refs['subfileList'].getvalue(this.formDatacp.Id, this.formDatacp.SupplierTypeCode, this.certId)
             if (this.certId && this.WorkflowId) {
               this.$refs['WfHistory'].getHistoryTask() /*  刷新工作流 */
             }
@@ -1559,7 +1664,7 @@
         })
       },
       getbuslist () {
-        this.$refs['subfileList'].getvalue(this.formDatacp.Id, this.formDatacp.SupplierTypeCode, this.certId)
+        // this.$refs['subfileList'].getvalue(this.formDatacp.Id, this.formDatacp.SupplierTypeCode, this.certId)
       },
 
       getorgtreelist () {

+ 1 - 1
src/dashoo.cn/frontend_web/src/pages/oilsupplier/infochangech/_opera/operation.vue

@@ -496,7 +496,7 @@
                        layout="total, sizes, prev, pager, next,jumper"
                        :total="currentItemCountProject"
                        style="margin: 5px;">
-        </el-pagination>
+              </el-pagination>
           </el-card>
         </el-tab-pane>