โครงสร้างอัตรากำลัง => fix bug

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-04-24 09:40:02 +07:00
parent 15d174a98c
commit 03dfcf6b9f
2 changed files with 6 additions and 3 deletions

View file

@ -219,6 +219,7 @@ watch(
if (props.modal === true) {
if (actionType.value === "ADD") {
console.log(props.dataNode);
console.log(level.value);
if (props.dataNode) {
formData.orgCode =
@ -351,7 +352,9 @@ function selectOrgLevele(val: string, status: boolean = true) {
<div class="col-2">
<q-input
:readonly="
(actionType === 'ADD' && props?.dataNode?.orgLevel !== 0) ||
(actionType === 'ADD' &&
props?.dataNode?.orgLevel !== 0 &&
level !== 0) ||
(actionType === 'EDIT' && props?.dataNode?.orgLevel > 1)
"
mask="##"

View file

@ -524,7 +524,6 @@ watch(
() => {
if (props.modal === true) {
fetchType();
// fetchLevel();
fetchExecutive();
if (props.actionType === "ADD") {
@ -535,6 +534,7 @@ watch(
formData.prefixNo = "";
formData.positionNo = "";
formData.suffixNo = "";
formData.reason = "";
} else {
props.rowId && fetchPosition(props.rowId);
}
@ -557,7 +557,6 @@ async function addPosition(data: RowDetailPositions) {
if (!isIdExist) {
rows.value = [...rows.value, data];
// rows.value.push(data);
}
}
@ -603,6 +602,7 @@ async function clearFormPositionSelect() {
function close() {
props.close?.();
clearFormPositionSelect();
isPosition.value = false;
}