|
|
package service
|
|
|
|
|
|
import (
|
|
|
"github.com/linmadan/egglib-go/core/application"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/application/mobile/cooperation/command"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/application/mobile/cooperation/dto"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/constant"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/domain"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/infrastructure/service_gateway/allied_creation_cooperation"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/infrastructure/service_gateway/allied_creation_user"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/log"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/util/blur"
|
|
|
"strconv"
|
|
|
"strings"
|
|
|
|
|
|
"github.com/linmadan/egglib-go/core/application"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/application/mobile/cooperation/command"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/application/mobile/cooperation/dto"
|
|
|
"gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/infrastructure/service_gateway/allied_creation_cooperation"
|
|
|
)
|
|
|
|
|
|
// CooperationProjectService 共创项目服务
|
...
|
...
|
@@ -245,6 +244,7 @@ func (srv CooperationProjectService) PersonSearchCooperationProjectShareInfoAtta |
|
|
return nil, application.ThrowError(application.BUSINESS_ERROR, err.Error())
|
|
|
}
|
|
|
// 不是本人查看需要做模糊处理
|
|
|
if response.Attachment != nil {
|
|
|
if response.UserBaseId != projectQuery.Operator.UserBaseId {
|
|
|
file, err := blur.FileBlur(response.Attachment.Url, true)
|
|
|
if err != nil { // || len(file)==0
|
...
|
...
|
@@ -256,6 +256,8 @@ func (srv CooperationProjectService) PersonSearchCooperationProjectShareInfoAtta |
|
|
}
|
|
|
response.Attachment.Url = file
|
|
|
}
|
|
|
}
|
|
|
|
|
|
return map[string]interface{}{
|
|
|
"attachment": response.Attachment,
|
|
|
}, nil
|
...
|
...
|
|