|
@@ -63,7 +63,7 @@ FROM
|
63
|
63
|
if flashBuyStatus != "" {
|
64
|
64
|
sql += ` and a.flash_buy_status ='` + flashBuyStatus + `'`
|
65
|
65
|
}
|
66
|
|
- sql += ` order by a.create_date desc limit ` + strconv.Itoa(page-1) + `, ` + strconv.Itoa(pageSize)
|
|
66
|
+ sql += ` order by a.create_date desc limit ` + strconv.Itoa((page-1)*pageSize) + `, ` + strconv.Itoa(pageSize)
|
67
|
67
|
err := m.db.Sql(sql).Find(&flashBuy)
|
68
|
68
|
return flashBuy, err
|
69
|
69
|
}
|
|
@@ -171,7 +171,7 @@ WHERE
|
171
|
171
|
if phone != "" {
|
172
|
172
|
sql += ` and b.phone like '%` + phone + `%'`
|
173
|
173
|
}
|
174
|
|
- sql += ` order by a.create_date desc limit ` + strconv.Itoa(page-1) + `, ` + strconv.Itoa(pageSize)
|
|
174
|
+ sql += ` order by a.create_date desc limit ` + strconv.Itoa((page-1)*pageSize) + `, ` + strconv.Itoa(pageSize)
|
175
|
175
|
err := m.db.Sql(sql).Find(&customerFlashBuy)
|
176
|
176
|
return customerFlashBuy, err
|
177
|
177
|
|
|
@@ -227,7 +227,7 @@ func (m *FlashbuyDAO) GetCustomerFlashBuyByCustomerId(customerId string, page, p
|
227
|
227
|
inner join ta_flash_buy b
|
228
|
228
|
on a.flash_buy_id = b.flash_buy_id
|
229
|
229
|
where a.customer_id = '` + customerId + `'`
|
230
|
|
- sql += ` order by a.validate_start desc limit ` + strconv.Itoa(page-1) + `, ` + strconv.Itoa(pageSize)
|
|
230
|
+ sql += ` order by a.validate_start desc limit ` + strconv.Itoa((page-1)*pageSize) + `, ` + strconv.Itoa(pageSize)
|
231
|
231
|
err := m.db.Sql(sql).Find(&customerResult)
|
232
|
232
|
return customerResult, err
|
233
|
233
|
|