From dacf37deb3d53345024402016e9c4d19ac82e3aa Mon Sep 17 00:00:00 2001
From: cuilei <ray_tsu1@163.com>
Date: 星期四, 07 八月 2025 10:29:19 +0800
Subject: [PATCH] 生产管控 排产工单页面
---
src/views/mdc/base/modules/alarmManager/alarmManangerEqupment.vue | 286 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 286 insertions(+), 0 deletions(-)
diff --git a/src/views/mdc/base/modules/alarmManager/alarmManangerEqupment.vue b/src/views/mdc/base/modules/alarmManager/alarmManangerEqupment.vue
new file mode 100644
index 0000000..b3001ba
--- /dev/null
+++ b/src/views/mdc/base/modules/alarmManager/alarmManangerEqupment.vue
@@ -0,0 +1,286 @@
+<template>
+ <a-modal :title="title" width="70%" :visible="visible" :maskClosable="false" @ok="handleOk" @cancel="handleCancel"
+ cancelText="鍏抽棴">
+ <a-card :bordered="false">
+ <!-- 鏌ヨ鍖哄煙 -->
+ <div class="table-page-search-wrapper">
+ <a-form layout="inline" @keyup.enter.native="searchQuery">
+ <a-row :gutter="24">
+ <a-col :md="6" :sm="6">
+ <a-form-item label="閮ㄩ棬" >
+ <a-select v-model="queryParam.sectionPid" placeholder="璇烽�夋嫨閮ㄩ棬" :options="sectionPData" @change="initGroupOptions" />
+ </a-form-item>
+ </a-col>
+
+ <a-col :md="6" :sm="6">
+ <a-form-item label="鍥㈤槦" >
+ <a-select v-model="queryParam.sectionId" placeholder="璇烽�夋嫨鍥㈤槦" :options="sectionData"/>
+ </a-form-item>
+ </a-col>
+
+ <a-col :md="6" :sm="6">
+ <a-form-item label="缁熶竴缂栫爜">
+ <a-input placeholder="璇疯緭鍏ョ粺涓�缂栫爜妫�绱�" v-model="queryParam.equipmentId"></a-input>
+ </a-form-item>
+ </a-col>
+
+ <a-col :md="6" :sm="6">
+ <a-form-item label="璁惧鍚嶇О">
+ <a-input placeholder="璇疯緭鍏ヨ澶囧悕绉版绱�" v-model="queryParam.equipmentName"></a-input>
+ </a-form-item>
+ </a-col>
+ </a-row>
+ </a-form>
+ </div>
+ <!-- 鎿嶄綔鎸夐挳鍖哄煙 -->
+ <div class="table-operator">
+ <a-button type="primary" @click="searchQuery" icon="search">鏌ヨ</a-button>
+ <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">閲嶇疆</a-button>
+ </div>
+ <!-- table鍖哄煙-begin -->
+ <div>
+ <a-table ref="table" size="middle" bordered rowKey="id" :scroll="{聽 y: 400聽}" :columns="columns"
+ :dataSource="dataSource" :pagination="ipagination" :loading="loading"
+ :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
+ @change="handleTableChange">
+ </a-table>
+ </div>
+ <!-- table鍖哄煙-end -->
+ </a-card>
+ </a-modal>
+</template>
+
+<script>
+ import {
+ ajaxGetSelectItems
+ } from '@/api/api'
+ import JDictSelectTag from '@/components/dict/JDictSelectTag'
+ import {
+ deleteAction,
+ requestPut,
+ getAction,
+ postAction
+ } from '@/api/manage'
+ import {
+ JeecgListMixin
+ } from '@/mixins/JeecgListMixin'
+ import JInput from '@/components/jeecg/JInput'
+ import JEllipsis from '@/components/jeecg/JEllipsis'
+ import Tooltip from 'ant-design-vue/es/tooltip'
+ import JDate from '@/components/jeecg/JDate'
+ import moment from 'moment'
+
+ export default {
+ name: 'alarmManangerEqupment',
+ mixins: [JeecgListMixin],
+ components: {
+ JDictSelectTag,
+ JEllipsis,
+ JInput,
+ Tooltip,
+ JDate
+ },
+ props: {
+ status: {
+ type: Number,
+ default: 1
+ }
+ },
+ data() {
+ return {
+ /*readOnly:true,*/
+ title:'',
+ visible: false,
+ SelectedList:[],
+ /*disableMixinCreated: true,
+ queryParam: {},*/
+ columns: [
+ {
+ title: '#',
+ dataIndex: '',
+ key: 'rowIndex',
+ width: 60,
+ align: "center",
+ customRender: function (t, r, index) {
+ return parseInt(index) + 1;
+ }
+ },{
+
+ title: '缁熶竴缂栫爜',
+ align: 'center',
+ dataIndex: 'equipmentId',
+ },
+ {
+ title: '璁惧鍚嶇О',
+ align: 'center',
+ dataIndex: 'equipmentName',
+ },
+ {
+ title: '椹卞姩绫诲瀷',
+ align: 'center',
+ dataIndex: 'driveType'
+ },
+ {
+ title: '鏁版帶绯荤粺',
+ align: 'center',
+ dataIndex: 'controlSystem'
+ },
+ ],
+ sectionPData: [],
+ sectionData: [],
+ url: {
+ list: '/mdc/mdcequipment/findEquipmentList',
+ loadOptions: '/mdc/sectionEquipment/loadOptions'
+ },
+
+ }
+ },
+ created() {
+
+ },
+ methods: {
+ onSelectChange(selectedRowKeys, selectionRows) {
+ // this.SelectedList.push(selectedRowKeys);
+ this.selectedRowKeys = selectedRowKeys;
+ this.selectionRows = selectionRows
+ // this.SelectedList =[...this.SelectedList,...selectionRows];
+ // console.log(this.SelectedList);
+ },
+ handleTableChange(pagination, filters, sorter) {
+ // this.onClearSelected()
+ //鍒嗛〉銆佹帓搴忋�佺瓫閫夊彉鍖栨椂瑙﹀彂
+ //TODO 绛涢��
+ console.log(pagination)
+ if (Object.keys(sorter).length > 0) {
+ this.isorter.column = sorter.field;
+ this.isorter.order = "ascend" == sorter.order ? "asc" : "desc"
+ }
+ this.ipagination = pagination;
+ this.loadData();
+ },
+ openPage() {
+ this.visible = true
+ this.onClearSelected()
+ this.dataSource = [];
+ this.queryParam = {
+ status: this.status
+ };
+
+ this.loadData();
+ this.initOptions();
+ },
+ loadData(arg) {
+ if(!this.url.list){
+ this.$message.error("璇疯缃畊rl.list灞炴��!")
+ return
+ }
+ //鍔犺浇鏁版嵁 鑻ヤ紶鍏ュ弬鏁�1鍒欏姞杞界涓�椤电殑鍐呭
+ if (arg === 1) {
+ this.ipagination.current = 1;
+ }
+ var params = this.getQueryParams();//鏌ヨ鏉′欢
+
+ if(!params){
+ return false;
+ }
+
+ this.loading = true;
+ postAction(this.url.list, params).then((res) => {
+ if (res.success) {
+ // console.log(res)
+ //update-begin---author:zhangyafei Date:20201118 for锛氶�傞厤涓嶅垎椤电殑鏁版嵁鍒楄〃------------
+ this.dataSource = res.result.records||res.result;
+ if(res.result.total)
+ {
+ this.ipagination.total = res.result.total;
+ }else{
+ this.ipagination.total = 0;
+ }
+ //update-end---author:zhangyafei Date:20201118 for锛氶�傞厤涓嶅垎椤电殑鏁版嵁鍒楄〃------------
+ }else{
+ // this.$message.warning(res.message)
+ this.$notification.warning({
+ message:'娑堟伅',
+ description:res.message
+ });
+ }
+ }).finally(() => {
+ this.loading = false
+ })
+ },
+ modalFormOk(val) {
+ // 鏂板/淇敼 鎴愬姛鏃讹紝閲嶈浇鍒楄〃
+ this.loadData();
+
+ this.selectedRowKeys = [val.id];
+ },
+ searchQuery() {
+ this.loadData();
+ this.onClearSelected()
+ },
+ searchReset() {
+ this.queryParam = {
+ status: 1
+ };
+ this.loadData();
+ this.onClearSelected()
+ },
+ close() {
+ this.$emit('close')
+ this.visible = false
+ },
+ handleCancel() {
+ this.close()
+ },
+ handleOk() {
+ // this.selectionRows = this.SelectedList;
+ // console.log(this.selectionRows);
+ this.$emit('sendSelectionRows', this.selectionRows)
+ this.close()
+ },
+ initOptions() {
+ postAction(this.url.loadOptions, { sectionRank: 2 }).then(res => {
+ if (res.success) {
+ this.sectionPData = res.result
+ } else {
+ // this.$message.warning(res.message)
+ this.$notification.warning({
+ message:'娑堟伅',
+ description:res.message
+ });
+ }
+ })
+ },
+ initGroupOptions() {
+ //娓呴櫎涓�绾т笅鎷夋閫変腑鍚庝簩绾т笅鎷夋宸叉湁閫変腑鍊�
+ this.$set(this.queryParam, 'sectionId', undefined)
+ postAction(this.url.loadOptions, { parentId: this.queryParam.sectionPid }).then(res => {
+ if (res.success) {
+ this.sectionData = res.result
+ } else {
+ // this.$message.warning(res.message)
+ this.$notification.warning({
+ message:'娑堟伅',
+ description:res.message
+ });
+ }
+ })
+ }
+ },
+ }
+</script>
+<style>
+ @import '~@assets/less/common.less';
+
+ .frozenRowClass {
+ color: #c9c9c9;
+ }
+
+ .success {
+ color: green;
+ }
+
+ .error {
+ color: red;
+ }
+</style>
--
Gitblit v1.9.3