fix: edit image not show
This commit is contained in:
parent
26300a189f
commit
5d30fd3f11
1 changed files with 4 additions and 0 deletions
|
|
@ -5,6 +5,8 @@ import useMyBranch from 'src/stores/my-branch';
|
||||||
import useCustomerStore from 'src/stores/customer';
|
import useCustomerStore from 'src/stores/customer';
|
||||||
|
|
||||||
export const useCustomerForm = defineStore('form-customer', () => {
|
export const useCustomerForm = defineStore('form-customer', () => {
|
||||||
|
const apiBaseUrl = import.meta.env.VITE_API_BASE_URL;
|
||||||
|
|
||||||
const customerStore = useCustomerStore();
|
const customerStore = useCustomerStore();
|
||||||
const branchStore = useMyBranch();
|
const branchStore = useMyBranch();
|
||||||
|
|
||||||
|
|
@ -85,6 +87,8 @@ export const useCustomerForm = defineStore('form-customer', () => {
|
||||||
|
|
||||||
if (!data) return;
|
if (!data) return;
|
||||||
|
|
||||||
|
state.value.customerImageUrl = `${apiBaseUrl}/customer/${id}/image`;
|
||||||
|
|
||||||
resetFormData.registeredBranchId = data.registeredBranchId;
|
resetFormData.registeredBranchId = data.registeredBranchId;
|
||||||
resetFormData.status = data.status;
|
resetFormData.status = data.status;
|
||||||
resetFormData.customerType = data.customerType;
|
resetFormData.customerType = data.customerType;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue