+
+
{{ $t('formDialogTitleFamilyHistoryDad') }}
-
+
('employeeOther');
v-model="employeeOther.fatherBirthPlace"
/>
-
-
+
+
+
{{ $t('formDialogTitleFamilyHistoryMom') }}
-
+
('employeeOther');
v-model="employeeOther.motherBirthPlace"
/>
-
-
-
-
-
diff --git a/src/components/03_customer-management/FormEmployeeWorkHistory.vue b/src/components/03_customer-management/FormEmployeeWorkHistory.vue
index aacea442..4e2141af 100644
--- a/src/components/03_customer-management/FormEmployeeWorkHistory.vue
+++ b/src/components/03_customer-management/FormEmployeeWorkHistory.vue
@@ -23,23 +23,21 @@ const workplaceOption = defineModel<{ label: string; value: string }[]>(
const tab = ref();
-withDefaults(
- defineProps<{
- title?: string;
- dense?: boolean;
- outlined?: boolean;
- readonly?: boolean;
- separator?: boolean;
- prefixId: string;
- showBtnSave: boolean;
- }>(),
- {
- showBtnSave: false,
- },
-);
+defineProps<{
+ title?: string;
+ dense?: boolean;
+ outlined?: boolean;
+ readonly?: boolean;
+ prefixId: string;
+}>();
+
+defineEmits<{
+ (e: 'save', index: number): void;
+}>();
function addData() {
- const canAdd = checkTabBeforeAdd(employeeWork.value || []);
+ // const canAdd = checkTabBeforeAdd(employeeWork.value || []);
+ const canAdd = true;
if (canAdd) {
employeeWork.value?.push({
workEndDate: null,
@@ -94,427 +92,372 @@ const workplaceFilter = selectFilterOptionRefMod(
-
-
-
+
+
-
-
-
- {{ $t('formDialogTabWork') + (index + 1) }}
- {
- if (employeeWork?.[index].statusSave) {
- $emit('remove', index);
- } else {
- removeData(index);
- }
- }
- "
- />
-
-
-
+ @click="addData"
+ v-if="!readonly"
+ />
-
-
-
- • {{ $t(`workHistory`) }}
-
-
-
-
-
-
-
- {{ $t('noResults') }}
-
-
-
-
-
-
-
-
- {{ $t('noResults') }}
-
-
-
-
-
-
-
-
- {{ $t('noResults') }}
-
-
-
-
-
-
-
- {{ $i18n.locale === 'th-th' ? value + 543 : value }}
-
-
- {{ $i18n.locale === 'th-th' ? value + 543 : value }}
-
-
- {
- if (v && v.toString().length === 10) {
- work.workEndDate = parseAndFormatDate(v, locale);
- }
- }
- "
- >
-
-
-
-
-
-
-
-
-
-
-
-
- {{ $i18n.locale === 'th-th' ? value + 543 : value }}
-
-
- {{ $i18n.locale === 'th-th' ? value + 543 : value }}
-
-
- {
- if (v && v.toString().length === 10) {
- work.workPermitIssuDate = parseAndFormatDate(v, locale);
- }
- }
- "
- >
-
-
-
-
-
-
-
-
-
-
-
- {{ $i18n.locale === 'th-th' ? value + 543 : value }}
-
-
- {{ $i18n.locale === 'th-th' ? value + 543 : value }}
-
-
- {
- if (v && v.toString().length === 10) {
- work.workPermitExpireDate = parseAndFormatDate(v, locale);
- }
- }
- "
- >
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+ {{ `ครั้งที่ ${index + 1}` }}
+
-
-
+
+
+
+
+
+ {{ $t('noResults') }}
+
+
+
+
+
+
+
+
+ {{ $t('noResults') }}
+
+
+
+
+
+
+
+ {{ $i18n.locale === 'th-th' ? value + 543 : value }}
+
+
+ {{ $i18n.locale === 'th-th' ? value + 543 : value }}
+
+
+ {
+ if (v && v.toString().length === 10) {
+ work.workEndDate = parseAndFormatDate(v, locale);
+ }
+ }
+ "
+ >
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ $i18n.locale === 'th-th' ? value + 543 : value }}
+
+
+ {{ $i18n.locale === 'th-th' ? value + 543 : value }}
+
+
+ {
+ if (v && v.toString().length === 10) {
+ work.workPermitIssuDate = parseAndFormatDate(v, locale);
+ }
+ }
+ "
+ >
+
+
+
+
+
+
+
+
+
+
+
+ {{ $i18n.locale === 'th-th' ? value + 543 : value }}
+
+
+ {{ $i18n.locale === 'th-th' ? value + 543 : value }}
+
+
+ {
+ if (v && v.toString().length === 10) {
+ work.workPermitExpireDate = parseAndFormatDate(v, locale);
+ }
+ }
+ "
+ >
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ $t('noResults') }}
+
+
+
+
+
-
+
diff --git a/src/pages/03_customer-management/MainPage.vue b/src/pages/03_customer-management/MainPage.vue
index 1b286d67..278b91c0 100644
--- a/src/pages/03_customer-management/MainPage.vue
+++ b/src/pages/03_customer-management/MainPage.vue
@@ -43,6 +43,8 @@ import { storeToRefs } from 'pinia';
import ProfileBanner from 'src/components/ProfileBanner.vue';
import ImageUploadDialog from 'src/components/ImageUploadDialog.vue';
import FormEmployeeHealthCheck from 'src/components/03_customer-management/FormEmployeeHealthCheck.vue';
+import FormEmployeeWorkHistory from 'src/components/03_customer-management/FormEmployeeWorkHistory.vue';
+import FormEmployeeOther from 'src/components/03_customer-management/FormEmployeeOther.vue';
import useOptionStore from 'src/stores/options';
const { t, locale } = useI18n();
@@ -1861,28 +1863,53 @@ function createEmployeeForm() {