|
@@ -341,6 +341,14 @@ func (repository *CooperationProjectRepository) Find(queryOptions map[string]int |
|
@@ -341,6 +341,14 @@ func (repository *CooperationProjectRepository) Find(queryOptions map[string]int |
341
|
} else {
|
341
|
} else {
|
342
|
if count > 0 {
|
342
|
if count > 0 {
|
343
|
for _, cooperationProjectModel := range cooperationProjectModels {
|
343
|
for _, cooperationProjectModel := range cooperationProjectModels {
|
|
|
344
|
+ if v, ok := queryOptions["isSkipFetchProjectModel"]; ok && v.(bool) {
|
|
|
345
|
+ if cooperationProject, err := transform.TransformToCooperationProjectDomainModelFromPgModels(cooperationProjectModel, &models.CooperationMode{}); err != nil {
|
|
|
346
|
+ return 0, cooperationProjects, err
|
|
|
347
|
+ } else {
|
|
|
348
|
+ cooperationProjects = append(cooperationProjects, cooperationProject)
|
|
|
349
|
+ }
|
|
|
350
|
+ continue
|
|
|
351
|
+ }
|
344
|
// 获取共创模式
|
352
|
// 获取共创模式
|
345
|
var cooperationModeModels []*models.CooperationMode
|
353
|
var cooperationModeModels []*models.CooperationMode
|
346
|
cooperationModeQuery := tx.Model(&cooperationModeModels)
|
354
|
cooperationModeQuery := tx.Model(&cooperationModeModels)
|