| | |
| | | * @LastEditors: shuishen 1109946754@qq.com |
| | | * @LastEditTime: 2025-04-28 11:38:16 |
| | | * @FilePath: \drone-web-manage\src\views\tickets\orderLog.vue |
| | | * @Description: |
| | | * |
| | | * Copyright (c) 2025 by shuishen, All Rights Reserved. |
| | | * @Description: |
| | | * |
| | | * Copyright (c) 2025 by shuishen, All Rights Reserved. |
| | | --> |
| | | <template> |
| | | <basic-container> |
| | | <el-tabs v-model="activeTab" @tab-click="handleTabChange"> |
| | | <el-tab-pane v-for="tab in filteredTabs" :key="tab.name" :label="`${tab.label} (${tab.count})`" :name="tab.name"> |
| | | <div class="tab-content"> |
| | | <basic-main-content> |
| | | <!-- 查询条件筛选栏 --> |
| | | <div class="filter-bar"> |
| | | <div class="search-bar-box"> |
| | |
| | | <!-- 表格部分 --> |
| | | <avue-crud :data="tableData" :option="option" v-model:page="page" ref="crud" :table-loading="loading" |
| | | @current-change="currentChange" @refresh-change="refreshChange" @on-load="onLoad" |
| | | @search-change="searchChange" @size-change="sizeChange"> |
| | | @search-change="searchChange" @size-change="sizeChange" v-if="activeTab === tab.name"> |
| | | <template #menu-left> |
| | | <el-button v-if="hasAddBtnPermission() && activeTab != 'WAIT_AUDIT'" type="primary" icon="el-icon-plus" |
| | | @click="handleAdd">新建工单</el-button> |
| | |
| | | " --> |
| | | <template v-if="row.status == 1"> |
| | | <!--待审核状态--> |
| | | <el-button type="text" icon="el-icon-warning" @click="orderLogRecall(row.id)">撤回</el-button> |
| | | <el-button type="text" icon="el-icon-warning" v-if="hasRecallPaddingBtnPermission()" |
| | | @click="orderLogRecall(row.id)">撤回</el-button> |
| | | <el-button type="text" icon="el-icon-view" @click="handleViewDetail(row)">详情</el-button> |
| | | </template> |
| | | <!--已驳回--> |
| | | <template v-if="row.status == 2"> |
| | |
| | | </el-tooltip> |
| | | </template> |
| | | </avue-crud> |
| | | </div> |
| | | </basic-main-content> |
| | | </el-tab-pane> |
| | | </el-tabs> |
| | | |
| | |
| | | <!-- <el-button type="primary" v-if="form.status == 0 || userInfo.user_id == form.create_user" |
| | | @click="submitForm(0)">保存</el-button> --> |
| | | |
| | | <el-button type="primary" v-if="form.status == 1 && this.permission.orderLogpass" |
| | | <el-button type="primary" v-if="form.status == 1 && hasPaddingBtnPermission()" |
| | | @click="orderLogPass(form.id)">通过</el-button> |
| | | <el-button type="danger" v-if="form.status == 1 && hasRejectionBtnPermission()" |
| | | @click="orderLogReject(form.id)">驳回</el-button> |
| | |
| | | <!-- <el-button type="primary" v-if="form.status == 0 || userInfo.user_id == form.create_user" |
| | | @click="submitForm(0)">保存</el-button> --> |
| | | |
| | | <el-button type="primary" v-if="form.status == 1 && this.permission.orderLogpass" |
| | | <el-button type="primary" v-if="form.status == 1 && hasPaddingBtnPermission()" |
| | | @click="orderLogPass(form.id)">通过</el-button> |
| | | <el-button type="danger" v-if="form.status == 1 && hasRejectionBtnPermission()" |
| | | @click="orderLogReject(form.id)">驳回</el-button> |
| | |
| | | menu: true, |
| | | menuWidth: 210, |
| | | menuClassName: 'cur-menu', |
| | | column: [ |
| | | { label: '工单编号', prop: 'job_info_num', width: 100, ellipsis: true, overHidden: true }, |
| | | { label: '工单名称', prop: 'name', width: 100, ellipsis: true, overHidden: true }, |
| | | { label: '工单状态', prop: 'status', width: 88 }, |
| | | { label: '所属单位', prop: 'dept_name', width: 100, ellipsis: true }, |
| | | { label: '发起时间', prop: 'create_time', width: 144, ellipsis: true }, |
| | | { label: '已执行次数', prop: 'job_num', width: 96, ellipsis: true }, |
| | | { label: '工单内容', prop: 'content', ellipsis: true, overHidden: true }, |
| | | { label: '关联航线', prop: 'wayline_name', width: 100, ellipsis: true, overHidden: true }, |
| | | { label: '关联算法', prop: 'ai_type_str', width: 100, ellipsis: true, overHidden: true }, |
| | | { label: '关联机巢', prop: 'device_names', width: 100, ellipsis: true, overHidden: true }, |
| | | |
| | | { label: '创建人', prop: 'creator_name', width: 96, ellipsis: true, overHidden: true }, |
| | | { label: '关联机巢', prop: 'device_names', width: 112, ellipsis: true, overHidden: true }, |
| | | height: 'auto', |
| | | calcHeight: 196, |
| | | |
| | | column: [ |
| | | { |
| | | label: '工单编号', prop: 'job_info_num', width: 100, ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '工单名称', prop: 'name', width: 100, ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '工单状态', prop: 'status', width: 88, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '所属单位', prop: 'dept_name', width: 100, ellipsis: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '发起时间', prop: 'create_time', width: 144, ellipsis: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '已执行次数', prop: 'job_num', width: 96, ellipsis: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '工单内容', prop: 'content', ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '关联航线', prop: 'wayline_name', width: 100, ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '关联算法', prop: 'ai_type_str', width: 100, ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '关联机巢', prop: 'device_names', width: 100, ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | |
| | | { |
| | | label: '创建人', prop: 'creator_name', width: 96, ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '关联机巢', prop: 'device_names', width: 112, ellipsis: true, overHidden: true, |
| | | showOverflowTooltip: true, |
| | | }, |
| | | { |
| | | label: '工单周期频次', |
| | | prop: '', |
| | |
| | | formatter: row => this.formatCycleTime(row), |
| | | html: true, |
| | | ellipsis: true, |
| | | showOverflowTooltip: true, |
| | | // overHidden: true |
| | | }, |
| | | ], |
| | |
| | | |
| | | //按照航线来 |
| | | const params = { |
| | | type: currentLine.wayline_type, |
| | | type: [2, 4, 5].includes(currentLine.wayline_type) ? 2 : 0, |
| | | wayline_id: waylineId, |
| | | polygon |
| | | } |
| | |
| | | let data = response.data.data |
| | | this.$message.success('审核通过') |
| | | this.detailVisibleCopy = false |
| | | |
| | | this.page.currentPage = 1 |
| | | this.onLoad(this.page, this.query) |
| | | }, |
| | | /** |
| | | * 驳回 |
| | |
| | | }).then(async ({ value }) => { |
| | | let response = await orderLogReject(id, value) |
| | | let data = response.data.data |
| | | this.$message.success('驳回成果') |
| | | this.$message.success('驳回成功') |
| | | this.detailVisibleCopy = false |
| | | |
| | | this.page.currentPage = 1 |
| | | this.onLoad(this.page, this.query) |
| | | }) |
| | | }, |
| | | }, |
| | |
| | | </script> |
| | | |
| | | <style lang="scss" scoped> |
| | | :deep() { |
| | | .avue-crud__body { |
| | | .el-form { |
| | | height: 625px; |
| | | overflow: auto; |
| | | ::v-deep(.el-tabs) { |
| | | height: 100%; |
| | | display: flex; |
| | | flex-direction: column; |
| | | |
| | | .el-tabs__header { |
| | | order: 1; |
| | | } |
| | | |
| | | .el-tabs__content { |
| | | order: 2; |
| | | } |
| | | |
| | | .el-tabs__content { |
| | | height: 0; |
| | | flex: 1; |
| | | display: flex; |
| | | flex-direction: column; |
| | | |
| | | .el-tab-pane { |
| | | height: 0; |
| | | flex: 1; |
| | | display: flex; |
| | | flex-direction: column; |
| | | } |
| | | } |
| | | } |
| | | |
| | | :deep(.el-pagination .el-select) { |
| | | width: 128px !important; |
| | | } |
| | | |
| | | .step-timer { |
| | | position: absolute; |
| | | left: 80%; |
| | | top: 50%; |
| | | transform: translateY(-50%); |
| | | width: 100px; |
| | | margin-left: 4px; |
| | | color: #666; |
| | | font-size: 12px; |
| | | } |
| | | |
| | | :deep(.el-textarea__inner) { |
| | | padding: 8px 12px; |
| | | } |
| | | |
| | | :deep(.el-input__inner), |
| | | :deep(.el-select), |
| | | :deep(.el-select .el-input) { |
| | | width: 100%; // 确保所有输入框和选择框宽度一致 |
| | | } |
| | | |
| | | .tab-content { |
| | | padding: 10px; |
| | | } |
| | | |
| | | .filter-bar { |
| | |
| | | } |
| | | } |
| | | |
| | | :deep(.el-pagination .el-select) { |
| | | width: 128px !important; |
| | | } |
| | | |
| | | .step-timer { |
| | | position: absolute; |
| | | left: 80%; |
| | | top: 50%; |
| | | transform: translateY(-50%); |
| | | width: 100px; |
| | | margin-left: 4px; |
| | | color: #666; |
| | | font-size: 12px; |
| | | } |
| | | |
| | | :deep(.el-textarea__inner) { |
| | | padding: 8px 12px; |
| | | } |
| | | |
| | | :deep(.el-input__inner), |
| | | :deep(.el-select), |
| | | :deep(.el-select .el-input) { |
| | | width: 100%; // 确保所有输入框和选择框宽度一致 |
| | | } |
| | | |
| | | .action-bar { |
| | | margin-bottom: 16px; |
| | | } |
| | |
| | | .el-tabs { |
| | | :deep(.el-tabs__content) { |
| | | overflow: visible; |
| | | } |
| | | } |
| | | |
| | | .tab-content { |
| | | min-height: 200px; |
| | | } |
| | | |
| | | .detail-form { |
| | | :deep(.el-form-item) { |
| | | margin-bottom: 10px; |
| | | } |
| | | |
| | | :deep(.el-form-item__label) { |
| | | color: #606266; |
| | | font-weight: normal; |
| | | } |
| | | |
| | | :deep(.el-form-item__content) { |
| | | color: #303133; |
| | | } |
| | | } |
| | | |
| | |
| | | |
| | | &> ::v-deep(.el-button) { |
| | | flex: 1; |
| | | max-width: 44px; |
| | | margin-left: 0; |
| | | margin-right: 10px; |
| | | |
| | | &:nth-child(4n) { |
| | | margin-left: 0; |
| | | } |
| | | } |
| | | } |
| | | } |