Merge branch 'develop' into dev
All checks were successful
Build & Deploy on Dev / build (push) Successful in 3m21s
All checks were successful
Build & Deploy on Dev / build (push) Successful in 3m21s
This commit is contained in:
commit
07dfc5a144
1 changed files with 12 additions and 5 deletions
|
|
@ -59,6 +59,8 @@ const formData = reactive({
|
||||||
|
|
||||||
const isReadOnly = ref<boolean>(false); //อ่ายได้อย่างเดียว
|
const isReadOnly = ref<boolean>(false); //อ่ายได้อย่างเดียว
|
||||||
const workflowRef = ref<any>(null);
|
const workflowRef = ref<any>(null);
|
||||||
|
const isDeputy = ref<boolean>(false); //คนอยู่ในสำนักปลัด
|
||||||
|
|
||||||
//ข้อมูลรายการสถานะ
|
//ข้อมูลรายการสถานะ
|
||||||
const statusOptionMain = ref<DataOption[]>(
|
const statusOptionMain = ref<DataOption[]>(
|
||||||
store.optionStatus.filter((e) => e.id !== "")
|
store.optionStatus.filter((e) => e.id !== "")
|
||||||
|
|
@ -86,6 +88,7 @@ async function fetchDataRequest() {
|
||||||
|
|
||||||
formData.status = data.status;
|
formData.status = data.status;
|
||||||
formData.remark = data.remark;
|
formData.remark = data.remark;
|
||||||
|
isDeputy.value = data.isDeputy;
|
||||||
|
|
||||||
if (data.status !== "PENDING") {
|
if (data.status !== "PENDING") {
|
||||||
isReadOnly.value = true;
|
isReadOnly.value = true;
|
||||||
|
|
@ -312,6 +315,7 @@ onMounted(async () => {
|
||||||
!isReadOnly) ||
|
!isReadOnly) ||
|
||||||
(typeEmp === 'employee' &&
|
(typeEmp === 'employee' &&
|
||||||
isStaff &&
|
isStaff &&
|
||||||
|
isDeputy &&
|
||||||
topicConvert(dataRequest.topic) !== '' &&
|
topicConvert(dataRequest.topic) !== '' &&
|
||||||
!isReadOnly)
|
!isReadOnly)
|
||||||
"
|
"
|
||||||
|
|
@ -470,14 +474,14 @@ onMounted(async () => {
|
||||||
:class="
|
:class="
|
||||||
classInput(
|
classInput(
|
||||||
isReadOnly ||
|
isReadOnly ||
|
||||||
(typeEmp === 'employee' && !isStaff) ||
|
(typeEmp === 'employee' && !isStaff && !isDeputy) ||
|
||||||
(typeEmp !== 'employee' &&
|
(typeEmp !== 'employee' &&
|
||||||
!workflowRef?.permission.isUpdate)
|
!workflowRef?.permission.isUpdate)
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
:readonly="
|
:readonly="
|
||||||
isReadOnly ||
|
isReadOnly ||
|
||||||
(typeEmp === 'employee' && !isStaff) ||
|
(typeEmp === 'employee' && !isStaff && !isDeputy) ||
|
||||||
(typeEmp !== 'employee' &&
|
(typeEmp !== 'employee' &&
|
||||||
!workflowRef?.permission.isUpdate)
|
!workflowRef?.permission.isUpdate)
|
||||||
"
|
"
|
||||||
|
|
@ -515,14 +519,14 @@ onMounted(async () => {
|
||||||
:class="
|
:class="
|
||||||
classInput(
|
classInput(
|
||||||
isReadOnly ||
|
isReadOnly ||
|
||||||
(typeEmp === 'employee' && !isStaff) ||
|
(typeEmp === 'employee' && !isStaff && !isDeputy) ||
|
||||||
(typeEmp !== 'employee' &&
|
(typeEmp !== 'employee' &&
|
||||||
!workflowRef?.permission.isUpdate)
|
!workflowRef?.permission.isUpdate)
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
:readonly="
|
:readonly="
|
||||||
isReadOnly ||
|
isReadOnly ||
|
||||||
(typeEmp === 'employee' && !isStaff) ||
|
(typeEmp === 'employee' && !isStaff && !isDeputy) ||
|
||||||
(typeEmp !== 'employee' &&
|
(typeEmp !== 'employee' &&
|
||||||
!workflowRef?.permission.isUpdate)
|
!workflowRef?.permission.isUpdate)
|
||||||
"
|
"
|
||||||
|
|
@ -539,7 +543,10 @@ onMounted(async () => {
|
||||||
class="row col-12 justify-end"
|
class="row col-12 justify-end"
|
||||||
v-if="
|
v-if="
|
||||||
(!isReadOnly && workflowRef?.permission.isUpdate) ||
|
(!isReadOnly && workflowRef?.permission.isUpdate) ||
|
||||||
(typeEmp === 'employee' && isStaff && !isReadOnly)
|
(typeEmp === 'employee' &&
|
||||||
|
isStaff &&
|
||||||
|
!isReadOnly &&
|
||||||
|
isDeputy)
|
||||||
"
|
"
|
||||||
>
|
>
|
||||||
<q-btn label="บันทึก" color="secondary" type="submit"
|
<q-btn label="บันทึก" color="secondary" type="submit"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue