p__Login.18f9f3ea.async.js 6.1 KB

1
  1. (self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[57],{10603:function(l,i,a){"use strict";a.r(i);var v=a(57663),r=a(71577),C=a(9715),c=a(903),g=a(47673),n=a(40305),y=a(67294),p=a(42285),h=a(58654),o=a(85893),f=function(){var _=(0,p.tT)("@@initialState"),D=_.refresh,E=function(u){console.log("Success:",u),T(u)},S=function(u){console.log("Failed:",u)},T=function(u){var j=u;(0,h.x4)(j).then(function(O){var t=O||{};t.result==="success"?(localStorage.setItem("token",t.token),p.m8.push("/equipment"),D()):localStorage.removeItem("token")}).catch(function(){})};return(0,o.jsxs)("div",{className:"homeContent",children:[(0,o.jsx)("div",{className:"home-left",children:(0,o.jsxs)("div",{className:"box",children:[(0,o.jsx)("img",{alt:"",src:a(9854)}),(0,o.jsx)("div",{className:"logo-text",children:"SagaCare"})]})}),(0,o.jsx)("div",{className:"home-right",children:(0,o.jsx)("div",{className:"box",children:(0,o.jsxs)(c.Z,{name:"basic",labelCol:{span:8},wrapperCol:{span:64},style:{maxWidth:600},initialValues:{remember:!0,username:"",password:""},onFinish:E,onFinishFailed:S,autoComplete:"off",children:[(0,o.jsx)(c.Z.Item,{label:"\u7528\u6237\u540D",name:"username",rules:[{required:!0,message:"Please input your username!"}],children:(0,o.jsx)(n.Z,{})}),(0,o.jsx)(c.Z.Item,{label:"\u5BC6\u7801",name:"password",rules:[{required:!0,message:"Please input your password!"}],children:(0,o.jsx)(n.Z.Password,{})}),(0,o.jsx)(c.Z.Item,{wrapperCol:{offset:8,span:16},children:(0,o.jsx)(r.Z,{type:"primary",htmlType:"submit",className:"loginButton",children:"\u63D0\u4EA4"})})]})})})]})};i.default=f},58654:function(l,i,a){"use strict";a.d(i,{WN:function(){return y},nZ:function(){return p},F6:function(){return h},K0:function(){return o},NR:function(){return f},LS:function(){return I},SK:function(){return _},mr:function(){return E},U9:function(){return S},YC:function(){return T},fh:function(){return m},mq:function(){return u},RX:function(){return j},x4:function(){return O}});var v=a(11849),r=a(42285),C=a(60607),c=a(69874);function g(){var t=C.T.projectId;return t}function n(){var t=c.Z.getInstance(),e=t.getUser(),d="sgadmin";return"openid=".concat(e.id,"&pubname=").concat(d,"&projectId=").concat(g(),"&userId=").concat(e.id,"&userName=").concat(e.name,"&userPhone=").concat(e.phone)}var y=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/object/eqp/infocode/set?".concat(n()),{method:"POST",from:"sagacare",isNotShowErrorToast:!0,errorSave:!0,data:JSON.stringify(e),headers:{"Content-Type":"application/json"}})},p=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/object/objectDataEqpGroup/query?".concat(n()),{method:"POST",from:"sagacare",isNotShowErrorToast:!0,errorSave:!0,data:JSON.stringify(e),headers:{"Content-Type":"application/json"}})},h=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/ctrl/queryEquipmentStatusInfo?".concat(n(),"&spaceId=").concat(e.spaceId,"&equipType=").concat(e.equipType),{skipErrorHandler:!0,method:"GET",from:"sagacare",headers:{"Content-Type":"application/json"}})},o=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/ctrl/set?".concat(n()),{method:"POST",from:"sagacare",isNotShowErrorToast:!0,errorSave:!0,data:JSON.stringify(e),headers:{"Content-Type":"application/json"}})},f=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/light/status/query?".concat(n(),"&spaceId=").concat(e),{skipErrorHandler:!0,method:"GET",from:"sagacare",headers:{"Content-Type":"application/json"}})},I=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/ctrl/set?".concat(n()),{method:"POST",isNotShowErrorToast:!0,errorSave:!0,from:"sagacare",data:JSON.stringify(e),headers:{"Content-Type":"application/json"}})},_=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/light/onoff/set?".concat(n()),{method:"POST",isNotShowErrorToast:!0,errorSave:!0,from:"sagacare",data:JSON.stringify(e),headers:{"Content-Type":"application/json"}})},D=function(e){return request("/sgadmin/duoduo-service/duoduoenv-service/light/onoff/setSatus?".concat(n()),{method:"POST",isNotShowErrorToast:!0,errorSave:!0,from:"sagacare",data:JSON.stringify(e),headers:{"Content-Type":"application/json"}})},E=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/custom/feedback/documents?".concat(n()),{isNotShowErrorToast:!0,errorSave:!0,from:"sagacare",method:"POST",data:JSON.stringify(e),headers:{"Content-Type":"application/json"}})},S=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/custom/feedbackCreate/v2?".concat(n()),{method:"POST",from:"sagacare",isNotShowErrorToast:!0,errorSave:!0,data:JSON.stringify((0,v.Z)((0,v.Z)({},e),{},{projectId:g()})),headers:{"Content-Type":"application/json"}})},T=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/space/property?".concat(n()),{method:"POST",from:"sagacare",isNotShowErrorToast:!0,data:e,headers:{"Content-Type":"application/json"}})},m=function(e){return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/custom/feedbackCreate/v2Batch?".concat(n()),{method:"POST",skipErrorHandler:!0,from:"sagacare",isNotShowErrorToast:!1,data:e,headers:{"Content-Type":"application/json"}})},u=function(e){var d=c.Z.getInstance(),s=d.getUser(),P="sgadmin",M="openid=".concat(s.id,"&pubname=").concat(P,"&projectId=Pj1101080255&userId=").concat(s.id,"&userName=").concat(s.name,"&userPhone=").concat(s.phone);return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/ctrl/querySpaceConditioners?".concat(n(),"&spaceId=").concat(e.spaceId),{from:"sagacare",method:"GET",headers:{"Content-Type":"application/json"}})},j=function(e){var d=c.Z.getInstance(),s=d.getUser(),P="sgadmin",M="openid=".concat(s.id,"&pubname=").concat(P,"&projectId=Pj1101080255&userId=").concat(s.id,"&userName=").concat(s.name,"&userPhone=").concat(s.phone);return(0,r.WY)("/sgadmin/duoduo-service/duoduoenv-service/ctrl/set?".concat(n()),{method:"POST",from:"sagacare",data:e,headers:{"Content-Type":"application/json"}})},O=function(e){return(0,r.WY)("/sgadmin/server/login",{method:"POST",data:e,headers:{"Content-Type":"application/json"}})}},9854:function(l,i,a){l.exports=a.p+"static/sagalogo.e7a1bb33.svg"}}]);