...
|
...
|
@@ -8,53 +8,20 @@ import ( |
|
|
)
|
|
|
|
|
|
type CooperationApplicationItem struct {
|
|
|
CooperationProject struct {
|
|
|
CooperationProjectID string `json:"cooperationProjectId"` //共创项目
|
|
|
CooperationProjectName string `json:"cooperationProjectName"` //共创名称
|
|
|
CooperationProjectNumber string `json:"cooperationProjectNumber"` //共创编号
|
|
|
} `json:"cooperationProject"`
|
|
|
CooperationApplicationApplicant struct {
|
|
|
UserId int
|
|
|
UserInfo struct {
|
|
|
UserAvatar string
|
|
|
UserEmail string
|
|
|
UserName string
|
|
|
UserPhone string
|
|
|
UserAccount string
|
|
|
}
|
|
|
} `json:"cooperationApplicationApplicant"`
|
|
|
CooperationApplicationAttachment []domain.Attachment `json:"cooperationApplicationAttachment"` //附件
|
|
|
CooperationApplicationDescription string `json:"cooperationApplicationDescription"` //描述
|
|
|
CooperationApplicationID string `json:"cooperationApplicationId"` //id
|
|
|
IsCanceled bool `json:"isCanceled"` //是否取消
|
|
|
CooperationApplicationVerifyDescription string `json:"cooperationApplicationVerifyDescription"` //审核描述
|
|
|
CooperationApplicationVerifyTime time.Time `json:"cooperationApplicationVerifyTime"` //审核时间
|
|
|
CooperationApplicationStatus int `json:"cooperationApplicationStatus"` //
|
|
|
Org struct {
|
|
|
OrgID string `json:"orgId"`
|
|
|
OrgName string `json:"orgName"`
|
|
|
} `json:"org"` //组织
|
|
|
allied_creation_cooperation.CooperationApplication
|
|
|
AuthFlag bool `json:"authFlag"`
|
|
|
}
|
|
|
|
|
|
func ToCooperationApplicationItem(param *allied_creation_cooperation.CooperationApplication) *CooperationApplicationItem {
|
|
|
//data := CooperationApplicationItem{
|
|
|
// CooperationApplicationAttachment: param.CooperationApplicationAttachment,
|
|
|
// CooperationApplicationDescription: param.CooperationApplicationDescription,
|
|
|
// CooperationApplicationID: param.CooperationApplicationID,
|
|
|
// IsCanceled: param.IsCanceled,
|
|
|
// CooperationApplicationVerifyDescription: param.CooperationApplicationVerifyDescription,
|
|
|
// CooperationApplicationStatus: param.CooperationApplicationStatus,
|
|
|
// Org: param.Org,
|
|
|
//}
|
|
|
//data.CooperationApplicationApplicant.UserName = param.CooperationApplicationApplicant.UserInfo.UserName
|
|
|
//data.CooperationApplicationApplicant.Phone = param.CooperationApplicationApplicant.UserInfo.UserPhone
|
|
|
//data.CooperationApplicationApplicant.UserCode = param.CooperationApplicationApplicant.UserInfo.UserPhone
|
|
|
//data.CooperationApplicationApplicant.DepartmentName = param.CooperationApplicationApplicant.Department.DepartmentName
|
|
|
//data.CooperationProject.CooperationProjectID = param.CooperationProject.CooperationProjectID
|
|
|
//data.CooperationProject.CooperationProjectName = param.CooperationProject.CooperationProjectName
|
|
|
//data.CooperationProject.CooperationProjectNumber = param.CooperationProject.CooperationProjectNumber
|
|
|
//return &data
|
|
|
return nil
|
|
|
func ToCooperationApplicationItem(param []allied_creation_cooperation.CooperationApplication, operatorOrgId int64) []CooperationApplicationItem {
|
|
|
listData := []CooperationApplicationItem{}
|
|
|
for i := range param {
|
|
|
item := CooperationApplicationItem{
|
|
|
CooperationApplication: param[i],
|
|
|
AuthFlag: param[i].Org.OrgID == int(operatorOrgId),
|
|
|
}
|
|
|
listData = append(listData, item)
|
|
|
}
|
|
|
return listData
|
|
|
}
|
|
|
|
|
|
type CooperationApplicationInfo struct {
|
...
|
...
|
|