Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

p__card__storedValueCard.cf7f16b7.async.js 11 KiB

1 ano atrás
1
  1. (self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[478,7975,1322],{59842:function(){},66050:function(H,I,a){"use strict";var G=a(11849),n=a(48971);I.Z={GetAllStore:function(){return(0,n.WY)("/kitchen/api/StoreHelper/GetAllStore",{method:"GET",headers:{TenantId:""}})},GetMemberListByPage:function(e){return(0,n.WY)("/kitchen/api/member/member-page-query",{method:"POST",data:e})},OnBindMember:function(e){return(0,n.WY)("/kitchen/api/member/member-binding-cards",{method:"POST",data:e})},GetMemberAccountCardConsRecord:function(e){return(0,n.WY)("/kitchen/api/member/member-account-amount-page",{method:"POST",data:e})},GetMemberAccountRecordTotal:function(e){return(0,n.WY)("/kitchen/api/member/member-account-record-total",{method:"POST",data:e})},AddGate:function(e){return(0,n.WY)("/kitchen/api/GateInfo/add",{method:"POST",data:e})},EnableGate:function(e){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return(0,n.WY)("/kitchen/api/GateInfo/Enable",{method:"POST",data:e,headers:{TenantId:l}})},GetGateListByStorePage:function(e,l,C){var _=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"";return(0,n.WY)("/kitchen/api/GateInfo/gatelist?StoreId=".concat(e,"&Current=").concat(l,"&PageSize=").concat(C),{method:"GET",headers:{TenantId:_}})},GetGateListByStorePageNew:function(e,l,C){var _=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"";return(0,n.WY)("/kitchen/api/one-card/gate-list?StoreId=".concat(e,"&Current=").concat(l,"&PageSize=").concat(C),{method:"GET",headers:{TenantId:_}})},GetGateListByStoreList:function(e){return(0,n.WY)("/kitchen/api/GateInfo/gatealllist?StoreId=".concat(e),{method:"GET"})},UpdateGateInfo:function(e){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return(0,n.WY)("/kitchen/api/GateInfo/Update",{method:"POST",data:e,headers:{TenantId:l}})},UpdateGateInfoNew:function(e){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return(0,n.WY)("/kitchen/api/one-card",{method:"PUT",data:e,headers:{TenantId:l}})},PayCardAdd:function(e){return(0,n.WY)("/kitchen/api/PayCard/add",{method:"POST",data:e})},PayCardEnable:function(e){return(0,n.WY)("/kitchenapi/PayCard/enable",{method:"POST",data:e})},PayCardByGateId:function(e,l,C){return(0,n.WY)("/kitchen/api/PayCard/gateList?GateId=".concat(e,"&Current=").concat(l,"&PageSize=").concat(C),{method:"GET"})},UpdatePayCardInfo:function(e){return(0,n.WY)("/kitchen/api/PayCard/update",{method:"POST",data:e})},GetCosRequestURL:function(e){return(0,n.WY)("/kitchen/api/systemconfig/GetCosRequestSignURL",{method:"POST",data:e})},GetMemberAccountPageList:function(e){return(0,n.WY)("/kitchen/api/member/member-account-page-list",{method:"POST",data:e})},UpdateMemberAccountStatus:function(e){return(0,n.WY)("/kitchen/api/member/member-account-status",{method:"POST",data:e})},GetMemberCardPageList:function(e){return(0,n.WY)("/kitchen/api/member/mmenber-card-page",{method:"POST",data:e})},AddMemberCard:function(e){return(0,n.WY)("/kitchen/api/member/mmenber-card",{method:"POST",data:e})},UpdateMemberCardState:function(e){return(0,n.WY)("/kitchen/api/member/mmenber-card-state",{method:"PUT",data:e})},GetDicList:function(e){return(0,n.WY)("/kitchen/api/dict-data/dic-list/".concat(e),{method:"Get"})},AddGateSetUp:function(e){return(0,n.WY)("/kitchen/api/GateInfo/AddGateSetUp",{method:"POST",data:e})},GetFoodList:function(e){return(0,n.WY)("/kitchen/api/dict-data/dic-list/".concat(e),{method:"Get"})},AddGateFood:function(e){return(0,n.WY)("/kitchen/api/GateInfo/AddGateFood",{method:"POST",data:e})},GetGoodsByMenuIdPage:function(e){return(0,n.WY)("/kitchen/api/FoodMenu/GetGoodsByMenuIdPage",{method:"POST",data:(0,G.Z)({},e)})}}},95510:function(H,I,a){"use strict";a.r(I);var G=a(57338),n=a(273),s=a(11849),e=a(71194),l=a(50146),C=a(43358),_=a(34041),Be=a(47673),y=a(4107),Te=a(57663),S=a(71577),ve=a(94233),W=a(51890),f=a(39428),Ae=a(34792),E=a(48086),g=a(3182),De=a(9715),p=a(55843),m=a(2824),h=a(67294),V=a(59842),J=a.n(V),Q=a(78009),Z=a(89366),R=a(49101),L=a(16894),b=a(66050),t=a(85893),X=function(){var O=(0,h.useRef)(),q=p.Z.useForm(),ee=(0,m.Z)(q,1),B=ee[0],te=(0,h.useState)(!1),U=(0,m.Z)(te,2),ae=U[0],M=U[1],ne=(0,h.useState)({id:""}),j=(0,m.Z)(ne,2),x=j[0],T=j[1],re=(0,h.useState)(1),K=(0,m.Z)(re,2),ye=K[0],se=K[1],de=(0,h.useState)(10),F=(0,m.Z)(de,2),ue=F[0],We=F[1],ie=(0,h.useState)(0),Y=(0,m.Z)(ie,2),Ze=Y[0],Re=Y[1],oe=(0,h.useState)(!1),k=(0,m.Z)(oe,2),le=k[0],v=k[1],_e=(0,h.useState)(1),z=(0,m.Z)(_e,2),Le=z[0],ce=z[1],me=(0,h.useState)(10),N=(0,m.Z)(me,2),he=N[0],Ue=N[1],Pe=(0,h.useState)(0),w=(0,m.Z)(Pe,2),je=w[0],fe=w[1],Ee=(0,h.useState)([]),$=(0,m.Z)(Ee,2),A=$[0],D=$[1],pe=function(r){B.setFieldsValue(r),T(r),M(!0)},Ce=function(){B.resetFields(),T({id:""}),M(!0)},be=function(r){v(!0),T(r),D([]),r.memberInfoId&&D([r.memberInfoId])},Me=function(){var u=(0,g.Z)((0,f.Z)().mark(function r(){var d;return(0,f.Z)().wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(A.length!==0){o.next=3;break}return E.default.info("\u8BF7\u9009\u62E9\u8981\u7ED1\u5B9A\u7684\u4F1A\u5458"),o.abrupt("return");case 3:return o.next=5,b.Z.OnBindMember({memberInfoId:A[0],memberCardId:x.id});case 5:d=o.sent,d.data===!0?(E.default.success("\u7ED1\u5B9A\u6210\u529F"),O.current.reload(),v(!1)):E.default.error("\u7ED1\u5B9A\u5931\u8D25");case 7:case"end":return o.stop()}},r)}));return function(){return u.apply(this,arguments)}}(),xe=function(r){console.log("\u5220\u9664",r)},Ie=function(){var u=(0,g.Z)((0,f.Z)().mark(function r(d){var c,o;return(0,f.Z)().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:if(!d.id){P.next=7;break}return P.next=3,b.Z.UpdateMemberCardState({id:d.id,type:d.type,state:d.state});case 3:c=P.sent,c.statusCode===200?(E.default.success("\u66F4\u65B0\u6210\u529F"),M(!1),O.current.reload()):E.default.error(c.errors||"\u66F4\u65B0\u50A8\u503C\u5361\u5931\u8D25"),P.next=11;break;case 7:return P.next=9,b.Z.AddMemberCard({type:d.type,state:d.state});case 9:o=P.sent,o.statusCode===200?(E.default.success("\u6DFB\u52A0\u6210\u529F"),M(!1),O.current.reload()):E.default.error(o.errors||"\u6DFB\u52A0\u50A8\u503C\u5361\u5931\u8D25");case 11:case"end":return P.stop()}},r)}));return function(d){return u.apply(this,arguments)}}(),ge=[{title:"\u5361\u53F7",dataIndex:"cardNum",ellipsis:!0},{title:"\u4F1A\u5458\u540D\u79F0",dataIndex:"memberName",ellipsis:!0,hideInSearch:!0},{title:"\u4F1A\u5458\u5934\u50CF",dataIndex:"headImgUrl",ellipsis:!0,width:100,align:"center",hideInSearch:!0,render:function(r,d){return(0,t.jsx)(W.C,{size:64,shape:"square",icon:(0,t.jsx)(Z.Z,{}),src:d.headImgUrl})}},{title:"\u4F1A\u5458\u7535\u8BDD",dataIndex:"phone",ellipsis:!0,hideInSearch:!0},{title:"\u72B6\u6001",dataIndex:"state",valueType:"select",hideInSearch:!0,valueEnum:{0:{text:"\u7981\u7528",status:"Error"},1:{text:"\u6B63\u5E38",status:"Success"},2:{text:"\u6302\u5931",status:"Error"},3:{text:"\u4F5C\u5E9F",status:"Error"}}},{title:"\u7C7B\u578B",dataIndex:"type",valueType:"select",hideInSearch:!0,valueEnum:{1:{text:"\u4EBA\u8138",status:"Success"},2:{text:"\u5B9E\u4F53\u5361",status:"Success"},3:{text:"\u6307\u7EB9",status:"Success"}}},{title:"\u64CD\u4F5C",valueType:"option",key:"option",render:function(r,d,c,o){return[(0,t.jsx)("a",{onClick:function(){return pe(d)},children:"\u7F16\u8F91"}),(0,t.jsx)("a",{onClick:function(){return be(d)},children:"\u7ED1\u5B9A\u4F1A\u5458"})]}}],Oe={onChange:function(r){D(r)},selectedRowKeys:A},Se=[{title:"\u4F1A\u5458\u5934\u50CF",dataIndex:"headImgUrl",ellipsis:!0,width:100,align:"center",hideInSearch:!0,render:function(r,d){return(0,t.jsx)(W.C,{size:64,shape:"square",icon:(0,t.jsx)(Z.Z,{}),src:d.headImgUrl})}},{title:"\u771F\u5B9E\u59D3\u540D",dataIndex:"realName",ellipsis:!0},{title:"\u8054\u7CFB\u65B9\u5F0F",dataIndex:"phone",ellipsis:!0}];return(0,t.jsx)(Q.ZP,{children:(0,t.jsxs)("div",{className:J().member_card_container,children:[(0,t.jsx)(L.ZP,{columns:ge,actionRef:O,request:function(){var u=(0,g.Z)((0,f.Z)().mark(function r(d){var c;return(0,f.Z)().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,b.Z.GetMemberCardPageList(d);case 2:return c=i.sent,i.abrupt("return",{data:c.data.data,success:!0,total:c.data.total});case 4:case"end":return i.stop()}},r)}));return function(r){return u.apply(this,arguments)}}(),cardBordered:!0,editable:{type:"multiple"},rowKey:"id",options:{setting:{listsHeight:400}},pagination:{pageSize:ue,onChange:function(r){return se(r)}},dateFormatter:"string",headerTitle:"\u50A8\u503C\u5361\u7BA1\u7406",toolBarRender:function(){return[(0,t.jsx)(S.Z,{icon:(0,t.jsx)(R.Z,{}),type:"primary",onClick:Ce,children:"\u65B0\u5EFA"},"button")]}}),(0,t.jsx)(l.Z,{width:600,title:x.id?"\u7F16\u8F91\u50A8\u503C\u5361":"\u6DFB\u52A0\u50A8\u503C\u5361",visible:ae,footer:!1,onCancel:function(){return M(!1)},children:(0,t.jsxs)(p.Z,{name:"basic",onFinish:Ie,form:B,labelCol:{span:4},children:[(0,t.jsx)(p.Z.Item,{label:"id",name:"id",hidden:!0,children:(0,t.jsx)(y.Z,{})}),(0,t.jsx)(p.Z.Item,{label:"\u5361\u53F7",name:"cardNum",children:(0,t.jsx)(y.Z,{disabled:!0})}),(0,t.jsx)(p.Z.Item,{label:"\u72B6\u6001",name:"state",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u9009\u62E9\u72B6\u6001\uFF01"}],children:(0,t.jsxs)(_.Z,{children:[(0,t.jsx)(_.Z.Option,{value:0,children:"\u7981\u7528"}),(0,t.jsx)(_.Z.Option,{value:1,children:"\u6B63\u5E38"}),(0,t.jsx)(_.Z.Option,{value:2,children:"\u6302\u5931"}),(0,t.jsx)(_.Z.Option,{value:3,children:"\u4F5C\u5E9F"})]})}),(0,t.jsx)(p.Z.Item,{label:"\u7C7B\u578B",name:"type",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u7C7B\u578B\uFF01"}],children:(0,t.jsxs)(_.Z,{children:[(0,t.jsx)(_.Z.Option,{value:1,children:"\u4EBA\u8138"}),(0,t.jsx)(_.Z.Option,{value:2,children:"\u5B9E\u4F53\u5361"}),(0,t.jsx)(_.Z.Option,{value:3,children:"\u6307\u7EB9"})]})}),(0,t.jsx)(p.Z.Item,{children:(0,t.jsx)(S.Z,{type:"primary",htmlType:"submit",children:"\u786E\u5B9A"})})]})}),(0,t.jsx)(n.Z,{width:600,title:"\u7ED1\u5B9A\u4F1A\u5458",placement:"right",onClose:function(){return v(!1)},visible:le,children:(0,t.jsx)(L.ZP,{toolBarRender:function(){return[(0,t.jsx)(S.Z,{icon:(0,t.jsx)(R.Z,{}),type:"primary",onClick:Me,children:"\u786E\u5B9A\u7ED1\u5B9A"},"button")]},rowSelection:(0,s.Z)({type:"radio"},Oe),columns:Se,cardBordered:!0,request:(0,g.Z)((0,f.Z)().mark(function u(){var r,d,c=arguments;return(0,f.Z)().wrap(function(i){for(;;)switch(i.prev=i.next){case 0:return r=c.length>0&&c[0]!==void 0?c[0]:{},i.next=3,b.Z.GetMemberListByPage(r);case 3:if(d=i.sent,d.statusCode!==200){i.next=7;break}return fe(d.data.total),i.abrupt("return",{data:d.data.data,success:!0,total:d.data.total});case 7:case"end":return i.stop()}},u)})),rowKey:"id",search:{labelWidth:"auto"},pagination:{pageSize:he,onChange:function(r){return ce(r)}},dateFormatter:"string",headerTitle:"\u4F1A\u5458\u5217\u8868"})})]})})};I.default=X}}]);