25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

2 lines
12 KiB

  1. (self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[6713,1322,9464,1981,2869,7013,9719,2383],{20498:function(j){j.exports={"data-search-card":"data-search-card___3kFoI","data-search-box":"data-search-box___3DFSh","search-btn-item":"search-btn-item___3Osl6","table-page":"table-page___3f6vl","loading-card":"loading-card___2D0GH","data-search-item":"data-search-item___SinMf","data-search-input":"data-search-input___3n8I5","data-search-prefix":"data-search-prefix___169Gl","data-search-sufixx":"data-search-sufixx___1KyMR","data-search-btns":"data-search-btns___1TGoh","download-btn":"download-btn___3iu0F"}},80638:function(){},51174:function(j,x,e){"use strict";e.r(x),e.d(x,{default:function(){return A}});var n=e(14781),E=e(36138),S=e(66456),L=e(64411),ue=e(58024),W=e(91894),D=e(57663),$=e(71577),ce=e(13062),T=e(71230),se=e(43358),re=e(34041),r=e(89032),K=e(15746),O=e(62999),g=e(54680),Z=e(93224),a=e(39428),C=e(34792),c=e(48086),i=e(3182),l=e(2824),z=e(20228),G=e(11382),k=e(14965),B=e(91774),d=e(67294),M=e(78009),Q=e(20498),v=e.n(Q),J=e(11849),b=e(48971),U={getReportSalesmargin:function(h){return(0,b.WY)("/kitchen/api/report/salesmargin",{method:"Post",data:h})},goodsList:function(h){return(0,b.WY)("/kitchen/api/goodes/list",{method:"Post",data:h})},goodsTypeList:function(h){return(0,b.WY)("/kitchen/api/goodstype/list",{method:"Post",data:h})},gettree:function(h){return(0,b.WY)("\u200B/kitchen/api\u200B/sysOrg\u200B/tree",{data:(0,J.Z)({},h)})}},y=e(30381),m=e.n(y),ne=e(90631),t=e(85893),q=["children"],H=B.Z.RangePicker,R=function(){return(0,t.jsx)("div",{className:v()["loading-card"],children:(0,t.jsx)(G.Z,{size:"large"})})};function A(){var u=(0,d.useState)([]),h=(0,l.Z)(u,2),oe=h[0],_e=h[1],me=(0,d.useState)(1),F=(0,l.Z)(me,2),I=F[0],ge=F[1],w=(0,d.useState)(10),ee=(0,l.Z)(w,2),te=ee[0],he=ee[1],de=(0,d.useState)(0),le=(0,l.Z)(de,2),ie=le[0],Ee=le[1],fe=(0,d.useState)(!1),N=(0,l.Z)(fe,2),Y=N[0],P=N[1],ve=(0,d.useState)([m()(m()(new Date(Date.now()-24*60*60*1e3*7)).format("YYYY-MM-DD 00:00:00")),m()(m()(new Date(Date.now())).format("YYYY-MM-DD 23:59:59"))]),ae=(0,l.Z)(ve,2),V=ae[0],ye=ae[1],Le=(0,d.useState)(""),pe=(0,l.Z)(Le,2),xe=pe[0],De=pe[1],Te=(0,d.useState)([]),Oe=(0,l.Z)(Te,2),Be=Oe[0],We=Oe[1],Ke=(0,d.useState)([]),Pe=(0,l.Z)(Ke,2),Ue=Pe[0],Ne=Pe[1],Ye=(0,d.useState)([]),Se=(0,l.Z)(Ye,2),Ze=Se[0],Ce=Se[1],Ge=(0,d.useState)([]),Me=(0,l.Z)(Ge,2),Re=Me[0],be=Me[1],Fe=(0,d.useState)([]),Ae=(0,l.Z)(Fe,2),we=Ae[0],$e=Ae[1],ze=(0,d.useState)([]),Ie=(0,l.Z)(ze,2),tt=Ie[0],Qe=Ie[1],Je=[{title:"\u95E8\u5E97\u540D\u79F0",dataIndex:"storeId",key:"storeId",render:function(o){var s=Ue.find(function(p){return p.key===o});return s?(0,t.jsx)("span",{children:s.title}):(0,t.jsx)("span",{children:"\u6682\u65E0\u95E8\u5E97\u540D\u79F0"})}},{title:"\u5546\u54C1\u540D\u79F0",dataIndex:"goodsId",key:"goodsId",render:function(o){var s=Re.find(function(p){return p.id===o});return s?(0,t.jsx)("span",{children:s.name}):(0,t.jsx)("span",{children:"\u6682\u65E0\u5546\u54C1\u540D\u79F0"})}},{title:"\u6BDB\u5229\u7387\uFF08%\uFF09",dataIndex:"marginRatio",key:"marginRatio"}],He=function(o,s){ge(o),he(s)},je=function(){var _=(0,i.Z)((0,a.Z)().mark(function o(){var s,p;return(0,a.Z)().wrap(function(X){for(;;)switch(X.prev=X.next){case 0:return s={storeId:xe,goodsId:Ze[0],goodsTypeId:we[0],begintime:V[0],endtime:V[1],current:I,pageSize:te},P(!0),X.next=4,U.getReportSalesmargin(s);case 4:p=X.sent,P(!1),p.statusCode===200?_e(p.data.data):c.default.error(p.errors||"\u83B7\u53D6\u9500\u552E\u6210\u672C\u5931\u8D25");case 7:case"end":return X.stop()}},o)}));return function(){return _.apply(this,arguments)}}(),Ve=function(){var _=(0,i.Z)((0,a.Z)().mark(function o(){var s;return(0,a.Z)().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return P(!0),f.next=3,U.gettree({});case 3:s=f.sent,P(!1),s.statusCode===200?(We(s.data),Ne(et(s.data))):c.default.error("\u67E5\u8BE2\u5E97\u94FA\u5217\u8868\u5931\u8D25");case 6:case"end":return f.stop()}},o)}));return function(){return _.apply(this,arguments)}}(),Xe=function(){var _=(0,i.Z)((0,a.Z)().mark(function o(){var s;return(0,a.Z)().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return P(!0),f.next=3,U.goodsList({});case 3:s=f.sent,P(!1),s.statusCode===200?be(s.data):c.default.error("\u67E5\u8BE2\u5546\u54C1\u5217\u8868\u5931\u8D25");case 6:case"end":return f.stop()}},o)}));return function(){return _.apply(this,arguments)}}(),ke=function(){var _=(0,i.Z)((0,a.Z)().mark(function o(){var s;return(0,a.Z)().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return P(!0),f.next=3,U.goodsTypeList({});case 3:s=f.sent,P(!1),s.statusCode===200?Qe(s.data):c.default.error("\u67E5\u8BE2\u5546\u54C1\u5206\u7C7B\u5217\u8868\u5931\u8D25");case 6:case"end":return f.stop()}},o)}));return function(){return _.apply(this,arguments)}}(),qe=function(){Ce([]),De([]),$e([]),ye([m()(m()(new Date(Date.now()-24*60*60*1e3*7)).format("YYYY-MM-DD 00:00:00")),m()(m()(new Date(Date.now())).format("YYYY-MM-DD 23:59:59"))])},et=function _(o){var s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return o.forEach(function(p){var f=p.children,X=(0,Z.Z)(p,q);s.push(X),f&&f.length>0&&_(f,s)}),s};return(0,d.useEffect)(function(){je(),Ve(),Xe(),ke()},[]),(0,t.jsxs)(M.ZP,{children:[Y?(0,t.jsx)(R,{}):null,(0,t.jsxs)(W.Z,{className:v()["data-search-card"],children:[(0,t.jsxs)(T.Z,{gutter:20,justify:"space-between",children:[(0,t.jsxs)(K.Z,{xs:24,sm:24,md:12,lg:12,xl:6,className:v()["data-search-item"],children:[(0,t.jsx)("div",{className:v()["data-search-prefix"],children:"\u95E8\u5E97"}),(0,t.jsx)(g.Z,{className:v()["data-search-sufixx"],value:xe,dropdownStyle:{maxHeight:400,overflow:"auto"},treeData:Be,placeholder:"\u8BF7\u9009\u62E9\u95E8\u5E97",treeDefaultExpandAll:!0,onChange:function(o){return De(o)}})]}),(0,t.jsxs)(K.Z,{xs:24,sm:24,md:12,lg:12,xl:6,className:v()["data-search-item"],children:[(0,t.jsx)("div",{className:v()["data-search-prefix"],children:"\u5546\u54C1"}),(0,t.jsx)(re.Z,{className:v()["data-search-sufixx"],showSearch:!0,mode:"tags",size:"middle",allowClear:!0,placeholder:"\u8BF7\u9009\u62E9\u5546\u54C1",value:Ze,onChange:function(o){return Ce(o)},filterOption:function(o,s){return s.children.toLowerCase().includes(o.toLowerCase())},children:Re.map(function(_,o){return(0,t.jsx)(Option,{children:_.name},_.id)})})]}),(0,t.jsxs)(K.Z,{xs:24,sm:24,md:12,lg:12,xl:6,className:v()["data-search-item"],children:[(0,t.jsx)("div",{className:v()["data-search-prefix"],children:"\u8D77\u59CB\u65F6\u95F4"}),(0,t.jsx)(H,{size:"middle",className:v()["data-search-sufixx"],value:V,onChange:function(o,s){var p=[m()(m()(new Date(s[0])).format("YYYY-MM-DD 00:00:00")),m()(m()(new Date(s[1])).format("YYYY-MM-DD 23:59:59"))];ye(p)}})]})]}),(0,t.jsxs)("div",{className:v()["data-search-btns"],children:[(0,t.jsx)($.Z,{className:v()["search-btn-item"],onClick:qe,children:"\u91CD\u7F6E"}),(0,t.jsx)($.Z,{className:v()["search-btn-item"],type:"primary",onClick:je,children:"\u67E5\u8BE2"})]})]}),(0,t.jsxs)(W.Z,{className:v()["table-card"],children:[(0,t.jsx)("div",{className:v()["download-btn"],children:(0,t.jsx)($.Z,{type:"primary",icon:(0,t.jsx)(ne.Z,{}),size:"middle",children:"\u4E0B\u8F7D"})}),(0,t.jsx)(L.Z,{dataSource:oe,columns:Je,pagination:!1}),(0,t.jsx)("div",{className:v()["table-page"],children:(0,t.jsx)(E.Z,{current:I,pageSize:te,total:ie,onChange:He})})]})]})}},15746:function(j,x,e){"use strict";var n=e(21584);x.Z=n.Z},89032:function(j,x,e){"use strict";var n=e(38663),E=e.n(n),S=e(6999)},99134:function(j,x,e){"use strict";var n=e(67294),E=(0,n.createContext)({});x.Z=E},21584:function(j,x,e){"use strict";var n=e(96156),E=e(22122),S=e(90484),L=e(94184),ue=e.n(L),W=e(67294),D=e(53124),$=e(99134),ce=function(r,K){var O={};for(var g in r)Object.prototype.hasOwnProperty.call(r,g)&&K.indexOf(g)<0&&(O[g]=r[g]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Z=0,g=Object.getOwnPropertySymbols(r);Z<g.length;Z++)K.indexOf(g[Z])<0&&Object.prototype.propertyIsEnumerable.call(r,g[Z])&&(O[g[Z]]=r[g[Z]]);return O};function T(r){return typeof r=="number"?"".concat(r," ").concat(r," auto"):/^\d+(\.\d+)?(px|em|rem|%)$/.test(r)?"0 0 ".concat(r):r}var se=["xs","sm","md","lg","xl","xxl"],re=W.forwardRef(function(r,K){var O,g=W.useContext(D.E_),Z=g.getPrefixCls,a=g.direction,C=W.useContext($.Z),c=C.gutter,i=C.wrap,l=C.supportFlexGap,z=r.prefixCls,G=r.span,k=r.order,B=r.offset,d=r.push,M=r.pull,Q=r.className,v=r.children,J=r.flex,b=r.style,U=ce(r,["prefixCls","span","order","offset","push","pull","className","children","flex","style"]),y=Z("col",z),m={};se.forEach(function(R){var A,u={},h=r[R];typeof h=="number"?u.span=h:(0,S.Z)(h)==="object"&&(u=h||{}),delete U[R],m=(0,E.Z)((0,E.Z)({},m),(A={},(0,n.Z)(A,"".concat(y,"-").concat(R,"-").concat(u.span),u.span!==void 0),(0,n.Z)(A,"".concat(y,"-").concat(R,"-order-").concat(u.order),u.order||u.order===0),(0,n.Z)(A,"".concat(y,"-").concat(R,"-offset-").concat(u.offset),u.offset||u.offset===0),(0,n.Z)(A,"".concat(y,"-").concat(R,"-push-").concat(u.push),u.push||u.push===0),(0,n.Z)(A,"".concat(y,"-").concat(R,"-pull-").concat(u.pull),u.pull||u.pull===0),(0,n.Z)(A,"".concat(y,"-rtl"),a==="rtl"),A))});var ne=ue()(y,(O={},(0,n.Z)(O,"".concat(y,"-").concat(G),G!==void 0),(0,n.Z)(O,"".concat(y,"-order-").concat(k),k),(0,n.Z)(O,"".concat(y,"-offset-").concat(B),B),(0,n.Z)(O,"".concat(y,"-push-").concat(d),d),(0,n.Z)(O,"".concat(y,"-pull-").concat(M),M),O),Q,m),t={};if(c&&c[0]>0){var q=c[0]/2;t.paddingLeft=q,t.paddingRight=q}if(c&&c[1]>0&&!l){var H=c[1]/2;t.paddingTop=H,t.paddingBottom=H}return J&&(t.flex=T(J),i===!1&&!t.minWidth&&(t.minWidth=0)),W.createElement("div",(0,E.Z)({},U,{style:(0,E.Z)((0,E.Z)({},t),b),className:ne,ref:K}),v)});x.Z=re},92820:function(j,x,e){"use strict";var n=e(22122),E=e(96156),S=e(90484),L=e(28481),ue=e(94184),W=e.n(ue),D=e(67294),$=e(53124),ce=e(98082),T=e(24308),se=e(93355),re=e(99134),r=function(a,C){var c={};for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&C.indexOf(i)<0&&(c[i]=a[i]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var l=0,i=Object.getOwnPropertySymbols(a);l<i.length;l++)C.indexOf(i[l])<0&&Object.prototype.propertyIsEnumerable.call(a,i[l])&&(c[i[l]]=a[i[l]]);return c},K=(0,se.b)("top","middle","bottom","stretch"),O=(0,se.b)("start","end","center","space-around","space-between","space-evenly");function g(a,C){var c=D.useState(typeof a=="string"?a:""),i=(0,L.Z)(c,2),l=i[0],z=i[1],G=function(){if(typeof a=="string"&&z(a),(0,S.Z)(a)==="object")for(var B=0;B<T.c4.length;B++){var d=T.c4[B];if(!!C[d]){var M=a[d];if(M!==void 0){z(M);return}}}};return D.useEffect(function(){G()},[JSON.stringify(a),C]),l}var Z=D.forwardRef(function(a,C){var c,i=a.prefixCls,l=a.justify,z=a.align,G=a.className,k=a.style,B=a.children,d=a.gutter,M=d===void 0?0:d,Q=a.wrap,v=r(a,["prefixCls","justify","align","className","style","children","gutter","wrap"]),J=D.useContext($.E_),b=J.getPrefixCls,U=J.direction,y=D.useState({xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0}),m=(0,L.Z)(y,2),ne=m[0],t=m[1],q=D.useState({xs:!1,sm:!1,md:!1,lg:!1,xl:!1,xxl:!1}),H=(0,L.Z)(q,2),R=H[0],A=H[1],u=g(z,R),h=g(l,R),oe=(0,ce.Z)(),_e=D.useRef(M);D.useEffect(function(){var fe=T.ZP.subscribe(function(N){A(N);var Y=_e.current||0;(!Array.isArray(Y)&&(0,S.Z)(Y)==="object"||Array.isArray(Y)&&((0,S.Z)(Y[0])==="object"||(0,S.Z)(Y[1])==="object"))&&t(N)});return function(){return T.ZP.unsubscribe(fe)}},[]);var me=function(){var N=[void 0,void 0],Y=Array.isArray(M)?M:[M,void 0];return Y.forEach(function(P,ve){if((0,S.Z)(P)==="object")for(var ae=0;ae<T.c4.length;ae++){var V=T.c4[ae];if(ne[V]&&P[V]!==void 0){N[ve]=P[V];break}}else N[ve]=P}),N},F=b("row",i),I=me(),ge=W()(F,(c={},(0,E.Z)(c,"".concat(F,"-no-wrap"),Q===!1),(0,E.Z)(c,"".concat(F,"-").concat(h),h),(0,E.Z)(c,"".concat(F,"-").concat(u),u),(0,E.Z)(c,"".concat(F,"-rtl"),U==="rtl"),c),G),w={},ee=I[0]!=null&&I[0]>0?I[0]/-2:void 0,te=I[1]!=null&&I[1]>0?I[1]/-2:void 0;if(ee&&(w.marginLeft=ee,w.marginRight=ee),oe){var he=(0,L.Z)(I,2);w.rowGap=he[1]}else te&&(w.marginTop=te,w.marginBottom=te);var de=(0,L.Z)(I,2),le=de[0],ie=de[1],Ee=D.useMemo(function(){return{gutter:[le,ie],wrap:Q,supportFlexGap:oe}},[le,ie,Q,oe]);return D.createElement(re.Z.Provider,{value:Ee},D.createElement("div",(0,n.Z)({},v,{className:ge,style:(0,n.Z)((0,n.Z)({},w),k),ref:C}),B))});x.Z=Z},6999:function(j,x,e){"use strict";var n=e(38663),E=e.n(n),S=e(80638),L=e.n(S)},71230:function(j,x,e){"use strict";var n=e(92820);x.Z=n.Z},13062:function(j,x,e){"use strict";var n=e(38663),E=e.n(n),S=e(6999)}}]);