|
@@ -30,7 +30,7 @@ func (this *MorningMeetingController) List() {
|
|
|
br.Ret = 408
|
|
|
return
|
|
|
}
|
|
|
- resp := new(models.GetCygxProductInteriorResp)
|
|
|
+ resp := new(models.CygxMorningMeetingGatherListResp)
|
|
|
pageSize, _ := this.GetInt("PageSize")
|
|
|
currentIndex, _ := this.GetInt("CurrentIndex")
|
|
|
|
|
@@ -44,25 +44,27 @@ func (this *MorningMeetingController) List() {
|
|
|
startSize = utils.StartIndex(currentIndex, pageSize)
|
|
|
var condition string
|
|
|
var pars []interface{}
|
|
|
- condition += ` AND art.status = 1 `
|
|
|
- total, err := models.GetCygxProductInteriorCount(condition, pars)
|
|
|
+ condition += ` AND status = 1 `
|
|
|
+ total, err := models.GetCygxMorningMeetingGatherCount(condition, pars)
|
|
|
if err != nil {
|
|
|
br.Msg = "获取失败"
|
|
|
br.ErrMsg = "获取失败,Err:" + err.Error()
|
|
|
return
|
|
|
}
|
|
|
- condition += " ORDER BY art.publish_time DESC , art.product_interior_id DESC "
|
|
|
- list, err := models.GetCygxProductInteriorList(condition, pars, startSize, pageSize)
|
|
|
+ condition += " ORDER BY publish_time DESC ,id DESC "
|
|
|
+ list, err := models.GetCygxMorningMeetingGatherList(condition, pars, startSize, pageSize)
|
|
|
if err != nil {
|
|
|
br.Msg = "获取失败"
|
|
|
br.ErrMsg = "获取失败,Err:" + err.Error()
|
|
|
return
|
|
|
}
|
|
|
+ page := paging.GetPaging(currentIndex, pageSize, total)
|
|
|
for _, v := range list {
|
|
|
- v.PublishTime = utils.TimeRemoveHms(v.PublishTime)
|
|
|
+ item := new(models.CygxMorningMeetingGatherResp)
|
|
|
+ item.Id = v.Id
|
|
|
+ item.Title = v.Title
|
|
|
+ resp.List = append(resp.List, item)
|
|
|
}
|
|
|
- page := paging.GetPaging(currentIndex, pageSize, total)
|
|
|
- resp.List = list
|
|
|
resp.Paging = page
|
|
|
br.Ret = 200
|
|
|
br.Success = true
|