Merge branch 'develop' of github.com:Frappet/bma-ehr-frontend into develop
# Conflicts: # src/modules/03_recruiting/components/Address.vue # src/modules/03_recruiting/views/03_editor/index.vue # src/modules/04_registryPerson/components/Dialog/02_Address.vue # src/modules/04_registryPerson/components/detail/PersonalInformation/03_Address.vue # src/modules/05_placement/components/PersonalDetail/CheckInformation/02_FormAddress.vue # src/modules/05_placement/components/PersonalDetail/Information/Address.vue
This commit is contained in:
commit
563f3e1b16
95 changed files with 580 additions and 489 deletions
|
|
@ -13,7 +13,7 @@ import type {
|
|||
DataOptionTechnique,
|
||||
FormProjectDetail,
|
||||
DataOption,
|
||||
StrategyNode
|
||||
StrategyNode,
|
||||
} from "@/modules/15_development/interface/index/Main";
|
||||
import type { DataStrategic } from "@/modules/15_development/interface/response/Main";
|
||||
|
||||
|
|
@ -310,12 +310,24 @@ function fetchTree() {
|
|||
}
|
||||
|
||||
/** Main save */
|
||||
function onSubmit() {
|
||||
async function onSubmit() {
|
||||
showLoader();
|
||||
http
|
||||
await http
|
||||
.put(config.API.developmentMainTab("tab3", projectId.value), {
|
||||
...formData,
|
||||
totalDate: formData.totalDate === "" ? null : formData.totalDate,
|
||||
projectDayBackPlanned:
|
||||
formData.projectDayBackPlanned === ""
|
||||
? null
|
||||
: formData.projectDayBackPlanned,
|
||||
projectDayHoldPlanned:
|
||||
formData.projectDayHoldPlanned === ""
|
||||
? null
|
||||
: formData.projectDayHoldPlanned,
|
||||
projectNigthHoldPlanned:
|
||||
formData.projectNigthHoldPlanned === ""
|
||||
? null
|
||||
: formData.projectNigthHoldPlanned,
|
||||
reasonPlanned70: reasonPlanned70.value,
|
||||
reasonPlanned20: reasonPlanned20.value,
|
||||
reasonPlanned10: reasonPlanned10.value,
|
||||
|
|
@ -392,6 +404,21 @@ function updatetotalDate() {
|
|||
function onNextTab() {
|
||||
step.value == "next" ? props.nextStep() : props.prevStep();
|
||||
}
|
||||
|
||||
const isCheckLocation = computed(() => {
|
||||
if (formData?.developmentAddresss?.length !== 0) {
|
||||
if (
|
||||
formData.developmentAddresss[formData.developmentAddresss.length - 1]
|
||||
.address !== "" &&
|
||||
formData.developmentAddresss[formData.developmentAddresss.length - 1]
|
||||
.provinceId !== ""
|
||||
) {
|
||||
return true;
|
||||
} else return false;
|
||||
}
|
||||
return true;
|
||||
});
|
||||
|
||||
/**
|
||||
* ดึงข้อมูลเมื่อคอมโพเนนต์โหลดเสร็จสมบูรณ์
|
||||
*/
|
||||
|
|
@ -465,6 +492,7 @@ defineExpose({
|
|||
</template>
|
||||
</q-input>
|
||||
<q-tree
|
||||
style="height: 350px; overflow: scroll"
|
||||
dense
|
||||
:nodes="nodes"
|
||||
selected-color="primary"
|
||||
|
|
@ -529,6 +557,7 @@ defineExpose({
|
|||
</template>
|
||||
</q-input>
|
||||
<q-tree
|
||||
style="height: 350px; overflow: scroll"
|
||||
dense
|
||||
:nodes="nodes"
|
||||
node-key="id"
|
||||
|
|
@ -680,8 +709,9 @@ defineExpose({
|
|||
|
||||
<div class="col-12 q-mt-md">
|
||||
<span class="text-bold">สถานที่ดำเนินการ</span>
|
||||
|
||||
<q-btn
|
||||
v-if="!checkRoutePermission"
|
||||
v-if="!checkRoutePermission && isCheckLocation"
|
||||
dense
|
||||
flat
|
||||
round
|
||||
|
|
@ -785,11 +815,15 @@ defineExpose({
|
|||
value="GO_BLACK"
|
||||
label="ไป-กลับ"
|
||||
v-model="formData.isBackPlanned"
|
||||
@update:model-value="props.onCheckChangeData()"
|
||||
@update:model-value="
|
||||
props.onCheckChangeData(),
|
||||
(formData.projectDayBackPlanned = null)
|
||||
"
|
||||
></q-checkbox>
|
||||
</div>
|
||||
<div class="col-12 col-md-4">
|
||||
<q-input
|
||||
:disable="!formData.isBackPlanned"
|
||||
:readonly="
|
||||
store.projectStatus === 'FINISH' || checkRoutePermission
|
||||
"
|
||||
|
|
@ -816,11 +850,16 @@ defineExpose({
|
|||
value="HOLD"
|
||||
label="พักค้าง"
|
||||
v-model="formData.isHoldPlanned"
|
||||
@update:model-value="props.onCheckChangeData()"
|
||||
@update:model-value="
|
||||
props.onCheckChangeData(),
|
||||
(formData.projectDayHoldPlanned = null),
|
||||
(formData.projectNigthHoldPlanned = null)
|
||||
"
|
||||
></q-checkbox>
|
||||
</div>
|
||||
<div class="col-12 col-md-4">
|
||||
<q-input
|
||||
:disable="!formData.isHoldPlanned"
|
||||
:readonly="
|
||||
store.projectStatus === 'FINISH' || checkRoutePermission
|
||||
"
|
||||
|
|
@ -836,6 +875,7 @@ defineExpose({
|
|||
</div>
|
||||
<div class="col-12 col-md-4">
|
||||
<q-input
|
||||
:disable="!formData.isHoldPlanned"
|
||||
:readonly="
|
||||
store.projectStatus === 'FINISH' || checkRoutePermission
|
||||
"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue