...
|
...
|
@@ -127,10 +127,28 @@ func newCompany(company *domain.Company, p *domain.PartnerStatics) userx.Company |
|
|
Name: company.Name,
|
|
|
Phone: company.Phone,
|
|
|
//SerialNo: p.Id,
|
|
|
CooperateTime: p.CooperateTime.Unix() * 1000,
|
|
|
MiniProgram: nil,
|
|
|
District: map[string]interface{}{"id": p.RegionInfo.RegionId, "name": p.RegionInfo.RegionName},
|
|
|
CareerSerialNo: "",
|
|
|
BusinessSerialNo: "",
|
|
|
DevelopSerialNo: "",
|
|
|
AppSerialNo: "",
|
|
|
CooperateTime: p.CooperateTime.Unix() * 1000,
|
|
|
MiniProgram: nil,
|
|
|
District: map[string]interface{}{"id": p.RegionInfo.RegionId, "name": p.RegionInfo.RegionName},
|
|
|
}
|
|
|
|
|
|
//获取合伙人编号
|
|
|
for _, partnerCategoryInfo := range p.PartnerCategoryInfos {
|
|
|
if partnerCategoryInfo.Id == 1 {
|
|
|
partnerCompany.CareerSerialNo = partnerCategoryInfo.Code
|
|
|
} else if partnerCategoryInfo.Id == 2 {
|
|
|
partnerCompany.BusinessSerialNo = partnerCategoryInfo.Code
|
|
|
} else if partnerCategoryInfo.Id == 3 {
|
|
|
partnerCompany.DevelopSerialNo = partnerCategoryInfo.Code
|
|
|
} else if partnerCategoryInfo.Id == 4 {
|
|
|
partnerCompany.AppSerialNo = partnerCategoryInfo.Code
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if len(p.Salesman) > 0 {
|
|
|
partnerCompany.Salesman = map[string]interface{}{"uname": p.Salesman[0].Name, "phone": p.Salesman[0].Telephone}
|
|
|
} else {
|
...
|
...
|
|