fix: package => disable work product step checkbox when readonly

This commit is contained in:
puriphatt 2024-11-19 17:38:43 +07:00
parent f6645b0a86
commit 2784922557

View file

@ -108,16 +108,6 @@ watch(
}
},
);
watch(
() => attributes.value.workflowId,
() => {
if (props.readonly) return;
attributes.value.workflowStep.forEach((s) => {
s.productsId = productItems.value.map((p) => p.id);
});
},
);
</script>
<template>
<div class="bordered rounded">
@ -619,7 +609,10 @@ watch(
].productsId.includes(product.id)
"
@click="
toggleCheckProductInStep(product.id, stepIndex)
() => {
if (readonly) return;
toggleCheckProductInStep(product.id, stepIndex);
}
"
size="xs"
/>