You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

2 lines
10 KiB

  1. (self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[2369],{26177:function(b,T,e){"use strict";var f=e(71194),c=e(50146),r=e(98858),x=e(4914),H=e(34792),_=e(48086),E=e(39428),L=e(3182),R=e(2824),Z=e(67294),k=e(16894),W=e(12826),y=e(46389),m=e(85893),l={},F=function(I){var M,u,D=I.createModalVisible,A=I.onCancel,h=(0,Z.useState)([]),g=(0,R.Z)(h,2),U=g[0],B=g[1];return(0,m.jsxs)(c.Z,{title:"\u8BA2\u5355\u8BE6\u60C5",width:1e3,visible:I.createModalVisible,bodyStyle:{padding:"32px 40px 48px"},footer:null,destroyOnClose:!0,onCancel:function(){return A()},maskClosable:!1,children:[(0,m.jsx)(W.ZP,{request:(0,L.Z)((0,E.Z)().mark(function o(){return(0,E.Z)().wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,y.Z.GetOrderDetails({id:I.values.id});case 2:return l=s.sent,B(l),s.abrupt("return",Promise.resolve({success:!0,data:l}));case 5:case"end":return s.stop()}},o)})),columns:[{title:"\u4F1A\u5458\u59D3\u540D",key:"customer_Name",dataIndex:"customer_Name"},{title:"\u624B\u673A\u53F7",key:"customer_Tel",dataIndex:"customer_Tel"},{title:"\u8BA2\u5355\u6D41\u6C34",key:"order_Number",dataIndex:"order_Number"},{title:"\u8BA2\u5355\u53F7",key:"transaction_ID",dataIndex:"transaction_ID"},{title:"\u4EA4\u6613\u5355\u53F7",key:"trade_no",dataIndex:"trade_no"},{title:"\u6392\u961F\u53F7",key:"order_SortID",dataIndex:"order_SortID"},{title:"\u6298\u6263",key:"discount",dataIndex:"discount"},{title:"\u5B9E\u4ED8\u91D1\u989D",dataIndex:"order_RealMoney",valueType:"money",fieldProps:{moneySymbol:"\xA5"}},{title:"\u5E94\u4ED8\u91D1\u989D",dataIndex:"order_OriginalMoney",valueType:"money",fieldProps:{moneySymbol:"\xA5"}},{title:"\u5B9E\u4ED8\u91D1\u989D(\u9000)",dataIndex:"refundRealMoney",valueType:"money",fieldProps:{moneySymbol:"\xA5"}},{title:"\u5E94\u4ED8\u91D1\u989D(\u9000)",dataIndex:"refundOriginalMoney",valueType:"money",fieldProps:{moneySymbol:"\xA5"}},{title:"\u6570\u91CF",dataIndex:"order_Count",hideInSearch:!0},{title:"\u652F\u4ED8\u65B9\u5F0F",dataIndex:"payMode",key:"payMode"},{title:"\u8BA2\u5355\u72B6\u6001",dataIndex:"order_Status",key:"order_Status"}]}),(0,m.jsx)(k.ZP,{rowKey:"id",request:(0,L.Z)((0,E.Z)().mark(function o(){return(0,E.Z)().wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,y.Z.GetOrderDetails({id:I.values.id});case 2:return l=s.sent,s.abrupt("return",{data:l.detailList,success:!0});case 4:case"end":return s.stop()}},o)})),columns:[{title:"\u5546\u54C1\u5206\u7C7B",key:"goodsTypeName",dataIndex:"goodsTypeName"},{title:"\u5546\u54C1\u540D\u79F0",key:"goodsName",dataIndex:"goodsName"},{title:"\u5E94\u4ED8\u91D1\u989D",key:"originalMoney",dataIndex:"originalMoney",valueType:"money",fieldProps:{moneySymbol:"\xA5"}},{title:"\u5B9E\u4ED8\u91D1\u989D",dataIndex:"realMoney",valueType:"money",fieldProps:{moneySymbol:"\xA5"}},{title:"\u64CD\u4F5C",dataIndex:"option",valueType:"option",render:function(n,s){return[(0,m.jsx)("a",{onClick:function(){y.Z.printsmallticket({orderId:I.values.id,subOrderId:s.id}).then(function(S){debugger;S.data?_.default.success("\u6253\u5370\u6210\u529F"):_.default.error("\u6253\u5370\u5931\u8D25")})},children:"\u6253\u5370\u5C0F\u7968"},"config")]}}],toolBarRender:!1,search:!1}),(0,m.jsx)(x.Z,{title:"\u4F18\u60E0\u5238",children:(M=l)===null||M===void 0||(u=M.paperCoupons)===null||u===void 0?void 0:u.map(function(o){return(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(x.Z.Item,{label:"\u5E73\u53F0",children:o.platformName}),(0,m.jsx)(x.Z.Item,{label:"\u4F18\u60E0\u5238",children:o.name}),(0,m.jsx)(x.Z.Item,{label:"\u4F18\u60E0\u91D1\u989D",children:o.amount})]})})})]})};T.Z=F},46389:function(b,T,e){"use strict";var f=e(48971);T.Z={orderList:function(r){return r.isreport=!0,(0,f.WY)("/kitchen/api/order/order-detail-flow",{method:"Post",data:r})},srdTypeList:function(r){return(0,f.WY)("/kitchen/api/storetype/list",{method:"Post",data:r})},srdList:function(r){return(0,f.WY)("/kitchen/api/store/list",{method:"Post",data:r})},goodsList:function(r){return(0,f.WY)("/kitchen/api/goodes/list",{method:"Post",data:r})},goodsTypeList:function(r){return(0,f.WY)("/kitchen/api/goodstype/list",{method:"Post",data:r})},StartRefund:function(r){return(0,f.WY)("/kitchen/api/refund/StartOrderRefund",{method:"Post",params:r})},GetOrderDetails:function(r){return(0,f.WY)("/kitchen/api/Order/GetOrderDetails",{method:"Post",params:r})},GetFlowExport:function(r){return(0,f.WY)("/kitchen/api/Order/GetFlowExport",{method:"Post",data:r})},printsmallticket:function(r){return(0,f.WY)("/kitchen/api/printer/print-small-ticket",{method:"Post",data:r})}}},65585:function(b,T,e){"use strict";e.r(T),e.d(T,{default:function(){return B}});var f=e(57663),c=e(71577),r=e(39428),x=e(3182),H=e(34792),_=e(48086),E=e(11849),L=e(47673),R=e(4107),Z=e(93224),k=e(43358),W=e(34041),y=e(2824),m=e(90631),l=e(67294),F=e(78009),K=e(16894),I=e(53667),M=e.n(I),u=e(48971),D={orderList:function(n){return n.isreport=!0,(0,u.WY)("/kitchen/api/order/order-detail-flow",{method:"Post",data:n})},srdTypeList:function(n){return(0,u.WY)("/kitchen/api/storetype/list",{method:"Post",data:n})},srdList:function(n){return(0,u.WY)("/kitchen/api/store/list",{method:"Post",data:n})},goodsList:function(n){return(0,u.WY)("/kitchen/api/goodes/list",{method:"Post",data:n})},goodsTypeList:function(n){return(0,u.WY)("/kitchen/api/goodstype/list",{method:"Post",data:n})},StartRefund:function(n){return(0,u.WY)("/kitchen/api/refund/StartOrderRefund",{method:"Post",params:n})},GetOrderDetails:function(n){return(0,u.WY)("/kitchen/api/Order/GetOrderDetails",{method:"Post",params:n})},GetFlowExport:function(n){return(0,u.WY)("/kitchen/api/Order/GetFlowExport",{method:"Post",data:n})},printsmallticket:function(n){return(0,u.WY)("/kitchen/api/printer/print-small-ticket",{method:"Post",data:n})}},A=e(26177),h=e(85893),g=["defaultRender"],U=function(){var n=(0,l.useState)(),s=(0,y.Z)(n,2),j=s[0],S=s[1],z=(0,l.useState)(!1),G=(0,y.Z)(z,2),J=G[0],Y=G[1],Q=(0,l.useState)([]),N=(0,y.Z)(Q,2),X=N[0],q=N[1],ee=(0,l.useState)([]),w=(0,y.Z)(ee,2),se=w[0],te=w[1],re=(0,l.useRef)(),ae=(0,l.useState)([]),V=(0,y.Z)(ae,2),$=V[0],ne=V[1];(0,l.useEffect)(function(){function i(){D.srdList().then(function(a){var t=a.data;t==null||t.forEach(function(d){d.value=d.id,d.label=d.name}),q(t)})}i()},[]);function ie(){D.GetFlowExport($).then(function(i){var a=URL.createObjectURL(new Blob([i])),t="\u8BA2\u5355\u6D41\u6C34.xlsx",d=document.createElement("a");d.href=a,d.download=t,d.click(),URL.revokeObjectURL(a)})}var oe=[{title:"\u4E3B\u952E",dataIndex:"id",tip:"\u89C4\u5219\u540D\u79F0\u662F\u552F\u4E00\u7684 key",hideInSearch:!0,hideInTable:!0},{title:"\u8BA2\u5355\u65F6\u95F4",dataIndex:"order_CreateTime",valueType:"dateRange",hideInTable:!0,search:{transform:function(a){return{order_CreateTime:a[0],order_EndTime:a[1]}}}},{title:"\u624B\u673A\u53F7",dataIndex:"Customer_Tel",hideInTable:!0},{title:"\u5E97\u94FA\u540D\u79F0",dataIndex:"storeId",hideInTable:!0,valueType:"select",renderFormItem:function(){return(0,h.jsx)(W.Z,{mode:"multiple",showArrow:!0,optionFilterProp:"label",placeholder:"\u8BF7\u9009\u62E9\u5E97\u94FA",style:{width:"100%"},options:X})}},{title:"\u4EA4\u6613\u5355\u53F7",dataIndex:"order_Number",hideInSearch:!0},{title:"\u5E97\u94FA\u540D\u79F0",dataIndex:"storeName",hideInSearch:!0},{title:"\u5E94\u4ED8\u91D1\u989D",dataIndex:"order_OriginalMoney",renderText:function(a){return"".concat(a,"\xA5")},hideInSearch:!0},{title:"\u5B9E\u4ED8\u91D1\u989D",dataIndex:"order_RealMoney",hideInSearch:!0,renderText:function(a){return"".concat(a,"\xA5")}},{title:"\u5E94\u4ED8\u91D1\u989D(\u9000)",dataIndex:"refundOriginalMoney",renderText:function(a){return"".concat(a,"\xA5")},hideInSearch:!0},{title:"\u5B9E\u4ED8\u91D1\u989D(\u9000)",dataIndex:"refundRealMoney",hideInSearch:!0,renderText:function(a){return"".concat(a,"\xA5")}},{title:"\u6570\u91CF",dataIndex:"order_Count",hideInSearch:!0},{title:"\u521B\u5EFA\u65F6\u95F4",sorter:!0,dataIndex:"order_CreateTime",valueType:"dateTime",hideInSearch:!0,renderFormItem:function(a,t,d){var P=t.defaultRender,p=(0,Z.Z)(t,g),O=d.getFieldValue("status");return"".concat(O)==="0"?!1:"".concat(O)==="3"?(0,h.jsx)(R.Z,(0,E.Z)((0,E.Z)({},p),{},{placeholder:"\u8BF7\u8F93\u5165\u5F02\u5E38\u539F\u56E0\uFF01"})):P(a)}},{title:"\u64CD\u4F5C",dataIndex:"option",valueType:"option",render:function(a,t){return[(0,h.jsx)("a",{onClick:function(){S(t),Y(!0)},children:"\u67E5\u770B\u8BE6\u60C5"},"config"),(0,h.jsx)("a",{onClick:function(){D.printsmallticket({orderId:t.id}).then(function(P){P.data?_.default.success("\u6253\u5370\u6210\u529F"):_.default.error("\u6253\u5370\u5931\u8D25")})},children:"\u6253\u5370\u5C0F\u7968"},"config")]}}],de=function(){var i=(0,x.Z)((0,r.Z)().mark(function a(){var t,d,P,p,O,v;return(0,r.Z)().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:return C.next=2,D.GetFlowExport($);case 2:t=C.sent,t.isSuccess?(d={},P=new Date,p="\u8BA2\u5355\u6D41\u6C34"+P.toLocaleString().replaceAll("/","-"),d.fileName=p,O=["storeTypeName","storeName","order_Number","order_OriginalMoney","order_RealMoney","refundOriginalMoney","refundRealMoney","order_Count","order_CreateTime"],d.datas=[{sheetData:t.data,sheetName:p,sheetFilter:O,sheetHeader:["\u5E97\u94FA\u5206\u7C7B","\u5E97\u94FA\u540D\u79F0","\u4EA4\u6613\u5355\u53F7","\u5E94\u4ED8\u91D1\u989D","\u5B9E\u4ED8\u91D1\u989D","\u5E94\u4ED8\u91D1\u989D(\u9000)","\u5B9E\u4ED8\u91D1\u989D(\u9000)","\u5B50\u8BA2\u5355\u6570\u91CF","\u521B\u5EFA\u65F6\u95F4"]}],v=new(M())(d),v.saveExcel()):_.default.error(t.errors||"\u5BFC\u51FA\u5931\u8D25");case 4:case"end":return C.stop()}},a)}));return function(){return i.apply(this,arguments)}}();return(0,h.jsxs)(F.ZP,{children:[(0,h.jsx)(K.ZP,{headerTitle:"\u8BA2\u5355\u6D41\u6C34",actionRef:re,rowKey:"orderFlowId",search:{labelWidth:120},toolBarRender:function(){return[(0,h.jsxs)(c.Z,{type:"primary",onClick:de,children:[(0,h.jsx)(m.Z,{})," \u5BFC\u51FA"]},"create")]},columns:oe,request:function(){var i=(0,x.Z)((0,r.Z)().mark(function a(t,d,P){var p;return(0,r.Z)().wrap(function(v){for(;;)switch(v.prev=v.next){case 0:return t.storeTypeId!=null&&(t.storeTypeId=srdTypeList[t.storeTypeId].storeTypeId),t.orderStatus=0,v.next=4,D.orderList(t);case 4:return p=v.sent,ne(t),te(p.data.data),v.abrupt("return",{data:p.data.data,success:!0,total:p.data.total});case 8:case"end":return v.stop()}},a)}));return function(a,t,d){return i.apply(this,arguments)}}()}),!!j&&(0,h.jsx)(A.Z,{onCancel:function(){S(void 0),Y(!1)},createModalVisible:J,values:j||{}})]})},B=U}}]);