2
3
Prechádzať zdrojové kódy

前后:资质文件展示

dubch 4 rokov pred
rodič
commit
92c091abef
21 zmenil súbory, kde vykonal 133 pridanie a 4 odobranie
  1. 43 0
      src/dashoo.cn/backend/api/business/oilsupplier/qualchange/qualchangeService.go
  2. 39 0
      src/dashoo.cn/backend/api/business/oilsupplier/suppliercertappendsub/oilsuppliercertappendsubService.go
  3. 7 1
      src/dashoo.cn/backend/api/controllers/oilsupplier/annualaudit.go
  4. 14 2
      src/dashoo.cn/backend/api/controllers/oilsupplier/qualchange.go
  5. 7 1
      src/dashoo.cn/backend/api/controllers/oilsupplier/suppliercertappendsub.go
  6. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/addtionaudit/_opera/basisdataopera.vue
  7. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/addtionaudit/_opera/goodsdataopera.vue
  8. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/addtionaudit/_opera/techdataopera.vue
  9. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/auditoperation.vue
  10. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/basicauditoperation.vue
  11. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/bassicoperation.vue
  12. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/goodsoperation.vue
  13. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/operation.vue
  14. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/techoperation.vue
  15. 3 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/infochangech/_opera/auditoperation.vue
  16. 3 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/infochangech/_opera/operation.vue
  17. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/basisdataopera.vue
  18. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/goodsdataopera.vue
  19. 1 0
      src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/techdataopera.vue
  20. 1 0
      src/dashoo.cn/frontend_web/src/pages/select/processselect/index.vue
  21. 4 0
      src/dashoo.cn/frontend_web/src/pages/select/processselect/wfmultihistory.vue

+ 43 - 0
src/dashoo.cn/backend/api/business/oilsupplier/qualchange/qualchangeService.go

@@ -190,3 +190,46 @@ func (s *QualChangeService) GetQualPagingEntities(FileName, qualChangeName strin
 	}
 	return total
 }
+func (s *QualChangeService) GetQualPagingEntitiesStatus(FileName, qualChangeName string, pageIndex, itemsPerPage int64, orderby string, asc bool, entitiesPtr interface{}, where, MInfoId string) (total int64) {
+	var resultsSlice []map[string][]byte
+
+	//获取总记录数
+	sqlCount := `select count(*) from ` + FileName + ` a `
+	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
+	sql = `select a.Id Id, a.SupplierId SupplierId, a.SupplierTypeCode SupplierTypeCode, a.SupplierCertSubId SupplierCertSubId, a.CertSubName CertSubName, a.OtherRemark Remark,`
+	sql += ` a.NeedFileType NeedFileType, a.NeedFileCode NeedFileCode, a.FileExt FileExt, a.FileType FileType, `
+	sql += ` a.EffectDate OldEffectDate, a.FileUrl OldFileUrl, a.FileName OldFileName, `
+	sql += ` '' as EffectDate, '' as FileUrl, '' as FileName, `
+	sql += ` b.ParentId,b.Remark Remark1, a.IsDelete `
+	sql += ` from ` + FileName + ` a `
+	if MInfoId != "" {
+		sql += ` left join ` + qualChangeName + " b on b.FileId = a.Id AND b.ParentId =" + MInfoId
+	} else {
+		sql += ` left join ` + qualChangeName + " b on b.FileId = a.Id"
+	}
+	sql += ` where ` + where
+	if asc {
+		sql += ` order by ` + orderby + ` ASC `
+	} else {
+		sql += ` order by ` + orderby + ` DESC `
+	}
+	sql += ` limit ` + utils.ToStr((pageIndex-1)*itemsPerPage) + "," + utils.ToStr(itemsPerPage)
+	s.DBE.SQL(sql).Find(entitiesPtr)
+	resultsSlice, _ = s.DBE.Query(sqlCount)
+
+	if len(resultsSlice) > 0 {
+		results := resultsSlice[0]
+		for _, value := range results {
+			total, _ = strconv.ParseInt(string(value), 10, 64)
+			break
+		}
+	}
+	return total
+}

