You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2 lines
1.7 MiB
2 lines
1.7 MiB
2 years ago
|
/*! For license information please see 26.a7de5213.chunk.js.LICENSE.txt */
|
||
|
(this["webpackJsonpsimpro-web"]=this["webpackJsonpsimpro-web"]||[]).push([[26,4,8],{2319:function(e,t,n){"use strict";n.r(t);var r=n(607),a=n(618),o=(n(719),n(2)),i=n.n(o),s=n(822),c=n(792),l=n(793),u=n(827),f=n(828),d=n(783),h=n(817),p=n(814),m=n(815),g=n(816),v=n(757),b=n(663),y=(n(739),n(597),n(431),b.default.Option,function(e){var t=e.openDialog,n=e.closeDialog,r=e.toggleDialog,b=e.typeDialog,y=e.dataEdit,w=Object(o.useState)(0),E=Object(a.a)(w,2),C=E[0],O=E[1],S=Object(o.useState)(""),x=Object(a.a)(S,2),_=x[0],k=x[1],A=Object(o.useState)(""),T=Object(a.a)(A,2),N=(T[0],T[1]),B=Object(o.useState)(""),I=Object(a.a)(B,2),R=I[0],P=I[1],D=Object(o.useState)(),j=Object(a.a)(D,2),M=(j[0],j[1]);Object(o.useEffect)((function(){"Edit"===b?(console.log("cel data Edit",y),O(y.id),P(y.description),M(y.unit_price),N(y.uom),k(y.name)):O(0)}),[y,t]);return i.a.createElement(i.a.Fragment,null,i.a.createElement(h.a,{size:"lg",isOpen:t,toggle:r},i.a.createElement(p.a,{className:"capitalize",toggle:n},"Save"==b?"Add":"Edit"," Resource"),i.a.createElement(m.a,null,i.a.createElement(s.a,null,i.a.createElement(c.a,null,i.a.createElement(l.a,{md:6},i.a.createElement(u.a,null,i.a.createElement(f.a,{className:"capitalize"},"Project Type"),i.a.createElement(d.a,{type:"text",value:_,onChange:function(e){return k(e.target.value)},placeholder:"Input material name..."}))),i.a.createElement(l.a,{md:6},i.a.createElement(u.a,null,i.a.createElement(f.a,{className:"capitalize"},"Description"),i.a.createElement(d.a,{row:"4",type:"textarea",value:R,onChange:function(e){return P(e.target.value)},placeholder:"Description ..."})))))),i.a.createElement(g.a,null,i.a.createElement(v.a,{color:"primary",onClick:function(){return"Save"===b?n("save",{name:_,description:R}):n("edit",{id:C,name:_,description:R}),O(0),void P("")}},b)," ",i.a.createElement(v.a,{className:"capitalize",color:"secondary",onClick:function(){return n("cancel","none"),O(0),void P("")}},"Batal"))))}),w=n(737),E=n(642),C=n(861),O=n(695),S=n(665),x=n.n(S),_=n(630),k=n(762),A=function(e){var t=e.openDialog,n=e.closeDialog,r=e.toggleDialog,c=e.typeDialog,l=e.dataEdit,b=e.idActivity,y=e.projectTypeId,w=Object(o.useState)(0),E=Object(a.a)(w,2),C=E[0],O=E[1],S=Object(o.useState)(""),x=Object(a.a)(S,2),_=x[0],k=x[1];Object(o.useEffect)((function(){"edit"===c?(O(l.id),k(l.name_activity)):(O(0),k(""))}),[l,t]);return i.a.createElement(i.a.Fragment,null,i.a.createElement(h.a,{isOpen:t,toggle:r},i.a.createElement(p.a,{className:"capitalize",toggle:n},"add"==c?"Add":"Edit"," Activity"),i.a.createElement(m.a,null,i.a.createElement(s.a,null,i.a.createElement(u.a,null,i.a.createElement(f.a,{className:"capitalize"},"Activity"),i.a.createElement(d.a,{row:"4",type:"textarea",value:_,onChange:function(e){return k(e.target.value)},placeholder:"Persiapan ..."})))),i.a.createElement(g.a,null,i.a.createElement(v.a,{className:"capitalize",color:"primary",onClick:function(){return function(){var e="";"add"===c?(e={name_activity:_,proyek_type_id:y},b&&b>0&&(e.parent_id=b),console.log("cek cek cek"),n("save",e)):(e={id:C,name_activity:_,proyek_type_id:y},b&&b>0&&(e.parent_id=b),console.log("cek cek cek 2"),n("edit",e)),O(0),k("")}()}},c)," ",i.a.createElement(v.a,{className:"capitalize",color:"secondary",onClick:function(){return n("cancel","none"),O(0),void k("")}},"Batal"))))};function T(){T=function(){return e};var e={},t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},a=r.iterator||"@@iterator",o=r.asyncIterator||"@@asyncIterator",i=r.toStringTag||"@@toStringTag";function s(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(_){s=function(e,t,n){return e[t]=n}}function c(e,t,n,r){var a=t&&t.prototype instanceof f?t:f,o=Object.create(a.prototype),i=new O(r||[]);return o._invoke=function(e,t,n){var r="suspendedStart";return function(a,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw o;return x()}for(n.method=a,n.arg=o;;){var i=n.delegate;if(i){var s=w(i,n);if(s){if(
|