diff --git a/public/option/option.json b/public/option/option.json
index 7b9f975f..2d4991aa 100644
--- a/public/option/option.json
+++ b/public/option/option.json
@@ -1,28 +1,5 @@
{
"eng": {
- "visaType": [
- {
- "label": "Non-LA",
- "value": "nla"
- },
- {
- "label": "Non-B",
- "value": "nb"
- },
- {
- "label": "TV.60",
- "value": "tv60"
- },
- {
- "label": "Non-TR",
- "value": "ntr"
- },
- {
- "label": "TV.30",
- "value": "tv30"
- }
- ],
-
"workerStatus": [
{
"label": "Normal",
@@ -1074,29 +1051,6 @@
},
"tha": {
- "visaType": [
- {
- "label": "Non-LA",
- "value": "nla"
- },
- {
- "label": "Non-B",
- "value": "nb"
- },
- {
- "label": "ผผ.60",
- "value": "tv60"
- },
- {
- "label": "Non-TR",
- "value": "ntr"
- },
- {
- "label": "ผผ.30",
- "value": "tv30"
- }
- ],
-
"workerStatus": [
{
"label": "ปกติ",
diff --git a/src/boot/i18n.ts b/src/boot/i18n.ts
index 9e2cda0d..647f3d10 100644
--- a/src/boot/i18n.ts
+++ b/src/boot/i18n.ts
@@ -2,7 +2,6 @@ import { defineBoot } from '#q-app/wrappers';
import { createI18n } from 'vue-i18n';
import messages from 'src/i18n';
-import { Lang } from 'src/utils/ui';
export type MessageLanguages = keyof typeof messages;
// Type-define 'eng' as the master schema for the resource
@@ -27,7 +26,7 @@ export const i18n = createI18n<
MessageLanguages,
false
>({
- locale: Lang.Thai,
+ locale: 'en-US',
legacy: false,
messages,
});
diff --git a/src/components/02_personnel-management/FormPerson.vue b/src/components/02_personnel-management/FormPerson.vue
index 7773b161..5fa321b6 100644
--- a/src/components/02_personnel-management/FormPerson.vue
+++ b/src/components/02_personnel-management/FormPerson.vue
@@ -196,11 +196,7 @@ watch(
class="col"
:label="$t('personnel.form.firstName')"
v-model="firstName"
- :rules="
- employee
- ? []
- : [(val: string) => !!val || $t('form.error.required')]
- "
+ :rules="[(val: string) => !!val || $t('form.error.required')]"
/>
@@ -410,15 +394,11 @@ watch(
:readonly="readonly"
:label="$t('form.birthDate')"
:disabled-dates="disabledAfterToday"
- :rules="
- employee
- ? []
- : [
- (val: string) =>
- !!val ||
- $t('form.error.selectField', { field: $t('form.birthDate') }),
- ]
- "
+ :rules="[
+ (val: string) =>
+ !!val ||
+ $t('form.error.selectField', { field: $t('form.birthDate') }),
+ ]"
/>
@@ -532,6 +513,7 @@ watch(
:hide-dropdown-icon="readonly"
:for="`${prefixId}-select-nationality`"
:label="$t('general.nationality')"
+ :rules="[(val: string) => !!val || $t('form.error.required')]"
@filter="nationalityFilter"
>
diff --git a/src/components/03_customer-management/FormEmployeeOther.vue b/src/components/03_customer-management/FormEmployeeOther.vue
index f2c32c63..3e9a4a89 100644
--- a/src/components/03_customer-management/FormEmployeeOther.vue
+++ b/src/components/03_customer-management/FormEmployeeOther.vue
@@ -106,7 +106,7 @@ const employeeOther = defineModel('employeeOther');
:readonly="readonly || employeeOther.statusSave"
hide-bottom-space
class="col-md-3 col-6"
- :label="$t('general.nativeLanguage', { msg: $t('form.firstName') })"
+ :label="$t('form.firstName')"
:model-value="employeeOther.fatherFirstName"
@update:model-value="
(v) =>
@@ -122,7 +122,7 @@ const employeeOther = defineModel('employeeOther');
:readonly="readonly || employeeOther.statusSave"
hide-bottom-space
class="col-md-3 col-6"
- :label="$t('general.nativeLanguage', { msg: $t('form.lastName') })"
+ :label="$t('form.lastName')"
:model-value="employeeOther.fatherLastName"
@update:model-value="
(v) =>
@@ -177,7 +177,7 @@ const employeeOther = defineModel('employeeOther');
:readonly="readonly || employeeOther.statusSave"
hide-bottom-space
class="col-md-3 col-6"
- :label="$t('general.nativeLanguage', { msg: $t('form.firstName') })"
+ :label="$t('form.firstName')"
:model-value="employeeOther.motherFirstName"
@update:model-value="
(v) =>
@@ -193,7 +193,7 @@ const employeeOther = defineModel('employeeOther');
:readonly="readonly || employeeOther.statusSave"
hide-bottom-space
class="col-md-3 col-6"
- :label="$t('general.nativeLanguage', { msg: $t('form.lastName') })"
+ :label="$t('form.lastName')"
:model-value="employeeOther.motherLastName"
@update:model-value="
(v) =>
diff --git a/src/components/03_customer-management/FormEmployeePassport.vue b/src/components/03_customer-management/FormEmployeePassport.vue
index 5fe21b52..1eb9096d 100644
--- a/src/components/03_customer-management/FormEmployeePassport.vue
+++ b/src/components/03_customer-management/FormEmployeePassport.vue
@@ -103,7 +103,7 @@ onMounted(() => {
'label',
);
passportIssuingCountryFilter = selectFilterOptionRefMod(
- ref(optionStore.rawOption?.eng.nationality),
+ ref(optionStore.globalOption.nationality),
passportIssuingCountryOptions,
'label',
);
@@ -121,13 +121,13 @@ onMounted(() => {
);
genderFilter = selectFilterOptionRefMod(
- ref(optionStore.rawOption?.eng.gender),
+ ref(optionStore.globalOption?.gender),
genderOptions,
'label',
);
nationalityFilter = selectFilterOptionRefMod(
- ref(optionStore.rawOption?.eng.nationality),
+ ref(optionStore.globalOption?.nationality),
nationalityOptions,
'label',
);
@@ -152,7 +152,7 @@ watch(
);
passportIssuingCountryFilter = selectFilterOptionRefMod(
- ref(optionStore.rawOption?.eng.nationality),
+ ref(optionStore.globalOption.nationality),
passportIssuingCountryOptions,
'label',
);
@@ -164,13 +164,13 @@ watch(
);
genderFilter = selectFilterOptionRefMod(
- ref(optionStore.rawOption?.eng.gender),
+ ref(optionStore.globalOption?.gender),
genderOptions,
'label',
);
nationalityFilter = selectFilterOptionRefMod(
- ref(optionStore.rawOption?.eng.nationality),
+ ref(optionStore.globalOption?.nationality),
nationalityOptions,
'label',
);
diff --git a/src/components/03_customer-management/FormEmployeeVisa.vue b/src/components/03_customer-management/FormEmployeeVisa.vue
index 876c7a52..a441ae65 100644
--- a/src/components/03_customer-management/FormEmployeeVisa.vue
+++ b/src/components/03_customer-management/FormEmployeeVisa.vue
@@ -92,7 +92,7 @@ let workerTypeFilter: (
onMounted(() => {
visaTypeFilter = selectFilterOptionRefMod(
- ref(optionStore.globalOption?.visaType),
+ ref(optionStore.globalOption?.nationality),
visaTypeOptions,
'label',
);
diff --git a/src/i18n/eng.ts b/src/i18n/eng.ts
index ba87cc2d..d3ddf4a4 100644
--- a/src/i18n/eng.ts
+++ b/src/i18n/eng.ts
@@ -153,7 +153,6 @@ export default {
tableOfContent: 'Table of Contents',
draw: 'Draw',
newUpload: 'New Upload',
- nativeLanguage: '{msg} Native Language',
},
menu: {
diff --git a/src/i18n/tha.ts b/src/i18n/tha.ts
index afdcf8f8..5978bb7e 100644
--- a/src/i18n/tha.ts
+++ b/src/i18n/tha.ts
@@ -153,7 +153,6 @@ export default {
tableOfContent: 'สารบัญ',
draw: 'วาด',
newUpload: 'อัปโหลดใหม่',
- nativeLanguage: '{msg} ภาษาต้นทาง',
},
menu: {
diff --git a/src/pages/03_customer-management/MainPage.vue b/src/pages/03_customer-management/MainPage.vue
index 45482ec4..8d962613 100644
--- a/src/pages/03_customer-management/MainPage.vue
+++ b/src/pages/03_customer-management/MainPage.vue
@@ -2918,7 +2918,6 @@ const emptyCreateDialog = ref(false);
class="q-mb-xl"
/>
{
}
return {
- rawOption,
globalOption,
mapOption,
};