chore: store customer code in state
This commit is contained in:
parent
6286e2685a
commit
bada761735
1 changed files with 3 additions and 0 deletions
|
|
@ -38,6 +38,7 @@ export const useCustomerForm = defineStore('form-customer', () => {
|
|||
imageEdit: boolean;
|
||||
readonly: boolean;
|
||||
editCustomerId?: string;
|
||||
editCustomerCode?: string;
|
||||
editCustomerBranchId?: string;
|
||||
}>({
|
||||
dialogType: 'info',
|
||||
|
|
@ -98,6 +99,8 @@ export const useCustomerForm = defineStore('form-customer', () => {
|
|||
|
||||
if (!data) return;
|
||||
|
||||
state.value.editCustomerId = id;
|
||||
state.value.editCustomerCode = data.code;
|
||||
state.value.customerImageUrl = `${apiBaseUrl}/customer/${id}/image`;
|
||||
|
||||
resetFormData.registeredBranchId = data.registeredBranchId;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue