Merge remote-tracking branch 'origin/master'
| | |
| | | hasUpload: true, |
| | | height: 110 |
| | | }, |
| | | result: '' |
| | | result: '', |
| | | elapsedTime:'', |
| | | }; |
| | | }, |
| | | computed: { |
| | |
| | | }); |
| | | } |
| | | }, |
| | | handleSizeChange(val) { |
| | | this.isLoading = true; |
| | | setTimeout(() => { |
| | | this.page.pageSize = val; |
| | | this.$emit("pageSize", val); |
| | | this.CrudRend(); |
| | | }, 3000); |
| | | async CrudRend() { |
| | | this.elapsedTime = 0; |
| | | const startTime = performance.now(); |
| | | const res = await TableData({ |
| | | templateOid: this.templateOid, |
| | | codeClassifyOid: this.codeClassifyOid, |
| | | page: this.page.currentPage, |
| | | limit: this.page.pageSize, |
| | | }); |
| | | const endTime = performance.now(); |
| | | this.elapsedTime = Math.floor(endTime - startTime) * 1; |
| | | this.page.total = res.data.total; |
| | | this.data = res.data.data; |
| | | this.tableData = res.data.data; |
| | | }, |
| | | handleCurrentChange(val) { |
| | | |
| | | async handleSizeChange(val) { |
| | | this.page.pageSize = val; |
| | | this.$emit("pageSize", val); |
| | | this.isLoading = true; |
| | | setTimeout(() => { |
| | | this.page.currentPage = val; |
| | | this.$emit("currentPage", val); |
| | | this.CrudRend(); |
| | | }, 3000); |
| | | await this.CrudRend(); |
| | | this.isLoading = false; |
| | | }, |
| | | |
| | | async handleCurrentChange(val) { |
| | | this.page.currentPage = val; |
| | | this.$emit("currentPage", val); |
| | | this.isLoading = true; |
| | | await this.CrudRend(); |
| | | this.isLoading = false; |
| | | }, |
| | | // 监听单元格点击事件并存储正在编辑的行 |
| | | handleCellClick(row, column) { |
| | |
| | | this.$refs.dataTable.doLayout(); |
| | | } |
| | | }) |
| | | }, |
| | | //表格头渲染 |
| | | CrudHeaderRend() { |
| | | if (this.codeClassifyOid != "") { |
| | | MasterTable({ |
| | | codeClassifyOid: this.codeClassifyOid |
| | | }).then((res) => { |
| | | this.options = res.data.tableDefineVO.seniorQueryColumns; |
| | | this.List = res.data.tableDefineVO.cols[0]; |
| | | this.List.forEach((item) => { |
| | | let columnItem = { |
| | | label: item.title, |
| | | prop: item.queryField, |
| | | type: this.columnType[item.type], |
| | | sortable: item.sort, |
| | | width: item.minWidth, |
| | | }; |
| | | this.option.column.push(columnItem); |
| | | this.option.column = this.tableHeadData; |
| | | this.templateOid = res.data.tableDefineVO.oid; |
| | | this.$emit("templateOid", this.templateOid); |
| | | }); |
| | | }); |
| | | } |
| | | }, |
| | | //表格数据 |
| | | CrudRend() { |
| | | TableData({ |
| | | templateOid: this.templateOid, |
| | | codeClassifyOid: this.codeClassifyOid, |
| | | page: this.page.currentPage, |
| | | limit: this.page.pageSize, |
| | | }).then((res) => { |
| | | this.page.total = res.data.total; |
| | | this.data = res.data.data; |
| | | this.tableData = res.data.data; |
| | | }); |
| | | }, |
| | | // 排序 |
| | | sortChange(val) { |
| | |
| | | <template> |
| | | <avue-crud v-if="Formlist.length>0" ref="crud" v-model="form" :data="data" :option="option" :page.sync="page" |
| | | :search.sync="search" :table-loading="loading" @on-load="getDataList" @row-save="handleSave" |
| | | @row-del="handleDelete" @row-update="handleEdit" @refresh-change="handleRefresh" |
| | | @size-change="handleSizePage" @current-change="handleCurrentPage"> |
| | | </avue-crud> |
| | | <div style="height: calc(100vh - 553px)"> |
| | | <avue-crud v-if="Formlist.length>0" ref="crud" v-model="form" :data="data" :option="option" :page.sync="page" |
| | | :search.sync="search" :table-loading="loading" @on-load="getDataList" @row-save="handleSave" |
| | | @row-del="handleDelete" @row-update="handleEdit" @refresh-change="handleRefresh" |
| | | @size-change="handleSizePage" @current-change="handleCurrentPage"> |
| | | </avue-crud> |
| | | </div> |
| | | |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | startData: [], |
| | | form: {}, |
| | | option: { |
| | | height: 340, |
| | | height: 'auto', |
| | | border: true, |
| | | align: 'center', |
| | | menu: !this.checkStatus || this.crudLCStatus == 'Editing', |
| | |
| | | <template> |
| | | <div v-if="Formlist.length>0"> |
| | | <avue-crud ref="crud" :data="data" :option="option" :page.sync="page" :table-loading="loading" |
| | | @on-load="getDataList" @size-change="handleSizePage" @current-change="handleCurrentPage" |
| | | @row-click="handleRowClick"> |
| | | <template slot="menu" slot-scope="{type,size,row,index}"> |
| | | <el-button :size="size" :type="type" icon="el-icon-check" |
| | | @click="handleMaintenance(row, index)">维护 |
| | | </el-button> |
| | | </template> |
| | | </avue-crud> |
| | | <div style="height: calc(100vh - 553px)"> |
| | | <avue-crud ref="crud" :data="data" :option="option" :page.sync="page" :table-loading="loading" |
| | | @on-load="getDataList" @size-change="handleSizePage" @current-change="handleCurrentPage" |
| | | @row-click="handleRowClick"> |
| | | <template slot="menu" slot-scope="{type,size,row,index}"> |
| | | <el-button :size="size" :type="type" icon="el-icon-check" |
| | | @click="handleMaintenance(row, index)">维护 |
| | | </el-button> |
| | | </template> |
| | | </avue-crud> |
| | | </div> |
| | | <el-dialog :visible.sync="dialogNode" append-to-body="true" title="模板阶段" width="50%"> |
| | | <avue-crud ref="crud" :data="stageData" :option="stageOption" :table-loading="loading" @on-load="getStagelist" |
| | | @row-click="handleRowStageClick"> |
| | |
| | | ], |
| | | option: { |
| | | ...options, |
| | | height: 383, |
| | | height: 'auto', |
| | | column: [ |
| | | {label: '模板编号', prop: 'modelKey'}, |
| | | {label: '模板名称', prop: 'modelName'}, |
| | |
| | | { |
| | | label: "枚举排序", |
| | | prop: "sort", |
| | | min:1, |
| | | max:9999, |
| | | type: "number", |
| | | align: "right", |
| | | hide: true, |
| | |
| | | <el-aside> |
| | | <basic-container style="overflow: hidden;"> |
| | | <!-- 树组件--> |
| | | <master-tree @codeClassifyOid="codeClassifyOidList" @coderuleoid="coderuleoidList" :pageSize="this.pageSize" |
| | | :currentPage="this.currentPage" @tableDataArray="tableDataArrays" @tableHeadDataFateher="tableHeadDatas" |
| | | @tableHeadBttoms="tableHeadBttoms" @total="totals" @nodeClick="nodeClick" |
| | | @tableHeadFindData="tableHeadFindDatas" @Treedata="TreedataList" @TreeValue="TreeValueEmit"></master-tree> |
| | | <master-tree |
| | | :currentPage="this.currentPage" |
| | | :pageSize="this.pageSize" |
| | | @TreeValue="TreeValueEmit" |
| | | @Treedata="TreedataList" |
| | | @codeClassifyOid="codeClassifyOidList" |
| | | @coderuleoid="coderuleoidList" |
| | | @nodeClick="nodeClick" |
| | | @tableDataArray="tableDataArrays" |
| | | @tableHeadBttoms="tableHeadBttoms" |
| | | @tableHeadDataFateher="tableHeadDatas" |
| | | @tableHeadFindData="tableHeadFindDatas" |
| | | @total="totals" |
| | | > |
| | | </master-tree> |
| | | </basic-container> |
| | | </el-aside> |
| | | <el-main> |
| | | <!-- 表格组件--> |
| | | <VciMasterCrud :page="this.page" :codeClassifyOid="this.codeClassifyOid" :coderuleoid="this.coderuleoid" |
| | | @pageSize="pageSizes" @currentPage="currentPages" :tableDataArray="tableDataArray" :total="this.total" |
| | | :tableHeadDataFateher="this.tableHeadDataFateher" :isLoading="isLoading" :templateOid="templateOid" |
| | | :tableHeadFindData="tableHeadFindData" :tableHeadBtnData="masterVrBtnList" :Treedata="Treedata" :TreeValue="TreeValue"></VciMasterCrud> |
| | | <VciMasterCrud |
| | | :TreeValue="TreeValue" |
| | | :Treedata="Treedata" |
| | | :codeClassifyOid="this.codeClassifyOid" |
| | | :coderuleoid="this.coderuleoid" |
| | | :isLoading="isLoading" |
| | | :page="this.page" |
| | | :tableDataArray="tableDataArray" |
| | | :tableHeadBtnData="masterVrBtnList" |
| | | :tableHeadDataFateher="this.tableHeadDataFateher" |
| | | :tableHeadFindData="tableHeadFindData" |
| | | :templateOid="templateOid" |
| | | :total="this.total" |
| | | @currentPage="currentPages" |
| | | @pageSize="pageSizes" |
| | | > |
| | | </VciMasterCrud> |
| | | </el-main> |
| | | </el-container> |
| | | </template> |
| | |
| | | currentPage: "1", |
| | | codeClassifyOid: "", |
| | | coderuleoid: "", |
| | | Treedata:[], |
| | | Treedata: [], |
| | | templateOid: "", |
| | | tableDataArray: [], |
| | | masterVrBtnList: [], |
| | |
| | | total: "", |
| | | isLoading: false, |
| | | tableHeadFindData: {}, |
| | | TreeValue:'' |
| | | TreeValue: '' |
| | | } |
| | | }, |
| | | created() { |
| | | }, |
| | | methods: { |
| | | TreeValueEmit(val){ |
| | | this.TreeValue=val |
| | | TreeValueEmit(val) { |
| | | this.TreeValue = val |
| | | }, |
| | | codeClassifyOidList(val) { |
| | | this.codeClassifyOid = val; |
| | |
| | | coderuleoidList(val) { |
| | | this.coderuleoid = val; |
| | | }, |
| | | TreedataList(val){ |
| | | this.Treedata=val |
| | | TreedataList(val) { |
| | | this.Treedata = val |
| | | }, |
| | | pageSizes(val) { |
| | | this.pageSize = val |
| | |
| | | // this.ModifyProperties(this.TreeData, 'text', 'label'); |
| | | // 根据this.TreeData的长度计算延迟时间 |
| | | const delayTime = this.TreeData.length * 1; |
| | | console.log(delayTime) |
| | | setTimeout(() => { |
| | | this.loading = false; |
| | | this.reload = Math.random(); |
| | |
| | | </avue-crud> |
| | | </basic-container> |
| | | </el-main> |
| | | <el-dialog :visible="ref.visible" append-to-body title="从数据库中添加" width="700px" @close="dialoghandelfalse"> |
| | | <el-dialog :visible="ref.visible" append-to-body title="从数据库中添加" width="700px" @close="dialoghandelfalse" top="9vh"> |
| | | 选择领域: |
| | | <el-select v-model="domain" placeholder="请选择" size="small" @change="refOnLoad"> |
| | | <el-option v-for="item in domainOptions" :key="item.value" :label="item.label" :value="item.value"> |
| | |
| | | @search-change="searchChange" |
| | | @row-click="rowClick"> |
| | | <template slot="menuLeft"> |
| | | <el-tooltip class="item" effect="dark" content="查找版本规则使用范围" placement="top"> |
| | | <el-button size="small" |
| | | plain |
| | | type="primary" |
| | | <el-tooltip class="item" content="查找版本规则使用范围" effect="dark" placement="top"> |
| | | <el-button v-if="permissionList.apply" |
| | | icon="el-icon-zoom-in" |
| | | v-if="permissionList.apply" |
| | | plain |
| | | size="small" |
| | | type="primary" |
| | | @click="applyRangeSearch">查看使用范围 |
| | | </el-button> |
| | | </el-tooltip> |
| | | </template> |
| | | <template slot="radio" |
| | | slot-scope="{row}"> |
| | | <el-radio v-model="selectRow" |
| | | :label="row.$index"> |
| | | </el-radio> |
| | | </template> |
| | | slot-scope="{row}"> |
| | | <el-radio v-model="selectRow" |
| | | :label="row.$index"> |
| | | </el-radio> |
| | | </template> |
| | | </avue-crud> |
| | | <versionpackage :rangeData="applyRangeData" ref="applyRange"></versionpackage> |
| | | <versionpackage ref="applyRange" :rangeData="applyRangeData"></versionpackage> |
| | | </basic-container> |
| | | |
| | | </template> |
| | | |
| | | <script> |
| | | import { getPage,add,update,remove,getAppayRange } from '../../api/omd/revisionRule'; |
| | | import {getPage, add, update, remove, getAppayRange} from '../../api/omd/revisionRule'; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: "Version", |
| | | data(){ |
| | | data() { |
| | | return { |
| | | //查看使用范围 |
| | | packageSearchBox:false, |
| | | packageSearchBox: false, |
| | | // 点击数据 |
| | | selectRow: '', |
| | | selectRowData: {}, |
| | |
| | | currentPage: 1, |
| | | total: 100 |
| | | }, |
| | | data:[ |
| | | ], |
| | | form:{}, |
| | | option:{ |
| | | height:'auto', |
| | | headerAlign:'center', |
| | | data: [], |
| | | form: {}, |
| | | option: { |
| | | height: 'auto', |
| | | headerAlign: 'center', |
| | | align: 'center', |
| | | border: true, |
| | | index: true, |
| | | searchMenuSpan:5, |
| | | searchMenuSpan: 5, |
| | | highlightCurrentRow: true, |
| | | stripe:true, |
| | | viewBtn:false, |
| | | columnBtn:false, |
| | | column:[ |
| | | stripe: true, |
| | | viewBtn: false, |
| | | columnBtn: false, |
| | | column: [ |
| | | { |
| | | label: '选择', |
| | | prop: 'radio', |
| | | width: 120, |
| | | display:false |
| | | display: false |
| | | }, |
| | | { |
| | | label:'英文名称', |
| | | label: '英文名称', |
| | | prop: 'id', |
| | | editDisabled: true, |
| | | rules: [ |
| | |
| | | ] |
| | | }, |
| | | { |
| | | label:"中文名称", |
| | | prop:"name", |
| | | search:true, |
| | | label: "中文名称", |
| | | prop: "name", |
| | | search: true, |
| | | required: true, |
| | | rules: [ |
| | | { |
| | |
| | | // }, |
| | | { |
| | | label: "初始值", |
| | | prop:"startCode", |
| | | prop: "startCode", |
| | | type: 'number', |
| | | min:1, |
| | | max:99999, |
| | | min: 1, |
| | | max: 99999, |
| | | rules: [ |
| | | { |
| | | required: true, |
| | |
| | | label: "步长", |
| | | prop: "serialStep", |
| | | type: 'number', |
| | | min:1, |
| | | max:99999, |
| | | min: 1, |
| | | max: 99999, |
| | | rules: [ |
| | | { |
| | | required: true, |
| | |
| | | // }, |
| | | { |
| | | label: "描述", |
| | | prop:"description", |
| | | type:"textarea" |
| | | prop: "description", |
| | | type: "textarea" |
| | | } |
| | | ] |
| | | }, |
| | | applyRangeData: [] |
| | | } |
| | | }, |
| | | computed:{ |
| | | computed: { |
| | | ...mapGetters(["permission"]), |
| | | permissionList(){ |
| | | return{ |
| | | addBtn:this.vaildData(this.permission.modeling_Version.version_add,false), |
| | | apply:this.vaildData(this.permission.modeling_Version.version_applyopen,false), |
| | | delBtn:this.vaildData(this.permission.modeling_Version.version_delete,false), |
| | | editBtn:this.vaildData(this.permission.modeling_Version.version_edit,false), |
| | | permissionList() { |
| | | return { |
| | | addBtn: this.vaildData(this.permission.modeling_Version.version_add, false), |
| | | apply: this.vaildData(this.permission.modeling_Version.version_applyopen, false), |
| | | delBtn: this.vaildData(this.permission.modeling_Version.version_delete, false), |
| | | editBtn: this.vaildData(this.permission.modeling_Version.version_edit, false), |
| | | } |
| | | } |
| | | }, |
| | | methods:{ |
| | | methods: { |
| | | // 行点击 |
| | | rowClick(row){ |
| | | rowClick(row) { |
| | | this.selectRow = row.$index; |
| | | this.selectRowData = row; |
| | | }, |
| | | // 查看应用范围 |
| | | applyRangeSearch(){ |
| | | if (!this.selectRowData && this.selectRowData.length != 0){ |
| | | console.log(this.selectRow); |
| | | this.$message({ |
| | | type:"warning", |
| | | message: "请先选择属性" |
| | | }) |
| | | } |
| | | getAppayRange(this.selectRowData.id).then(res => { |
| | | this.applyRangeData = res.data.data; |
| | | this.$refs.applyRange.rangeData = this.applyRangeData; |
| | | this.$refs.applyRange.showDialog = true; |
| | | }) |
| | | applyRangeSearch() { |
| | | if (this.selectRow === '') { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "请先选择属性" |
| | | }) |
| | | return |
| | | } |
| | | getAppayRange(this.selectRowData.id).then(res => { |
| | | this.applyRangeData = res.data.data; |
| | | this.$refs.applyRange.rangeData = this.applyRangeData; |
| | | this.$refs.applyRange.showDialog = true; |
| | | }) |
| | | |
| | | |
| | | // this.packageSearchBox=true |
| | | }, |
| | | getList() { |
| | | this.loading = true; |
| | | getPage(this.page.currentPage,this.page.pageSize,this.params).then(res => { |
| | | getPage(this.page.currentPage, this.page.pageSize, this.params).then(res => { |
| | | const data = res.data.data |
| | | this.loading = false; |
| | | this.page.total = data.total; |
| | |
| | | type: 'warning' |
| | | }).then(() => { |
| | | console.log(row); |
| | | return remove({oid : row.oid}) |
| | | return remove({oid: row.oid}) |
| | | }).then(() => { |
| | | this.$message.success('删除成功') |
| | | this.getList(); |
| | | }) |
| | | }, |
| | | searchChange(params, done) { |
| | | var p = {"name_like" : params.name} |
| | | getPage(this.page.currentPage,this.page.pageSize,p).then(res => { |
| | | var p = {"name_like": params.name} |
| | | getPage(this.page.currentPage, this.page.pageSize, p).then(res => { |
| | | const data = res.data.data |
| | | this.loading = false; |
| | | this.page.total = data.total; |
| | | this.data = data.records; |
| | | }); |
| | | if (done) { |
| | | done(); |
| | | done(); |
| | | } |
| | | }, |
| | | refreshChange() { |
| | |
| | | this.selectRowData = row; |
| | | }, |
| | | applyRangeSearch(){ |
| | | console.log(this.selectRow); |
| | | if (!this.selectRow){ |
| | | if (this.selectRow === ''){ |
| | | this.$message({ |
| | | type:"warning", |
| | | message: "请先选择属性" |
| | | }) |
| | | return |
| | | } |
| | | getApplyRange(this.selectRowData.id).then(res => { |
| | | this.applyRangeData = res.data.data; |
| | |
| | | info.style.fontSize = '16px'; |
| | | }); |
| | | items.forEach((item) => { |
| | | item.style.border = '1px solid rgb(200, 200, 200, 1)'; |
| | | item.style.border = '1px solid #DCDFE6'; |
| | | }); |
| | | this.loading = false; |
| | | }, 1000); // 延迟1秒查找info元素 |