lining 5 years ago
parent
commit
9b2b4155f6

+ 2 - 2
src/dashoo.cn/backend/api/business/oilsupplier/infochange/infochange.go

@@ -185,8 +185,8 @@ type OilInfoChangeItem struct {
 	SupplierId       int       `xorm:"comment('供方Id') INT(10)"`
 	SelectItem       string    `xorm:"comment('变更字段名') VARCHAR(50)"`
 	SelectItemName   string    `xorm:"comment('变更字段名') VARCHAR(255)"`
-	BeChangeInfo     string    `xorm:"comment('变更前内容') VARCHAR(255)"`
-	ChangeInfo       string    `xorm:"comment('变更后内容') VARCHAR(255)"`
+	BeChangeInfo     string    `xorm:"comment('变更前内容') TEXT"`
+	ChangeInfo       string    `xorm:"comment('变更后内容') TEXT"`
 	ChangeStatus     int       `xorm:"comment('变更状态') INT(10)"`
 	CreateOn         time.Time `xorm:"DATETIME"`
 	CreateUserId     int       `xorm:"INT(10)"`

+ 5 - 1
src/dashoo.cn/backend/api/business/oilsupplier/qualchange/qualchangeService.go

@@ -151,7 +151,11 @@ func (s *QualChangeService) GetQualPagingEntities(FileName, qualChangeName strin
 
 	//获取总记录数
 	sqlCount := `select count(*) from ` + FileName + ` a `
-	sqlCount += ` left join ` + qualChangeName + " b on b.FileId = a.Id"
+	if MInfoId != "" {
+		sqlCount += ` left join ` + qualChangeName + " b on b.FileId = a.Id AND b.ParentId =" + MInfoId
+	} else {
+		sqlCount += ` left join ` + qualChangeName + " b on b.FileId = a.Id"
+	}
 	sqlCount += ` where ` + where
 
 	var sql string

+ 2 - 2
src/dashoo.cn/backend/api/business/oilsupplier/suppliercertappendsub/oilsuppliercertappendsub.go

@@ -50,8 +50,8 @@ type OilAppendChangeItem struct {
 	SupplierId       int       `xorm:"comment('供方Id') INT(10)"`
 	SelectItem       string    `xorm:"comment('变更字段名') VARCHAR(50)"`
 	SelectItemName   string    `xorm:"comment('变更字段名') VARCHAR(255)"`
-	BeChangeInfo     string    `xorm:"comment('变更前内容') VARCHAR(255)"`
-	ChangeInfo       string    `xorm:"comment('变更后内容') VARCHAR(255)"`
+	BeChangeInfo     string    `xorm:"comment('变更前内容') TEXT"`
+	ChangeInfo       string    `xorm:"comment('变更后内容') TEXT"`
 	ChangeStatus     int       `xorm:"comment('变更状态') INT(10)"`
 	CreateOn         time.Time `xorm:"DATETIME"`
 	CreateUserId     int       `xorm:"INT(10)"`

+ 3 - 2
src/dashoo.cn/backend/api/controllers/oilsupplier/qualchange.go

@@ -266,6 +266,7 @@ func (this *QualChangeController) AuditFileList() {
 		}
 	}
 	SupplierId := this.GetString("SupplierId")
+	MInfoId := this.GetString("MInfoId")
 	if SupplierId != "" {
 		where = where + " and a.SupplierId = '" + SupplierId + "'"
 	}
@@ -274,7 +275,7 @@ func (this *QualChangeController) AuditFileList() {
 		where = where + " and a.SupplierTypeCode in ( '000', '" + SupplierTypeCode + "')"
 	}
 	where = where + " and (b.FileUrl != '' OR a.IsDelete = 1)"
-	total := svc.GetQualPagingEntities(OilSupplierFileName, OilQualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, "")
+	total := svc.GetQualPagingEntities(OilSupplierFileName, OilQualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total
@@ -529,7 +530,7 @@ func (this *QualChangeController) EditQualChange() {
 		entity.CreateUserId, _ = utils.StrTo(this.User.Id).Int()
 		_, err = svc.InsertEntityBytbl(OilQualChangeDetailName, &entity)
 	} else {
-		err = svc.UpdateEntityBywheretbl(OilQualChangeDetailName, &entity, []string{"OldEffectDate", "FileUrl", "FileName", "OtherRemark"}, qdwhere)
+		err = svc.UpdateEntityBywheretbl(OilQualChangeDetailName, &entity, []string{"EffectDate", "FileUrl", "FileName", "OtherRemark"}, qdwhere)
 	}
 
 	if err == nil {

+ 3 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/infochangech/_opera/auditoperation.vue

@@ -1327,6 +1327,7 @@
         const params = {
           SupplierId: this.SuppId,
           SupplierTypeCode: '01',
+          MInfoId: this.infoId,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject
         }
@@ -1457,6 +1458,7 @@
         const params = {
           SupplierId: this.SuppId,
           SupplierTypeCode: '02',
+          MInfoId: this.infoId,
           _currentPage: 1,
           _size: 1000,
         }
@@ -1502,6 +1504,7 @@
         const params = {
           SupplierId: this.SuppId,
           SupplierTypeCode: '03',
+          MInfoId: this.infoId,
           _currentPage: 1,
           _size: 1000,
         }

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

@@ -399,7 +399,7 @@
               </el-col>
               <el-col :span="8">
                 <el-form-item label="营业范围" prop="BusinessScope">
-                  <el-input v-model="formData.BusinessScope" maxlength="200" placeholder="营业执照上的信息" type="textarea"
+                  <el-input v-model="formData.BusinessScope" placeholder="营业执照上的信息" type="textarea"
                     :class="changedForm['BusinessScope'] ? 'modified-form-input' : ''" style="width: 100%"></el-input>
                 </el-form-item>
               </el-col>

+ 6 - 5
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/basisdataopera.vue

@@ -366,7 +366,7 @@
                 </el-col>
                 <el-col :span="16">
                   <el-form-item label="营业范围" prop="BusinessScope">
-                    <el-input v-model="supplierData.BusinessScope" maxlength="200" placeholder="营业执照上的信息" type="textarea"
+                    <el-input v-model="supplierData.BusinessScope" placeholder="营业执照上的信息" type="textarea"
                               :class="changedForm['BusinessScope'] ? 'modified-form-input' : ''" style="width: 100%"></el-input>
                   </el-form-item>
                 </el-col>
@@ -1395,16 +1395,16 @@
       this.orgtreeChange(this.majorDept)
       this.changeOrgUnit(this.selectDept)
       this.initTableHeader()
-      this.getsubfile()
+      //this.getsubfile()
     },
     methods: {
       // =======================================
       getsubfile () {
         let _this = this
         const params = {
-          SupplierId: this.supplierId,
+          SupplierId: this.formData.SupplierId + '',
           SupplierTypeCode: '02',
-          MInfoId: this.Id
+          MInfoId: this.Id + ''
         }
         _this.$axios.get('suppliercertappendsub/filelist', {
           params
@@ -2040,6 +2040,7 @@
           _this.getSortList()
           _this.getMySortList()
           _this.getSupplierData()
+          _this.getsubfile()
         }).catch(err => {
           console.error(err)
         })
@@ -2054,7 +2055,7 @@
           if (valid) {
             let AllInfochangeItemList = {
               SupplierId: this.formData.SupplierId + '',
-              MInfoId: this.Id,
+              MInfoId: this.Id + '',
               InfochangeForm: this.infochangeItemList
             }
             api.addInfoChangeItemCh(AllInfochangeItemList, this.$axios).then(res => {

+ 6 - 5
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/goodsdataopera.vue

@@ -432,7 +432,7 @@
                 </el-col>
                 <el-col :span="16">
                   <el-form-item label="营业范围" prop="BusinessScope">
-                    <el-input v-model="supplierData.BusinessScope" maxlength="200" placeholder="营业执照上的信息" type="textarea"
+                    <el-input v-model="supplierData.BusinessScope" placeholder="营业执照上的信息" type="textarea"
                               :class="changedForm['BusinessScope'] ? 'modified-form-input' : ''" style="width: 100%"></el-input>
                   </el-form-item>
                 </el-col>
@@ -1692,16 +1692,16 @@
       this.changeOrgUnit(this.selectDept)
       this.initTableHeader()
       this.initData2019()
-      this.getsubfile()
+      // this.getsubfile()
     },
     methods: {
       // =======================================
       getsubfile () {
         let _this = this
         const params = {
-          SupplierId: this.supplierId,
+          SupplierId: this.formData.SupplierId + '',
           SupplierTypeCode: '01',
-          MInfoId: this.Id
+          MInfoId: this.Id + ''
         }
         _this.$axios.get('suppliercertappendsub/filelist', {
           params
@@ -2085,6 +2085,7 @@
           _this.getMySortList()
           _this.getSupplier()
           _this.getSupplierData()
+          _this.getsubfile()
         }).catch(err => {
           console.error(err)
         })
@@ -2099,7 +2100,7 @@
           if (valid) {
             let AllInfochangeItemList = {
               SupplierId: this.formData.SupplierId + '',
-              MInfoId: this.Id,
+              MInfoId: this.Id + '',
               InfochangeForm: this.infochangeItemList
             }
             api.addInfoChangeItemCh(AllInfochangeItemList, this.$axios).then(res => {

+ 6 - 5
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/techdataopera.vue

@@ -366,7 +366,7 @@
                 </el-col>
                 <el-col :span="16">
                   <el-form-item label="营业范围" prop="BusinessScope">
-                    <el-input v-model="supplierData.BusinessScope" maxlength="200" placeholder="营业执照上的信息" type="textarea"
+                    <el-input v-model="supplierData.BusinessScope" placeholder="营业执照上的信息" type="textarea"
                               :class="changedForm['BusinessScope'] ? 'modified-form-input' : ''" style="width: 100%"></el-input>
                   </el-form-item>
                 </el-col>
@@ -1374,16 +1374,16 @@
       // this.orgtreeChange(this.majorDept)
       // this.changeOrgUnit(this.selectDept)
       this.initTableHeader()
-      this.getsubfile()
+      // this.getsubfile()
     },
     methods: {
       // =======================================
       getsubfile () {
         let _this = this
         const params = {
-          SupplierId: this.supplierId,
+          SupplierId: this.formData.SupplierId + '',
           SupplierTypeCode: '03',
-          MInfoId: this.Id
+          MInfoId: this.Id + ''
         }
         _this.$axios.get('suppliercertappendsub/filelist', {
           params
@@ -1662,6 +1662,7 @@
           _this.getSortList()
           _this.getMySortList()
           _this.getSupplierData()
+          _this.getsubfile()
         }).catch(err => {
           console.error(err)
         })
@@ -1676,7 +1677,7 @@
           if (valid) {
             let AllInfochangeItemList = {
               SupplierId: this.formData.SupplierId + '',
-              MInfoId: this.Id,
+              MInfoId: this.Id + '',
               InfochangeForm: this.infochangeItemList
             }
             api.addInfoChangeItemCh(AllInfochangeItemList, this.$axios).then(res => {