Merge pull request 'master' (#26) from master into prod

Reviewed-on: http://git.feashow.cn/clay/mosr-web/pulls/26
This commit is contained in:
2024-03-25 09:09:50 +00:00
17 changed files with 183 additions and 11441 deletions

11294
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -38,6 +38,7 @@
"@codemirror/lang-sql": "^6.5.4",
"@vitejs/plugin-vue": "^4.2.1",
"@vitejs/plugin-vue-jsx": "^3.0.1",
"lodash": "^4.17.21",
"unplugin-auto-import": "^0.15.3",
"unplugin-vue-components": "^0.24.1",
"vite": "^4.3.4",

View File

@@ -224,16 +224,18 @@ html, body, #app, .el-container, .el-aside, .el-main {
position: relative;
.branch-merge {
font-size: 12px;
display: flex;
width: 38px;
align-items: center;
justify-content: center;
flex-direction: column;
font-size: 12px;
width: 30px;
height: 30px;
border-radius: 50%;
left: 0;
right: 0;
margin: -20px auto 0;
background: #fff;
justify-content: center;
flex-direction: column;
box-shadow: 0 0 5px 0 #d8d8d8;
z-index: 0;
position: relative;
@@ -246,6 +248,10 @@ html, body, #app, .el-container, .el-aside, .el-main {
justify-content: center;
z-index: 0;
position: relative;
.el-icon{
width: 1.4em;
height: 1.4em;
}
}
.el-button {
@@ -263,7 +269,7 @@ html, body, #app, .el-container, .el-aside, .el-main {
margin: auto;
width: 2px;
height: 100%;
background-color: #CACACA;
background-color: #000000;
}
}
@@ -439,7 +445,10 @@ html, body, #app, .el-container, .el-aside, .el-main {
overflow: hidden;
margin-right: 5px;
}
.fen-icon{
width: 1.8em;
height: 1.7em;
}
.middle-icon {
width: 1.4em;
height: 1.4em;

View File

@@ -0,0 +1 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1711286414943" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="24248" xmlns:xlink="http://www.w3.org/1999/xlink" width="128" height="128"><path d="M480.246 771.968a128 128 0 1 0 63.488 0 32.32 32.32 0 0 0 0.256-3.96800001c0-75.648 51.392-140.16 180.672-249.59999999 96.256-81.408 102.528-86.912 132.416-118.912C903.414 349.76 927.99 304.25599999 927.99 256c0-1.34399999-0.064-2.688-0.256-3.968a128 128 0 1 0-63.488 0 32.32 32.32 0 0 0-0.256 3.96800001c0 28.672-17.408 60.8-53.76 99.83999999-27.264 29.248-33.6 34.816-126.912 113.728-60.992 51.648-106.816 94.71999999-139.328 135.04L543.99 256.00000001c0-1.34399999-0.064-2.688-0.256-3.96800001a128 128 0 1 0-63.488 0 32.32 32.32 0 0 0-0.256 3.968L479.99 604.608c-32.512-40.32-78.336-83.392-139.328-135.03999999-93.312-78.912-99.648-84.48-126.912-113.72800001-36.352-39.04-53.76-71.168-53.76-99.84 0-1.34399999-0.064-2.688-0.256-3.968a128 128 0 1 0-63.488 0 32.32 32.32 0 0 0-0.25600001 3.968c0 48.256 24.576 93.76 70.91200001 143.488 29.888 32 36.16 37.504 132.416 118.976C428.598 627.84 479.98999999 692.352 479.99 768a32.32 32.32 0 0 0 0.256 3.968zM511.99 192a64 64 0 1 1 0-128 64 64 0 0 1 0 128z m384 0a64 64 0 1 1 0-128 64 64 0 0 1 0 128z m-768 0a64 64 0 1 1 0-128 64 64 0 0 1 0 128z m384 768a64 64 0 1 1 0-128 64 64 0 0 1 0 128z" p-id="24249" fill="#2E7CF0"></path></svg>

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

@@ -73,56 +73,56 @@ const handleViewDetails = (noticeId) => {
viewForm.value = res.data
})
}
const setWsUrl=(url)=>{
return (window.location.protocol === 'http:' ? "ws://" : "wss://")+window.location.host + import.meta.env.VITE_BASE_URL + url;
}
const initWebSocket = () => {
try {
//怎么区分http https /url(全局url) 封装url 只填个url
const wsUrl=setWsUrl('/notice-ws/notice')
const socket = new WebSocket(wsUrl)
// 2. ws.send()给服务器发送信息
//连接发生错误的回调方法
socket.onerror = function () {
console.log("ws连接发生错误");
};
//连接成功建立的回调方法
socket.onopen = function () {
let authInfo = {
token: getToken(),
type: "auth",
cluster: "notice"
}
socket.send(JSON.stringify(authInfo))
console.log("ws连接成功");
}
//接收到消息的回调方法
socket.onmessage = function (event) {
let data = JSON.parse(event.data)
console.log('测试铃铛',data)
if (data.type === 'notice') {
noticeList.value.push(data.notice)
total.value += 1
} else if(!data.type&&data.cluster==="notice"){
noticeList.value.push(data)
total.value += 1
}
// console.log("服务器返回的信息: ", JSON.parse(event.data));
}
//连接关闭的回调方法
socket.onclose = function () {
// initWebSocket()
console.log("ws连接关闭");
}
setInterval(() => {
socket.send(JSON.stringify(send))
}, 30000)
} catch (e) {
console.log(e)
console.log("ws连接失败");
}
}
initWebSocket()
// const setWsUrl=(url)=>{
// return (window.location.protocol === 'http:' ? "ws://" : "wss://")+window.location.host + import.meta.env.VITE_BASE_URL + url;
// }
// const initWebSocket = () => {
// try {
// //怎么区分http https /url(全局url) 封装url 只填个url
// const wsUrl=setWsUrl('/notice-ws/notice')
// const socket = new WebSocket(wsUrl)
// // 2. ws.send()给服务器发送信息
// //连接发生错误的回调方法
// socket.onerror = function () {
// console.log("ws连接发生错误");
// };
// //连接成功建立的回调方法
// socket.onopen = function () {
// let authInfo = {
// token: getToken(),
// type: "auth",
// cluster: "notice"
// }
// socket.send(JSON.stringify(authInfo))
// console.log("ws连接成功");
// }
// //接收到消息的回调方法
// socket.onmessage = function (event) {
// let data = JSON.parse(event.data)
// console.log('测试铃铛',data)
// if (data.type === 'notice') {
// noticeList.value.push(data.notice)
// total.value += 1
// } else if(!data.type&&data.cluster==="notice"){
// noticeList.value.push(data)
// total.value += 1
// }
// // console.log("服务器返回的信息: ", JSON.parse(event.data));
// }
// //连接关闭的回调方法
// socket.onclose = function () {
// // initWebSocket()
// console.log("ws连接关闭");
// }
// setInterval(() => {
// socket.send(JSON.stringify(send))
// }, 30000)
// } catch (e) {
// console.log(e)
// console.log("ws连接失败");
// }
// }
// initWebSocket()
const searchNotifyList = () => {
let params = {

View File

@@ -35,7 +35,6 @@ export const useProcessStore = defineStore('process', () => {
}
const addProcess = (val) => {
console.log("添加节点成功")
processData.value.process.push(val)
}
const delProcess = (delNode) => {
@@ -109,4 +108,4 @@ export const useProcessStore = defineStore('process', () => {
getAssignedUser,
addAssignedUser
}
})
})

View File

@@ -74,7 +74,8 @@ const visible = ref(false)
const timer = ref(null)
const validComponents = ref(['processSetting', 'formDesign', 'processDesign'])
// const activeSelect = ref('formDesign')
const activeSelect = ref('processSetting')
// const activeSelect = ref('processSetting')
const activeSelect = ref('processDesign')
const validVisible = ref(false)
const validStep = ref(0)
const validResult = ref({})

View File

@@ -7,7 +7,6 @@
import {useProcessStore} from '@/stores/processStore.js'
import {computed, defineExpose} from "vue";
const processStore = useProcessStore()
console.log(processStore.getDesign)
const processData = computed(() => {
return processStore.getDesign()
@@ -27,4 +26,4 @@ defineExpose({
<style scoped>
</style>
</style>

View File

@@ -11,6 +11,7 @@ import MergeNode from './nodes/MergeNode.vue'
import DelayNode from './nodes/DelayNode.vue'
import AddBranchNode from './nodes/AddBranchNode.vue'
import { debounce } from 'lodash'
import {defineExpose, h, render, ref} from 'vue'
import DefaultProps from "./DefaultNodeProps"
import {ElMessage, ElMessageBox} from 'element-plus'
@@ -47,7 +48,6 @@ const init = () => {
// 初始化map集合,以便数据整理
const initMapping = (node) => {
console.log("初始化数据", node)
node.forEach(nodeItem => {
processStore.nodeMap.set(nodeItem.id, nodeItem)
processStore.parentMap.set(nodeItem.parentId, nodeItem)
@@ -290,7 +290,7 @@ const selectNode = (node) => {
}
//处理节点插入逻辑
const insertNode = (type, parentNode) => {
const insertNode =debounce( (type, parentNode) => {
//插入新节点
let id = getRandomId();
updateParentId(id, parentNode.id)
@@ -321,9 +321,8 @@ const insertNode = (type, parentNode) => {
default:
break;
}
console.log('开始刷新')
init()
}
},1000)
/**
* 更新父id
* @param newId
@@ -700,8 +699,9 @@ defineExpose({
//background: #f5f6f6;
flex-direction: column;
align-items: center;
border-top: 2px solid #cccccc;
border-bottom: 2px solid #cccccc;
border-top: 2px solid #000000;
border-bottom: 2px solid #000000;
&:before {
content: "";
@@ -711,7 +711,7 @@ defineExpose({
margin: auto;
width: 2px;
height: 100%;
background-color: #CACACA;
background-color: #000000;
}
.line-top-left, .line-top-right, .line-bot-left, .line-bot-right {
@@ -745,7 +745,9 @@ defineExpose({
.add-branch-btn {
position: absolute;
width: 80px;
.el-button {
border-color: #000000;
}
.add-branch-btn-el {
z-index: 999;
position: absolute;

View File

@@ -1,5 +1,5 @@
<template>
<el-popover :visible="visible" placement="bottom-start" title="添加流程节点" width="350">
<el-popover :visible="visible" placement="bottom-start" title="添加流程节点" width="306">
<div class="node-select">
<div @click="addApprovalNode">
<el-icon style="color:rgb(255, 148, 62);">
@@ -39,18 +39,29 @@
</div>
</div>
<template #reference>
<el-button :icon="Plus" slot="reference" type="primary" @click="visible = !visible" size="small" circle></el-button>
<!-- <el-button :icon="Plus" slot="reference" type="primary" @click="visible = !visible" size="small"-->
<!-- circle></el-button>-->
<el-icon @click="visible = !visible" color="#fff" style="background-color:#2E7CF0;border-radius: 50%;cursor: pointer" ><Plus /></el-icon>
</template>
</el-popover>
</template>
<script setup>
import {Plus } from '@element-plus/icons-vue'
import {Plus, Clock, SetUp, Operation, Share, Promotion, Coordinate} from '@element-plus/icons-vue'
const emit = defineEmits(['insertNode'])
const visible = ref(false)
onMounted(() => {
document.addEventListener('click', nullBlockClick)
})
/**
* 点击空白处, 清除选项选中状态
*/
const nullBlockClick = (e) => {
if(!(e.target.tagName==='svg'||e.target.tagName==='path')){
disVisible()
}
}
const addApprovalNode = () => {
emit('insertNode', "APPROVAL")
disVisible()

View File

@@ -46,7 +46,7 @@ const assignedUser = computed(() => {
const headerBgc = computed(() => {
if (props.mode === 'design' || props.mode === 'view') {
return '#ff943e'
return '#F0A32E'
} else {
return props.config.props.headerBgc
}

View File

@@ -27,7 +27,7 @@ import {Promotion} from '@element-plus/icons-vue'
const headerBgc = computed(() => {
if (props.mode === 'design' || props.mode === 'view') {
return '#3296fa'
return '#2EC2F0'
} else {
return props.config.props.headerBgc
}

View File

@@ -29,7 +29,7 @@ const errorInfo = ref('')
const headerBgc = computed(() => {
if (props.mode === 'design' || props.mode === 'view') {
return '#f25643'
return '#F05D2E'
} else {
return props.config.props.headerBgc
}

View File

@@ -1,53 +1,56 @@
<template>
<div :class="{'node': true, 'root': isRoot || !show, 'node-error-state': showError}">
<div v-if="show" @click="emit('selected')" :class="{'node-body': true, 'error': showError}">
<div class="node-body-header" :style="{'background-color': headerBgc}">
<el-icon v-if="headerIcon" size="15">
<component :is="headerIcon"/>
</el-icon>
<ellipsis class="name" hover-tip :content="title"/>
<el-icon v-if="!isRoot && designState" size="15" style="float:right;" @click="emit('delNode')">
<Close/>
</el-icon>
</div>
<div class="node-body-content">
<el-icon v-if="leftIcon">
<component :is="leftIcon"/>
</el-icon>
<template v-if="selectUser.show && mode === 'view'">
<div class="avatar_button">
<avatar-ellipsis :row="3" v-if="userInfo.length > 0" :user-info="userInfo"/>
<el-button type="primary" :icon="Plus" circle/>
</div>
</template>
<template v-else-if="showAvatar">
<span class="placeholder" v-if="userInfo.length === 0">{{ placeholder }}</span>
<avatar-ellipsis :row="3" :user-info="userInfo" v-else/>
</template>
<template v-else>
<span class="placeholder" v-if="(content || '').trim() === ''">{{ placeholder }}</span>
<ellipsis :row="3" :content="content" v-else/>
</template>
</div>
<div class="node-error" v-if="showError">
<el-tooltip effect="dark" :content="errorInfo" placement="top-start">
<el-icon><Warning /></el-icon>
</el-tooltip>
</div>
<div class="node-body-header" :style="{'background-color': headerBgc}">
<el-icon v-if="headerIcon" size="15">
<component :is="headerIcon"/>
</el-icon>
<ellipsis class="name" hover-tip :content="title"/>
<el-icon v-if="!isRoot && designState" size="15" style="float:right;" @click="emit('delNode')">
<Close/>
</el-icon>
</div>
<div class="node-body-content">
<el-icon v-if="leftIcon">
<component :is="leftIcon"/>
</el-icon>
<template v-if="selectUser.show && mode === 'view'">
<div class="avatar_button">
<avatar-ellipsis :row="3" v-if="userInfo.length > 0" :user-info="userInfo"/>
<el-button type="primary" :icon="Plus" circle/>
</div>
</template>
<template v-else-if="showAvatar">
<span class="placeholder" v-if="userInfo.length === 0">{{ placeholder }}</span>
<avatar-ellipsis :row="3" :user-info="userInfo" v-else/>
</template>
<template v-else>
<span class="placeholder" v-if="(content || '').trim() === ''">{{ placeholder }}</span>
<ellipsis :row="3" :content="content" v-else/>
</template>
</div>
<div class="node-error" v-if="showError">
<el-tooltip effect="dark" :content="errorInfo" placement="top-start">
<el-icon>
<Warning/>
</el-icon>
</el-tooltip>
</div>
</div>
<div class="node-footer">
<div v-if="merge" class="branch-merge">
<img data-v-1e7b1da5=""
src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAABXlJREFUeF7tmm2IVGUUx3/nLkQUqxmkpAVhSPUllZX8EEGhvVgZQWCU6wcpsqi2mXtnoaBwoqLCufeO9oJYUJQiFZWlZPQCfYiIXkylstTyS1oWWeYWCe6cuLsz7t3r3Ll3du6907oz35bnPM9z/r895zznmWeECf6RCa6fDoBOBExwAp0UmOAB0CmCnRTopECbCZi2nivK1CMD7FpXlH+ydqctKZBz9QyjwkqFG4HzfKK/0gpvl/ulmBWIzAHkVmlRDFY2EihwwLFkRhYQxgzAtHW2CpcBc4CpOsg26eK7yVPYVFwu/9ZzPufq2VLhQBxhAk85lvSF2Y5l/3prjQlAvqR3IjwJTKqz6DeGssQuyLfBsbyjz6PcFgeAZyOwzLFk/QnrjHH/RACYtj6ncHuUCDWYXs7Lz367XEn3inB+1NzauMLGsiW3+u1b2b9lAH22LuiCD2IJED5yTbmiZpt3dAbKT7Hmjhjtdi25oPZnK/uH7dtUCpi2vqVwQ1wRWuHhWkW3StpTEb6IO3fIThhwTemuzWll/0QA5G39FTgrtghhs2vKELA7inra6d38HXvusOEnriWXHo+iFvZvGUDfap3VdYzdzQgIHmd5W7cBc2Ovoax1C3KXZ5/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zSNWqvSmeSvMDIAnybT1boWnY0I4aigL7YJ4bXRqn0wBeCqG7gYVVqFcFapKWXt0gP5nizKQmvLqwpkDqAkaanmhB4MelOkI27XCDjHY7pqyN23htfXbBiArgVH7dABEETrZxzsRcLL/h6P0/Qc1qphfvB2K3wAAAABJRU5ErkJggg=="
alt="">
<svg-icon name="fenzhi" :class-name="'fen-icon'"/>
<!-- <img data-v-1e7b1da5=""-->
<!-- src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAABXlJREFUeF7tmm2IVGUUx3/nLkQUqxmkpAVhSPUllZX8EEGhvVgZQWCU6wcpsqi2mXtnoaBwoqLCufeO9oJYUJQiFZWlZPQCfYiIXkylstTyS1oWWeYWCe6cuLsz7t3r3Ll3du6907oz35bnPM9z/r895zznmWeECf6RCa6fDoBOBExwAp0UmOAB0CmCnRTopECbCZi2nivK1CMD7FpXlH+ydqctKZBz9QyjwkqFG4HzfKK/0gpvl/ulmBWIzAHkVmlRDFY2EihwwLFkRhYQxgzAtHW2CpcBc4CpOsg26eK7yVPYVFwu/9ZzPufq2VLhQBxhAk85lvSF2Y5l/3prjQlAvqR3IjwJTKqz6DeGssQuyLfBsbyjz6PcFgeAZyOwzLFk/QnrjHH/RACYtj6ncHuUCDWYXs7Lz367XEn3inB+1NzauMLGsiW3+u1b2b9lAH22LuiCD2IJED5yTbmiZpt3dAbKT7Hmjhjtdi25oPZnK/uH7dtUCpi2vqVwQ1wRWuHhWkW3StpTEb6IO3fIThhwTemuzWll/0QA5G39FTgrtghhs2vKELA7inra6d38HXvusOEnriWXHo+iFvZvGUDfap3VdYzdzQgIHmd5W7cBc2Ovoax1C3KXZ5/E/i3VgCQciNMD+J1Ug55yXjxo7QfgOdFKCvjyeL/C9MgoEBa5przrt0ti/+C+mRVB/8amrWsU7m2Ql/c5lqwJjre9CDZ1DMFnriXzw0SatvZW4FqBW6o2vwGvCGxyLPmw3rym9g8cwy0X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c1qphfvB2K3wAAAABJRU5ErkJggg=="-->
<!-- alt="">-->
</div>
<div class="btn">
<insert-button v-if="designState" @insertNode="type => emit('insertNode', type)"/>
</div>
</div>
<!-- <user-picker v-if="selectUser.show" title="请选择系统用户" :multiple="selectUser.multiple" ref="userPicker"-->
<!-- :selected="_userInfo"-->
<!-- @ok="selectedUser"/>-->
<!-- <user-picker v-if="selectUser.show" title="请选择系统用户" :multiple="selectUser.multiple" ref="userPicker"-->
<!-- :selected="_userInfo"-->
<!-- @ok="selectedUser"/>-->
</div>
</template>
@@ -55,18 +58,19 @@
import InsertButton from '../common/InsertButton.vue'
import Ellipsis from '../common/Ellipsis.vue'
import AvatarEllipsis from '../common/AvatarEllipsis.vue'
import {defineProps,defineEmits} from "vue";
import SvgIcon from '@/components/svgIcon/index.vue'
import {Close, Warning, Plus} from '@element-plus/icons-vue'
const emit = defineEmits(['insertNode'])
import {Close,Warning,Plus} from '@element-plus/icons-vue'
const props = defineProps({
//是否为根节点
isRoot: {
type: Boolean,
default: false
},
nodeId:{
type:String,
default:()=>{
nodeId: {
type: String,
default: () => {
return "";
}
},
@@ -144,7 +148,7 @@ const props = defineProps({
}
})
const designState = computed(()=>{
const designState = computed(() => {
return props.mode === 'design'
})
@@ -165,7 +169,7 @@ const init = () => {
// }
}
init()
// init()
</script>
<style lang="scss" scoped>
@@ -185,15 +189,15 @@ init()
&:before {
content: '';
position: absolute;
top: -12px;
top: -9px;
left: 50%;
-webkit-transform: translateX(-50%);
transform: translateX(-50%);
width: 0;
border-style: solid;
border-width: 8px 6px 4px;
border-color: #CACACA transparent transparent;
background: #F5F5F7;
border-color: #000000 transparent transparent;
background: #ffffff;
}
.node-body {
@@ -216,6 +220,7 @@ init()
}
.node-body-header {
text-align: center;
border-top-left-radius: 5px;
border-top-right-radius: 5px;
padding: 5px 15px;
@@ -227,8 +232,8 @@ init()
}
.name {
height: 14px;
width: 150px;
//height: 14px;
//width: 150px;
display: inline-block
}
}
@@ -243,6 +248,7 @@ init()
display: flex;
//flex: 1;
flex-wrap: wrap;
button {
margin-top: 3px;
height: 40px;

View File

@@ -1,13 +1,13 @@
<template>
<node title="发起人" :is-root="true" :mode="mode" :content="content" show-avatar :user-info="config.props.assignedUser"
@selected="emit('selected')" @insertNode="type => emit('insertNode', type)"
placeholder="所有人" :header-bgc="config.props.headerBgc" :header-icon="UserFilled"/>
placeholder="所有人" :header-bgc="headerBgc" :header-icon="UserFilled"/>
</template>
<script setup>
import Node from './Node.vue'
import {UserFilled} from '@element-plus/icons-vue'
import {defineExpose, defineProps} from "vue";
import {computed, defineExpose, defineProps} from "vue";
const emit = defineEmits(['insertNode','selected'])
const props = defineProps({
@@ -34,6 +34,14 @@ const content = computed(() => {
}
})
const headerBgc = computed(() => {
if (props.mode === 'design' || props.mode === 'view') {
return '#2E7CF0'
} else {
return props.config.props.headerBgc
}
})
const validate = () => {
console.log("调用成功")

View File

@@ -31,12 +31,11 @@ const preview = computed(() => {
})
const headerBgc = computed(() => {
return '#47bc82'
// if (preview || !viewer) {
// return '#ff943e'
// } else {
// return props.config.props.headerBgc
// }
if (props.mode === 'design' || props.mode === 'view') {
return '#BE2EF0'
} else {
return props.config.props.headerBgc
}
})
const content = computed(() => {
return '请设置触发器'

View File

@@ -69,21 +69,21 @@ export default defineConfig({
strictPort: false,
open: true,
proxy: {
'/api/admin': {
target: 'http://dev-mosr.frp.feashow.cn/',
// target: 'http://192.168.31.175:8000',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/api/, '')
},
// '/api/admin': {
// target: 'http://dev-mosr.frp.feashow.cn/',
// // target: 'http://192.168.31.175:8000',
// changeOrigin: true,
// rewrite: (path) => path.replace(/^\/api/, '')
// },
'/api': {
target: 'http://mosr.feashow.cn',
changeOrigin: true,
},
'/api/notice-ws': {
target: 'ws://mosr.feashow.cn/api/notice-ws',
ws: true,
changeOrigin: true,
}
// '/api/notice-ws': {
// target: 'ws://mosr.feashow.cn/api/notice-ws',
// ws: true,
// changeOrigin: true,
// }
}
}
})