Parcourir la source

更新

master
huangjiajun il y a 5 mois
Parent
révision
e33f9223e8
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. +1
    -1
      app/admin/svc/order/svc_order_list.go

+ 1
- 1
app/admin/svc/order/svc_order_list.go Voir le fichier

@@ -531,7 +531,7 @@ func OrderGoodsTotal(c *gin.Context) {
}
where += " and o.enterprise_id in(" + php2go.Implode(",", oids) + ")"
}
sql := "select SUM(IF(state!=5,num*price,0)) as amount,SUM(IF(state!=5,num,0)) as alls,SUM(IF(state=0,num,0)) as wait_do,SUM(IF(state=1,num,0)) as dos,SUM(IF(state=2,num,0)) as baking,SUM(IF(state=3,num,0)) as sorting,SUM(IF(state=4,num,0)) as success,SUM(IF(state=5,num,0)) as cancel from `order_goods` left join `order` o on o.oid=og.oid where %s"
sql := "select SUM(IF(og.state!=5,og.num*og.price,0)) as amount,SUM(IF(og.state!=5,og.num,0)) as alls,SUM(IF(og.state=0,og.num,0)) as wait_do,SUM(IF(og.state=1,og.num,0)) as dos,SUM(IF(og.state=2,og.num,0)) as baking,SUM(IF(og.state=3,og.num,0)) as sorting,SUM(IF(og.state=4,og.num,0)) as success,SUM(IF(og.state=5,og.num,0)) as cancel from `order_goods` og left join `order` o on o.oid=og.oid where %s"
sql = fmt.Sprintf(sql, where)
nativeString, _ := db.QueryNativeString(eg, sql)
var res = make([]string, 0)


Chargement…
Annuler
Enregistrer