fix: แก้ personName
This commit is contained in:
parent
8013c553ea
commit
0cf2af9754
2 changed files with 13 additions and 0 deletions
|
|
@ -74,6 +74,7 @@ const {
|
||||||
const employeeStore = useEmployeeStore();
|
const employeeStore = useEmployeeStore();
|
||||||
const formData = ref<CustomerCreate>({
|
const formData = ref<CustomerCreate>({
|
||||||
status: 'CREATED',
|
status: 'CREATED',
|
||||||
|
personName: '',
|
||||||
customerType: 'CORP',
|
customerType: 'CORP',
|
||||||
customerName: '',
|
customerName: '',
|
||||||
customerNameEN: '',
|
customerNameEN: '',
|
||||||
|
|
@ -440,6 +441,7 @@ function clearForm() {
|
||||||
customerType: 'CORP',
|
customerType: 'CORP',
|
||||||
customerName: '',
|
customerName: '',
|
||||||
customerNameEN: '',
|
customerNameEN: '',
|
||||||
|
personName: '',
|
||||||
taxNo: '',
|
taxNo: '',
|
||||||
customerBranch: [
|
customerBranch: [
|
||||||
{
|
{
|
||||||
|
|
@ -725,6 +727,7 @@ async function onSubmitEdit(id: string) {
|
||||||
customerNameEN: formData.value.customerNameEN,
|
customerNameEN: formData.value.customerNameEN,
|
||||||
customerBranch: formData.value.customerBranch,
|
customerBranch: formData.value.customerBranch,
|
||||||
taxNo: formData.value.taxNo,
|
taxNo: formData.value.taxNo,
|
||||||
|
personName: formData.value.personName,
|
||||||
};
|
};
|
||||||
|
|
||||||
await editById(id, tempValue);
|
await editById(id, tempValue);
|
||||||
|
|
@ -820,6 +823,7 @@ async function assignFormData(data: Customer & { branch: CustomerBranch[] }) {
|
||||||
customerType: data.customerType,
|
customerType: data.customerType,
|
||||||
customerName: data.customerName,
|
customerName: data.customerName,
|
||||||
customerNameEN: data.customerNameEN,
|
customerNameEN: data.customerNameEN,
|
||||||
|
personName: data.personName,
|
||||||
taxNo: data.taxNo,
|
taxNo: data.taxNo,
|
||||||
customerBranch: [],
|
customerBranch: [],
|
||||||
image: null,
|
image: null,
|
||||||
|
|
@ -1651,6 +1655,7 @@ watch(currentStatus, async () => {
|
||||||
:type-customer="customerType"
|
:type-customer="customerType"
|
||||||
v-model:customer-name="formData.customerName"
|
v-model:customer-name="formData.customerName"
|
||||||
v-model:customer-name-en="formData.customerNameEN"
|
v-model:customer-name-en="formData.customerNameEN"
|
||||||
|
v-model:person-name="formData.personName"
|
||||||
v-model:tax-no="formData.taxNo"
|
v-model:tax-no="formData.taxNo"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -1826,6 +1831,7 @@ watch(currentStatus, async () => {
|
||||||
v-model:customer-branch="formDataEmployeeOwner"
|
v-model:customer-branch="formDataEmployeeOwner"
|
||||||
v-model:employee-id="currentEmployeeCode"
|
v-model:employee-id="currentEmployeeCode"
|
||||||
v-model:nrc-no="formDataEmployee.nrcNo"
|
v-model:nrc-no="formDataEmployee.nrcNo"
|
||||||
|
v-model:person-name="formData.personName"
|
||||||
@filter-owner-branch="employeeFilterOwnerBranch"
|
@filter-owner-branch="employeeFilterOwnerBranch"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -2235,6 +2241,7 @@ watch(currentStatus, async () => {
|
||||||
:type-customer="customerType"
|
:type-customer="customerType"
|
||||||
v-model:customer-name="formData.customerName"
|
v-model:customer-name="formData.customerName"
|
||||||
v-model:customer-name-en="formData.customerNameEN"
|
v-model:customer-name-en="formData.customerNameEN"
|
||||||
|
v-model:person-name="formData.personName"
|
||||||
v-model:tax-no="formData.taxNo"
|
v-model:tax-no="formData.taxNo"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -2426,6 +2433,7 @@ watch(currentStatus, async () => {
|
||||||
:type-customer="customerType"
|
:type-customer="customerType"
|
||||||
v-model:customer-name="formData.customerName"
|
v-model:customer-name="formData.customerName"
|
||||||
v-model:customer-name-en="formData.customerNameEN"
|
v-model:customer-name-en="formData.customerNameEN"
|
||||||
|
v-model:person-name="formData.personName"
|
||||||
v-model:tax-no="formData.taxNo"
|
v-model:tax-no="formData.taxNo"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -2634,6 +2642,7 @@ watch(currentStatus, async () => {
|
||||||
v-model:customer-branch="formDataEmployeeOwner"
|
v-model:customer-branch="formDataEmployeeOwner"
|
||||||
v-model:employee-id="currentEmployeeCode"
|
v-model:employee-id="currentEmployeeCode"
|
||||||
v-model:nrc-no="formDataEmployee.nrcNo"
|
v-model:nrc-no="formDataEmployee.nrcNo"
|
||||||
|
v-model:person-name="formData.personName"
|
||||||
@filter-owner-branch="employeeFilterOwnerBranch"
|
@filter-owner-branch="employeeFilterOwnerBranch"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
|
|
@ -16,10 +16,12 @@ export type Customer = {
|
||||||
updateBy: string | null;
|
updateBy: string | null;
|
||||||
updatedAt: string;
|
updatedAt: string;
|
||||||
taxNo: string;
|
taxNo: string;
|
||||||
|
personName: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type CustomerBranch = {
|
export type CustomerBranch = {
|
||||||
id: string;
|
id: string;
|
||||||
|
|
||||||
branchNo: number;
|
branchNo: number;
|
||||||
legalPersonNo: string;
|
legalPersonNo: string;
|
||||||
name: string;
|
name: string;
|
||||||
|
|
@ -97,6 +99,7 @@ export type CustomerCreate = {
|
||||||
customerType: CustomerType;
|
customerType: CustomerType;
|
||||||
status?: Status;
|
status?: Status;
|
||||||
image: File | null;
|
image: File | null;
|
||||||
|
personName: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type CustomerUpdate = {
|
export type CustomerUpdate = {
|
||||||
|
|
@ -107,6 +110,7 @@ export type CustomerUpdate = {
|
||||||
customerBranch?: (CustomerBranchCreate & { id?: string })[];
|
customerBranch?: (CustomerBranchCreate & { id?: string })[];
|
||||||
taxNo?: string | null;
|
taxNo?: string | null;
|
||||||
image?: File;
|
image?: File;
|
||||||
|
personName: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type BranchAttachmentCreate = {
|
export type BranchAttachmentCreate = {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue