|
@@ -1,56 +1,54 @@
|
|
<template>
|
|
<template>
|
|
<div class="todo-center-container layout-padding">
|
|
<div class="todo-center-container layout-padding">
|
|
<div class="layout-padding-auto layout-padding-view pd15">
|
|
<div class="layout-padding-auto layout-padding-view pd15">
|
|
- <vxe-grid v-bind="gridOptions" v-on="gridEvents" ref="gridRef" @checkbox-all="selectAllChangeEvent" @checkbox-change="selectChangeEvent">
|
|
|
|
- <template #form>
|
|
|
|
- <el-form :model="state.queryParams" ref="ruleFormRef" @submit.native.prevent class="mb10" inline :disabled="state.loading">
|
|
|
|
- <el-form-item label="工单标题" prop="Title">
|
|
|
|
- <el-input v-model.trim="state.queryParams.Title" placeholder="工单标题" clearable @keyup.enter="handleQuery" class="keyword-input" />
|
|
|
|
- </el-form-item>
|
|
|
|
- <el-form-item label="工单编码" prop="No">
|
|
|
|
- <el-input v-model.trim="state.queryParams.No" placeholder="工单编码" clearable @keyup.enter="handleQuery" class="keyword-input" />
|
|
|
|
- </el-form-item>
|
|
|
|
- <el-form-item>
|
|
|
|
- <el-button type="primary" @click="handleQuery" :loading="state.loading"> <SvgIcon name="ele-Search" class="mr5" />查询 </el-button>
|
|
|
|
- <el-button @click="drawer = true" class="default-button"> <SvgIcon name="ele-Search" class="mr5" />更多查询</el-button>
|
|
|
|
- </el-form-item>
|
|
|
|
- </el-form>
|
|
|
|
- </template>
|
|
|
|
- <template #toolbar_buttons>
|
|
|
|
- <el-button type="primary" @click="onJbExport" :loading="state.loading" :disabled="isChecked" v-auth="'todo:center:jbdExport'"
|
|
|
|
- ><SvgIcon name="iconfont icon-daochu" class="mr5" />交办单导出<span v-if="checkTable.length">({{ checkTable.length }})</span>
|
|
|
|
- </el-button>
|
|
|
|
- <el-button type="primary" @click="onAssignOrders" :loading="state.loading" v-auth="'todo:center:assignOrders'"
|
|
|
|
- ><SvgIcon name="ele-List" class="mr5" />分配工单
|
|
|
|
- </el-button>
|
|
|
|
- </template>
|
|
|
|
- <template #statusText="{ row }">
|
|
|
|
- <el-text type="danger" tag="b" v-if="[1, 2, 3, 9, 101, 102, 103, 104, 105, 200].includes(row.status)">{{ row.statusText }}</el-text>
|
|
|
|
- <span v-else>{{ row.statusText }}</span>
|
|
|
|
- </template>
|
|
|
|
- <template #order_detail="{ row }">
|
|
|
|
- <order-detail :order="row" @updateList="handleQuery">{{ row.title }}</order-detail>
|
|
|
|
- </template>
|
|
|
|
- <template #action="{ row }">
|
|
|
|
- <el-button link type="primary" @click="onSign(row)" title="签收工单" v-if="row.canSign" v-auth="'todo:center:sign'"> 签收 </el-button>
|
|
|
|
- <el-button link type="success" @click="onOrderEdit(row)" title="编辑工单" v-if="row.canEdit" v-auth="'todo:center:edit'">
|
|
|
|
- 修改
|
|
|
|
- </el-button>
|
|
|
|
- <el-button link type="primary" @click="onMigration(row)" title="平级移动" v-auth="'todo:center:migration'"> 平级移动 </el-button>
|
|
|
|
- </template>
|
|
|
|
- <template #pager>
|
|
|
|
- <pagination
|
|
|
|
- @pagination="queryList"
|
|
|
|
- :total="state.total"
|
|
|
|
- v-model:current-page="state.queryParams.PageIndex"
|
|
|
|
- v-model:page-size="state.queryParams.PageSize"
|
|
|
|
- :disabled="state.loading"
|
|
|
|
- />
|
|
|
|
- </template>
|
|
|
|
- </vxe-grid>
|
|
|
|
|
|
+ <vxe-grid v-bind="gridOptions" v-on="gridEvents" ref="gridRef" @checkbox-all="selectAllChangeEvent" @checkbox-change="selectChangeEvent">
|
|
|
|
+ <template #form>
|
|
|
|
+ <el-form :model="state.queryParams" ref="ruleFormRef" @submit.native.prevent class="mb10" inline :disabled="state.loading">
|
|
|
|
+ <el-form-item label="工单标题" prop="Title">
|
|
|
|
+ <el-input v-model.trim="state.queryParams.Title" placeholder="工单标题" clearable @keyup.enter="handleQuery" class="keyword-input" />
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item label="工单编码" prop="No">
|
|
|
|
+ <el-input v-model.trim="state.queryParams.No" placeholder="工单编码" clearable @keyup.enter="handleQuery" class="keyword-input" />
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item>
|
|
|
|
+ <el-button type="primary" @click="handleQuery" :loading="state.loading"> <SvgIcon name="ele-Search" class="mr5" />查询 </el-button>
|
|
|
|
+ <el-button @click="drawer = true" class="default-button"> <SvgIcon name="ele-Search" class="mr5" />更多查询</el-button>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </el-form>
|
|
|
|
+ </template>
|
|
|
|
+ <template #toolbar_buttons>
|
|
|
|
+ <el-button type="primary" @click="onJbExport" :loading="state.loading" :disabled="isChecked" v-auth="'todo:center:jbdExport'"
|
|
|
|
+ ><SvgIcon name="iconfont icon-daochu" class="mr5" />交办单导出<span v-if="checkTable.length">({{ checkTable.length }})</span>
|
|
|
|
+ </el-button>
|
|
|
|
+ <el-button type="primary" @click="onAssignOrders" :loading="state.loading" v-auth="'todo:center:assignOrders'"
|
|
|
|
+ ><SvgIcon name="ele-List" class="mr5" />分配工单
|
|
|
|
+ </el-button>
|
|
|
|
+ </template>
|
|
|
|
+ <template #statusText="{ row }">
|
|
|
|
+ <el-text type="danger" tag="b" v-if="[1, 2, 3, 9, 101, 102, 103, 104, 105, 200].includes(row.status)">{{ row.statusText }}</el-text>
|
|
|
|
+ <span v-else>{{ row.statusText }}</span>
|
|
|
|
+ </template>
|
|
|
|
+ <template #order_detail="{ row }">
|
|
|
|
+ <order-detail :order="row" @updateList="refreshList">{{ row.title }}</order-detail>
|
|
|
|
+ </template>
|
|
|
|
+ <template #action="{ row }">
|
|
|
|
+ <el-button link type="primary" @click="onSign(row)" title="签收工单" v-if="row.canSign" v-auth="'todo:center:sign'"> 签收 </el-button>
|
|
|
|
+ <el-button link type="success" @click="onOrderEdit(row)" title="编辑工单" v-if="row.canEdit" v-auth="'todo:center:edit'"> 修改 </el-button>
|
|
|
|
+ <el-button link type="primary" @click="onMigration(row)" title="平级移动" v-auth="'todo:center:migration'"> 平级移动 </el-button>
|
|
|
|
+ </template>
|
|
|
|
+ <template #pager>
|
|
|
|
+ <pagination
|
|
|
|
+ @pagination="queryList"
|
|
|
|
+ :total="state.total"
|
|
|
|
+ v-model:current-page="state.queryParams.PageIndex"
|
|
|
|
+ v-model:page-size="state.queryParams.PageSize"
|
|
|
|
+ :disabled="state.loading"
|
|
|
|
+ />
|
|
|
|
+ </template>
|
|
|
|
+ </vxe-grid>
|
|
</div>
|
|
</div>
|
|
<!-- 工单平移 -->
|
|
<!-- 工单平移 -->
|
|
- <order-migration ref="orderMigrationRef" @updateList="handleQuery" />
|
|
|
|
|
|
+ <order-migration ref="orderMigrationRef" @updateList="refreshList" />
|
|
<!-- 更多查询 -->
|
|
<!-- 更多查询 -->
|
|
<el-drawer v-model="drawer" title="更多查询" size="500px">
|
|
<el-drawer v-model="drawer" title="更多查询" size="500px">
|
|
<el-form :model="state.queryParams" ref="drawerRuleFormRef" @submit.native.prevent label-width="100px">
|
|
<el-form :model="state.queryParams" ref="drawerRuleFormRef" @submit.native.prevent label-width="100px">
|
|
@@ -306,6 +304,10 @@ const handleQuery = () => {
|
|
state.queryParams.PageIndex = 1;
|
|
state.queryParams.PageIndex = 1;
|
|
queryList();
|
|
queryList();
|
|
};
|
|
};
|
|
|
|
+// 刷新列表 停留当前页 重新查询数据和总数
|
|
|
|
+const refreshList = () => {
|
|
|
|
+ queryList();
|
|
|
|
+};
|
|
/** 获取列表 */
|
|
/** 获取列表 */
|
|
const requestParams = ref<EmptyObjectType>({});
|
|
const requestParams = ref<EmptyObjectType>({});
|
|
const queryList = () => {
|
|
const queryList = () => {
|