|
@@ -30,14 +30,6 @@ const props = defineProps({
|
|
|
}
|
|
|
});
|
|
|
const emits = defineEmits(['update:modelValue', 'close', 'confirm']);
|
|
|
-// watch(
|
|
|
-// () => props.task_id,
|
|
|
-// (new_task_id) => {
|
|
|
-// form.value.task_id = new_task_id;
|
|
|
-// console.log('new_task_id', new_task_id);
|
|
|
-// },
|
|
|
-// { immediate: true }
|
|
|
-// );
|
|
|
|
|
|
const formRef = ref();
|
|
|
|
|
@@ -59,11 +51,16 @@ const handleClose = () => {
|
|
|
emits('update:modelValue', false);
|
|
|
};
|
|
|
|
|
|
+onMounted(()=>{
|
|
|
+ form.value.leader_name = '';
|
|
|
+ form.value.leader_unit = '';
|
|
|
+ form.value.content = '';
|
|
|
+});
|
|
|
//
|
|
|
const handleSubmit = () => {
|
|
|
formRef.value?.validate((valid) => {
|
|
|
if (valid) {
|
|
|
- console.log(form.value);
|
|
|
+ form.value.task_id = props.task_id;
|
|
|
addLeaderInstruction(form.value).then((response)=>{
|
|
|
if (response.code === 200) {
|
|
|
showSuccessMsg('批示成功');
|