⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.1
Server IP:
185.238.29.86
Server:
Linux server2 6.8.12-6-pve #1 SMP PREEMPT_DYNAMIC PMX 6.8.12-6 (2024-12-19T19:05Z) x86_64
Server Software:
nginx/1.18.0
PHP Version:
8.1.31
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
var
/
www
/
qda-digital.online
/
public
/
dist
/
js
/
Edit File: 123.65fa59.js
/*! For license information please see 123.65fa59.js.LICENSE.txt */ (window.webpackJsonp=window.webpackJsonp||[]).push([[123],{499:function(t,e,o){"use strict";o.r(e);var r=o(4),a=o(5),n=o(3),l=o.n(n);function s(t){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(){i=function(){return t};var t={},e=Object.prototype,o=e.hasOwnProperty,r=Object.defineProperty||function(t,e,o){t[e]=o.value},a="function"==typeof Symbol?Symbol:{},n=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",c=a.toStringTag||"@@toStringTag";function m(t,e,o){return Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{m({},"")}catch(t){m=function(t,e,o){return t[e]=o}}function u(t,e,o,a){var n=e&&e.prototype instanceof d?e:d,l=Object.create(n.prototype),s=new N(a||[]);return r(l,"_invoke",{value:C(t,o,s)}),l}function f(t,e,o){try{return{type:"normal",arg:t.call(e,o)}}catch(t){return{type:"throw",arg:t}}}t.wrap=u;var v={};function d(){}function p(){}function h(){}var y={};m(y,n,(function(){return this}));var _=Object.getPrototypeOf,g=_&&_(_(P([])));g&&g!==e&&o.call(g,n)&&(y=g);var b=h.prototype=d.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){m(t,e,(function(t){return this._invoke(e,t)}))}))}function $(t,e){var a;r(this,"_invoke",{value:function(r,n){function l(){return new e((function(a,l){!function r(a,n,l,i){var c=f(t[a],t,n);if("throw"!==c.type){var m=c.arg,u=m.value;return u&&"object"==s(u)&&o.call(u,"__await")?e.resolve(u.__await).then((function(t){r("next",t,l,i)}),(function(t){r("throw",t,l,i)})):e.resolve(u).then((function(t){m.value=t,l(m)}),(function(t){return r("throw",t,l,i)}))}i(c.arg)}(r,n,a,l)}))}return a=a?a.then(l,l):l()}})}function C(t,e,o){var r="suspendedStart";return function(a,n){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw n;return A()}for(o.method=a,o.arg=n;;){var l=o.delegate;if(l){var s=S(l,o);if(s){if(s===v)continue;return s}}if("next"===o.method)o.sent=o._sent=o.arg;else if("throw"===o.method){if("suspendedStart"===r)throw r="completed",o.arg;o.dispatchException(o.arg)}else"return"===o.method&&o.abrupt("return",o.arg);r="executing";var i=f(t,e,o);if("normal"===i.type){if(r=o.done?"completed":"suspendedYield",i.arg===v)continue;return{value:i.arg,done:o.done}}"throw"===i.type&&(r="completed",o.method="throw",o.arg=i.arg)}}}function S(t,e){var o=e.method,r=t.iterator[o];if(void 0===r)return e.delegate=null,"throw"===o&&t.iterator.return&&(e.method="return",e.arg=void 0,S(t,e),"throw"===e.method)||"return"!==o&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+o+"' method")),v;var a=f(r,t.iterator,e.arg);if("throw"===a.type)return e.method="throw",e.arg=a.arg,e.delegate=null,v;var n=a.arg;return n?n.done?(e[t.resultName]=n.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,v):n:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,v)}function x(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function B(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(x,this),this.reset(!0)}function P(t){if(t){var e=t[n];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,a=function e(){for(;++r<t.length;)if(o.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return a.next=a}}return{next:A}}function A(){return{value:void 0,done:!0}}return p.prototype=h,r(b,"constructor",{value:h,configurable:!0}),r(h,"constructor",{value:p,configurable:!0}),p.displayName=m(h,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===p||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,h):(t.__proto__=h,m(t,c,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},w($.prototype),m($.prototype,l,(function(){return this})),t.AsyncIterator=$,t.async=function(e,o,r,a,n){void 0===n&&(n=Promise);var l=new $(u(e,o,r,a),n);return t.isGeneratorFunction(o)?l:l.next().then((function(t){return t.done?t.value:l.next()}))},w(b),m(b,c,"Generator"),m(b,n,(function(){return this})),m(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),o=[];for(var r in e)o.push(r);return o.reverse(),function t(){for(;o.length;){var r=o.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},t.values=P,N.prototype={constructor:N,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(B),!t)for(var e in this)"t"===e.charAt(0)&&o.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(o,r){return l.type="throw",l.arg=t,e.next=o,r&&(e.method="next",e.arg=void 0),!!r}for(var a=this.tryEntries.length-1;a>=0;--a){var n=this.tryEntries[a],l=n.completion;if("root"===n.tryLoc)return r("end");if(n.tryLoc<=this.prev){var s=o.call(n,"catchLoc"),i=o.call(n,"finallyLoc");if(s&&i){if(this.prev<n.catchLoc)return r(n.catchLoc,!0);if(this.prev<n.finallyLoc)return r(n.finallyLoc)}else if(s){if(this.prev<n.catchLoc)return r(n.catchLoc,!0)}else{if(!i)throw new Error("try statement without catch or finally");if(this.prev<n.finallyLoc)return r(n.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&o.call(a,"finallyLoc")&&this.prev<a.finallyLoc){var n=a;break}}n&&("break"===t||"continue"===t)&&n.tryLoc<=e&&e<=n.finallyLoc&&(n=null);var l=n?n.completion:{};return l.type=t,l.arg=e,n?(this.method="next",this.next=n.finallyLoc,v):this.complete(l)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),v},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var o=this.tryEntries[e];if(o.finallyLoc===t)return this.complete(o.completion,o.afterLoc),B(o),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var o=this.tryEntries[e];if(o.tryLoc===t){var r=o.completion;if("throw"===r.type){var a=r.arg;B(o)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,o){return this.delegate={iterator:P(t),resultName:e,nextLoc:o},"next"===this.method&&(this.arg=void 0),v}},t}function c(t,e,o,r,a,n,l){try{var s=t[n](l),i=s.value}catch(t){return void o(t)}s.done?e(i):Promise.resolve(i).then(r,a)}function m(t){return function(){var e=this,o=arguments;return new Promise((function(r,a){var n=t.apply(e,o);function l(t){c(n,r,a,l,s,"next",t)}function s(t){c(n,r,a,l,s,"throw",t)}l(void 0)}))}}function u(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),o.push.apply(o,r)}return o}function f(t,e,o){return(e=function(t){var e=function(t,e){if("object"!==s(t)||null===t)return t;var o=t[Symbol.toPrimitive];if(void 0!==o){var r=o.call(t,e||"default");if("object"!==s(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"===s(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}var v={middleware:["auth","check-permissions"],metaInfo:function(){return{title:this.$t("payroll.edit.page_title")}},data:function(){var t;return{breadcrumbsCurrent:"payroll.edit.breadcrumbs_current",breadcrumbs:[{name:"payroll.edit.breadcrumbs_first",url:"home"},{name:"payroll.edit.breadcrumbs_second",url:"payroll.index"},{name:"payroll.edit.breadcrumbs_active",url:""}],form:new a.a((t={chequeNo:"",salaryMonth:"",employee:"",account:""},f(t,"chequeNo",""),f(t,"presentSalary",""),f(t,"deductionAmount",""),f(t,"deductionReason",""),f(t,"mobileBill",""),f(t,"foodBill",""),f(t,"bonus",""),f(t,"commission",""),f(t,"advance",""),f(t,"festivalBonus",""),f(t,"travelAllowance",""),f(t,"others",""),f(t,"totalSalary",""),f(t,"salaryDate",""),f(t,"status",1),f(t,"note",""),f(t,"image",""),t)),url:null,accounts:""}},computed:function(t){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?u(Object(o),!0).forEach((function(e){f(t,e,o[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):u(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}({},Object(r.b)("operations",["items"])),created:function(){this.getEmployees(),this.getAccounts(),this.getPayroll()},methods:{getEmployees:function(){var t=this;return m(i().mark((function e(){return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.$store.dispatch("operations/allData",{path:"/api/all-employees"});case 2:case"end":return e.stop()}}),e)})))()},getAccounts:function(){var t=this;return m(i().mark((function e(){var o,r;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,l.a.get(window.location.origin+"/api/all-accounts");case 2:o=e.sent,r=o.data,t.accounts=r.data;case 5:case"end":return e.stop()}}),e)})))()},getPayroll:function(){var t=this;return m(i().mark((function e(){var o,r;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,l.a.get(window.location.origin+"/api/payroll/"+t.$route.params.slug);case 2:o=e.sent,r=o.data,t.form.chequeNo=r.data.chequeNo,t.form.salaryMonth=r.data.salaryMonth,t.form.employee=r.data.employee,t.form.account=r.data.account,t.form.availableBalance=r.data.account.availableBalance,t.form.presentSalary=r.data.employee.totalSalary,t.form.deductionAmount=r.data.deductionAmount,t.form.deductionReason=r.data.deductionReason,t.form.mobileBill=r.data.mobileBill,t.form.foodBill=r.data.foodBill,t.form.bonus=r.data.bonus,t.form.commission=r.data.commission,t.form.advance=r.data.advance,t.form.festivalBonus=r.data.festivalBonus,t.form.travelAllowance=r.data.travelAllowance,t.form.others=r.data.others,t.form.totalSalary=r.data.transaction.amount,t.form.salaryDate=r.data.salaryDate,t.form.note=r.data.note,t.form.status=r.data.status,t.url=r.data.image;case 25:case"end":return e.stop()}}),e)})))()},onFileChange:function(t){var e=this,o=t.target.files[0],r=new FileReader;o.size<2111775&&("image/jpeg"===o.type||"image/png"===o.type||"image/gif"===o.type)?(r.onloadend=function(t){e.form.image=r.result},r.readAsDataURL(o),this.url=URL.createObjectURL(o)):Swal.fire(this.$t("common.error"),this.$t("common.image_error"),"error")},calculateTotalSalary:function(){var t=Number(this.form.employee.totalSalary),e=Number(this.form.deductionAmount),o=Number(this.form.mobileBill),r=Number(this.form.foodBill),a=Number(this.form.bonus),n=Number(this.form.commission),l=Number(this.form.advance),s=Number(this.form.festivalBonus),i=Number(this.form.travelAllowance),c=Number(this.form.others);return this.form.totalSalary=o+r+a+n+s+i+c+l-e,t>0?this.form.totalSalary=t+this.form.totalSalary:this.form.totalSalary},updateBalance:function(){this.form.availableBalance=0,this.form.account&&(this.form.availableBalance=this.form.account.availableBalance)},updatePayroll:function(){var t=this;return m(i().mark((function e(){return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t.form.patch(window.location.origin+"/api/payroll/"+t.$route.params.slug).then((function(e){toast.fire({type:"success",title:t.$t("payroll.edit.success_msg")}),t.$router.push({name:"payroll.index"})})).catch((function(){toast.fire({type:"error",title:t.$t("common.error_msg")})}));case 2:case"end":return e.stop()}}),e)})))()}}},d=o(1),p=Object(d.a)(v,(function(){var t=this,e=t._self._c;return e("div",[e("breadcrumbs",{attrs:{items:t.breadcrumbs,current:t.breadcrumbsCurrent}}),t._v(" "),e("div",{staticClass:"row"},[e("div",{staticClass:"col-lg-12"},[e("div",{staticClass:"card"},[e("div",{staticClass:"card-header"},[t.form.employee?e("h3",{staticClass:"card-title"},[t._v("\n "+t._s(t.$t("payroll.edit.form_title"))+"\n ")]):t._e(),t._v(" "),e("router-link",{staticClass:"btn btn-dark float-right",attrs:{to:{name:"payroll.index"}}},[e("i",{staticClass:"fas fa-long-arrow-alt-left"}),t._v(" "+t._s(t.$t("common.back"))+"\n ")])],1),t._v(" "),e("form",{attrs:{role:"form"},on:{submit:function(e){return e.preventDefault(),t.updatePayroll.apply(null,arguments)},keydown:function(e){return t.form.onKeydown(e)}}},[e("div",{staticClass:"card-body"},[e("div",{staticClass:"row"},[t.items?e("div",{staticClass:"form-group col-md-6"},[e("label",{attrs:{for:"employee"}},[t._v(t._s(t.$t("common.employee"))),e("span",{staticClass:"required"},[t._v("*")])]),t._v(" "),t.items?e("v-select",{class:{"is-invalid":t.form.errors.has("employee")},attrs:{options:t.items,label:"name",name:"employee",placeholder:t.$t("common.employee_placeholder")},on:{input:t.calculateTotalSalary},model:{value:t.form.employee,callback:function(e){t.$set(t.form,"employee",e)},expression:"form.employee"}}):t._e(),t._v(" "),e("has-error",{attrs:{form:t.form,field:"employee"}})],1):t._e(),t._v(" "),e("div",{staticClass:"form-group col-md-6"},[e("label",{attrs:{for:"salaryMonth"}},[t._v(t._s(t.$t("payroll.common.salary_month"))),e("span",{staticClass:"required"},[t._v("*")])]),t._v(" "),e("select",{directives:[{name:"model",rawName:"v-model",value:t.form.salaryMonth,expression:"form.salaryMonth"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("salaryMonth")},attrs:{id:"salaryMonth",name:"salaryMonth"},on:{change:function(e){var o=Array.prototype.filter.call(e.target.options,(function(t){return t.selected})).map((function(t){return"_value"in t?t._value:t.value}));t.$set(t.form,"salaryMonth",e.target.multiple?o:o[0])}}},[e("option",{attrs:{value:"",selected:"",disabled:""}},[t._v("\n "+t._s(t.$t("payroll.common.salary_month_placeholder"))+"\n ")]),t._v(" "),e("option",{attrs:{value:"January"}},[t._v("January")]),t._v(" "),e("option",{attrs:{value:"February"}},[t._v("February")]),t._v(" "),e("option",{attrs:{value:"March"}},[t._v("March")]),t._v(" "),e("option",{attrs:{value:"April"}},[t._v("April")]),t._v(" "),e("option",{attrs:{value:"May"}},[t._v("May")]),t._v(" "),e("option",{attrs:{value:"June"}},[t._v("June")]),t._v(" "),e("option",{attrs:{value:"July"}},[t._v("July")]),t._v(" "),e("option",{attrs:{value:"August"}},[t._v("August")]),t._v(" "),e("option",{attrs:{value:"September"}},[t._v("September")]),t._v(" "),e("option",{attrs:{value:"October"}},[t._v("October")]),t._v(" "),e("option",{attrs:{value:"November"}},[t._v("November")]),t._v(" "),e("option",{attrs:{value:"December"}},[t._v("December")])]),t._v(" "),e("has-error",{attrs:{form:t.form,field:"salaryMonth"}})],1)]),t._v(" "),t.form.employee?e("div",{staticClass:"row"},[e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"presentSalary"}},[t._v(t._s(t.$t("payroll.common.present_salary")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.employee.totalSalary,expression:"form.employee.totalSalary"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("presentSalary")},attrs:{id:"presentSalary",type:"number",step:"any",name:"presentSalary",readonly:""},domProps:{value:t.form.employee.totalSalary},on:{input:function(e){e.target.composing||t.$set(t.form.employee,"totalSalary",e.target.value)}}})]),t._v(" "),e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"deductionAmount"}},[t._v(t._s(t.$t("payroll.common.deduction_amount")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.deductionAmount,expression:"form.deductionAmount"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("deductionAmount")},attrs:{id:"deductionAmount",type:"number",step:"any",name:"deductionAmount",min:"0",placeholder:t.$t("payroll.common.deduction_amount_placeholder")},domProps:{value:t.form.deductionAmount},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"deductionAmount",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"deductionAmount"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"deductionReason"}},[t._v(t._s(t.$t("payroll.common.deduction_reason")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.deductionReason,expression:"form.deductionReason"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("deductionReason")},attrs:{id:"deductionReason",type:"text",name:"deductionReason",placeholder:t.$t("payroll.common.deduction_reason_placeholder")},domProps:{value:t.form.deductionReason},on:{input:function(e){e.target.composing||t.$set(t.form,"deductionReason",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"deductionReason"}})],1)]):t._e(),t._v(" "),e("div",{staticClass:"row"},[e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"mobileBill"}},[t._v(t._s(t.$t("payroll.common.mobile_bill")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.mobileBill,expression:"form.mobileBill"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("mobileBill")},attrs:{id:"mobileBill",type:"number",step:"any",name:"mobileBill",min:"0",placeholder:t.$t("payroll.common.mobile_bill_placeholder")},domProps:{value:t.form.mobileBill},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"mobileBill",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"mobileBill"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"foodBill"}},[t._v(t._s(t.$t("payroll.common.food_bill")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.foodBill,expression:"form.foodBill"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("foodBill")},attrs:{id:"foodBill",type:"number",step:"any",name:"foodBill",placeholder:t.$t("payroll.common.food_bill_placeholder")},domProps:{value:t.form.foodBill},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"foodBill",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"foodBill"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"bonus"}},[t._v(t._s(t.$t("payroll.common.bonus")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.bonus,expression:"form.bonus"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("bonus")},attrs:{id:"bonus",type:"number",step:"any",name:"bonus",min:"0",placeholder:t.$t("payroll.common.bonus_placeholder")},domProps:{value:t.form.bonus},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"bonus",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"bonus"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"commission"}},[t._v(t._s(t.$t("payroll.common.commission")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.commission,expression:"form.commission"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("commission")},attrs:{id:"commission",type:"number",step:"any",name:"commission",placeholder:t.$t("payroll.common.commission_placeholder")},domProps:{value:t.form.commission},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"commission",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"commission"}})],1)]),t._v(" "),e("div",{staticClass:"row"},[e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"festivalBonus"}},[t._v(t._s(t.$t("payroll.common.festival_bonus")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.festivalBonus,expression:"form.festivalBonus"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("festivalBonus")},attrs:{id:"festivalBonus",type:"number",step:"any",name:"festivalBonus",min:"0",placeholder:t.$t("payroll.common.festival_bonus_placeholder")},domProps:{value:t.form.festivalBonus},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"festivalBonus",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"festivalBonus"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"travelAllowance"}},[t._v(t._s(t.$t("payroll.common.travel_allowance")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.travelAllowance,expression:"form.travelAllowance"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("travelAllowance")},attrs:{id:"travelAllowance",type:"number",step:"any",name:"travelAllowance",placeholder:t.$t("payroll.common.travel_allowance_placeholder")},domProps:{value:t.form.travelAllowance},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"travelAllowance",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"travelAllowance"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"others"}},[t._v(t._s(t.$t("payroll.common.others")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.others,expression:"form.others"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("others")},attrs:{id:"others",type:"number",step:"any",name:"others",min:"0",placeholder:t.$t("payroll.common.others_placeholder")},domProps:{value:t.form.others},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"others",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"others"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-3"},[e("label",{attrs:{for:"advance"}},[t._v(t._s(t.$t("payroll.common.advance")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.advance,expression:"form.advance"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("advance")},attrs:{id:"advance",type:"number",step:"any",name:"advance",placeholder:t.$t("payroll.common.advance")},domProps:{value:t.form.advance},on:{change:t.calculateTotalSalary,keyup:t.calculateTotalSalary,input:function(e){e.target.composing||t.$set(t.form,"advance",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"advance"}})],1)]),t._v(" "),e("div",{staticClass:"row"},[e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"totalSalary"}},[t._v(t._s(t.$t("payroll.common.total_salary")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.totalSalary,expression:"form.totalSalary"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("totalSalary")},attrs:{id:"totalSalary",type:"number",step:"any",name:"totalSalary",readonly:""},domProps:{value:t.form.totalSalary},on:{input:function(e){e.target.composing||t.$set(t.form,"totalSalary",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"totalSalary"}})],1),t._v(" "),t.accounts?e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"account"}},[t._v(t._s(t.$t("common.account"))+"\n "),e("span",{staticClass:"required"},[t._v("*")])]),t._v(" "),e("v-select",{class:{"is-invalid":t.form.errors.has("account")},attrs:{options:t.accounts,label:"label",name:"account",placeholder:t.$t("common.account_placeholder")},model:{value:t.form.account,callback:function(e){t.$set(t.form,"account",e)},expression:"form.account"}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"account"}})],1):t._e(),t._v(" "),e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"availableBalance"}},[t._v(t._s(t.$t("common.available_balance")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.account.availableBalance,expression:"form.account.availableBalance"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("availableBalance")},attrs:{id:"availableBalance",type:"number",step:"any",name:"availableBalance",readonly:""},domProps:{value:t.form.account.availableBalance},on:{input:function(e){e.target.composing||t.$set(t.form.account,"availableBalance",e.target.value)}}})])]),t._v(" "),e("div",{staticClass:"row"},[e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"chequeNo"}},[t._v(t._s(t.$t("common.cheque_no")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.chequeNo,expression:"form.chequeNo"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("chequeNo")},attrs:{id:"chequeNo",type:"text",name:"chequeNo",placeholder:t.$t("common.cheque_placeholder")},domProps:{value:t.form.chequeNo},on:{input:function(e){e.target.composing||t.$set(t.form,"chequeNo",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"chequeNo"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"salaryDate"}},[t._v(t._s(t.$t("payroll.common.salary_date")))]),t._v(" "),e("input",{directives:[{name:"model",rawName:"v-model",value:t.form.salaryDate,expression:"form.salaryDate"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("salaryDate")},attrs:{id:"salaryDate",type:"date",name:"salaryDate"},domProps:{value:t.form.salaryDate},on:{input:function(e){e.target.composing||t.$set(t.form,"salaryDate",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"salaryDate"}})],1),t._v(" "),e("div",{staticClass:"form-group col-md-4"},[e("label",{attrs:{for:"status"}},[t._v(t._s(t.$t("common.status")))]),t._v(" "),e("select",{directives:[{name:"model",rawName:"v-model",value:t.form.status,expression:"form.status"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("status")},attrs:{id:"status"},on:{change:function(e){var o=Array.prototype.filter.call(e.target.options,(function(t){return t.selected})).map((function(t){return"_value"in t?t._value:t.value}));t.$set(t.form,"status",e.target.multiple?o:o[0])}}},[e("option",{attrs:{value:"1"}},[t._v(t._s(t.$t("common.active")))]),t._v(" "),e("option",{attrs:{value:"0"}},[t._v(t._s(t.$t("common.in_active")))])]),t._v(" "),e("has-error",{attrs:{form:t.form,field:"status"}})],1)]),t._v(" "),e("div",{staticClass:"form-group"},[e("label",{attrs:{for:"note"}},[t._v(t._s(t.$t("common.note")))]),t._v(" "),e("textarea",{directives:[{name:"model",rawName:"v-model",value:t.form.note,expression:"form.note"}],staticClass:"form-control",class:{"is-invalid":t.form.errors.has("note")},attrs:{id:"note",placeholder:t.$t("common.note_placeholder")},domProps:{value:t.form.note},on:{input:function(e){e.target.composing||t.$set(t.form,"note",e.target.value)}}}),t._v(" "),e("has-error",{attrs:{form:t.form,field:"note"}})],1),t._v(" "),e("div",{staticClass:"form-group"},[e("label",{attrs:{for:"image"}},[t._v(t._s(t.$t("common.image")))]),t._v(" "),e("div",{staticClass:"custom-file"},[e("input",{staticClass:"custom-file-input",class:{"is-invalid":t.form.errors.has("image")},attrs:{id:"image",type:"file",name:"image"},on:{change:t.onFileChange}}),t._v(" "),e("label",{staticClass:"custom-file-label",attrs:{for:"image"}},[t._v(t._s(t.$t("common.choose_file")))])]),t._v(" "),e("has-error",{attrs:{form:t.form,field:"image"}}),t._v(" "),e("div",{staticClass:"bg-light mt-4 w-25"},[t.url?e("img",{staticClass:"img-fluid",attrs:{src:t.url,alt:t.$t("common.image_alt")}}):t._e()])],1)]),t._v(" "),e("div",{staticClass:"card-footer"},[e("v-button",{staticClass:"btn btn-primary",attrs:{loading:t.form.busy}},[e("i",{staticClass:"fas fa-edit"}),t._v(" "+t._s(t.$t("common.save_changes"))+"\n ")]),t._v(" "),e("button",{staticClass:"btn btn-secondary float-right",attrs:{type:"reset"},on:{click:function(e){return t.form.reset()}}},[e("i",{staticClass:"fas fa-power-off"}),t._v(" "+t._s(t.$t("common.reset"))+"\n ")])],1)])])])])],1)}),[],!1,null,"a3b6a608",null);e.default=p.exports}}]);
Simpan