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

zhouweidong@lab.ibiz5.com 部署微服务应用

上级 4c8af2d8
......@@ -23,12 +23,11 @@
</template>
<template v-if="getColumnState('username')">
<el-table-column show-overflow-tooltip :prop="'username'" :label="$t('entities.sysauthlog.main_grid.columns.username')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.username')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.username')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.username}}</span>
</template>
......@@ -36,12 +35,11 @@
</template>
<template v-if="getColumnState('personname')">
<el-table-column show-overflow-tooltip :prop="'personname'" :label="$t('entities.sysauthlog.main_grid.columns.personname')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.personname')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.personname')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.personname}}</span>
</template>
......@@ -49,12 +47,11 @@
</template>
<template v-if="getColumnState('authtime')">
<el-table-column show-overflow-tooltip :prop="'authtime'" :label="$t('entities.sysauthlog.main_grid.columns.authtime')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.authtime')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.authtime')}}
</span>
</template>
<template v-slot="{row,column}">
<app-format-data format="YYYY-MM-DD hh:mm:ss" :data="row.authtime"></app-format-data>
</template>
......@@ -62,12 +59,11 @@
</template>
<template v-if="getColumnState('authcode')">
<el-table-column show-overflow-tooltip :prop="'authcode'" :label="$t('entities.sysauthlog.main_grid.columns.authcode')" :width="100" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.authcode')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.authcode')}}
</span>
</template>
<template v-slot="{row,column}">
<template >
<codelist :value="row.authcode" tag='CLAuthCode' codelistType='STATIC' ></codelist>
......@@ -77,12 +73,11 @@
</template>
<template v-if="getColumnState('ipaddr')">
<el-table-column show-overflow-tooltip :prop="'ipaddr'" :label="$t('entities.sysauthlog.main_grid.columns.ipaddr')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.ipaddr')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.ipaddr')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.ipaddr}}</span>
</template>
......@@ -90,12 +85,11 @@
</template>
<template v-if="getColumnState('macaddr')">
<el-table-column show-overflow-tooltip :prop="'macaddr'" :label="$t('entities.sysauthlog.main_grid.columns.macaddr')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.macaddr')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.macaddr')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.macaddr}}</span>
</template>
......@@ -103,12 +97,11 @@
</template>
<template v-if="getColumnState('useragent')">
<el-table-column show-overflow-tooltip :prop="'useragent'" :label="$t('entities.sysauthlog.main_grid.columns.useragent')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.useragent')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.useragent')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.useragent}}</span>
</template>
......@@ -116,12 +109,11 @@
</template>
<template v-if="getColumnState('domain')">
<el-table-column show-overflow-tooltip :prop="'domain'" :label="$t('entities.sysauthlog.main_grid.columns.domain')" :width="100" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.domain')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysauthlog.main_grid.columns.domain')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.domain}}</span>
</template>
......
......@@ -23,12 +23,11 @@
</template>
<template v-if="getColumnState('sys_permissionid')">
<el-table-column show-overflow-tooltip :prop="'sys_permissionid'" :label="$t('entities.syspermission.main_grid.columns.sys_permissionid')" :width="150" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.syspermission.main_grid.columns.sys_permissionid')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.syspermission.main_grid.columns.sys_permissionid')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.sys_permissionid}}</span>
</template>
......@@ -36,12 +35,11 @@
</template>
<template v-if="getColumnState('sys_permissionname')">
<el-table-column show-overflow-tooltip :prop="'sys_permissionname'" :label="$t('entities.syspermission.main_grid.columns.sys_permissionname')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.syspermission.main_grid.columns.sys_permissionname')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.syspermission.main_grid.columns.sys_permissionname')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.sys_permissionname}}</span>
</template>
......
......@@ -23,12 +23,11 @@
</template>
<template v-if="getColumnState('sys_rolename')">
<el-table-column show-overflow-tooltip :prop="'sys_rolename'" :label="$t('entities.sysrolepermission.main_grid.columns.sys_rolename')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrolepermission.main_grid.columns.sys_rolename')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrolepermission.main_grid.columns.sys_rolename')}}
</span>
</template>
<template v-slot="{row,column}">
<app-column-link deKeyField='sysrole' :context="JSON.parse(JSON.stringify(context))" :viewparams="JSON.parse(JSON.stringify(viewparams))" :data="row" :linkview="{viewname: 'sys-roleredirect-view', height: 0,width: 0,title: $t('entities.sysrole.views.redirectview.title'),placement: '', isRedirectView: true,deResParameters: [
]
......@@ -43,12 +42,11 @@
</template>
<template v-if="getColumnState('sys_permissionname')">
<el-table-column show-overflow-tooltip :prop="'sys_permissionname'" :label="$t('entities.sysrolepermission.main_grid.columns.sys_permissionname')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrolepermission.main_grid.columns.sys_permissionname')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrolepermission.main_grid.columns.sys_permissionname')}}
</span>
</template>
<template v-slot="{row,column}">
<app-column-link deKeyField='syspermission' :context="JSON.parse(JSON.stringify(context))" :viewparams="JSON.parse(JSON.stringify(viewparams))" :data="row" :linkview="{viewname: 'sys-permissionredirect-view', height: 0,width: 0,title: $t('entities.syspermission.views.redirectview.title'),placement: '', isRedirectView: true,deResParameters: [
]
......@@ -63,12 +61,11 @@
</template>
<template v-if="getColumnState('updatedate')">
<el-table-column show-overflow-tooltip :prop="'updatedate'" :label="$t('entities.sysrolepermission.main_grid.columns.updatedate')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrolepermission.main_grid.columns.updatedate')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrolepermission.main_grid.columns.updatedate')}}
</span>
</template>
<template v-slot="{row,column}">
<app-format-data format="YYYY-MM-DD hh:mm:ss" :data="row.updatedate"></app-format-data>
</template>
......
......@@ -23,12 +23,11 @@
</template>
<template v-if="getColumnState('sys_roleid')">
<el-table-column show-overflow-tooltip :prop="'sys_roleid'" :label="$t('entities.sysrole.main_grid.columns.sys_roleid')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.sys_roleid')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.sys_roleid')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.sys_roleid}}</span>
</template>
......@@ -36,12 +35,11 @@
</template>
<template v-if="getColumnState('sys_rolename')">
<el-table-column show-overflow-tooltip :prop="'sys_rolename'" :label="$t('entities.sysrole.main_grid.columns.sys_rolename')" :width="350" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.sys_rolename')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.sys_rolename')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.sys_rolename}}</span>
</template>
......@@ -49,12 +47,11 @@
</template>
<template v-if="getColumnState('memo')">
<el-table-column show-overflow-tooltip :prop="'memo'" :label="$t('entities.sysrole.main_grid.columns.memo')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.memo')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.memo')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.memo}}</span>
</template>
......@@ -62,12 +59,11 @@
</template>
<template v-if="getColumnState('updatedate')">
<el-table-column show-overflow-tooltip :prop="'updatedate'" :label="$t('entities.sysrole.main_grid.columns.updatedate')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.updatedate')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysrole.main_grid.columns.updatedate')}}
</span>
</template>
<template v-slot="{row,column}">
<app-format-data format="YYYY-MM-DD hh:mm:ss" :data="row.updatedate"></app-format-data>
</template>
......
......@@ -23,12 +23,11 @@
</template>
<template v-if="getColumnState('sys_username')">
<el-table-column show-overflow-tooltip :prop="'sys_username'" :label="$t('entities.sysuserrole.main_grid.columns.sys_username')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuserrole.main_grid.columns.sys_username')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuserrole.main_grid.columns.sys_username')}}
</span>
</template>
<template v-slot="{row,column}">
<app-column-link deKeyField='sysuser' :context="JSON.parse(JSON.stringify(context))" :viewparams="JSON.parse(JSON.stringify(viewparams))" :data="row" :linkview="{viewname: 'sys-userredirect-view', height: 0,width: 0,title: $t('entities.sysuser.views.redirectview.title'),placement: '', isRedirectView: true,deResParameters: [
]
......@@ -43,12 +42,11 @@
</template>
<template v-if="getColumnState('sys_rolename')">
<el-table-column show-overflow-tooltip :prop="'sys_rolename'" :label="$t('entities.sysuserrole.main_grid.columns.sys_rolename')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuserrole.main_grid.columns.sys_rolename')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuserrole.main_grid.columns.sys_rolename')}}
</span>
</template>
<template v-slot="{row,column}">
<app-column-link deKeyField='sysrole' :context="JSON.parse(JSON.stringify(context))" :viewparams="JSON.parse(JSON.stringify(viewparams))" :data="row" :linkview="{viewname: 'sys-roleredirect-view', height: 0,width: 0,title: $t('entities.sysrole.views.redirectview.title'),placement: '', isRedirectView: true,deResParameters: [
]
......@@ -63,12 +61,11 @@
</template>
<template v-if="getColumnState('updatedate')">
<el-table-column show-overflow-tooltip :prop="'updatedate'" :label="$t('entities.sysuserrole.main_grid.columns.updatedate')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuserrole.main_grid.columns.updatedate')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuserrole.main_grid.columns.updatedate')}}
</span>
</template>
<template v-slot="{row,column}">
<app-format-data format="YYYY-MM-DD hh:mm:ss" :data="row.updatedate"></app-format-data>
</template>
......
......@@ -23,12 +23,11 @@
</template>
<template v-if="getColumnState('userid')">
<el-table-column show-overflow-tooltip :prop="'userid'" :label="$t('entities.sysuser.main_grid.columns.userid')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuser.main_grid.columns.userid')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuser.main_grid.columns.userid')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.userid}}</span>
</template>
......@@ -36,12 +35,11 @@
</template>
<template v-if="getColumnState('username')">
<el-table-column show-overflow-tooltip :prop="'username'" :label="$t('entities.sysuser.main_grid.columns.username')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuser.main_grid.columns.username')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuser.main_grid.columns.username')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.username}}</span>
</template>
......@@ -49,12 +47,11 @@
</template>
<template v-if="getColumnState('personname')">
<el-table-column show-overflow-tooltip :prop="'personname'" :label="$t('entities.sysuser.main_grid.columns.personname')" :width="250" :align="'left'" :sortable="'custom'">
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuser.main_grid.columns.personname')}}
</span>
</template>
<template v-slot:header="{column}">
<span class="column-header ">
{{$t('entities.sysuser.main_grid.columns.personname')}}
</span>
</template>
<template v-slot="{row,column}">
<span>{{row.personname}}</span>
</template>
......
......@@ -37,6 +37,11 @@
git clone -b master $para2 ibzuaa/
export NODE_OPTIONS=--max-old-space-size=4096
cd ibzuaa/
mvn clean package -Pweb
cd ibzuaa-app/ibzuaa-app-web
mvn -Pweb docker:build
mvn -Pweb docker:push
docker -H $para1 stack deploy --compose-file=src/main/docker/ibzuaa-app-web.yaml ibzlab-rt --with-registry-auth
</command>
</hudson.tasks.Shell>
</builders>
......
......@@ -9,6 +9,6 @@ CMD echo "The application will start in ${IBZ_SLEEP}s..." && \
sleep ${IBZ_SLEEP} && \
java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /ibzuaa-app-web.jar
EXPOSE 8080
EXPOSE 30002
ADD ibzuaa-app-web.jar /ibzuaa-app-web.jar
......@@ -3,9 +3,23 @@ services:
ibzuaa-app-web:
image: registry.cn-shanghai.aliyuncs.com/ibizsys/ibzuaa-app-web:latest
ports:
- "8080:8080"
- "30002:30002"
networks:
- agent_network
environment:
- SPRING_CLOUD_NACOS_DISCOVERY_IP=172.16.180.237
- SERVER_PORT=30002
- 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
- ABC=1
- DEC=2
deploy:
mode: replicated
replicas: 1
......
......@@ -22,6 +22,7 @@ import org.springframework.data.domain.Pageable;
import org.springframework.util.StringUtils;
import org.springframework.context.annotation.Lazy;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.security.access.prepost.PostAuthorize;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiResponse;
......@@ -47,7 +48,6 @@ public class SysAuthLogResource {
public SysAuthLogDTO permissionDTO=new SysAuthLogDTO();
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysAuthLog-GetDraft-all')")
@ApiOperation(value = "GetDraft", tags = {"SysAuthLog" }, notes = "GetDraft")
@RequestMapping(method = RequestMethod.GET, value = "/sysauthlogs/getdraft")
public ResponseEntity<SysAuthLogDTO> getDraft() {
......@@ -59,14 +59,14 @@ public class SysAuthLogResource {
@RequestMapping(method = RequestMethod.PUT, value = "/sysauthlogs/{sysauthlog_id}")
@Transactional
public ResponseEntity<SysAuthLogDTO> update(@PathVariable("sysauthlog_id") String sysauthlog_id, @RequestBody SysAuthLogDTO sysauthlogdto) {
SysAuthLog domain = sysauthlogMapping.toDomain(sysauthlogdto);
domain.setLogid(sysauthlog_id);
sysauthlogService.update(domain);
SysAuthLogDTO dto = sysauthlogMapping.toDto(domain);
SysAuthLog domain = sysauthlogMapping.toDomain(sysauthlogdto);
domain .setLogid(sysauthlog_id);
sysauthlogService.update(domain );
SysAuthLogDTO dto = sysauthlogMapping.toDto(domain );
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Update',{'Sql',this.sysauthlogMapping,#sysauthlogdtos})")
//@PreAuthorize("hasPermission('Update',{'Sql',this.sysauthlogMapping,#sysauthlogdtos})")
@ApiOperation(value = "UpdateBatch", tags = {"SysAuthLog" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/sysauthlogs/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<SysAuthLogDTO> sysauthlogdtos) {
......@@ -82,7 +82,7 @@ public class SysAuthLogResource {
return ResponseEntity.status(HttpStatus.OK).body(sysauthlogService.remove(sysauthlog_id));
}
@PreAuthorize("hasPermission('Remove',{'Sql',this.sysauthlogMapping,this.permissionDTO,#ids})")
//@PreAuthorize("hasPermission('Remove',{'Sql',this.sysauthlogMapping,this.permissionDTO,#ids})")
@ApiOperation(value = "RemoveBatch", tags = {"SysAuthLog" }, notes = "RemoveBatch")
@RequestMapping(method = RequestMethod.DELETE, value = "/sysauthlogs/batch")
public ResponseEntity<Boolean> removeBatch(@RequestBody List<String> ids) {
......@@ -101,7 +101,7 @@ public class SysAuthLogResource {
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Create',{'Sql',this.sysauthlogMapping,#sysauthlogdtos})")
//@PreAuthorize("hasPermission('Create',{'Sql',this.sysauthlogMapping,#sysauthlogdtos})")
@ApiOperation(value = "createBatch", tags = {"SysAuthLog" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/sysauthlogs/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<SysAuthLogDTO> sysauthlogdtos) {
......@@ -109,7 +109,6 @@ public class SysAuthLogResource {
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysAuthLog-CheckKey-all')")
@ApiOperation(value = "CheckKey", tags = {"SysAuthLog" }, notes = "CheckKey")
@RequestMapping(method = RequestMethod.POST, value = "/sysauthlogs/checkkey")
public ResponseEntity<Boolean> checkKey(@RequestBody SysAuthLogDTO sysauthlogdto) {
......@@ -132,7 +131,7 @@ public class SysAuthLogResource {
return ResponseEntity.status(HttpStatus.OK).body(sysauthlogService.save(sysauthlogMapping.toDomain(sysauthlogdto)));
}
@PreAuthorize("hasPermission('Save',{'Sql',this.sysauthlogMapping,#sysauthlogdtos})")
//@PreAuthorize("hasPermission('Save',{'Sql',this.sysauthlogMapping,#sysauthlogdtos})")
@ApiOperation(value = "SaveBatch", tags = {"SysAuthLog" }, notes = "SaveBatch")
@RequestMapping(method = RequestMethod.POST, value = "/sysauthlogs/savebatch")
public ResponseEntity<Boolean> saveBatch(@RequestBody List<SysAuthLogDTO> sysauthlogdtos) {
......
......@@ -22,6 +22,7 @@ import org.springframework.data.domain.Pageable;
import org.springframework.util.StringUtils;
import org.springframework.context.annotation.Lazy;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.security.access.prepost.PostAuthorize;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiResponse;
......@@ -54,7 +55,7 @@ public class SysPermissionResource {
return ResponseEntity.status(HttpStatus.OK).body(syspermissionService.save(syspermissionMapping.toDomain(syspermissiondto)));
}
@PreAuthorize("hasPermission('Save',{'Sql',this.syspermissionMapping,#syspermissiondtos})")
//@PreAuthorize("hasPermission('Save',{'Sql',this.syspermissionMapping,#syspermissiondtos})")
@ApiOperation(value = "SaveBatch", tags = {"SysPermission" }, notes = "SaveBatch")
@RequestMapping(method = RequestMethod.POST, value = "/syspermissions/savebatch")
public ResponseEntity<Boolean> saveBatch(@RequestBody List<SysPermissionDTO> syspermissiondtos) {
......@@ -62,7 +63,6 @@ public class SysPermissionResource {
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysPermission-GetDraft-all')")
@ApiOperation(value = "GetDraft", tags = {"SysPermission" }, notes = "GetDraft")
@RequestMapping(method = RequestMethod.GET, value = "/syspermissions/getdraft")
public ResponseEntity<SysPermissionDTO> getDraft() {
......@@ -77,7 +77,7 @@ public class SysPermissionResource {
return ResponseEntity.status(HttpStatus.OK).body(syspermissionService.remove(syspermission_id));
}
@PreAuthorize("hasPermission('Remove',{'Sql',this.syspermissionMapping,this.permissionDTO,#ids})")
//@PreAuthorize("hasPermission('Remove',{'Sql',this.syspermissionMapping,this.permissionDTO,#ids})")
@ApiOperation(value = "RemoveBatch", tags = {"SysPermission" }, notes = "RemoveBatch")
@RequestMapping(method = RequestMethod.DELETE, value = "/syspermissions/batch")
public ResponseEntity<Boolean> removeBatch(@RequestBody List<String> ids) {
......@@ -90,14 +90,14 @@ public class SysPermissionResource {
@RequestMapping(method = RequestMethod.PUT, value = "/syspermissions/{syspermission_id}")
@Transactional
public ResponseEntity<SysPermissionDTO> update(@PathVariable("syspermission_id") String syspermission_id, @RequestBody SysPermissionDTO syspermissiondto) {
SysPermission domain = syspermissionMapping.toDomain(syspermissiondto);
domain.setPermissionid(syspermission_id);
syspermissionService.update(domain);
SysPermissionDTO dto = syspermissionMapping.toDto(domain);
SysPermission domain = syspermissionMapping.toDomain(syspermissiondto);
domain .setPermissionid(syspermission_id);
syspermissionService.update(domain );
SysPermissionDTO dto = syspermissionMapping.toDto(domain );
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Update',{'Sql',this.syspermissionMapping,#syspermissiondtos})")
//@PreAuthorize("hasPermission('Update',{'Sql',this.syspermissionMapping,#syspermissiondtos})")
@ApiOperation(value = "UpdateBatch", tags = {"SysPermission" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/syspermissions/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<SysPermissionDTO> syspermissiondtos) {
......@@ -116,7 +116,7 @@ public class SysPermissionResource {
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Create',{'Sql',this.syspermissionMapping,#syspermissiondtos})")
//@PreAuthorize("hasPermission('Create',{'Sql',this.syspermissionMapping,#syspermissiondtos})")
@ApiOperation(value = "createBatch", tags = {"SysPermission" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/syspermissions/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<SysPermissionDTO> syspermissiondtos) {
......@@ -124,7 +124,6 @@ public class SysPermissionResource {
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysPermission-CheckKey-all')")
@ApiOperation(value = "CheckKey", tags = {"SysPermission" }, notes = "CheckKey")
@RequestMapping(method = RequestMethod.POST, value = "/syspermissions/checkkey")
public ResponseEntity<Boolean> checkKey(@RequestBody SysPermissionDTO syspermissiondto) {
......
......@@ -22,6 +22,7 @@ import org.springframework.data.domain.Pageable;
import org.springframework.util.StringUtils;
import org.springframework.context.annotation.Lazy;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.security.access.prepost.PostAuthorize;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiResponse;
......@@ -54,7 +55,7 @@ public class SysRoleResource {
return ResponseEntity.status(HttpStatus.OK).body(sysroleService.save(sysroleMapping.toDomain(sysroledto)));
}
@PreAuthorize("hasPermission('Save',{'Sql',this.sysroleMapping,#sysroledtos})")
//@PreAuthorize("hasPermission('Save',{'Sql',this.sysroleMapping,#sysroledtos})")
@ApiOperation(value = "SaveBatch", tags = {"SysRole" }, notes = "SaveBatch")
@RequestMapping(method = RequestMethod.POST, value = "/sysroles/savebatch")
public ResponseEntity<Boolean> saveBatch(@RequestBody List<SysRoleDTO> sysroledtos) {
......@@ -67,14 +68,14 @@ public class SysRoleResource {
@RequestMapping(method = RequestMethod.PUT, value = "/sysroles/{sysrole_id}")
@Transactional
public ResponseEntity<SysRoleDTO> update(@PathVariable("sysrole_id") String sysrole_id, @RequestBody SysRoleDTO sysroledto) {
SysRole domain = sysroleMapping.toDomain(sysroledto);
domain.setRoleid(sysrole_id);
sysroleService.update(domain);
SysRoleDTO dto = sysroleMapping.toDto(domain);
SysRole domain = sysroleMapping.toDomain(sysroledto);
domain .setRoleid(sysrole_id);
sysroleService.update(domain );
SysRoleDTO dto = sysroleMapping.toDto(domain );
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Update',{'Sql',this.sysroleMapping,#sysroledtos})")
//@PreAuthorize("hasPermission('Update',{'Sql',this.sysroleMapping,#sysroledtos})")
@ApiOperation(value = "UpdateBatch", tags = {"SysRole" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/sysroles/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<SysRoleDTO> sysroledtos) {
......@@ -93,7 +94,7 @@ public class SysRoleResource {
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Create',{'Sql',this.sysroleMapping,#sysroledtos})")
//@PreAuthorize("hasPermission('Create',{'Sql',this.sysroleMapping,#sysroledtos})")
@ApiOperation(value = "createBatch", tags = {"SysRole" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/sysroles/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<SysRoleDTO> sysroledtos) {
......@@ -118,7 +119,7 @@ public class SysRoleResource {
return ResponseEntity.status(HttpStatus.OK).body(sysroleService.remove(sysrole_id));
}
@PreAuthorize("hasPermission('Remove',{'Sql',this.sysroleMapping,this.permissionDTO,#ids})")
//@PreAuthorize("hasPermission('Remove',{'Sql',this.sysroleMapping,this.permissionDTO,#ids})")
@ApiOperation(value = "RemoveBatch", tags = {"SysRole" }, notes = "RemoveBatch")
@RequestMapping(method = RequestMethod.DELETE, value = "/sysroles/batch")
public ResponseEntity<Boolean> removeBatch(@RequestBody List<String> ids) {
......@@ -126,14 +127,12 @@ public class SysRoleResource {
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysRole-GetDraft-all')")
@ApiOperation(value = "GetDraft", tags = {"SysRole" }, notes = "GetDraft")
@RequestMapping(method = RequestMethod.GET, value = "/sysroles/getdraft")
public ResponseEntity<SysRoleDTO> getDraft() {
return ResponseEntity.status(HttpStatus.OK).body(sysroleMapping.toDto(sysroleService.getDraft(new SysRole())));
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysRole-CheckKey-all')")
@ApiOperation(value = "CheckKey", tags = {"SysRole" }, notes = "CheckKey")
@RequestMapping(method = RequestMethod.POST, value = "/sysroles/checkkey")
public ResponseEntity<Boolean> checkKey(@RequestBody SysRoleDTO sysroledto) {
......
......@@ -22,6 +22,7 @@ import org.springframework.data.domain.Pageable;
import org.springframework.util.StringUtils;
import org.springframework.context.annotation.Lazy;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.security.access.prepost.PostAuthorize;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiResponse;
......@@ -55,7 +56,7 @@ public class SysUserResource {
return ResponseEntity.status(HttpStatus.OK).body(sysuserService.remove(sysuser_id));
}
@PreAuthorize("hasPermission('Remove',{'Sql',this.sysuserMapping,this.permissionDTO,#ids})")
//@PreAuthorize("hasPermission('Remove',{'Sql',this.sysuserMapping,this.permissionDTO,#ids})")
@ApiOperation(value = "RemoveBatch", tags = {"SysUser" }, notes = "RemoveBatch")
@RequestMapping(method = RequestMethod.DELETE, value = "/sysusers/batch")
public ResponseEntity<Boolean> removeBatch(@RequestBody List<String> ids) {
......@@ -68,14 +69,14 @@ public class SysUserResource {
@RequestMapping(method = RequestMethod.PUT, value = "/sysusers/{sysuser_id}")
@Transactional
public ResponseEntity<SysUserDTO> update(@PathVariable("sysuser_id") String sysuser_id, @RequestBody SysUserDTO sysuserdto) {
SysUser domain = sysuserMapping.toDomain(sysuserdto);
domain.setUserid(sysuser_id);
sysuserService.update(domain);
SysUserDTO dto = sysuserMapping.toDto(domain);
SysUser domain = sysuserMapping.toDomain(sysuserdto);
domain .setUserid(sysuser_id);
sysuserService.update(domain );
SysUserDTO dto = sysuserMapping.toDto(domain );
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Update',{'Sql',this.sysuserMapping,#sysuserdtos})")
//@PreAuthorize("hasPermission('Update',{'Sql',this.sysuserMapping,#sysuserdtos})")
@ApiOperation(value = "UpdateBatch", tags = {"SysUser" }, notes = "UpdateBatch")
@RequestMapping(method = RequestMethod.PUT, value = "/sysusers/batch")
public ResponseEntity<Boolean> updateBatch(@RequestBody List<SysUserDTO> sysuserdtos) {
......@@ -83,7 +84,6 @@ public class SysUserResource {
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUser-CheckKey-all')")
@ApiOperation(value = "CheckKey", tags = {"SysUser" }, notes = "CheckKey")
@RequestMapping(method = RequestMethod.POST, value = "/sysusers/checkkey")
public ResponseEntity<Boolean> checkKey(@RequestBody SysUserDTO sysuserdto) {
......@@ -106,7 +106,7 @@ public class SysUserResource {
return ResponseEntity.status(HttpStatus.OK).body(sysuserService.save(sysuserMapping.toDomain(sysuserdto)));
}
@PreAuthorize("hasPermission('Save',{'Sql',this.sysuserMapping,#sysuserdtos})")
//@PreAuthorize("hasPermission('Save',{'Sql',this.sysuserMapping,#sysuserdtos})")
@ApiOperation(value = "SaveBatch", tags = {"SysUser" }, notes = "SaveBatch")
@RequestMapping(method = RequestMethod.POST, value = "/sysusers/savebatch")
public ResponseEntity<Boolean> saveBatch(@RequestBody List<SysUserDTO> sysuserdtos) {
......@@ -114,7 +114,6 @@ public class SysUserResource {
return ResponseEntity.status(HttpStatus.OK).body(true);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','ibzuaa-SysUser-GetDraft-all')")
@ApiOperation(value = "GetDraft", tags = {"SysUser" }, notes = "GetDraft")
@RequestMapping(method = RequestMethod.GET, value = "/sysusers/getdraft")
public ResponseEntity<SysUserDTO> getDraft() {
......@@ -132,7 +131,7 @@ public class SysUserResource {
return ResponseEntity.status(HttpStatus.OK).body(dto);
}
@PreAuthorize("hasPermission('Create',{'Sql',this.sysuserMapping,#sysuserdtos})")
//@PreAuthorize("hasPermission('Create',{'Sql',this.sysuserMapping,#sysuserdtos})")
@ApiOperation(value = "createBatch", tags = {"SysUser" }, notes = "createBatch")
@RequestMapping(method = RequestMethod.POST, value = "/sysusers/batch")
public ResponseEntity<Boolean> createBatch(@RequestBody List<SysUserDTO> sysuserdtos) {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册