refactor: pre view
This commit is contained in:
parent
6b51b0ed05
commit
532284995e
1 changed files with 21 additions and 2 deletions
|
|
@ -322,9 +322,28 @@ async function storeDataLocal(id: string) {
|
||||||
localStorage.setItem(
|
localStorage.setItem(
|
||||||
'quotation-preview',
|
'quotation-preview',
|
||||||
JSON.stringify({
|
JSON.stringify({
|
||||||
data: quotationFormData.value,
|
data: {
|
||||||
|
...quotationFormData.value,
|
||||||
|
},
|
||||||
meta: {
|
meta: {
|
||||||
source: quotationFormState.value.source,
|
source: {
|
||||||
|
...quotationFormState.value.source,
|
||||||
|
code:
|
||||||
|
quotationFormState.value.mode === 'create'
|
||||||
|
? '-'
|
||||||
|
: quotationFormState.value?.source?.code,
|
||||||
|
createAt:
|
||||||
|
quotationFormState.value.mode === 'create'
|
||||||
|
? Date.now()
|
||||||
|
: quotationFormState.value?.source?.createdAt,
|
||||||
|
createBy: quotationFormState.value?.source?.createdBy,
|
||||||
|
payCondition: quotationFormData.value.payCondition,
|
||||||
|
contactName: quotationFormData.value.contactName,
|
||||||
|
contactTel: quotationFormData.value.contactTel,
|
||||||
|
workName: quotationFormData.value.workName,
|
||||||
|
dueDate: quotationFormData.value.dueDate,
|
||||||
|
},
|
||||||
|
selectedWorker: quotationFormData.value.worker,
|
||||||
createdBy: quotationFormState.value.createdBy('tha'),
|
createdBy: quotationFormState.value.createdBy('tha'),
|
||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue