|
@@ -6,7 +6,7 @@
|
|
|
v-model="queryParams.planCode"
|
|
|
placeholder="请输入月计划编号"
|
|
|
clearable
|
|
|
-
|
|
|
+
|
|
|
/>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="周计划编号" prop="planCodeW" label-width="120">
|
|
@@ -17,7 +17,7 @@
|
|
|
/>
|
|
|
</el-form-item>
|
|
|
</el-form-item>
|
|
|
-
|
|
|
+
|
|
|
</el-form-item>
|
|
|
<el-form-item label="区县单位" prop="county">
|
|
|
<el-input
|
|
@@ -33,7 +33,7 @@
|
|
|
clearable
|
|
|
/>
|
|
|
</el-form-item>
|
|
|
-
|
|
|
+
|
|
|
<el-form-item label="线路名称" prop="lineName">
|
|
|
<el-input
|
|
|
v-model="queryParams.lineName"
|
|
@@ -46,6 +46,9 @@
|
|
|
<el-form-item>
|
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
|
+ <el-button type="primary" plain size="mini" @click="handleExport"
|
|
|
+ >导出</el-button
|
|
|
+ >
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
<!--el-col :span="1.5">
|
|
@@ -57,7 +60,7 @@
|
|
|
:disabled="maintenancePalan"
|
|
|
@click="uploadMaintenanceFile()"
|
|
|
>上传检修方案</el-button>
|
|
|
-
|
|
|
+
|
|
|
<el-button
|
|
|
type="danger"
|
|
|
plain
|
|
@@ -179,7 +182,7 @@
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
-
|
|
|
+
|
|
|
<pagination
|
|
|
v-show="total>0"
|
|
|
:total="total"
|
|
@@ -187,7 +190,7 @@
|
|
|
:limit.sync="queryParams.pageSize"
|
|
|
@pagination="getList"
|
|
|
/>
|
|
|
-
|
|
|
+
|
|
|
<!-- 添加或修改检修计划全流程管理对话框 -->
|
|
|
<el-dialog :title="title" :visible.sync="open" width="650px" append-to-body>
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
|
|
@@ -248,7 +251,7 @@
|
|
|
<el-button @click="cancel">取 消</el-button>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
-
|
|
|
+
|
|
|
<!-- 文件上传对话框 -->
|
|
|
<el-dialog :title="fileShow" :visible.sync="uploadVisible" width="550px" append-to-body>
|
|
|
<el-form ref="uploadForm" :model="uploadForm" label-width="100px">
|
|
@@ -266,11 +269,11 @@
|
|
|
</el-dialog>
|
|
|
<recordDetails v-if="dialog.detailsSave" ref="detailsDialog" @closed="dialog.detailsSave=false"></recordDetails>
|
|
|
</div>
|
|
|
-
|
|
|
+
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { listProcess, getProcess, delProcess, addProcess, updateProcess } from "@/api/powerdistribution/process";
|
|
|
+import { listProcess, getProcess, delProcess, addProcess, updateProcess,exportProcess } from "@/api/powerdistribution/process";
|
|
|
import recordDetails from './details'
|
|
|
import fileUpload from "./components/fileUpload"
|
|
|
export default {
|
|
@@ -293,7 +296,7 @@ export default {
|
|
|
single: true,
|
|
|
// 非多个禁用
|
|
|
multiple: true,
|
|
|
-
|
|
|
+
|
|
|
// 检修计划
|
|
|
maintenancePalan: true,
|
|
|
// 显示搜索条件
|
|
@@ -454,10 +457,23 @@ export default {
|
|
|
}).catch(() => {});
|
|
|
},
|
|
|
/** 导出按钮操作 */
|
|
|
- handleExport() {
|
|
|
- this.download('powerdistribution/process/export', {
|
|
|
- ...this.queryParams
|
|
|
- }, `process_${new Date().getTime()}.xlsx`)
|
|
|
+ async handleExport() {
|
|
|
+ const res = await exportProcess({
|
|
|
+ ...this.queryParams,
|
|
|
+ });
|
|
|
+ if (res) {
|
|
|
+ const elink = document.createElement("a");
|
|
|
+ elink.download = `检修计划全流程.xlsx`;
|
|
|
+ elink.style.display = "none";
|
|
|
+ const blob = new Blob([res], { type: "application/vnd.ms-excel" });
|
|
|
+ elink.href = URL.createObjectURL(blob);
|
|
|
+ document.body.appendChild(elink);
|
|
|
+ elink.click();
|
|
|
+ document.body.removeChild(elink);
|
|
|
+ window.URL.revokeObjectURL(url);
|
|
|
+ } else {
|
|
|
+ this.$message.error("导出异常请联系管理员");
|
|
|
+ }
|
|
|
},
|
|
|
//查看
|
|
|
table_show(row){
|
|
@@ -507,4 +523,4 @@ export default {
|
|
|
background-color: #ff0000; /* 浅绿色背景色 */
|
|
|
color: #ff0000; /* 绿色文字 */
|
|
|
}
|
|
|
-</style>
|
|
|
+</style>
|