Files
FBSAdminTool/build/static/js/7.d6ae30a5.chunk.js

2 lines
5.4 KiB
JavaScript
Raw Normal View History

2022-06-17 17:06:20 +05:30
(this["webpackJsonp@coreui/coreui-free-react-admin-template"]=this["webpackJsonp@coreui/coreui-free-react-admin-template"]||[]).push([[7],{768:function(e,t,c){"use strict";c.r(t);var n=c(653),s=c.n(n),r=c(654),i=c(651),a=c(1),o=c(638),l=c.n(o),j=c(633),u=c(632),b=c(711),d=c.n(b),h=(c(710),c(17));t.default=function(){var e="https://openshield.ts.bizside.biz",t=Object(a.useState)([]),c=Object(i.a)(t,2),n=c[0],o=c[1],b=Object(a.useState)(""),x=Object(i.a)(b,2),O=x[0],p=x[1],m=Object(a.useState)(""),f=Object(i.a)(m,2),g=f[0],v=f[1],k=Object(a.useState)(!1),y=Object(i.a)(k,2),S=y[0],_=y[1],C=Object(a.useState)(null),w=Object(i.a)(C,2),z=w[0],M=w[1],D=Object(a.useState)([]),F=Object(i.a)(D,2),H=F[0],B=F[1],L=Object(a.useState)(""),N=Object(i.a)(L,2),T=N[0],E=N[1];function J(e){var t=String(e.getDate()).padStart(2,"0"),c=String(e.getMonth()+1).padStart(2,"0");return e.getFullYear()+"-"+c+"-"+t}function I(){if(console.log(K()),console.log(T),""!=O&&""!=g){var t="";null!==z?(t=S?e+"/generate"+O+"?construction_id="+g+"&construction_date="+J(z)+"&graph=true":e+"/generate"+O+"?construction_id="+g+"&construction_date="+J(z),E(t)):E(t=S?e+"/generate"+O+"?construction_id="+g+"&graph=true":e+"/generate"+O+"?construction_id="+g)}else alert("\u5efa\u8a2d\u3068\u30ec\u30dd\u30fc\u30c8\u306e\u4e21\u65b9\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044")}function K(){return!1===Y()&&""!==O&&""!==g||null!==z}function Y(){return"BoxDisplacement"===O||"MachineControl"===O||"MachineSheet"===O}return Object(a.useEffect)((function(){function e(){return(e=Object(r.a)(s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,l()("https://openshield.ts.bizside.biz/getConstructionList");case 2:t=e.sent,o(t.data);case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}!function(){e.apply(this,arguments)}()}),[]),Object(a.useEffect)((function(){function e(){return(e=Object(r.a)(s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(""===g||""===O||1!=Y()){e.next=5;break}return e.next=3,l()("https://openshield.ts.bizside.biz/getDateToHaveData?construction_id="+g+"&sheetname="+O);case 3:t=e.sent,B(t.data.record);case 5:case"end":return e.stop()}}),e)})))).apply(this,arguments)}!function(){e.apply(this,arguments)}()}),[O,g]),Object(h.jsxs)(j.K,{children:[Object(h.jsx)(j.k,{xs:"12",sm:"12",md:"12",children:Object(h.jsxs)(j.f,{children:[Object(h.jsx)(j.j,{children:"\u30ec\u30dd\u30fc\u30c8"}),Object(h.jsxs)(j.g,{children:[Object(h.jsxs)(j.L,{custom:!0,name:"cons_select",id:"cons_select",onChange:function(e){v(e.target.value),M(null),E("")},children:['" ',Object(h.jsx)("option",{value:"",children:"-- \u5de5\u4e8b\u540d --"}),'"+',n.map((function(e,t){return Object(h.jsx)("option",{value:e.construction_id,children:e.construction_name},e.construction_id)}))]}),Object(h.jsxs)(j.f,{children:[Object(h.jsx)(j.g,{children:Object(h.jsxs)(j.s,{action:"",method:"post",encType:"multipart/form-data",className:"form-horizontal",children:[Object(h.jsxs)(j.t,{row:!0,children:[Object(h.jsx)(j.k,{md:"3",children:Object(h.jsx)(j.H,{htmlFor:"select",children:"\u30ec\u30dd\u30fc\u30c8\u7a2e\u985e"})}),Object(h.jsx)(j.k,{xs:"12",md:"9",children:Object(h.jsxs)(j.L,{custom:!0,name:"select",id:"select",onChange:function(e){p(e.target.value),M(null),E("")},value:O,children:[Object(h.jsx)("option",{value:"",children:"-- \u30ec\u30dd\u30fc\u30c8\u7a2e\u985e --"}),Object(h.jsx)("option",{value:"BoxDisplacement",children:"\u51fd\u4f53\u5909\u4f4d\u8868"}),Object(h.jsx)("option",{value:"MachineControl",children:"\u30aa\u30fc\u30d7\u30f3\u30b7\u30fc\u30eb\u30c9\u30de\u30b7\u30f3\u7ba1\u7406\u65e5\u5831"}),Object(h.jsx)("option",{value:"Measurement",children:"\u51fd\u5e95\u9ad8\u30fb\u504f\u4f4d\u91cf\u6e2c\u5b9a\u4e00\u89a7\u8868"}),Object(h.jsx)("option",{value:"CheckSheet",children:"\u5de5\u7a0b\u5185\u691c\u67fb\u8868"}),Object(h.jsx)("option",{value:"Injection",children:"\u88cf\u8fbc\u6ce8\u5165\u6750\u6599\u53d7\u6255\u3044\u7c3f"})]})})]}),!0===Y()?Object(h.jsxs)(j.t,{row:!0,
//# sourceMappingURL=7.d6ae30a5.chunk.js.map