|
@@ -75,13 +75,25 @@
|
|
|
|
|
|
<!-- 表单 -->
|
|
|
<examine-form ref="examineRef" :get-list="getList"></examine-form>
|
|
|
+ <el-dialog title="拒绝取消" v-model="cancelEntrust" width="720px" append-to-body size="small" draggable
|
|
|
+ :close-on-click-modal="false">
|
|
|
+ <el-form-item label="拒绝理由" prop="refuseReason" style="margin-top: 10px">
|
|
|
+ <el-input v-model="form.refuseReason" type="textarea" placeholder="请输入取消理由" />
|
|
|
+ </el-form-item>
|
|
|
+ <template #footer>
|
|
|
+ <div class="dialog-footer">
|
|
|
+ <el-button type="primary" icon="Finished" size="small" @click="submitForm">确 定</el-button>
|
|
|
+ <el-button icon="close" size="small" @click="cancelEntrust = false">取 消</el-button>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script setup name="Examine">
|
|
|
- import { listExamine, delExamine } from "@/api/business/examine";
|
|
|
+ import { listExamine, delExamine, refuse } from "@/api/business/examine";
|
|
|
import {
|
|
|
- delEntrust,
|
|
|
+ okDelEntrust,
|
|
|
} from "@/api/business/entrust/currentWorkOrder";
|
|
|
const { proxy } = getCurrentInstance()
|
|
|
/** 字典数组区 */
|
|
@@ -91,6 +103,7 @@
|
|
|
const loading = ref(true);
|
|
|
const ids = ref([])
|
|
|
const single = ref(true);
|
|
|
+ const cancelEntrust = ref(false);
|
|
|
const multiple = ref(true);
|
|
|
const total = ref(0);
|
|
|
/** 查询对象 */
|
|
@@ -102,7 +115,7 @@
|
|
|
cancelReason: null,
|
|
|
status: null,
|
|
|
})
|
|
|
-
|
|
|
+ const form = ref({});
|
|
|
/*********************** 方法区 ****************************/
|
|
|
|
|
|
/** 查询企业租户列表 */
|
|
@@ -141,31 +154,43 @@
|
|
|
|
|
|
/** 修改按钮操作 */
|
|
|
function handleUpdate(row) {
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
proxy.$modal
|
|
|
.confirm("确定同意么?")
|
|
|
.then((_) => {
|
|
|
const entrust = {
|
|
|
workMonth: row.currentPeriod,
|
|
|
- workOrderIds:[row.id],
|
|
|
+ workOrderIds: [row.workOrderId],
|
|
|
+ examineId: row.id
|
|
|
};
|
|
|
- delEntrust(entrust).then((res) => {
|
|
|
+
|
|
|
+ okDelEntrust(entrust).then((res) => {
|
|
|
+ proxy.$modal.msgSuccess("同意成功");
|
|
|
getList();
|
|
|
});
|
|
|
})
|
|
|
.catch((_) => { });
|
|
|
}
|
|
|
-
|
|
|
+ function submitForm() {
|
|
|
+ if(form.value.refuseReason == null){
|
|
|
+ proxy.$modal.msgError("请填写拒绝理由");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ console.log(23,form.value);
|
|
|
+ refuse(form.value).then((res) => {
|
|
|
+ proxy.$modal.msgSuccess("操作成功");
|
|
|
+ getList();
|
|
|
+ cancelEntrust.value = false;
|
|
|
+ });
|
|
|
+ }
|
|
|
|
|
|
/** 删除按钮操作 */
|
|
|
function handleDelete(row) {
|
|
|
- const _ids = row.id || ids.value;
|
|
|
- proxy.$modal.confirm('是否确认删除选中的数据项?').then(function () {
|
|
|
- return delExamine(_ids);
|
|
|
- }).then(() => {
|
|
|
- getList();
|
|
|
- proxy.$modal.msgSuccess("删除成功!");
|
|
|
- }).catch(() => { });
|
|
|
+ cancelEntrust.value = true;
|
|
|
+ form.value.id = row.id
|
|
|
+ console.log(form.value);
|
|
|
+
|
|
|
}
|
|
|
|
|
|
/** 导出按钮操作 */
|