fix: properties doc check & form/move item workflow step

This commit is contained in:
puriphatt 2024-11-28 15:42:49 +07:00
parent 5d5621882e
commit ba64702287
4 changed files with 49 additions and 7 deletions

View file

@ -77,7 +77,7 @@ function assignToForm() {
<q-expansion-item
dense
v-model="isExpand"
class="overflow-hidden bordered q-my-sm full-width"
class="overflow-hidden bordered full-width"
switch-toggle-side
style="border-radius: var(--radius-2)"
expand-icon="mdi-chevron-down-circle"

View file

@ -30,6 +30,12 @@ import {
EmployeePassportPayload,
EmployeeVisaPayload,
} from 'stores/employee/types';
import {
PropDate,
PropNumber,
PropOptions,
PropString,
} from 'src/stores/product-service/types';
const { locale } = useI18n();
@ -483,8 +489,18 @@ async function triggerViewFile(opt: {
"
>
<template v-slot="{ product }">
<section class="column surface-1 q-pa-sm bordered-t">
<section
class="column surface-1 q-px-sm bordered-t q-pb-sm q-gutter-y-sm"
>
<DocumentExpansion
v-if="
value.productService.work?.attributes?.workflowStep[
pageState.currentStep - 1
].attributes?.properties.some(
(v: PropString | PropNumber | PropDate | PropOptions) =>
v.fieldName === 'documentCheck',
)
"
ref="refDocumentExpansion"
:attributes="value.attributes"
@change-status="
@ -534,6 +550,14 @@ async function triggerViewFile(opt: {
:listDocument="product?.document"
/>
<FormExpansion
v-if="
value.productService.work?.attributes?.workflowStep[
pageState.currentStep - 1
].attributes?.properties.some(
(v: PropString | PropNumber | PropDate | PropOptions) =>
v.fieldName === 'designForm',
)
"
:step="{
step: pageState.currentStep,
requestWorkId: value.id || '',