Commit 475bb004 by zzrdark

1.fix设备模块 生产配置

2.个人信息
parent b242d937
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ChangeListManager">
<list default="true" id="58efcb75-622d-40c1-b8e0-10cd2fb456b4" name="Default Changelist" comment="">
<change afterPath="$PROJECT_DIR$/cneeds-server-authorization/src/main/resources/application-prod.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-authorization/src/main/resources/application-test.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/application-prod.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/css/chunk-113720ab.9d63d053.css" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/app.bacadfa9.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-0b251b6b.c62cffd6.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-113720ab.c13124c4.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-1d606ab9.36c5da6b.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-218bb4cf.2c87854b.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-47af9ee4.a003a3e1.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-636f8118.2d5d0784.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-79a85582.dd8d44e5.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-acf60ff8.f55e1c1c.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-e19c4374.a6d2a75b.js" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-device/src/main/resources/application-prod.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-device/src/main/resources/application-test.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-eureka/src/main/resources/application-prod.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-eureka/src/main/resources/application-test.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/resources/application-prod.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/resources/application-test.yml" afterDir="false" />
<list default="true" id="58efcb75-622d-40c1-b8e0-10cd2fb456b4" name="Default Changelist" comment="1.fix设备模块&#10;2.生产配置">
<change afterPath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/dto/DeviceInfoDto.java" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-logupload/src/main/resources/application-dev.yml" afterDir="false" />
<change afterPath="$PROJECT_DIR$/cneeds-server-logupload/src/main/resources/application.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/dto/DevicesDto.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/dto/DevicesDto.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/vo/DeviceChannelVo.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/vo/DeviceChannelVo.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-data/db/cneeds_server.sql" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-data/db/cneeds_server.sql" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-data/src/main/java/com/mx/cneeds/server/entity/SysUserEntity.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-data/src/main/java/com/mx/cneeds/server/entity/SysUserEntity.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-data/src/main/resources/mapper/SysUserDao.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-data/src/main/resources/mapper/SysUserDao.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-pojo/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-pojo/pom.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/dto/UserDto.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/dto/UserDto.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/vo/UserVo.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-pojo/src/main/java/com/mx/cneeds/common/vo/UserVo.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-common-utils/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-common-utils/pom.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-authorization/build.sh" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-authorization/build.sh" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-authorization/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-authorization/pom.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-authorization/src/main/resources/application.yml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-authorization/src/main/resources/application.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/build.sh" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/build.sh" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-authorization/src/test/java/utils/PasswordEncode.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-authorization/src/test/java/utils/PasswordEncode.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/pom.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/client/DeviceClient.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/client/DeviceClient.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/config/OAuth2ResourceServer.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/config/OAuth2ResourceServer.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/device/DeviceController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/device/DeviceController.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/system/SystemController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/system/SystemController.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/system/UserController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/system/UserController.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/application.yml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/application.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/index.html" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/index.html" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/app.e5fc0d17.js" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-21520446.0ba4244e.js" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-218bb4cf.bbc78c96.js" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-47af9ee4.c1792ef7.js" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-636f8118.9a467c91.js" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-datashow/src/main/resources/statics/static/js/chunk-e19c4374.65d65d64.js" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-device/build.sh" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-device/build.sh" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-device/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-device/pom.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-device/src/main/java/com/mx/cneeds/server/device/service/DeviceInfoService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-device/src/main/java/com/mx/cneeds/server/device/service/DeviceInfoService.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-device/src/main/java/com/mx/cneeds/server/device/service/impl/DeviceInfoServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-device/src/main/java/com/mx/cneeds/server/device/service/impl/DeviceInfoServiceImpl.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-device/src/main/java/com/mx/cneeds/server/device/web/DeviceInfoController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-device/src/main/java/com/mx/cneeds/server/device/web/DeviceInfoController.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-device/src/main/resources/application.yml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-device/src/main/resources/application.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-eureka/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-eureka/pom.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-eureka/src/main/resources/application-prod.yml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-eureka/src/main/resources/application-prod.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-eureka/src/main/resources/application.yml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-eureka/src/main/resources/application.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/build.sh" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/build.sh" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/pom.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/SysFuncService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/SysFuncService.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/SysUserFuncService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/SysUserFuncService.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/SysUserService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/SysUserService.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/impl/SysFuncServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/impl/SysFuncServiceImpl.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/impl/SysUserServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/service/impl/SysUserServiceImpl.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/web/SysUserController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/java/com/mx/cneeds/server/user/web/SysUserController.java" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/resources/application-dev.yml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/resources/application-dev.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/cneeds-server-user/src/main/resources/application.yml" beforeDir="false" afterPath="$PROJECT_DIR$/cneeds-server-user/src/main/resources/application.yml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/pom.xml" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
......@@ -70,6 +68,9 @@
<component name="DefaultGradleProjectSettings">
<option name="isMigrated" value="true" />
</component>
<component name="FavoritesManager">
<favorites_list name="cneeds-server" />
</component>
<component name="FileTemplateManagerImpl">
<option name="RECENT_TEMPLATES">
<list>
......@@ -117,7 +118,7 @@
<property name="SHARE_PROJECT_CONFIGURATION_FILES" value="true" />
<property name="WebServerToolWindowFactoryState" value="false" />
<property name="aspect.path.notification.shown" value="true" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/cneeds-server-user/src/main/resources" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/cneeds-server-logupload/src/main/resources" />
<property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" />
<property name="nodejs_npm_path_reset_for_default_project" value="true" />
<property name="project.structure.last.edited" value="Modules" />
......@@ -128,12 +129,12 @@
<property name="settings.editor.splitter.proportion" value="0.20898877" />
</component>
<component name="RecentsManager">
<key name="MoveFile.RECENT_KEYS">
<recent name="E:\mx_project\cneeds-server\cneeds-common-data\src\test" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-datashow\src\main\java\com\mx\cneeds" />
<key name="CopyFile.RECENT_KEYS">
<recent name="E:\mx_project\cneeds-server\cneeds-server-logupload\src\main\resources" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-user\src\main\resources" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-eureka\src\main\resources" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-device\src\main\resources" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-datashow\src\main\resources" />
<recent name="E:\mx_project\cneeds-server" />
<recent name="E:\mx_project\cneeds-server\src" />
</key>
<key name="CopyClassDialog.RECENTS_KEY">
<recent name="com.mx.cneeds.server.device.common" />
......@@ -142,15 +143,15 @@
<recent name="com.mx.cneeds.common.vo" />
<recent name="com.mx.cneeds.common.generate" />
</key>
<key name="CopyFile.RECENT_KEYS">
<recent name="E:\mx_project\cneeds-server\cneeds-server-user\src\main\resources" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-eureka\src\main\resources" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-device\src\main\resources" />
<key name="MoveFile.RECENT_KEYS">
<recent name="E:\mx_project\cneeds-server\cneeds-common-data\src\test" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-datashow\src\main\java\com\mx\cneeds" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-datashow\src\main\resources" />
<recent name="E:\mx_project\cneeds-server\cneeds-server-authorization\src\main\resources" />
<recent name="E:\mx_project\cneeds-server" />
<recent name="E:\mx_project\cneeds-server\src" />
</key>
</component>
<component name="RunManager" selected="Spring Boot.DeviceApplication">
<component name="RunManager" selected="Spring Boot.UserServerApplication">
<configuration default="true" type="JetRunConfigurationType" factoryName="Kotlin">
<module name="cneeds-server-advice-control" />
<option name="VM_PARAMETERS" />
......@@ -318,7 +319,9 @@
<workItem from="1584583200954" duration="19003000" />
<workItem from="1584671773646" duration="19144000" />
<workItem from="1584927645789" duration="18154000" />
<workItem from="1585014666194" duration="17923000" />
<workItem from="1585014666194" duration="17976000" />
<workItem from="1585101859853" duration="17933000" />
<workItem from="1585188207827" duration="22574000" />
</task>
<task id="LOCAL-00001" summary="1.修改不需要web服务 &#10;2.增加一个logupload">
<created>1578451117064</created>
......@@ -432,7 +435,14 @@
<option name="project" value="LOCAL" />
<updated>1584962456528</updated>
</task>
<option name="localTasksCounter" value="17" />
<task id="LOCAL-00017" summary="1.fix设备模块&#10;2.生产配置">
<created>1585056865041</created>
<option name="number" value="00017" />
<option name="presentableId" value="LOCAL-00017" />
<option name="project" value="LOCAL" />
<updated>1585056865041</updated>
</task>
<option name="localTasksCounter" value="18" />
<servers />
</component>
<component name="TypeScriptGeneratedFilesManager">
......@@ -468,13 +478,14 @@
<MESSAGE value="1.用户模块" />
<MESSAGE value="1.增加页面&#10;2.系统管理大模块的修改&#10;3. 产品系列" />
<MESSAGE value="1.增加页面&#10;2.系统管理大模块的修改&#10;3.设备控制模块" />
<option name="LAST_COMMIT_MESSAGE" value="1.增加页面&#10;2.系统管理大模块的修改&#10;3.设备控制模块" />
<MESSAGE value="1.fix设备模块&#10;2.生产配置" />
<option name="LAST_COMMIT_MESSAGE" value="1.fix设备模块&#10;2.生产配置" />
</component>
<component name="WindowStateProjectService">
<state x="552" y="178" key="#Project_Structure" timestamp="1584514052764">
<state x="552" y="178" key="#Project_Structure" timestamp="1585133454018">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="552" y="178" key="#Project_Structure/0.0.1920.1040@0.0.1920.1040" timestamp="1584514052764" />
<state x="552" y="178" key="#Project_Structure/0.0.1920.1040@0.0.1920.1040" timestamp="1585133454018" />
<state x="414" y="175" key="#com.intellij.execution.impl.EditConfigurationsDialog" timestamp="1583824373022">
<screen x="0" y="0" width="1920" height="1040" />
</state>
......@@ -499,62 +510,66 @@
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="703" y="356" key="ANALYSIS_DLG_com.intellij.analysis.BaseAnalysisAction$1/0.0.1920.1040@0.0.1920.1040" timestamp="1583822701848" />
<state x="463" y="112" key="CommitChangelistDialog2" timestamp="1584962451248">
<state x="463" y="112" key="CommitChangelistDialog2" timestamp="1585230288165">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="463" y="112" key="CommitChangelistDialog2/0.0.1920.1040@0.0.1920.1040" timestamp="1585230288165" />
<state x="150" y="103" key="DiffContextDialog" timestamp="1585117146381">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="463" y="112" key="CommitChangelistDialog2/0.0.1920.1040@0.0.1920.1040" timestamp="1584962451248" />
<state x="150" y="103" key="DiffContextDialog/0.0.1920.1040@0.0.1920.1040" timestamp="1585117146381" />
<state x="740" y="275" key="FileChooserDialogImpl" timestamp="1585025839954">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="740" y="275" key="FileChooserDialogImpl/0.0.1920.1040@0.0.1920.1040" timestamp="1585025839953" />
<state width="1877" height="326" key="GridCell.Tab.0.bottom" timestamp="1585047970775">
<state width="1877" height="297" key="GridCell.Tab.0.bottom" timestamp="1585230269912">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="1877" height="326" key="GridCell.Tab.0.bottom/0.0.1920.1040@0.0.1920.1040" timestamp="1585047970775" />
<state width="1877" height="326" key="GridCell.Tab.0.center" timestamp="1585047970775">
<state width="1877" height="297" key="GridCell.Tab.0.bottom/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269912" />
<state width="1877" height="297" key="GridCell.Tab.0.center" timestamp="1585230269912">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="1877" height="326" key="GridCell.Tab.0.center/0.0.1920.1040@0.0.1920.1040" timestamp="1585047970775" />
<state width="1877" height="326" key="GridCell.Tab.0.left" timestamp="1585047970775">
<state width="1877" height="297" key="GridCell.Tab.0.center/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269912" />
<state width="1877" height="297" key="GridCell.Tab.0.left" timestamp="1585230269912">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="1877" height="326" key="GridCell.Tab.0.left/0.0.1920.1040@0.0.1920.1040" timestamp="1585047970775" />
<state width="1877" height="326" key="GridCell.Tab.0.right" timestamp="1585047970775">
<state width="1877" height="297" key="GridCell.Tab.0.left/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269912" />
<state width="1877" height="297" key="GridCell.Tab.0.right" timestamp="1585230269912">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="1877" height="326" key="GridCell.Tab.0.right/0.0.1920.1040@0.0.1920.1040" timestamp="1585047970775" />
<state width="938" height="351" key="GridCell.Tab.1.bottom" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.0.right/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269912" />
<state width="1877" height="297" key="GridCell.Tab.1.bottom" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.1.bottom/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="938" height="351" key="GridCell.Tab.1.center" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.1.bottom/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state width="1877" height="297" key="GridCell.Tab.1.center" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.1.center/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="938" height="351" key="GridCell.Tab.1.left" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.1.center/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state width="1877" height="297" key="GridCell.Tab.1.left" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.1.left/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="938" height="351" key="GridCell.Tab.1.right" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.1.left/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state width="1877" height="297" key="GridCell.Tab.1.right" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.1.right/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="938" height="351" key="GridCell.Tab.2.bottom" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.1.right/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state width="1877" height="297" key="GridCell.Tab.2.bottom" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.2.bottom/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="938" height="351" key="GridCell.Tab.2.center" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.2.bottom/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state width="1877" height="297" key="GridCell.Tab.2.center" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.2.center/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="938" height="351" key="GridCell.Tab.2.left" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.2.center/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state width="1877" height="297" key="GridCell.Tab.2.left" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.2.left/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="938" height="351" key="GridCell.Tab.2.right" timestamp="1585020911160">
<state width="1877" height="297" key="GridCell.Tab.2.left/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state width="1877" height="297" key="GridCell.Tab.2.right" timestamp="1585230269913">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state width="938" height="351" key="GridCell.Tab.2.right/0.0.1920.1040@0.0.1920.1040" timestamp="1585020911160" />
<state width="1877" height="297" key="GridCell.Tab.2.right/0.0.1920.1040@0.0.1920.1040" timestamp="1585230269913" />
<state x="490" y="175" key="Maven.ArtifactSearchDialog" timestamp="1583320014926">
<screen x="0" y="0" width="1920" height="1040" />
</state>
......@@ -563,14 +578,14 @@
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="600" y="217" key="NewModule_or_Project.wizard/0.0.1920.1040@0.0.1920.1040" timestamp="1582699806601" />
<state x="438" y="166" width="1352" height="708" key="SettingsEditor" timestamp="1583725437328">
<state x="438" y="166" width="1352" height="708" key="SettingsEditor" timestamp="1585203134051">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="438" y="166" width="1352" height="708" key="SettingsEditor/0.0.1920.1040@0.0.1920.1040" timestamp="1583725437328" />
<state x="552" y="253" key="Vcs.Push.Dialog.v2" timestamp="1584962477473">
<state x="438" y="166" width="1352" height="708" key="SettingsEditor/0.0.1920.1040@0.0.1920.1040" timestamp="1585203134051" />
<state x="552" y="253" key="Vcs.Push.Dialog.v2" timestamp="1585056867102">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="552" y="253" key="Vcs.Push.Dialog.v2/0.0.1920.1040@0.0.1920.1040" timestamp="1584962477473" />
<state x="552" y="253" key="Vcs.Push.Dialog.v2/0.0.1920.1040@0.0.1920.1040" timestamp="1585056867102" />
<state x="752" y="437" key="com.intellij.openapi.vcs.update.UpdateOrStatusOptionsDialogupdate-v2" timestamp="1583724603426">
<screen x="0" y="0" width="1920" height="1040" />
</state>
......@@ -579,18 +594,18 @@
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="690" y="284" key="extract.method.dialog/0.0.1920.1040@0.0.1920.1040" timestamp="1584010366958" />
<state x="636" y="253" width="647" height="534" key="find.popup" timestamp="1584529336702">
<state x="636" y="253" width="659" height="534" key="find.popup" timestamp="1585209389354">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="636" y="253" width="647" height="534" key="find.popup/0.0.1920.1040@0.0.1920.1040" timestamp="1584529336702" />
<state x="636" y="253" width="659" height="534" key="find.popup/0.0.1920.1040@0.0.1920.1040" timestamp="1585209389354" />
<state x="511" y="210" key="new project wizard" timestamp="1583318693876">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="511" y="210" key="new project wizard/0.0.1920.1040@0.0.1920.1040" timestamp="1583318693876" />
<state x="616" y="173" width="672" height="676" key="search.everywhere.popup" timestamp="1585037123423">
<state x="616" y="173" width="672" height="676" key="search.everywhere.popup" timestamp="1585209477222">
<screen x="0" y="0" width="1920" height="1040" />
</state>
<state x="616" y="173" width="672" height="676" key="search.everywhere.popup/0.0.1920.1040@0.0.1920.1040" timestamp="1585037123423" />
<state x="616" y="173" width="672" height="676" key="search.everywhere.popup/0.0.1920.1040@0.0.1920.1040" timestamp="1585209477222" />
</component>
<component name="XDebuggerManager">
<breakpoint-manager>
......@@ -606,13 +621,8 @@
<option name="timeStamp" value="10" />
</line-breakpoint>
<line-breakpoint enabled="true" type="java-line">
<url>file://$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/system/SystemController.java</url>
<line>304</line>
<option name="timeStamp" value="15" />
</line-breakpoint>
<line-breakpoint enabled="true" type="java-line">
<url>file://$PROJECT_DIR$/cneeds-server-datashow/src/main/java/com/mx/cneeds/server/datashow/web/device/DeviceController.java</url>
<line>165</line>
<line>166</line>
<option name="timeStamp" value="17" />
</line-breakpoint>
</breakpoints>
......
......@@ -231,8 +231,8 @@ CREATE TABLE `sys_user` (
`user_id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '用户id',
`username` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户名',
`password` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '密码',
`salt` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL COMMENT '加密盐',
`email` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL COMMENT '邮箱',
`remark` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL COMMENT '简介',
`mobile` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL COMMENT '手机',
`status` int(11) DEFAULT NULL COMMENT '账户状态 0:禁用 1:正常',
`create_time` date DEFAULT NULL COMMENT '创建时间',
......
......@@ -32,10 +32,12 @@ public class SysUserEntity implements Serializable {
* 密码
*/
private String password;
/**
* 加密盐
* 简介
*/
private String salt;
private String remark;
/**
* 邮箱
*/
......
......@@ -8,7 +8,7 @@
<result property="userId" column="user_id"/>
<result property="username" column="username"/>
<result property="password" column="password"/>
<result property="salt" column="salt"/>
<result property="remark" column="remark"/>
<result property="email" column="email"/>
<result property="mobile" column="mobile"/>
<result property="status" column="status"/>
......
......@@ -15,12 +15,24 @@
<artifactId>cneeds-common-pojo</artifactId>
<!--<dependencies>
<dependency>
<dependencies>
<!--<dependency>
<groupId>com.mx.cneeds</groupId>
<artifactId>cneeds-common-utils</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<scope>compile</scope>
</dependency>
</dependencies>-->
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
</dependency>
</dependencies>
</project>
\ No newline at end of file
package com.mx.cneeds.common.dto;
import lombok.Data;
import java.util.Date;
/**
* @ClassName DeviceDto
* @Author zzrdark
* @Date 2020-03-25 18:51
* @Description TODO
**/
@Data
public class DeviceInfoDto {
/**
* 设备id
*/
private Long deviceId;
/**
*
*/
private Long deptId;
/**
* imei
*/
private String imei;
/**
* iccid
*/
private String iccid;
/**
* 状态0未激活,1已激活
*/
private String status;
/**
* 设备版本
*/
private String deviceVersion;
/**
* 产品系列
*/
private Long seriesId;
/**
* 创建时间
*/
private Date createTime;
/**
* 激活时间
*/
private Date activeTime;
/**
* 渠道号
*/
private String channelNums;
/**
* 渠道号提示信息
*/
private String channelNumsMessage;
/**
* 0:黑名单,1:白名单
*/
private Integer channelRules;
/**
* 产品系列号
*/
private String seriesNum;
}
......@@ -26,10 +26,12 @@ public class UserDto implements Serializable {
* 密码
*/
private String password;
/**
* 加密盐
* 简介
*/
private String salt;
private String remark;
/**
* 邮箱
*/
......@@ -52,9 +54,21 @@ public class UserDto implements Serializable {
*/
private Date createTime;
private List<Long> funcIdList;
/**
* 用户模块Id
*/
private List<Long> userFuncIdList;
/**
* 用户部门Id
*/
private List<Long> userDeptIdList;
/**
* 模块权限名
*/
private List<String> funcPerms;
private List<Long> deptIdList;
private Long roleId;
}
......@@ -27,10 +27,12 @@ public class UserVo implements Serializable {
* 密码
*/
private String password;
/**
* 加密盐
* 简介
*/
private String salt;
private String remark;
/**
* 邮箱
*/
......@@ -55,9 +57,9 @@ public class UserVo implements Serializable {
private Date createTime;
private List<Long> funcIdList;
private List<Long> userFuncIdList;
private List<Long> deptIdList;
private List<Long> userDeptIdList;
private Long roleId;
}
......@@ -43,6 +43,11 @@
<artifactId>commons-io</artifactId>
<version>${commons.io.version}</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>16.0</version>
</dependency>
<dependency>
<groupId>com.mx.cneeds</groupId>
......
......@@ -7,9 +7,9 @@ mvn clean package -Dmaven.test.skip=true -U
#docker push hub.c.163.com/springcloud/eureka
docker build -t zzrdark/eureka .
docker push zzrdark/eureka
#docker build -t zzrdark/eureka .
#docker push zzrdark/eureka
# docker build -t 192.168.2.244:5000/eureka .
docker build -t 192.168.2.244:5000/springcloud_authorization .
# docker push 192.168.2.244:5000/eureka
\ No newline at end of file
docker push 192.168.2.244:5000/springcloud_authorization
\ No newline at end of file
......@@ -16,7 +16,10 @@
<mysql.version>8.0.16</mysql.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-openfeign</artifactId>
</dependency>
<!-- eureka-client -->
<dependency>
<groupId>org.springframework.cloud</groupId>
......
spring:
profiles:
active: prod
active: dev
application:
name: cneeds-server-authorization
server:
......
......@@ -10,7 +10,7 @@ import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
**/
public class PasswordEncode {
public static void main(String[] args) {
String password = "admin";
String password = "123456";
BCryptPasswordEncoder encoder = new BCryptPasswordEncoder();
String enPassword1 = encoder.encode(password);
String enPassword2 = encoder.encode(password);
......
......@@ -14,7 +14,10 @@
<version>1.0-SNAPSHOT</version>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-openfeign</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
......@@ -53,6 +56,17 @@
<version>1.0-SNAPSHOT</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-swagger2</artifactId>
<version>${swagger.version}</version>
</dependency>
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-swagger-ui</artifactId>
<version>${swagger.version}</version>
</dependency>
</dependencies>
<build>
......
package com.mx.cneeds.server.datashow.client;
import com.mx.cneeds.common.dto.DeviceInfoDto;
import com.mx.cneeds.common.dto.DevicesDto;
import com.mx.cneeds.common.dto.PageDto;
import com.mx.cneeds.common.dto.SeriesDto;
......@@ -38,12 +39,17 @@ public interface DeviceClient {
void deleteSeries(@RequestBody List<Long> ids);
@PostMapping("device/info/list")
PageDto deviceList(@RequestParam Integer page,
@RequestParam("limit") Integer pageSize,
@RequestParam("sidx") String orderField,
@RequestParam("order") String order);
@PostMapping("/device/info/infoByImei")
DeviceInfoDto queryDeviceByImei(@RequestParam String imei);
@PostMapping("/device/info/importDevice")
void importDevice(@RequestBody DevicesDto dto);
......
......@@ -3,6 +3,7 @@ package com.mx.cneeds.server.datashow.config;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
import org.springframework.security.oauth2.config.annotation.web.configuration.EnableResourceServer;
import org.springframework.security.oauth2.config.annotation.web.configuration.ResourceServerConfigurerAdapter;
import org.springframework.security.oauth2.config.annotation.web.configurers.ResourceServerSecurityConfigurer;
......@@ -49,4 +50,9 @@ public class OAuth2ResourceServer extends ResourceServerConfigurerAdapter {
converter.setSigningKey("imooc");
return converter;
}
@Bean
public BCryptPasswordEncoder bCryptPasswordEncoder(){
return new BCryptPasswordEncoder();
}
}
\ No newline at end of file
......@@ -34,8 +34,9 @@ public class DeviceController {
@GetMapping("/device/getChannel")
public R getChannel_nums(String imei){
DeviceChannelVo channelVo = new DeviceChannelVo("123456,112233,654321", "提示的信息", 0);
DeviceChannelVo channelVo = new DeviceChannelVo();
DeviceInfoDto deviceInfoDto = deviceClient.queryDeviceByImei(imei);
BeanUtils.copyProperties(deviceInfoDto,channelVo);
return new R().put("data",channelVo);
}
......
......@@ -12,6 +12,7 @@ import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
import org.springframework.web.bind.annotation.*;
import java.util.ArrayList;
......@@ -31,6 +32,9 @@ public class SystemController {
@Autowired
private UserClient userClient;
@Autowired
private BCryptPasswordEncoder bCryptPasswordEncoder;
@PostMapping("/module/list")
public R funcList(@RequestParam(required = false) Integer page,
@RequestParam(required = false) Integer pageSize,
......@@ -348,7 +352,6 @@ public class SystemController {
}
PageDto pageDto = userClient.userList(page,pageSize,orderField,order);
return new R().put("data",pageDto);
}
......@@ -361,6 +364,7 @@ public class SystemController {
@RequestMapping("/user/add")
public R addUser(UserVo vo){
UserDto dto = new UserDto();
vo.setPassword(bCryptPasswordEncoder.encode(vo.getPassword()));
BeanUtils.copyProperties(vo,dto);
userClient.addUser(dto);
return R.ok();
......@@ -369,6 +373,10 @@ public class SystemController {
@PostMapping("/user/update")
public R editUser(UserVo vo){
UserDto dto = new UserDto();
if (StringUtils.isNotEmpty(vo.getPassword())
&& StringUtils.isNotBlank(vo.getPassword().trim())) {
vo.setPassword(bCryptPasswordEncoder.encode(vo.getPassword()));
}
BeanUtils.copyProperties(vo,dto);
userClient.updateUser(dto);
return R.ok();
......
package com.mx.cneeds.server.datashow.web.system;
import com.mx.cneeds.common.UserUtils;
import com.mx.cneeds.common.dto.UserDto;
import com.mx.cneeds.common.result.R;
import com.mx.cneeds.common.vo.UserInfoVo;
import com.mx.cneeds.server.datashow.client.AuthorizationClient;
......@@ -49,10 +51,24 @@ public class UserController {
@RequestMapping("/info")
public R getInfo(){
UserDto userDto = userClient.userInfo(UserUtils.getUserName());
UserInfoVo userInfoVo = new UserInfoVo();
userInfoVo.setName("admin");
if (userDto.getUserId()==1){
userInfoVo.setRoles("admin");
}else {
StringBuffer sb = new StringBuffer();
userDto.getFuncPerms().forEach(perms -> {
sb.append(perms+",");
});
sb.substring(0,sb.length()-2);
userInfoVo.setRoles(sb.toString());
}
userInfoVo.setName(userDto.getUsername());
userInfoVo.setIntroduction("manager");
userInfoVo.setRoles("book:editor,admin");
userInfoVo.setAvatar("avatar");
return new R().put("data",userInfoVo);
}
......
spring:
profiles:
active: prod
active: dev
application:
name: cneeds-server-datashow
......
......@@ -15,6 +15,10 @@
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-openfeign</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
</dependency>
<dependency>
......
......@@ -19,5 +19,7 @@ public interface DeviceInfoService extends IService<DeviceInfoEntity> {
PageUtils queryPage(Map<String, Object> params);
void updateBatchByImei(List<DeviceInfoEntity> deviceInfoEntityList);
DeviceInfoEntity queryDeviceByImei(String imei);
}
......@@ -60,4 +60,11 @@ public class DeviceInfoServiceImpl extends ServiceImpl<DeviceInfoDao, DeviceInfo
});
}
@Override
public DeviceInfoEntity queryDeviceByImei(String imei){
DeviceInfoEntity deviceInfoEntity = getBaseMapper().selectOne(new QueryWrapper<DeviceInfoEntity>()
.eq("imei", imei));
return deviceInfoEntity;
}
}
......@@ -2,12 +2,14 @@ package com.mx.cneeds.server.device.web;
import java.util.*;
import com.mx.cneeds.common.dto.DeviceInfoDto;
import com.mx.cneeds.common.dto.DevicesDto;
import com.mx.cneeds.common.pager.PageUtils;
import com.mx.cneeds.common.result.R;
import com.mx.cneeds.common.validator.ValidatorUtils;
import com.mx.cneeds.server.device.service.DeviceInfoService;
import com.mx.cneeds.server.entity.DeviceInfoEntity;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
......@@ -52,6 +54,17 @@ public class DeviceInfoController {
}
/**
* 信息
*/
@RequestMapping("/infoByImei")
public DeviceInfoDto infoByimei(String imei){
DeviceInfoEntity deviceInfoEntity = deviceInfoService.queryDeviceByImei(imei);
DeviceInfoDto deviceInfoDto = new DeviceInfoDto();
BeanUtils.copyProperties(deviceInfoEntity,deviceInfoDto);
return deviceInfoDto;
}
/**
* 保存
*/
@RequestMapping("/save")
......
spring:
profiles:
active: prod
active: dev
application:
name: cneeds-server-device
......
......@@ -19,12 +19,6 @@
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
......
......@@ -6,7 +6,8 @@ eureka:
## 单机的时候开启
register-with-eureka: false
fetch-registry: 'false'

# server:
server:
use-read-only-response-cache: false
# enable-self-preservation: false
instance:
prefer-ip-address: true
spring:
profiles:
active: prod
active: dev
application:
name: cneeds-server-eureka
server:
......
spring:
datasource:
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://192.168.2.244:3306/cneeds_server?useUnicode=true&characterEncoding=UTF-8&useSSL=false
password: cneeds!QAZ1qaz
username: root
# hikari:
# driver-class-name: com.mysql.jdbc.Driver
# url: jdbc:mysql://192.168.2.244:3306/cneeds_server?useUnicode=true&characterEncoding=UTF-8&useSSL=false
# username: root
# password: cneeds!QAZ1qaz
# datasource:
# type: com.alibaba.druid.pool.DruidDataSource
# druid:
# driver-class-name: com.mysql.jdbc.Driver
# url: jdbc:mysql://192.168.2.244:3306/cneeds_server?useUnicode=true&characterEncoding=UTF-8&useSSL=false
# username: root
# password: cneeds!QAZ1qaz
# initial-size: 10
# max-active: 100
# min-idle: 10
# max-wait: 60000
# pool-prepared-statements: true
# max-pool-prepared-statement-per-connection-size: 20
# time-between-eviction-runs-millis: 60000
# min-evictable-idle-time-millis: 300000
# #Oracle需要打开注释
# #validation-query: SELECT 1 FROM DUAL
# test-while-idle: true
# test-on-borrow: false
# test-on-return: false
# stat-view-servlet:
# enabled: true
# url-pattern: /druid/*
# #login-username: admin
# #login-password: admin
# filter:
# stat:
# log-slow-sql: true
# slow-sql-millis: 1000
# merge-sql: false
# wall:
# config:
# multi-statement-allow: true
eureka:
client:
service-url:
defaultZone: http://192.168.2.244:8761/eureka/
instance:
prefer-ip-address: true
ip-address: 192.168.2.244
spring:
profiles:
active: dev
application:
name: cneeds-server-logupload
server:
port: 9003
servlet:
context-path: /
mybatis-plus:
mapper-locations: classpath:mapper/*.xml
#实体扫描,多个package用逗号或者分号分隔
typeAliasesPackage: com.mx.cneeds.server.entity
global-config:
#数据库相关配置
db-config:
#主键类型 AUTO:"数据库ID自增", INPUT:"用户输入ID", ID_WORKER:"全局唯一ID (数字类型唯一ID)", UUID:"全局唯一ID UUID";
id-type: AUTO
#字段策略 IGNORED:"忽略判断",NOT_NULL:"非 NULL 判断"),NOT_EMPTY:"非空判断"
field-strategy: NOT_NULL
#驼峰下划线转换
column-underline: true
logic-delete-value: -1
logic-not-delete-value: 0
banner: false
#原生配置
configuration:
map-underscore-to-camel-case: true
cache-enabled: false
call-setters-on-nulls: true
jdbc-type-for-null: 'null'
......@@ -18,6 +18,10 @@
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-openfeign</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
</dependency>
<dependency>
......
......@@ -4,6 +4,8 @@ import com.baomidou.mybatisplus.extension.service.IService;
import com.mx.cneeds.common.pager.PageUtils;
import com.mx.cneeds.server.entity.SysFuncEntity;
import java.util.Collection;
import java.util.List;
import java.util.Map;
/**
......@@ -16,5 +18,7 @@ import java.util.Map;
public interface SysFuncService extends IService<SysFuncEntity> {
PageUtils queryPage(Map<String, Object> params);
List<SysFuncEntity> queryFuncByIds(Collection<Long> funcId);
}
......@@ -23,6 +23,6 @@ public interface SysUserFuncService extends IService<SysUserFuncEntity> {
void saveOrUpdate(Long userId, List<Long> menuIdList);
List<Long> queryFuncIdList(Long user);
List<Long> queryFuncIdList(Long userId);
}
......@@ -29,6 +29,8 @@ public interface SysUserService extends IService<SysUserEntity> {
void update(SysUserEntity user, List<Long> funcIdList, List<Long> deptIdList);
List<String> getUserPerms(String username);
String genDataFilter(DataFilterDto dataFilterDto);
}
......@@ -6,6 +6,9 @@ import com.mx.cneeds.server.dao.SysFuncDao;
import com.mx.cneeds.server.entity.SysFuncEntity;
import com.mx.cneeds.server.user.service.SysFuncService;
import org.springframework.stereotype.Service;
import java.util.Collection;
import java.util.List;
import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
......@@ -22,8 +25,13 @@ public class SysFuncServiceImpl extends ServiceImpl<SysFuncDao, SysFuncEntity> i
new Query<SysFuncEntity>().getPage(params),
new QueryWrapper<SysFuncEntity>()
);
return new PageUtils(page);
}
@Override
public List<SysFuncEntity> queryFuncByIds(Collection<Long> funcId){
List<SysFuncEntity> sysFuncEntities = getBaseMapper().selectBatchIds(funcId);
return sysFuncEntities;
}
}
......@@ -5,6 +5,7 @@ import com.mx.cneeds.common.dto.DataFilterDto;
import com.mx.cneeds.common.pager.PageUtils;
import com.mx.cneeds.common.pager.Query;
import com.mx.cneeds.server.dao.SysUserDao;
import com.mx.cneeds.server.entity.SysFuncEntity;
import com.mx.cneeds.server.entity.SysUserEntity;
import com.mx.cneeds.server.user.service.*;
import org.apache.commons.lang.StringUtils;
......@@ -37,6 +38,12 @@ public class SysUserServiceImpl extends ServiceImpl<SysUserDao, SysUserEntity> i
@Autowired
private SysRoleDeptService sysRoleDeptService;
@Autowired
private SysRoleFuncService sysRoleFuncService;
@Autowired
private SysFuncService sysFuncService;
@Override
public PageUtils queryPage(Map<String, Object> params) {
......@@ -79,7 +86,6 @@ public class SysUserServiceImpl extends ServiceImpl<SysUserDao, SysUserEntity> i
//保存用户与角色关系
sysUserRoleService.saveOrUpdate(user.getUserId(), roleId);
//保存角色与菜单关系
sysUserFuncService.saveOrUpdate(user.getUserId(), funcIdList);
......@@ -91,12 +97,47 @@ public class SysUserServiceImpl extends ServiceImpl<SysUserDao, SysUserEntity> i
@Transactional(rollbackFor = Exception.class)
public void update(SysUserEntity user, List<Long> funcIdList, List<Long> deptIdList) {
this.updateById(user);
if (funcIdList!=null && funcIdList.size()!=0){
//更新用户与菜单关系
sysUserFuncService.saveOrUpdate(user.getUserId(), funcIdList);
}
//更新用户与菜单关系
sysUserFuncService.saveOrUpdate(user.getUserId(), funcIdList);
if (deptIdList!=null && deptIdList.size()!=0){
//保存用户与部门关系
sysUserDeptService.saveOrUpdate(user.getUserId(), deptIdList);
}
}
@Override
public List<String> getUserPerms(String username){
SysUserEntity sysUserEntity = queryUserByUsername(username);
// 模块Id
Set<Long> funcIdList = new HashSet<>();
// 模块权限字段
List<String> funcPermsList = new ArrayList<>();
//用户角色对应的模块区权限
Long roleId = sysUserRoleService.queryRoleId(sysUserEntity.getUserId());
List<Long> funcList = sysRoleFuncService.queryFuncId(roleId);
funcIdList.addAll(funcList);
List<Long> userFuncList = sysUserFuncService.queryFuncIdList(sysUserEntity.getUserId());
userFuncList.forEach(funcId -> {
funcIdList.add(funcId);
});
if (funcIdList.size() !=0){
List<SysFuncEntity> sysFuncEntities = sysFuncService.queryFuncByIds(funcIdList);
sysFuncEntities.forEach(entity -> {
funcPermsList.add(entity.getPerms());
});
return funcPermsList;
}else {
return null;
}
//保存用户与部门关系
sysUserDeptService.saveOrUpdate(user.getUserId(), deptIdList);
}
@Override
......
......@@ -75,8 +75,9 @@ public class SysUserController {
UserDto userDto = new UserDto();
BeanUtils.copyProperties(sysUser,userDto);
userDto.setRoleId(roleId);
userDto.setDeptIdList(sysUserDeptService.queryDeptIdList(sysUser.getUserId()));
userDto.setFuncIdList(sysUserFuncService.queryFuncIdList(sysUser.getUserId()));
userDto.setUserDeptIdList(sysUserDeptService.queryDeptIdList(sysUser.getUserId()));
userDto.setUserFuncIdList(sysUserFuncService.queryFuncIdList(sysUser.getUserId()));
userDto.setFuncPerms(sysUserService.getUserPerms(userDto.getUsername()));
return userDto;
}
......@@ -90,7 +91,7 @@ public class SysUserController {
BeanUtils.copyProperties(dto,sysUser);
sysUserService.saveUser(sysUser, dto.getFuncIdList(), dto.getDeptIdList(), dto.getRoleId());
sysUserService.saveUser(sysUser, dto.getUserFuncIdList(), dto.getUserDeptIdList(), dto.getRoleId());
return R.ok();
}
......@@ -103,7 +104,7 @@ public class SysUserController {
BeanUtils.copyProperties(dto,sysUser);
ValidatorUtils.validateEntity(sysUser);
sysUserService.update(sysUser, dto.getFuncIdList(), dto.getDeptIdList());
sysUserService.update(sysUser, dto.getUserFuncIdList(), dto.getUserDeptIdList());
return R.ok();
}
......
......@@ -50,7 +50,7 @@ eureka:
defaultZone: http://192.168.2.244:8761/eureka/
instance:
prefer-ip-address: true
ip-address: 192.168.2.244
# ip-address: 192.168.2.244
......
spring:
profiles:
active: prod
active: dev
application:
name: cneeds-server-user
......
......@@ -57,27 +57,6 @@
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-openfeign</artifactId>
</dependency>
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-swagger2</artifactId>
<version>${swagger.version}</version>
</dependency>
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-swagger-ui</artifactId>
<version>${swagger.version}</version>
</dependency>
</dependencies>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment