作者 tangxuhui

数据结构调整

  1 +package query
  2 +
  3 +import "gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/domain"
  4 +
  5 +type ListContractChangeLogQuery struct {
  6 + //操作人
  7 + Operator domain.Operator `json:"-"`
  8 + PageNumber int ` json:"pageNumber,omitempty"` // 页码
  9 + PageSize int `json:"pageSize,omitempty"` // 页面大小
  10 +}
  1 +package service
  2 +
  3 +import (
  4 + "gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway/pkg/application/web/contractChangeLog/query"
  5 +)
  6 +
  7 +type ContractChangeLogService struct{}
  8 +
  9 +func (srv ContractChangeLogService) ContractChangeLogSearch(queryParam *query.ListContractChangeLogQuery) (interface{}, error) {
  10 + //creationCooperationGateway := allied_creation_cooperation.NewHttplibAlliedCreationCooperation(queryParam.Operator)
  11 + // _, err := creationCooperationGateway.CooperationContractsSearchByUndertaker(
  12 + // allied_creation_cooperation.ContractChangeLogsSearch{})
  13 + return nil, nil
  14 +}
@@ -9,25 +9,29 @@ import ( @@ -9,25 +9,29 @@ import (
9 9
10 type CooperationApplicationItem struct { 10 type CooperationApplicationItem struct {
11 CooperationProject struct { 11 CooperationProject struct {
12 - CooperationProjectID int `json:"cooperationProjectId"` //共创项目 12 + CooperationProjectID string `json:"cooperationProjectId"` //共创项目
13 CooperationProjectName string `json:"cooperationProjectName"` //共创名称 13 CooperationProjectName string `json:"cooperationProjectName"` //共创名称
14 CooperationProjectNumber string `json:"cooperationProjectNumber"` //共创编号 14 CooperationProjectNumber string `json:"cooperationProjectNumber"` //共创编号
15 } `json:"cooperationProject"` 15 } `json:"cooperationProject"`
16 CooperationApplicationApplicant struct { 16 CooperationApplicationApplicant struct {
17 - UserName string `json:"usersName"` //申请人名字  
18 - UserCode string `json:"usersCode"`  
19 - DepartmentName string `json:"departmentName"` //申请人部门  
20 - Phone string `json:"Phone"` //申请人电话 17 + UserId int
  18 + UserInfo struct {
  19 + UserAvatar string
  20 + UserEmail string
  21 + UserName string
  22 + UserPhone string
  23 + UserAccount string
  24 + }
21 } `json:"cooperationApplicationApplicant"` 25 } `json:"cooperationApplicationApplicant"`
22 CooperationApplicationAttachment []domain.Attachment `json:"cooperationApplicationAttachment"` //附件 26 CooperationApplicationAttachment []domain.Attachment `json:"cooperationApplicationAttachment"` //附件
23 CooperationApplicationDescription string `json:"cooperationApplicationDescription"` //描述 27 CooperationApplicationDescription string `json:"cooperationApplicationDescription"` //描述
24 - CooperationApplicationID int `json:"cooperationApplicationId"` //id 28 + CooperationApplicationID string `json:"cooperationApplicationId"` //id
25 IsCanceled bool `json:"isCanceled"` //是否取消 29 IsCanceled bool `json:"isCanceled"` //是否取消
26 CooperationApplicationVerifyDescription string `json:"cooperationApplicationVerifyDescription"` //审核描述 30 CooperationApplicationVerifyDescription string `json:"cooperationApplicationVerifyDescription"` //审核描述
27 CooperationApplicationVerifyTime time.Time `json:"cooperationApplicationVerifyTime"` //审核时间 31 CooperationApplicationVerifyTime time.Time `json:"cooperationApplicationVerifyTime"` //审核时间
28 CooperationApplicationStatus int `json:"cooperationApplicationStatus"` // 32 CooperationApplicationStatus int `json:"cooperationApplicationStatus"` //
29 Org struct { 33 Org struct {
30 - OrgID int `json:"orgId"` 34 + OrgID string `json:"orgId"`
31 OrgName string `json:"orgName"` 35 OrgName string `json:"orgName"`
32 } `json:"org"` //组织 36 } `json:"org"` //组织
33 } 37 }
@@ -53,7 +53,7 @@ func (cooperationContractService *CooperationContractService) CreateCooperationC @@ -53,7 +53,7 @@ func (cooperationContractService *CooperationContractService) CreateCooperationC
53 UserId: v.UserId, 53 UserId: v.UserId,
54 ReferrerId: v.RerferrerId, 54 ReferrerId: v.RerferrerId,
55 SalesmanId: v.SalesmanId, 55 SalesmanId: v.SalesmanId,
56 - Attachment: v.Attachment, 56 + ContractAttachment: v.Attachment,
57 } 57 }
58 underTakers = append(underTakers, u) 58 underTakers = append(underTakers, u)
59 } 59 }
@@ -176,7 +176,7 @@ func (cooperationContractService *CooperationContractService) UpdateCooperationC @@ -176,7 +176,7 @@ func (cooperationContractService *CooperationContractService) UpdateCooperationC
176 UserId: v.UserId, 176 UserId: v.UserId,
177 ReferrerId: v.RerferrerId, 177 ReferrerId: v.RerferrerId,
178 SalesmanId: v.SalesmanId, 178 SalesmanId: v.SalesmanId,
179 - Attachment: v.Attachment, 179 + ContractAttachment: v.Attachment,
180 } 180 }
181 underTakers = append(underTakers, u) 181 underTakers = append(underTakers, u)
182 } 182 }
@@ -155,7 +155,7 @@ type ( @@ -155,7 +155,7 @@ type (
155 UserId int `json:"userId,string"` //承接人用户id 155 UserId int `json:"userId,string"` //承接人用户id
156 ReferrerId int `json:"referrerId,string"` //推荐人用户id 156 ReferrerId int `json:"referrerId,string"` //推荐人用户id
157 SalesmanId int `json:"salesmanId,string"` //关联业务员id 157 SalesmanId int `json:"salesmanId,string"` //关联业务员id
158 - Attachment []domain.Attachment `json:"attachment"` 158 + ContractAttachment []domain.Attachment `json:"contractAttachment"`
159 } 159 }
160 160
161 ReqCooperationContractAdd struct { 161 ReqCooperationContractAdd struct {
  1 +package allied_creation_cooperation
  2 +
  3 +import "time"
  4 +
  5 +//共创合约变更记录搜索
  6 +type (
  7 + ReqContractChangeLogsSearch struct {
  8 + PageNumber int ` json:"pageNumber,omitempty"` // 页码
  9 + PageSize int `json:"pageSize,omitempty"` // 页面大小
  10 + CompanyId int `json:"companyId"` //公司ID
  11 + OrgId int64 `json:"orgId"` // 组织机构ID
  12 + OrgIds []int64 `json:"orgIds"` // 关联的组织机构ID列表
  13 + UserId int64 ` json:"userId"` // 用户ID,
  14 + UserBaseId int64 `json:"userBaseId"` // 用户基础数据id
  15 + }
  16 +
  17 + DataContractChangeLogsSearch struct {
  18 + Grid struct {
  19 + Total int
  20 + List []struct {
  21 + CooperationContractChangeLogId int64 `json:"cooperationContractChangeLogId,string"` // 共创合约变更日志
  22 + IncentivesRule string `json:"incentivesRule"` // 激励规则
  23 + IncentivesRuleDetail string `json:"incentivesRuleDetail"` // 激励规则明细
  24 + OperationType int32 `json:"operationType"` // 合约变更操作类型,1编辑、2暂停、3恢复
  25 + CooperationContractNumber string `json:"cooperationContractNumber"` // 共创合约编号
  26 + Undertakers string `json:"undertakers"` // 承接人
  27 + Company struct {
  28 + CompanyId int64 `json:"companyId,string"` // 公司ID,通过集成REST上下文获取
  29 + CompanyLogo string `json:"companyLogo"` // 公司logo
  30 + CompanyName string `json:"companyName"` // 公司名称
  31 + } `json:"company"` // 公司
  32 + Org struct {
  33 + OrgId int64 `json:"orgId,string"` // 组织机构ID
  34 + OrgName string `json:"orgName"` // 组织名称
  35 + } `json:"org"` // 组织机构
  36 + Operator struct {
  37 + UserId int64 `json:"userId,string"` // 用户ID,
  38 + UserBaseId int64 `json:"userBaseId,string"` // 用户基本id
  39 + UserName string `json:"userName"` // 用户姓名
  40 + UserPhone string `json:"userPhone"` // 用户手机号
  41 + } `json:"operator"` // 操作人
  42 + OperatorTime time.Time `json:"operatorTime"` // 操作时间
  43 + UpdatedAt time.Time `json:"updatedAt"` // 更新时间
  44 + CreatedAt time.Time `json:"createdAt"` // 创建时间
  45 + }
  46 + }
  47 + }
  48 +)