|
@@ -88,9 +88,9 @@ func success(eg *xorm.Engine, canalMsg *md.ZhiosGuideStoreOrder) error { |
|
|
defer sess.Close() |
|
|
defer sess.Close() |
|
|
sess.Begin() |
|
|
sess.Begin() |
|
|
var data model.GuideStoreOrder |
|
|
var data model.GuideStoreOrder |
|
|
get, _ := eg.Where("pvd_oid=?", canalMsg.Oid).Get(&data) |
|
|
|
|
|
|
|
|
get, _ := sess.Where("pvd_oid=?", canalMsg.Oid).Get(&data) |
|
|
var newOrd model.OrdList |
|
|
var newOrd model.OrdList |
|
|
eg.Where("pvd_oid=?", canalMsg.Oid).Get(&newOrd) |
|
|
|
|
|
|
|
|
sess.Where("pvd_oid=?", canalMsg.Oid).Get(&newOrd) |
|
|
if get == false { |
|
|
if get == false { |
|
|
deductPrice := canalMsg.DeductPrice |
|
|
deductPrice := canalMsg.DeductPrice |
|
|
var storeOrder = model.GuideStoreOrder{ |
|
|
var storeOrder = model.GuideStoreOrder{ |
|
@@ -124,6 +124,8 @@ func success(eg *xorm.Engine, canalMsg *md.ZhiosGuideStoreOrder) error { |
|
|
return err |
|
|
return err |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
newOrd.OrderFormType = -2 |
|
|
|
|
|
sess.Where("ord_id=?", newOrd.OrdId).Cols("order_form_type").Update(&newOrd) |
|
|
} |
|
|
} |
|
|
sess.Commit() |
|
|
sess.Commit() |
|
|
return nil |
|
|
return nil |
|
|