|
@@ -6,7 +6,6 @@ import (
|
|
|
"hongze/hz_crm_api/models/roadshow"
|
|
|
"hongze/hz_crm_api/services"
|
|
|
"hongze/hz_crm_api/utils"
|
|
|
- "strings"
|
|
|
)
|
|
|
|
|
|
|
|
@@ -61,6 +60,7 @@ func (this *CalendarController) CompanySearch() {
|
|
|
|
|
|
|
|
|
|
|
|
+
|
|
|
|
|
|
|
|
|
func (this *CalendarController) CompanyDetail() {
|
|
@@ -86,6 +86,7 @@ func (this *CalendarController) CompanyDetail() {
|
|
|
}
|
|
|
englishCompany, _ := this.GetInt("EnglishCompany")
|
|
|
companyType := this.GetString("CompanyType")
|
|
|
+ rsReportRecordId, _ := this.GetInt("RsReportRecordId")
|
|
|
productId := services.GetProductId(sysUser.RoleTypeCode)
|
|
|
if productId == 0 {
|
|
|
productId = 1
|
|
@@ -95,6 +96,14 @@ func (this *CalendarController) CompanyDetail() {
|
|
|
}
|
|
|
detailView := new(roadshow.CompanyDetailView)
|
|
|
if englishCompany == 0 {
|
|
|
+
|
|
|
+ rsReportRecordItem, err := roadshow.GetRsReportRecordDetailByRsReportRecordId(rsReportRecordId)
|
|
|
+ if err != nil {
|
|
|
+ br.Msg = "路演信息不存在!"
|
|
|
+ br.ErrMsg = "路演信息不存在!Err:" + err.Error()
|
|
|
+ return
|
|
|
+ }
|
|
|
+
|
|
|
companyProductItem, err := company.GetCompanyProductByCompanyIdAndProductId(companyId, productId)
|
|
|
if err != nil {
|
|
|
if err.Error() == utils.ErrNoRow() {
|
|
@@ -117,10 +126,11 @@ func (this *CalendarController) CompanyDetail() {
|
|
|
}
|
|
|
detailView.CompanyId = companyProductItem.CompanyId
|
|
|
detailView.CompanyName = companyProductItem.CompanyName
|
|
|
- detailView.Status = companyProductItem.Status
|
|
|
+ detailView.Status = rsReportRecordItem.CompanyStatus
|
|
|
detailView.IndustryId = companyProductItem.IndustryId
|
|
|
detailView.IndustryName = companyProductItem.IndustryName
|
|
|
- detailView.PermissionName = strings.Join(permissionArr, "/")
|
|
|
+
|
|
|
+ detailView.PermissionName = rsReportRecordItem.PermissionName
|
|
|
detailView.ReportReadTotal = companyProductItem.ViewTotal
|
|
|
br.Ret = 200
|
|
|
br.Success = true
|