+ 39 - 0
src/dashoo.cn/backend/api/business/oilsupplier/suppliercertappendsub/oilsuppliercertappendsubService.go

@@ -47,6 +47,45 @@ func (s *OilSupplierCertAppendSubService) GetQualPagingEntities(FileName, qualCh
 	s.DBE.SQL(sql).Find(entitiesPtr)
 	resultsSlice, _ = s.DBE.Query(sqlCount)
 
+	if len(resultsSlice) > 0 {
+		results := resultsSlice[0]
+		for _, value := range results {
+			total, _ = strconv.ParseInt(string(value), 10, 64)
+			break
+		}
+	}
+	return total
+}
+func (s *OilSupplierCertAppendSubService) GetQualPagingEntitiesStatus(FileName, qualChangeName string, pageIndex, itemsPerPage int64, orderby string, asc bool, entitiesPtr interface{}, where, MInfoId string) (total int64) {
+	var resultsSlice []map[string][]byte
+
+	//获取总记录数
+	sqlCount := `select count(*) from ` + FileName + ` a `
+	sqlCount += ` left join ` + qualChangeName + " b on b.FileId = a.Id"
+	sqlCount += ` where ` + where
+
+	var sql string
+	sql = `select a.Id Id, a.SupplierId SupplierId, a.SupplierTypeCode SupplierTypeCode, a.SupplierCertSubId SupplierCertSubId, a.CertSubName CertSubName,a.OtherRemark Remark, `
+	sql += ` a.NeedFileType NeedFileType, a.NeedFileCode NeedFileCode, a.FileExt FileExt, a.FileType FileType, `
+	sql += ` a.EffectDate OldEffectDate, a.FileUrl OldFileUrl, a.FileName OldFileName, `
+	sql += ` '' as EffectDate, '' as FileUrl, '' as FileName, `
+	sql += ` b.EffectDate EffectDate, b.FileUrl FileUrl, b.FileName FileName, b.ParentId, b.OtherRemark Remark1, a.IsDelete `
+	sql += ` from ` + FileName + ` a `
+	if MInfoId != "" {
+		sql += ` left join ` + qualChangeName + " b on b.FileId = a.Id AND b.ParentId =" + MInfoId
+	} else {
+		sql += ` left join ` + qualChangeName + " b on b.FileId = a.Id"
+	}
+	sql += ` where ` + where
+	if asc {
+		sql += ` order by ` + orderby + ` ASC `
+	} else {
+		sql += ` order by ` + orderby + ` DESC `
+	}
+	//sql += ` limit ` + utils.ToStr((pageIndex-1)*itemsPerPage) + "," + utils.ToStr(itemsPerPage)
+	s.DBE.SQL(sql).Find(entitiesPtr)
+	resultsSlice, _ = s.DBE.Query(sqlCount)
+
 	if len(resultsSlice) > 0 {
 		results := resultsSlice[0]
 		for _, value := range results {

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

@@ -1660,7 +1660,13 @@ func (this *AnnualAuditController) FileList() {
 	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 total int64
+	AuditStatus := this.GetString("Status")
+	if AuditStatus == "8" {
+		total = svc.GetQualPagingEntitiesStatus(OilSupplierFileName, OilAnnualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	} else {
+		total = svc.GetQualPagingEntities(OilSupplierFileName, OilAnnualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	}
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total

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

@@ -209,7 +209,13 @@ func (this *QualChangeController) FileList() {
 		where = where + " and a.SupplierTypeCode in ( '000', '" + SupplierTypeCode + "')"
 	}
 
-	total := svc.GetQualPagingEntities(OilSupplierFileName, OilQualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	var total int64
+	AuditStatus := this.GetString("Status")
+	if AuditStatus == "8" {
+		total = svc.GetQualPagingEntitiesStatus(OilSupplierFileName, OilQualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	} else {
+		total = svc.GetQualPagingEntities(OilSupplierFileName, OilQualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	}
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total
@@ -276,7 +282,13 @@ 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, MInfoId)
+	var total int64
+	AuditStatus := this.GetString("Status")
+	if AuditStatus == "8" {
+		total = svc.GetQualPagingEntitiesStatus(OilSupplierFileName, OilQualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	} else {
+		total = svc.GetQualPagingEntities(OilSupplierFileName, OilQualChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	}
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total

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

@@ -1036,7 +1036,13 @@ func (this *OilSupplierCertAppendSubController) FileList() {
 	if SupplierTypeCode != "" {
 		where = where + " and a.SupplierTypeCode in ( '000', '" + SupplierTypeCode + "')"
 	}
-	total := svc.GetQualPagingEntities(OilSupplierFileName, OilAppendChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	var total int64
+	AuditStatus := this.GetString("Status")
+	if AuditStatus == "8" {
+		total = svc.GetQualPagingEntitiesStatus(OilSupplierFileName, OilAppendChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	} else {
+		total = svc.GetQualPagingEntities(OilSupplierFileName, OilAppendChangeDetailName, page.CurrentPage, page.Size, orderby, asc, &list, where, MInfoId)
+	}
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/addtionaudit/_opera/basisdataopera.vue

@@ -1985,6 +1985,7 @@
         const params = {
           SupplierId: this.formData.SupplierId,
           SupplierTypeCode: '02',
+          Status: this.formData.Status,
           MInfoId: this.AppendId
         }
         _this.$axios.get('suppliercertappendsub/filelist', {

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/addtionaudit/_opera/goodsdataopera.vue

@@ -2160,6 +2160,7 @@
         let _this = this
         const params = {
           SupplierId: this.formData.SupplierId,
+          Status: this.formData.Status,
           SupplierTypeCode: '01',
           MInfoId: this.AppendId
         }

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/addtionaudit/_opera/techdataopera.vue

@@ -1973,6 +1973,7 @@
         const params = {
           SupplierId: this.formData.SupplierId,
           SupplierTypeCode: '03',
+          Status: this.formData.Status,
           MInfoId: this.AppendId
         }
         _this.$axios.get('suppliercertappendsub/filelist', {

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/auditoperation.vue

@@ -2329,6 +2329,7 @@ export default {
         const params = {
           SupplierId: this.formData.Id,
           SupplierTypeCode: '01',
+          Status: this.AnnualStatus,
           MInfoId: this.annualId,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/basicauditoperation.vue

@@ -1511,6 +1511,7 @@
         const params = {
           SupplierId: this.formData.Id,
           SupplierTypeCode: '02',
+          Status: this.AnnualStatus,
           MInfoId: this.annualId,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/bassicoperation.vue

@@ -2303,6 +2303,7 @@ import Viewer from 'v-viewer'
         const params = {
           SupplierId: this.formData.Id,
           SupplierTypeCode: '02',
+          Status: this.Status,
           MInfoId: this.annualId,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/goodsoperation.vue

@@ -2649,6 +2649,7 @@
         const params = {
           SupplierId: this.formData.Id,
           SupplierTypeCode: '01',
+          Status: this.Status,
           MInfoId: this.annualId,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject

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

@@ -2249,6 +2249,7 @@ import Viewer from 'v-viewer'
           SupplierId: this.formData.Id,
           SupplierTypeCode: '03',
           MInfoId: this.annualId,
+          Status: this.Status,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject
         }

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/annualaudit/_opera/techoperation.vue

@@ -1506,6 +1506,7 @@
         const params = {
           SupplierId: this.formData.Id,
           SupplierTypeCode: '03',
+          Status: this.AnnualStatus,
           MInfoId: this.annualId,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject

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

@@ -2100,6 +2100,7 @@
           SupplierId: this.SuppId,
           SupplierTypeCode: '01',
           MInfoId: this.infoId,
+          Status: this.InfoStatus,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject
         }
@@ -2225,6 +2226,7 @@
           SupplierId: this.SuppId,
           SupplierTypeCode: '02',
           MInfoId: this.infoId,
+          Status: this.InfoStatus,
           _currentPage: 1,
           _size: 1000
         }
@@ -2265,6 +2267,7 @@
           SupplierId: this.SuppId,
           SupplierTypeCode: '03',
           MInfoId: this.infoId,
+          Status: this.InfoStatus,
           _currentPage: 1,
           _size: 1000
         }

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

@@ -2618,6 +2618,7 @@
           SupplierId: this.supplierId,
           SupplierTypeCode: '01',
           SupType: '2',
+          Status: this.InfoStatus,
           MInfoId: this.MInfoId,
           _currentPage: this.currentPageProject,
           _size: this.sizeProject
@@ -2663,6 +2664,7 @@
           SupplierId: this.supplierId,
           SupplierTypeCode: '02',
           SupType: '2',
+          Status: this.InfoStatus,
           MInfoId: this.MInfoId,
           _currentPage: this.currentPageProject2,
           _size: this.sizeProject2
@@ -2708,6 +2710,7 @@
           SupplierId: this.supplierId,
           SupplierTypeCode: '03',
           SupType: '2',
+          Status: this.InfoStatus,
           MInfoId: this.MInfoId,
           _currentPage: this.currentPageProject3,
           _size: this.sizeProject3

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/basisdataopera.vue

@@ -1927,6 +1927,7 @@
         const params = {
           SupplierId: this.formData.SupplierId + '',
           SupplierTypeCode: '02',
+          Status: this.currentStatus,
           MInfoId: this.Id + ''
         }
         _this.$axios.get('suppliercertappendsub/filelist', {

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/goodsdataopera.vue

@@ -2145,6 +2145,7 @@
         const params = {
           SupplierId: this.formData.SupplierId + '',
           SupplierTypeCode: '01',
+          Status: this.currentStatus,
           MInfoId: this.Id + ''
         }
         _this.$axios.get('suppliercertappendsub/filelist', {

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/oilsupplier/supplierappend/_opera/techdataopera.vue

@@ -1948,6 +1948,7 @@
         const params = {
           SupplierId: this.formData.SupplierId + '',
           SupplierTypeCode: '03',
+          Status: this.currentStatus,
           MInfoId: this.Id + ''
         }
         _this.$axios.get('suppliercertappendsub/filelist', {

+ 1 - 0
src/dashoo.cn/frontend_web/src/pages/select/processselect/index.vue

@@ -415,6 +415,7 @@
         this.$refs.wfMultiHistory.certId = val.Id
         this.$refs.wfMultiHistory.SupplierTypeCode = val.SupplierTypeCode
         this.$refs.wfMultiHistory.SupplierId = val.SupplierId
+        this.$refs.wfMultiHistory.Status = val.Status
         if (this.tabinx == '1' || val.Type == '1') { // 准入
           this.$refs.wfMultiHistory.dialogVisible1 = true
           this.$refs.wfMultiHistory.process = val.ProcessKey

+ 4 - 0
src/dashoo.cn/frontend_web/src/pages/select/processselect/wfmultihistory.vue

@@ -3499,6 +3499,7 @@
         const params = {
           InStyle: this.formDataCert.InStyle,
           SupplierId: this.SupplierId,
+          Status: this.Status,
           SupplierTypeCode: this.SupplierTypeCode,
           // SubClassIds: this.SubClassIds.join(),
           _currentPage: 1,
@@ -3840,6 +3841,7 @@
         const params = {
           SupplierId: this.SupplierId,
           SupplierTypeCode: '01',
+          Status: this.Status,
           MInfoId: this.business,
           SupType: this.dialogVisible3 ? '1' : '',
           _currentPage: 1,
@@ -3866,6 +3868,7 @@
         const params = {
           SupplierId: this.SupplierId,
           SupplierTypeCode: '02',
+          Status: this.Status,
           SupType: this.dialogVisible3 ? '1' : '',
           MInfoId: this.business,
           _currentPage: 1,
@@ -3892,6 +3895,7 @@
         const params = {
           SupplierId: this.SupplierId,
           SupplierTypeCode: '02',
+          Status: this.Status,
           SupType: this.dialogVisible3 ? '1' : '',
           MInfoId: this.business,
           _currentPage: 1,