Prechádzať zdrojové kódy

是否感兴趣默认值处理

WH01243 2 rokov pred
rodič
commit
c2dc54969e

+ 5 - 1
jyBXSubscribe/rpc/model/service/pushSet.go

@@ -83,7 +83,11 @@ func (this *PushSetService) Find() map[string]*bxsubscribe.PushSet {
 	}
 	if o_pushset != nil {
 		pushSet["interested"] = &bxsubscribe.PushSet{
-			Interested: common.Int64All(o_pushset["i_interested"]),
+			Interested: common.Int64All(common.If(o_pushset["i_interested"] == nil, 1, common.Int64All(o_pushset["i_interested"]))),
+		}
+	} else {
+		pushSet["interested"] = &bxsubscribe.PushSet{
+			Interested: 1,
 		}
 	}
 	fool, o_subset := pushSetMontage(o_pushset["o_subset"], "o_subset", powerData, ShowWx)