包含后厨 团餐 门店分支
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
5.2 KiB

  1. (self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[7307],{4506:function(L,D,e){"use strict";e.r(D);var E=e(18106),o=e(95562),P=e(58024),_=e(91894),ae=e(57663),I=e(71577),ne=e(47673),M=e(4107),h=e(39428),B=e(3182),m=e(2824),se=e(14965),F=e(91774),b=e(28790),C=e(16894),l=e(67294),w=e(30381),r=e.n(w),v=e(64008),t=e(85893),k=F.Z.RangePicker,H=function(){var z=(0,l.useState)(1),O=(0,m.Z)(z,2),p=O[0],$=O[1],G=(0,l.useState)(""),R=(0,m.Z)(G,2),g=R[0],T=R[1],J=(0,l.useState)(""),y=(0,m.Z)(J,2),f=y[0],U=y[1],Q=(0,l.useState)(""),A=(0,m.Z)(Q,2),S=A[0],Z=A[1],V=(0,l.useState)([]),W=(0,m.Z)(V,2),Y=W[0],x=W[1],X=(0,l.useState)([r()(r()(new Date(Date.now())).format("YYYY-MM-DD 00:00:00")),r()(r()(new Date(Date.now())).format("YYYY-MM-DD 23:59:59"))]),j=(0,m.Z)(X,2),c=j[0],K=j[1];(0,l.useEffect)(function(){N()},[p]);var N=function(){var i=(0,B.Z)((0,h.Z)().mark(function a(){var n;return(0,h.Z)().wrap(function(s){for(;;)switch(s.prev=s.next){case 0:if(n=[],p!=1){s.next=7;break}return s.next=4,v.Z.getRecipeUseDetail({recipeName:g,startTime:c[0]._i,endTime:c[1]._i,storeName:f,deviceName:S});case 4:n=s.sent,s.next=10;break;case 7:return s.next=9,v.Z.getRecipeUseSummary({recipeName:g,startTime:c[0]._i,endTime:c[1]._i,storeName:f,deviceName:S});case 9:n=s.sent;case 10:x(n.data);case 11:case"end":return s.stop()}},a)}));return function(){return i.apply(this,arguments)}}(),q=function(){var i=(0,B.Z)((0,h.Z)().mark(function a(){var n,d,s;return(0,h.Z)().wrap(function(u){for(;;)switch(u.prev=u.next){case 0:if(T(""),U(""),Z(""),n=r()(new Date(Date.now())).format("YYYY-MM-DD 00:00:00"),d=r()(new Date(Date.now())).format("YYYY-MM-DD 23:59:59"),K([r()(n),r()(d)]),s=[],p!=1){u.next=13;break}return u.next=10,v.Z.getRecipeUseDetail({recipeName:"",startTime:n,endTime:d,storeName:"",deviceName:""});case 10:s=u.sent,u.next=16;break;case 13:return u.next=15,v.Z.getRecipeUseSummary({recipeName:"",startTime:n,endTime:d,storeName:"",deviceName:""});case 15:s=u.sent;case 16:x(s.data);case 17:case"end":return u.stop()}},a)}));return function(){return i.apply(this,arguments)}}(),ee=[{title:"\u4E3B\u952E",dataIndex:"id",tip:"key",hideInSearch:!0,hideInTable:!0},{title:"\u914D\u65B9\u540D\u79F0",dataIndex:"recipeName",ellipsis:!0,hideInSearch:!0},{title:"\u95E8\u5E97\u540D\u79F0",dataIndex:"storeName",ellipsis:!0,hideInSearch:!0},{title:"\u8BBE\u5907\u540D\u79F0",dataIndex:"deviceName",ellipsis:!0,hideInSearch:!0},{title:"\u4F7F\u7528\u65F6\u95F4",dataIndex:"useDate",ellipsis:!0,hideInSearch:!0}],te=[{title:"\u4E3B\u952E",dataIndex:"id",tip:"key",hideInSearch:!0,hideInTable:!0},{title:"\u914D\u65B9\u540D\u79F0",dataIndex:"recipeName",ellipsis:!0,hideInSearch:!0},{title:"\u95E8\u5E97\u540D\u79F0",dataIndex:"storeName",ellipsis:!0,hideInSearch:!0},{title:"\u8BBE\u5907\u540D\u79F0",dataIndex:"deviceName",ellipsis:!0,hideInSearch:!0},{title:"\u4F7F\u7528\u6570\u91CF",dataIndex:"useCount",ellipsis:!0,hideInSearch:!0}];return(0,t.jsxs)(b.ZP,{header:{title:"",breadcrumb:{}},children:[(0,t.jsxs)(_.Z,{style:{marginBottom:20},children:[(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",width:"100%"},children:[(0,t.jsx)("span",{children:"\u914D\u65B9\u540D\u79F0:"}),(0,t.jsx)(M.Z,{placeholder:"\u8BF7\u8F93\u5165\u914D\u65B9\u540D\u79F0",style:{width:"15%",margin:10},value:g,onChange:function(a){T(a.target.value)}}),(0,t.jsx)("span",{children:"\u95E8\u5E97\u540D\u79F0:"}),(0,t.jsx)(M.Z,{placeholder:"\u8BF7\u8F93\u5165\u95E8\u5E97\u540D\u79F0",style:{width:"15%",margin:10},value:f,onChange:function(a){U(a.target.value)}}),(0,t.jsx)("span",{children:"\u8BBE\u5907\u540D\u79F0:"}),(0,t.jsx)(M.Z,{placeholder:"\u8BF7\u8F93\u5165\u8BBE\u5907\u540D\u79F0",style:{width:"15%",margin:10},value:S,onChange:function(a){Z(a.target.value)}})]}),(0,t.jsxs)("div",{style:{display:"flex",alignItems:"center",width:"100%"},children:[(0,t.jsx)("span",{children:"\u4F7F\u7528\u65F6\u95F4:"}),(0,t.jsx)(k,{showTime:!0,style:{width:"25%",margin:10},value:c,onChange:function(a,n){var d=[r()(r()(new Date(n[0])).format("YYYY-MM-DD HH:mm:ss")),r()(r()(new Date(n[1])).format("YYYY-MM-DD HH:mm:ss"))];K(d)}}),(0,t.jsx)(I.Z,{onClick:function(){q()},children:"\u91CD\u7F6E"}),(0,t.jsx)(I.Z,{type:"primary",style:{marginLeft:10},onClick:function(){N()},children:"\u67E5\u8BE2"})]})]}),(0,t.jsx)(_.Z,{children:(0,t.jsx)(o.Z,{tabPosition:"left",value:p,onChange:function(a){$(a)},items:new Array(2).fill(null).map(function(i,a){var n=String(a+1);return{label:n==1?"\u914D\u65B9\u4F7F\u7528\u660E\u7EC6":"\u914D\u65B9\u4F7F\u7528\u6C47\u603B",key:n,children:n==1?(0,t.jsx)(C.ZP,{headerTitle:"\u914D\u65B9\u4F7F\u7528\u660E\u7EC6",rowKey:"id",pagination:{defaultPageSize:10},search:!1,toolBarRender:!1,columns:ee,dataSource:Y}):(0,t.jsx)(C.ZP,{headerTitle:"\u914D\u65B9\u4F7F\u7528\u6C47\u603B",rowKey:"id",pagination:{defaultPageSize:10},search:!1,toolBarRender:!1,columns:te,dataSource:Y})}})})})]})};D.default=H},64008:function(L,D,e){"use strict";var E=e(48971),o=e(96690);D.Z={getRecipeUseDetail:function(_){return(0,E.WY)((0,o.w)()+"/api/report/getRecipeUseDetail",{method:"Post",data:_})},getRecipeUseSummary:function(_){return(0,E.WY)((0,o.w)()+"/api/report/getRecipeUseSummary",{method:"Post",data:_})},getBatchingUseSummary:function(_){return(0,E.WY)((0,o.w)()+"/api/report/getBatchingUseSummary",{method:"Post",data:_})}}}}]);