mirror of
https://gitee.com/dolphinscheduler/DolphinScheduler.git
synced 2024-12-02 20:28:03 +08:00
commit
2977e6ae5e
@ -469,121 +469,17 @@ API_BASE = http://192.168.220.204:12345
|
||||
<li><p><code>npm run build</code> 项目打包 (打包后根目录会创建一个名为dist文件夹,用于发布线上Nginx)</p>
|
||||
</li>
|
||||
</ul>
|
||||
<h3 id="2自动化部署">2.自动化部署</h3>
|
||||
<p>前端自动部署基于<code>yum</code>操作,部署之前请先安装更新<code>yum</code></p>
|
||||
<h3 id="2自动化部署">2.自动化部署`</h3>
|
||||
<p>在项目<code>escheduler-ui</code>根目录编辑安装文件<code>vi install(线上环境).sh</code></p>
|
||||
<p>更改前端访问端口和后端代理接口地址</p>
|
||||
<pre><code># 配置前端访问端口
|
||||
esc_proxy="8888"
|
||||
|
||||
# 配置代理后端接口
|
||||
esc_proxy_port="http://192.168.220.154:12345"
|
||||
</code></pre><p>前端自动部署基于<code>yum</code>操作,部署之前请先安装更新`yum</p>
|
||||
<p>在项目<code>escheduler-ui</code>根目录执行<code>./install(线上环境).sh</code> </p>
|
||||
<pre><code>[root@localhost escheduler-ui]# ./install.sh
|
||||
escheduler-ui-install.sh
|
||||
========================================================================配置信息=======================================================================
|
||||
前端访问端口:8888
|
||||
后端代理接口地址:http://192.168.220.154:12345
|
||||
静态文件地址:/data/EasyScheduler/escheduler-ui/dist
|
||||
当前路径:/data/EasyScheduler/escheduler-ui
|
||||
本机ip:192.168.60.94
|
||||
========================================================================配置信息=======================================================================
|
||||
|
||||
获取http://nginx.org/packages/centos/7/noarch/RPMS/nginx-release-centos-7-0.el7.ngx.noarch.rpm
|
||||
警告:/var/tmp/rpm-tmp.pgG0MW: 头V4 RSA/SHA1 Signature, 密钥 ID 7bd9bf62: NOKEY
|
||||
准备中... ################################# [100%]
|
||||
正在升级/安装...
|
||||
1:nginx-release-centos-7-0.el7.ngx ################################# [100%]
|
||||
已加载插件:fastestmirror
|
||||
Loading mirror speeds from cached hostfile
|
||||
* base: mirrors.zju.edu.cn
|
||||
* extras: mirrors.tuna.tsinghua.edu.cn
|
||||
* updates: mirrors.tuna.tsinghua.edu.cn
|
||||
正在解决依赖关系
|
||||
--> 正在检查事务
|
||||
---> 软件包 nginx.x86_64.1.1.14.2-1.el7_4.ngx 将被 安装
|
||||
--> 解决依赖关系完成
|
||||
|
||||
依赖关系解决
|
||||
|
||||
========================================================================================================================================================================================================
|
||||
Package 架构 版本 源 大小
|
||||
========================================================================================================================================================================================================
|
||||
正在安装:
|
||||
nginx x86_64 1:1.14.2-1.el7_4.ngx nginx 754 k
|
||||
|
||||
事务概要
|
||||
========================================================================================================================================================================================================
|
||||
安装 1 软件包
|
||||
|
||||
总下载量:754 k
|
||||
安装大小:2.6 M
|
||||
Downloading packages:
|
||||
nginx-1.14.2-1.el7_4.ngx.x86_64.rpm | 754 kB 00:00:18
|
||||
Running transaction check
|
||||
Running transaction test
|
||||
Transaction test succeeded
|
||||
Running transaction
|
||||
警告:RPM 数据库已被非 yum 程序修改。
|
||||
正在安装 : 1:nginx-1.14.2-1.el7_4.ngx.x86_64 1/1
|
||||
----------------------------------------------------------------------
|
||||
|
||||
Thanks for using nginx!
|
||||
|
||||
Please find the official documentation for nginx here:
|
||||
* http://nginx.org/en/docs/
|
||||
|
||||
Please subscribe to nginx-announce mailing list to get
|
||||
the most important news about nginx:
|
||||
* http://nginx.org/en/support.html
|
||||
|
||||
Commercial subscriptions for nginx are available on:
|
||||
* http://nginx.com/products/
|
||||
|
||||
----------------------------------------------------------------------
|
||||
验证中 : 1:nginx-1.14.2-1.el7_4.ngx.x86_64 1/1
|
||||
|
||||
已安装:
|
||||
nginx.x86_64 1:1.14.2-1.el7_4.ngx
|
||||
|
||||
完毕!
|
||||
nginx 安装成功
|
||||
已加载插件:fastestmirror
|
||||
Loading mirror speeds from cached hostfile
|
||||
* base: mirrors.zju.edu.cn
|
||||
* extras: mirrors.tuna.tsinghua.edu.cn
|
||||
* updates: mirrors.tuna.tsinghua.edu.cn
|
||||
正在解决依赖关系
|
||||
--> 正在检查事务
|
||||
---> 软件包 policycoreutils-python.x86_64.0.2.5-29.el7_6.1 将被 安装
|
||||
--> 解决依赖关系完成
|
||||
|
||||
依赖关系解决
|
||||
|
||||
========================================================================================================================================================================================================
|
||||
Package 架构 版本 源 大小
|
||||
========================================================================================================================================================================================================
|
||||
正在安装:
|
||||
policycoreutils-python x86_64 2.5-29.el7_6.1 updates 456 k
|
||||
|
||||
事务概要
|
||||
========================================================================================================================================================================================================
|
||||
安装 1 软件包
|
||||
|
||||
总下载量:456 k
|
||||
安装大小:1.2 M
|
||||
Downloading packages:
|
||||
policycoreutils-python-2.5-29.el7_6.1.x86_64.rpm | 456 kB 00:00:11
|
||||
Running transaction check
|
||||
Running transaction test
|
||||
Transaction test succeeded
|
||||
Running transaction
|
||||
正在安装 : policycoreutils-python-2.5-29.el7_6.1.x86_64 1/1
|
||||
验证中 : policycoreutils-python-2.5-29.el7_6.1.x86_64 1/1
|
||||
|
||||
已安装:
|
||||
policycoreutils-python.x86_64 0:2.5-29.el7_6.1
|
||||
|
||||
完毕!
|
||||
ValueError: 已定义端口 tcp/8888
|
||||
success
|
||||
success
|
||||
请浏览器访问:http://192.168.60.94:8888
|
||||
[root@localhost escheduler-ui]#
|
||||
</code></pre><h3 id="3手动部署">3.手动部署</h3>
|
||||
<h3 id="3手动部署">3.手动部署</h3>
|
||||
<p>安装epel源 <code>yum install epel-release -y</code></p>
|
||||
<p>安装Nginx <code>yum install nginx -y</code></p>
|
||||
<h4 id="命令">命令</h4>
|
||||
@ -642,6 +538,17 @@ success
|
||||
<h3 id="4liunx下使用node启动并且守护进程">4.Liunx下使用node启动并且守护进程</h3>
|
||||
<p>安装pm2 <code>npm install -g pm2</code></p>
|
||||
<p>在项目<code>escheduler-ui</code>根目录执行 <code>pm2 start npm -- run dev</code> 启动项目</p>
|
||||
<h4 id="命令">命令</h4>
|
||||
<ul>
|
||||
<li><p>启用 <code>pm2 start npm -- run dev</code></p>
|
||||
</li>
|
||||
<li><p>停止 <code>pm2 stop npm</code></p>
|
||||
</li>
|
||||
<li><p>删除 <code>pm2 delete npm</code></p>
|
||||
</li>
|
||||
<li><p>状态 <code>pm2 list</code></p>
|
||||
</li>
|
||||
</ul>
|
||||
<pre><code>
|
||||
[root@localhost escheduler-ui]# pm2 start npm -- run dev
|
||||
[PM2] Applying action restartProcessId on app [npm](ids: 0)
|
||||
@ -697,7 +604,7 @@ client_max_body_size 1024m
|
||||
<script>
|
||||
var gitbook = gitbook || [];
|
||||
gitbook.push(function() {
|
||||
gitbook.page.hasChanged({"page":{"title":"环境搭建","level":"1.2.1","depth":2,"next":{"title":"安装及配置","level":"1.2.2","depth":2,"anchor":"#安装及配置","path":"前端部署文档.md","ref":"前端部署文档.md#安装及配置","articles":[]},"previous":{"title":"前端部署文档","level":"1.2","depth":1,"ref":"","articles":[{"title":"环境搭建","level":"1.2.1","depth":2,"anchor":"#前端项目环境构建及编译","path":"前端部署文档.md","ref":"前端部署文档.md#前端项目环境构建及编译","articles":[]},{"title":"安装及配置","level":"1.2.2","depth":2,"anchor":"#安装及配置","path":"前端部署文档.md","ref":"前端部署文档.md#安装及配置","articles":[]},{"title":"项目生产环境Nginx配置","level":"1.2.3","depth":2,"anchor":"#项目生产环境配置","path":"前端部署文档.md","ref":"前端部署文档.md#项目生产环境配置","articles":[]},{"title":"前端项目发布","level":"1.2.4","depth":2,"anchor":"#前端项目发布","path":"前端部署文档.md","ref":"前端部署文档.md#前端项目发布","articles":[]},{"title":"问题","level":"1.2.5","depth":2,"anchor":"#问题","path":"前端部署文档.md","ref":"前端部署文档.md#问题","articles":[]}]},"dir":"ltr"},"config":{"plugins":["expandable-chapters","insert-logo-link","livereload"],"styles":{"website":"./styles/website.css"},"pluginsConfig":{"livereload":{},"insert-logo-link":{"src":"http://geek.analysys.cn/static/upload/236/2019-03-29/379450b4-7919-4707-877c-4d33300377d4.png","url":"https://github.com/analysys/EasyScheduler"},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"fontsettings":{"theme":"white","family":"sans","size":2},"highlight":{},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false},"expandable-chapters":{}},"theme":"default","author":"YIGUAN","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"调度系统-EasyScheduler","language":"zh-hans","gitbook":"3.2.3","description":"调度系统"},"file":{"path":"前端部署文档.md","mtime":"2019-04-10T09:13:40.540Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2019-04-10T07:14:01.407Z"},"basePath":".","book":{"language":""}});
|
||||
gitbook.page.hasChanged({"page":{"title":"环境搭建","level":"1.2.1","depth":2,"next":{"title":"安装及配置","level":"1.2.2","depth":2,"anchor":"#安装及配置","path":"前端部署文档.md","ref":"前端部署文档.md#安装及配置","articles":[]},"previous":{"title":"前端部署文档","level":"1.2","depth":1,"ref":"","articles":[{"title":"环境搭建","level":"1.2.1","depth":2,"anchor":"#前端项目环境构建及编译","path":"前端部署文档.md","ref":"前端部署文档.md#前端项目环境构建及编译","articles":[]},{"title":"安装及配置","level":"1.2.2","depth":2,"anchor":"#安装及配置","path":"前端部署文档.md","ref":"前端部署文档.md#安装及配置","articles":[]},{"title":"项目生产环境Nginx配置","level":"1.2.3","depth":2,"anchor":"#项目生产环境配置","path":"前端部署文档.md","ref":"前端部署文档.md#项目生产环境配置","articles":[]},{"title":"前端项目发布","level":"1.2.4","depth":2,"anchor":"#前端项目发布","path":"前端部署文档.md","ref":"前端部署文档.md#前端项目发布","articles":[]},{"title":"问题","level":"1.2.5","depth":2,"anchor":"#问题","path":"前端部署文档.md","ref":"前端部署文档.md#问题","articles":[]}]},"dir":"ltr"},"config":{"plugins":["expandable-chapters","insert-logo-link","livereload"],"styles":{"website":"./styles/website.css"},"pluginsConfig":{"livereload":{},"insert-logo-link":{"src":"http://geek.analysys.cn/static/upload/236/2019-03-29/379450b4-7919-4707-877c-4d33300377d4.png","url":"https://github.com/analysys/EasyScheduler"},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"fontsettings":{"theme":"white","family":"sans","size":2},"highlight":{},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false},"expandable-chapters":{}},"theme":"default","author":"YIGUAN","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"调度系统-EasyScheduler","language":"zh-hans","gitbook":"3.2.3","description":"调度系统"},"file":{"path":"前端部署文档.md","mtime":"2019-04-12T01:30:07.632Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2019-04-10T07:14:01.407Z"},"basePath":".","book":{"language":""}});
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
|
@ -45,126 +45,24 @@ API_BASE = http://192.168.220.204:12345
|
||||
|
||||
|
||||
|
||||
### 2.自动化部署
|
||||
### 2.自动化部署`
|
||||
|
||||
前端自动部署基于`yum`操作,部署之前请先安装更新`yum`
|
||||
在项目`escheduler-ui`根目录编辑安装文件`vi install(线上环境).sh`
|
||||
|
||||
更改前端访问端口和后端代理接口地址
|
||||
|
||||
```
|
||||
# 配置前端访问端口
|
||||
esc_proxy="8888"
|
||||
|
||||
# 配置代理后端接口
|
||||
esc_proxy_port="http://192.168.220.154:12345"
|
||||
```
|
||||
|
||||
前端自动部署基于`yum`操作,部署之前请先安装更新`yum
|
||||
|
||||
在项目`escheduler-ui`根目录执行`./install(线上环境).sh`
|
||||
|
||||
```
|
||||
[root@localhost escheduler-ui]# ./install.sh
|
||||
escheduler-ui-install.sh
|
||||
========================================================================配置信息=======================================================================
|
||||
前端访问端口:8888
|
||||
后端代理接口地址:http://192.168.220.154:12345
|
||||
静态文件地址:/data/EasyScheduler/escheduler-ui/dist
|
||||
当前路径:/data/EasyScheduler/escheduler-ui
|
||||
本机ip:192.168.60.94
|
||||
========================================================================配置信息=======================================================================
|
||||
|
||||
获取http://nginx.org/packages/centos/7/noarch/RPMS/nginx-release-centos-7-0.el7.ngx.noarch.rpm
|
||||
警告:/var/tmp/rpm-tmp.pgG0MW: 头V4 RSA/SHA1 Signature, 密钥 ID 7bd9bf62: NOKEY
|
||||
准备中... ################################# [100%]
|
||||
正在升级/安装...
|
||||
1:nginx-release-centos-7-0.el7.ngx ################################# [100%]
|
||||
已加载插件:fastestmirror
|
||||
Loading mirror speeds from cached hostfile
|
||||
* base: mirrors.zju.edu.cn
|
||||
* extras: mirrors.tuna.tsinghua.edu.cn
|
||||
* updates: mirrors.tuna.tsinghua.edu.cn
|
||||
正在解决依赖关系
|
||||
--> 正在检查事务
|
||||
---> 软件包 nginx.x86_64.1.1.14.2-1.el7_4.ngx 将被 安装
|
||||
--> 解决依赖关系完成
|
||||
|
||||
依赖关系解决
|
||||
|
||||
========================================================================================================================================================================================================
|
||||
Package 架构 版本 源 大小
|
||||
========================================================================================================================================================================================================
|
||||
正在安装:
|
||||
nginx x86_64 1:1.14.2-1.el7_4.ngx nginx 754 k
|
||||
|
||||
事务概要
|
||||
========================================================================================================================================================================================================
|
||||
安装 1 软件包
|
||||
|
||||
总下载量:754 k
|
||||
安装大小:2.6 M
|
||||
Downloading packages:
|
||||
nginx-1.14.2-1.el7_4.ngx.x86_64.rpm | 754 kB 00:00:18
|
||||
Running transaction check
|
||||
Running transaction test
|
||||
Transaction test succeeded
|
||||
Running transaction
|
||||
警告:RPM 数据库已被非 yum 程序修改。
|
||||
正在安装 : 1:nginx-1.14.2-1.el7_4.ngx.x86_64 1/1
|
||||
----------------------------------------------------------------------
|
||||
|
||||
Thanks for using nginx!
|
||||
|
||||
Please find the official documentation for nginx here:
|
||||
* http://nginx.org/en/docs/
|
||||
|
||||
Please subscribe to nginx-announce mailing list to get
|
||||
the most important news about nginx:
|
||||
* http://nginx.org/en/support.html
|
||||
|
||||
Commercial subscriptions for nginx are available on:
|
||||
* http://nginx.com/products/
|
||||
|
||||
----------------------------------------------------------------------
|
||||
验证中 : 1:nginx-1.14.2-1.el7_4.ngx.x86_64 1/1
|
||||
|
||||
已安装:
|
||||
nginx.x86_64 1:1.14.2-1.el7_4.ngx
|
||||
|
||||
完毕!
|
||||
nginx 安装成功
|
||||
已加载插件:fastestmirror
|
||||
Loading mirror speeds from cached hostfile
|
||||
* base: mirrors.zju.edu.cn
|
||||
* extras: mirrors.tuna.tsinghua.edu.cn
|
||||
* updates: mirrors.tuna.tsinghua.edu.cn
|
||||
正在解决依赖关系
|
||||
--> 正在检查事务
|
||||
---> 软件包 policycoreutils-python.x86_64.0.2.5-29.el7_6.1 将被 安装
|
||||
--> 解决依赖关系完成
|
||||
|
||||
依赖关系解决
|
||||
|
||||
========================================================================================================================================================================================================
|
||||
Package 架构 版本 源 大小
|
||||
========================================================================================================================================================================================================
|
||||
正在安装:
|
||||
policycoreutils-python x86_64 2.5-29.el7_6.1 updates 456 k
|
||||
|
||||
事务概要
|
||||
========================================================================================================================================================================================================
|
||||
安装 1 软件包
|
||||
|
||||
总下载量:456 k
|
||||
安装大小:1.2 M
|
||||
Downloading packages:
|
||||
policycoreutils-python-2.5-29.el7_6.1.x86_64.rpm | 456 kB 00:00:11
|
||||
Running transaction check
|
||||
Running transaction test
|
||||
Transaction test succeeded
|
||||
Running transaction
|
||||
正在安装 : policycoreutils-python-2.5-29.el7_6.1.x86_64 1/1
|
||||
验证中 : policycoreutils-python-2.5-29.el7_6.1.x86_64 1/1
|
||||
|
||||
已安装:
|
||||
policycoreutils-python.x86_64 0:2.5-29.el7_6.1
|
||||
|
||||
完毕!
|
||||
ValueError: 已定义端口 tcp/8888
|
||||
success
|
||||
success
|
||||
请浏览器访问:http://192.168.60.94:8888
|
||||
[root@localhost escheduler-ui]#
|
||||
|
||||
```
|
||||
|
||||
|
||||
|
||||
@ -247,6 +145,16 @@ systemctl restart nginx
|
||||
|
||||
在项目`escheduler-ui`根目录执行 `pm2 start npm -- run dev` 启动项目
|
||||
|
||||
#### 命令
|
||||
|
||||
- 启用 `pm2 start npm -- run dev`
|
||||
|
||||
- 停止 `pm2 stop npm`
|
||||
|
||||
- 删除 `pm2 delete npm`
|
||||
|
||||
- 状态 `pm2 list`
|
||||
|
||||
```
|
||||
|
||||
[root@localhost escheduler-ui]# pm2 start npm -- run dev
|
||||
|
@ -1,6 +1,8 @@
|
||||
|
||||
# 后端接口地址
|
||||
API_BASE = http://192.168.220.154:12345
|
||||
#API_BASE = http://192.168.220.154:12345
|
||||
|
||||
API_BASE = http://192.168.221.188:12345
|
||||
|
||||
# 本地开发如需ip访问项目把"#"号去掉
|
||||
#DEV_HOST = 192.168.xx.xx
|
||||
|
@ -41,7 +41,6 @@
|
||||
"env-parse": "^1.0.5",
|
||||
"extract-text-webpack-plugin": "^3.0.2",
|
||||
"file-loader": "^1.1.11",
|
||||
"ghooks": "^2.0.4",
|
||||
"globby": "^8.0.1",
|
||||
"html-loader": "^0.5.5",
|
||||
"html-webpack-ext-plugin": "^1.0.0",
|
||||
@ -76,9 +75,6 @@
|
||||
"build/**"
|
||||
]
|
||||
},
|
||||
"config": {
|
||||
"ghooks": {}
|
||||
},
|
||||
"devDependencies": {
|
||||
"jasmine-core": "^3.2.1",
|
||||
"jquery": "1.12.4",
|
||||
|
@ -96,6 +96,3 @@
|
||||
components: { mPopup, mListBoxF }
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" rel="stylesheet/scss">
|
||||
</style>
|
||||
|
@ -11,8 +11,8 @@
|
||||
<template slot="content">
|
||||
<x-input
|
||||
type="input"
|
||||
v-model="tenantName"
|
||||
:placeholder="$t('请输入name')"
|
||||
v-model="queueName"
|
||||
placeholder="请输入名称"
|
||||
autocomplete="off">
|
||||
</x-input>
|
||||
</template>
|
||||
@ -22,8 +22,8 @@
|
||||
<template slot="content">
|
||||
<x-input
|
||||
type="input"
|
||||
v-model="tenantName"
|
||||
:placeholder="$t('请输入name')"
|
||||
v-model="queue"
|
||||
placeholder="请输入队列值"
|
||||
autocomplete="off">
|
||||
</x-input>
|
||||
</template>
|
||||
@ -45,18 +45,72 @@
|
||||
data () {
|
||||
return {
|
||||
store,
|
||||
queue:'',
|
||||
queueName:''
|
||||
}
|
||||
},
|
||||
props: {
|
||||
item: Object
|
||||
},
|
||||
methods: {
|
||||
_ok(){
|
||||
if (!this._verification()) {
|
||||
return
|
||||
}
|
||||
|
||||
let param = {
|
||||
queue: _.trim(this.queue),
|
||||
queueName: _.trim(this.queueName)
|
||||
}
|
||||
// edit
|
||||
if (this.item) {
|
||||
param.id = this.item.id
|
||||
}
|
||||
this._verifyName(param).then(() => {
|
||||
this.$refs['popup'].spinnerLoading = true
|
||||
this.store.dispatch(`security/${this.item ? 'updateQueueQ' : 'createQueueQ'}`, param).then(res => {
|
||||
this.$emit('onUpdate')
|
||||
this.$message.success(res.msg)
|
||||
setTimeout(() => {
|
||||
this.$refs['popup'].spinnerLoading = false
|
||||
}, 800)
|
||||
}).catch(e => {
|
||||
this.$message.error(e.msg || '')
|
||||
this.$refs['popup'].spinnerLoading = false
|
||||
})
|
||||
}).catch(e => {
|
||||
this.$message.error(e.msg || '')
|
||||
})
|
||||
|
||||
},
|
||||
_verification(){
|
||||
if (!this.queueName) {
|
||||
this.$message.warning(`请输入名称`)
|
||||
return false
|
||||
}
|
||||
if (!this.queue) {
|
||||
this.$message.warning(`请输入队列值`)
|
||||
return false
|
||||
}
|
||||
return true
|
||||
},
|
||||
_verifyName(param){
|
||||
return new Promise((resolve, reject) => {
|
||||
this.store.dispatch(`security/verifyQueueQ`, param).then(res => {
|
||||
resolve()
|
||||
}).catch(e => {
|
||||
reject(e)
|
||||
})
|
||||
})
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
},
|
||||
created () {
|
||||
|
||||
if (this.item) {
|
||||
this.queueName = this.item.queueName
|
||||
this.queue = this.item.queue
|
||||
}
|
||||
},
|
||||
mounted () {
|
||||
|
||||
|
@ -7,16 +7,10 @@
|
||||
<span>{{$t('编号')}}</span>
|
||||
</th>
|
||||
<th>
|
||||
<span>{{$t('租户编码')}}</span>
|
||||
<span>{{$t('名称')}}</span>
|
||||
</th>
|
||||
<th>
|
||||
<span>{{$t('租户名称')}}</span>
|
||||
</th>
|
||||
<th>
|
||||
<span>{{$t('描述')}}</span>
|
||||
</th>
|
||||
<th>
|
||||
<span>{{$t('队列')}}</span>
|
||||
<span>队列值</span>
|
||||
</th>
|
||||
<th>
|
||||
<span>{{$t('创建时间')}}</span>
|
||||
@ -35,25 +29,25 @@
|
||||
<td>
|
||||
<span>
|
||||
<a href="javascript:" class="links">
|
||||
{{item.tenantCode}}
|
||||
{{item.queueName}}
|
||||
</a>
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<span>
|
||||
<a href="javascript:" class="links">
|
||||
{{item.tenantName}}
|
||||
{{item.queue}}
|
||||
</a>
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<span>{{item.desc}}</span>
|
||||
<span v-if="item.createTime">{{item.createTime | formatDate}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td>
|
||||
<span>{{item.queueName}}</span>
|
||||
<span v-if="item.updateTime">{{item.updateTime | formatDate}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td><span>{{item.createTime | formatDate}}</span></td>
|
||||
<td><span>{{item.updateTime | formatDate}}</span></td>
|
||||
<td>
|
||||
<x-button
|
||||
type="info"
|
||||
@ -96,7 +90,7 @@
|
||||
}
|
||||
},
|
||||
props: {
|
||||
tenementList: Array,
|
||||
queueList: Array,
|
||||
pageNo: Number,
|
||||
pageSize: Number
|
||||
},
|
||||
@ -118,11 +112,11 @@
|
||||
})
|
||||
},
|
||||
_edit (item) {
|
||||
findComponentDownward(this.$root, 'tenement-index')._create(item)
|
||||
findComponentDownward(this.$root, 'queue-index')._create(item)
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
tenementList (a) {
|
||||
queueList (a) {
|
||||
this.list = []
|
||||
setTimeout(() => {
|
||||
this.list = a
|
||||
@ -130,7 +124,7 @@
|
||||
}
|
||||
},
|
||||
created () {
|
||||
this.list = this.tenementList
|
||||
this.list = this.queueList
|
||||
},
|
||||
mounted () {
|
||||
},
|
||||
|
@ -11,13 +11,13 @@
|
||||
</m-conditions>
|
||||
</template>
|
||||
<template slot="content">
|
||||
<template v-if="tenementList.length">
|
||||
<m-list :tenement-list="tenementList" :page-no="pageNo" :page-size="pageSize"></m-list>
|
||||
<template v-if="queueList.length">
|
||||
<m-list :queue-list="queueList" :page-no="pageNo" :page-size="pageSize"></m-list>
|
||||
<div class="page-box">
|
||||
<x-page :current="pageNo" :total="total" show-elevator @on-change="_page"></x-page>
|
||||
</div>
|
||||
</template>
|
||||
<template v-if="!tenementList.length">
|
||||
<template v-if="!queueList.length">
|
||||
<m-no-data></m-no-data>
|
||||
</template>
|
||||
<m-spin :is-spin="isLoading"></m-spin>
|
||||
@ -45,23 +45,23 @@
|
||||
total: null,
|
||||
searchVal: '',
|
||||
isLoading: true,
|
||||
tenementList: []
|
||||
queueList: []
|
||||
}
|
||||
},
|
||||
props: {},
|
||||
methods: {
|
||||
...mapActions('security', ['getTenantListP']),
|
||||
...mapActions('security', ['getQueueListP']),
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
_onConditions (o) {
|
||||
this.searchVal = o.searchVal
|
||||
this.pageNo = 1
|
||||
this._getTenantListP()
|
||||
this._getQueueListP()
|
||||
},
|
||||
_page (val) {
|
||||
this.pageNo = val
|
||||
this._getTenantListP()
|
||||
this._getQueueListP()
|
||||
},
|
||||
_create (item) {
|
||||
let self = this
|
||||
@ -75,7 +75,7 @@
|
||||
return h(mCreateQueue, {
|
||||
on: {
|
||||
onUpdate () {
|
||||
self._getTenantListP('false')
|
||||
self._getQueueListP('false')
|
||||
modal.remove()
|
||||
},
|
||||
close () {
|
||||
@ -89,14 +89,14 @@
|
||||
}
|
||||
})
|
||||
},
|
||||
_getTenantListP (flag) {
|
||||
_getQueueListP (flag) {
|
||||
this.isLoading = !flag
|
||||
this.getTenantListP({
|
||||
this.getQueueListP({
|
||||
pageSize: this.pageSize,
|
||||
pageNo: this.pageNo,
|
||||
searchVal: this.searchVal
|
||||
}).then(res => {
|
||||
this.tenementList = res.totalList
|
||||
this.queueList = res.totalList
|
||||
this.total = res.total
|
||||
this.isLoading = false
|
||||
}).catch(e => {
|
||||
@ -106,7 +106,7 @@
|
||||
},
|
||||
watch: {},
|
||||
created () {
|
||||
this._getTenantListP()
|
||||
this._getQueueListP()
|
||||
},
|
||||
mounted () {
|
||||
|
||||
|
@ -50,7 +50,7 @@
|
||||
},
|
||||
props: {},
|
||||
methods: {
|
||||
...mapActions('security', ['getUsersListP']),
|
||||
...mapActions('security', ['getUsersList']),
|
||||
/**
|
||||
* 查询
|
||||
*/
|
||||
@ -91,7 +91,7 @@
|
||||
},
|
||||
_getUsersListP (flag) {
|
||||
this.isLoading = !flag
|
||||
this.getUsersListP({
|
||||
this.getUsersList({
|
||||
pageSize: this.pageSize,
|
||||
pageNo: this.pageNo,
|
||||
searchVal: this.searchVal
|
||||
|
@ -90,7 +90,7 @@ export default {
|
||||
* @param "searchVal":string,
|
||||
* @param "pageSize":int
|
||||
*/
|
||||
getUsersListP ({ state }, payload) {
|
||||
getUsersList ({ state }, payload) {
|
||||
return new Promise((resolve, reject) => {
|
||||
io.get(`users/list-paging`, payload, res => {
|
||||
resolve(res.data)
|
||||
@ -353,5 +353,53 @@ export default {
|
||||
reject(e)
|
||||
})
|
||||
})
|
||||
}
|
||||
},
|
||||
/**
|
||||
* get queue list pages
|
||||
*/
|
||||
getQueueListP({ state }, payload){
|
||||
return new Promise((resolve, reject) => {
|
||||
io.get(`queue/list-paging`, payload, res => {
|
||||
resolve(res.data)
|
||||
}).catch(e => {
|
||||
reject(e)
|
||||
})
|
||||
})
|
||||
},
|
||||
/**
|
||||
* create queue
|
||||
*/
|
||||
createQueueQ({ state }, payload){
|
||||
return new Promise((resolve, reject) => {
|
||||
io.post(`queue/create`, payload, res => {
|
||||
resolve(res)
|
||||
}).catch(e => {
|
||||
reject(e)
|
||||
})
|
||||
})
|
||||
},
|
||||
/**
|
||||
* update queue
|
||||
*/
|
||||
updateQueueQ({ state }, payload){
|
||||
return new Promise((resolve, reject) => {
|
||||
io.post(`queue/update`, payload, res => {
|
||||
resolve(res)
|
||||
}).catch(e => {
|
||||
reject(e)
|
||||
})
|
||||
})
|
||||
},
|
||||
/**
|
||||
* update queue
|
||||
*/
|
||||
verifyQueueQ({ state }, payload){
|
||||
return new Promise((resolve, reject) => {
|
||||
io.post(`queue/verify-queue`, payload, res => {
|
||||
resolve(res)
|
||||
}).catch(e => {
|
||||
reject(e)
|
||||
})
|
||||
})
|
||||
},
|
||||
}
|
||||
|
@ -87,7 +87,7 @@ let menu = {
|
||||
id: 1,
|
||||
path: 'queue-manage',
|
||||
isOpen: true,
|
||||
icon: 'fa-warning',
|
||||
icon: 'fa-recycle',
|
||||
children: []
|
||||
},
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user