From 92ff846fb659c62037a32b1d8c15eae9df9d9b54 Mon Sep 17 00:00:00 2001 From: zenglf <18502938215@163.com> Date: 星期一, 18 九月 2023 13:24:30 +0800 Subject: [PATCH] Merge branch 'develop' of http://117.34.109.166:18448/r/vue_mdc_430 --- src/views/eam/SerialNumberList.vue | 297 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 297 insertions(+), 0 deletions(-) diff --git a/src/views/eam/SerialNumberList.vue b/src/views/eam/SerialNumberList.vue new file mode 100644 index 0000000..cc9c7dd --- /dev/null +++ b/src/views/eam/SerialNumberList.vue @@ -0,0 +1,297 @@ +<template> + <a-card + :bordered="false" + title="缂栫爜瑙勫垯" + > + <!-- 鏌ヨ鍖哄煙 --> + <div class="table-page-search-wrapper"> + <a-form + layout="inline" + @keyup.enter.native="searchQuery" + > + <a-row :gutter="24"> + <a-col + :md="6" + :sm="8" + > + <a-form-item label="鍗曟嵁鍚嶇О"> + <j-input + placeholder="璇疯緭鍏ュ崟鎹悕绉版煡璇�" + v-model="queryParam.functionName" + ></j-input> + </a-form-item> + </a-col> + <a-col + :md="6" + :sm="8" + > + <a-form-item label="鍥哄畾瀛楃"> + <j-input + placeholder="璇疯緭鍏ュ浐瀹氬瓧绗︽煡璇�" + v-model="queryParam.beginSymbol" + ></j-input> + </a-form-item> + </a-col> + <template v-if="toggleSearchStatus"> + </template> + <a-col + :md="6" + :sm="8" + > + <span + style="float: left;overflow: hidden;" + class="table-page-search-submitButtons" + > + <a-button + type="primary" + @click="searchQuery" + icon="search" + >鏌ヨ</a-button> + <a-button + type="primary" + @click="searchReset" + icon="reload" + style="margin-left: 8px" + >閲嶇疆</a-button> + </span> + </a-col> + </a-row> + </a-form> + </div> + + <!-- 鎿嶄綔鎸夐挳鍖哄煙 --> + <div class="table-operator"> + <a-button + @click="handleAdd" + type="primary" + icon="plus" + >鏂板</a-button> + <a-dropdown v-if="selectedRowKeys.length > 0"> + <a-menu slot="overlay"> + <a-menu-item + key="1" + @click="batchDel" + > + <a-icon type="delete" />鍒犻櫎 + </a-menu-item> + </a-menu> + <a-button style="margin-left: 8px"> + 鎵归噺鎿嶄綔 + <a-icon type="down" /> + </a-button> + </a-dropdown> + </div> + + <!-- table鍖哄煙-begin --> + <div> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > + <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 + <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> + </div> + + <a-table + ref="table" + size="middle" + bordered + rowKey="id" + :columns="columns" + :rowClassName="tableRowClass" + :dataSource="dataSource" + :pagination="ipagination" + :loading="loading" + :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" + @change="handleTableChange" + > + + <span + slot="action" + slot-scope="text, record" + > + <a + href="javascript:;" + @click="handleDetail(record)" + >璇︽儏</a> + + <a-divider type="vertical" /> + <a-dropdown> + <a class="ant-dropdown-link">鏇村 + <a-icon type="down" /> + </a> + <a-menu slot="overlay"> + <a-menu-item> + <a @click="handleEdit(record)">缂栬緫</a> + </a-menu-item> + <a-menu-item> + <a-popconfirm + title="纭畾鍒犻櫎鍚�?" + @confirm="() => handleDelete(record.id)" + > + <a>鍒犻櫎</a> + </a-popconfirm> + + </a-menu-item> + </a-menu> + </a-dropdown> + </span> + </a-table> + </div> + + <!-- 琛ㄥ崟鍖哄煙 --> + <serial-number-model + ref="modalForm" + @ok="modalFormOk" + ></serial-number-model> + </a-card> +</template> + +<script> +import SerialNumberModel from './modules/SerialNumberModel' +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import JDictSelectTag from '@/components/dict/JDictSelectTag' +import { initDictOptions, filterDictText } from '@/components/dict/JDictSelectUtil' +import { requestPut } from '@/api/manage' +import JInput from '@/components/jeecg/JInput' +import JEllipsis from "@/components/jeecg/JEllipsis"; + +export default { + name: 'SerialNumberList', + mixins: [JeecgListMixin], + components: { + SerialNumberModel, + JDictSelectTag, + JInput, + JEllipsis, + }, + data() { + return { + isorter: { + column: 'createTime', + order: 'desc', + }, + columns: [ + { + title: '#', + dataIndex: '', + key: 'rowIndex', + align: 'center', + customRender: function (t, r, index) { + return parseInt(index) + 1 + }, + width: 50, + }, + { + title: '鍗曟嵁鍚嶇О', + align: 'center', + dataIndex: 'functionName', + sorter: true, + }, + { + title: '鍥哄畾瀛楃', + align: 'center', + dataIndex: 'beginSymbol', + sorter: true, + }, + // { + // title: '浼佷笟浠g爜', + // align: 'center', + // dataIndex: 'enterpriseCode', + // sorter: true, + // }, + { + title: '绫诲瀷', + align: 'center', + dataIndex: 'type', + sorter: true, + }, + // { + // title: '鍒涘缓鏃堕棿', + // align: 'center', + // dataIndex: 'createTime', + // scopedSlots: { + // customRender: 'createTime', + // }, + // sorter: true, + // }, + // { + // title: '鍒涘缓浜�', + // align: 'center', + // dataIndex: 'createBy', + // scopedSlots: { + // customRender: 'createBy', + // }, + // sorter: true, + // }, + // { + // title: '鐘舵��', + // align: 'center', + // scopedSlots: { + // customRender: 'status', + // }, + // dataIndex: 'status', + // sorter: true, + // width: 100, + // }, + { + + title: '鎿嶄綔', + align: 'center', + dataIndex: 'action', + scopedSlots: { + customRender: 'action', + }, + width: 150, + }, + + ], + url: { + list: '/eam/serialNumber/list', + delete: '/eam/serialNumber/delete', + }, + } + }, + methods: { + + //绂佺敤鐘舵�佹牱寮� + tableRowClass(record, index) { + // if (record.status != "1") { + // return "frozenRowClass"; + // } + // return ""; + }, + + + searchReset() { + this.queryParam = {}; + this.loadData(1); + }, + + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` + } + } +} +</script> +<style> +@import '~@assets/less/common.less'; +.frozenRowClass { + color: #c9c9c9; +} +.success { + color: green; +} +.error { + color: red; +} +.fontweight { + font-weight: bold; +} +</style> \ No newline at end of file -- Gitblit v1.9.3