Эх сурвалжийг харах

Merge branch 'feature/needs_business_contract' into debug

hsun 1 жил өмнө
parent
commit
0af50dd39c

+ 2 - 1
models/eta_business/eta_business.go

@@ -13,6 +13,7 @@ const (
 	EtaBusinessSigningStatusFirst = iota + 1
 	EtaBusinessSigningStatusContinue
 	EtaBusinessSigningStatusTerminate
+	EtaBusinessSigningStatusWait
 )
 
 type EtaBusiness struct {
@@ -32,7 +33,7 @@ type EtaBusiness struct {
 	CapitalScale     string    `description:"资金规模"`
 	ResearchTeamSize string    `description:"研究团队规模"`
 	UserMax          int       `description:"用户上限"`
-	SigningStatus    int       `description:"签约状态:1-首次签约;2-续约中;3-已终止"`
+	SigningStatus    int       `description:"签约状态:1-首次签约;2-续约中;3-已终止;4-待签约"`
 	Enable           int       `description:"状态:0-禁用;1-启用"`
 	ContractId       int       `description:"当前合约ID"`
 	SigningTime      time.Time `description:"当前合约的签约时间"`

+ 6 - 6
services/eta_business.go

@@ -205,13 +205,13 @@ func EtaBusinessUpdateStatus(cont context.Context) (err error) {
 	today, _ := time.ParseInLocation(utils.FormatDate, strToday, time.Local)
 	for _, b := range businesses {
 		cs := businessContracts[b.EtaBusinessId]
-		// 无签约-正常来讲不会出现这种情况
+		// 待签约
 		if cs == nil || (cs != nil && len(cs) == 0) {
-			if b.SigningStatus != eta_business.EtaBusinessSigningStatusTerminate {
-				b.SigningStatus = eta_business.EtaBusinessSigningStatusTerminate
-				b.ModifyTime = time.Now().Local()
-				updateBusiness = append(updateBusiness, b)
-			}
+			//if b.SigningStatus != eta_business.EtaBusinessSigningStatusTerminate {
+			//	b.SigningStatus = eta_business.EtaBusinessSigningStatusTerminate
+			//	b.ModifyTime = time.Now().Local()
+			//	updateBusiness = append(updateBusiness, b)
+			//}
 			continue
 		}