Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 
 

2 lignes
12 KiB

  1. (self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[6442],{19273:function(ne,V,r){"use strict";r.r(V),r.d(V,{default:function(){return fe}});var j=r(57338),b=r(273),T=r(57663),E=r(71577),L=r(58024),w=r(91894),Y=r(32157),M=r(7573),x=r(2824),s=r(39428),K=r(11849),U=r(34792),v=r(48086),C=r(3182),H=r(49101),p=r(67294),G=r(78009),$=r(85224),u=r(53779),o=r(12826),A=r(71194),t=r(50146),W=r(77883),se=r(85986),Oe=r(62999),le=r(54680),Be=r(9715),g=r(55843),Te=r(43358),D=r(34041),Re=r(47673),I=r(4107),e=r(85893),ie=function(l){var f=I.Z.TextArea,c=D.Z.Option,m=D.Z.OptGroup;return(0,e.jsx)(t.Z,{title:l.values.id?"\u7F16\u8F91\u673A\u6784":"\u65B0\u5EFA\u673A\u6784",width:640,visible:l.modalVisible,bodyStyle:{padding:"32px 40px 48px"},footer:null,onCancel:function(){l.onCancel()},keyboard:!1,destroyOnClose:!0,children:(0,e.jsxs)(g.Z,{layout:"horizontal",preserve:!1,labelCol:{span:4},initialValues:l.values,onFinish:l.onFinish,children:[(0,e.jsx)(g.Z.Item,{name:"id",hidden:!0,children:(0,e.jsx)(I.Z,{})}),(0,e.jsx)(g.Z.Item,{name:"code",label:"\u7EC4\u7EC7\u7F16\u7801",rules:[{required:!0,max:64}],children:(0,e.jsx)(I.Z,{placeholder:"\u8BF7\u8F93\u5165\u7EC4\u7EC7\u7F16\u7801"})}),(0,e.jsx)(g.Z.Item,{name:"name",label:"\u7EC4\u7EC7\u540D\u79F0",rules:[{required:!0,max:64}],children:(0,e.jsx)(I.Z,{placeholder:"\u8BF7\u8F93\u5165\u540D\u79F0"})}),(0,e.jsx)(g.Z.Item,{name:"pid",label:"\u4E0A\u7EA7\u540D\u79F0",rules:[{required:!0}],children:(0,e.jsx)(le.Z,{style:{width:"100%"},dropdownStyle:{maxHeight:400,overflow:"auto"},treeData:l.treeDatas,placeholder:"\u8BF7\u9009\u62E9\u4E0A\u7EA7\u540D\u79F0",treeDefaultExpandAll:!0})}),(0,e.jsx)(g.Z.Item,{name:"type",label:"\u7EC4\u7EC7\u7C7B\u578B",defaultValue:l.values.type,rules:[{required:!0,message:"\u8BF7\u9009\u62E9\u7EC4\u7EC7\u7C7B\u578B"}],children:(0,e.jsx)(D.Z,{placeholder:"\u8BF7\u9009\u62E9\u673A\u6784\u7C7B\u578B",children:(0,e.jsxs)(m,{children:[(0,e.jsx)(D.Z.Option,{value:0,children:"\u673A\u6784"}),(0,e.jsx)(D.Z.Option,{value:1,children:"\u914D\u9001\u4E2D\u5FC3"}),(0,e.jsx)(D.Z.Option,{value:2,children:"\u76F4\u8425\u5E97"}),(0,e.jsx)(D.Z.Option,{value:3,children:"\u52A0\u76DF\u5E97"})]})})}),(0,e.jsx)(g.Z.Item,{label:"\u5E97\u94FA\u5730\u5740",name:"store_Addr",rules:[{required:!0,max:100}],children:(0,e.jsx)(I.Z,{placeholder:"\u6210\u90FD\u5E02\u6B66\u4FAF\u533A\u6842\u6EAA\u8857\u9053\u73AF\u7403\u4E2D\u5FC3N5-9111C"})}),(0,e.jsx)(g.Z.Item,{label:"\u5E97\u94FA\u5750\u6807",name:"store_Loc",rules:[{required:!0,max:100,pattern:/^[-\+]?\d+(\.\d+)\,[-\+]?\d+(\.\d+)$/,message:"\u7ECF\u7EAC\u5EA6\u683C\u5F0F\u4E0D\u5BF9"}],children:(0,e.jsx)(I.Z,{placeholder:"104.070734,30.575041"})}),(0,e.jsx)(g.Z.Item,{name:"tel",label:"\u7535\u8BDD",rules:[{max:20}],children:(0,e.jsx)(I.Z,{placeholder:"\u8BF7\u8F93\u5165\u8054\u7CFB\u7535\u8BDD"})}),(0,e.jsx)(g.Z.Item,{name:"sort",label:"\u6392\u5E8F",children:(0,e.jsx)(se.Z,{min:1,step:1,precision:0})}),(0,e.jsx)(g.Z.Item,{name:"remark",label:"\u5907\u6CE8",children:(0,e.jsx)(f,{rows:4,rules:[{max:500}]})}),(0,e.jsx)(g.Z.Item,{children:(0,e.jsx)(E.Z,{type:"primary",htmlType:"submit",children:"\u4FDD\u5B58"})})]})})},de=ie,R=r(3408),oe=r(48971),ce=function(){var O=(0,C.Z)((0,s.Z)().mark(function l(f){var c,m;return(0,s.Z)().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return c=v.default.loading("\u6B63\u5728\u6DFB\u52A0"),a.prev=1,a.next=4,(0,R.IH)((0,K.Z)({},f));case 4:if(m=a.sent,m.succeeded){a.next=9;break}return v.default.error(m.errors),c(),a.abrupt("return",!1);case 9:return c(),v.default.success("\u6DFB\u52A0\u6210\u529F"),a.abrupt("return",!0);case 14:return a.prev=14,a.t0=a.catch(1),c(),v.default.error("\u6DFB\u52A0\u5931\u8D25\u8BF7\u91CD\u8BD5\uFF01"),a.abrupt("return",!1);case 19:case"end":return a.stop()}},l,null,[[1,14]])}));return function(f){return O.apply(this,arguments)}}(),he=function(){var O=(0,C.Z)((0,s.Z)().mark(function l(f){var c,m;return(0,s.Z)().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return c=v.default.loading("\u6B63\u5728\u914D\u7F6E"),a.prev=1,a.next=4,(0,R.eP)((0,K.Z)({},f));case 4:if(m=a.sent,m.succeeded){a.next=9;break}return v.default.error(m.errors),c(),a.abrupt("return",!1);case 9:return c(),v.default.success("\u4FEE\u6539\u6210\u529F"),a.abrupt("return",!0);case 14:return a.prev=14,a.t0=a.catch(1),c(),v.default.error("\u914D\u7F6E\u5931\u8D25\u8BF7\u91CD\u8BD5\uFF01"),a.abrupt("return",!1);case 19:case"end":return a.stop()}},l,null,[[1,14]])}));return function(f){return O.apply(this,arguments)}}(),pe=function(){var O=(0,C.Z)((0,s.Z)().mark(function l(f){var c;return(0,s.Z)().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:if(c=v.default.loading("\u6B63\u5728\u5220\u9664"),f){d.next=3;break}return d.abrupt("return",!0);case 3:return d.prev=3,d.next=6,(0,R.mm)({key:f.map(function(a){return a.key})});case 6:return c(),v.default.success("\u5220\u9664\u6210\u529F\uFF0C\u5373\u5C06\u5237\u65B0"),d.abrupt("return",!0);case 11:return d.prev=11,d.t0=d.catch(3),c(),v.default.error("\u5220\u9664\u5931\u8D25\uFF0C\u8BF7\u91CD\u8BD5"),d.abrupt("return",!1);case 16:case"end":return d.stop()}},l,null,[[3,11]])}));return function(f){return O.apply(this,arguments)}}(),me=function(){var l=(0,p.useState)(),f=(0,x.Z)(l,2),c=f[0],m=f[1],d=(0,p.useState)(),a=(0,x.Z)(d,2),Pe=a[0],we=a[1],ve=(0,p.useState)({}),N=(0,x.Z)(ve,2),Ze=N[0],z=N[1],ye=(0,p.useState)(),J=(0,x.Z)(ye,2),Me=J[0],$e=J[1],ge=(0,p.useState)(),Q=(0,x.Z)(ge,2),je=Q[0],Ce=Q[1],k=(0,p.useRef)(),Ee=(0,p.useState)(),X=(0,x.Z)(Ee,2),S=X[0],xe=X[1],Se=(0,p.useState)(),q=(0,x.Z)(Se,2),P=q[0],Fe=q[1],be=(0,p.useState)(),_=(0,x.Z)(be,2),ee=_[0],re=_[1],Ae=(0,p.useState)(),te=(0,x.Z)(Ae,2),De=te[0],Ie=te[1],ae=[{title:"\u4E3B\u952E",dataIndex:"id",tip:"key",hideInSearch:!0,hideInTable:!0},{title:"\u7EC4\u7EC7\u540D\u79F0",dataIndex:"name"},{title:"\u7EC4\u7EC7\u7F16\u7801",dataIndex:"code"},{title:"\u7EC4\u7EC7\u7C7B\u578B",dataIndex:"type",valueEnum:{0:{text:"\u673A\u6784"},1:{text:"\u914D\u9001\u4E2D\u5FC3"},2:{text:"\u76F4\u8425\u5E97"},3:{text:"\u52A0\u76DF\u5E97"}}},{title:"\u7535\u8BDD",dataIndex:"tel",hideInSearch:!0},{title:"\u6392\u5E8F",dataIndex:"sort",valueType:"digit",hideInSearch:!0},{title:"\u63CF\u8FF0",dataIndex:"remark",valueType:"textarea",hideInSearch:!0},{title:"\u64CD\u4F5C",dataIndex:"x",valueType:"option",render:function(i,n){var Z=(0,e.jsx)("a",{},"primary");return n.type>=2&&(Z=(0,e.jsx)("a",{onClick:function(){oe.m8.push({pathname:"/sys/storemanage",query:{isAdd:!1,values:n.id}})},children:"\u5E97\u94FA\u7BA1\u7406"},"primary2")),[(0,e.jsxs)("a",{onClick:function(){m(!0),z(n)},children:[" ","\u4FEE\u6539"]},"primary3"),Z]}}];return(0,p.useEffect)(function(){function h(){(0,R.FM)().then(function(i){re(i.data)})}h()},[]),(0,e.jsxs)(G.ZP,{children:[(0,e.jsx)(u.ZP,{headerTitle:"\u7EC4\u7EC7\u5217\u8868",actionRef:k,rowKey:"id",search:{labelWidth:120},tableRender:function(i,n){return(0,e.jsxs)("div",{style:{display:"flex",width:"100%"},children:[(0,e.jsx)(w.Z,{title:"\u673A\u6784\u90E8\u95E8",children:(0,e.jsx)(M.Z,{defaultExpandAll:!0,onSelect:function(y){return Ie(y[0])},treeData:ee})}),(0,e.jsx)("div",{style:{flex:1},children:n})]})},toolBarRender:function(){return[(0,e.jsxs)(E.Z,{type:"primary",onClick:function(){m(!0)},children:[(0,e.jsx)(H.Z,{})," \u65B0\u5EFA"]},"primary1")]},params:{Pid:De},request:function(){var h=(0,C.Z)((0,s.Z)().mark(function i(n){var Z,y;return(0,s.Z)().wrap(function(B){for(;;)switch(B.prev=B.next){case 0:return Z=[],y=0,B.next=4,(0,R.lM)(n).then(function(ue){Z=ue.data.data,y=ue.data.total});case 4:return B.abrupt("return",{data:Z,success:!0,total:y});case 5:case"end":return B.stop()}},i)}));return function(i){return h.apply(this,arguments)}}(),columns:ae}),(P==null?void 0:P.length)>0&&(0,e.jsxs)($.Z,{extra:(0,e.jsxs)("div",{children:["\u5DF2\u9009\u62E9"," ",(0,e.jsx)("a",{style:{fontWeight:600},children:P.length})," ","\u9879 \xA0\xA0",(0,e.jsxs)("span",{children:["\u670D\u52A1\u8C03\u7528\u6B21\u6570\u603B\u8BA1 ",P.reduce(function(h,i){return h+i.callNo},0)," \u4E07"]})]}),children:[(0,e.jsx)(E.Z,{onClick:(0,C.Z)((0,s.Z)().mark(function h(){var i,n;return(0,s.Z)().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return y.next=2,pe(P);case 2:Fe([]),(i=k.current)===null||i===void 0||(n=i.reloadAndRest)===null||n===void 0||n.call(i);case 4:case"end":return y.stop()}},h)})),children:"\u6279\u91CF\u5220\u9664"}),(0,e.jsx)(E.Z,{type:"primary",children:"\u6279\u91CF\u5BA1\u6279"})]}),(0,e.jsx)(de,{treeDatas:[{key:"0",parentId:"0",title:"\u9876\u7EA7",value:"0",children:ee}],onFinish:function(){var h=(0,C.Z)((0,s.Z)().mark(function i(n){var Z;return(0,s.Z)().wrap(function(F){for(;;)switch(F.prev=F.next){case 0:if(Z=!1,!n.id){F.next=7;break}return F.next=4,he(n);case 4:Z=F.sent,F.next=10;break;case 7:return F.next=9,ce(n);case 9:Z=F.sent;case 10:Z&&(m(!1),k.current&&((0,R.FM)().then(function(B){re(B.data)}),k.current.reload()));case 11:case"end":return F.stop()}},i)}));return function(i){return h.apply(this,arguments)}}(),onCancel:function(){m(!1),z({})},modalVisible:c,values:Ze||{}}),(0,e.jsx)(b.Z,{width:600,visible:je,onClose:function(){xe(void 0),Ce(!1)},closable:!1,children:(S==null?void 0:S.name)&&(0,e.jsx)(o.ZP,{column:2,title:S==null?void 0:S.name,request:(0,C.Z)((0,s.Z)().mark(function h(){return(0,s.Z)().wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.abrupt("return",{data:S||{}});case 1:case"end":return n.stop()}},h)})),params:{id:S==null?void 0:S.name},columns:ae})})]})},fe=me},3408:function(ne,V,r){"use strict";r.d(V,{lM:function(){return L},IH:function(){return Y},mm:function(){return K},eP:function(){return v},FM:function(){return G}});var j=r(39428),b=r(11849),T=r(3182),E=r(48971);function L(u,o){return w.apply(this,arguments)}function w(){return w=(0,T.Z)((0,j.Z)().mark(function u(o,A){return(0,j.Z)().wrap(function(W){for(;;)switch(W.prev=W.next){case 0:return W.abrupt("return",(0,E.WY)("/kitchen/api/sysOrg\u200B/page",{method:"GET",params:(0,b.Z)({},o)}));case 1:case"end":return W.stop()}},u)})),w.apply(this,arguments)}function Y(u){return M.apply(this,arguments)}function M(){return M=(0,T.Z)((0,j.Z)().mark(function u(o){return(0,j.Z)().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",(0,E.WY)("/kitchen/api/sysOrg/add",{method:"POST",data:(0,b.Z)({},o)}));case 1:case"end":return t.stop()}},u)})),M.apply(this,arguments)}function x(u){return s.apply(this,arguments)}function s(){return s=_asyncToGenerator(_regeneratorRuntime().mark(function u(o){return _regeneratorRuntime().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",request("\u200B/kitchen/api\u200B/sysOrg\u200B/list",{method:"POST",data:_objectSpread({},o)}));case 1:case"end":return t.stop()}},u)})),s.apply(this,arguments)}function K(u){return U.apply(this,arguments)}function U(){return U=(0,T.Z)((0,j.Z)().mark(function u(o){return(0,j.Z)().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",(0,E.WY)("\u200B/kitchen/api\u200B/sysOrg\u200B/delete",{method:"POST",data:(0,b.Z)({},o)}));case 1:case"end":return t.stop()}},u)})),U.apply(this,arguments)}function v(u){return C.apply(this,arguments)}function C(){return C=(0,T.Z)((0,j.Z)().mark(function u(o){return(0,j.Z)().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",(0,E.WY)("\u200B/kitchen/api\u200B/sysOrg\u200B/edit",{method:"POST",data:(0,b.Z)({},o)}));case 1:case"end":return t.stop()}},u)})),C.apply(this,arguments)}function H(u){return p.apply(this,arguments)}function p(){return p=_asyncToGenerator(_regeneratorRuntime().mark(function u(o){return _regeneratorRuntime().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",request("/kitchen\u200B/api\u200B/sysOrg\u200B/detail",{method:"POST",data:_objectSpread({},o)}));case 1:case"end":return t.stop()}},u)})),p.apply(this,arguments)}function G(u){return $.apply(this,arguments)}function $(){return $=(0,T.Z)((0,j.Z)().mark(function u(o){return(0,j.Z)().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",(0,E.WY)("\u200B/kitchen/api\u200B/sysOrg\u200B/tree",{data:(0,b.Z)({},o)}));case 1:case"end":return t.stop()}},u)})),$.apply(this,arguments)}}}]);