提交 b2214d3a 编写于 作者: ibizdev's avatar ibizdev

ibiz4j 发布系统代码

上级 0174a065
...@@ -117,7 +117,9 @@ $ yarn build ...@@ -117,7 +117,9 @@ $ yarn build
|─ ─ favicon.ico 图标 |─ ─ favicon.ico 图标
​ |─ ─ src 工程文件夹 ​ |─ ─ src 工程文件夹
|─ ─ assets 静态资源 |─ ─ assets 静态资源
|─ ─ codelist 动态代码表服务
|─ ─ components 基础组件,主要包含编辑器组件和其他全局使用的组件 |─ ─ components 基础组件,主要包含编辑器组件和其他全局使用的组件
|─ ─ counter 计数器服务
|─ ─ engine 引擎文件,主要封装了内置视图的内置逻辑 |─ ─ engine 引擎文件,主要封装了内置视图的内置逻辑
|─ ─ environments 环境文件 |─ ─ environments 环境文件
​ |─ ─ interface 接口文件 ​ |─ ─ interface 接口文件
...@@ -150,6 +152,7 @@ $ yarn build ...@@ -150,6 +152,7 @@ $ yarn build
|─ ─ YYY-ui-logic-base.ts 应用实体界面处理逻辑文件 |─ ─ YYY-ui-logic-base.ts 应用实体界面处理逻辑文件
|─ ─ YYY-ui-logic.ts 自定义应用实体界面处理逻辑文件 |─ ─ YYY-ui-logic.ts 自定义应用实体界面处理逻辑文件
|─ ─ utils 工具类文件 |─ ─ utils 工具类文件
|─ ─ utilservice 应用功能服务
|─ ─ widgets 部件文件夹 |─ ─ widgets 部件文件夹
|─ ─ appde 应用实体名称 |─ ─ appde 应用实体名称
​ |─ ─ XXX 部件名称 ​ |─ ─ XXX 部件名称
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
"element-ui": "^2.13.0", "element-ui": "^2.13.0",
"file-saver": "^2.0.2", "file-saver": "^2.0.2",
"font-awesome": "^4.7.0", "font-awesome": "^4.7.0",
"ibiz-gantt-elastic": "^1.0.8",
"interactjs": "^1.9.4", "interactjs": "^1.9.4",
"moment": "^2.24.0", "moment": "^2.24.0",
"path-to-regexp": "^6.1.0", "path-to-regexp": "^6.1.0",
......
...@@ -81,9 +81,16 @@ export default class AppUser extends Vue { ...@@ -81,9 +81,16 @@ export default class AppUser extends Vue {
* @memberof AppUser * @memberof AppUser
*/ */
public logout() { public logout() {
localStorage.removeItem('user'); const get: Promise<any> = this.$http.get('v7/logout');
localStorage.removeItem('token'); get.then((response:any) =>{
this.$router.push({ name: 'login' }); if (response && response.status === 200) {
localStorage.removeItem('user');
localStorage.removeItem('token');
this.$router.push({ name: 'login' });
}
}).catch((error: any) =>{
console.error(error);
})
} }
} }
</script> </script>
......
<template> <template>
<div class='view-container degridview wfgroup-grid-view'> <div class='view-container degridview wfgroup-grid-view'>
<app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfgroupgridview"></app-studioaction> <app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfgroupgridview"></app-studioaction>
<card class='view-card ' :dis-hover="true" :bordered="false"> <card class='view-card ' :dis-hover="true" :bordered="false">
<p slot='title'> <p slot='title'>
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div style='margin-bottom: 6px;'> <div style='margin-bottom: 6px;'>
<i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' /> <i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="请输入组名称" />
<div class='pull-right'> <div class='pull-right'>
<div class='toolbar-container'> <div class='toolbar-container'>
<tooltip :transfer="true" :max-width="600"> <tooltip :transfer="true" :max-width="600">
......
<template> <template>
<div class='view-container degridview wfmember-grid-view'> <div class='view-container degridview wfmember-grid-view'>
<app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfmembergridview"></app-studioaction> <app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfmembergridview"></app-studioaction>
<card class='view-card ' :dis-hover="true" :bordered="false"> <card class='view-card ' :dis-hover="true" :bordered="false">
<p slot='title'> <p slot='title'>
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div style='margin-bottom: 6px;'> <div style='margin-bottom: 6px;'>
<i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' /> <i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="请输入组成员名称" />
<div class='pull-right'> <div class='pull-right'>
<div class='toolbar-container'> <div class='toolbar-container'>
<tooltip :transfer="true" :max-width="600"> <tooltip :transfer="true" :max-width="600">
......
<template> <template>
<div class='view-container degridview wfprocess-definition-grid-view'> <div class='view-container degridview wfprocess-definition-grid-view'>
<app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfprocessdefinitiongridview"></app-studioaction> <app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfprocessdefinitiongridview"></app-studioaction>
<card class='view-card ' :dis-hover="true" :bordered="false"> <card class='view-card ' :dis-hover="true" :bordered="false">
<p slot='title'> <p slot='title'>
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div style='margin-bottom: 6px;'> <div style='margin-bottom: 6px;'>
<i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' /> <i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="请输入流程定义名称" />
<div class='pull-right'> <div class='pull-right'>
<div class='toolbar-container'> <div class='toolbar-container'>
<tooltip :transfer="true" :max-width="600"> <tooltip :transfer="true" :max-width="600">
......
<template> <template>
<div class='view-container degridview wfuser-grid-view'> <div class='view-container degridview wfuser-grid-view'>
<app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfusergridview"></app-studioaction> <app-studioaction :viewTitle="$t(model.srfTitle)" viewName="wfusergridview"></app-studioaction>
<card class='view-card ' :dis-hover="true" :bordered="false"> <card class='view-card ' :dis-hover="true" :bordered="false">
<p slot='title'> <p slot='title'>
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<div class='view-top-messages'> <div class='view-top-messages'>
</div> </div>
<div style='margin-bottom: 6px;'> <div style='margin-bottom: 6px;'>
<i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' /> <i-input v-show="!isExpandSearchForm" v-model="query" search enter-button @on-search="onSearch($event)" class='quick-search-input' style='max-width: 400px;' placeholder="请输入用户名称" />
<div class='pull-right'> <div class='pull-right'>
<div class='toolbar-container'> <div class='toolbar-container'>
<tooltip :transfer="true" :max-width="600"> <tooltip :transfer="true" :max-width="600">
......
...@@ -3626,6 +3626,11 @@ date-fns@^1.27.2: ...@@ -3626,6 +3626,11 @@ date-fns@^1.27.2:
resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-1.30.1.tgz#2e71bf0b119153dbb4cc4e88d9ea5acfb50dc05c" resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-1.30.1.tgz#2e71bf0b119153dbb4cc4e88d9ea5acfb50dc05c"
integrity sha512-hBSVCvSmWC+QypYObzwGOd9wqdDpOt+0wl0KbU+R+uuZBS1jN8VsD1ss3irQDknRj5NvxiTF6oj/nDRnN/UQNw== integrity sha512-hBSVCvSmWC+QypYObzwGOd9wqdDpOt+0wl0KbU+R+uuZBS1jN8VsD1ss3irQDknRj5NvxiTF6oj/nDRnN/UQNw==
dayjs@^1.8.16:
version "1.8.27"
resolved "https://registry.yarnpkg.com/dayjs/-/dayjs-1.8.27.tgz#a8ae63ee990af28c05c430f0e160ae835a0fbbf8"
integrity sha512-Jpa2acjWIeOkg8KURUHICk0EqnEFSSF5eMEscsOgyJ92ZukXwmpmRkPSUka7KHSfbj5eKH30ieosYip+ky9emQ==
de-indent@^1.0.2: de-indent@^1.0.2:
version "1.0.2" version "1.0.2"
resolved "https://registry.yarnpkg.com/de-indent/-/de-indent-1.0.2.tgz#b2038e846dc33baa5796128d0804b455b8c1e21d" resolved "https://registry.yarnpkg.com/de-indent/-/de-indent-1.0.2.tgz#b2038e846dc33baa5796128d0804b455b8c1e21d"
...@@ -5204,6 +5209,17 @@ human-signals@^1.1.1: ...@@ -5204,6 +5209,17 @@ human-signals@^1.1.1:
resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-1.1.1.tgz#c5b1cd14f50aeae09ab6c59fe63ba3395fe4dfa3" resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-1.1.1.tgz#c5b1cd14f50aeae09ab6c59fe63ba3395fe4dfa3"
integrity sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw== integrity sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==
ibiz-gantt-elastic@^1.0.8:
version "1.0.8"
resolved "https://registry.yarnpkg.com/ibiz-gantt-elastic/-/ibiz-gantt-elastic-1.0.8.tgz#d7c40b6b0068a9303772594608375d42b8dbcb61"
integrity sha512-vlawRcYGiNv6N8N9Wx2ZO7oorV3R6dZWYT7Yvb2lxWfdWYX+cK1KZP0p+2S/Is1/A7+eDFhu60iZ2nf7LExaFQ==
dependencies:
dayjs "^1.8.16"
resize-observer-polyfill "^1.5.1"
vue "^2.6.10"
vue-slider-component "^3.0.40"
vue-switches "^2.0.1"
iconv-lite@0.4.24: iconv-lite@0.4.24:
version "0.4.24" version "0.4.24"
resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b"
...@@ -8623,7 +8639,7 @@ requires-port@^1.0.0: ...@@ -8623,7 +8639,7 @@ requires-port@^1.0.0:
resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff"
integrity sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8= integrity sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=
resize-observer-polyfill@^1.5.0: resize-observer-polyfill@^1.5.0, resize-observer-polyfill@^1.5.1:
version "1.5.1" version "1.5.1"
resolved "https://registry.yarnpkg.com/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz#0e9020dd3d21024458d4ebd27e23e40269810464" resolved "https://registry.yarnpkg.com/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz#0e9020dd3d21024458d4ebd27e23e40269810464"
integrity sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg== integrity sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg==
...@@ -10115,6 +10131,13 @@ vue-loader@^15.7.2: ...@@ -10115,6 +10131,13 @@ vue-loader@^15.7.2:
vue-hot-reload-api "^2.3.0" vue-hot-reload-api "^2.3.0"
vue-style-loader "^4.1.0" vue-style-loader "^4.1.0"
vue-property-decorator@^8.0.0:
version "8.4.2"
resolved "https://registry.yarnpkg.com/vue-property-decorator/-/vue-property-decorator-8.4.2.tgz#016e17f259f73bc547e77a50ce282ba18db4ee41"
integrity sha512-IqbARlvgPE2pzKfbecKxsu2yEH0Wv7hfHR6m4eZA3LTnNw9hveAX77vDfLFyTeMISS5N7Kucp/xRSHjcQ6bAfQ==
dependencies:
vue-class-component "^7.1.0"
vue-property-decorator@^8.3.0: vue-property-decorator@^8.3.0:
version "8.3.0" version "8.3.0"
resolved "https://registry.yarnpkg.com/vue-property-decorator/-/vue-property-decorator-8.3.0.tgz#536f027dc7d626f37c8d85a2dc02f0a6cb979440" resolved "https://registry.yarnpkg.com/vue-property-decorator/-/vue-property-decorator-8.3.0.tgz#536f027dc7d626f37c8d85a2dc02f0a6cb979440"
...@@ -10127,6 +10150,13 @@ vue-router@^3.1.3: ...@@ -10127,6 +10150,13 @@ vue-router@^3.1.3:
resolved "https://registry.yarnpkg.com/vue-router/-/vue-router-3.1.4.tgz#98a6a4dd38fca0db3b9f3c04bfbd008a3b6d958d" resolved "https://registry.yarnpkg.com/vue-router/-/vue-router-3.1.4.tgz#98a6a4dd38fca0db3b9f3c04bfbd008a3b6d958d"
integrity sha512-pX2BGvZg5/MOXbJoYsRppoZM+0B4LSszvIXQvLPZ7govbgbBorYQ4JHx99lDTjzEBkbTyKfRG+ru1VCnMuVcUg== integrity sha512-pX2BGvZg5/MOXbJoYsRppoZM+0B4LSszvIXQvLPZ7govbgbBorYQ4JHx99lDTjzEBkbTyKfRG+ru1VCnMuVcUg==
vue-slider-component@^3.0.40:
version "3.1.3"
resolved "https://registry.yarnpkg.com/vue-slider-component/-/vue-slider-component-3.1.3.tgz#f5e61cdbd7b677840f7286ee590c6450469f71fb"
integrity sha512-SPFb1I3G2a4thIwghvVNhcvPGCUz6PIZR1ClwtvN4MT44ZUzvqCMDS7osdKz0hdKu4kfanxET8qZn826A/XPxA==
dependencies:
vue-property-decorator "^8.0.0"
vue-style-loader@^4.1.0: vue-style-loader@^4.1.0:
version "4.1.2" version "4.1.2"
resolved "https://registry.yarnpkg.com/vue-style-loader/-/vue-style-loader-4.1.2.tgz#dedf349806f25ceb4e64f3ad7c0a44fba735fcf8" resolved "https://registry.yarnpkg.com/vue-style-loader/-/vue-style-loader-4.1.2.tgz#dedf349806f25ceb4e64f3ad7c0a44fba735fcf8"
...@@ -10135,6 +10165,13 @@ vue-style-loader@^4.1.0: ...@@ -10135,6 +10165,13 @@ vue-style-loader@^4.1.0:
hash-sum "^1.0.2" hash-sum "^1.0.2"
loader-utils "^1.0.2" loader-utils "^1.0.2"
vue-switches@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/vue-switches/-/vue-switches-2.0.1.tgz#f23436259c7fe4ffca9c4a6df49ac78941e20a20"
integrity sha512-rDqBtK3TKy1pEvyZeWmnSHVeXqAcn+ozch7LiNThBzr1QMjg5rhvqBY7uWeli/baDDslf6CXmBJbHPwASJLqoA==
dependencies:
vue "^2.2.6"
vue-template-compiler@^2.6.10: vue-template-compiler@^2.6.10:
version "2.6.11" version "2.6.11"
resolved "https://registry.yarnpkg.com/vue-template-compiler/-/vue-template-compiler-2.6.11.tgz#c04704ef8f498b153130018993e56309d4698080" resolved "https://registry.yarnpkg.com/vue-template-compiler/-/vue-template-compiler-2.6.11.tgz#c04704ef8f498b153130018993e56309d4698080"
...@@ -10148,7 +10185,7 @@ vue-template-es2015-compiler@^1.6.0, vue-template-es2015-compiler@^1.9.0: ...@@ -10148,7 +10185,7 @@ vue-template-es2015-compiler@^1.6.0, vue-template-es2015-compiler@^1.9.0:
resolved "https://registry.yarnpkg.com/vue-template-es2015-compiler/-/vue-template-es2015-compiler-1.9.1.tgz#1ee3bc9a16ecbf5118be334bb15f9c46f82f5825" resolved "https://registry.yarnpkg.com/vue-template-es2015-compiler/-/vue-template-es2015-compiler-1.9.1.tgz#1ee3bc9a16ecbf5118be334bb15f9c46f82f5825"
integrity sha512-4gDntzrifFnCEvyoO8PqyJDmguXgVPxKiIxrBKjIowvL9l+N66196+72XVYR8BBf1Uv1Fgt3bGevJ+sEmxfZzw== integrity sha512-4gDntzrifFnCEvyoO8PqyJDmguXgVPxKiIxrBKjIowvL9l+N66196+72XVYR8BBf1Uv1Fgt3bGevJ+sEmxfZzw==
vue@^2.6.10: vue@^2.2.6, vue@^2.6.10:
version "2.6.11" version "2.6.11"
resolved "https://registry.yarnpkg.com/vue/-/vue-2.6.11.tgz#76594d877d4b12234406e84e35275c6d514125c5" resolved "https://registry.yarnpkg.com/vue/-/vue-2.6.11.tgz#76594d877d4b12234406e84e35275c6d514125c5"
integrity sha512-VfPwgcGABbGAue9+sfrD4PuwFar7gPb1yl1UK1MwXoQPAw0BKSqWfoYCT/ThFrdEVWoI51dBuyCoiNU9bZDZxQ== integrity sha512-VfPwgcGABbGAue9+sfrD4PuwFar7gPb1yl1UK1MwXoQPAw0BKSqWfoYCT/ThFrdEVWoI51dBuyCoiNU9bZDZxQ==
......
...@@ -37,11 +37,6 @@ ...@@ -37,11 +37,6 @@
git clone -b master $para2 ibzwf/ git clone -b master $para2 ibzwf/
export NODE_OPTIONS=--max-old-space-size=4096 export NODE_OPTIONS=--max-old-space-size=4096
cd ibzwf/ cd ibzwf/
mvn clean package -Pweb
cd ibzwf-app/ibzwf-app-web
mvn -Pweb docker:build
mvn -Pweb docker:push
docker -H $para1 stack deploy --compose-file=src/main/docker/ibzwf-app-web.yaml ibzlab-rt --with-registry-auth
</command> </command>
</hudson.tasks.Shell> </hudson.tasks.Shell>
</builders> </builders>
......
...@@ -9,6 +9,6 @@ CMD echo "The application will start in ${IBZ_SLEEP}s..." && \ ...@@ -9,6 +9,6 @@ CMD echo "The application will start in ${IBZ_SLEEP}s..." && \
sleep ${IBZ_SLEEP} && \ sleep ${IBZ_SLEEP} && \
java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /ibzwf-app-web.jar java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /ibzwf-app-web.jar
EXPOSE 30003 EXPOSE 8080
ADD ibzwf-app-web.jar /ibzwf-app-web.jar ADD ibzwf-app-web.jar /ibzwf-app-web.jar
...@@ -3,21 +3,9 @@ services: ...@@ -3,21 +3,9 @@ services:
ibzwf-app-web: ibzwf-app-web:
image: registry.cn-shanghai.aliyuncs.com/ibizsys/ibzwf-app-web:latest image: registry.cn-shanghai.aliyuncs.com/ibizsys/ibzwf-app-web:latest
ports: ports:
- "30003:30003" - "8080:8080"
networks: networks:
- agent_network - agent_network
environment:
- SPRING_CLOUD_NACOS_DISCOVERY_IP=172.16.180.237
- SERVER_PORT=30003
- SPRING_CLOUD_NACOS_DISCOVERY_SERVER-ADDR=172.16.102.211:8848
- SPRING_REDIS_HOST=172.16.100.243
- SPRING_REDIS_PORT=6379
- SPRING_REDIS_DATABASE=0
- SPRING_DATASOURCE_USERNAME=a_A_5d9d78509
- SPRING_DATASOURCE_PASSWORD=@6dEfb3@
- SPRING_DATASOURCE_URL=jdbc:mysql://172.16.180.232:3306/a_A_5d9d78509?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8&useOldAliasMetadataBehavior=true
- SPRING_DATASOURCE_DRIVER-CLASS-NAME=com.mysql.jdbc.Driver
- SPRING_DATASOURCE_DEFAULTSCHEMA=a_A_5d9d78509
deploy: deploy:
mode: replicated mode: replicated
replicas: 1 replicas: 1
......
...@@ -56,6 +56,7 @@ ...@@ -56,6 +56,7 @@
<column name="FONTSIZE" type="VARCHAR2(10 BYTE)"/> <column name="FONTSIZE" type="VARCHAR2(10 BYTE)"/>
<column name="LANG" type="VARCHAR2(100 BYTE)"/> <column name="LANG" type="VARCHAR2(100 BYTE)"/>
<column name="MEMO" type="VARCHAR2(500 BYTE)"/> <column name="MEMO" type="VARCHAR2(500 BYTE)"/>
<column name="SUPERUSER" type="INTEGER"/>
</createTable> </createTable>
</changeSet> </changeSet>
<changeSet author="Think (generated)" id="1561433044682-3"> <changeSet author="Think (generated)" id="1561433044682-3">
...@@ -65,6 +66,7 @@ ...@@ -65,6 +66,7 @@
<column name="USERNAME" value="系统管理员"/> <column name="USERNAME" value="系统管理员"/>
<column name="USERCODE" value="0100"/> <column name="USERCODE" value="0100"/>
<column name="LOGINNAME" value="ibzadmin"/> <column name="LOGINNAME" value="ibzadmin"/>
<column name="SUPERUSER" value="1"/>
<column name="PASSWORD" value="123456"/> <column name="PASSWORD" value="123456"/>
<column name="DOMAINS" value="100000"/> <column name="DOMAINS" value="100000"/>
<column name="MDEPTID"/> <column name="MDEPTID"/>
......
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.1.xsd"> xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.1.xsd">
<include file="changelog/20190625112530_init_ibizsys.xml" relativeToChangelogFile="true"/> <include file="changelog/20190625112530_init_ibizsys.xml" relativeToChangelogFile="true"/>
<include file="changelog/20190817112530_init_ibizsys_audit.xml" relativeToChangelogFile="true"/>
<include file="h2_table.xml" relativeToChangelogFile="true"/> <include file="h2_table.xml" relativeToChangelogFile="true"/>
<include file="view.xml" relativeToChangelogFile="true"/> <include file="view.xml" relativeToChangelogFile="true"/>
......
{ {
"unires":[ "unires":[
], ],
"predefineddatarange":[{"id":"ALL","name":"全部数据"},{"id":"CURORG","name":"当前单位"},{"id":"PORG","name":"上级单位"},{"id":"SORG","name":"下级单位"},{"id":"CURORGDEPT","name":"当前部门"},{"id":"PORGDEPT","name":"上级部门"},{"id":"SORGDEPT","name":"下级部门"}],
"entities":[ "entities":[
{
"dename":"WFREModel",
"delogicname":"流程模型",
"sysmoudle":{"id":"WORKFLOW","name":"workflow"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"Save" , "name":"Save" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" },{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" },{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}]
}
, {
"dename":"WFMember",
"delogicname":"成员",
"sysmoudle":{"id":"WORKFLOW","name":"workflow"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" },{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" },{"id":"Save" , "name":"Save" , "type":"BUILTIN" },{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}]
}
, {
"dename":"WFGroup",
"delogicname":"角色/用户组",
"sysmoudle":{"id":"WORKFLOW","name":"workflow"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"Save" , "name":"Save" , "type":"BUILTIN" },{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" },{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" },{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}]
}
, {
"dename":"WFUser",
"delogicname":"用户",
"sysmoudle":{"id":"WORKFLOW","name":"workflow"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" },{"id":"Save" , "name":"Save" , "type":"BUILTIN" },{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" },{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}]
}
, {
"dename":"WFProcessDefinition",
"delogicname":"流程定义",
"sysmoudle":{"id":"WORKFLOW","name":"workflow"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"Save" , "name":"Save" , "type":"BUILTIN" },{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" },{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" },{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}]
}
, {
"dename":"WFSystem",
"delogicname":"系统",
"sysmoudle":{"id":"WORKFLOW","name":"workflow"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" },{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" },{"id":"Save" , "name":"Save" , "type":"BUILTIN" },{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}]
}
], ],
"appmenus":[ "appmenus":[
......
...@@ -46,9 +46,6 @@ ...@@ -46,9 +46,6 @@
<!-- Security --> <!-- Security -->
<spring-cloud-security.version>2.1.1.RELEASE</spring-cloud-security.version> <spring-cloud-security.version>2.1.1.RELEASE</spring-cloud-security.version>
<!-- Activity -->
<activiti.version>7.1.0.M2</activiti.version>
<maven-jar-plugin.version>3.1.1</maven-jar-plugin.version> <maven-jar-plugin.version>3.1.1</maven-jar-plugin.version>
<!--logstash-logback-encoder--> <!--logstash-logback-encoder-->
<logstash.version>5.2</logstash.version> <logstash.version>5.2</logstash.version>
...@@ -63,7 +60,10 @@ ...@@ -63,7 +60,10 @@
<jsonwebtoken-jjwt.version>0.9.1</jsonwebtoken-jjwt.version> <jsonwebtoken-jjwt.version>0.9.1</jsonwebtoken-jjwt.version>
<!--Liquibase数据库版本更新工具--> <!--Liquibase数据库版本更新工具-->
<liquibase.version>3.6.3</liquibase.version> <liquibase.version>3.8.7</liquibase.version>
<!--H2内存数据库-->
<h2.version>1.4.200</h2.version>
<!--caffeine缓存--> <!--caffeine缓存-->
<caffeine-cache.version>2.6.0</caffeine-cache.version> <caffeine-cache.version>2.6.0</caffeine-cache.version>
...@@ -71,6 +71,9 @@ ...@@ -71,6 +71,9 @@
<!--反序列化工具--> <!--反序列化工具-->
<kryo.version>4.0.2</kryo.version> <kryo.version>4.0.2</kryo.version>
<!--httpClient -->
<openfeign-httpclient.version>11.0</openfeign-httpclient.version>
</properties> </properties>
<dependencyManagement> <dependencyManagement>
...@@ -124,6 +127,13 @@ ...@@ -124,6 +127,13 @@
<version>${liquibase.version}</version> <version>${liquibase.version}</version>
</dependency> </dependency>
<!-- H2 -->
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<version>${h2.version}</version>
</dependency>
<!-- Swagger2 --> <!-- Swagger2 -->
<dependency> <dependency>
<groupId>io.springfox</groupId> <groupId>io.springfox</groupId>
...@@ -170,23 +180,6 @@ ...@@ -170,23 +180,6 @@
<version>${drools-version}</version> <version>${drools-version}</version>
</dependency> </dependency>
<!-- Activiti -->
<dependency>
<groupId>org.activiti</groupId>
<artifactId>activiti-spring-boot-starter</artifactId>
<version>${activiti.version}</version>
</dependency>
<dependency>
<groupId>org.activiti</groupId>
<artifactId>activiti-json-converter</artifactId>
<version>${activiti.version}</version>
</dependency>
<dependency>
<groupId>org.activiti</groupId>
<artifactId>activiti-image-generator</artifactId>
<version>${activiti.version}</version>
</dependency>
<!-- Error --> <!-- Error -->
<!-- Security --> <!-- Security -->
...@@ -250,6 +243,11 @@ ...@@ -250,6 +243,11 @@
<version>${kryo.version}</version> <version>${kryo.version}</version>
</dependency> </dependency>
<dependency>
<groupId>io.github.openfeign</groupId>
<artifactId>feign-httpclient</artifactId>
<version>${openfeign-httpclient.version}</version>
</dependency>
</dependencies> </dependencies>
</dependencyManagement> </dependencyManagement>
...@@ -304,6 +302,12 @@ ...@@ -304,6 +302,12 @@
<artifactId>druid-spring-boot-starter</artifactId> <artifactId>druid-spring-boot-starter</artifactId>
</dependency> </dependency>
<!-- H2内存库 -->
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
</dependency>
<!-- Error --> <!-- Error -->
<!-- Security --> <!-- Security -->
......
...@@ -25,6 +25,7 @@ import org.springframework.beans.factory.annotation.Qualifier; ...@@ -25,6 +25,7 @@ import org.springframework.beans.factory.annotation.Qualifier;
@Profile("api-prod") @Profile("api-prod")
@Configuration @Configuration
@EnableWebSecurity @EnableWebSecurity
@EnableGlobalMethodSecurity(prePostEnabled = true)
public class apiSecurityConfig extends WebSecurityConfigurerAdapter { public class apiSecurityConfig extends WebSecurityConfigurerAdapter {
@Autowired @Autowired
......
...@@ -71,7 +71,7 @@ public class WFGroupResource { ...@@ -71,7 +71,7 @@ public class WFGroupResource {
@PreAuthorize("hasPermission(#wfgroup_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Update-all')")
@ApiOperation(value = "Update", tags = {"WFGroup" }, notes = "Update") @ApiOperation(value = "Update", tags = {"WFGroup" }, notes = "Update")
@RequestMapping(method = RequestMethod.PUT, value = "/wfgroups/{wfgroup_id}") @RequestMapping(method = RequestMethod.PUT, value = "/wfgroups/{wfgroup_id}")
@Transactional @Transactional
...@@ -83,7 +83,7 @@ public class WFGroupResource { ...@@ -83,7 +83,7 @@ public class WFGroupResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission(#wfgroup_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Update-all')")
@ApiOperation(value = "UpdateBatch", tags = {"WFGroup" }, notes = "UpdateBatch") @ApiOperation(value = "UpdateBatch", tags = {"WFGroup" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/wfgroups/batch") @RequestMapping(method = RequestMethod.PUT, value = "/wfgroups/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFGroupDTO> wfgroupdtos) { public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFGroupDTO> wfgroupdtos) {
...@@ -112,7 +112,7 @@ public class WFGroupResource { ...@@ -112,7 +112,7 @@ public class WFGroupResource {
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Create-all')")
@ApiOperation(value = "Create", tags = {"WFGroup" }, notes = "Create") @ApiOperation(value = "Create", tags = {"WFGroup" }, notes = "Create")
@RequestMapping(method = RequestMethod.POST, value = "/wfgroups") @RequestMapping(method = RequestMethod.POST, value = "/wfgroups")
@Transactional @Transactional
...@@ -122,8 +122,7 @@ public class WFGroupResource { ...@@ -122,8 +122,7 @@ public class WFGroupResource {
WFGroupDTO dto = wfgroupMapping.toDto(domain); WFGroupDTO dto = wfgroupMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Create-all')")
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})")
@ApiOperation(value = "createBatch", tags = {"WFGroup" }, notes = "createBatch") @ApiOperation(value = "createBatch", tags = {"WFGroup" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/wfgroups/batch") @RequestMapping(method = RequestMethod.POST, value = "/wfgroups/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<WFGroupDTO> wfgroupdtos) { public ResponseEntity<Boolean> createBatch(@RequestBody List<WFGroupDTO> wfgroupdtos) {
...@@ -134,7 +133,7 @@ public class WFGroupResource { ...@@ -134,7 +133,7 @@ public class WFGroupResource {
@PreAuthorize("hasPermission('Remove',{#wfgroup_id,{this.getEntity(),'Sql'}})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Remove-all')")
@ApiOperation(value = "Remove", tags = {"WFGroup" }, notes = "Remove") @ApiOperation(value = "Remove", tags = {"WFGroup" }, notes = "Remove")
@RequestMapping(method = RequestMethod.DELETE, value = "/wfgroups/{wfgroup_id}") @RequestMapping(method = RequestMethod.DELETE, value = "/wfgroups/{wfgroup_id}")
@Transactional @Transactional
...@@ -152,7 +151,7 @@ public class WFGroupResource { ...@@ -152,7 +151,7 @@ public class WFGroupResource {
@PreAuthorize("hasPermission(#wfgroup_id,'Get',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Get-all')")
@ApiOperation(value = "Get", tags = {"WFGroup" }, notes = "Get") @ApiOperation(value = "Get", tags = {"WFGroup" }, notes = "Get")
@RequestMapping(method = RequestMethod.GET, value = "/wfgroups/{wfgroup_id}") @RequestMapping(method = RequestMethod.GET, value = "/wfgroups/{wfgroup_id}")
public ResponseEntity<WFGroupDTO> get(@PathVariable("wfgroup_id") String wfgroup_id) { public ResponseEntity<WFGroupDTO> get(@PathVariable("wfgroup_id") String wfgroup_id) {
...@@ -161,7 +160,7 @@ public class WFGroupResource { ...@@ -161,7 +160,7 @@ public class WFGroupResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Default-all')")
@ApiOperation(value = "fetchDEFAULT", tags = {"WFGroup" } ,notes = "fetchDEFAULT") @ApiOperation(value = "fetchDEFAULT", tags = {"WFGroup" } ,notes = "fetchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfgroups/fetchdefault") @RequestMapping(method= RequestMethod.GET , value="/wfgroups/fetchdefault")
public ResponseEntity<List<WFGroupDTO>> fetchDefault(WFGroupSearchContext context) { public ResponseEntity<List<WFGroupDTO>> fetchDefault(WFGroupSearchContext context) {
...@@ -174,10 +173,10 @@ public class WFGroupResource { ...@@ -174,10 +173,10 @@ public class WFGroupResource {
.body(list); .body(list);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFGroup-Default-all')")
@ApiOperation(value = "searchDEFAULT", tags = {"WFGroup" } ,notes = "searchDEFAULT") @ApiOperation(value = "searchDEFAULT", tags = {"WFGroup" } ,notes = "searchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfgroups/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfgroups/searchdefault")
public ResponseEntity<Page<WFGroupDTO>> searchDefault(WFGroupSearchContext context) { public ResponseEntity<Page<WFGroupDTO>> searchDefault(@RequestBody WFGroupSearchContext context) {
Page<WFGroup> domains = wfgroupService.searchDefault(context) ; Page<WFGroup> domains = wfgroupService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(wfgroupMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(wfgroupMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
......
...@@ -73,7 +73,7 @@ public class WFMemberResource { ...@@ -73,7 +73,7 @@ public class WFMemberResource {
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Create-all')")
@ApiOperation(value = "Create", tags = {"WFMember" }, notes = "Create") @ApiOperation(value = "Create", tags = {"WFMember" }, notes = "Create")
@RequestMapping(method = RequestMethod.POST, value = "/wfmembers") @RequestMapping(method = RequestMethod.POST, value = "/wfmembers")
@Transactional @Transactional
...@@ -83,8 +83,7 @@ public class WFMemberResource { ...@@ -83,8 +83,7 @@ public class WFMemberResource {
WFMemberDTO dto = wfmemberMapping.toDto(domain); WFMemberDTO dto = wfmemberMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Create-all')")
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})")
@ApiOperation(value = "createBatch", tags = {"WFMember" }, notes = "createBatch") @ApiOperation(value = "createBatch", tags = {"WFMember" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/wfmembers/batch") @RequestMapping(method = RequestMethod.POST, value = "/wfmembers/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<WFMemberDTO> wfmemberdtos) { public ResponseEntity<Boolean> createBatch(@RequestBody List<WFMemberDTO> wfmemberdtos) {
...@@ -95,7 +94,7 @@ public class WFMemberResource { ...@@ -95,7 +94,7 @@ public class WFMemberResource {
@PreAuthorize("hasPermission('Remove',{#wfmember_id,{this.getEntity(),'Sql'}})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Remove-all')")
@ApiOperation(value = "Remove", tags = {"WFMember" }, notes = "Remove") @ApiOperation(value = "Remove", tags = {"WFMember" }, notes = "Remove")
@RequestMapping(method = RequestMethod.DELETE, value = "/wfmembers/{wfmember_id}") @RequestMapping(method = RequestMethod.DELETE, value = "/wfmembers/{wfmember_id}")
@Transactional @Transactional
...@@ -129,7 +128,7 @@ public class WFMemberResource { ...@@ -129,7 +128,7 @@ public class WFMemberResource {
@PreAuthorize("hasPermission(#wfmember_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Update-all')")
@ApiOperation(value = "Update", tags = {"WFMember" }, notes = "Update") @ApiOperation(value = "Update", tags = {"WFMember" }, notes = "Update")
@RequestMapping(method = RequestMethod.PUT, value = "/wfmembers/{wfmember_id}") @RequestMapping(method = RequestMethod.PUT, value = "/wfmembers/{wfmember_id}")
@Transactional @Transactional
...@@ -141,7 +140,7 @@ public class WFMemberResource { ...@@ -141,7 +140,7 @@ public class WFMemberResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission(#wfmember_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Update-all')")
@ApiOperation(value = "UpdateBatch", tags = {"WFMember" }, notes = "UpdateBatch") @ApiOperation(value = "UpdateBatch", tags = {"WFMember" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/wfmembers/batch") @RequestMapping(method = RequestMethod.PUT, value = "/wfmembers/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFMemberDTO> wfmemberdtos) { public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFMemberDTO> wfmemberdtos) {
...@@ -152,7 +151,7 @@ public class WFMemberResource { ...@@ -152,7 +151,7 @@ public class WFMemberResource {
@PreAuthorize("hasPermission(#wfmember_id,'Get',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Get-all')")
@ApiOperation(value = "Get", tags = {"WFMember" }, notes = "Get") @ApiOperation(value = "Get", tags = {"WFMember" }, notes = "Get")
@RequestMapping(method = RequestMethod.GET, value = "/wfmembers/{wfmember_id}") @RequestMapping(method = RequestMethod.GET, value = "/wfmembers/{wfmember_id}")
public ResponseEntity<WFMemberDTO> get(@PathVariable("wfmember_id") String wfmember_id) { public ResponseEntity<WFMemberDTO> get(@PathVariable("wfmember_id") String wfmember_id) {
...@@ -161,7 +160,7 @@ public class WFMemberResource { ...@@ -161,7 +160,7 @@ public class WFMemberResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Default-all')")
@ApiOperation(value = "fetchDEFAULT", tags = {"WFMember" } ,notes = "fetchDEFAULT") @ApiOperation(value = "fetchDEFAULT", tags = {"WFMember" } ,notes = "fetchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfmembers/fetchdefault") @RequestMapping(method= RequestMethod.GET , value="/wfmembers/fetchdefault")
public ResponseEntity<List<WFMemberDTO>> fetchDefault(WFMemberSearchContext context) { public ResponseEntity<List<WFMemberDTO>> fetchDefault(WFMemberSearchContext context) {
...@@ -174,10 +173,10 @@ public class WFMemberResource { ...@@ -174,10 +173,10 @@ public class WFMemberResource {
.body(list); .body(list);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFMember-Default-all')")
@ApiOperation(value = "searchDEFAULT", tags = {"WFMember" } ,notes = "searchDEFAULT") @ApiOperation(value = "searchDEFAULT", tags = {"WFMember" } ,notes = "searchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfmembers/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfmembers/searchdefault")
public ResponseEntity<Page<WFMemberDTO>> searchDefault(WFMemberSearchContext context) { public ResponseEntity<Page<WFMemberDTO>> searchDefault(@RequestBody WFMemberSearchContext context) {
Page<WFMember> domains = wfmemberService.searchDefault(context) ; Page<WFMember> domains = wfmemberService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(wfmemberMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(wfmemberMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
...@@ -299,8 +298,8 @@ public class WFMemberResource { ...@@ -299,8 +298,8 @@ public class WFMemberResource {
} }
@ApiOperation(value = "searchDEFAULTByWFGroup", tags = {"WFMember" } ,notes = "searchDEFAULTByWFGroup") @ApiOperation(value = "searchDEFAULTByWFGroup", tags = {"WFMember" } ,notes = "searchDEFAULTByWFGroup")
@RequestMapping(method= RequestMethod.GET , value="/wfgroups/{wfgroup_id}/wfmembers/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfgroups/{wfgroup_id}/wfmembers/searchdefault")
public ResponseEntity<Page<WFMemberDTO>> searchWFMemberDefaultByWFGroup(@PathVariable("wfgroup_id") String wfgroup_id,WFMemberSearchContext context) { public ResponseEntity<Page<WFMemberDTO>> searchWFMemberDefaultByWFGroup(@PathVariable("wfgroup_id") String wfgroup_id, @RequestBody WFMemberSearchContext context) {
context.setN_groupid_eq(wfgroup_id); context.setN_groupid_eq(wfgroup_id);
Page<WFMember> domains = wfmemberService.searchDefault(context) ; Page<WFMember> domains = wfmemberService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
...@@ -423,8 +422,8 @@ public class WFMemberResource { ...@@ -423,8 +422,8 @@ public class WFMemberResource {
} }
@ApiOperation(value = "searchDEFAULTByWFUser", tags = {"WFMember" } ,notes = "searchDEFAULTByWFUser") @ApiOperation(value = "searchDEFAULTByWFUser", tags = {"WFMember" } ,notes = "searchDEFAULTByWFUser")
@RequestMapping(method= RequestMethod.GET , value="/wfusers/{wfuser_id}/wfmembers/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfusers/{wfuser_id}/wfmembers/searchdefault")
public ResponseEntity<Page<WFMemberDTO>> searchWFMemberDefaultByWFUser(@PathVariable("wfuser_id") String wfuser_id,WFMemberSearchContext context) { public ResponseEntity<Page<WFMemberDTO>> searchWFMemberDefaultByWFUser(@PathVariable("wfuser_id") String wfuser_id, @RequestBody WFMemberSearchContext context) {
context.setN_userid_eq(wfuser_id); context.setN_userid_eq(wfuser_id);
Page<WFMember> domains = wfmemberService.searchDefault(context) ; Page<WFMember> domains = wfmemberService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
......
...@@ -71,7 +71,7 @@ public class WFProcessDefinitionResource { ...@@ -71,7 +71,7 @@ public class WFProcessDefinitionResource {
@PreAuthorize("hasPermission(#wfprocessdefinition_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Update-all')")
@ApiOperation(value = "Update", tags = {"WFProcessDefinition" }, notes = "Update") @ApiOperation(value = "Update", tags = {"WFProcessDefinition" }, notes = "Update")
@RequestMapping(method = RequestMethod.PUT, value = "/wfprocessdefinitions/{wfprocessdefinition_id}") @RequestMapping(method = RequestMethod.PUT, value = "/wfprocessdefinitions/{wfprocessdefinition_id}")
@Transactional @Transactional
...@@ -83,7 +83,7 @@ public class WFProcessDefinitionResource { ...@@ -83,7 +83,7 @@ public class WFProcessDefinitionResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission(#wfprocessdefinition_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Update-all')")
@ApiOperation(value = "UpdateBatch", tags = {"WFProcessDefinition" }, notes = "UpdateBatch") @ApiOperation(value = "UpdateBatch", tags = {"WFProcessDefinition" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/wfprocessdefinitions/batch") @RequestMapping(method = RequestMethod.PUT, value = "/wfprocessdefinitions/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFProcessDefinitionDTO> wfprocessdefinitiondtos) { public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFProcessDefinitionDTO> wfprocessdefinitiondtos) {
...@@ -94,7 +94,7 @@ public class WFProcessDefinitionResource { ...@@ -94,7 +94,7 @@ public class WFProcessDefinitionResource {
@PreAuthorize("hasPermission(#wfprocessdefinition_id,'Get',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Get-all')")
@ApiOperation(value = "Get", tags = {"WFProcessDefinition" }, notes = "Get") @ApiOperation(value = "Get", tags = {"WFProcessDefinition" }, notes = "Get")
@RequestMapping(method = RequestMethod.GET, value = "/wfprocessdefinitions/{wfprocessdefinition_id}") @RequestMapping(method = RequestMethod.GET, value = "/wfprocessdefinitions/{wfprocessdefinition_id}")
public ResponseEntity<WFProcessDefinitionDTO> get(@PathVariable("wfprocessdefinition_id") String wfprocessdefinition_id) { public ResponseEntity<WFProcessDefinitionDTO> get(@PathVariable("wfprocessdefinition_id") String wfprocessdefinition_id) {
...@@ -124,7 +124,7 @@ public class WFProcessDefinitionResource { ...@@ -124,7 +124,7 @@ public class WFProcessDefinitionResource {
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Create-all')")
@ApiOperation(value = "Create", tags = {"WFProcessDefinition" }, notes = "Create") @ApiOperation(value = "Create", tags = {"WFProcessDefinition" }, notes = "Create")
@RequestMapping(method = RequestMethod.POST, value = "/wfprocessdefinitions") @RequestMapping(method = RequestMethod.POST, value = "/wfprocessdefinitions")
@Transactional @Transactional
...@@ -134,8 +134,7 @@ public class WFProcessDefinitionResource { ...@@ -134,8 +134,7 @@ public class WFProcessDefinitionResource {
WFProcessDefinitionDTO dto = wfprocessdefinitionMapping.toDto(domain); WFProcessDefinitionDTO dto = wfprocessdefinitionMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Create-all')")
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})")
@ApiOperation(value = "createBatch", tags = {"WFProcessDefinition" }, notes = "createBatch") @ApiOperation(value = "createBatch", tags = {"WFProcessDefinition" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/wfprocessdefinitions/batch") @RequestMapping(method = RequestMethod.POST, value = "/wfprocessdefinitions/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<WFProcessDefinitionDTO> wfprocessdefinitiondtos) { public ResponseEntity<Boolean> createBatch(@RequestBody List<WFProcessDefinitionDTO> wfprocessdefinitiondtos) {
...@@ -146,7 +145,7 @@ public class WFProcessDefinitionResource { ...@@ -146,7 +145,7 @@ public class WFProcessDefinitionResource {
@PreAuthorize("hasPermission('Remove',{#wfprocessdefinition_id,{this.getEntity(),'Sql'}})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Remove-all')")
@ApiOperation(value = "Remove", tags = {"WFProcessDefinition" }, notes = "Remove") @ApiOperation(value = "Remove", tags = {"WFProcessDefinition" }, notes = "Remove")
@RequestMapping(method = RequestMethod.DELETE, value = "/wfprocessdefinitions/{wfprocessdefinition_id}") @RequestMapping(method = RequestMethod.DELETE, value = "/wfprocessdefinitions/{wfprocessdefinition_id}")
@Transactional @Transactional
...@@ -161,7 +160,7 @@ public class WFProcessDefinitionResource { ...@@ -161,7 +160,7 @@ public class WFProcessDefinitionResource {
return ResponseEntity.status(HttpStatus.OK).body(true); return ResponseEntity.status(HttpStatus.OK).body(true);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Default-all')")
@ApiOperation(value = "fetchDEFAULT", tags = {"WFProcessDefinition" } ,notes = "fetchDEFAULT") @ApiOperation(value = "fetchDEFAULT", tags = {"WFProcessDefinition" } ,notes = "fetchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfprocessdefinitions/fetchdefault") @RequestMapping(method= RequestMethod.GET , value="/wfprocessdefinitions/fetchdefault")
public ResponseEntity<List<WFProcessDefinitionDTO>> fetchDefault(WFProcessDefinitionSearchContext context) { public ResponseEntity<List<WFProcessDefinitionDTO>> fetchDefault(WFProcessDefinitionSearchContext context) {
...@@ -174,10 +173,10 @@ public class WFProcessDefinitionResource { ...@@ -174,10 +173,10 @@ public class WFProcessDefinitionResource {
.body(list); .body(list);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFProcessDefinition-Default-all')")
@ApiOperation(value = "searchDEFAULT", tags = {"WFProcessDefinition" } ,notes = "searchDEFAULT") @ApiOperation(value = "searchDEFAULT", tags = {"WFProcessDefinition" } ,notes = "searchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfprocessdefinitions/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfprocessdefinitions/searchdefault")
public ResponseEntity<Page<WFProcessDefinitionDTO>> searchDefault(WFProcessDefinitionSearchContext context) { public ResponseEntity<Page<WFProcessDefinitionDTO>> searchDefault(@RequestBody WFProcessDefinitionSearchContext context) {
Page<WFProcessDefinition> domains = wfprocessdefinitionService.searchDefault(context) ; Page<WFProcessDefinition> domains = wfprocessdefinitionService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(wfprocessdefinitionMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(wfprocessdefinitionMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
......
...@@ -55,7 +55,7 @@ public class WFREModelResource { ...@@ -55,7 +55,7 @@ public class WFREModelResource {
@PreAuthorize("hasPermission(#wfremodel_id,'Update',{this.getEntity(),'None'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Update-all')")
@ApiOperation(value = "Update", tags = {"WFREModel" }, notes = "Update") @ApiOperation(value = "Update", tags = {"WFREModel" }, notes = "Update")
@RequestMapping(method = RequestMethod.PUT, value = "/wfremodels/{wfremodel_id}") @RequestMapping(method = RequestMethod.PUT, value = "/wfremodels/{wfremodel_id}")
@Transactional @Transactional
...@@ -67,7 +67,7 @@ public class WFREModelResource { ...@@ -67,7 +67,7 @@ public class WFREModelResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission(#wfremodel_id,'Update',{this.getEntity(),'None'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Update-all')")
@ApiOperation(value = "UpdateBatch", tags = {"WFREModel" }, notes = "UpdateBatch") @ApiOperation(value = "UpdateBatch", tags = {"WFREModel" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/wfremodels/batch") @RequestMapping(method = RequestMethod.PUT, value = "/wfremodels/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFREModelDTO> wfremodeldtos) { public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFREModelDTO> wfremodeldtos) {
...@@ -94,7 +94,7 @@ public class WFREModelResource { ...@@ -94,7 +94,7 @@ public class WFREModelResource {
@PreAuthorize("hasPermission(#wfremodel_id,'Get',{this.getEntity(),'None'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Get-all')")
@ApiOperation(value = "Get", tags = {"WFREModel" }, notes = "Get") @ApiOperation(value = "Get", tags = {"WFREModel" }, notes = "Get")
@RequestMapping(method = RequestMethod.GET, value = "/wfremodels/{wfremodel_id}") @RequestMapping(method = RequestMethod.GET, value = "/wfremodels/{wfremodel_id}")
public ResponseEntity<WFREModelDTO> get(@PathVariable("wfremodel_id") String wfremodel_id) { public ResponseEntity<WFREModelDTO> get(@PathVariable("wfremodel_id") String wfremodel_id) {
...@@ -106,7 +106,7 @@ public class WFREModelResource { ...@@ -106,7 +106,7 @@ public class WFREModelResource {
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'None'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Create-all')")
@ApiOperation(value = "Create", tags = {"WFREModel" }, notes = "Create") @ApiOperation(value = "Create", tags = {"WFREModel" }, notes = "Create")
@RequestMapping(method = RequestMethod.POST, value = "/wfremodels") @RequestMapping(method = RequestMethod.POST, value = "/wfremodels")
@Transactional @Transactional
...@@ -116,8 +116,7 @@ public class WFREModelResource { ...@@ -116,8 +116,7 @@ public class WFREModelResource {
WFREModelDTO dto = wfremodelMapping.toDto(domain); WFREModelDTO dto = wfremodelMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Create-all')")
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'None'})")
@ApiOperation(value = "createBatch", tags = {"WFREModel" }, notes = "createBatch") @ApiOperation(value = "createBatch", tags = {"WFREModel" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/wfremodels/batch") @RequestMapping(method = RequestMethod.POST, value = "/wfremodels/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<WFREModelDTO> wfremodeldtos) { public ResponseEntity<Boolean> createBatch(@RequestBody List<WFREModelDTO> wfremodeldtos) {
...@@ -137,7 +136,7 @@ public class WFREModelResource { ...@@ -137,7 +136,7 @@ public class WFREModelResource {
@PreAuthorize("hasPermission('Remove',{#wfremodel_id,{this.getEntity(),'None'}})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Remove-all')")
@ApiOperation(value = "Remove", tags = {"WFREModel" }, notes = "Remove") @ApiOperation(value = "Remove", tags = {"WFREModel" }, notes = "Remove")
@RequestMapping(method = RequestMethod.DELETE, value = "/wfremodels/{wfremodel_id}") @RequestMapping(method = RequestMethod.DELETE, value = "/wfremodels/{wfremodel_id}")
@Transactional @Transactional
...@@ -161,7 +160,7 @@ public class WFREModelResource { ...@@ -161,7 +160,7 @@ public class WFREModelResource {
return ResponseEntity.status(HttpStatus.OK).body(wfremodelMapping.toDto(wfremodelService.getDraft(new WFREModel()))); return ResponseEntity.status(HttpStatus.OK).body(wfremodelMapping.toDto(wfremodelService.getDraft(new WFREModel())));
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'None'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Default-all')")
@ApiOperation(value = "fetchDEFAULT", tags = {"WFREModel" } ,notes = "fetchDEFAULT") @ApiOperation(value = "fetchDEFAULT", tags = {"WFREModel" } ,notes = "fetchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfremodels/fetchdefault") @RequestMapping(method= RequestMethod.GET , value="/wfremodels/fetchdefault")
public ResponseEntity<List<WFREModelDTO>> fetchDefault(WFREModelSearchContext context) { public ResponseEntity<List<WFREModelDTO>> fetchDefault(WFREModelSearchContext context) {
...@@ -174,10 +173,10 @@ public class WFREModelResource { ...@@ -174,10 +173,10 @@ public class WFREModelResource {
.body(list); .body(list);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'None'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFREModel-Default-all')")
@ApiOperation(value = "searchDEFAULT", tags = {"WFREModel" } ,notes = "searchDEFAULT") @ApiOperation(value = "searchDEFAULT", tags = {"WFREModel" } ,notes = "searchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfremodels/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfremodels/searchdefault")
public ResponseEntity<Page<WFREModelDTO>> searchDefault(WFREModelSearchContext context) { public ResponseEntity<Page<WFREModelDTO>> searchDefault(@RequestBody WFREModelSearchContext context) {
Page<WFREModel> domains = wfremodelService.searchDefault(context) ; Page<WFREModel> domains = wfremodelService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(wfremodelMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(wfremodelMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
......
...@@ -55,7 +55,7 @@ public class WFSystemResource { ...@@ -55,7 +55,7 @@ public class WFSystemResource {
@PreAuthorize("hasPermission('Remove',{#wfsystem_id,{this.getEntity(),'Sql'}})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Remove-all')")
@ApiOperation(value = "Remove", tags = {"WFSystem" }, notes = "Remove") @ApiOperation(value = "Remove", tags = {"WFSystem" }, notes = "Remove")
@RequestMapping(method = RequestMethod.DELETE, value = "/wfsystems/{wfsystem_id}") @RequestMapping(method = RequestMethod.DELETE, value = "/wfsystems/{wfsystem_id}")
@Transactional @Transactional
...@@ -73,7 +73,7 @@ public class WFSystemResource { ...@@ -73,7 +73,7 @@ public class WFSystemResource {
@PreAuthorize("hasPermission(#wfsystem_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Update-all')")
@ApiOperation(value = "Update", tags = {"WFSystem" }, notes = "Update") @ApiOperation(value = "Update", tags = {"WFSystem" }, notes = "Update")
@RequestMapping(method = RequestMethod.PUT, value = "/wfsystems/{wfsystem_id}") @RequestMapping(method = RequestMethod.PUT, value = "/wfsystems/{wfsystem_id}")
@Transactional @Transactional
...@@ -85,7 +85,7 @@ public class WFSystemResource { ...@@ -85,7 +85,7 @@ public class WFSystemResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission(#wfsystem_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Update-all')")
@ApiOperation(value = "UpdateBatch", tags = {"WFSystem" }, notes = "UpdateBatch") @ApiOperation(value = "UpdateBatch", tags = {"WFSystem" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/wfsystems/batch") @RequestMapping(method = RequestMethod.PUT, value = "/wfsystems/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFSystemDTO> wfsystemdtos) { public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFSystemDTO> wfsystemdtos) {
...@@ -121,7 +121,7 @@ public class WFSystemResource { ...@@ -121,7 +121,7 @@ public class WFSystemResource {
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Create-all')")
@ApiOperation(value = "Create", tags = {"WFSystem" }, notes = "Create") @ApiOperation(value = "Create", tags = {"WFSystem" }, notes = "Create")
@RequestMapping(method = RequestMethod.POST, value = "/wfsystems") @RequestMapping(method = RequestMethod.POST, value = "/wfsystems")
@Transactional @Transactional
...@@ -131,8 +131,7 @@ public class WFSystemResource { ...@@ -131,8 +131,7 @@ public class WFSystemResource {
WFSystemDTO dto = wfsystemMapping.toDto(domain); WFSystemDTO dto = wfsystemMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Create-all')")
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})")
@ApiOperation(value = "createBatch", tags = {"WFSystem" }, notes = "createBatch") @ApiOperation(value = "createBatch", tags = {"WFSystem" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/wfsystems/batch") @RequestMapping(method = RequestMethod.POST, value = "/wfsystems/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<WFSystemDTO> wfsystemdtos) { public ResponseEntity<Boolean> createBatch(@RequestBody List<WFSystemDTO> wfsystemdtos) {
...@@ -152,7 +151,7 @@ public class WFSystemResource { ...@@ -152,7 +151,7 @@ public class WFSystemResource {
@PreAuthorize("hasPermission(#wfsystem_id,'Get',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Get-all')")
@ApiOperation(value = "Get", tags = {"WFSystem" }, notes = "Get") @ApiOperation(value = "Get", tags = {"WFSystem" }, notes = "Get")
@RequestMapping(method = RequestMethod.GET, value = "/wfsystems/{wfsystem_id}") @RequestMapping(method = RequestMethod.GET, value = "/wfsystems/{wfsystem_id}")
public ResponseEntity<WFSystemDTO> get(@PathVariable("wfsystem_id") String wfsystem_id) { public ResponseEntity<WFSystemDTO> get(@PathVariable("wfsystem_id") String wfsystem_id) {
...@@ -161,7 +160,7 @@ public class WFSystemResource { ...@@ -161,7 +160,7 @@ public class WFSystemResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Default-all')")
@ApiOperation(value = "fetchDEFAULT", tags = {"WFSystem" } ,notes = "fetchDEFAULT") @ApiOperation(value = "fetchDEFAULT", tags = {"WFSystem" } ,notes = "fetchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfsystems/fetchdefault") @RequestMapping(method= RequestMethod.GET , value="/wfsystems/fetchdefault")
public ResponseEntity<List<WFSystemDTO>> fetchDefault(WFSystemSearchContext context) { public ResponseEntity<List<WFSystemDTO>> fetchDefault(WFSystemSearchContext context) {
...@@ -174,10 +173,10 @@ public class WFSystemResource { ...@@ -174,10 +173,10 @@ public class WFSystemResource {
.body(list); .body(list);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFSystem-Default-all')")
@ApiOperation(value = "searchDEFAULT", tags = {"WFSystem" } ,notes = "searchDEFAULT") @ApiOperation(value = "searchDEFAULT", tags = {"WFSystem" } ,notes = "searchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfsystems/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfsystems/searchdefault")
public ResponseEntity<Page<WFSystemDTO>> searchDefault(WFSystemSearchContext context) { public ResponseEntity<Page<WFSystemDTO>> searchDefault(@RequestBody WFSystemSearchContext context) {
Page<WFSystem> domains = wfsystemService.searchDefault(context) ; Page<WFSystem> domains = wfsystemService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(wfsystemMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(wfsystemMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
......
...@@ -55,7 +55,7 @@ public class WFUserResource { ...@@ -55,7 +55,7 @@ public class WFUserResource {
@PreAuthorize("hasPermission('Remove',{#wfuser_id,{this.getEntity(),'Sql'}})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Remove-all')")
@ApiOperation(value = "Remove", tags = {"WFUser" }, notes = "Remove") @ApiOperation(value = "Remove", tags = {"WFUser" }, notes = "Remove")
@RequestMapping(method = RequestMethod.DELETE, value = "/wfusers/{wfuser_id}") @RequestMapping(method = RequestMethod.DELETE, value = "/wfusers/{wfuser_id}")
@Transactional @Transactional
...@@ -98,7 +98,7 @@ public class WFUserResource { ...@@ -98,7 +98,7 @@ public class WFUserResource {
@PreAuthorize("hasPermission(#wfuser_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Update-all')")
@ApiOperation(value = "Update", tags = {"WFUser" }, notes = "Update") @ApiOperation(value = "Update", tags = {"WFUser" }, notes = "Update")
@RequestMapping(method = RequestMethod.PUT, value = "/wfusers/{wfuser_id}") @RequestMapping(method = RequestMethod.PUT, value = "/wfusers/{wfuser_id}")
@Transactional @Transactional
...@@ -110,7 +110,7 @@ public class WFUserResource { ...@@ -110,7 +110,7 @@ public class WFUserResource {
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasPermission(#wfuser_id,'Update',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Update-all')")
@ApiOperation(value = "UpdateBatch", tags = {"WFUser" }, notes = "UpdateBatch") @ApiOperation(value = "UpdateBatch", tags = {"WFUser" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/wfusers/batch") @RequestMapping(method = RequestMethod.PUT, value = "/wfusers/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFUserDTO> wfuserdtos) { public ResponseEntity<Boolean> updateBatch(@RequestBody List<WFUserDTO> wfuserdtos) {
...@@ -121,7 +121,7 @@ public class WFUserResource { ...@@ -121,7 +121,7 @@ public class WFUserResource {
@PreAuthorize("hasPermission(#wfuser_id,'Get',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Get-all')")
@ApiOperation(value = "Get", tags = {"WFUser" }, notes = "Get") @ApiOperation(value = "Get", tags = {"WFUser" }, notes = "Get")
@RequestMapping(method = RequestMethod.GET, value = "/wfusers/{wfuser_id}") @RequestMapping(method = RequestMethod.GET, value = "/wfusers/{wfuser_id}")
public ResponseEntity<WFUserDTO> get(@PathVariable("wfuser_id") String wfuser_id) { public ResponseEntity<WFUserDTO> get(@PathVariable("wfuser_id") String wfuser_id) {
...@@ -133,7 +133,7 @@ public class WFUserResource { ...@@ -133,7 +133,7 @@ public class WFUserResource {
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Create-all')")
@ApiOperation(value = "Create", tags = {"WFUser" }, notes = "Create") @ApiOperation(value = "Create", tags = {"WFUser" }, notes = "Create")
@RequestMapping(method = RequestMethod.POST, value = "/wfusers") @RequestMapping(method = RequestMethod.POST, value = "/wfusers")
@Transactional @Transactional
...@@ -143,8 +143,7 @@ public class WFUserResource { ...@@ -143,8 +143,7 @@ public class WFUserResource {
WFUserDTO dto = wfuserMapping.toDto(domain); WFUserDTO dto = wfuserMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(dto); return ResponseEntity.status(HttpStatus.OK).body(dto);
} }
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Create-all')")
@PreAuthorize("hasPermission('','Create',{this.getEntity(),'Sql'})")
@ApiOperation(value = "createBatch", tags = {"WFUser" }, notes = "createBatch") @ApiOperation(value = "createBatch", tags = {"WFUser" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/wfusers/batch") @RequestMapping(method = RequestMethod.POST, value = "/wfusers/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<WFUserDTO> wfuserdtos) { public ResponseEntity<Boolean> createBatch(@RequestBody List<WFUserDTO> wfuserdtos) {
...@@ -161,7 +160,7 @@ public class WFUserResource { ...@@ -161,7 +160,7 @@ public class WFUserResource {
return ResponseEntity.status(HttpStatus.OK).body(wfuserService.checkKey(wfuserMapping.toDomain(wfuserdto))); return ResponseEntity.status(HttpStatus.OK).body(wfuserService.checkKey(wfuserMapping.toDomain(wfuserdto)));
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Default-all')")
@ApiOperation(value = "fetchDEFAULT", tags = {"WFUser" } ,notes = "fetchDEFAULT") @ApiOperation(value = "fetchDEFAULT", tags = {"WFUser" } ,notes = "fetchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfusers/fetchdefault") @RequestMapping(method= RequestMethod.GET , value="/wfusers/fetchdefault")
public ResponseEntity<List<WFUserDTO>> fetchDefault(WFUserSearchContext context) { public ResponseEntity<List<WFUserDTO>> fetchDefault(WFUserSearchContext context) {
...@@ -174,10 +173,10 @@ public class WFUserResource { ...@@ -174,10 +173,10 @@ public class WFUserResource {
.body(list); .body(list);
} }
@PreAuthorize("hasPermission('Get',{#context,'Default',this.getEntity(),'Sql'})") @PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzwf-WFUser-Default-all')")
@ApiOperation(value = "searchDEFAULT", tags = {"WFUser" } ,notes = "searchDEFAULT") @ApiOperation(value = "searchDEFAULT", tags = {"WFUser" } ,notes = "searchDEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/wfusers/searchdefault") @RequestMapping(method= RequestMethod.POST , value="/wfusers/searchdefault")
public ResponseEntity<Page<WFUserDTO>> searchDefault(WFUserSearchContext context) { public ResponseEntity<Page<WFUserDTO>> searchDefault(@RequestBody WFUserSearchContext context) {
Page<WFUser> domains = wfuserService.searchDefault(context) ; Page<WFUser> domains = wfuserService.searchDefault(context) ;
return ResponseEntity.status(HttpStatus.OK) return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(wfuserMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements())); .body(new PageImpl(wfuserMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
......
...@@ -85,5 +85,10 @@ ...@@ -85,5 +85,10 @@
<artifactId>springfox-swagger-ui</artifactId> <artifactId>springfox-swagger-ui</artifactId>
</dependency> </dependency>
<dependency>
<groupId>io.github.openfeign</groupId>
<artifactId>feign-httpclient</artifactId>
</dependency>
</dependencies> </dependencies>
</project> </project>
...@@ -32,11 +32,11 @@ public class DEFieldDefaultValueAspect ...@@ -32,11 +32,11 @@ public class DEFieldDefaultValueAspect
* @param point * @param point
* @throws Exception * @throws Exception
*/ */
@Before(value = "execution(* com.cntmtech.support.core.*.service.*.create(..))") @Before(value = "execution(* cn.ibizlab.core.*.service.*.create(..))")
public void BeforeCreate(JoinPoint point) throws Exception { public void BeforeCreate(JoinPoint point) throws Exception {
fillDEFieldDefaultValue(point); fillDEFieldDefaultValue(point);
} }
@Before(value = "execution(* com.cntmtech.support.core.*.service.*.createBatch(..))") @Before(value = "execution(* cn.ibizlab.core.*.service.*.createBatch(..))")
public void BeforeCreateBatch(JoinPoint point) throws Exception { public void BeforeCreateBatch(JoinPoint point) throws Exception {
fillDEFieldDefaultValue(point); fillDEFieldDefaultValue(point);
} }
...@@ -46,11 +46,11 @@ public class DEFieldDefaultValueAspect ...@@ -46,11 +46,11 @@ public class DEFieldDefaultValueAspect
* @param point * @param point
* @throws Exception * @throws Exception
*/ */
@Before(value = "execution(* com.cntmtech.support.core.*.service.*.update(..))") @Before(value = "execution(* cn.ibizlab.core.*.service.*.update(..))")
public void BeforeUpdate(JoinPoint point) throws Exception { public void BeforeUpdate(JoinPoint point) throws Exception {
fillDEFieldDefaultValue(point); fillDEFieldDefaultValue(point);
} }
@Before(value = "execution(* com.cntmtech.support.core.*.service.*.updateBatch(..))") @Before(value = "execution(* cn.ibizlab.core.*.service.*.updateBatch(..))")
public void BeforeUpdateBatch(JoinPoint point) throws Exception { public void BeforeUpdateBatch(JoinPoint point) throws Exception {
fillDEFieldDefaultValue(point); fillDEFieldDefaultValue(point);
} }
...@@ -60,11 +60,11 @@ public class DEFieldDefaultValueAspect ...@@ -60,11 +60,11 @@ public class DEFieldDefaultValueAspect
* @param point * @param point
* @throws Exception * @throws Exception
*/ */
@Before(value = "execution(* com.cntmtech.support.core.*.service.*.save(..))") @Before(value = "execution(* cn.ibizlab.core.*.service.*.save(..))")
public void BeforeSave(JoinPoint point) throws Exception { public void BeforeSave(JoinPoint point) throws Exception {
fillDEFieldDefaultValue(point); fillDEFieldDefaultValue(point);
} }
@Before(value = "execution(* com.cntmtech.support.core.*.service.*.saveBatch(..))") @Before(value = "execution(* cn.ibizlab.core.*.service.*.saveBatch(..))")
public void BeforeSaveBatch(JoinPoint point) throws Exception { public void BeforeSaveBatch(JoinPoint point) throws Exception {
fillDEFieldDefaultValue(point); fillDEFieldDefaultValue(point);
} }
......
...@@ -111,4 +111,6 @@ public class IBZUSER implements Serializable{ ...@@ -111,4 +111,6 @@ public class IBZUSER implements Serializable{
@Size(min = 0, max = 500, message = "[备注]长度必须在[500]以内!") @Size(min = 0, max = 500, message = "[备注]长度必须在[500]以内!")
private String memo; private String memo;
private int superuser;
} }
\ No newline at end of file
...@@ -7,6 +7,7 @@ import com.fasterxml.jackson.annotation.JsonProperty; ...@@ -7,6 +7,7 @@ import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data; import lombok.Data;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.data.domain.PageRequest; import org.springframework.data.domain.PageRequest;
import com.fasterxml.jackson.annotation.JsonIgnore;
import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Pageable;
import org.springframework.data.domain.Sort; import org.springframework.data.domain.Sort;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
...@@ -54,6 +55,7 @@ public class SearchContextBase implements ISearchContext{ ...@@ -54,6 +55,7 @@ public class SearchContextBase implements ISearchContext{
/** /**
* 排序对象 * 排序对象
*/ */
@JsonIgnore
public Sort pageSort; public Sort pageSort;
/** /**
* 工作流步骤标识 * 工作流步骤标识
......
...@@ -6,13 +6,11 @@ import lombok.AllArgsConstructor; ...@@ -6,13 +6,11 @@ import lombok.AllArgsConstructor;
import lombok.Data; import lombok.Data;
import org.springframework.security.core.GrantedAuthority; import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.context.SecurityContextHolder; import org.springframework.security.core.context.SecurityContextHolder;
import org.springframework.security.core.authority.SimpleGrantedAuthority;
import org.springframework.security.core.userdetails.UserDetails; import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.util.ObjectUtils; import org.springframework.util.ObjectUtils;
import java.util.Map;
import java.util.HashMap;
import java.sql.Timestamp; import java.sql.Timestamp;
import java.util.Collection; import java.util.*;
import java.util.Set;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
@Data @Data
...@@ -58,8 +56,8 @@ public class AuthenticationUser implements UserDetails ...@@ -58,8 +56,8 @@ public class AuthenticationUser implements UserDetails
private String memo; private String memo;
private Map <String,Object> sessionParams; private Map <String,Object> sessionParams;
@JsonIgnore @JsonIgnore
private Collection<GrantedAuthority> authorities; private Collection<GrantedAuthority> authorities;
@JsonIgnore
private int superuser; private int superuser;
private JSONObject permissionList; private JSONObject permissionList;
private String orglevel;//单位级别 private String orglevel;//单位级别
...@@ -144,4 +142,15 @@ public class AuthenticationUser implements UserDetails ...@@ -144,4 +142,15 @@ public class AuthenticationUser implements UserDetails
else else
return new HashMap<>(); return new HashMap<>();
} }
public Collection<GrantedAuthority> getAuthorities() {
if(authorities==null && permissionList !=null){
if(permissionList.getJSONArray("authorities")!=null){
authorities=new ArrayList<>();
permissionList.getJSONArray("authorities").
forEach(item->authorities.add(new SimpleGrantedAuthority(String.valueOf(item))));
}
}
return authorities;
}
} }
...@@ -12,7 +12,7 @@ import com.alibaba.fastjson.JSONObject; ...@@ -12,7 +12,7 @@ import com.alibaba.fastjson.JSONObject;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression; import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression;
import org.springframework.security.core.authority.AuthorityUtils;
/** /**
* 实体[IBZUSER] 服务对象接口实现 * 实体[IBZUSER] 服务对象接口实现
*/ */
...@@ -44,6 +44,8 @@ public class SimpleUserService implements AuthenticationUserService{ ...@@ -44,6 +44,8 @@ public class SimpleUserService implements AuthenticationUserService{
user.setOrgid(domains); user.setOrgid(domains);
user.setOrgcode(domains); user.setOrgcode(domains);
user.setOrgname(domains); user.setOrgname(domains);
user.setSuperuser(1);
user.setAuthorities(AuthorityUtils.createAuthorityList("ROLE_SUPERADMIN"));
return user; return user;
} }
......
...@@ -63,6 +63,8 @@ mybatis-plus: ...@@ -63,6 +63,8 @@ mybatis-plus:
#阿里sentinel熔断器 #阿里sentinel熔断器
feign: feign:
httpclient:
enabled: true
sentinel: sentinel:
enabled: true enabled: true
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册