1、全局车间层级以及部门层级树默认展开
2、车间看板页面设备详情弹窗背景透明度改为不透明
3、所有含有车间层级树页面新增弹窗中的选择设备弹窗内容由表格选择调整为树方式
4、报警分析页面表格字段出现次数与合计持续时间增加排序功能以及表格请求数据设置加载中动画
5、设备利用率、设备开动率以及班次利用率页面表格有关时间值调整为小时并保留两位小数以及通过与后端数据联调,增加表格平均值及合计值展示
6、设备综合效率分析页面表格班次字段若数据过长则省略
7、用户管理页面添加用户与重新设定密码弹窗中的登录密码校验长度与数据字典password_length设置保持一致以及表格车间字段若数据过长则省略
| | |
| | | <div style="width: 100%; height: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <a-row type="flex" :gutter="16"> |
| | | <a-col :md="4"> |
| | | <a-col :md="5"> |
| | | <a-tabs :activeKey="activeKey" @change="tabChange"> |
| | | <a-tab-pane key="1" tab="车间层级" force-render> |
| | | <base-tree @getCurrSelected="changeSelectionNode"></base-tree> |
| | |
| | | </a-tab-pane> |
| | | </a-tabs> |
| | | </a-col> |
| | | <a-col :md="20"> |
| | | <a-col :md="19"> |
| | | <efficiencyPO-list ref="EfficiencyPOList" :nodeTree='selectEquement' :nodePeople='selectPeople' :Type="slectTypeTree"/> |
| | | </a-col> |
| | | </a-row> |
| | |
| | | <div style="width: 100%; height: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <a-row type="flex" :gutter="16"> |
| | | <a-col :md="4"> |
| | | <a-col :md="5"> |
| | | <a-tabs :activeKey="activeKey" @change="tabChange"> |
| | | <a-tab-pane key="1" tab="车间层级" force-render> |
| | | <base-tree @getCurrSelected="changeSelectionNode"></base-tree> |
| | |
| | | </a-tab-pane> |
| | | </a-tabs> |
| | | </a-col> |
| | | <a-col :md="20"> |
| | | <a-col :md="19"> |
| | | <EfficiencyList ref="EfficiencyList" :nodePeople='selectPeople' :nodeTree = 'selectEquement' :Type="slectTypeTree"></EfficiencyList> |
| | | </a-col> |
| | | </a-row> |
| | |
| | | this.allTreeKeys = [] |
| | | this.treeDataSource = res.result |
| | | this.generateList(res.result) |
| | | this.expandedKeys=this.allTreeKeys |
| | | } else { |
| | | // this.$message.warn(res.message) |
| | | this.$notification.warning({ |
| | |
| | | <a-col :span="24"> |
| | | <a-form-item label="设备组" :labelCol="labelColLong" :wrapperCol="wrapperColLong"> |
| | | <a-input-search :readOnly="true" v-decorator="['equipmentIds', validatorRules.equipmentIds]" |
| | | @search="deviceSearch" enter-button/> |
| | | @search="deviceSearch" enter-button placeholder="请选择设备"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | |
| | | </a-form> |
| | | </a-spin> |
| | | <holiday-management-modal-list ref="deviceRepairListModel" @sendSelectionRows="getDeviceRows"></holiday-management-modal-list> |
| | | |
| | | <select-device-modal ref="selectDeviceModal" @selectFinished="selectOK" :title="'选择设备'"/> |
| | | </a-modal> |
| | | </template> |
| | | |
| | |
| | | import { |
| | | duplicateCheck |
| | | } from '@/api/api' |
| | | import SelectDeviceModal from '../../../../system/modules/SelectDeviceModal' |
| | | |
| | | export default { |
| | | name: 'HolidayManagementModal', |
| | | components: {HolidayManagementModalList}, |
| | | components: { SelectDeviceModal, HolidayManagementModalList}, |
| | | props: {}, |
| | | data() { |
| | | return { |
| | |
| | | // }) |
| | | }, |
| | | deviceSearch() { |
| | | this.$refs.deviceRepairListModel.openPage() |
| | | this.$refs.deviceRepairListModel.title = '选择设备' |
| | | this.$refs.deviceRepairListModel.disableSubmit = false |
| | | this.$refs.selectDeviceModal.visible = true |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.form.getFieldValue('equipmentIds') ? this.form.getFieldValue('equipmentIds').split(',') : [] |
| | | }, |
| | | //级联框onChange事件 |
| | | // onChange(value) { |
| | |
| | | }, |
| | | checkboxChange(e) { |
| | | this.checked = e.target.checked |
| | | }, |
| | | |
| | | /** |
| | | * 选择已有设备后点击确定时触发 |
| | | * @param data 已选择的设备 |
| | | */ |
| | | selectOK(data) { |
| | | // let params = {} |
| | | // params.equipmentIdList = [] |
| | | // for (var a = 0; a < data.length; a++) { |
| | | // params.equipmentIdList.push(data[a]) |
| | | // } |
| | | console.log('data=', data) |
| | | this.form.setFieldsValue({ |
| | | equipmentIds: data.join(',') |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | <div class="container" id="EfficiencyShift" style="margin-top: 20px;"> |
| | | <div class="table2"> |
| | | <a-table :columns="columns" :dataSource="dataSource.records" :pagination="false" bordered |
| | | :scroll="{ x: 3000, y: false }"> |
| | | :scroll="{ x: 3200, y: false }"> |
| | | </a-table> |
| | | </div> |
| | | </div> |
| | |
| | | { |
| | | title: '设备名称', |
| | | align: 'center', |
| | | width: 150, |
| | | width: 200, |
| | | dataIndex: 'equipmentName' |
| | | // fixed: 'left' |
| | | }, |
| | |
| | | { |
| | | title: '班次', |
| | | align: 'center', |
| | | width: 80, |
| | | dataIndex: 'shift' |
| | | width: 300, |
| | | dataIndex: 'shift', |
| | | ellipsis: true, |
| | | }, |
| | | { |
| | | title: '每班小时', |
| | |
| | | <a-col :span="24"> |
| | | <a-form-item label="设备组" :labelCol="labelColLong" :wrapperCol="wrapperColLong"> |
| | | <a-input-search :readOnly="true" v-decorator="['equipmentIds', validatorRules.equipmentIds]" |
| | | @search="deviceSearch" enter-button/> |
| | | @search="deviceSearch" enter-button placeholder="请选择设备"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | |
| | | <a-row :gutter="24"> |
| | | <a-col :span="24"> |
| | | <a-form-item label="备注" :labelCol="labelColLong" :wrapperCol="wrapperColLong"> |
| | | <a-textarea :maxLength="20" v-decorator="['notes', validatorRules.notes]" placeholder="请输入备注" ></a-textarea> |
| | | <a-textarea :maxLength="20" v-decorator="['notes', validatorRules.notes]" |
| | | placeholder="请输入备注"></a-textarea> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | | </a-form> |
| | | </a-spin> |
| | | <torqueconfiguration-modal-list ref="deviceRepairListModel" @sendSelectionRows="getDeviceRows"></torqueconfiguration-modal-list> |
| | | |
| | | <select-device-modal ref="selectDeviceModal" @selectFinished="selectOK" :title="'选择设备'"/> |
| | | </a-modal> |
| | | </template> |
| | | |
| | |
| | | import { |
| | | duplicateCheck |
| | | } from '@/api/api' |
| | | import SelectDeviceModal from '../../../../system/modules/SelectDeviceModal' |
| | | |
| | | export default { |
| | | name: 'TorqueconfigurationModal', |
| | | components: {TorqueconfigurationModalList}, |
| | | components: { SelectDeviceModal }, |
| | | props: {}, |
| | | data() { |
| | | return { |
| | |
| | | show: false, |
| | | model: {}, |
| | | checked: false, |
| | | startData:"", |
| | | endData:"", |
| | | startData: '', |
| | | endData: '', |
| | | labelCol: { |
| | | xs: { |
| | | span: 24 |
| | |
| | | rules:[ |
| | | { |
| | | required:true, |
| | | message: "请选择设备" |
| | | }, |
| | | ], |
| | | message: '请选择设备' |
| | | } |
| | | ] |
| | | }, |
| | | torqueDate:{ |
| | | rules:[ |
| | | { |
| | | required:true, |
| | | message: "请选择时间" |
| | | }, |
| | | ], |
| | | message: '请选择时间' |
| | | } |
| | | ] |
| | | }, |
| | | torqueValue:{ |
| | | rules:[ |
| | | { |
| | | required:true, |
| | | message: "请输入扭矩值" |
| | | }, |
| | | ], |
| | | }, |
| | | message: '请输入扭矩值' |
| | | } |
| | | ] |
| | | } |
| | | }, |
| | | |
| | | url: { |
| | |
| | | // // console.log(this.startData,this.endData); |
| | | // }, |
| | | onChangeEnd(dates, dateStrings){ |
| | | this.endTime = dateStrings[0]; |
| | | this.endTime = dateStrings[0] |
| | | }, |
| | | getDeviceRows(val) { |
| | | var equipmentIds; |
| | | var equipmentIds |
| | | for(var i = 0;i<val.length;i++){ |
| | | if (i == 0) { |
| | | equipmentIds = val[i].equipmentId; |
| | | equipmentIds = val[i].equipmentId |
| | | } else { |
| | | equipmentIds = equipmentIds + "," + val[i].equipmentId; |
| | | equipmentIds = equipmentIds + ',' + val[i].equipmentId |
| | | } |
| | | } |
| | | // console.log("========",equipmentIds); |
| | | this.form.setFieldsValue({ |
| | | equipmentIds: equipmentIds, |
| | | equipmentIds: equipmentIds |
| | | }) |
| | | // this.form.setFieldsValue({ |
| | | // equipmentId: val.equipmentId, |
| | |
| | | // }) |
| | | }, |
| | | deviceSearch() { |
| | | this.$refs.deviceRepairListModel.openPage() |
| | | this.$refs.deviceRepairListModel.title = '选择设备' |
| | | this.$refs.deviceRepairListModel.disableSubmit = false |
| | | this.$refs.selectDeviceModal.visible = true |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.form.getFieldValue('equipmentIds') ? this.form.getFieldValue('equipmentIds').split(',') : [] |
| | | }, |
| | | //级联框onChange事件 |
| | | // onChange(value) { |
| | |
| | | this.model = Object.assign({}, record) |
| | | this.visible = true |
| | | this.$nextTick(() => { |
| | | this.form.setFieldsValue(pick(this.model, 'equipmentIds', 'equipmentName', 'mdcRepairType', 'startTime', 'endTime', |
| | | this.form.setFieldsValue(pick(this.model, 'equipmentIds', 'equipmentName', 'mdcRepairType', 'startTime', 'endTime' |
| | | )) |
| | | }) |
| | | }, |
| | |
| | | // that.$message.success("添加成功") |
| | | that.$notification.success({ |
| | | message:'消息', |
| | | description:"添加成功" |
| | | }); |
| | | description: '添加成功' |
| | | }) |
| | | // that.$message.success(res.message) |
| | | that.$emit('ok', res.result) |
| | | } else { |
| | |
| | | that.$notification.warning({ |
| | | message:'消息', |
| | | description:res.message |
| | | }); |
| | | }) |
| | | } |
| | | }).finally(() => { |
| | | that.confirmLoading = false |
| | |
| | | }, |
| | | checkboxChange(e) { |
| | | this.checked = e.target.checked |
| | | }, |
| | | |
| | | /** |
| | | * 选择已有设备后点击确定时触发 |
| | | * @param data 已选择的设备 |
| | | */ |
| | | selectOK(data) { |
| | | // let params = {} |
| | | // params.equipmentIdList = [] |
| | | // for (var a = 0; a < data.length; a++) { |
| | | // params.equipmentIdList.push(data[a]) |
| | | // } |
| | | console.log('data=', data) |
| | | this.form.setFieldsValue({ |
| | | equipmentIds: data.join(',') |
| | | }) |
| | | } |
| | | |
| | | } |
| | | } |
| | | </script> |
| | |
| | | .ant-tabs-content .ant-form-item { |
| | | margin-bottom: 0px; |
| | | } |
| | | |
| | | /deep/ .ant-input-number{ |
| | | width: 100%!important; |
| | | } |
| | |
| | | <a-col :span="24"> |
| | | <a-form-item label="设备组" :labelCol="labelColLong" :wrapperCol="wrapperColLong"> |
| | | <a-input-search :readOnly="true" v-decorator="['equipmentIds', validatorRules.equipmentIds]" |
| | | @search="deviceSearch" enter-button/> |
| | | @search="deviceSearch" enter-button placeholder="请选择设备"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | |
| | | </a-row> |
| | | </a-form> |
| | | </a-spin> |
| | | <plan-downtime-maintenance-modal-list ref="deviceRepairListModel" @sendSelectionRows="getDeviceRows"></plan-downtime-maintenance-modal-list> |
| | | |
| | | <select-device-modal ref="selectDeviceModal" @selectFinished="selectOK" :title="'选择设备'"/> |
| | | </a-modal> |
| | | </template> |
| | | |
| | | <script> |
| | | import moment from 'moment' |
| | | import pick from 'lodash.pick' |
| | | import PlanDowntimeMaintenanceModalList from './UnplannedDowntimemManagerModalList' |
| | | import JDate from '../deviceRepair/JDate' |
| | | import { |
| | | getAction, |
| | |
| | | import { |
| | | duplicateCheck |
| | | } from '@/api/api' |
| | | import SelectDeviceModal from '../../../../system/modules/SelectDeviceModal' |
| | | |
| | | export default { |
| | | name: 'UnplannedDowntimemManagerModal', |
| | | components: {PlanDowntimeMaintenanceModalList,JDate}, |
| | | components: { SelectDeviceModal,JDate}, |
| | | props: {}, |
| | | data() { |
| | | return { |
| | |
| | | // }) |
| | | }, |
| | | deviceSearch() { |
| | | this.$refs.deviceRepairListModel.openPage() |
| | | this.$refs.deviceRepairListModel.title = '选择设备' |
| | | this.$refs.deviceRepairListModel.disableSubmit = false |
| | | this.$refs.selectDeviceModal.visible = true |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.form.getFieldValue('equipmentIds') ? this.form.getFieldValue('equipmentIds').split(',') : [] |
| | | }, |
| | | //级联框onChange事件 |
| | | // onChange(value) { |
| | |
| | | }, |
| | | checkboxChange(e) { |
| | | this.checked = e.target.checked |
| | | }, |
| | | |
| | | /** |
| | | * 选择已有设备后点击确定时触发 |
| | | * @param data 已选择的设备 |
| | | */ |
| | | selectOK(data) { |
| | | // let params = {} |
| | | // params.equipmentIdList = [] |
| | | // for (var a = 0; a < data.length; a++) { |
| | | // params.equipmentIdList.push(data[a]) |
| | | // } |
| | | console.log('data=', data) |
| | | this.form.setFieldsValue({ |
| | | equipmentIds: data.join(',') |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | /*background: -ms-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ |
| | | /*background: linear-gradient(to right, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ |
| | | background-color: #312c2c; |
| | | opacity: 0.7; |
| | | opacity: 1; |
| | | } |
| | | |
| | | /deep/ .ant-modal-close { |
| | |
| | | <!--</table>--> |
| | | <!--</div>--> |
| | | <!--</div>--> |
| | | <a-table :columns="columns" :data-source="dataList" bordered :pagination="false" :scroll="{y:168}" |
| | | <a-table :columns="columns" :data-source="dataList" bordered :pagination="false" :scroll="{y:210}" |
| | | :customRow="customRow" |
| | | rowKey="alarmCode" |
| | | rowKey="alarmCode" @expand="handleExpandChange" |
| | | > |
| | | <span slot="timeCount" slot-scope="text">{{getFormattedTime(text)}}</span> |
| | | <!--<a-table--> |
| | |
| | | <!--:data-source="row.innerDataList"--> |
| | | <!--:pagination="false"--> |
| | | <!--rowKey="equipmentId"--> |
| | | <!--:loading="loading"--> |
| | | <!-->--> |
| | | <!--<span slot="duration" slot-scope="text">{{getFormattedTime(text)}}</span>--> |
| | | <!--</a-table>--> |
| | |
| | | |
| | | const columns = [ |
| | | { title: '报警号', dataIndex: 'alarmCode', key: 'alarmCode', align: 'center' }, |
| | | { title: '出现次数', dataIndex: 'count', key: 'count', align: 'center' }, |
| | | { title: '出现次数', dataIndex: 'count', key: 'count', align: 'center', sorter: (a, b) => b.count - a.count }, |
| | | { |
| | | title: '合计持续时间', |
| | | dataIndex: 'timeCount', |
| | | key: 'timeCount', |
| | | scopedSlots: { customRender: 'timeCount' }, |
| | | align: 'center' |
| | | align: 'center', |
| | | sorter: (a, b) => b.timeCount - a.timeCount |
| | | }, |
| | | { title: '报警信息', dataIndex: 'alarmContent', key: 'alarmContent', align: 'center' } |
| | | ] |
| | |
| | | XData: [0], |
| | | YData: [0], |
| | | columns, |
| | | innerColumns |
| | | innerColumns, |
| | | hasRequsetAlarmCodeList: [] |
| | | } |
| | | }, |
| | | props: { nodeTree: '', Type: '', nodePeople: '' }, |
| | |
| | | if (res.success) { |
| | | // this.tableHeads = res.result.dates |
| | | this.dataList = res.result |
| | | this.dataList[0].innerDataList=[ |
| | | { |
| | | equipmentId: '11234', |
| | | equipmentName: '立体机床', |
| | | alarmTime: 20, |
| | | endTime: 20, |
| | | duration: 123 |
| | | }, |
| | | { |
| | | equipmentId: '4213', |
| | | equipmentName: '卧室机床', |
| | | alarmTime: 312, |
| | | endTime: 31, |
| | | duration: 421 |
| | | } |
| | | ] |
| | | this.dataList[1].innerDataList=[ |
| | | { |
| | | equipmentId: '4213', |
| | | equipmentName: '卧室机床', |
| | | alarmTime: 312, |
| | | endTime: 31, |
| | | duration: 421 |
| | | } |
| | | ] |
| | | this.hasRequsetAlarmCodeList = [] |
| | | // this.draw() |
| | | // this.checkSameData(this.dataList) |
| | | // this.checkSameData1(this.dataList) |
| | |
| | | } |
| | | }, |
| | | |
| | | /** |
| | | * 自定义展开表格图标 |
| | | * @param props 图标属性 |
| | | * @returns {null} 若主表数据下无数据则不显示图标 |
| | | */ |
| | | expandIcon(props){ |
| | | console.log('props',props) |
| | | if (props.record.innerDataList&&props.record.innerDataList.length>0){ |
| | | if (props.expanded) { |
| | | return <a style="margin-right:0px;color:#999" onClick={e=> { |
| | | props.onExpand(props.record, e); |
| | | }}><a-icon type="minus" /></a> |
| | | } else{ |
| | | return <a style="margin-right:0px;color:#999" onClick={e => { |
| | | props.onExpand(props.record, e); |
| | | }}><a-icon type="plus"/></a> |
| | | handleExpandChange(expanded, record) { |
| | | console.log('expanded', expanded, 'record', record) |
| | | let _this = this |
| | | // 当展开时若该行未被展开过才会请求后台数据,展开过的数据会被缓存无需重复请求 |
| | | if (expanded && !this.hasRequsetAlarmCodeList.includes(record.alarmCode)) { |
| | | this.loading = true |
| | | setTimeout(() => { |
| | | _this.dataList.forEach(item => { |
| | | if (record.alarmCode === item.alarmCode) { |
| | | item.innerDataList = [ |
| | | { |
| | | equipmentId: '11234', |
| | | equipmentName: '立体机床', |
| | | alarmTime: 20, |
| | | endTime: 20, |
| | | duration: 123 |
| | | }, |
| | | { |
| | | equipmentId: '4213', |
| | | equipmentName: '卧室机床', |
| | | alarmTime: 312, |
| | | endTime: 31, |
| | | duration: 421 |
| | | } |
| | | }else{ |
| | | return null |
| | | ] |
| | | } |
| | | }) |
| | | this.loading = false |
| | | }, 1000) |
| | | this.hasRequsetAlarmCodeList.push(record.alarmCode) |
| | | } |
| | | } |
| | | |
| | | // /** |
| | | // * 自定义展开表格图标 |
| | | // * @param props 图标属性 |
| | | // * @returns {null} 若主表数据下无数据则不显示图标 |
| | | // */ |
| | | // expandIcon(props){ |
| | | // console.log('props',props) |
| | | // if (props.record.innerDataList&&props.record.innerDataList.length>0){ |
| | | // if (props.expanded) { |
| | | // return <a style="margin-right:0px;color:#999" onClick={e=> { |
| | | // props.onExpand(props.record, e); |
| | | // }}><a-icon type="minus" /></a> |
| | | // } else{ |
| | | // return <a style="margin-right:0px;color:#999" onClick={e => { |
| | | // props.onExpand(props.record, e); |
| | | // }}><a-icon type="plus"/></a> |
| | | // } |
| | | // }else{ |
| | | // return null |
| | | // } |
| | | // } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | height: 100%; |
| | | } |
| | | |
| | | /deep/ .ant-table.ant-table-bordered { |
| | | height: 265px; |
| | | } |
| | | |
| | | /deep/ .ant-table-scroll>.ant-table-placeholder { |
| | | height: 210px; |
| | | } |
| | | </style> |
| | |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.queryParam.equipmentId.split(',') |
| | | this.$refs.selectDeviceModal.expandAll() |
| | | }, |
| | | |
| | | /** |
| | |
| | | <a-col :span="24"> |
| | | <a-form-item label="设备组" :labelCol="labelColLong" :wrapperCol="wrapperColLong"> |
| | | <a-input-search :readOnly="true" v-decorator="['equipmentId', validatorRules.equipmentId]" |
| | | @search="deviceSearch" enter-button/> |
| | | @search="deviceSearch" enter-button placeholder="请选择设备"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | |
| | | </a-form> |
| | | </a-spin> |
| | | <device-calend-list-model ref="deviceRepairListModel" @sendSelectionRows="getDeviceRows"></device-calend-list-model> |
| | | <select-device-modal ref="selectDeviceModal" @selectFinished="selectOK" :title="'选择设备'"/> |
| | | </a-modal> |
| | | </div> |
| | | </template> |
| | |
| | | } from '@/api/api' |
| | | |
| | | import Calendar from 'vue-calendar-component'; |
| | | import SelectDeviceModal from '../../../../system/modules/SelectDeviceModal' |
| | | |
| | | export default { |
| | | name: 'ShiftInfoModel', |
| | | components: {DeviceCalendListModel,Calendar}, |
| | | components: { SelectDeviceModal, DeviceCalendListModel,Calendar}, |
| | | props: {}, |
| | | data() { |
| | | return { |
| | |
| | | this.value = value; |
| | | }, |
| | | deviceSearch() { |
| | | this.$refs.deviceRepairListModel.openPage() |
| | | this.$refs.deviceRepairListModel.title = '选择设备' |
| | | this.$refs.deviceRepairListModel.disableSubmit = false |
| | | this.$refs.selectDeviceModal.visible = true |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.form.getFieldValue('equipmentId') ? this.form.getFieldValue('equipmentId').split(',') : [] |
| | | }, |
| | | getDeviceRows(val) { |
| | | console.log("========",val); |
| | |
| | | this.close() |
| | | }, |
| | | |
| | | /** |
| | | * 选择已有设备后点击确定时触发 |
| | | * @param data 已选择的设备 |
| | | */ |
| | | selectOK(data) { |
| | | // let params = {} |
| | | // params.equipmentIdList = [] |
| | | // for (var a = 0; a < data.length; a++) { |
| | | // params.equipmentIdList.push(data[a]) |
| | | // } |
| | | console.log('data=', data) |
| | | this.form.setFieldsValue({ |
| | | equipmentId: data.join(',') |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | <!--</a-form-item>--> |
| | | <a-form-item label="设备组" :labelCol="labelColLong" :wrapperCol="wrapperColLong"> |
| | | <a-input-search :readOnly="true" v-decorator="['equipmentIds', validatorRules.equipmentIds]" |
| | | @search="deviceSearch" enter-button/> |
| | | @search="deviceSearch" enter-button placeholder="请选择设备"/> |
| | | <!--<a-input :disabled="disableSubmit" :readOnly="disableSubmit" allow-clear placeholder="请输入设备编号"--> |
| | | <!--v-decorator="['equipmentId',validatorRules.equipmentId]"/>--> |
| | | </a-form-item> |
| | |
| | | <!--</a-row>--> |
| | | </a-form> |
| | | </a-spin> |
| | | <device-repair-list-model ref="deviceRepairListModel" @sendSelectionRows="getDeviceRows" |
| | | :selectedEquipmentIds="selectedEquipmentIds" |
| | | ></device-repair-list-model> |
| | | |
| | | <select-device-modal ref="selectDeviceModal" @selectFinished="selectOK" :title="'选择设备'"/> |
| | | </a-modal> |
| | | </template> |
| | | |
| | | <script> |
| | | import moment from 'moment' |
| | | import pick from 'lodash.pick' |
| | | import DeviceRepairListModel from './DeviceRepairListModel' |
| | | import JDate from './JDate' |
| | | import { |
| | | getAction, |
| | |
| | | import { |
| | | duplicateCheck |
| | | } from '@/api/api' |
| | | import AFormItem from 'ant-design-vue/es/form/FormItem' |
| | | import Vue from 'vue' |
| | | import SelectDeviceModal from '../../../../system/modules/SelectDeviceModal' |
| | | |
| | | export default { |
| | | name: 'DeviceRepairModel', |
| | | components: { AFormItem, DeviceRepairListModel, JDate }, |
| | | components: { SelectDeviceModal, JDate }, |
| | | props: { |
| | | equipmentId: { |
| | | type: String |
| | |
| | | // }) |
| | | }, |
| | | deviceSearch() { |
| | | this.$refs.deviceRepairListModel.openPage() |
| | | this.$refs.deviceRepairListModel.title = '选择设备' |
| | | this.$refs.deviceRepairListModel.disableSubmit = false |
| | | this.$refs.selectDeviceModal.visible = true |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.form.getFieldValue('equipmentIds') ? this.form.getFieldValue('equipmentIds').split(',') : [] |
| | | }, |
| | | //级联框onChange事件 |
| | | // onChange(value) { |
| | |
| | | return { |
| | | disabledSeconds: () => this.range(1, 60) |
| | | } |
| | | }, |
| | | |
| | | /** |
| | | * 选择已有设备后点击确定时触发 |
| | | * @param data 已选择的设备 |
| | | */ |
| | | selectOK(data) { |
| | | // let params = {} |
| | | // params.equipmentIdList = [] |
| | | // for (var a = 0; a < data.length; a++) { |
| | | // params.equipmentIdList.push(data[a]) |
| | | // } |
| | | console.log('data=', data) |
| | | this.form.setFieldsValue({ |
| | | equipmentIds: data.join(',') |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | </tr> |
| | | </table> |
| | | </div> |
| | | <a-spin :spinning="spinning"> |
| | | <div class="container" id="EfficiencyPO" style="margin-top: 20px;"> |
| | | <div class="table2"> |
| | | <table class="dataContent table" border="1" cellspacing="0" cellpadding="0" style="white-space: nowrap"> |
| | | <table class="dataContent table" border="1" cellspacing="0" cellpadding="0" style="white-space: nowrap" v-if="dataList.length>0"> |
| | | <thead> |
| | | <tr class="thead fixed equipname"> |
| | | <th class="thgu dong1 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong2 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong3 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong1 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">公司</th> |
| | | <th class="thgu dong2 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">车间</th> |
| | | <th class="thgu dong3 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">工段</th> |
| | | <th class="thgu dong4 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备编号</th> |
| | | <th class="thgu dong5 name" rowspan="2" style="min-width: 150px; max-width: 150px;width: 150px;">设备名称</th> |
| | | <th class="thgu dong5 name" rowspan="2" style="min-width: 162px; max-width: 162px;width: 162px;">设备名称</th> |
| | | <th class="thgu dong6 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备类型</th> |
| | | <!--<th rowspan="2">组别</th>--> |
| | | <template v-for="(tableHead, index) in tableHeads"> |
| | |
| | | <template v-for="(tableHead, index) in tableHeads"> |
| | | <th>开动率(%)</th> |
| | | <th v-if="checkedList.indexOf('kjl') > -1">开机率(%)</th> |
| | | <th v-if="checkedList.indexOf('kjsj') > -1">开机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('jgsj') > -1">加工时间(s)</th> |
| | | <th v-if="checkedList.indexOf('djsj') > -1">待机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('gjsj') > -1">关机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('kjsj') > -1">开机时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('jgsj') > -1">加工时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('djsj') > -1">待机时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('gjsj') > -1">关机时间(小时)</th> |
| | | </template> |
| | | </tr> |
| | | </thead> |
| | | <tbody> |
| | | <tr class="mathData" v-for="(item, index) in dataList"> |
| | | <template v-if="item.level1!=='合计'&&item.level1!=='平均值'"> |
| | | <td class="tdgu kaitou wenzi" :rowspan="item.level1span" :class="{hidden: item.level1dis,noExl:item.level1dis}" v-show="!item.level1dis">{{item.level1}}</td> |
| | | <td class="tdgu1 kaitou wenzi" :rowspan="item.level2span" :class="{hidden: item.level2dis,noExl:item.level2dis}" v-show="!item.level2dis">{{item.level2}}</td> |
| | | <td class="tdgu2 kaitou wenzi" :rowspan="item.level3span" :class="{hidden: item.level3dis,noExl:item.level3dis}" v-show="!item.level3dis">{{item.level3}}</td> |
| | | <td class="tdgu3 kaitou">{{item.equipmentId}}</td> |
| | | <td class="tdgu4 kaitou">{{item.equipmentName}}</td> |
| | | <td style="min-width: 162px; max-width: 162px;width: 162px;" class="tdgu4 kaitou">{{item.equipmentName}}</td> |
| | | <td class="tdgu5 kaitou">{{item.equipmentType}}</td> |
| | | </template> |
| | | |
| | | <template v-else> |
| | | <td colspan="6" class="tdgu kaitou">{{item.level1}}</td> |
| | | </template> |
| | | <!--<td>{{item.tierType}}</td>--> |
| | | <template v-for="(tableHead, index) in item.dataList"> |
| | | <td :style="{background:tableHead.color }">{{tableHead.startRate | numFilter}}</td> |
| | |
| | | {{tableHead.openRate | numFilter}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('kjsj') > -1"> |
| | | {{tableHead.openLong}} |
| | | {{tableHead.openLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('jgsj') > -1"> |
| | | {{tableHead.processLong}} |
| | | {{tableHead.processLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('djsj') > -1"> |
| | | {{tableHead.waitLong}} |
| | | {{tableHead.waitLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('gjsj') > -1"> |
| | | {{tableHead.closeLong}} |
| | | {{tableHead.closeLong | getFormattedTime}} |
| | | </td> |
| | | </template> |
| | | </tr> |
| | |
| | | </table> |
| | | </div> |
| | | </div> |
| | | </a-spin> |
| | | </div> |
| | | </div> |
| | | </template> |
| | |
| | | listByType: '/mdc/MdcUtilizationRate/getByType', |
| | | queryEquipmentType: '/mdc/mdcEquipmentType/queryEquipmentType' |
| | | }, |
| | | tableHeads: [] |
| | | tableHeads: [], |
| | | spinning:false |
| | | } |
| | | }, |
| | | props: { nodeTree: '', Type:'',nodePeople: ''}, |
| | |
| | | } else { |
| | | return '0' |
| | | } |
| | | }, |
| | | |
| | | /** |
| | | * 格式化时间 |
| | | * @param seconds 秒数 |
| | | * @returns '' 格式化后时间字符串 |
| | | */ |
| | | getFormattedTime(seconds) { |
| | | if (seconds) { |
| | | return parseFloat((seconds / 3600).toFixed(2)) + '小时' |
| | | } else { |
| | | return '0' |
| | | } |
| | | }, |
| | | }, |
| | | methods: { |
| | | checkSameData(dataList){ |
| | |
| | | // this.onClearSelected() |
| | | }, |
| | | loadData() { |
| | | this.spinning=true |
| | | this.tableHeads = [] |
| | | this.dataList = [] |
| | | getAction(this.url.list, this.queryParam).then(res => { |
| | |
| | | this.combineCell(); |
| | | // this.initDeviceType(this.dataList) |
| | | } |
| | | }).finally(()=>{ |
| | | this.spinning=false |
| | | }) |
| | | }, |
| | | queryGroup() { |
| | |
| | | } |
| | | .table tbody tr .tdgu5{ |
| | | position: sticky; |
| | | left: 400px; |
| | | left: 412px; |
| | | z-index: 2; |
| | | } |
| | | |
| | |
| | | } |
| | | .table2 thead .equipname .dong6{ |
| | | z-index: 5; |
| | | left: 400px; |
| | | left: 412px; |
| | | } |
| | | |
| | | |
| | |
| | | <a-row :gutter="24"> |
| | | <a-col :md="4" :sm="4"> |
| | | <a-form-item label="设备类型"> |
| | | <a-select placeholder="请选择设备类型" :triggerChange="true" v-model="queryParam.equipmentType" :allowClear="true"> |
| | | <a-select placeholder="请选择设备类型" :triggerChange="true" v-model="queryParam.equipmentType" |
| | | :allowClear="true"> |
| | | <a-select-option v-for='item in selectList' :key='item.id' :value='item.equipmentTypeName'> |
| | | {{item.equipmentTypeName}} |
| | | </a-select-option> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <a-spin :spinning="spinning"> |
| | | <div id="Efficiency" class="container" style="margin-top: 20px;"> |
| | | <div class="table2"> |
| | | <table class="dataContent table" border="1" cellspacing="0" cellpadding="0" style="white-space: nowrap"> |
| | | <table class="dataContent table" border="1" cellspacing="0" cellpadding="0" style="white-space: nowrap" |
| | | v-if="dataList.length>0"> |
| | | <thead> |
| | | <tr class="thead fixed equipname"> |
| | | <th class="thgu dong1 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong2 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong3 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong4 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备编号</th> |
| | | <th class="thgu dong5 name" rowspan="2" style="min-width: 150px; max-width: 150px;width: 150px;">设备名称</th> |
| | | <th class="thgu dong6 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备类型</th> |
| | | <th class="thgu dong1 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">公司</th> |
| | | <th class="thgu dong2 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">车间</th> |
| | | <th class="thgu dong3 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">工段</th> |
| | | <th class="thgu dong4 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备编号 |
| | | </th> |
| | | <th class="thgu dong5 name" rowspan="2" style="min-width: 162px; max-width: 162px;width: 162px;">设备名称 |
| | | </th> |
| | | <th class="thgu dong6 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备类型 |
| | | </th> |
| | | <!--<th rowspan="2">组别</th>--> |
| | | <template v-for="(tableHead, index) in tableHeads"> |
| | | <th class="timeth" :colspan="checkedList.length">{{tableHead}}</th> |
| | |
| | | <template v-for="(tableHead, index) in tableHeads"> |
| | | <th>利用率(%)</th> |
| | | <th v-if="checkedList.indexOf('kjl') > -1">开机率(%)</th> |
| | | <th v-if="checkedList.indexOf('kjsj') > -1">开机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('jgsj') > -1">加工时间(s)</th> |
| | | <th v-if="checkedList.indexOf('djsj') > -1">待机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('gjsj') > -1">关机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('kjsj') > -1">开机时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('jgsj') > -1">加工时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('djsj') > -1">待机时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('gjsj') > -1">关机时间(小时)</th> |
| | | </template> |
| | | |
| | | </tr> |
| | | </thead> |
| | | <tbody> |
| | | |
| | | <tr class="mathData" v-for="(item, index) in dataList"> |
| | | <template v-if="item.level1!=='合计'&&item.level1!=='平均值'"> |
| | | <td class="tdgu kaitou wenzi" :rowspan="item.level1span" |
| | | :class="{hidden: item.level1dis,noExl:item.level1dis}" v-show="!item.level1dis">{{item.level1}} |
| | | </td> |
| | |
| | | :class="{hidden: item.level3dis,noExl:item.level3dis}" v-show="!item.level3dis">{{item.level3}} |
| | | </td> |
| | | <td class="tdgu3 kaitou">{{item.equipmentId}}</td> |
| | | <td class="tdgu4 kaitou">{{item.equipmentName}}</td> |
| | | <td class="tdgu4 kaitou" style="min-width: 162px; max-width: 162px;width: 162px;">{{item.equipmentName}}</td> |
| | | <td class="tdgu5 kaitou">{{item.equipmentType}}</td> |
| | | </template> |
| | | |
| | | <!--合计与平均值区域--> |
| | | <template v-else> |
| | | <td colspan="6" class="tdgu kaitou">{{item.level1}}</td> |
| | | </template> |
| | | |
| | | <template v-for="(tableHead, index) in item.dataList"> |
| | | <td :style="{background:tableHead.color }">{{tableHead.utilizationRate | numFilter}}</td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('kjl') > -1"> |
| | | {{tableHead.openRate | numFilter}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('kjsj') > -1"> |
| | | {{tableHead.openLong}} |
| | | {{tableHead.openLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('jgsj') > -1"> |
| | | {{tableHead.processLong}} |
| | | {{tableHead.processLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('djsj') > -1"> |
| | | {{tableHead.waitLong}} |
| | | {{tableHead.waitLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('gjsj') > -1"> |
| | | {{tableHead.closeLong}} |
| | | {{tableHead.closeLong | getFormattedTime}} |
| | | </td> |
| | | </template> |
| | | |
| | | </tr> |
| | | |
| | | </tbody> |
| | | </table> |
| | | |
| | | </div> |
| | | </div> |
| | | </a-spin> |
| | | </div> |
| | | </div> |
| | | </template> |
| | |
| | | listByType: '/mdc/MdcUtilizationRate/getByType', |
| | | queryEquipmentType: '/mdc/mdcEquipmentType/queryEquipmentType' |
| | | }, |
| | | tableHeads: [] |
| | | |
| | | tableHeads: [], |
| | | distinguishColorList: [], |
| | | utilizationRateRowAverage: '', |
| | | openRateRowAverage: '', |
| | | openLongRowAverage: '', |
| | | processLongRowAverage: '', |
| | | waitLongRowAverage: '', |
| | | closeLongRowAverage: '', |
| | | spinning: false |
| | | } |
| | | }, |
| | | props: { nodeTree: '', Type: '', nodePeople: '' }, |
| | |
| | | } else { |
| | | return '0' |
| | | } |
| | | }, |
| | | |
| | | /** |
| | | * 格式化时间 |
| | | * @param seconds 秒数 |
| | | * @returns '' 格式化后时间字符串 |
| | | */ |
| | | getFormattedTime(seconds) { |
| | | if (seconds) { |
| | | return parseFloat((seconds / 3600).toFixed(2)) + '小时' |
| | | } else { |
| | | return '0' |
| | | } |
| | | } |
| | | }, |
| | | computed: {}, |
| | | methods: { |
| | | checkSameData(dataList) { |
| | | let cache = {} //存储的是键是kclx 的值,值是kclx 在indeces中数组的下标 |
| | |
| | | loadData() { |
| | | this.tableHeads = [] |
| | | this.dataList = [] |
| | | this.spinning = true |
| | | getAction(this.url.list, this.queryParam).then(res => { |
| | | if (res.success) { |
| | | this.tableHeads = res.result.dates |
| | | this.dataList = res.result.mdcEfficiencyList |
| | | this.distinguishColorList = res.result.utilizationRateList |
| | | this.checkSameData(this.dataList) |
| | | this.checkSameData1(this.dataList) |
| | | this.checkSameData2(this.dataList) |
| | | this.combineCell() |
| | | // this.columns.push(...dataColumns) |
| | | // this.initDeviceType(this.dataList) |
| | | |
| | | } |
| | | }).finally(() => { |
| | | this.spinning = false |
| | | }) |
| | | }, |
| | | queryGroup() { |
| | |
| | | }).finally(() => { |
| | | this.loading = false |
| | | }) |
| | | } |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | |
| | | |
| | | .table tbody tr .tdgu5 { |
| | | position: sticky; |
| | | left: 400px; |
| | | left: 412px; |
| | | z-index: 2; |
| | | } |
| | | |
| | |
| | | |
| | | .table2 thead .equipname .dong6 { |
| | | z-index: 5; |
| | | left: 400px; |
| | | left: 412px; |
| | | } |
| | | |
| | | @media screen and (min-width: 1920px) { |
| | |
| | | padding: 10px; |
| | | } |
| | | |
| | | .dataContent .mathData .tdd { |
| | | /*display: none;*/ |
| | | } |
| | | |
| | | td { |
| | | vertical-align: middle; |
| | | } |
| | |
| | | .green { |
| | | background-color: #99ff4e; |
| | | } |
| | | |
| | | .vertical-text { |
| | | writing-mode: vertical-rl; |
| | | } |
| | | |
| | | /*/deep/ .ant-table-body .ant-table-row td {*/ |
| | | /*padding-top: 10px;*/ |
| | | /*padding-bottom: 10px;*/ |
| | | /*}*/ |
| | | |
| | | /deep/ .ant-table-body .ant-table-row td.data { |
| | | min-width: 150px; |
| | | max-width: 150px; |
| | | } |
| | | |
| | | /deep/ .ant-table-tbody > tr.ant-table-row:hover > td { |
| | | background: none !important; |
| | | } |
| | | |
| | | /deep/ .ant-table-thead th { |
| | | text-align: center; |
| | | } |
| | | |
| | | </style> |
| | |
| | | <!--</table>--> |
| | | <!--</div>--> |
| | | </div> |
| | | <a-spin :spinning="spinning"> |
| | | <div class="container" id="EfficiencyShift" style="margin-top: 20px;"> |
| | | <div class="table2"> |
| | | <table class="dataContent table" border="1" cellspacing="0" cellpadding="0" style="white-space: nowrap"> |
| | | <table class="dataContent table" border="1" cellspacing="0" cellpadding="0" style="white-space: nowrap" v-if="dataList.length>0"> |
| | | <thead> |
| | | <tr class="thead fixed equipname"> |
| | | <th class="thgu dong1 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong2 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong3 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;"></th> |
| | | <th class="thgu dong1 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">公司</th> |
| | | <th class="thgu dong2 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">车间</th> |
| | | <th class="thgu dong3 name" rowspan="2" style="min-width: 50px; max-width: 50px;width: 50px;">工段</th> |
| | | <th class="thgu dong4 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备编号</th> |
| | | <th class="thgu dong5 name" rowspan="2" style="min-width: 150px; max-width: 150px;width: 150px;">设备名称</th> |
| | | <th class="thgu dong5 name" rowspan="2" style="min-width: 162px; max-width: 162px;width: 162px;">设备名称</th> |
| | | <th class="thgu dong6 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">设备类型</th> |
| | | <th class="thgu dong7 name" rowspan="2" style="min-width: 100px; max-width: 100px;width: 100px;">班次</th> |
| | | <template v-for="(tableHead, index) in tableHeads"> |
| | |
| | | <!--<th v-if="checkedList.indexOf('totalLong') > -1">有效时间(s)</th>--> |
| | | <!--<th v-if="checkedList.indexOf('faultLong') > -1">故障时间(s)</th>--> |
| | | <!--<!–<th v-if="checkedList.indexOf('gjsj') > -1">关机时间(s)</th>–>--> |
| | | <th v-if="checkedList.indexOf('kjsj') > -1">开机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('jgsj') > -1">加工时间(s)</th> |
| | | <th v-if="checkedList.indexOf('djsj') > -1">待机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('gjsj') > -1">关机时间(s)</th> |
| | | <th v-if="checkedList.indexOf('kjsj') > -1">开机时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('jgsj') > -1">加工时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('djsj') > -1">待机时间(小时)</th> |
| | | <th v-if="checkedList.indexOf('gjsj') > -1">关机时间(小时)</th> |
| | | </template> |
| | | </tr> |
| | | <!-- <tr>--> |
| | | <!-- <th rowspan="2">平均值</th>--> |
| | | <!-- </tr>--> |
| | | </thead> |
| | | <tbody> |
| | | <tr class="mathData" v-for="(item, index) in dataList"> |
| | | <template v-if="item.level1!=='合计'&&item.level1!=='平均值'"> |
| | | <td class="tdgu kaitou wenzi" :rowspan="item.level1span" :class="{hidden: item.level1dis,noExl:item.level1dis}" v-show="!item.level1dis">{{item.level1}}</td> |
| | | <td class="tdgu1 kaitou wenzi" :rowspan="item.level2span" :class="{hidden: item.level2dis,noExl:item.level2dis}" v-show="!item.level2dis">{{item.level2}}</td> |
| | | <td class="tdgu2 kaitou wenzi" :rowspan="item.level3span" :class="{hidden: item.level3dis,noExl:item.level3dis}" v-show="!item.level3dis">{{item.level3}}</td> |
| | | <td class="tdgu3 kaitou">{{item.equipmentId}}</td> |
| | | <td class="tdgu4 kaitou">{{item.equipmentName}}</td> |
| | | <td class="tdgu4 kaitou" style="min-width: 162px; max-width: 162px;width: 162px;">{{item.equipmentName}}</td> |
| | | <td class="tdgu5 kaitou">{{item.equipmentType}}</td> |
| | | <td class="tdgu6 kaitou">{{item.shiftSubName}}</td> |
| | | </template> |
| | | |
| | | <template v-else> |
| | | <td colspan="7" class="tdgu kaitou">{{item.level1}}</td> |
| | | </template> |
| | | <!--<td>{{item.tierType}}</td>--> |
| | | <template v-for="(tableHead, index) in item.dataList"> |
| | | <!--<td :style="{background:tableHead.color }" v-if='tableHead.utilizationRate !== 0'>{{tableHead.utilizationRate | numFilter}}</td>--> |
| | |
| | | <!--{{tableHead.gzl | numFilter}}--> |
| | | <!--</td>--> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('kjsj') > -1"> |
| | | {{tableHead.openLong}} |
| | | {{tableHead.openLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('jgsj') > -1"> |
| | | {{tableHead.processLong}} |
| | | {{tableHead.processLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('djsj') > -1"> |
| | | {{tableHead.waitLong}} |
| | | {{tableHead.waitLong | getFormattedTime}} |
| | | </td> |
| | | <td :style="{background:tableHead.color }" v-if="checkedList.indexOf('gjsj') > -1"> |
| | | {{tableHead.closeLong}} |
| | | {{tableHead.closeLong | getFormattedTime}} |
| | | </td> |
| | | <!--<td :style="{background:item[tableHead].color }" v-if="checkedList.indexOf('gjsj') > -1">--> |
| | | <!--{{item[tableHead].gjsj}}--> |
| | |
| | | </table> |
| | | </div> |
| | | </div> |
| | | </a-spin> |
| | | </div> |
| | | </div> |
| | | </template> |
| | |
| | | }, |
| | | tableHeads: [], |
| | | shiftList: [], |
| | | shiftSubList: [] |
| | | shiftSubList: [], |
| | | spinning:false |
| | | } |
| | | }, |
| | | props: { nodeTree: '', Type:'',nodePeople: '' }, |
| | |
| | | } else { |
| | | return '0' |
| | | } |
| | | }, |
| | | |
| | | /** |
| | | * 格式化时间 |
| | | * @param seconds 秒数 |
| | | * @returns '' 格式化后时间字符串 |
| | | */ |
| | | getFormattedTime(seconds) { |
| | | if (seconds) { |
| | | return parseFloat((seconds / 3600).toFixed(2)) + '小时' |
| | | } else { |
| | | return '0' |
| | | } |
| | | }, |
| | | }, |
| | | methods: { |
| | | checkSameData(dataList){ |
| | |
| | | // this.onClearSelected() |
| | | }, |
| | | loadData() { |
| | | this.spinning=true |
| | | this.tableHeads = [] |
| | | this.dataList = [] |
| | | getAction(this.url.list, this.queryParam).then(res => { |
| | |
| | | this.combineCell(); |
| | | // this.initDeviceType(this.dataList) |
| | | } |
| | | }).finally(()=>{ |
| | | this.spinning=false |
| | | }) |
| | | }, |
| | | queryGroup() { |
| | |
| | | } |
| | | .table tbody tr .tdgu5{ |
| | | position: sticky; |
| | | left: 400px; |
| | | left: 412px; |
| | | z-index: 2; |
| | | } |
| | | .table tbody tr .tdgu6{ |
| | | position: sticky; |
| | | left: 500px; |
| | | left: 512px; |
| | | z-index: 2; |
| | | } |
| | | |
| | |
| | | } |
| | | .table2 thead .equipname .dong6{ |
| | | z-index: 5; |
| | | left: 400px; |
| | | left: 412px; |
| | | } |
| | | .table2 thead .equipname .dong7{ |
| | | z-index: 6; |
| | | left: 500px; |
| | | left: 512px; |
| | | } |
| | | |
| | | @media screen and (min-width: 1920px){ |
| | |
| | | <a-col :span="12"> |
| | | <a-form-item label="设备组" :labelCol="labelCol" :wrapperCol="wrapperCol"> |
| | | <a-input-search :readOnly="true" v-decorator="['equipmentIds', validatorRules.equipmentIds]" |
| | | @search="deviceSearch" enter-button/> |
| | | @search="deviceSearch" enter-button placeholder="请选择设备"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | |
| | |
| | | </a-row> |
| | | </a-form> |
| | | </a-spin> |
| | | <mdc-pass-rate-modal-list ref="deviceRepairListModel" @sendSelectionRows="getDeviceRows"></mdc-pass-rate-modal-list> |
| | | |
| | | <select-device-modal ref="selectDeviceModal" @selectFinished="selectOK" :title="'选择设备'"/> |
| | | </a-modal> |
| | | </template> |
| | | |
| | | <script> |
| | | import moment from 'moment' |
| | | import pick from 'lodash.pick' |
| | | import mdcPassRateModalList from './mdcPassRateModalList' |
| | | // import JDate from './JDate' |
| | | import { |
| | | getAction, |
| | |
| | | import { |
| | | duplicateCheck |
| | | } from '@/api/api' |
| | | import SelectDeviceModal from '../../../../system/modules/SelectDeviceModal' |
| | | |
| | | export default { |
| | | name: 'mdcPassRateModal', |
| | | components: {mdcPassRateModalList}, |
| | | components: { SelectDeviceModal}, |
| | | props: {}, |
| | | data() { |
| | | return { |
| | |
| | | // }) |
| | | }, |
| | | deviceSearch() { |
| | | this.$refs.deviceRepairListModel.openPage() |
| | | this.$refs.deviceRepairListModel.title = '选择设备' |
| | | this.$refs.deviceRepairListModel.disableSubmit = false |
| | | this.$refs.selectDeviceModal.visible = true |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.form.getFieldValue('equipmentIds') ? this.form.getFieldValue('equipmentIds').split(',') : [] |
| | | }, |
| | | //级联框onChange事件 |
| | | // onChange(value) { |
| | |
| | | }, |
| | | checkboxChange(e) { |
| | | this.checked = e.target.checked |
| | | }, |
| | | |
| | | /** |
| | | * 选择已有设备后点击确定时触发 |
| | | * @param data 已选择的设备 |
| | | */ |
| | | selectOK(data) { |
| | | // let params = {} |
| | | // params.equipmentIdList = [] |
| | | // for (var a = 0; a < data.length; a++) { |
| | | // params.equipmentIdList.push(data[a]) |
| | | // } |
| | | console.log('data=', data) |
| | | this.form.setFieldsValue({ |
| | | equipmentIds: data.join(',') |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | <a-col :span="24"> |
| | | <a-form-item label="设备组" :labelCol="labelColLong" :wrapperCol="wrapperColLong"> |
| | | <a-input-search :readOnly="true" v-decorator="['equipmentIds', validatorRules.equipmentIds]" |
| | | @search="deviceSearch" enter-button/> |
| | | @search="deviceSearch" enter-button placeholder="请选择设备"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | |
| | | </a-row> |
| | | </a-form> |
| | | </a-spin> |
| | | <mdc-standard-process-duration-modal-list ref="deviceRepairListModel" @sendSelectionRows="getDeviceRows"></mdc-standard-process-duration-modal-list> |
| | | <select-device-modal ref="selectDeviceModal" @selectFinished="selectOK" :title="'选择设备'"/> |
| | | |
| | | </a-modal> |
| | | </template> |
| | |
| | | <script> |
| | | import moment from 'moment' |
| | | import pick from 'lodash.pick' |
| | | import MdcStandardProcessDurationModalList from './MdcStandardProcessDurationModalList' |
| | | // import JDate from './JDate' |
| | | import { |
| | | getAction, |
| | |
| | | import { |
| | | duplicateCheck |
| | | } from '@/api/api' |
| | | import SelectDeviceModal from '../../../../system/modules/SelectDeviceModal' |
| | | |
| | | export default { |
| | | name: 'MdcStandardProcessDurationModal', |
| | | components: {MdcStandardProcessDurationModalList}, |
| | | components: { SelectDeviceModal }, |
| | | props: {}, |
| | | data() { |
| | | return { |
| | |
| | | // }) |
| | | }, |
| | | deviceSearch() { |
| | | this.$refs.deviceRepairListModel.openPage() |
| | | this.$refs.deviceRepairListModel.title = '选择设备' |
| | | this.$refs.deviceRepairListModel.disableSubmit = false |
| | | this.$refs.selectDeviceModal.visible = true |
| | | this.$refs.selectDeviceModal.selectedRowKeys = [] |
| | | this.$refs.selectDeviceModal.selectedRows = [] |
| | | this.$refs.selectDeviceModal.checkedKeys = this.form.getFieldValue('equipmentIds') ? this.form.getFieldValue('equipmentIds').split(',') : [] |
| | | }, |
| | | //级联框onChange事件 |
| | | // onChange(value) { |
| | |
| | | }, |
| | | checkboxChange(e) { |
| | | this.checked = e.target.checked |
| | | }, |
| | | |
| | | /** |
| | | * 选择已有设备后点击确定时触发 |
| | | * @param data 已选择的设备 |
| | | */ |
| | | selectOK(data) { |
| | | // let params = {} |
| | | // params.equipmentIdList = [] |
| | | // for (var a = 0; a < data.length; a++) { |
| | | // params.equipmentIdList.push(data[a]) |
| | | // } |
| | | console.log('data=', data) |
| | | this.form.setFieldsValue({ |
| | | equipmentIds: data.join(',') |
| | | }) |
| | | } |
| | | } |
| | | } |
| | |
| | | this.allTreeKeys = [] |
| | | this.treeDataSource = res.result |
| | | this.generateList(res.result) |
| | | this.expandedKeys=this.allTreeKeys |
| | | } else { |
| | | this.$message.warn(res.message) |
| | | } |
| | |
| | | title: '车间', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'productionName' |
| | | dataIndex: 'productionName', |
| | | ellipsis: true, |
| | | }, |
| | | { |
| | | title: '状态', |
| | |
| | | title: '车间', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'productionName' |
| | | dataIndex: 'productionName', |
| | | ellipsis: true, |
| | | }, |
| | | { |
| | | title: '状态', |
| | |
| | | title: '车间', |
| | | align: "center", |
| | | width: 240, |
| | | dataIndex: 'productionName' |
| | | dataIndex: 'productionName', |
| | | ellipsis: true, |
| | | }, |
| | | { |
| | | title: '班组', |
| | |
| | | |
| | | <script> |
| | | import {changePassword} from '@/api/api' |
| | | import { ajaxGetDictItems, getDictItemsFromCache } from '@/api/api' |
| | | |
| | | export default { |
| | | name: "PasswordModal", |
| | |
| | | sm: { span: 16 }, |
| | | }, |
| | | form:this.$form.createForm(this) |
| | | } |
| | | }, |
| | | watch:{ |
| | | visible:{ |
| | | handler(value){ |
| | | if(value) this.initDictData('password_length') |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | |
| | | handleConfirmBlur (e) { |
| | | const value = e.target.value |
| | | this.confirmDirty = this.confirmDirty || !!value |
| | | }, |
| | | initDictData(dictCode) { |
| | | //根据字典Code, 初始化字典数组 |
| | | ajaxGetDictItems(dictCode, null).then((res) => { |
| | | if (res.success) { |
| | | const regExp = new RegExp("^(?=.*[a-zA-Z])(?=.*\\\d)(?=.*[~!@#$%^&*()_+`\\-={}:\";'<>?,./]).{"+Number(res.result[0].value)+",}$"); |
| | | this.validatorRules.password.rules[0]={ |
| | | required:true, |
| | | pattern: regExp, |
| | | message: `密码由${res.result[0].value}位数字、大小写字母和特殊符号组成!`, |
| | | } |
| | | } |
| | | }) |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | |
| | | this.treeDataSource = res.result |
| | | this.generateList(this.treeDataSource) |
| | | console.log('treeDataSource', this.treeDataSource) |
| | | this.expandedKeys = this.allTreeKeys |
| | | } else { |
| | | this.$message.warn(res.message) |
| | | } |
| | |
| | | this.visible = false |
| | | }, |
| | | handleOk() { |
| | | if (this.checkedKeys.length > 0) { |
| | | this.$emit('selectFinished', this.deviceNodes) |
| | | } |
| | | this.visible = false |
| | | } |
| | | |
| | |
| | | import { duplicateCheck } from '@/api/api' |
| | | import JSelectProduction from '../../../components/jeecgbiz/JSelectProduction' |
| | | import {mapActions} from 'vuex' |
| | | import { ajaxGetDictItems, getDictItemsFromCache } from '@/api/api' |
| | | |
| | | export default { |
| | | name: "UserModal", |
| | |
| | | nextProductionOptions:[], |
| | | isDepartType:'', |
| | | |
| | | } |
| | | }, |
| | | watch:{ |
| | | visible:{ |
| | | handler(value){ |
| | | if(value) this.initDictData('password_length') |
| | | } |
| | | } |
| | | }, |
| | | created () { |
| | |
| | | }else{ |
| | | this.departIdShow=true; |
| | | } |
| | | }, |
| | | initDictData(dictCode) { |
| | | //根据字典Code, 初始化字典数组 |
| | | ajaxGetDictItems(dictCode, null).then((res) => { |
| | | if (res.success) { |
| | | const regExp = new RegExp("^(?=.*[a-zA-Z])(?=.*\\\d)(?=.*[~!@#$%^&*()_+`\\-={}:\";'<>?,./]).{"+Number(res.result[0].value)+",}$"); |
| | | |
| | | this.validatorRules.password[0]={ |
| | | required:true, |
| | | pattern: regExp, |
| | | message: `密码由${res.result[0].value}位数字、大小写字母和特殊符号组成!`, |
| | | } |
| | | |
| | | } |
| | | }) |
| | | }, |
| | | } |
| | | } |
| | | </script> |