Explorar o código

后端: 集中评审导出字段顺序调整

baichengfei %!s(int64=4) %!d(string=hai) anos
pai
achega
bfe7ccd720
Modificáronse 1 ficheiros con 9 adicións e 10 borrados
  1. 9 10
      src/dashoo.cn/backend/api/controllers/oilsupplier/supplier.go

+ 9 - 10
src/dashoo.cn/backend/api/controllers/oilsupplier/supplier.go

@@ -11,9 +11,9 @@ import (
 	"dashoo.cn/backend/api/business/oilsupplier/tableheader"
 	"dashoo.cn/backend/api/business/register"
 	"dashoo.cn/business3/parameter"
-	. "github.com/linxGnu/goseaweedfs"
 	"encoding/json"
 	"fmt"
+	. "github.com/linxGnu/goseaweedfs"
 	"github.com/tealeg/xlsx"
 	"log"
 	"os"
@@ -927,7 +927,7 @@ func (this *OilSupplierController) JzpsListExport() {
 	svc.GetMyPagingEntitiesWithOrderBytblExport(OilSupplierName, OilSupplierCertName, &list, where)
 
 	fileTitle := "集中评审"
-	showColumnArr := "序号,审核状态,审核处室,推荐单位,准入类别,企业名称,法人,工商注册号,注册资本,币种,公司类型,成立时间,手机号,准入范围"
+	showColumnArr := "序号,审核状态,企业名称,准入类别,审核处室,推荐单位,法人,工商注册号,注册资本,币种,公司类型,成立时间,手机号,准入范围"
 
 	f := xlsx.NewFile()
 	sheet, _ := f.AddSheet(fileTitle)
@@ -937,9 +937,9 @@ func (this *OilSupplierController) JzpsListExport() {
 
 	for idx, item := range list {
 		var certSubList []suppliercertsub.OilSupplierCertSub
-		svc.GetEntitysByWhere(OilSupplierCertSubName, "SupplierCertId = " + strconv.Itoa(item.CertId), &certSubList)
+		svc.GetEntitysByWhere(OilSupplierCertSubName, "SupplierCertId = "+strconv.Itoa(item.CertId), &certSubList)
 		subName := ""
-		for _,certSub := range certSubList{
+		for _, certSub := range certSubList {
 			subName += "," + certSub.Name
 		}
 		regCapital := strconv.FormatFloat(item.RegCapital, 'f', 2, 64)
@@ -956,8 +956,8 @@ func (this *OilSupplierController) JzpsListExport() {
 		if item.Currency == "EUR" {
 			currency = "欧元"
 		}
-		dataString := strconv.Itoa(idx+1) + "+待集中评审+" + item.FullName + "+" + item.RecUnitName + "+" + item.SupplierTypeName + "+" + item.SupplierName + "+" + item.LegalPerson + "+" + item.CommercialNo + "+" +
-			regCapital  + "+" + currency  + "+" + item.CompanyType  + "+" + utils.ToStr(item.SetupTime.Format("2006-01-02")) + "+" + item.Mobile + "+" + strings.TrimLeft(subName, ",")
+		dataString := strconv.Itoa(idx+1) + "+待集中评审+" + item.SupplierName + "+" + item.SupplierTypeName + "+" + item.FullName + "+" + item.RecUnitName + "+" + item.LegalPerson + "+" + item.CommercialNo + "+" +
+			regCapital + "+" + currency + "+" + item.CompanyType + "+" + utils.ToStr(item.SetupTime.Format("2006-01-02")) + "+" + item.Mobile + "+" + strings.TrimLeft(subName, ",")
 		cellName := strings.Split(dataString, "+")
 		row := sheet.AddRow()
 		row.WriteSlice(&cellName, -1)
@@ -3401,7 +3401,7 @@ func (this *OilSupplierController) CheckSupplierFileList() {
 	filesvc := supplierfile.GetSupplierfileService(utils.DBE)
 	mergerCertSkipField := paramSvc.GetBaseparameterMessage("GFGL", "paramset", "MergerCertSkipFieldName")
 
-	for _,cert := range certList {
+	for _, cert := range certList {
 		if file.CertId != "0" && strconv.Itoa(cert.Id) != file.CertId {
 			continue
 		}
@@ -3524,11 +3524,10 @@ func (this *OilSupplierController) CheckSupplierFileList() {
 			}
 		}
 
-
 	}
 	var certSubList1 []suppliercertsub.OilSupplierCertSub
 	var total int64
-	where3 := "IsQuestion = 2 and SupplierId = "+strconv.Itoa(supplierEntity.Id)
+	where3 := "IsQuestion = 2 and SupplierId = " + strconv.Itoa(supplierEntity.Id)
 	if file.FileName != "" {
 		where3 += " and LackFile like '%" + file.FileName + "%'"
 	}
@@ -3536,7 +3535,7 @@ func (this *OilSupplierController) CheckSupplierFileList() {
 		where3 += " and Name like '%" + file.SubName + "%'"
 	}
 	if file.CertId != "0" {
-		where3 += " and SupplierCertId = "+file.CertId
+		where3 += " and SupplierCertId = " + file.CertId
 	}
 	total = certsubService.GetPagingEntitiesWithOrderBytbl("", file.CurrentPage, file.Size, "Id", true, &certSubList1, where3)