| | |
| | | <!-- 搜索区域 --> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | | <a-row :gutter="24"> |
| | | <a-col :md="12" :sm="8"> |
| | | <a-form-item label="车间名称" :labelCol="{ span: 5 }" :wrapperCol="{ span: 18, offset: 1 }"> |
| | | <a-col :md="8" :sm="8"> |
| | | <a-form-item label="车间名称" :labelCol="{ span: 5 }" :wrapperCol="{ span: 19}"> |
| | | <a-input placeholder="" v-model="queryParam.workshopName"></a-input> |
| | | </a-form-item> |
| | | </a-col> |
| | | <span style="float: left; overflow: hidden" class="table-page-search-submitButtons"> |
| | | <a-col :md="12" :sm="24"> |
| | | <a-button type="primary" @click="searchQuery" icon="search" style="margin-left: 21px">查询</a-button> |
| | | <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button> |
| | | <a-col> |
| | | <a-space> |
| | | <a-button type="primary" @click="searchQuery" icon="search">查询</a-button> |
| | | <a-button type="primary" @click="searchReset" icon="reload">重置</a-button> |
| | | </a-space> |
| | | </a-col> |
| | | </span> |
| | | </a-row> |
| | |
| | | </a-col> |
| | | <a-col :md="rightColMd" :sm="24" v-if="this.rightcolval == 1"> |
| | | <a-card :bordered="false"> |
| | | <div style="text-align: right"> |
| | | <a-icon type="close-circle" @click="hideUserList" /> |
| | | <div @click="hideUserList" class="close-circle"> |
| | | <a-icon type="close-circle"/> |
| | | </div> |
| | | <!-- 查询区域 --> |
| | | <div class="table-page-search-wrapper"> |
| | |
| | | </div> |
| | | <!-- 操作按钮区域 --> |
| | | <div class="table-operator" :md="24" :sm="24"> |
| | | <a-button @click="handleAddDeviceInWorkshop" type="primary" icon="plus" style="margin-top: 16px" |
| | | <a-button @click="handleAddDeviceInWorkshop" type="primary" icon="plus" style="margin: 5px 0 10px 2px" |
| | | >已有设备 |
| | | </a-button> |
| | | |
| | |
| | | </a-button> |
| | | </a-dropdown> |
| | | </div> |
| | | |
| | | <!-- table区域-begin --> |
| | | <div> |
| | | <div class="ant-alert ant-alert-info" style="margin-bottom: 16px"> |
| | |
| | | <!-- 表单区域 --> |
| | | <workshop-modal ref="modalForm" @ok="modalFormOk"></workshop-modal> |
| | | <!--新增车间--> |
| | | <select-device-modal ref="selectUserModal" @selectFinished="selectOK"></select-device-modal> |
| | | <select-device-drawer ref="selectDeviceDrawer" @selectFinished="selectOK" :title="'添加已有设备'"></select-device-drawer> |
| | | <!--已有设备--> |
| | | </a-row> |
| | | </template> |
| | | <script> |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import { deleteAction, postAction, getAction } from '@/api/manage' |
| | | import SelectDeviceModal from './modules/SelectDeviceModal' |
| | | import SelectDeviceDrawer from './modules/SelectDeviceDrawer' |
| | | import WorkshopModal from './modules/WorkshopModal' |
| | | import { filterObj } from '@/utils/util' |
| | | import moment from 'moment' |
| | |
| | | name: 'WorkshopSignageManagement', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | SelectDeviceModal, |
| | | SelectDeviceDrawer, |
| | | WorkshopModal, |
| | | moment, |
| | | }, |
| | |
| | | dataIndex: 'backgroundImage', |
| | | align: 'center', |
| | | scopedSlots: { customRender: 'backgroundImage' }, |
| | | }, |
| | | { |
| | | title: '设备编号颜色', |
| | | dataIndex: 'equipmentIdColor', |
| | | align: 'center', |
| | | }, |
| | | { |
| | | title: '操作', |
| | |
| | | if (res.success) { |
| | | this.dataSource2 = res.result.records |
| | | this.ipagination2.total = res.result.total |
| | | }else{ |
| | | this.dataSource2=[] |
| | | } |
| | | this.loading2 = false |
| | | }) |
| | |
| | | */ |
| | | handleDelete2: function (equipmentId) { |
| | | if (!this.url.delete2) { |
| | | this.$message.error('请设置url.delete2属性!') |
| | | this.$notification.error({ |
| | | message:'消息', |
| | | description:'请设置url.delete2属性!' |
| | | }); |
| | | return |
| | | } |
| | | var that = this |
| | | deleteAction(that.url.delete2, { workshopId: this.currentWorkshopId, equipmentId }).then((res) => { |
| | | if (res.success) { |
| | | that.$message.success(res.message) |
| | | that.$notification.success({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | that.loadData2() |
| | | } else { |
| | | that.$message.warning(res.message) |
| | | that.$notification.warning({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | } |
| | | }) |
| | | }, |
| | |
| | | if (res.success) { |
| | | that.$message.success(res.message) |
| | | that.loadData2() |
| | | that.onClearSelected() |
| | | that.onClearSelected2() |
| | | } else { |
| | | that.$message.warning(res.message) |
| | | } |
| | |
| | | postAction(this.url.addDeviceInWorkshop, params).then((res) => { |
| | | if (res.success) { |
| | | this.loadData2() |
| | | this.$message.success(res.message) |
| | | this.$notification.success({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | } else { |
| | | this.$message.warning(res.message) |
| | | this.$notification.warning({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | } |
| | | }) |
| | | }, |
| | |
| | | if (this.currentWorkshopId == '') { |
| | | this.$message.error('请选择一个车间!') |
| | | } else { |
| | | this.$refs.selectUserModal.visible = true |
| | | this.$refs.selectUserModal.selectedRowKeys = [] |
| | | this.$refs.selectUserModal.selectedRows = [] |
| | | this.$refs.selectDeviceDrawer.visible = true |
| | | this.$refs.selectDeviceDrawer.selectedRowKeys = [] |
| | | this.$refs.selectDeviceDrawer.selectedRows = [] |
| | | this.$refs.selectDeviceDrawer.checkedKeys = [] |
| | | this.$refs.selectDeviceDrawer.expandAll() |
| | | } |
| | | }, |
| | | |
| | |
| | | .ant-btn { |
| | | margin-left: 8px; |
| | | } |
| | | .close-circle{ |
| | | position: absolute; |
| | | z-index: 1; |
| | | right: 15px; |
| | | top: 15px; |
| | | cursor: pointer; |
| | | } |
| | | </style> |