mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-09-23 13:56:39 +08:00
v1.0.5 修复权限保存按钮的显示
This commit is contained in:
parent
8c3c2735ba
commit
bcc376e7bc
@ -38,7 +38,6 @@
|
||||
<oss.version>2.7.0</oss.version>
|
||||
<qiniu.version>[7.2.0, 7.2.99]</qiniu.version>
|
||||
<fileupload.version>1.3.1</fileupload.version>
|
||||
<fastjson.version>1.2.9</fastjson.version>
|
||||
<jjwt.version>0.9.0</jjwt.version>
|
||||
<openhtml.version>0.0.1-RC11</openhtml.version>
|
||||
<hibernate-validator-version>6.0.2.Final</hibernate-validator-version>
|
||||
@ -485,11 +484,6 @@
|
||||
</resources>
|
||||
<pluginManagement>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>pl.project13.maven</groupId>
|
||||
<artifactId>git-commit-id-plugin</artifactId>
|
||||
<version>2.2.4</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
|
@ -356,32 +356,6 @@
|
||||
<testFailureIgnore>true</testFailureIgnore>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>pl.project13.maven</groupId>
|
||||
<artifactId>git-commit-id-plugin</artifactId>
|
||||
<version>2.2.4</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>get-the-git-infos</id>
|
||||
<goals>
|
||||
<goal>revision</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
<configuration>
|
||||
<dotGitDirectory>${project.basedir}/.git</dotGitDirectory>
|
||||
<prefix>git</prefix>
|
||||
<verbose>false</verbose>
|
||||
<generateGitPropertiesFile>true</generateGitPropertiesFile>
|
||||
<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>
|
||||
<format>json</format>
|
||||
<gitDescribe>
|
||||
<skip>false</skip>
|
||||
<always>false</always>
|
||||
<dirty>-dirty</dirty>
|
||||
</gitDescribe>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
@ -46,7 +46,7 @@ public class PrivilegeController {
|
||||
|
||||
@ApiOperation(value = "查询所有菜单项")
|
||||
@PostMapping("/privilege/menu/queryAll")
|
||||
public ResponseDTO<List<PrivilegeMenuListVO>> queryAll() {
|
||||
public ResponseDTO<List<PrivilegeMenuVO>> queryAll() {
|
||||
return privilegeService.menuQueryAll();
|
||||
}
|
||||
|
||||
|
@ -3,6 +3,7 @@ package com.gangquan360.smartadmin.module.privilege.domain.dto;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -16,7 +17,7 @@ import java.util.List;
|
||||
* @since JDK1.8
|
||||
*/
|
||||
@Data
|
||||
public class PrivilegeMenuListVO {
|
||||
public class PrivilegeMenuVO {
|
||||
|
||||
@ApiModelProperty("菜单名")
|
||||
private String menuName;
|
||||
@ -30,8 +31,8 @@ public class PrivilegeMenuListVO {
|
||||
@ApiModelProperty("顺序")
|
||||
private Integer sort;
|
||||
|
||||
@ApiModelProperty("子菜单列表")
|
||||
private List<PrivilegeMenuListVO> menuList;
|
||||
@ApiModelProperty("前端路由path")
|
||||
private String url;
|
||||
|
||||
|
||||
}
|
@ -6,7 +6,6 @@ import com.gangquan360.smartadmin.module.privilege.dao.PrivilegeDao;
|
||||
import com.gangquan360.smartadmin.module.privilege.domain.dto.*;
|
||||
import com.gangquan360.smartadmin.module.privilege.domain.entity.PrivilegeEntity;
|
||||
import com.gangquan360.smartadmin.module.role.roleprivilege.RolePrivilegeDao;
|
||||
import com.gangquan360.smartadmin.util.SmartBeanUtil;
|
||||
import com.google.common.collect.Lists;
|
||||
import org.apache.commons.collections.CollectionUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@ -140,18 +139,19 @@ public class PrivilegeService {
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public ResponseDTO<List<PrivilegeMenuListVO>> menuQueryAll() {
|
||||
public ResponseDTO<List<PrivilegeMenuVO>> menuQueryAll() {
|
||||
List<PrivilegeEntity> privilegeEntityList = privilegeDao.selectByType(PrivilegeTypeEnum.MENU.getValue());
|
||||
if (CollectionUtils.isEmpty(privilegeEntityList)) {
|
||||
return ResponseDTO.succData(Lists.newArrayList());
|
||||
}
|
||||
|
||||
List<PrivilegeMenuListVO> voList = privilegeEntityList.stream().map( e-> {
|
||||
PrivilegeMenuListVO vo = new PrivilegeMenuListVO();
|
||||
List<PrivilegeMenuVO> voList = privilegeEntityList.stream().map(e-> {
|
||||
PrivilegeMenuVO vo = new PrivilegeMenuVO();
|
||||
vo.setMenuKey(e.getKey());
|
||||
vo.setMenuName(e.getName());
|
||||
vo.setParentKey(e.getParentKey());
|
||||
vo.setSort(e.getSort());
|
||||
vo.setUrl(e.getUrl());
|
||||
return vo;
|
||||
}).collect(Collectors.toList());
|
||||
|
||||
|
@ -21,7 +21,6 @@ spring.jackson.serialization.write-dates-as-timestamps=false
|
||||
spring.servlet.multipart.max-file-size=30MB
|
||||
spring.servlet.multipart.max-request-size=30MB
|
||||
file-upload-service.path=/home/upload/
|
||||
file-upload-service.geturl=http://127.0.0.1/smartAdmin/file/
|
||||
|
||||
######################### database #########################
|
||||
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/smart-admin-dev?autoReconnect=true&useServerPreparedStmts=false&rewriteBatchedStatements=true&characterEncoding=UTF-8&useSSL=false&allowMultiQueries=true&serverTimezone=UTC
|
||||
|
@ -21,7 +21,6 @@ spring.jackson.serialization.write-dates-as-timestamps=false
|
||||
spring.servlet.multipart.max-file-size=30MB
|
||||
spring.servlet.multipart.max-request-size=30MB
|
||||
file-upload-service.path=/home/upload/
|
||||
file-upload-service.geturl=http://172.16.0.145/smartAdmin/file/
|
||||
|
||||
######################### database #########################
|
||||
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/smart-admin-dev?autoReconnect=true&useServerPreparedStmts=false&rewriteBatchedStatements=true&characterEncoding=UTF-8&useSSL=false&allowMultiQueries=true&serverTimezone=UTC
|
||||
|
@ -22,7 +22,6 @@ spring.jackson.serialization.write-dates-as-timestamps=false
|
||||
spring.servlet.multipart.max-file-size=30MB
|
||||
spring.servlet.multipart.max-request-size=30MB
|
||||
file-upload-service.path=/home/upload/smart-admin-file
|
||||
file-upload-service.geturl=http://smartadmin.gangquan360.com/demoAdmin/file/
|
||||
|
||||
######################### database #########################
|
||||
spring.datasource.url=jdbc:mysql://172.16.0.201:3306/smart-admin-prod?autoReconnect=true&useServerPreparedStmts=false&rewriteBatchedStatements=true&characterEncoding=UTF-8&useSSL=false&allowMultiQueries=true
|
||||
|
@ -21,7 +21,6 @@ spring.jackson.serialization.write-dates-as-timestamps=false
|
||||
spring.servlet.multipart.max-file-size=30MB
|
||||
spring.servlet.multipart.max-request-size=30MB
|
||||
file-upload-service.path=/home/upload/
|
||||
file-upload-service.geturl=http://172.16.0.145/smartAdmin/file/
|
||||
|
||||
######################### database #########################
|
||||
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/smart-admin-dev?autoReconnect=true&useServerPreparedStmts=false&rewriteBatchedStatements=true&characterEncoding=UTF-8&useSSL=false&allowMultiQueries=true&serverTimezone=UTC
|
||||
|
@ -241,7 +241,8 @@ export default {
|
||||
isChange =
|
||||
serverMenu.menuName !== menu.menuName ||
|
||||
serverMenu.menuKey !== menu.menuKey ||
|
||||
serverMenu.parentKey !== menu.parentKey;
|
||||
serverMenu.parentKey !== menu.parentKey||
|
||||
serverMenu.url !== menu.url;
|
||||
} else {
|
||||
isChange = true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user