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