Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibztask
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibztask
提交
217474d5
提交
217474d5
编写于
7月 17, 2020
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
ibiz4j 发布系统代码
上级
f2bee743
变更
69
展开全部
显示空白字符变更
内嵌
并排
正在显示
69 个修改的文件
包含
1103 行增加
和
513 行删除
+1103
-513
CHANGELOG.md
app_web/CHANGELOG.md
+82
-2
package.json
app_web/package.json
+1
-0
app-register.ts
app_web/src/app-register.ts
+2
-0
app-actionbar.vue
app_web/src/components/app-actionbar/app-actionbar.vue
+94
-5
app-breadcrumb.vue
app_web/src/components/app-breadcrumb/app-breadcrumb.vue
+1
-0
app-form-druipart.vue
...eb/src/components/app-form-druipart/app-form-druipart.vue
+3
-2
app-form-group.vue
app_web/src/components/app-form-group/app-form-group.vue
+3
-2
app-menu-item.vue
app_web/src/components/app-menu-item/app-menu-item.vue
+98
-0
app-picker.vue
app_web/src/components/app-picker/app-picker.vue
+1
-1
app-span.vue
app_web/src/components/app-span/app-span.vue
+74
-2
input-box.vue
app_web/src/components/input-box/input-box.vue
+1
-24
view-engine.ts
app_web/src/engine/view/view-engine.ts
+4
-2
jobs-info-edit-view-base.vue
...ges/task/jobs-info-edit-view/jobs-info-edit-view-base.vue
+1
-1
jobs-info-grid-view-base.vue
...ges/task/jobs-info-grid-view/jobs-info-grid-view-base.vue
+1
-1
jobs-log-edit-view-base.vue
...pages/task/jobs-log-edit-view/jobs-log-edit-view-base.vue
+1
-1
jobs-log-grid-view-base.vue
...pages/task/jobs-log-grid-view/jobs-log-grid-view-base.vue
+1
-1
jobs-registry-edit-view-base.vue
.../jobs-registry-edit-view/jobs-registry-edit-view-base.vue
+1
-1
jobs-registry-grid-view-base.vue
.../jobs-registry-grid-view/jobs-registry-grid-view-base.vue
+1
-1
entity-service.ts
app_web/src/service/entity-service.ts
+15
-1
jobs-info-service-base.ts
app_web/src/service/jobs-info/jobs-info-service-base.ts
+20
-7
jobs-lock-service-base.ts
app_web/src/service/jobs-lock/jobs-lock-service-base.ts
+14
-4
jobs-log-service-base.ts
app_web/src/service/jobs-log/jobs-log-service-base.ts
+14
-4
jobs-registry-service-base.ts
...b/src/service/jobs-registry/jobs-registry-service-base.ts
+14
-4
jobs-info-ui-service-base.ts
app_web/src/uiservice/jobs-info/jobs-info-ui-service-base.ts
+1
-1
jobs-lock-ui-service-base.ts
app_web/src/uiservice/jobs-lock/jobs-lock-ui-service-base.ts
+1
-1
jobs-log-ui-service-base.ts
app_web/src/uiservice/jobs-log/jobs-log-ui-service-base.ts
+1
-1
jobs-registry-ui-service-base.ts
.../uiservice/jobs-registry/jobs-registry-ui-service-base.ts
+1
-1
app-popover.less
app_web/src/utils/app-popover/app-popover.less
+14
-42
app-popover.tsx
app_web/src/utils/app-popover/app-popover.tsx
+75
-197
errorlog.ts
app_web/src/utils/decorators/errorlog.ts
+1
-4
view-tool.ts
app_web/src/utils/view-tool/view-tool.ts
+3
-2
task-index-view-appmenu-base.vue
.../task-index-view-appmenu/task-index-view-appmenu-base.vue
+1
-105
default-searchform-base.vue
.../jobs-info/default-searchform/default-searchform-base.vue
+3
-0
default-searchform-service.ts
...obs-info/default-searchform/default-searchform-service.ts
+21
-1
main-form-base.vue
app_web/src/widgets/jobs-info/main-form/main-form-base.vue
+81
-21
main-form-service.ts
app_web/src/widgets/jobs-info/main-form/main-form-service.ts
+21
-1
main-grid-base.vue
app_web/src/widgets/jobs-info/main-grid/main-grid-base.vue
+2
-2
main-grid-model.ts
app_web/src/widgets/jobs-info/main-grid/main-grid-model.ts
+1
-0
main-grid-service.ts
app_web/src/widgets/jobs-info/main-grid/main-grid-service.ts
+40
-4
default-searchform-base.vue
...s/jobs-log/default-searchform/default-searchform-base.vue
+3
-0
default-searchform-service.ts
...jobs-log/default-searchform/default-searchform-service.ts
+21
-1
main-form-base.vue
app_web/src/widgets/jobs-log/main-form/main-form-base.vue
+69
-15
main-form-service.ts
app_web/src/widgets/jobs-log/main-form/main-form-service.ts
+21
-1
main-grid-base.vue
app_web/src/widgets/jobs-log/main-grid/main-grid-base.vue
+2
-2
main-grid-model.ts
app_web/src/widgets/jobs-log/main-grid/main-grid-model.ts
+1
-0
main-grid-service.ts
app_web/src/widgets/jobs-log/main-grid/main-grid-service.ts
+40
-4
default-searchform-base.vue
...s-registry/default-searchform/default-searchform-base.vue
+2
-0
default-searchform-service.ts
...registry/default-searchform/default-searchform-service.ts
+21
-1
main-form-base.vue
...eb/src/widgets/jobs-registry/main-form/main-form-base.vue
+54
-8
main-form-service.ts
.../src/widgets/jobs-registry/main-form/main-form-service.ts
+21
-1
main-grid-base.vue
...eb/src/widgets/jobs-registry/main-grid/main-grid-base.vue
+2
-2
main-grid-model.ts
...eb/src/widgets/jobs-registry/main-grid/main-grid-model.ts
+1
-0
main-grid-service.ts
.../src/widgets/jobs-registry/main-grid/main-grid-service.ts
+40
-4
yarn.lock
app_web/yarn.lock
+5
-0
application-web-prod.yml
...ztask-app-web/src/main/resources/application-web-prod.yml
+9
-9
application.yml
...sk-app/ibztask-app-web/src/main/resources/application.yml
+1
-1
application.yml
ibztask-boot/src/main/resources/application.yml
+1
-1
JobsInfoServiceImpl.java
...n/ibizlab/core/task/service/impl/JobsInfoServiceImpl.java
+1
-1
pom.xml
ibztask-dependencies/pom.xml
+11
-0
JobsInfoResource.java
...i/src/main/java/cn/ibizlab/api/rest/JobsInfoResource.java
+3
-3
application.yml
...r/ibztask-provider-api/src/main/resources/application.yml
+1
-1
IBZOUFeignClient.java
...rc/main/java/cn/ibizlab/util/client/IBZOUFeignClient.java
+1
-1
IBZUAAFeignClient.java
...c/main/java/cn/ibizlab/util/client/IBZUAAFeignClient.java
+1
-1
IBZWFFeignClient.java
...rc/main/java/cn/ibizlab/util/client/IBZWFFeignClient.java
+1
-1
LiquibaseProp.java
...l/src/main/java/cn/ibizlab/util/domain/LiquibaseProp.java
+1
-1
AuthenticationUser.java
...ain/java/cn/ibizlab/util/security/AuthenticationUser.java
+28
-0
application-eureka.yml
ibztask-util/src/main/resources/application-eureka.yml
+14
-0
application-nacos.yml
ibztask-util/src/main/resources/application-nacos.yml
+12
-0
application-sys.yml
ibztask-util/src/main/resources/application-sys.yml
+1
-5
未找到文件。
app_web/CHANGELOG.md
浏览文件 @
217474d5
## v7.0.0-alpha.14 [2020-7-18]
### Bug修复
修复表格列千分位格式化
修复标签值格式化
修复表格转化数据错误问题
修复嵌套关系无数据时设置数据为空数组
### 功能新增及优化
#### 模板
新增编辑器插件
新增数据服务增加临时模式判断
新增支持实体行为定义检查方法
新增实体行为执行前、后逻辑
新增操作栏主状态无权限模式
优化开发环境错误提示友好性
优化应用菜单多层嵌套问题
#### 基础文件
优化popover组件
实体数据服务基类增加saveBatch方法
优化应用菜单多层嵌套问题
## v7.0.0-alpha.13 [2020-7-12]
### Bug修复
修复表格设置更新默认值不生效
修复行编辑中文本字段修改数据保存无法生效
修复行编辑时的错误提示
修复表格开关部件保存异常问题
修复表单可以修改数据主键问题
修复表格操作列问题
#### 基础文件
优化关系界面逻辑
## v7.0.0-alpha.12 [2020-7-2]
### Bug修复
...
...
@@ -14,6 +72,14 @@
修复多行输入十行 高度问题
修复调整实体处理逻辑(参数name转化为codeName)
修复表单项更新值规则校验
修复单位部门选择器禁用功能
修复修复去掉某个子菜单后,主菜单不显示
### 功能新增及优化
#### 模板
...
...
@@ -24,14 +90,28 @@
新增状态向导面板(658)
优化门户操作栏
新增门户操作栏图标(654)
新增首页空白模式支持
新增表格支持列拖动
优化应用级数据状态同步功能
新增主状态操作标识权限逻辑
新增工具栏、表格操作列、表单分组主状态操作标识判断
优化应用级数据状态同步功能(654)
优化应用国际化部分
#### 基础文件
新增修改密码功能(654)
优化无权限错误信息友好提示
优化应用国际化部分
## v7.0.0-alpha.11 [2020-6-21]
### Bug修复
...
...
app_web/package.json
浏览文件 @
217474d5
...
...
@@ -20,6 +20,7 @@
"@fullcalendar/vue"
:
"^4.4.0"
,
"vuedraggable"
:
"^2.23.2"
,
"async-validator"
:
"^3.3.0"
,
"@popperjs/core"
:
"^2.4.3"
,
"axios"
:
"^0.19.1"
,
"core-js"
:
"^3.4.4"
,
"echarts"
:
"^4.6.0"
,
...
...
app_web/src/app-register.ts
浏览文件 @
217474d5
...
...
@@ -78,6 +78,7 @@ import AppOrgSelect from './components/app-org-select/app-org-select.vue'
import
AppDepartmentSelect
from
'./components/app-department-select/app-department-select.vue'
import
AppGroupSelect
from
'./components/app-group-select/app-group-select.vue'
import
UpdatePwd
from
'./components/app-update-password/app-update-password.vue'
import
AppMenuItem
from
'./components/app-menu-item/app-menu-item.vue'
// 全局挂载UI实体服务注册中心
window
[
'uiServiceRegister'
]
=
uiServiceRegister
;
// 全局挂载实体权限服务注册中心
...
...
@@ -168,5 +169,6 @@ export const AppComponents = {
v
.
component
(
'app-transfer'
,
AppTransfer
);
v
.
component
(
'context-menu-drag'
,
ContextMenuDrag
);
v
.
component
(
'app-update-password'
,
UpdatePwd
);
v
.
component
(
'app-menu-item'
,
AppMenuItem
);
},
};
\ No newline at end of file
app_web/src/components/app-actionbar/app-actionbar.vue
浏览文件 @
217474d5
<
template
>
<div
class=
"app-actionbar"
>
<div
class=
"app-actionbar-item"
v-for=
"(item,index) in items"
:key=
"index"
>
<Badge
v-if=
"item.counterService&&item.counterService.counterData"
:count=
"item.counterService.counterData[item.counterId]"
type=
"primary"
>
<i-button
@
click=
"handleClick(item.viewlogicname)"
><i
v-if=
"item.icon"
style=
"margin-right: 5px;"
:class=
"item.icon"
></i>
{{
item
.
actionName
}}
</i-button>
<Badge
v-if=
"item.counterService&&item.counterService.counterData"
v-show=
"item.visabled"
:count=
"item.counterService.counterData[item.counterId]"
type=
"primary"
>
<i-button
:style=
"
{'pointer-events':item.disabled?'none':'auto'}"
@click="handleClick(item.viewlogicname)">
<i
v-if=
"item.icon"
style=
"margin-right: 5px;"
:class=
"item.icon"
></i>
{{
item
.
actionName
}}
</i-button>
</Badge>
<i-button
v-else
@
click=
"handleClick(item.viewlogicname)"
>
{{
item
.
actionName
}}
</i-button>
<i-button
v-
show=
"item.visabled"
:style=
"
{'pointer-events':item.disabled?'none':'auto'}" v-
else @click="handleClick(item.viewlogicname)">
{{
item
.
actionName
}}
</i-button>
</div>
</div>
</
template
>
<
script
lang=
"ts"
>
import
{
Vue
,
Component
,
Prop
,
Model
,
Emit
}
from
"vue-property-decorator"
;
import
{
Subject
}
from
"rxjs"
;
import
{
Vue
,
Component
,
Prop
,
Model
,
Emit
,
Inject
,
Watch
}
from
"vue-property-decorator"
;
import
{
Subject
,
Subscription
}
from
"rxjs"
;
@
Component
({})
export
default
class
AppActionBar
extends
Vue
{
...
...
@@ -24,6 +24,49 @@ export default class AppActionBar extends Vue {
*/
@
Prop
()
public
items
!
:
any
;
/**
* 注入的UI服务
*
* @type {*}
* @memberof AppActionBar
*/
@
Prop
()
public
uiService
!
:
any
;
/**
* 视图通讯对象
*
* @type {Subject<ViewState>}
* @memberof AppActionBar
*/
@
Prop
()
public
viewState
!
:
Subject
<
ViewState
>
;
/**
* 视图状态事件
*
* @public
* @type {(Subscription | undefined)}
* @memberof ActionlinetestBase
*/
public
viewStateEvent
:
Subscription
|
undefined
;
/**
* 组件初始化
*
* @memberof AppActionBar
*/
public
created
(){
if
(
this
.
viewState
)
{
this
.
viewStateEvent
=
this
.
viewState
.
subscribe
(({
tag
,
action
,
data
})
=>
{
if
(
!
Object
.
is
(
tag
,
"app-actionbar"
))
{
return
;
}
if
(
Object
.
is
(
action
,
'loadmodel'
)){
this
.
calcActionItemAuthState
(
data
,
this
.
items
,
this
.
uiService
);
}
});
}
}
/**
* 触发界面行为
*
...
...
@@ -33,6 +76,52 @@ export default class AppActionBar extends Vue {
this
.
$emit
(
'itemClick'
,
$event
);
}
/**
* 计算界面行为项权限状态
*
* @param {*} [data] 传入数据
* @param {*} [ActionModel] 界面行为模型
* @param {*} [UIService] 界面行为服务
* @memberof AppActionBar
*/
public
calcActionItemAuthState
(
data
:
any
,
ActionModel
:
any
,
UIService
:
any
){
for
(
const
key
in
ActionModel
)
{
if
(
!
ActionModel
.
hasOwnProperty
(
key
))
{
return
;
}
const
_item
=
ActionModel
[
key
];
if
(
_item
&&
_item
[
'dataaccaction'
]
&&
UIService
&&
data
&&
Object
.
keys
(
data
).
length
>
0
){
let
dataActionResult
:
any
=
UIService
.
getAllOPPrivs
(
data
)[
_item
[
'dataaccaction'
]];
// 无权限:0;有权限:1
if
(
dataActionResult
===
0
){
// 禁用:1;隐藏:2;隐藏且默认隐藏:6
if
(
_item
.
noprivdisplaymode
===
1
){
_item
.
disabled
=
true
;
}
if
((
_item
.
noprivdisplaymode
===
2
)
||
(
_item
.
noprivdisplaymode
===
6
)){
_item
.
visabled
=
false
;
}
else
{
_item
.
visabled
=
true
;
}
}
if
(
dataActionResult
===
1
){
_item
.
visabled
=
true
;
_item
.
disabled
=
false
;
}
}
}
}
/**
* 组件销毁
*
* @memberof AppActionBar
*/
public
destory
(){
if
(
this
.
viewStateEvent
)
{
this
.
viewStateEvent
.
unsubscribe
();
}
}
}
</
script
>
...
...
app_web/src/components/app-breadcrumb/app-breadcrumb.vue
浏览文件 @
217474d5
...
...
@@ -161,6 +161,7 @@ export default class Breadcrumb extends Vue {
if
(
item
&&
item
.
meta
&&
item
.
meta
.
viewType
&&
Object
.
is
(
item
.
meta
.
viewType
,
"APPINDEX"
)){
let
path
:
string
|
null
=
window
.
sessionStorage
.
getItem
(
Environment
.
AppName
);
if
(
path
)
{
this
.
$store
.
commit
(
"removeAllPage"
);
this
.
$router
.
push
({
path
:
path
});
}
else
{
this
.
$router
.
push
(
"/"
);
...
...
app_web/src/components/app-form-druipart/app-form-druipart.vue
浏览文件 @
217474d5
...
...
@@ -271,6 +271,7 @@ export default class AppFormDRUIPart extends Vue {
//设置顶层视图唯一标识
Object
.
assign
(
tempContext
,
this
.
context
);
Object
.
assign
(
tempContext
,{
srfparentdename
:
this
.
parentName
,
srfparentkey
:
_paramitem
});
Object
.
assign
(
tempParam
,{
srfparentdename
:
this
.
parentName
,
srfparentkey
:
_paramitem
});
// 设置局部上下文
if
(
this
.
localContext
&&
Object
.
keys
(
this
.
localContext
).
length
>
0
){
let
_context
:
any
=
this
.
$util
.
computedNavData
(
formData
,
tempContext
,
this
.
viewparams
,
this
.
localContext
);
...
...
@@ -292,9 +293,9 @@ export default class AppFormDRUIPart extends Vue {
}
}
if
(
!
this
.
isForbidLoad
){
this
.
$nextTick
(()
=>
{
setTimeout
(()
=>
{
this
.
formDruipart
.
next
({
action
:
'load'
,
data
:{
srfparentdename
:
this
.
parentName
,
srfparentkey
:
_paramitem
}});
});
}
,
0
);
}
}
...
...
app_web/src/components/app-form-group/app-form-group.vue
浏览文件 @
217474d5
...
...
@@ -165,7 +165,7 @@ export default class AppFormGroup extends Vue {
if
(
_item
&&
_item
[
'dataaccaction'
]
&&
UIService
&&
data
&&
Object
.
keys
(
data
).
length
>
0
){
let
dataActionResult
:
any
=
UIService
.
getAllOPPrivs
(
data
)[
_item
[
'dataaccaction'
]];
// 无权限:0;有权限:1
if
(
!
dataActionResult
){
if
(
dataActionResult
===
0
){
// 禁用:1;隐藏:2;隐藏且默认隐藏:6
if
(
_item
.
noprivdisplaymode
===
1
){
_item
.
disabled
=
true
;
...
...
@@ -175,7 +175,8 @@ export default class AppFormGroup extends Vue {
}
else
{
_item
.
visabled
=
true
;
}
}
else
{
}
if
(
dataActionResult
===
1
){
_item
.
visabled
=
true
;
_item
.
disabled
=
false
;
}
...
...
app_web/src/components/app-menu-item/app-menu-item.vue
0 → 100644
浏览文件 @
217474d5
<
template
>
<div
class=
"app-menu-item"
>
<template
v-for=
"item in menus"
>
<template
v-if=
"item.items && Array.isArray(item.items) && item.items.length > 0"
>
<el-submenu
v-show=
"!item.hidden"
:index=
"item.name"
:popper-class=
"popperClass"
:key=
"item.id"
>
<template
slot=
'title'
>
<template
v-if=
"item.icon && item.icon != ''"
>
<img
:src=
"item.icon"
class=
'app-menu-icon'
/>
</
template
>
<
template
v-else-if=
"item.iconcls && item.iconcls != ''"
>
<i
:class=
"[item.iconcls, 'app-menu-icon']"
></i>
</
template
>
<
template
v-else
>
<i
v-if=
"isFirst"
class=
'fa fa-cogs app-menu-icon'
></i>
</
template
>
<span
class=
'text'
:title=
"$t(`app.menus.${ctrlName}.${item.name}`)"
>
{{$t(`app.menus.${ctrlName}.${item.name}`)}}
</span>
</template>
<app-menu-item
:menus=
"item.items"
:ctrlName=
"ctrlName"
:isFirst=
"false"
:counterdata=
"counterdata"
:popperclass=
"popperClass"
></app-menu-item>
</el-submenu>
</template>
<
template
v-else
>
<template
v-if=
"item.type =='MENUITEM'"
>
<el-menu-item
v-show=
"!item.hidden"
:index=
"item.name"
:key=
"item.id"
>
<template
v-if=
"item.icon && item.icon != ''"
>
<img
:src=
"item.icon"
class=
'app-menu-icon'
/>
</
template
>
<
template
v-else-if=
"item.iconcls && item.iconcls != ''"
>
<i
:class=
"[item.iconcls, 'app-menu-icon']"
></i>
</
template
>
<
template
v-else
>
<i
v-if=
"isFirst"
class=
'fa fa-cogs app-menu-icon'
></i>
</
template
>
<
template
slot=
"title"
>
<span
class=
"text"
:title=
"$t(`app.menus.$
{ctrlName}.${item.name}`)">
{{
$t
(
`app.menus.${ctrlName
}
.${item.name
}
`
)
}}
<
/span
>
<
template
v
-
if
=
"counterdata && counterdata[item.counterid] && counterdata[item.counterid] > 0"
>
<
span
class
=
"pull-right"
>
<
badge
:
count
=
"counterdata[item.counterid]"
:
overflow
-
count
=
"9999"
><
/badge
>
<
/span
>
<
/template
>
<
/template
>
<
/el-menu-item
>
<
/template
>
<
template
v
-
if
=
"item.type =='SEPERATOR'"
>
<
divider
:
key
=
"item.id"
/>
<
/template
>
<
/template
>
<
/template
>
<
/div>
<
/template
>
<
script
lang
=
"ts"
>
import
{
Component
,
Vue
,
Prop
}
from
'vue-property-decorator'
;
@
Component
({
}
)
export
default
class
AppMenuItem
extends
Vue
{
/**
* 菜单数据
*
* @type {*
}
* @memberof AppMenuItem
*/
@
Prop
(
{
default
:
[]
}
)
public
menus
!
:
any
;
/**
* 部件名称
*
* @type {*
}
* @memberof AppMenuItem
*/
@
Prop
()
public
ctrlName
!
:
string
;
/**
* 计数器数据
*
* @type {*
}
* @memberof AppMenuItem
*/
@
Prop
()
public
counterdata
!
:
any
;
/**
* 提示框主题样式
*
* @type {*
}
* @memberof AppMenuItem
*/
@
Prop
()
public
popperClass
!
:
any
;
/**
* 是否是一级菜单
*
* @type {*
}
* @memberof AppMenuItem
*/
@
Prop
()
public
isFirst
!
:
boolean
;
}
<
/script>
\ No newline at end of file
app_web/src/components/app-picker/app-picker.vue
浏览文件 @
217474d5
...
...
@@ -242,7 +242,7 @@ export default class AppPicker extends Vue {
* @param {*} oldVal
* @memberof AppPicker
*/
@
Watch
(
'value'
)
@
Watch
(
'value'
,{
immediate
:
true
}
)
public
onValueChange
(
newVal
:
any
,
oldVal
:
any
)
{
this
.
curvalue
=
newVal
;
if
(
Object
.
is
(
this
.
editortype
,
'dropdown'
)
&&
this
.
valueitem
)
{
...
...
app_web/src/components/app-span/app-span.vue
浏览文件 @
217474d5
...
...
@@ -6,7 +6,7 @@
<
script
lang=
"ts"
>
import
{
Vue
,
Component
,
Prop
,
Watch
,
Model
}
from
'vue-property-decorator'
;
import
moment
from
"moment"
;
@
Component
({})
export
default
class
AppSpan
extends
Vue
{
...
...
@@ -18,6 +18,38 @@ export default class AppSpan extends Vue {
*/
@
Prop
()
public
value
?:
any
;
/**
* 数据类型
*
* @type {string}
* @memberof AppSpan
*/
@
Prop
()
public
dataType
?:
string
;
/**
* 单位名称
*
* @type {string}
* @memberof AppSpan
*/
@
Prop
({
default
:
''
})
public
unitName
?:
string
;
/**
* 精度
*
* @type {number}
* @memberof AppSpan
*/
@
Prop
({
default
:
'2'
})
public
precision
?:
number
;
/**
* 日期值格式化
*
* @type {string}
* @memberof AppSpan
*/
@
Prop
()
public
valueFormat
?:
string
;
/**
* 当前表单项名称
*
...
...
@@ -158,12 +190,52 @@ export default class AppSpan extends Vue {
}
else
{
if
(
this
.
$util
.
isEmpty
(
this
.
value
)){
this
.
text
=
''
;
}
else
if
(
this
.
dataType
){
this
.
dataFormat
();
}
else
{
this
.
text
=
this
.
value
;
}
}
}
/**
* 数据格式化
*
* @memberof AppSpan
*/
public
dataFormat
(){
if
(
this
.
valueFormat
){
this
.
dateFormat
()
;
return
;
}
if
(
Object
.
is
(
this
.
dataType
,
"CURRENCY"
)){
let
number
:
any
=
Number
(
this
.
value
);
this
.
text
=
Number
(
number
.
toFixed
(
this
.
precision
)).
toLocaleString
(
'en-US'
)
+
' '
+
this
.
unitName
;
}
else
if
(
Object
.
is
(
this
.
dataType
,
"FLOAT"
)
||
Object
.
is
(
this
.
dataType
,
"DECIMAL"
)){
let
number
:
any
=
Number
(
this
.
value
);
this
.
text
=
number
.
toFixed
(
this
.
precision
);
}
else
{
this
.
text
=
this
.
value
;
}
}
/**
* 日期格式化
*
* @memberof AppSpan
*/
public
dateFormat
(){
if
(
this
.
valueFormat
){
if
(
this
.
valueFormat
.
indexOf
(
'%1$t'
)
!==
-
1
){
this
.
text
=
moment
(
this
.
data
).
format
(
"YYYY-MM-DD HH:mm:ss"
);
}
else
if
(
this
.
valueFormat
.
indexOf
(
'%1$s'
)
==
-
1
){
this
.
text
=
moment
(
this
.
data
).
format
(
this
.
valueFormat
);
}
else
{
this
.
text
=
this
.
value
;
}
}
}
}
</
script
>
...
...
app_web/src/components/input-box/input-box.vue
浏览文件 @
217474d5
...
...
@@ -7,8 +7,7 @@
:precision=
"precision"
v-model=
"CurrentVal"
:disabled=
"disabled ? true : false"
:formatter=
"formatter"
:parser=
"parser"
:active-change=
"false"
></InputNumber>
<i-input
v-else
:placeholder=
"placeholder"
...
...
@@ -188,29 +187,7 @@ export default class InputBox extends Vue {
}
}
/**
* 指定输入框展示值的格式
*/
public
formatter
(
value
:
any
){
if
(
this
.
precision
===
0
)
return
this
.
CurrentVal
;
if
(
value
.
indexOf
(
'.'
)
!==-
1
){
let
arr
:
Array
<
any
>
=
value
.
split
(
'.'
);
if
(
arr
[
1
]
===
'00'
){
return
arr
[
0
];
}
if
(
parseInt
(
arr
[
1
])
%
10
===
0
){
return
arr
[
0
]
+
'.'
+
parseInt
(
arr
[
1
])
/
10
;
}
}
return
value
;
}
/**
* 指定从 formatter 里转换回数字的方式
*/
public
parser
(
value
:
any
){
return
value
;
}
}
</
script
>
...
...
app_web/src/engine/view/view-engine.ts
浏览文件 @
217474d5
...
...
@@ -193,7 +193,7 @@ export default class ViewEngine {
if
(
_item
&&
_item
[
'dataaccaction'
]
&&
_this
.
view
.
appUIService
&&
data
&&
Object
.
keys
(
data
).
length
>
0
){
let
dataActionResult
:
any
=
_this
.
view
.
appUIService
.
getAllOPPrivs
(
data
)[
_item
[
'dataaccaction'
]];
// 无权限:0;有权限:1
if
(
!
dataActionResult
){
if
(
dataActionResult
===
0
){
// 禁用:1;隐藏:2;隐藏且默认隐藏:6
if
(
_item
.
noprivdisplaymode
===
1
){
_this
.
view
.
toolBarModels
[
key
].
disabled
=
true
;
...
...
@@ -203,8 +203,10 @@ export default class ViewEngine {
}
else
{
_this
.
view
.
toolBarModels
[
key
].
visabled
=
true
;
}
}
else
{
}
if
(
dataActionResult
===
1
){
_this
.
view
.
toolBarModels
[
key
].
visabled
=
true
;
_this
.
view
.
toolBarModels
[
key
].
disabled
=
false
;
}
}
}
...
...
app_web/src/pages/task/jobs-info-edit-view/jobs-info-edit-view-base.vue
浏览文件 @
217474d5
...
...
@@ -83,7 +83,7 @@ export default class JobsInfoEditViewBase extends Vue {
public
appEntityService
:
JobsInfoService
=
new
JobsInfoService
;
/**
* 实体
权限
服务对象
* 实体
UI
服务对象
*
* @type JobsInfoUIService
* @memberof JobsInfoEditViewBase
...
...
app_web/src/pages/task/jobs-info-grid-view/jobs-info-grid-view-base.vue
浏览文件 @
217474d5
...
...
@@ -144,7 +144,7 @@ export default class JobsInfoGridViewBase extends Vue {
public
appEntityService
:
JobsInfoService
=
new
JobsInfoService
;
/**
* 实体
权限
服务对象
* 实体
UI
服务对象
*
* @type JobsInfoUIService
* @memberof JobsInfoGridViewBase
...
...
app_web/src/pages/task/jobs-log-edit-view/jobs-log-edit-view-base.vue
浏览文件 @
217474d5
...
...
@@ -67,7 +67,7 @@ export default class JobsLogEditViewBase extends Vue {
public
appEntityService
:
JobsLogService
=
new
JobsLogService
;
/**
* 实体
权限
服务对象
* 实体
UI
服务对象
*
* @type JobsLogUIService
* @memberof JobsLogEditViewBase
...
...
app_web/src/pages/task/jobs-log-grid-view/jobs-log-grid-view-base.vue
浏览文件 @
217474d5
...
...
@@ -93,7 +93,7 @@ export default class JobsLogGridViewBase extends Vue {
public
appEntityService
:
JobsLogService
=
new
JobsLogService
;
/**
* 实体
权限
服务对象
* 实体
UI
服务对象
*
* @type JobsLogUIService
* @memberof JobsLogGridViewBase
...
...
app_web/src/pages/task/jobs-registry-edit-view/jobs-registry-edit-view-base.vue
浏览文件 @
217474d5
...
...
@@ -83,7 +83,7 @@ export default class JobsRegistryEditViewBase extends Vue {
public
appEntityService
:
JobsRegistryService
=
new
JobsRegistryService
;
/**
* 实体
权限
服务对象
* 实体
UI
服务对象
*
* @type JobsRegistryUIService
* @memberof JobsRegistryEditViewBase
...
...
app_web/src/pages/task/jobs-registry-grid-view/jobs-registry-grid-view-base.vue
浏览文件 @
217474d5
...
...
@@ -123,7 +123,7 @@ export default class JobsRegistryGridViewBase extends Vue {
public
appEntityService
:
JobsRegistryService
=
new
JobsRegistryService
;
/**
* 实体
权限
服务对象
* 实体
UI
服务对象
*
* @type JobsRegistryUIService
* @memberof JobsRegistryGridViewBase
...
...
app_web/src/service/entity-service.ts
浏览文件 @
217474d5
...
...
@@ -294,7 +294,8 @@ export default class EntityService {
let
result
:
any
=
JSON
.
parse
(
this
.
tempStorage
.
getItem
(
context
.
srfsessionkey
+
'_'
+
this
.
APPDENAME
)
as
any
);
if
(
result
){
let
tempResult
:
any
=
result
.
filter
((
item
:
any
)
=>
{
return
!
(
Object
.
is
(
item
[
this
.
APPDEKEY
],
data
[
this
.
APPDEKEY
])
&&
Object
.
is
(
item
[
this
.
APPDETEXT
],
data
[
this
.
APPDETEXT
]));
// return !( Object.is(item[this.APPDEKEY],data[this.APPDEKEY]) && Object.is(item[this.APPDETEXT],data[this.APPDETEXT]));
return
!
Object
.
is
(
item
[
this
.
APPDEKEY
],
data
[
this
.
APPDEKEY
]);
})
this
.
tempStorage
.
setItem
(
context
.
srfsessionkey
+
'_'
+
this
.
APPDENAME
,
JSON
.
stringify
(
tempResult
));
return
{
"status"
:
200
,
"data"
:
data
};
...
...
@@ -596,6 +597,19 @@ export default class EntityService {
return
Http
.
getInstance
().
post
(
`/
${
this
.
APPDENAME
}
/batch`
,
data
,
isloading
);
}
/**
* saveBatch接口方法
*
* @param {*} [context={}]
* @param {*} [data]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof EntityService
*/
public
async
saveBatch
(
context
:
any
=
{},
data
:
any
,
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/
${
this
.
APPDENAME
}
/savebatch`
,
data
,
isloading
);
}
/**
* updateBatch接口方法
*
...
...
app_web/src/service/jobs-info/jobs-info-service-base.ts
浏览文件 @
217474d5
...
...
@@ -48,7 +48,9 @@ export default class JobsInfoServiceBase extends EntityService {
* @memberof JobsInfoServiceBase
*/
public
async
Select
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
get
(
`/jobsinfos/
${
context
.
jobsinfo
}
/select`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobsinfos/
${
context
.
jobsinfo
}
/select`
,
isloading
);
return
res
;
}
/**
...
...
@@ -71,6 +73,7 @@ export default class JobsInfoServiceBase extends EntityService {
}
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobsinfos`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -87,6 +90,7 @@ export default class JobsInfoServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
put
(
`/jobsinfos/
${
context
.
jobsinfo
}
`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -100,7 +104,8 @@ export default class JobsInfoServiceBase extends EntityService {
* @memberof JobsInfoServiceBase
*/
public
async
Remove
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
delete
(
`/jobsinfos/
${
context
.
jobsinfo
}
`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
delete
(
`/jobsinfos/
${
context
.
jobsinfo
}
`
,
isloading
);
return
res
;
}
/**
...
...
@@ -114,6 +119,7 @@ export default class JobsInfoServiceBase extends EntityService {
*/
public
async
Get
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobsinfos/
${
context
.
jobsinfo
}
`
,
isloading
);
return
res
;
}
...
...
@@ -129,6 +135,7 @@ export default class JobsInfoServiceBase extends EntityService {
public
async
GetDraft
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobsinfos/getdraft`
,
isloading
);
res
.
data
.
jobsinfo
=
data
.
jobsinfo
;
return
res
;
}
...
...
@@ -142,7 +149,8 @@ export default class JobsInfoServiceBase extends EntityService {
* @memberof JobsInfoServiceBase
*/
public
async
CheckKey
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/checkkey`
,
data
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/checkkey`
,
data
,
isloading
);
return
res
;
}
/**
...
...
@@ -155,7 +163,8 @@ export default class JobsInfoServiceBase extends EntityService {
* @memberof JobsInfoServiceBase
*/
public
async
Execute
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/execute`
,
data
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/execute`
,
data
,
isloading
);
return
res
;
}
/**
...
...
@@ -171,6 +180,7 @@ export default class JobsInfoServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/save`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -184,7 +194,8 @@ export default class JobsInfoServiceBase extends EntityService {
* @memberof JobsInfoServiceBase
*/
public
async
Start
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/start`
,
data
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/start`
,
data
,
isloading
);
return
res
;
}
/**
...
...
@@ -197,7 +208,8 @@ export default class JobsInfoServiceBase extends EntityService {
* @memberof JobsInfoServiceBase
*/
public
async
Stop
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/stop`
,
data
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
post
(
`/jobsinfos/
${
context
.
jobsinfo
}
/stop`
,
data
,
isloading
);
return
res
;
}
/**
...
...
@@ -211,6 +223,7 @@ export default class JobsInfoServiceBase extends EntityService {
*/
public
async
FetchDefault
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
tempData
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
return
Http
.
getInstance
().
get
(
`/jobsinfos/fetchdefault`
,
tempData
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobsinfos/fetchdefault`
,
tempData
,
isloading
);
return
res
;
}
}
\ No newline at end of file
app_web/src/service/jobs-lock/jobs-lock-service-base.ts
浏览文件 @
217474d5
...
...
@@ -48,7 +48,9 @@ export default class JobsLockServiceBase extends EntityService {
* @memberof JobsLockServiceBase
*/
public
async
Select
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
get
(
`/jobslocks/
${
context
.
jobslock
}
/select`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobslocks/
${
context
.
jobslock
}
/select`
,
isloading
);
return
res
;
}
/**
...
...
@@ -71,6 +73,7 @@ export default class JobsLockServiceBase extends EntityService {
}
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobslocks`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -87,6 +90,7 @@ export default class JobsLockServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
put
(
`/jobslocks/
${
context
.
jobslock
}
`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -100,7 +104,8 @@ export default class JobsLockServiceBase extends EntityService {
* @memberof JobsLockServiceBase
*/
public
async
Remove
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
delete
(
`/jobslocks/
${
context
.
jobslock
}
`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
delete
(
`/jobslocks/
${
context
.
jobslock
}
`
,
isloading
);
return
res
;
}
/**
...
...
@@ -114,6 +119,7 @@ export default class JobsLockServiceBase extends EntityService {
*/
public
async
Get
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobslocks/
${
context
.
jobslock
}
`
,
isloading
);
return
res
;
}
...
...
@@ -129,6 +135,7 @@ export default class JobsLockServiceBase extends EntityService {
public
async
GetDraft
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobslocks/getdraft`
,
isloading
);
res
.
data
.
jobslock
=
data
.
jobslock
;
return
res
;
}
...
...
@@ -142,7 +149,8 @@ export default class JobsLockServiceBase extends EntityService {
* @memberof JobsLockServiceBase
*/
public
async
CheckKey
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/jobslocks/
${
context
.
jobslock
}
/checkkey`
,
data
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
post
(
`/jobslocks/
${
context
.
jobslock
}
/checkkey`
,
data
,
isloading
);
return
res
;
}
/**
...
...
@@ -158,6 +166,7 @@ export default class JobsLockServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobslocks/
${
context
.
jobslock
}
/save`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -172,6 +181,7 @@ export default class JobsLockServiceBase extends EntityService {
*/
public
async
FetchDefault
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
tempData
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
return
Http
.
getInstance
().
get
(
`/jobslocks/fetchdefault`
,
tempData
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobslocks/fetchdefault`
,
tempData
,
isloading
);
return
res
;
}
}
\ No newline at end of file
app_web/src/service/jobs-log/jobs-log-service-base.ts
浏览文件 @
217474d5
...
...
@@ -48,7 +48,9 @@ export default class JobsLogServiceBase extends EntityService {
* @memberof JobsLogServiceBase
*/
public
async
Select
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
get
(
`/jobslogs/
${
context
.
jobslog
}
/select`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobslogs/
${
context
.
jobslog
}
/select`
,
isloading
);
return
res
;
}
/**
...
...
@@ -71,6 +73,7 @@ export default class JobsLogServiceBase extends EntityService {
}
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobslogs`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -87,6 +90,7 @@ export default class JobsLogServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
put
(
`/jobslogs/
${
context
.
jobslog
}
`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -100,7 +104,8 @@ export default class JobsLogServiceBase extends EntityService {
* @memberof JobsLogServiceBase
*/
public
async
Remove
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
delete
(
`/jobslogs/
${
context
.
jobslog
}
`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
delete
(
`/jobslogs/
${
context
.
jobslog
}
`
,
isloading
);
return
res
;
}
/**
...
...
@@ -114,6 +119,7 @@ export default class JobsLogServiceBase extends EntityService {
*/
public
async
Get
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobslogs/
${
context
.
jobslog
}
`
,
isloading
);
return
res
;
}
...
...
@@ -129,6 +135,7 @@ export default class JobsLogServiceBase extends EntityService {
public
async
GetDraft
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobslogs/getdraft`
,
isloading
);
res
.
data
.
jobslog
=
data
.
jobslog
;
return
res
;
}
...
...
@@ -142,7 +149,8 @@ export default class JobsLogServiceBase extends EntityService {
* @memberof JobsLogServiceBase
*/
public
async
CheckKey
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/jobslogs/
${
context
.
jobslog
}
/checkkey`
,
data
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
post
(
`/jobslogs/
${
context
.
jobslog
}
/checkkey`
,
data
,
isloading
);
return
res
;
}
/**
...
...
@@ -158,6 +166,7 @@ export default class JobsLogServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobslogs/
${
context
.
jobslog
}
/save`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -172,6 +181,7 @@ export default class JobsLogServiceBase extends EntityService {
*/
public
async
FetchDefault
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
tempData
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
return
Http
.
getInstance
().
get
(
`/jobslogs/fetchdefault`
,
tempData
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobslogs/fetchdefault`
,
tempData
,
isloading
);
return
res
;
}
}
\ No newline at end of file
app_web/src/service/jobs-registry/jobs-registry-service-base.ts
浏览文件 @
217474d5
...
...
@@ -48,7 +48,9 @@ export default class JobsRegistryServiceBase extends EntityService {
* @memberof JobsRegistryServiceBase
*/
public
async
Select
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
get
(
`/jobsregistries/
${
context
.
jobsregistry
}
/select`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobsregistries/
${
context
.
jobsregistry
}
/select`
,
isloading
);
return
res
;
}
/**
...
...
@@ -71,6 +73,7 @@ export default class JobsRegistryServiceBase extends EntityService {
}
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobsregistries`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -87,6 +90,7 @@ export default class JobsRegistryServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
put
(
`/jobsregistries/
${
context
.
jobsregistry
}
`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -100,7 +104,8 @@ export default class JobsRegistryServiceBase extends EntityService {
* @memberof JobsRegistryServiceBase
*/
public
async
Remove
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
delete
(
`/jobsregistries/
${
context
.
jobsregistry
}
`
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
delete
(
`/jobsregistries/
${
context
.
jobsregistry
}
`
,
isloading
);
return
res
;
}
/**
...
...
@@ -114,6 +119,7 @@ export default class JobsRegistryServiceBase extends EntityService {
*/
public
async
Get
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobsregistries/
${
context
.
jobsregistry
}
`
,
isloading
);
return
res
;
}
...
...
@@ -129,6 +135,7 @@ export default class JobsRegistryServiceBase extends EntityService {
public
async
GetDraft
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
res
:
any
=
await
Http
.
getInstance
().
get
(
`/jobsregistries/getdraft`
,
isloading
);
res
.
data
.
jobsregistry
=
data
.
jobsregistry
;
return
res
;
}
...
...
@@ -142,7 +149,8 @@ export default class JobsRegistryServiceBase extends EntityService {
* @memberof JobsRegistryServiceBase
*/
public
async
CheckKey
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
return
Http
.
getInstance
().
post
(
`/jobsregistries/
${
context
.
jobsregistry
}
/checkkey`
,
data
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
post
(
`/jobsregistries/
${
context
.
jobsregistry
}
/checkkey`
,
data
,
isloading
);
return
res
;
}
/**
...
...
@@ -158,6 +166,7 @@ export default class JobsRegistryServiceBase extends EntityService {
let
masterData
:
any
=
{};
Object
.
assign
(
data
,
masterData
);
let
res
:
any
=
await
Http
.
getInstance
().
post
(
`/jobsregistries/
${
context
.
jobsregistry
}
/save`
,
data
,
isloading
);
return
res
;
}
...
...
@@ -172,6 +181,7 @@ export default class JobsRegistryServiceBase extends EntityService {
*/
public
async
FetchDefault
(
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
let
tempData
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
return
Http
.
getInstance
().
get
(
`/jobsregistries/fetchdefault`
,
tempData
,
isloading
);
let
res
:
any
=
Http
.
getInstance
().
get
(
`/jobsregistries/fetchdefault`
,
tempData
,
isloading
);
return
res
;
}
}
\ No newline at end of file
app_web/src/uiservice/jobs-info/jobs-info-ui-service-base.ts
浏览文件 @
217474d5
...
...
@@ -392,7 +392,7 @@ export default class JobsInfoUIServiceBase extends UIService {
this
.
mainStateFields
.
forEach
((
singleMainField
:
any
)
=>
{
if
(
!
(
singleMainField
in
curData
)){
console
.
error
(
`当前数据对象不包含属性singleMainField
,可能会发生错误`
);
console
.
warn
(
`当前数据对象不包含属性
${
singleMainField
}
,可能会发生错误`
);
}
})
for
(
let
i
=
0
;
i
<=
1
;
i
++
)
{
...
...
app_web/src/uiservice/jobs-lock/jobs-lock-ui-service-base.ts
浏览文件 @
217474d5
...
...
@@ -198,7 +198,7 @@ export default class JobsLockUIServiceBase extends UIService {
this
.
mainStateFields
.
forEach
((
singleMainField
:
any
)
=>
{
if
(
!
(
singleMainField
in
curData
)){
console
.
error
(
`当前数据对象不包含属性singleMainField
,可能会发生错误`
);
console
.
warn
(
`当前数据对象不包含属性
${
singleMainField
}
,可能会发生错误`
);
}
})
for
(
let
i
=
0
;
i
<=
1
;
i
++
)
{
...
...
app_web/src/uiservice/jobs-log/jobs-log-ui-service-base.ts
浏览文件 @
217474d5
...
...
@@ -200,7 +200,7 @@ export default class JobsLogUIServiceBase extends UIService {
this
.
mainStateFields
.
forEach
((
singleMainField
:
any
)
=>
{
if
(
!
(
singleMainField
in
curData
)){
console
.
error
(
`当前数据对象不包含属性singleMainField
,可能会发生错误`
);
console
.
warn
(
`当前数据对象不包含属性
${
singleMainField
}
,可能会发生错误`
);
}
})
for
(
let
i
=
0
;
i
<=
1
;
i
++
)
{
...
...
app_web/src/uiservice/jobs-registry/jobs-registry-ui-service-base.ts
浏览文件 @
217474d5
...
...
@@ -200,7 +200,7 @@ export default class JobsRegistryUIServiceBase extends UIService {
this
.
mainStateFields
.
forEach
((
singleMainField
:
any
)
=>
{
if
(
!
(
singleMainField
in
curData
)){
console
.
error
(
`当前数据对象不包含属性singleMainField
,可能会发生错误`
);
console
.
warn
(
`当前数据对象不包含属性
${
singleMainField
}
,可能会发生错误`
);
}
})
for
(
let
i
=
0
;
i
<=
1
;
i
++
)
{
...
...
app_web/src/utils/app-popover/app-popover.less
浏览文件 @
217474d5
.el-popover {
overflow-y: auto;
//z-index: 99 !important;
background: #ffffff;
border: 1px solid #dee0e4;
padding: 0px;
z-index: 2000;
color: var(--app-color-font-content);
line-height: 1.4;
text-align: justify;
font-size: 14px;
overflow-y: hidden;
overflow-x: hidden;
.el-card__header {
padding: 5px 10px;
border-bottom: 1px solid #dee0e4;
color: var(--app-color-font-content);
}
.el-card{
min-width: 150px;
border: none;
background-color: #ffffff;
color: var(--app-color-font-content);
}
.el-card__body {
padding: 0px;
overflow-x:hidden;
overflow-y: auto;
.viewcontainer2{
.content-container{
margin: 0;
}
}
}
}
.clearfix{
position: relative;
.cancel{
.app-popover-wrapper {
position: absolute;
right: 5px;
top: 5px;
top: 0;
right: 0;
bottom: 0;
left: 0;
.app-popover.app-popper {
border-radius: 5px;
overflow: auto;
border: 1px solid #bfbfbf;
padding: 5px;
background: #e8e8e8;
}
}
\ No newline at end of file
app_web/src/utils/app-popover/app-popover.tsx
浏览文件 @
217474d5
此差异已折叠。
点击以展开。
app_web/src/utils/decorators/errorlog.ts
浏览文件 @
217474d5
import
{
Notice
}
from
'view-design'
;
export
function
Errorlog
(
target
:
Object
,
propertyKey
:
string
,
descriptor
:
TypedPropertyDescriptor
<
any
>
){
let
origin
=
descriptor
.
value
;
let
$Notice
:
any
=
Notice
;
descriptor
.
value
=
function
(...
args
:
any
[]){
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
// 原方法调用方法
...
...
@@ -12,7 +9,7 @@ export function Errorlog(target: Object, propertyKey: string, descriptor: TypedP
}).
catch
((
error
:
any
)
=>
{
// 开发模式下页面报错
if
(
process
.
env
.
NODE_ENV
===
'development'
)
{
$Notice
.
error
({
title
:
'错误'
,
desc
:
target
.
constructor
.
name
+
'类'
+
propertyKey
+
'方法产生异常'
}
);
console
.
error
(
target
.
constructor
.
name
+
'类'
+
propertyKey
+
'方法产生异常'
);
}
// 控制台报错
console
.
error
(
error
);
...
...
app_web/src/utils/view-tool/view-tool.ts
浏览文件 @
217474d5
...
...
@@ -260,7 +260,7 @@ export class ViewTool {
if
(
_item
&&
_item
[
'dataaccaction'
]
&&
UIService
&&
data
&&
Object
.
keys
(
data
).
length
>
0
){
let
dataActionResult
:
any
=
UIService
.
getAllOPPrivs
(
data
)[
_item
[
'dataaccaction'
]];
// 无权限:0;有权限:1
if
(
!
dataActionResult
){
if
(
dataActionResult
===
0
){
// 禁用:1;隐藏:2;隐藏且默认隐藏:6
if
(
_item
.
noprivdisplaymode
===
1
){
_item
.
disabled
=
true
;
...
...
@@ -270,7 +270,8 @@ export class ViewTool {
}
else
{
_item
.
visabled
=
true
;
}
}
else
{
}
if
(
dataActionResult
===
1
){
_item
.
visabled
=
true
;
_item
.
disabled
=
false
;
}
...
...
app_web/src/widgets/app/task-index-view-appmenu/task-index-view-appmenu-base.vue
浏览文件 @
217474d5
...
...
@@ -8,111 +8,7 @@
:collapse=
"isCollapse"
@
select=
"select"
:default-active=
"defaultActive"
>
<template
v-for=
"item0 in menus"
>
<template
v-if=
"item0.items && Array.isArray(item0.items) && item0.items.length > 0"
>
<el-submenu
v-show=
"!item0.hidden"
:index=
"item0.name"
:popper-class=
"popperClass"
:key=
"item0.id"
>
<template
slot=
'title'
>
<template
v-if=
"item0.icon && item0.icon != ''"
>
<img
:src=
"item0.icon"
class=
'app-menu-icon'
/>
</
template
>
<
template
v-else-if=
"item0.iconcls && item0.iconcls != ''"
>
<i
:class=
"[item0.iconcls, 'app-menu-icon']"
></i>
</
template
>
<
template
v-else
>
<i
class=
'fa fa-cogs app-menu-icon'
></i>
</
template
>
<span
class=
'text'
:title=
"$t('app.menus.taskindexview.' + item0.name)"
>
{{$t('app.menus.taskindexview.' + item0.name)}}
</span>
</template>
<
template
v-for=
"item1 in item0.items"
>
<template
v-if=
"item1.items && Array.isArray(item1.items) && item1.items.length > 0"
>
<el-submenu
v-show=
"!item1.hidden"
:index=
"item1.name"
:popper-class=
"popperClass"
:key=
"item1.id"
>
<template
slot=
'title'
>
<template
v-if=
"item1.icon && item1.icon != ''"
>
<img
:src=
"item1.icon"
class=
'app-menu-icon'
/>
</
template
>
<
template
v-else-if=
"item1.iconcls && item1.iconcls != ''"
>
<i
:class=
"[item1.iconcls, 'app-menu-icon']"
></i>
</
template
>
<span
class=
'text'
:title=
"$t('app.menus.taskindexview.' + item1.name)"
>
{{$t('app.menus.taskindexview.' + item1.name)}}
</span>
</template>
<
template
v-for=
"item2 in item1.items"
>
<template
v-if=
"item2.type =='MENUITEM'"
>
<el-menu-item
v-show=
"!item2.hidden"
:index=
"item2.name"
:key=
"item2.id"
>
<template
v-if=
"item2.icon && item2.icon != ''"
>
<img
:src=
"item2.icon"
class=
'app-menu-icon'
/>
</
template
>
<
template
v-else-if=
"item2.iconcls && item2.iconcls != ''"
>
<i
:class=
"[item2.iconcls, 'app-menu-icon']"
></i>
</
template
>
<
template
slot=
"title"
>
<span
class=
"text"
:title=
"$t('app.menus.taskindexview.' + item2.name)"
>
{{
$t
(
'app.menus.taskindexview.'
+
item2
.
name
)
}}
</span>
<template
v-if=
"counterdata && counterdata[item2.counterid] && counterdata[item2.counterid] > 0"
>
<span
class=
"pull-right"
>
<badge
:count=
"counterdata[item2.counterid]"
:overflow-count=
"9999"
></badge>
</span>
</
template
>
</template>
</el-menu-item>
</template>
<
template
v-if=
"item2.type =='SEPERATOR'"
>
<divider
:key=
"item2.id"
/>
</
template
>
</template>
</el-submenu>
</template>
<
template
v-else
>
<template
v-if=
"item1.type =='MENUITEM'"
>
<el-menu-item
v-show=
"!item1.hidden"
:index=
"item1.name"
:key=
"item1.id"
>
<template
v-if=
"item1.icon && item1.icon != ''"
>
<img
:src=
"item1.icon"
class=
'app-menu-icon'
/>
</
template
>
<
template
v-else-if=
"item1.iconcls && item1.iconcls != ''"
>
<i
:class=
"[item1.iconcls, 'app-menu-icon']"
></i>
</
template
>
<
template
slot=
"title"
>
<span
class=
"text"
:title=
"$t('app.menus.taskindexview.' + item1.name)"
>
{{
$t
(
'app.menus.taskindexview.'
+
item1
.
name
)
}}
</span>
<template
v-if=
"counterdata && counterdata[item1.counterid] && counterdata[item1.counterid] > 0"
>
<span
class=
"pull-right"
>
<badge
:count=
"counterdata[item1.counterid]"
:overflow-count=
"9999"
></badge>
</span>
</
template
>
</template>
</el-menu-item>
</template>
<
template
v-if=
"item1.type =='SEPERATOR'"
>
<divider
:key=
"item1.id"
/>
</
template
>
</template>
</template>
</el-submenu>
</template>
<
template
v-else
>
<template
v-if=
"item0.type =='MENUITEM'"
>
<el-menu-item
v-show=
"!item0.hidden"
:index=
"item0.name"
:key=
"item0.id"
>
<template
v-if=
"item0.icon && item0.icon != ''"
>
<img
:src=
"item0.icon"
class=
'app-menu-icon'
/>
</
template
>
<
template
v-else-if=
"item0.iconcls && item0.iconcls != ''"
>
<i
:class=
"[item0.iconcls, 'app-menu-icon']"
></i>
</
template
>
<
template
v-else
>
<i
class=
'fa fa-cogs app-menu-icon'
></i>
</
template
>
<
template
slot=
"title"
>
<span
class=
"text"
:title=
"$t('app.menus.taskindexview.' + item0.name)"
>
{{
$t
(
'app.menus.taskindexview.'
+
item0
.
name
)
}}
</span>
<template
v-if=
"counterdata && counterdata[item0.counterid] && counterdata[item0.counterid] > 0"
>
<span
class=
"pull-right"
>
<badge
:count=
"counterdata[item0.counterid]"
:overflow-count=
"9999"
></badge>
</span>
</
template
>
</template>
</el-menu-item>
</template>
<
template
v-if=
"item0.type =='SEPERATOR'"
>
<divider
:key=
"item0.id"
/>
</
template
>
</template>
</template>
<app-menu-item
:menus=
"menus"
:ctrlName=
"'taskindexview'"
:isFirst=
"true"
:counterdata=
"counterdata"
:popperclass=
"popperClass"
></app-menu-item>
</el-menu>
</div>
</
template
>
...
...
app_web/src/widgets/jobs-info/default-searchform/default-searchform-base.vue
浏览文件 @
217474d5
...
...
@@ -7,12 +7,14 @@
<i-col
v-show=
"detailsModel.n_app_like.visible"
:style=
"
{}" :sm="{ span: 24, offset: 0 }" :md="{ span: 8, offset: 0 }" :lg="{ span: 8, offset: 0 }" :xl="{ span: 8, offset: 0 }">
<app-form-item
name=
'n_app_like'
:itemRules=
"this.rules.n_app_like"
class=
''
:caption=
"$t('entities.jobsinfo.default_searchform.details.n_app_like')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.n_app_like.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.n_app_like"
@
enter=
"onEnter($event)"
:disabled=
"detailsModel.n_app_like.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
<i-col
v-show=
"detailsModel.n_handler_like.visible"
:style=
"
{}" :sm="{ span: 24, offset: 0 }" :md="{ span: 8, offset: 0 }" :lg="{ span: 8, offset: 0 }" :xl="{ span: 8, offset: 0 }">
<app-form-item
name=
'n_handler_like'
:itemRules=
"this.rules.n_handler_like"
class=
''
:caption=
"$t('entities.jobsinfo.default_searchform.details.n_handler_like')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.n_handler_like.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.n_handler_like"
@
enter=
"onEnter($event)"
:disabled=
"detailsModel.n_handler_like.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
...
...
@@ -31,6 +33,7 @@
codelistType='STATIC'
placeholder='请选择...' style="">
</dropdown-list>
</app-form-item>
</i-col>
...
...
app_web/src/widgets/jobs-info/default-searchform/default-searchform-service.ts
浏览文件 @
217474d5
...
...
@@ -150,7 +150,6 @@ export default class DefaultService extends ControlService {
});
}
/**
* 添加数据
*
...
...
@@ -365,4 +364,25 @@ export default class DefaultService extends ControlService {
return
{
context
:
tempContext
,
data
:
requestData
};
}
/**
* 通过属性名称获取表单项名称
*
* @param name 实体属性名称
* @memberof DefaultService
*/
public
getItemNameByDeName
(
name
:
string
)
:
string
{
let
itemName
=
name
;
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
name
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
prop
===
name
){
itemName
=
item
.
name
;
}
});
return
itemName
.
trim
();
}
}
\ No newline at end of file
app_web/src/widgets/jobs-info/main-form/main-form-base.vue
浏览文件 @
217474d5
此差异已折叠。
点击以展开。
app_web/src/widgets/jobs-info/main-form/main-form-service.ts
浏览文件 @
217474d5
...
...
@@ -150,7 +150,6 @@ export default class MainService extends ControlService {
});
}
/**
* 添加数据
*
...
...
@@ -370,4 +369,25 @@ export default class MainService extends ControlService {
return
{
context
:
tempContext
,
data
:
requestData
};
}
/**
* 通过属性名称获取表单项名称
*
* @param name 实体属性名称
* @memberof MainService
*/
public
getItemNameByDeName
(
name
:
string
)
:
string
{
let
itemName
=
name
;
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
name
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
prop
===
name
){
itemName
=
item
.
name
;
}
});
return
itemName
.
trim
();
}
}
\ No newline at end of file
app_web/src/widgets/jobs-info/main-grid/main-grid-base.vue
浏览文件 @
217474d5
...
...
@@ -593,7 +593,7 @@ export default class MainBase extends Vue implements ControlInterface {
*
* @memberof MainBase
*/
public
defaultUpdateItems
:
Array
<
any
>
=
[
'srfkey'
];
public
defaultUpdateItems
:
Array
<
any
>
=
[];
/**
* 选中行数据
...
...
@@ -1605,7 +1605,7 @@ export default class MainBase extends Vue implements ControlInterface {
this
.
$Notice
.
success
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.commonWords.saveSuccess'
)
as
string
)
});
}
else
{
errorItems
.
forEach
((
item
:
any
,
index
:
number
)
=>
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.
saveFailed'
)
as
string
),
desc
:
item
.
majorentityname
+
(
this
.
$t
(
'app.commonWords.saveFailed'
)
as
string
)
+
'!'
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.
wrong'
)
as
string
),
desc
:
errorMessage
[
index
].
data
.
message
});
console
.
error
(
errorMessage
[
index
]);
});
}
...
...
app_web/src/widgets/jobs-info/main-grid/main-grid-model.ts
浏览文件 @
217474d5
...
...
@@ -75,6 +75,7 @@ export default class MainModel {
name
:
'srfkey'
,
prop
:
'id'
,
dataType
:
'TEXT'
,
isEditable
:
true
},
{
name
:
'timeout'
,
...
...
app_web/src/widgets/jobs-info/main-grid/main-grid-service.ts
浏览文件 @
217474d5
...
...
@@ -99,7 +99,7 @@ export default class MainService extends ControlService {
*/
@
Errorlog
public
add
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
);
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
WithUpdate
(
action
,
context
,
data
,
true
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_appEntityService
:
any
=
this
.
appEntityService
;
let
result
:
Promise
<
any
>
;
...
...
@@ -158,14 +158,14 @@ export default class MainService extends ControlService {
*/
@
Errorlog
public
update
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
);
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
WithUpdate
(
action
,
context
,
data
,
true
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_appEntityService
:
any
=
this
.
appEntityService
;
let
result
:
Promise
<
any
>
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Data
,
Context
,
isloading
);
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
_appEntityService
.
Update
(
Data
,
Context
,
isloading
);
result
=
_appEntityService
.
Update
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
);
...
...
@@ -306,4 +306,40 @@ export default class MainService extends ControlService {
})
}
/**
* 处理请求数据(修改或增加数据)
*
* @param action 行为
* @param data 数据
* @memberof MainService
*/
public
handleRequestDataWithUpdate
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isMerge
:
boolean
=
false
){
let
model
:
any
=
this
.
getMode
();
if
(
!
model
&&
model
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
dataItems
:
any
[]
=
model
.
getDataItems
();
let
requestData
:
any
=
{};
if
(
isMerge
&&
(
data
&&
data
.
viewparams
)){
Object
.
assign
(
requestData
,
data
.
viewparams
);
}
dataItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
&&
item
.
dataType
&&
Object
.
is
(
item
.
dataType
,
'FONTKEY'
)){
if
(
item
&&
item
.
prop
&&
item
.
name
){
requestData
[
item
.
prop
]
=
context
[
item
.
name
];
}
}
else
{
if
(
item
&&
item
.
isEditable
&&
item
.
prop
&&
item
.
name
&&
(
data
[
item
.
name
]
||
Object
.
is
(
data
[
item
.
name
],
0
))
){
requestData
[
item
.
prop
]
=
data
[
item
.
name
];
}
}
});
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
if
(
tempContext
&&
tempContext
.
srfsessionid
){
tempContext
.
srfsessionkey
=
tempContext
.
srfsessionid
;
delete
tempContext
.
srfsessionid
;
}
return
{
context
:
tempContext
,
data
:
requestData
};
}
}
\ No newline at end of file
app_web/src/widgets/jobs-log/default-searchform/default-searchform-base.vue
浏览文件 @
217474d5
...
...
@@ -7,18 +7,21 @@
<i-col
v-show=
"detailsModel.n_job_id_eq.visible"
:style=
"
{}" :sm="{ span: 24, offset: 0 }" :md="{ span: 8, offset: 0 }" :lg="{ span: 8, offset: 0 }" :xl="{ span: 8, offset: 0 }">
<app-form-item
name=
'n_job_id_eq'
:itemRules=
"this.rules.n_job_id_eq"
class=
''
:caption=
"$t('entities.jobslog.default_searchform.details.n_job_id_eq')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.n_job_id_eq.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.n_job_id_eq"
@
enter=
"onEnter($event)"
:disabled=
"detailsModel.n_job_id_eq.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
<i-col
v-show=
"detailsModel.n_handler_like.visible"
:style=
"
{}" :sm="{ span: 24, offset: 0 }" :md="{ span: 8, offset: 0 }" :lg="{ span: 8, offset: 0 }" :xl="{ span: 8, offset: 0 }">
<app-form-item
name=
'n_handler_like'
:itemRules=
"this.rules.n_handler_like"
class=
''
:caption=
"$t('entities.jobslog.default_searchform.details.n_handler_like')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.n_handler_like.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.n_handler_like"
@
enter=
"onEnter($event)"
:disabled=
"detailsModel.n_handler_like.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
<i-col
v-show=
"detailsModel.n_trigger_code_eq.visible"
:style=
"
{}" :sm="{ span: 24, offset: 0 }" :md="{ span: 8, offset: 0 }" :lg="{ span: 8, offset: 0 }" :xl="{ span: 8, offset: 0 }">
<app-form-item
name=
'n_trigger_code_eq'
:itemRules=
"this.rules.n_trigger_code_eq"
class=
''
:caption=
"$t('entities.jobslog.default_searchform.details.n_trigger_code_eq')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.n_trigger_code_eq.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.n_trigger_code_eq"
@
enter=
"onEnter($event)"
:disabled=
"detailsModel.n_trigger_code_eq.disabled"
type=
'number'
style=
""
></input-box>
</app-form-item>
</i-col>
...
...
app_web/src/widgets/jobs-log/default-searchform/default-searchform-service.ts
浏览文件 @
217474d5
...
...
@@ -150,7 +150,6 @@ export default class DefaultService extends ControlService {
});
}
/**
* 添加数据
*
...
...
@@ -365,4 +364,25 @@ export default class DefaultService extends ControlService {
return
{
context
:
tempContext
,
data
:
requestData
};
}
/**
* 通过属性名称获取表单项名称
*
* @param name 实体属性名称
* @memberof DefaultService
*/
public
getItemNameByDeName
(
name
:
string
)
:
string
{
let
itemName
=
name
;
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
name
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
prop
===
name
){
itemName
=
item
.
name
;
}
});
return
itemName
.
trim
();
}
}
\ No newline at end of file
app_web/src/widgets/jobs-log/main-form/main-form-base.vue
浏览文件 @
217474d5
此差异已折叠。
点击以展开。
app_web/src/widgets/jobs-log/main-form/main-form-service.ts
浏览文件 @
217474d5
...
...
@@ -150,7 +150,6 @@ export default class MainService extends ControlService {
});
}
/**
* 添加数据
*
...
...
@@ -370,4 +369,25 @@ export default class MainService extends ControlService {
return
{
context
:
tempContext
,
data
:
requestData
};
}
/**
* 通过属性名称获取表单项名称
*
* @param name 实体属性名称
* @memberof MainService
*/
public
getItemNameByDeName
(
name
:
string
)
:
string
{
let
itemName
=
name
;
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
name
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
prop
===
name
){
itemName
=
item
.
name
;
}
});
return
itemName
.
trim
();
}
}
\ No newline at end of file
app_web/src/widgets/jobs-log/main-grid/main-grid-base.vue
浏览文件 @
217474d5
...
...
@@ -579,7 +579,7 @@ export default class MainBase extends Vue implements ControlInterface {
*
* @memberof MainBase
*/
public
defaultUpdateItems
:
Array
<
any
>
=
[
'srfkey'
];
public
defaultUpdateItems
:
Array
<
any
>
=
[];
/**
* 选中行数据
...
...
@@ -1575,7 +1575,7 @@ export default class MainBase extends Vue implements ControlInterface {
this
.
$Notice
.
success
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.commonWords.saveSuccess'
)
as
string
)
});
}
else
{
errorItems
.
forEach
((
item
:
any
,
index
:
number
)
=>
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.
saveFailed'
)
as
string
),
desc
:
item
.
majorentityname
+
(
this
.
$t
(
'app.commonWords.saveFailed'
)
as
string
)
+
'!'
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.
wrong'
)
as
string
),
desc
:
errorMessage
[
index
].
data
.
message
});
console
.
error
(
errorMessage
[
index
]);
});
}
...
...
app_web/src/widgets/jobs-log/main-grid/main-grid-model.ts
浏览文件 @
217474d5
...
...
@@ -65,6 +65,7 @@ export default class MainModel {
name
:
'srfkey'
,
prop
:
'id'
,
dataType
:
'TEXT'
,
isEditable
:
true
},
{
name
:
'fail_retry_count'
,
...
...
app_web/src/widgets/jobs-log/main-grid/main-grid-service.ts
浏览文件 @
217474d5
...
...
@@ -99,7 +99,7 @@ export default class MainService extends ControlService {
*/
@
Errorlog
public
add
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
);
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
WithUpdate
(
action
,
context
,
data
,
true
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_appEntityService
:
any
=
this
.
appEntityService
;
let
result
:
Promise
<
any
>
;
...
...
@@ -158,14 +158,14 @@ export default class MainService extends ControlService {
*/
@
Errorlog
public
update
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
);
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
WithUpdate
(
action
,
context
,
data
,
true
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_appEntityService
:
any
=
this
.
appEntityService
;
let
result
:
Promise
<
any
>
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Data
,
Context
,
isloading
);
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
_appEntityService
.
Update
(
Data
,
Context
,
isloading
);
result
=
_appEntityService
.
Update
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
);
...
...
@@ -306,4 +306,40 @@ export default class MainService extends ControlService {
})
}
/**
* 处理请求数据(修改或增加数据)
*
* @param action 行为
* @param data 数据
* @memberof MainService
*/
public
handleRequestDataWithUpdate
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isMerge
:
boolean
=
false
){
let
model
:
any
=
this
.
getMode
();
if
(
!
model
&&
model
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
dataItems
:
any
[]
=
model
.
getDataItems
();
let
requestData
:
any
=
{};
if
(
isMerge
&&
(
data
&&
data
.
viewparams
)){
Object
.
assign
(
requestData
,
data
.
viewparams
);
}
dataItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
&&
item
.
dataType
&&
Object
.
is
(
item
.
dataType
,
'FONTKEY'
)){
if
(
item
&&
item
.
prop
&&
item
.
name
){
requestData
[
item
.
prop
]
=
context
[
item
.
name
];
}
}
else
{
if
(
item
&&
item
.
isEditable
&&
item
.
prop
&&
item
.
name
&&
(
data
[
item
.
name
]
||
Object
.
is
(
data
[
item
.
name
],
0
))
){
requestData
[
item
.
prop
]
=
data
[
item
.
name
];
}
}
});
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
if
(
tempContext
&&
tempContext
.
srfsessionid
){
tempContext
.
srfsessionkey
=
tempContext
.
srfsessionid
;
delete
tempContext
.
srfsessionid
;
}
return
{
context
:
tempContext
,
data
:
requestData
};
}
}
\ No newline at end of file
app_web/src/widgets/jobs-registry/default-searchform/default-searchform-base.vue
浏览文件 @
217474d5
...
...
@@ -7,6 +7,7 @@
<i-col
v-show=
"detailsModel.n_app_like.visible"
:style=
"
{}" :sm="{ span: 24, offset: 0 }" :md="{ span: 12, offset: 0 }" :lg="{ span: 12, offset: 0 }" :xl="{ span: 12, offset: 0 }">
<app-form-item
name=
'n_app_like'
:itemRules=
"this.rules.n_app_like"
class=
''
:caption=
"$t('entities.jobsregistry.default_searchform.details.n_app_like')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.n_app_like.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.n_app_like"
@
enter=
"onEnter($event)"
:disabled=
"detailsModel.n_app_like.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
...
...
@@ -25,6 +26,7 @@
codelistType='STATIC'
placeholder='请选择...' style="">
</dropdown-list>
</app-form-item>
</i-col>
...
...
app_web/src/widgets/jobs-registry/default-searchform/default-searchform-service.ts
浏览文件 @
217474d5
...
...
@@ -150,7 +150,6 @@ export default class DefaultService extends ControlService {
});
}
/**
* 添加数据
*
...
...
@@ -365,4 +364,25 @@ export default class DefaultService extends ControlService {
return
{
context
:
tempContext
,
data
:
requestData
};
}
/**
* 通过属性名称获取表单项名称
*
* @param name 实体属性名称
* @memberof DefaultService
*/
public
getItemNameByDeName
(
name
:
string
)
:
string
{
let
itemName
=
name
;
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
name
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
prop
===
name
){
itemName
=
item
.
name
;
}
});
return
itemName
.
trim
();
}
}
\ No newline at end of file
app_web/src/widgets/jobs-registry/main-form/main-form-base.vue
浏览文件 @
217474d5
...
...
@@ -7,19 +7,21 @@
<app-form-group
:uiService=
"appUIService"
:data=
"transformData(data)"
:manageContainerStatus=
"detailsModel.group1.manageContainerStatus"
:isManageContainer=
"detailsModel.group1.isManageContainer"
@
managecontainerclick=
"manageContainerClick('group1')"
layoutType=
"TABLE_24COL"
titleStyle=
""
class=
''
:uiActionGroup=
"detailsModel.group1.uiActionGroup"
@
groupuiactionclick=
"groupUIActionClick($event)"
:caption=
"$t('entities.jobsregistry.main_form.details.group1')"
:isShowCaption=
"false"
uiStyle=
"DEFAULT"
:titleBarCloseMode=
"0"
:isInfoGroupMode=
"false"
>
<row>
<i-col
v-show=
"detailsModel.app.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-item
name=
'app'
:itemRules=
"this.rules.app"
class=
''
:caption=
"$t('entities.jobsregistry.main_form.details.app')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.app.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<app-form-item
name=
'app'
:itemRules=
"this.rules
()
.app"
class=
''
:caption=
"$t('entities.jobsregistry.main_form.details.app')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.app.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.app"
@
enter=
"onEnter($event)"
unit=
""
:disabled=
"detailsModel.app.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
<i-col
v-show=
"detailsModel.address.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-item
name=
'address'
:itemRules=
"this.rules.address"
class=
''
:caption=
"$t('entities.jobsregistry.main_form.details.address')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.address.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<app-form-item
name=
'address'
:itemRules=
"this.rules
()
.address"
class=
''
:caption=
"$t('entities.jobsregistry.main_form.details.address')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.address.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<input-box
v-model=
"data.address"
@
enter=
"onEnter($event)"
unit=
""
:disabled=
"detailsModel.address.disabled"
type=
'text'
style=
""
></input-box>
</app-form-item>
</i-col>
<i-col
v-show=
"detailsModel.status.visible"
:style=
"
{}" :lg="{ span: 24, offset: 0 }">
<app-form-item
name=
'status'
:itemRules=
"this.rules.status"
class=
''
:caption=
"$t('entities.jobsregistry.main_form.details.status')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.status.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<app-form-item
name=
'status'
:itemRules=
"this.rules
()
.status"
class=
''
:caption=
"$t('entities.jobsregistry.main_form.details.status')"
uiStyle=
"DEFAULT"
:labelWidth=
"130"
:isShowCaption=
"true"
:error=
"detailsModel.status.error"
:isEmptyCaption=
"false"
labelPos=
"LEFT"
>
<dropdown-list
v-model=
"data.status"
...
...
@@ -33,6 +35,7 @@
codelistType='STATIC'
placeholder='请选择...' style="">
</dropdown-list>
</app-form-item>
</i-col>
...
...
@@ -424,7 +427,8 @@ export default class MainBase extends Vue implements ControlInterface {
* @type {*}
* @memberof MainBase
*/
public
rules
:
any
=
{
public
rules
()
:
any
{
return
{
srforikey
:
[
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'change'
},
{
type
:
'string'
,
message
:
' 值必须为字符串类型'
,
trigger
:
'blur'
},
...
...
@@ -492,6 +496,51 @@ export default class MainBase extends Vue implements ControlInterface {
{
required
:
false
,
type
:
'string'
,
message
:
'主键ID 值不能为空'
,
trigger
:
'blur'
},
],
}
}
/**
* 属性值规则
*
* @type {*}
* @memberof MainBase
*/
public
deRules
:
any
=
{
};
/**
* 校验属性值规则
*
* @public
* @param {{ name: string }} { name }
* @memberof MainBase
*/
public
verifyDeRules
(
name
:
string
,
rule
:
any
=
this
.
deRules
)
:{
isPast
:
boolean
,
infoMessage
:
string
}{
let
falg
=
{
isPast
:
true
,
infoMessage
:
""
};
if
(
!
rule
[
name
]){
return
falg
;
}
rule
[
name
].
forEach
((
item
:
any
)
=>
{
if
(
item
.
type
==
'SIMPLE'
&&
this
.
data
[
this
.
service
.
getItemNameByDeName
(
item
.
deName
)]
!=
item
.
paramValue
){
falg
.
isPast
=
false
;
falg
.
infoMessage
=
item
.
ruleInfo
;
}
if
(
item
.
type
==
'REGEX'
&&
(
item
.
isNotMode
?
item
.
RegExCode
.
test
(
this
.
data
[
name
])
:
!
item
.
RegExCode
.
test
(
this
.
data
[
name
]))){
falg
.
isPast
=
false
;
falg
.
infoMessage
=
item
.
ruleInfo
;
}
if
(
item
.
type
==
'STRINGLENGTH'
){
let
valueLength
:
number
=
this
.
data
[
name
]?
this
.
data
[
name
].
length
:
0
;
if
(
item
.
isNotMode
?
valueLength
>
item
.
minValue
&&
valueLength
<
item
.
maxValue
:
!
(
valueLength
>
item
.
minValue
&&
valueLength
<
item
.
maxValue
)){
falg
.
isPast
=
false
;
falg
.
infoMessage
=
item
.
ruleInfo
;
}
}
if
(
item
.
type
==
'GROUP'
){
falg
=
this
.
verifyDeRules
(
'group'
,
item
)
}
});
return
falg
;
}
/**
* 详情模型集合
...
...
@@ -738,7 +787,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/
public
checkItem
(
name
:
string
):
Promise
<
any
>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
var
validator
=
new
schema
({[
name
]:
this
.
rules
[
name
]});
var
validator
=
new
schema
({[
name
]:
this
.
rules
()
[
name
]});
validator
.
validate
({[
name
]:
this
.
data
[
name
]}).
then
(()
=>
{
resolve
(
true
);
})
...
...
@@ -1169,9 +1218,6 @@ export default class MainBase extends Vue implements ControlInterface {
}
const
data
=
response
.
data
;
if
(
data
.
jobsregistry
){
Object
.
assign
(
this
.
context
,{
jobsregistry
:
data
.
jobsregistry
})
}
this
.
resetDraftFormStates
();
this
.
onFormLoad
(
data
,
'loadDraft'
);
this
.
$emit
(
'load'
,
data
);
...
...
app_web/src/widgets/jobs-registry/main-form/main-form-service.ts
浏览文件 @
217474d5
...
...
@@ -150,7 +150,6 @@ export default class MainService extends ControlService {
});
}
/**
* 添加数据
*
...
...
@@ -370,4 +369,25 @@ export default class MainService extends ControlService {
return
{
context
:
tempContext
,
data
:
requestData
};
}
/**
* 通过属性名称获取表单项名称
*
* @param name 实体属性名称
* @memberof MainService
*/
public
getItemNameByDeName
(
name
:
string
)
:
string
{
let
itemName
=
name
;
let
mode
:
any
=
this
.
getMode
();
if
(
!
mode
&&
mode
.
getDataItems
instanceof
Function
)
{
return
name
;
}
let
formItemItems
:
any
[]
=
mode
.
getDataItems
();
formItemItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
.
prop
===
name
){
itemName
=
item
.
name
;
}
});
return
itemName
.
trim
();
}
}
\ No newline at end of file
app_web/src/widgets/jobs-registry/main-grid/main-grid-base.vue
浏览文件 @
217474d5
...
...
@@ -533,7 +533,7 @@ export default class MainBase extends Vue implements ControlInterface {
*
* @memberof MainBase
*/
public
defaultUpdateItems
:
Array
<
any
>
=
[
'srfkey'
];
public
defaultUpdateItems
:
Array
<
any
>
=
[];
/**
* 选中行数据
...
...
@@ -1505,7 +1505,7 @@ export default class MainBase extends Vue implements ControlInterface {
this
.
$Notice
.
success
({
title
:
''
,
desc
:
(
this
.
$t
(
'app.commonWords.saveSuccess'
)
as
string
)
});
}
else
{
errorItems
.
forEach
((
item
:
any
,
index
:
number
)
=>
{
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.
saveFailed'
)
as
string
),
desc
:
item
.
majorentityname
+
(
this
.
$t
(
'app.commonWords.saveFailed'
)
as
string
)
+
'!'
});
this
.
$Notice
.
error
({
title
:
(
this
.
$t
(
'app.commonWords.
wrong'
)
as
string
),
desc
:
errorMessage
[
index
].
data
.
message
});
console
.
error
(
errorMessage
[
index
]);
});
}
...
...
app_web/src/widgets/jobs-registry/main-grid/main-grid-model.ts
浏览文件 @
217474d5
...
...
@@ -60,6 +60,7 @@ export default class MainModel {
name
:
'srfkey'
,
prop
:
'id'
,
dataType
:
'TEXT'
,
isEditable
:
true
},
{
name
:
'jobsregistry'
,
...
...
app_web/src/widgets/jobs-registry/main-grid/main-grid-service.ts
浏览文件 @
217474d5
...
...
@@ -99,7 +99,7 @@ export default class MainService extends ControlService {
*/
@
Errorlog
public
add
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
);
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
WithUpdate
(
action
,
context
,
data
,
true
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_appEntityService
:
any
=
this
.
appEntityService
;
let
result
:
Promise
<
any
>
;
...
...
@@ -158,14 +158,14 @@ export default class MainService extends ControlService {
*/
@
Errorlog
public
update
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isloading
?:
boolean
):
Promise
<
any
>
{
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
(
action
,
context
,
data
,
true
);
const
{
data
:
Data
,
context
:
Context
}
=
this
.
handleRequestData
WithUpdate
(
action
,
context
,
data
,
true
);
return
new
Promise
((
resolve
:
any
,
reject
:
any
)
=>
{
const
_appEntityService
:
any
=
this
.
appEntityService
;
let
result
:
Promise
<
any
>
;
if
(
_appEntityService
[
action
]
&&
_appEntityService
[
action
]
instanceof
Function
)
{
result
=
_appEntityService
[
action
](
Data
,
Context
,
isloading
);
result
=
_appEntityService
[
action
](
Context
,
Data
,
isloading
);
}
else
{
result
=
_appEntityService
.
Update
(
Data
,
Context
,
isloading
);
result
=
_appEntityService
.
Update
(
Context
,
Data
,
isloading
);
}
result
.
then
((
response
)
=>
{
this
.
handleResponse
(
action
,
response
);
...
...
@@ -306,4 +306,40 @@ export default class MainService extends ControlService {
})
}
/**
* 处理请求数据(修改或增加数据)
*
* @param action 行为
* @param data 数据
* @memberof MainService
*/
public
handleRequestDataWithUpdate
(
action
:
string
,
context
:
any
=
{},
data
:
any
=
{},
isMerge
:
boolean
=
false
){
let
model
:
any
=
this
.
getMode
();
if
(
!
model
&&
model
.
getDataItems
instanceof
Function
)
{
return
data
;
}
let
dataItems
:
any
[]
=
model
.
getDataItems
();
let
requestData
:
any
=
{};
if
(
isMerge
&&
(
data
&&
data
.
viewparams
)){
Object
.
assign
(
requestData
,
data
.
viewparams
);
}
dataItems
.
forEach
((
item
:
any
)
=>
{
if
(
item
&&
item
.
dataType
&&
Object
.
is
(
item
.
dataType
,
'FONTKEY'
)){
if
(
item
&&
item
.
prop
&&
item
.
name
){
requestData
[
item
.
prop
]
=
context
[
item
.
name
];
}
}
else
{
if
(
item
&&
item
.
isEditable
&&
item
.
prop
&&
item
.
name
&&
(
data
[
item
.
name
]
||
Object
.
is
(
data
[
item
.
name
],
0
))
){
requestData
[
item
.
prop
]
=
data
[
item
.
name
];
}
}
});
let
tempContext
:
any
=
JSON
.
parse
(
JSON
.
stringify
(
context
));
if
(
tempContext
&&
tempContext
.
srfsessionid
){
tempContext
.
srfsessionkey
=
tempContext
.
srfsessionid
;
delete
tempContext
.
srfsessionid
;
}
return
{
context
:
tempContext
,
data
:
requestData
};
}
}
\ No newline at end of file
app_web/yarn.lock
浏览文件 @
217474d5
...
...
@@ -1210,6 +1210,11 @@
dependencies:
mkdirp "^1.0.4"
"@popperjs/core@^2.4.3":
version "2.4.4"
resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.4.4.tgz#11d5db19bd178936ec89cd84519c4de439574398"
integrity sha512-1oO6+dN5kdIA3sKPZhRGJTfGVP4SWV6KqlMOwry4J3HfyD68sl/3KmG7DeYUzvN+RbhXDnv/D8vNNB8168tAMg==
"@soda/friendly-errors-webpack-plugin@^1.7.1":
version "1.7.1"
resolved "https://registry.yarnpkg.com/@soda/friendly-errors-webpack-plugin/-/friendly-errors-webpack-plugin-1.7.1.tgz#706f64bcb4a8b9642b48ae3ace444c70334d615d"
...
...
ibztask-app/ibztask-app-web/src/main/resources/application-web-prod.yml
浏览文件 @
217474d5
...
...
@@ -9,39 +9,39 @@ zuul:
routes
:
jobs_info
:
path
:
/jobsinfos/**
serviceId
:
ibztask-api
serviceId
:
${ibiz.ref.service.ibztask-api:ibztask-api}
stripPrefix
:
false
jobs_log
:
path
:
/jobslogs/**
serviceId
:
ibztask-api
serviceId
:
${ibiz.ref.service.ibztask-api:ibztask-api}
stripPrefix
:
false
jobs_lock
:
path
:
/jobslocks/**
serviceId
:
ibztask-api
serviceId
:
${ibiz.ref.service.ibztask-api:ibztask-api}
stripPrefix
:
false
jobs_registry
:
path
:
/jobsregistries/**
serviceId
:
ibztask-api
serviceId
:
${ibiz.ref.service.ibztask-api:ibztask-api}
stripPrefix
:
false
loginv7
:
path
:
/v7/login
serviceId
:
ibzuaa-api
serviceId
:
${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix
:
false
changepwd
:
path
:
/v7/changepwd
serviceId
:
ibzuaa-api
serviceId
:
${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix
:
false
uaa
:
path
:
/uaa/**
serviceId
:
ibzuaa-api
serviceId
:
${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix
:
false
config
:
path
:
/config/**
serviceId
:
ibzuaa-api
serviceId
:
${ibiz.ref.service.uaa:ibzuaa-api}
stripPrefix
:
false
oucore
:
path
:
/ibzorganizations/**
serviceId
:
ibzou-api
serviceId
:
${ibiz.ref.service.ou:ibzou-api}
stripPrefix
:
false
sensitive-headers
:
-
Cookie,Set-Cookie,Authorization
ibztask-app/ibztask-app-web/src/main/resources/application.yml
浏览文件 @
217474d5
spring
:
profiles
:
include
:
sys , web-prod
include
:
sys ,
nacos,
web-prod
application
:
name
:
ibztask-web
ibztask-boot/src/main/resources/application.yml
浏览文件 @
217474d5
spring
:
profiles
:
include
:
sys , web-dev, api-dev, dev
include
:
sys ,
nacos,
web-dev, api-dev, dev
application
:
name
:
ibztask
main
:
...
...
ibztask-core/src/main/java/cn/ibizlab/core/task/service/impl/JobsInfoServiceImpl.java
浏览文件 @
217474d5
...
...
@@ -158,9 +158,9 @@ public class JobsInfoServiceImpl extends ServiceImpl<JobsInfoMapper, JobsInfo> i
@Override
@Transactional
public
JobsInfo
stop
(
JobsInfo
et
)
{
et
.
set
(
"Next_time"
,
"0"
);
et
.
set
(
"Last_time"
,
"0"
);
et
.
set
(
"Status"
,
"1"
);
et
.
set
(
"Next_time"
,
"0"
);
update
(
et
);
return
et
;
}
...
...
ibztask-dependencies/pom.xml
浏览文件 @
217474d5
...
...
@@ -77,6 +77,9 @@
<!--baomidou-jobs定时服务 -->
<baomidou-jobs.version>
1.0.3
</baomidou-jobs.version>
<!-- eureka微服务注册中心 -->
<eureka-client.version>
2.2.1.RELEASE
</eureka-client.version>
<oracle.version>
11.2.0.3
</oracle.version>
<postgresql.version>
42.2.6
</postgresql.version>
...
...
@@ -314,6 +317,13 @@
<artifactId>
h2
</artifactId>
</dependency>
<!-- eureka服务注册中心 -->
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-netflix-eureka-client
</artifactId>
<version>
${eureka-client.version}
</version>
</dependency>
<!-- Oracle驱动包 -->
<dependency>
<groupId>
com.oracle
</groupId>
...
...
@@ -332,6 +342,7 @@
<artifactId>
mysql-connector-java
</artifactId>
</dependency>
</dependencies>
</project>
ibztask-provider/ibztask-provider-api/src/main/java/cn/ibizlab/api/rest/JobsInfoResource.java
浏览文件 @
217474d5
...
...
@@ -129,7 +129,7 @@ public class JobsInfoResource {
@Transactional
public
ResponseEntity
<
JobsInfoDTO
>
execute
(
@PathVariable
(
"jobsinfo_id"
)
String
jobsinfo_id
,
@RequestBody
JobsInfoDTO
jobsinfodto
)
{
JobsInfo
domain
=
jobsinfoMapping
.
toDomain
(
jobsinfodto
);
domain
.
setId
(
jobsinfo_id
);
domain
.
setId
(
jobsinfo_id
);
domain
=
jobsinfoService
.
execute
(
domain
);
jobsinfodto
=
jobsinfoMapping
.
toDto
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
jobsinfodto
);
...
...
@@ -156,7 +156,7 @@ public class JobsInfoResource {
@Transactional
public
ResponseEntity
<
JobsInfoDTO
>
start
(
@PathVariable
(
"jobsinfo_id"
)
String
jobsinfo_id
,
@RequestBody
JobsInfoDTO
jobsinfodto
)
{
JobsInfo
domain
=
jobsinfoMapping
.
toDomain
(
jobsinfodto
);
domain
.
setId
(
jobsinfo_id
);
domain
.
setId
(
jobsinfo_id
);
domain
=
jobsinfoService
.
start
(
domain
);
jobsinfodto
=
jobsinfoMapping
.
toDto
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
jobsinfodto
);
...
...
@@ -168,7 +168,7 @@ public class JobsInfoResource {
@Transactional
public
ResponseEntity
<
JobsInfoDTO
>
stop
(
@PathVariable
(
"jobsinfo_id"
)
String
jobsinfo_id
,
@RequestBody
JobsInfoDTO
jobsinfodto
)
{
JobsInfo
domain
=
jobsinfoMapping
.
toDomain
(
jobsinfodto
);
domain
.
setId
(
jobsinfo_id
);
domain
.
setId
(
jobsinfo_id
);
domain
=
jobsinfoService
.
stop
(
domain
);
jobsinfodto
=
jobsinfoMapping
.
toDto
(
domain
);
return
ResponseEntity
.
status
(
HttpStatus
.
OK
).
body
(
jobsinfodto
);
...
...
ibztask-provider/ibztask-provider-api/src/main/resources/application.yml
浏览文件 @
217474d5
spring
:
profiles
:
include
:
sys , api-prod
include
:
sys ,
nacos,
api-prod
application
:
name
:
ibztask-api
\ No newline at end of file
ibztask-util/src/main/java/cn/ibizlab/util/client/IBZOUFeignClient.java
浏览文件 @
217474d5
...
...
@@ -7,7 +7,7 @@ import org.springframework.web.bind.annotation.PathVariable;
import
java.util.Map
;
import
java.util.Set
;
@FeignClient
(
value
=
"
ibzou-api
"
,
fallback
=
IBZOUFallback
.
class
)
@FeignClient
(
value
=
"
${ibiz.ref.service.ou:ibzou-api}
"
,
fallback
=
IBZOUFallback
.
class
)
public
interface
IBZOUFeignClient
{
/**
...
...
ibztask-util/src/main/java/cn/ibizlab/util/client/IBZUAAFeignClient.java
浏览文件 @
217474d5
...
...
@@ -7,7 +7,7 @@ import org.springframework.cloud.openfeign.FeignClient;
import
org.springframework.web.bind.annotation.*
;
import
com.alibaba.fastjson.JSONObject
;
@FeignClient
(
value
=
"
ibzuaa-api
"
,
fallback
=
IBZUAAFallback
.
class
)
@FeignClient
(
value
=
"
${ibiz.ref.service.uaa:ibzuaa-api}
"
,
fallback
=
IBZUAAFallback
.
class
)
public
interface
IBZUAAFeignClient
{
/**
...
...
ibztask-util/src/main/java/cn/ibizlab/util/client/IBZWFFeignClient.java
浏览文件 @
217474d5
...
...
@@ -4,7 +4,7 @@ import org.springframework.cloud.openfeign.FeignClient;
import
org.springframework.web.bind.annotation.*
;
import
java.util.*
;
@FeignClient
(
value
=
"
ibzwf-api
"
,
fallback
=
IBZWFFallback
.
class
)
@FeignClient
(
value
=
"
${ibiz.ref.service.wf:ibzwf-api}
"
,
fallback
=
IBZWFFallback
.
class
)
public
interface
IBZWFFeignClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/{system}-app-{appname}/{entity}/process-definitions/{processDefinitionKey}/usertasks/{taskDefinitionKey}/tasks"
)
...
...
ibztask-util/src/main/java/cn/ibizlab/util/domain/LiquibaseProp.java
浏览文件 @
217474d5
...
...
@@ -4,9 +4,9 @@ import lombok.Data;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
import
org.springframework.stereotype.Component
;
@Data
@Component
@ConfigurationProperties
(
prefix
=
"spring.datasource"
)
@Data
public
class
LiquibaseProp
{
private
String
url
;
...
...
ibztask-util/src/main/java/cn/ibizlab/util/security/AuthenticationUser.java
浏览文件 @
217474d5
...
...
@@ -65,6 +65,10 @@ public class AuthenticationUser implements UserDetails
@JsonIgnore
private
Map
<
String
,
Object
>
userSessionParam
;
//用户自定义session值
private
Map
<
String
,
Set
<
String
>>
orgInfo
;
//上下级组织信息
private
String
porg
;
private
String
sorg
;
private
String
pdept
;
private
String
sdept
;
@JsonIgnore
...
...
@@ -133,6 +137,10 @@ public class AuthenticationUser implements UserDetails
sessionParams
.
put
(
"srflocale"
,
this
.
getLang
());
sessionParams
.
put
(
"srftimezone"
,
""
);
sessionParams
.
put
(
"srfusercode"
,
this
.
getUsercode
());
sessionParams
.
put
(
"srfporg"
,
this
.
getPorg
());
sessionParams
.
put
(
"srfsorg"
,
this
.
getSorg
());
sessionParams
.
put
(
"srfpdept"
,
this
.
getPdept
());
sessionParams
.
put
(
"srfsdept"
,
this
.
getSdept
());
}
return
this
.
sessionParams
;
}
...
...
@@ -143,6 +151,26 @@ public class AuthenticationUser implements UserDetails
return
new
HashMap
<>();
}
public
void
setOrgInfo
(
Map
<
String
,
Set
<
String
>>
orgInfo
)
{
this
.
orgInfo
=
orgInfo
;
if
(!
ObjectUtils
.
isEmpty
(
orgInfo
)
&&
!
ObjectUtils
.
isEmpty
(
orgInfo
.
get
(
"parentorg"
))){
porg
=(
String
.
format
(
"'%s'"
,
String
.
join
(
"','"
,
orgInfo
.
get
(
"parentorg"
))));
this
.
getSessionParams
().
put
(
"srfporg"
,
porg
);
}
if
(!
ObjectUtils
.
isEmpty
(
orgInfo
)
&&
!
ObjectUtils
.
isEmpty
(
orgInfo
.
get
(
"suborg"
))
){
sorg
=(
String
.
format
(
"'%s'"
,
String
.
join
(
"','"
,
orgInfo
.
get
(
"suborg"
))));
this
.
getSessionParams
().
put
(
"srfsorg"
,
sorg
);
}
if
(!
ObjectUtils
.
isEmpty
(
orgInfo
)
&&
!
ObjectUtils
.
isEmpty
(
orgInfo
.
get
(
"parentdept"
))){
pdept
=(
String
.
format
(
"'%s'"
,
String
.
join
(
"','"
,
orgInfo
.
get
(
"parentdept"
))));
this
.
getSessionParams
().
put
(
"srfpdept"
,
pdept
);
}
if
(!
ObjectUtils
.
isEmpty
(
orgInfo
)
&&
!
ObjectUtils
.
isEmpty
(
orgInfo
.
get
(
"subdept"
))){
sdept
=(
String
.
format
(
"'%s'"
,
String
.
join
(
"','"
,
orgInfo
.
get
(
"subdept"
))));
this
.
getSessionParams
().
put
(
"srfsdept"
,
sdept
);
}
}
public
void
setPermissionList
(
JSONObject
permissionList
)
{
this
.
permissionList
=
permissionList
;
if
(
authorities
==
null
&&
permissionList
!=
null
){
...
...
ibztask-util/src/main/resources/application-eureka.yml
0 → 100644
浏览文件 @
217474d5
#eureka配置中心
spring
:
cloud
:
nacos
:
discovery
:
enabled
:
false
eureka
:
client
:
enabled
:
true
serviceUrl
:
defaultZone
:
http://127.0.0.1:8762/eureka/
ibztask-util/src/main/resources/application-nacos.yml
0 → 100644
浏览文件 @
217474d5
#nacos配置中心
spring
:
cloud
:
nacos
:
discovery
:
server-addr
:
172.16.102.211:8848
enabled
:
true
eureka
:
client
:
enabled
:
false
ibztask-util/src/main/resources/application-sys.yml
浏览文件 @
217474d5
#
nacos配置中心
、数据源
#
缓存
、数据源
spring
:
cloud
:
nacos
:
discovery
:
server-addr
:
172.16.102.211:8848
cache
:
redis
:
time-to-live
:
3600
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录