|
@@ -56,6 +56,9 @@ func (t *Structed_data)GetData(){
|
|
|
|
|
|
listQuery := "select * " + sql + fmt.Sprintf(" order by submit_time asc limit %d,%d", (currentPage-1)*perPage, perPage)
|
|
|
res := util.Mysql.Query(listQuery, val...)
|
|
|
+ for k, v := range *res {
|
|
|
+ v["index"] = k + 1
|
|
|
+ }
|
|
|
t.ServeJson(map[string]interface{}{
|
|
|
"currentPage": currentPage,
|
|
|
"data": res,
|