File manager - Edit - /home/autoph/.trash/assets/index-d248b112.js
Back
import{C as y}from"./ProposalService-654b1e4e.js";import{F as g}from"./index-dc1d7949.js";import{F as x}from"./lodash-40555032.js";import"./index-a9dd6c30.js";import{_ as C,r as i,o as c,c as I,g as m,f as e,I as l,e as n,d as _,J as k,G as B,H as P,b as S,K as F,L as M}from"./index-c93b54f1.js";import"./vue-cleave.min-f5c28995.js";import{T as V}from"./index-63749718.js";import"./index-c2f9a41d.js";import{C as w}from"./CloseButton-97e8859a.js";import{S as R}from"./UpdateButton-3b0d94bb.js";/* empty css */import{I as G}from"./index-497d4024.js";const N={components:{FormModal:g,InputGroup:G,FormGroup:x,TextArea:V,SubmitButton:R,CloseButton:w},data(){return{form:{id:null,remarks:""},searchQuery:"",items:[],state:{isLoading:!1,isSaving:!1,showModal:!1}}},computed:{filteredItems(){let s=this.items;return this.searchQuery&&(s=this.items.filter(d=>d.supplier_name.toLowerCase().includes(this.searchQuery.toLowerCase()||d.ref_code.includes(this.searchQuery)))),s}},methods:{async fetchRecords(){y.fetchRecords({validity:"2024-01-01"}).then(s=>{s.status==200&&(console.log("response"),console.log(s),this.items=s.data.data,console.log("this.items"),console.log(this.items))}).catch(s=>{console.log(s)})},closeModal(){this.state.showModal=!1},selectItem(s){this.form.id=s,console.log(s)},submit(){this.$emit("submit")}}},r=s=>(F("data-v-ec1c0907"),s=s(),M(),s),Q={class:"space-y-2 p-2 mb-10"},A={class:"grid lg:grid-cols-2"},L={class:"flex gap-2 border-b border-slate-300 border-dashed py-1"},q=r(()=>e("div",{class:"label text-slate-500"},"Reference No:",-1)),T={class:"value font-bold"},D=r(()=>e("div",{class:"flex gap-2 border-b border-slate-300 border-dashed py-1"},[e("div",{class:"label text-slate-500"},"Requested By:"),e("div",{class:"value font-bold"})],-1)),z={class:"grid lg:grid-cols-2"},H={class:"flex gap-2 border-b border-slate-300 border-dashed py-1"},U=r(()=>e("div",{class:"label text-slate-500"},"Company:",-1)),j={class:"value font-bold"},E={class:"flex gap-2 border-b border-slate-300 border-dashed py-1"},J=r(()=>e("div",{class:"label text-slate-500"},"Dealership:",-1)),K={class:"value font-bold"},O={class:"grid lg:grid-cols-2"},W={class:"flex gap-2 border-b border-slate-300 border-dashed py-1"},X=r(()=>e("div",{class:"label text-slate-500"},"Date Needed:",-1)),Y={class:"value font-bold"},Z={class:"flex gap-1 border-b border-slate-300 border-dashed py-1"},$=r(()=>e("div",{class:"label text-slate-500"},"Approving Head:",-1)),ee={class:"value font-bold"},se={class:"flex gap-1 border-b border-slate-300 border-dashed py-1"},oe=r(()=>e("div",{class:"label text-slate-500"},"Requested By:",-1)),te={class:"value font-bold"},le={class:"flex gap-1 border-b border-slate-500 border-dashed py-1"},re=r(()=>e("div",{class:"label text-slate-500"},"Purpose:",-1)),de={class:"value font-bold"},ae={class:"py-4"},ie={class:"max-h-80 overflow-y-auto"},ne=r(()=>e("thead",null,[e("tr",null,[e("th",null,"Ref No"),e("th",null,"Supplier"),e("th",null,"Validity"),e("th",null,"File"),e("th",null,"Notes")])],-1)),ce={key:0},_e=["onClick"],me={class:"flex gap-2 justify-end"};function ue(s,d,pe,he,o,a){const u=i("InputGroup"),p=i("TextArea"),h=i("FormGroup"),f=i("SubmitButton"),b=i("CloseButton"),v=i("FormModal");return c(),I(v,{title:"Approved Proposals",active:o.state.showModal,onClose:a.closeModal,themeClass:"bg-primary-600",sizeClass:"w-full"},{default:m(()=>[e("div",Q,[e("div",A,[e("div",L,[q,e("div",T,l(o.form.PrInfo.reference_no),1)]),D]),e("div",z,[e("div",H,[U,e("div",j,l(o.form.PrInfo.company_name),1)]),e("div",E,[J,e("div",K,l(o.form.PrInfo.dealership_name),1)])]),e("div",O,[e("div",W,[X,e("div",Y,l(o.form.PrInfo.needed_at),1)]),e("div",Z,[$,e("div",ee,l(o.form.PrInfo.approving_head_name),1)])]),e("div",se,[oe,e("div",te,l(o.form.PrInfo.requested_by_name),1)]),e("div",le,[re,e("div",de,l(o.form.PrInfo.purpose),1)])]),e("div",ae,[n(u,{modelValue:o.searchQuery,"onUpdate:modelValue":d[0]||(d[0]=t=>o.searchQuery=t)},null,8,["modelValue"])]),e("div",ie,[e("table",null,[ne,a.filteredItems&&a.filteredItems.length>0?(c(),_("tbody",ce,[(c(!0),_(k,null,B(a.filteredItems,t=>(c(),_("tr",{key:t.id,onClick:fe=>a.selectItem(t.id),class:P({"bg-primary-300":o.form.id==t.id})},[e("td",null,l(t.ref_code),1),e("td",null,l(t.supplier_name),1),e("td",null,l(t.validity_date),1),e("td",null,l(t.file_code),1)],10,_e))),128))])):S("",!0)])]),n(h,{label:"Remarks",isRequired:"",formClass:"my-8"},{default:m(()=>[n(p,{modelValue:o.form.remarks,"onUpdate:modelValue":d[1]||(d[1]=t=>o.form.remarks=t)},null,8,["modelValue"])]),_:1}),e("div",me,[n(f,{onClick:a.submit},null,8,["onClick"]),n(b,{onClick:a.closeModal},null,8,["onClick"])])]),_:1},8,["active","onClose"])}const Me=C(N,[["render",ue],["__scopeId","data-v-ec1c0907"]]);export{Me as P};
| ver. 1.4 |
.
| PHP 7.3.33 | Generation time: 0 |
proxy
|
phpinfo
|
Settings