Browse Source

add taskInstance link, add email title input

pull/2/head
huyuanming 6 years ago
parent
commit
02d5c53a1c
  1. 17
      escheduler-ui/src/js/conf/home/pages/dag/_source/formModel/tasks/sql.vue
  2. 10
      escheduler-ui/src/js/conf/home/pages/projects/pages/taskInstance/_source/list.vue
  3. 2
      escheduler-ui/src/js/module/i18n/locale/en_US.js
  4. 2
      escheduler-ui/src/js/module/i18n/locale/zh_CN.js

17
escheduler-ui/src/js/conf/home/pages/dag/_source/formModel/tasks/sql.vue

@ -28,6 +28,17 @@
</div> </div>
</m-list-box> </m-list-box>
<template v-if="!sqlType && showType.length"> <template v-if="!sqlType && showType.length">
<m-list-box>
<div slot="text">{{$t('Title')}}</div>
<div slot="content">
<x-input
type="input"
v-model="title"
:placeholder="$t('Please enter the title of email')"
autocomplete="off">
</x-input>
</div>
</m-list-box>
<m-list-box> <m-list-box>
<div slot="text">{{$t('Recipient')}}</div> <div slot="text">{{$t('Recipient')}}</div>
<div slot="content"> <div slot="content">
@ -141,6 +152,8 @@
udfs: '', udfs: '',
// Sql type // Sql type
sqlType: 0, sqlType: 0,
// Email title
title: '',
// Form/attachment // Form/attachment
showType: ['TABLE'], showType: ['TABLE'],
// Sql parameter // Sql parameter
@ -241,6 +254,7 @@
sql: editor.getValue(), sql: editor.getValue(),
udfs: this.udfs, udfs: this.udfs,
sqlType: this.sqlType, sqlType: this.sqlType,
title: this.title,
receivers: this.receivers.join(','), receivers: this.receivers.join(','),
receiversCc: this.receiversCc.join(','), receiversCc: this.receiversCc.join(','),
showType: (() => { showType: (() => {
@ -308,6 +322,7 @@
this.showType = [] this.showType = []
} }
if (val !== 0) { if (val !== 0) {
this.title = ''
this.receivers = [] this.receivers = []
this.receiversCc = [] this.receiversCc = []
} }
@ -321,6 +336,7 @@
// //
showType (val) { showType (val) {
if (!val.length) { if (!val.length) {
this.title = ''
this.receivers = [] this.receivers = []
this.receiversCc = [] this.receiversCc = []
} }
@ -342,6 +358,7 @@
this.showType = o.params.showType.split(',') || [] this.showType = o.params.showType.split(',') || []
this.preStatements = o.params.preStatements || [] this.preStatements = o.params.preStatements || []
this.postStatements = o.params.postStatements || [] this.postStatements = o.params.postStatements || []
this.title = o.params.title || ''
this.receivers = o.params.receivers && o.params.receivers.split(',') || [] this.receivers = o.params.receivers && o.params.receivers.split(',') || []
this.receiversCc = o.params.receiversCc && o.params.receiversCc.split(',') || [] this.receiversCc = o.params.receiversCc && o.params.receiversCc.split(',') || []
} }

10
escheduler-ui/src/js/conf/home/pages/projects/pages/taskInstance/_source/list.vue

@ -45,10 +45,9 @@
<span>{{parseInt(pageNo === 1 ? ($index + 1) : (($index + 1) + (pageSize * (pageNo - 1))))}}</span> <span>{{parseInt(pageNo === 1 ? ($index + 1) : (($index + 1) + (pageSize * (pageNo - 1))))}}</span>
</td> </td>
<td> <td>
<span v-if="isAuth" class="ellipsis"><a href="javascript:" class="links">{{item.name}}</a></span> <span class="ellipsis"><a href="javascript:" class="links">{{item.name}}</a></span>
<span v-if="!isAuth" class="ellipsis"><a href="javascript:" class="links">{{item.name}}</a></span>
</td> </td>
<td><span class="ellipsis">{{item.processInstanceName}}</span></td> <td><a href="javascript:" class="links" @click="_go(item)"><span class="ellipsis">{{item.processInstanceName}}</span></a></td>
<td><span>{{item.taskType}}</span></td> <td><span>{{item.taskType}}</span></td>
<td><span v-html="_rtState(item.state)" style="cursor: pointer;"></span></td> <td><span v-html="_rtState(item.state)" style="cursor: pointer;"></span></td>
<td><span>{{item.submitTime | formatDate}}</span></td> <td><span>{{item.submitTime | formatDate}}</span></td>
@ -125,7 +124,10 @@
}) })
} }
}) })
} },
_go (item) {
this.$router.push({ path: `/projects/instance/list/${item.processInstanceId}` })
},
}, },
watch: { watch: {
taskInstanceList (a) { taskInstanceList (a) {

2
escheduler-ui/src/js/module/i18n/locale/en_US.js

@ -111,6 +111,8 @@ export default {
'Please enter ExecutorPlease enter Executor core number': 'Please enter ExecutorPlease enter Executor core number', 'Please enter ExecutorPlease enter Executor core number': 'Please enter ExecutorPlease enter Executor core number',
'Core number should be positive integer': 'Core number should be positive integer', 'Core number should be positive integer': 'Core number should be positive integer',
'SQL Type': 'SQL Type', 'SQL Type': 'SQL Type',
'Title': 'Title',
'Please enter the title of email': 'Please enter the title of email',
'Table': 'Table', 'Table': 'Table',
'Attachment': 'Attachment', 'Attachment': 'Attachment',
'SQL Parameter': 'SQL Parameter', 'SQL Parameter': 'SQL Parameter',

2
escheduler-ui/src/js/module/i18n/locale/zh_CN.js

@ -111,6 +111,8 @@ export default {
'Please enter ExecutorPlease enter Executor core number': '请填写Executor内核数', 'Please enter ExecutorPlease enter Executor core number': '请填写Executor内核数',
'Core number should be positive integer': '内核数为正整数', 'Core number should be positive integer': '内核数为正整数',
'SQL Type': 'sql类型', 'SQL Type': 'sql类型',
'Title': '主题',
'Please enter the title of email': '请输入邮件主题',
'Table': '表格', 'Table': '表格',
'Attachment': '附件', 'Attachment': '附件',
'SQL Parameter': 'sql参数', 'SQL Parameter': 'sql参数',

Loading…
Cancel
Save