整合代码&&表单定义扩展属性添加提示文字&&显示类型修改默认值和绑定值
| | |
| | | import {Message} from 'element-ui' |
| | | import {setStore, getStore} from '@/util/store' |
| | | import {isURL, validatenull} from '@/util/validate' |
| | | import {deepClone,queryStringToObject} from '@/util/util' |
| | | import {deepClone, queryStringToObject} from '@/util/util' |
| | | import website from '@/config/website' |
| | | import {loginByUsername, loginBySocial, loginBySso, getUserInfo, logout, refreshToken, getButtons} from '@/api/user' |
| | | import {getTopMenu, getRoutes} from '@/api/system/menu' |
| | |
| | | item.pathValue = item.path; |
| | | item.path = '/' + item.code; |
| | | item.query = {}; // 初始化 item.query |
| | | if(item.pathValue.indexOf('?')!=-1) { |
| | | if (item.pathValue.indexOf('?') != -1) { |
| | | item.query = queryStringToObject(item.pathValue) |
| | | } |
| | | if (item.children && item.children.length > 0) { |
| | |
| | | //根据用户名登录 |
| | | LoginByUsername({commit}, userInfo) { |
| | | return new Promise((resolve, reject) => { |
| | | let passwordDes = func.encryptData(userInfo.password,'daliantan0v0vcip') |
| | | loginByUsername(userInfo.deptId, userInfo.roleId, userInfo.username,passwordDes, userInfo.type, userInfo.key,).then(res => { |
| | | let passwordDes = func.encryptData(userInfo.password, 'daliantan0v0vcip') |
| | | loginByUsername(userInfo.deptId, userInfo.roleId, userInfo.username, passwordDes, userInfo.type, userInfo.key,).then(res => { |
| | | const data = res.data; |
| | | if (data.obj.failCode === 'loginSuccess') { |
| | | commit('SET_TOKEN', data.obj.tokenVO.accessToken); |
| | |
| | | return new Promise((resolve, reject) => { |
| | | getUserInfo().then((res) => { |
| | | const data = res.data.data; |
| | | console.log('user',res) |
| | | console.log('user', res) |
| | | // commit('SET_USER_INFO', data.roles); |
| | | resolve(data); |
| | | }).catch(err => { |
| | |
| | | SET_ROLES: (state, roles) => { |
| | | state.roles = roles; |
| | | }, |
| | | |
| | | SET_PERMISSION: (state, permission) => { |
| | | let permission_new = {}; |
| | | permission.forEach(item => { |
| | | let children = {}; |
| | | if (item.children && item.children.length > 0) { |
| | | item.children.forEach(child => { |
| | | Vue.set(children, child.code, true); |
| | | }); |
| | | } |
| | | Vue.set(permission_new, item.code, children); |
| | | }); |
| | | state.permission = permission_new; |
| | | setStore({name: "permission", content: permission_new}); |
| | | }, |
| | | } |
| | | |
| | | } |
| | | export default user |
| | |
| | | import CryptoJS from 'crypto-js' |
| | | |
| | | export default class func { |
| | | |
| | | static getSvgList() { |
| | | const fs = require('fs'); |
| | | const path = require('path'); |
| | | |
| | | // 指定文件夹路径 |
| | | const directoryPath = "../config/svg"; // 修改为你的文件夹路径 |
| | | |
| | | // 存储 .svg 文件路径的数组 |
| | | let svgFiles = []; |
| | | |
| | | // 读取文件夹 |
| | | fs.readdir(directoryPath, (err, files) => { |
| | | if (err) { |
| | | return console.error('无法读取目录: ' + err); |
| | | } |
| | | |
| | | // 遍历文件 |
| | | files.forEach(file => { |
| | | // 检查文件后缀名 |
| | | if (path.extname(file).toLowerCase() === '.svg') { |
| | | // 构建文件的完整路径 |
| | | const filePath = path.join(directoryPath, file); |
| | | svgFiles.push(filePath); |
| | | } |
| | | }); |
| | | |
| | | // 输出结果 |
| | | console.log(JSON.stringify(svgFiles, null, 2)); |
| | | }); |
| | | } |
| | | |
| | | /** |
| | | * 单选表格行 |
| | | * 时间戳格式化 |
| | |
| | | */ |
| | | |
| | | static isEmptyObject(obj) { |
| | | if(obj){ |
| | | if (obj) { |
| | | return Object.keys(obj).length === 0; |
| | | }else { |
| | | } else { |
| | | return true; |
| | | } |
| | | } |
| | |
| | | <span v-else-if="form.searchTarger === '1'">源对象</span> |
| | | <span v-else-if="form.searchTarger === '2'">目标对象</span> |
| | | </template> |
| | | |
| | | <template slot="extAttrLabel" slot-scope="{}"> |
| | | <el-tooltip placement="top"> |
| | | <div slot="content">示例:ext1:xx;ext2;ext3:xx;ext4:xxx;extn:xxx; |
| | | <br/>1、用英交半角分号:分隔各组值; |
| | | <br/>2、每组用英交半角冒号:分隔单一扩展属性名称及属性值; |
| | | <br/>3、可以定义任意组,但总字符长度不得超过4000; |
| | | <br/>4、输入时,不要敲回车换行; |
| | | </div> |
| | | <span>扩展属性 <i class="el-icon-warning" style="color:red;"></i> </span> |
| | | </el-tooltip> |
| | | </template> |
| | | |
| | | <template slot="templateIdForm" slot-scope="{}"> |
| | | <el-select v-model="form.templateId" filterable placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in templateIdList" |
| | | :key="item.viName" |
| | | :label="item.viName" |
| | | :value="item.viName"> |
| | | </el-option> |
| | | </el-select> |
| | | </template> |
| | | </avue-crud> |
| | | <el-dialog |
| | | v-dialogDrag |
| | |
| | | delPageDefination, |
| | | joinBtn, |
| | | exitBtn, |
| | | updatePageDefination |
| | | updatePageDefination, |
| | | getPortalVIDatasByPage |
| | | } from "@/api/UI/uiDefine"; |
| | | import actionDialog from '@/views/modelingMenu/ui/Aciton/components/dialog'; |
| | | import cloneDialog from "@/views/modelingMenu/ui/uiDefine/rightRegion/cloneDialog"; |
| | |
| | | name: "index", |
| | | data() { |
| | | return { |
| | | templateIdList: [], |
| | | searchTargerChangeFlag: false, |
| | | formBtnOid: '', |
| | | sourceBtnOid: '', |
| | | sourceOId: '', |
| | |
| | | hide: true, |
| | | }, |
| | | { |
| | | label: '扩展属性', |
| | | label: '', |
| | | prop: 'extAttr', |
| | | hide: true, |
| | | }, |
| | |
| | | dicData: [ |
| | | { |
| | | label: '不显示', |
| | | value: '3' |
| | | value: '1' |
| | | }, |
| | | { |
| | | label: '显示角色', |
| | |
| | | }, |
| | | { |
| | | label: '显示Folder', |
| | | value: '1', |
| | | value: '3', |
| | | }, |
| | | ], |
| | | }, |
| | |
| | | const obj = this.option.group[0].column.find(item => item.prop === 'linkType'); |
| | | obj.display = val.value !== '1'; |
| | | } |
| | | // 切换清空模板类型 |
| | | const list = ['showType', 'linkType', 'templateId', 'SubUILayout', 'queryTemplateName', 'searchObjType']; |
| | | // list.forEach(item => { |
| | | // this.form[item] = ''; |
| | | // }) |
| | | if (this.searchTargerChangeFlag) { |
| | | // 切换清空模板类型 |
| | | const list = ['showType', 'linkType', 'templateId', 'SubUILayout', 'queryTemplateName', 'searchObjType', 'bsCustQueryCLsOrUrl', 'csCustQueryCLsOrUrl']; |
| | | list.forEach(item => { |
| | | this.form[item] = ''; |
| | | }) |
| | | } else { |
| | | this.searchTargerChangeFlag = true; |
| | | } |
| | | } |
| | | }, |
| | | { |
| | |
| | | placeholder: "请输入内容", |
| | | dicUrl: '/api/uiManagerController/getBtmDatasByPage?page=1&limit=-1', |
| | | filterable: true, |
| | | change: (val) => { |
| | | console.log('val', val); |
| | | if (val) { |
| | | let params = { |
| | | 'conditionMap[selectBtmType]': this.form.searchTarger === '1' ? this.form.showType : this.form.linkType |
| | | } |
| | | getPortalVIDatasByPage(1, -1, params).then(res => { |
| | | this.templateIdList = res.data.data; |
| | | }) |
| | | } |
| | | }, |
| | | props: { |
| | | label: 'name', |
| | | value: 'name', |
| | |
| | | label: '选择模板', |
| | | prop: 'templateId', |
| | | display: false, |
| | | type: 'select', |
| | | filterable: true, |
| | | dicUrl: '/api/uiManagerController/getPortalVIDatasByPage?page=1&limit=-1&conditionMap[selectBtmType]={{key}}', |
| | | formslot: true, |
| | | rules: [ |
| | | { |
| | | required: true, |
| | |
| | | trigger: 'submit' |
| | | } |
| | | ], |
| | | props: { |
| | | label: 'viName', |
| | | value: 'viName', |
| | | desc: 'viType' |
| | | }, |
| | | }, |
| | | { |
| | | label: 'UI定义', |
| | |
| | | labelWidth: 135, |
| | | span: 12 |
| | | }, |
| | | { |
| | | label: 'B/S自定义查询', |
| | | prop: 'bsCustQueryCLsOrUrl', |
| | | display: false, |
| | | labelWidth: 115, |
| | | span: 12 |
| | | }, |
| | | { |
| | | label: 'C/S自定义查询', |
| | | prop: 'csCustQueryCLsOrUrl', |
| | | display: false, |
| | | labelWidth: 115, |
| | | span: 12 |
| | | }, |
| | | ] |
| | | }, |
| | | { |
| | |
| | | |
| | | // 增加 |
| | | addClickHandler() { |
| | | console.log(this.sourceData); |
| | | if (!this.sourceData || !this.sourceData.plOId) { |
| | | this.$message.error('请在上方选择一条数据后进行添加'); |
| | | return; |
| | | } |
| | | this.$refs.crud.rowAdd(); |
| | | }, |
| | | |
| | | // 编辑打开表单前 |
| | | beforeOpen(done, type) { |
| | | // if (type === 'edit') { |
| | | // console.log('edit'); |
| | | // this.form.showType = 'Ludc'; |
| | | // } |
| | | done(); |
| | | }, |
| | | |
| | | // 增加关闭对话框 清空event数组 |
| | |
| | | }); |
| | | } |
| | | this.$refs.crud.rowEdit(row); |
| | | console.log(this.form); |
| | | }, |
| | | |
| | | // 删除 |
| | | rowDeleteHandler(row) { |
| | | console.log(row); |
| | | this.$confirm('您确定要删除所选择的数据吗?', '提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | |
| | | row.SubUIObjType = row.showType; |
| | | row.showType = ""; |
| | | } |
| | | console.log(this.sourceData); |
| | | const params = { |
| | | ...row, |
| | | tabPageOId: this.sourceData.plOId |
| | | } |
| | | addPageDefination(params).then(res => { |
| | | console.log(res); |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.obj); |
| | | this.getTableList(); |
| | |
| | | }) |
| | | }, |
| | | |
| | | rowUpdateHandler(row,index,done,loading){ |
| | | rowUpdateHandler(row, index, done, loading) { |
| | | if (row.templateType === '6') { |
| | | row.SubUIObjType = row.showType; |
| | | row.showType = ""; |
| | | } |
| | | console.log(this.sourceData); |
| | | const params = { |
| | | ...row, |
| | | tabPageOId: this.sourceData.plOId |
| | | } |
| | | updatePageDefination(params).then(res => { |
| | | console.log(res); |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.obj); |
| | | this.getTableList(); |
| | |
| | | // 模板类型为表格 |
| | | templateTypeTable(val) { |
| | | if (!val) return; |
| | | this.updateDisplay(val, ['showType', 'templateId', 'queryTemplateName']); |
| | | this.updateDisplay(val, ['showType', 'templateId', 'queryTemplateName', 'bsCustQueryCLsOrUrl', 'csCustQueryCLsOrUrl']); |
| | | }, |
| | | |
| | | // 模板类型为自定义模板 |
| | |
| | | // 模板类型为树表 |
| | | templateTypeTreeTable(val) { |
| | | if (!val) return; |
| | | this.updateDisplay(val, ['showType', 'templateId', 'queryTemplateName', 'expandCols', 'expandMode']); |
| | | this.updateDisplay(val, ['showType', 'templateId', 'queryTemplateName', 'expandCols', 'expandMode', 'bsCustQueryCLsOrUrl', 'csCustQueryCLsOrUrl']); |
| | | }, |
| | | |
| | | // 模板类型为表单 |
| | | templateTypeForm(val) { |
| | | if (!val) return; |
| | | this.updateDisplay(val, ['showType', 'templateId', 'queryTemplateName']); |
| | | this.updateDisplay(val, ['showType', 'templateId', 'queryTemplateName', 'bsCustQueryCLsOrUrl', 'csCustQueryCLsOrUrl']); |
| | | }, |
| | | |
| | | // 模板类型为树 |
| | |
| | | if (!val) return; |
| | | const searchTarger = this.option.column.find(item => item.prop === 'searchTarger'); // 获取搜索类型配置项 |
| | | searchTarger.display = false; // 不展示搜索类型 |
| | | this.updateDisplay(val, ['showType', 'queryTemplateName', 'rootContent', 'showAbs', 'showLinkAbs', 'separator', 'expandMode', 'linkType']); |
| | | this.updateDisplay(val, ['showType', 'queryTemplateName', 'rootContent', 'showAbs', 'showLinkAbs', 'separator', 'expandMode', 'linkType', 'bsCustQueryCLsOrUrl', 'csCustQueryCLsOrUrl']); |
| | | }, |
| | | |
| | | // 模板类型为UI定义 |
| | |
| | | if (!val) return; |
| | | const searchTarger = this.option.column.find(item => item.prop === 'searchTarger'); // 获取搜索类型配置项 |
| | | searchTarger.display = false; // 不展示搜索类型 |
| | | this.updateDisplay(val, ['showType', 'SubUILayout', 'searchType', 'searchObjType', 'queryTemplateName']); |
| | | this.updateDisplay(val, ['showType', 'SubUILayout', 'searchType', 'searchObjType', 'queryTemplateName', 'bsCustQueryCLsOrUrl', 'csCustQueryCLsOrUrl']); |
| | | }, |
| | | |
| | | // 查找数组中对象索引 |
| | |
| | | this.$message.error('请选择一条数据'); |
| | | return; |
| | | } |
| | | console.log(this.selectList); |
| | | this.btnDesignVisible = true; |
| | | this.formBtnOid = this.selectList[0].id; |
| | | this.getTabBtnTree(); |
| | |
| | | |
| | | // 按钮设计信息参数信息修改 |
| | | paramsRowEditHandler(row) { |
| | | this.$refs.paramsCrud.rowEdit(row,row.$index); |
| | | this.$refs.paramsCrud.rowEdit(row, row.$index); |
| | | }, |
| | | |
| | | // 按钮设计参数信息添加按钮 |
| | |
| | | |
| | | // 按钮设计参数信息修改保存 |
| | | paramsRowUpdate(row, index, done, loading) { |
| | | console.log(row,index); |
| | | this.paramsData.splice(index, 1, row); |
| | | done(); |
| | | }, |
| | |
| | | type: 'warning' |
| | | }).then(() => { |
| | | deleteTabButton(this.nodeTreeRow).then(res => { |
| | | // console.log(res); |
| | | if (res.data.code === 200) { |
| | | this.$message.success('删除成功'); |
| | | this.getTabBtnTree(); |
| | |
| | | |
| | | // 打开克隆对话框 |
| | | rowCloneHandler(row) { |
| | | console.log(row); |
| | | this.fromOid = this.sourceData.plOId; |
| | | this.sourceOId = row.id; |
| | | this.$refs.cloneDialog.openDialog(row); |
| | |
| | | return; |
| | | } |
| | | joinBtn(this.nodeTreeRow).then(res => { |
| | | // console.log(res); |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.obj); |
| | | this.getTabBtnTree(); |
| | |
| | | this.$message.error('请选择节点进行修改'); |
| | | return; |
| | | } |
| | | |
| | | if (this.nodeTreeRow.oId === "parentNode") { |
| | | this.$message.error('顶层节点不允许调整'); |
| | | return; |
| | |
| | | rowSaveHandler(row, done, loading) { |
| | | delete row.roleClassifyText; |
| | | addRole(row).then(res => { |
| | | console.log(res) |
| | | if (res.data.code === 200) { |
| | | this.$message.success(res.data.obj); |
| | | this.getTableList(); |
| | |
| | | } |
| | | }).catch(err => { |
| | | loading(); |
| | | console.log(err); |
| | | }); |
| | | }, |
| | | |
| | |
| | | return; |
| | | } |
| | | listUserByRoleOid({pkRole: this.selectList[0].oid}).then(res => { |
| | | console.log(res) |
| | | if (res.data.code === 200) { |
| | | const data = res.data.data; |
| | | this.countData = data.map(item => { |
| | |
| | | }); |
| | | this.statisticsVisible = true; |
| | | } |
| | | }).catch(err => { |
| | | console.log(err) |
| | | }) |
| | | }, |
| | | |
| | |
| | | <el-row> |
| | | <el-col :span="16" style="height: 560px"> |
| | | <basic-container> |
| | | <el-collapse v-model="activeNames" @change="handleChange"> |
| | | <el-collapse v-model="activeNames"> |
| | | <el-collapse-item name="1" title="欢迎使用PLT-WEB平台"> |
| | | <div> |
| | | 1、北京宏博远达科技有限公司(以下简称“宏博远达”)长期专注于制造业信息化建设,为客户提供企业信息化整体解决方案及相关软件研发、咨询及实施服务。宏博远达客户群体涵盖航空、航天、船舶、兵器、汽车、通用机械、电子等制造行业,通过与客户深度合作,承担了多项国家级软件研发与技术服务项目,拥有多项具有自主知识产权的软件产品。 |
| | |
| | | <div> |
| | | 2、为了给客户提供更多的技术创新能力及相应的企业级管理支撑平台,宏博远达研发了具有自主知识产权的企业级信息化整体解决方案,同时针对客户的特定需求,提供了高度可定制的专业应用。为了进一步提升技术服务能力,宏博远达投入专门力量在前沿技术方面进行探索,在企业私有云计算和大数据等领域不断取得突破。随着新一代业务与管理技术平台的推出,更增强了公司为客户提供高质量、全方位、深层次服务的技术能力。 |
| | | </div> |
| | | <div>3、宏博远达一直秉承“用智慧为客户创造价值”的宗旨,愿以“诚信负责”的态度和专业化的服务,在企业信息化发展的道路上,与客户一起成长,共同见证成功!</div> |
| | | <div> |
| | | 3、宏博远达一直秉承“用智慧为客户创造价值”的宗旨,愿以“诚信负责”的态度和专业化的服务,在企业信息化发展的道路上,与客户一起成长,共同见证成功! |
| | | </div> |
| | | </el-collapse-item> |
| | | |
| | | <el-collapse-item name="2" title="服务计划制定"> |
| | |
| | | |
| | | <span>说明文档</span> |
| | | <el-divider direction="vertical"/> |
| | | <span><el-link href="https://bladex.vip" target="_blank" |
| | | type="primary">https://bladex.vip</el-link></span> |
| | | <span> |
| | | <el-link href="https://bladex.vip" target="_blank" |
| | | type="primary">https://bladex.vip |
| | | </el-link> |
| | | </span> |
| | | <el-divider content-position="right"><i class="el-icon-star-off"/></el-divider> |
| | | |
| | | </div> |
| | |
| | | import 'echarts/lib/chart/pie' // 导入柱状图组件 |
| | | import 'echarts/lib/component/tooltip' |
| | | import 'echarts/lib/component/legend' |
| | | import func from "@/util/func"; |
| | | |
| | | export default { |
| | | name: "wel", |
| | |
| | | this.getLogHandler(); |
| | | }, |
| | | methods: { |
| | | handleChange(val) { |
| | | window.console.log(val); |
| | | }, |
| | | |
| | | getLogHandler() { |
| | | this.loading = true; |
| | | |