| | |
| | | <!-- header--> |
| | | <div class="main_header" style="flex-direction: row-reverse;"> |
| | | <div class="header_item" style="margin-right:0px"> |
| | | <el-button class="search_btn" icon="el-icon-plus" v-if="showButton('insert')" @click="addRow">新增</el-button> |
| | | <el-button class="search_btn" icon="el-icon-plus" v-permission="'insert'" @click="addRow">新增</el-button> |
| | | </div> |
| | | </div> |
| | | <!-- content--> |
| | |
| | | <el-table-column prop="planOutput" label="总需求(环)" align="center"></el-table-column> |
| | | <el-table-column label="操作" align="center" width="140"> |
| | | <template #default="scope"> |
| | | <el-button class="table_btn" size="mini" v-if="showButton('stop')" |
| | | @click="deleteRow(scope.row)">停用</el-button> |
| | | <el-button class="delete_btn" size="mini" v-if="showButton('update')" |
| | | <el-button class="table_btn" size="mini" v-permission="'stop'" @click="deleteRow(scope.row)">停用</el-button> |
| | | <el-button class="delete_btn" size="mini" v-permission="'update'" |
| | | @click="updateRow(scope.$index)">修改</el-button> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | <!-- detail dialog --> |
| | | <el-dialog class="prop_dialog" v-if="detail.isRenderDetail" title="管片数量" :visible.sync="detail.asyncVisible" |
| | | width="800px"> |
| | | <cpnTable :table-index="true" :table-data="detail.tableData" :table-columns-config="detail.tableColumns" |
| | | <cpnTable :table-index="true" :table-data="detail.tableData" :table-columns="detail.tableColumns" |
| | | :page-total="detail.total" :page-num.sync="detail.pageNum" :page-size.sync="detail.pageSize" |
| | | :page-change="pageChange"> |
| | | </cpnTable> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import {buttonPinia} from '../../pinia/index'; |
| | | import {throttle} from '../../plugins/public'; // 导入节流、动态切换组件尺寸方法 |
| | | import cpnTable from '@/components/table/Table' |
| | | import cpnTable from '@/components/element/Table' |
| | | export default { |
| | | data() { |
| | | return { |
| | |
| | | } |
| | | }) |
| | | }, 1000), |
| | | // 判断按钮权限信息 |
| | | showButton(str) { |
| | | const pinia = buttonPinia(); |
| | | return pinia.$state.buttonInfo.includes(str); |
| | | }, |
| | | changePageNum(page) { |
| | | this.queryInfo.pageNum = page; |
| | | this.getLists(); |
| | |
| | | if (!detailData.tableColumns.length) { |
| | | detailData.tableColumns = [ |
| | | {index: true}, |
| | | {slot: "name"}, |
| | | {name: "环号", key: "ringNum"}, |
| | | {name: "管片编号", key: "pipeNum", width: 140}, |
| | | {name: "转向", key: "turnName", width: 106}, |