diff --git a/internal/api/mobile/order/query.go b/internal/api/mobile/order/query.go index d05b525..f6295ec 100755 --- a/internal/api/mobile/order/query.go +++ b/internal/api/mobile/order/query.go @@ -33,6 +33,7 @@ type queryOrderListResponse struct { TotalGoodsCount uint `json:"totalGoodsCount"` GoodsList []order.GoodsDetail `json:"goodsList"` OrderType string `json:"orderType"` // 订单类型,线上订单(配送) or 门店订单(自提) + CanPay bool `json:"can_pay"` } var TypeMap = map[uint]string{ @@ -108,6 +109,7 @@ func QueryAllOrders(c *gin.Context) { TotalGoodsCount: totalGoodsCount, GoodsList: goodsList, OrderType: TypeMap[orderInfoList[i1].ShippingMethod], + CanPay: v1.CanPay, }) } back.Suc(c, "", list) @@ -417,6 +419,7 @@ type queryOrderDetailResponse struct { StatusList []goodsStatus `json:"status_list"` MakeUpText string `json:"make_up_text"` MakeUpAmount decimal.Decimal `json:"make_up_amount"` + CanPay bool `json:"can_pay"` } type goodsStatus struct { @@ -636,6 +639,7 @@ func QueryOrderDetail(c *gin.Context) { StatusList: statusList, MakeUpText: o.Reason, MakeUpAmount: o.Amount, + CanPay: temp.CanPay, }) } diff --git a/internal/v2/controller/app/jyy/jyy.go b/internal/v2/controller/app/jyy/jyy.go index b7930e5..bc8c5bd 100644 --- a/internal/v2/controller/app/jyy/jyy.go +++ b/internal/v2/controller/app/jyy/jyy.go @@ -181,6 +181,11 @@ func (o Proxy) CompanyApplyList(c *gin.Context) { }) } +func (o Proxy) CompanyAllAmount(c *gin.Context) { + id, _ := common.GetAppUserId(c) + back.Suc(c, "ok", jyy.Logic.CompanyAllAmount(id)) +} + func (o Proxy) CompanyApply(c *gin.Context) { var args company.Apply if err := tools.ParseParams(&args, c); err != nil { diff --git a/internal/v2/logic/app/jyy/jyy.go b/internal/v2/logic/app/jyy/jyy.go index c417655..24bb541 100644 --- a/internal/v2/logic/app/jyy/jyy.go +++ b/internal/v2/logic/app/jyy/jyy.go @@ -700,3 +700,10 @@ func (o logic) CompanyApply(args company.Apply) error { args.CompanyID = int(company.ID) return mysql.Db.Create(&args).Error } + +type Data struct { +} + +func (o logic) CompanyAllAmount(id uint) error { + return nil +} diff --git a/internal/v2/model/company/company.go b/internal/v2/model/company/company.go index 44a6da7..7eb947c 100644 --- a/internal/v2/model/company/company.go +++ b/internal/v2/model/company/company.go @@ -86,6 +86,7 @@ type Info struct { UserID uint `json:"-"` Password string `json:"password"` Tax decimal.Decimal `json:"tax"` + TaxBillType string `json:"tax_bill_type"` } func (o *Info) TableName() string { diff --git a/internal/v2/router/app.go b/internal/v2/router/app.go index c83c4c2..67df99f 100644 --- a/internal/v2/router/app.go +++ b/internal/v2/router/app.go @@ -297,10 +297,11 @@ func routerApp(appRouter *gin.RouterGroup) { { companyController.POST("info", proxy.CompanyInfo) companyController.POST("apply/list", proxy.CompanyApplyList) // 提现列表 - companyController.POST("apply", proxy.CompanyApply) // 提现 - companyController.POST("deposit", proxy.CompanyDespoit) // 充值 - companyController.POST("deposit/list", proxy.DespoitInfo) // 充值列表 - companyController.POST("record/list", proxy.RecordInfo) // 钱包记录 + companyController.POST("apply/all_amount", proxy.CompanyAllAmount) + companyController.POST("apply", proxy.CompanyApply) // 提现 + companyController.POST("deposit", proxy.CompanyDespoit) // 充值 + companyController.POST("deposit/list", proxy.DespoitInfo) // 充值列表 + companyController.POST("record/list", proxy.RecordInfo) // 钱包记录 companyController.POST("contact", proxy.ContactFix) } }