Procházet zdrojové kódy

对接MES系统与称重PLC

zhifei před 1 rokem
rodič
revize
35abbf7fc7
100 změnil soubory, kde provedl 653 přidání a 1923 odebrání
  1. 7 0
      pom.xml
  2. 2 2
      warewms-admin/src/main/resources/application-dev.yml
  3. 203 0
      warewms-admin/src/main/resources/application-prod.yml
  4. 33 0
      warewms-admin/src/main/resources/application.yml
  5. 0 45
      warewms-admin/src/test/java/TestData.java
  6. 0 42
      warewms-admin/src/test/java/com/ruoyi/admin/test/base/WarehouseTest.java
  7. 6 0
      warewms-common/pom.xml
  8. 11 1
      warewms-system/pom.xml
  9. 30 0
      warewms-system/src/main/java/com/warewms/hailiang/MES/MesService.java
  10. 50 0
      warewms-system/src/main/java/com/warewms/hailiang/MES/impl/MesServiceImpl.java
  11. 32 0
      warewms-system/src/main/java/com/warewms/hailiang/config/PlcConfig.java
  12. 86 0
      warewms-system/src/main/java/com/warewms/hailiang/config/PlcConnectServiceRunner.java
  13. 22 0
      warewms-system/src/main/java/com/warewms/hailiang/config/PlcProperties.java
  14. 24 0
      warewms-system/src/main/java/com/warewms/hailiang/enums/WeighPlcEnum.java
  15. 147 0
      warewms-system/src/main/java/com/warewms/hailiang/util/HslTools.java
  16. 0 22
      warewms-ui/.editorconfig
  17. 0 11
      warewms-ui/.env.development
  18. 0 8
      warewms-ui/.env.production
  19. 0 10
      warewms-ui/.env.staging
  20. 0 10
      warewms-ui/.eslintignore
  21. 0 199
      warewms-ui/.eslintrc.js
  22. 0 23
      warewms-ui/.gitignore
  23. 0 30
      warewms-ui/README.md
  24. 0 13
      warewms-ui/babel.config.js
  25. 0 12
      warewms-ui/bin/build.bat
  26. 0 12
      warewms-ui/bin/package.bat
  27. 0 12
      warewms-ui/bin/run-web.bat
  28. 0 35
      warewms-ui/build/index.js
  29. 0 90
      warewms-ui/package.json
  30. binární
      warewms-ui/public/favicon.ico
  31. 0 46
      warewms-ui/public/html/ie.html
  32. 0 208
      warewms-ui/public/index.html
  33. 0 2
      warewms-ui/public/robots.txt
  34. 0 28
      warewms-ui/src/App.vue
  35. 0 59
      warewms-ui/src/api/login.js
  36. 0 9
      warewms-ui/src/api/menu.js
  37. 0 57
      warewms-ui/src/api/monitor/cache.js
  38. 0 71
      warewms-ui/src/api/monitor/job.js
  39. 0 26
      warewms-ui/src/api/monitor/jobLog.js
  40. 0 34
      warewms-ui/src/api/monitor/logininfor.js
  41. 0 18
      warewms-ui/src/api/monitor/online.js
  42. 0 26
      warewms-ui/src/api/monitor/operlog.js
  43. 0 9
      warewms-ui/src/api/monitor/server.js
  44. 0 60
      warewms-ui/src/api/system/config.js
  45. 0 52
      warewms-ui/src/api/system/dept.js
  46. 0 52
      warewms-ui/src/api/system/dict/data.js
  47. 0 60
      warewms-ui/src/api/system/dict/type.js
  48. 0 60
      warewms-ui/src/api/system/menu.js
  49. 0 44
      warewms-ui/src/api/system/notice.js
  50. 0 44
      warewms-ui/src/api/system/post.js
  51. 0 119
      warewms-ui/src/api/system/role.js
  52. 0 135
      warewms-ui/src/api/system/user.js
  53. 0 76
      warewms-ui/src/api/tool/gen.js
  54. binární
      warewms-ui/src/assets/401_images/401.gif
  55. binární
      warewms-ui/src/assets/404_images/404.png
  56. binární
      warewms-ui/src/assets/404_images/404_cloud.png
  57. 0 9
      warewms-ui/src/assets/icons/index.js
  58. 0 1
      warewms-ui/src/assets/icons/svg/404.svg
  59. 0 1
      warewms-ui/src/assets/icons/svg/bug.svg
  60. 0 1
      warewms-ui/src/assets/icons/svg/build.svg
  61. 0 1
      warewms-ui/src/assets/icons/svg/button.svg
  62. 0 1
      warewms-ui/src/assets/icons/svg/cascader.svg
  63. 0 1
      warewms-ui/src/assets/icons/svg/chart.svg
  64. 0 1
      warewms-ui/src/assets/icons/svg/checkbox.svg
  65. 0 1
      warewms-ui/src/assets/icons/svg/clipboard.svg
  66. 0 1
      warewms-ui/src/assets/icons/svg/code.svg
  67. 0 1
      warewms-ui/src/assets/icons/svg/color.svg
  68. 0 1
      warewms-ui/src/assets/icons/svg/component.svg
  69. 0 1
      warewms-ui/src/assets/icons/svg/dashboard.svg
  70. 0 1
      warewms-ui/src/assets/icons/svg/date-range.svg
  71. 0 1
      warewms-ui/src/assets/icons/svg/date.svg
  72. 0 1
      warewms-ui/src/assets/icons/svg/dict.svg
  73. 0 1
      warewms-ui/src/assets/icons/svg/documentation.svg
  74. 0 1
      warewms-ui/src/assets/icons/svg/download.svg
  75. 0 1
      warewms-ui/src/assets/icons/svg/drag.svg
  76. 0 1
      warewms-ui/src/assets/icons/svg/druid.svg
  77. 0 1
      warewms-ui/src/assets/icons/svg/edit.svg
  78. 0 1
      warewms-ui/src/assets/icons/svg/education.svg
  79. 0 1
      warewms-ui/src/assets/icons/svg/email.svg
  80. 0 1
      warewms-ui/src/assets/icons/svg/example.svg
  81. 0 1
      warewms-ui/src/assets/icons/svg/excel.svg
  82. 0 1
      warewms-ui/src/assets/icons/svg/exit-fullscreen.svg
  83. 0 1
      warewms-ui/src/assets/icons/svg/eye-open.svg
  84. 0 1
      warewms-ui/src/assets/icons/svg/eye.svg
  85. 0 1
      warewms-ui/src/assets/icons/svg/form.svg
  86. 0 1
      warewms-ui/src/assets/icons/svg/fullscreen.svg
  87. 0 1
      warewms-ui/src/assets/icons/svg/github.svg
  88. 0 1
      warewms-ui/src/assets/icons/svg/guide.svg
  89. 0 1
      warewms-ui/src/assets/icons/svg/icon.svg
  90. 0 1
      warewms-ui/src/assets/icons/svg/input.svg
  91. 0 1
      warewms-ui/src/assets/icons/svg/international.svg
  92. 0 1
      warewms-ui/src/assets/icons/svg/job.svg
  93. 0 1
      warewms-ui/src/assets/icons/svg/language.svg
  94. 0 1
      warewms-ui/src/assets/icons/svg/link.svg
  95. 0 1
      warewms-ui/src/assets/icons/svg/list.svg
  96. 0 1
      warewms-ui/src/assets/icons/svg/lock.svg
  97. 0 1
      warewms-ui/src/assets/icons/svg/log.svg
  98. 0 1
      warewms-ui/src/assets/icons/svg/logininfor.svg
  99. 0 1
      warewms-ui/src/assets/icons/svg/message.svg
  100. 0 0
      warewms-ui/src/assets/icons/svg/money.svg

+ 7 - 0
pom.xml

@@ -43,6 +43,7 @@
         <knife4j.spring.version>3.0.3</knife4j.spring.version>
         <guava.version>23.0</guava.version>
         <guava.retry.version>2.0.0</guava.retry.version>
+        <HslCommunication.version>2.0.2</HslCommunication.version>
     </properties>
 
     <!-- 依赖声明 -->
@@ -203,6 +204,12 @@
                 <version>${guava.retry.version}</version>
             </dependency>
 
+            <dependency>
+                <groupId>com.github.dathlin</groupId>
+                <artifactId>HslCommunication</artifactId>
+                <version>${HslCommunication.version}</version>
+            </dependency>
+
         </dependencies>
     </dependencyManagement>
 

+ 2 - 2
warewms-admin/src/main/resources/application-dev.yml

@@ -67,7 +67,7 @@ spring:
     druid:
       # 主库数据源
       master:
-        url: jdbc:mysql://47.100.220.92:3306/warewms-standard?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&serverTimezone=GMT%2B8
+        url: jdbc:mysql://47.100.220.92:3306/trace_system_hailiang?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&serverTimezone=GMT%2B8
         username: warewms
         password: warewms123
       # 从库数据源
@@ -123,7 +123,7 @@ spring:
   # redis 配置
   redis:
     # 地址
-    host: 154.12.20.200
+    host: localhost
     # 端口,默认为6379
     port: 6379
     # 数据库索引

+ 203 - 0
warewms-admin/src/main/resources/application-prod.yml

@@ -0,0 +1,203 @@
+# 项目相关配置
+warewms:
+  # 名称
+  name: automated warehouse management system
+  # 版本
+  version: 1.0
+  # 版权年份
+  copyrightYear: 2023
+  # 实例演示开关
+  demoEnabled: true
+  # 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
+  profile: D:/warewms/uploadPath
+  # 获取ip地址开关
+  addressEnabled: false
+  # 验证码类型 math 数组计算 char 字符验证
+  captchaType: math
+
+# 开发环境配置
+server:
+  # 服务器的HTTP端口,默认为8080
+  port: 8080
+  servlet:
+    # 应用的访问路径
+    context-path: /
+  tomcat:
+    # tomcat的URI编码
+    uri-encoding: UTF-8
+    # 连接数满后的排队数,默认为100
+    accept-count: 1000
+    threads:
+      # tomcat最大线程数,默认为200
+      max: 800
+      # Tomcat启动初始化的线程数,默认值10
+      min-spare: 100
+
+# 日志配置
+logging:
+  level:
+    com.ruoyi: debug
+    org.springframework: warn
+
+# 用户配置
+user:
+  password:
+    # 密码最大错误次数
+    maxRetryCount: 5
+    # 密码锁定时间(默认10分钟)
+    lockTime: 10
+
+# Spring配置
+spring:
+  # 资源信息
+  messages:
+    # 国际化资源文件路径
+    basename: i18n/messages
+  # 文件上传
+  servlet:
+     multipart:
+       # 单个文件大小
+       max-file-size:  10MB
+       # 设置总上传的文件大小
+       max-request-size:  20MB
+  # 数据源配置
+  datasource:
+    type: com.alibaba.druid.pool.DruidDataSource
+    driverClassName: com.mysql.cj.jdbc.Driver
+    druid:
+      # 主库数据源
+      master:
+        url: jdbc:mysql://localhost:3306/trace_system?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=false&serverTimezone=GMT%2B8
+        username: warewms
+        password: warewms123
+      # 从库数据源
+      slave:
+        # 从数据源开关/默认关闭
+        enabled: false
+        url:
+        username:
+        password:
+      # 初始连接数
+      initialSize: 5
+      # 最小连接池数量
+      minIdle: 10
+      # 最大连接池数量
+      maxActive: 20
+      # 配置获取连接等待超时的时间
+      maxWait: 60000
+      # 配置连接超时时间
+      connectTimeout: 30000
+      # 配置网络超时时间
+      socketTimeout: 60000
+      # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
+      timeBetweenEvictionRunsMillis: 60000
+      # 配置一个连接在池中最小生存的时间,单位是毫秒
+      minEvictableIdleTimeMillis: 300000
+      # 配置一个连接在池中最大生存的时间,单位是毫秒
+      maxEvictableIdleTimeMillis: 900000
+      # 配置检测连接是否有效
+      validationQuery: SELECT 1 FROM DUAL
+      testWhileIdle: true
+      testOnBorrow: false
+      testOnReturn: false
+      webStatFilter:
+        enabled: true
+      statViewServlet:
+        enabled: true
+        # 设置白名单,不填则允许所有访问
+        allow:
+        url-pattern: /druid/*
+        # 控制台管理用户名和密码
+        login-username: admin
+        login-password: 123456
+      filter:
+        stat:
+          enabled: true
+          # 慢SQL记录
+          log-slow-sql: true
+          slow-sql-millis: 1000
+          merge-sql: true
+        wall:
+          config:
+            multi-statement-allow: true
+  # redis 配置
+  redis:
+    # 地址
+    host: localhost
+    # 端口,默认为6379
+    port: 6379
+    # 数据库索引
+    database: 0
+    # 密码
+    password:
+    # 连接超时时间
+    timeout: 10s
+    lettuce:
+      pool:
+        # 连接池中的最小空闲连接
+        min-idle: 0
+        # 连接池中的最大空闲连接
+        max-idle: 8
+        # 连接池的最大数据库连接数
+        max-active: 8
+        # #连接池最大阻塞等待时间(使用负值表示没有限制)
+        max-wait: -1ms
+
+# token配置
+token:
+    # 令牌自定义标识
+    header: Authorization
+    # 令牌密钥
+    secret: abcdefghijklmnopqrstuvwxyz
+    # 令牌有效期(默认30分钟)
+    expireTime: 30
+
+# MyBatis Plus配置
+mybatis-plus:
+
+  mapper-locations: classpath*:/mapper/**/*.xml,classpath:/META-INF/modeler-mybatis-mappings/*.xml
+  #实体扫描,多个package用逗号或者分号分隔
+  # 不支持多包, 如有需要可在注解配置 或 提升扫包等级
+  # 例如 com.**.**.mapper
+  mapperPackage: com.warewms.**.mapper
+  # 实体扫描,多个package用逗号或者分号分隔
+  typeAliasesPackage: com.warewms.**.domain
+  configuration:
+    # 自动驼峰命名规则(camel case)映射
+    mapUnderscoreToCamelCase: true
+    # 更详细的日志输出 会有性能损耗 org.apache.ibatis.logging.stdout.StdOutImpl
+    # 默认日志输出 org.apache.ibatis.logging.slf4j.Slf4jImpl
+    logImpl: org.apache.ibatis.logging.stdout.StdOutImpl
+  global-config:
+    # 是否打印 Logo banner
+    banner: false
+    dbConfig:
+      # 主键类型
+      # AUTO 自增 NONE 空 INPUT 用户输入 ASSIGN_ID 雪花 ASSIGN_UUID 唯一 UUID
+      idType: AUTO
+      logic-delete-field: deleted # 全局逻辑删除的实体字段名
+      logic-delete-value: 1 # 逻辑已删除值(默认为 1)
+      logic-not-delete-value: 0 # 逻辑未删除值(默认为 0)
+
+
+# Knife4j配置
+knife4j:
+  #开启增强配置
+  enable: true
+  #开启生产环境屏蔽
+  production: false
+  basic:
+    enable: false
+    username: admin
+    password: 123456
+
+# 防止XSS攻击
+xss:
+  # 过滤开关
+  enabled: true
+  # 排除链接(多个用逗号分隔)
+  excludes: /system/notice
+  # 匹配链接
+  urlPatterns: /system/*,/monitor/*,/tool/*
+
+

+ 33 - 0
warewms-admin/src/main/resources/application.yml

@@ -2,3 +2,36 @@
 spring:
   profiles:
     active: dev
+socket:
+  # 监听端口 8090
+  port: 8090
+  #ip地址
+  host: 127.0.0.1
+
+plc:
+  plcList[0]:
+    ip: 172.20.52.21
+    enable: false
+    slot: 1
+    rack: 0
+    name: ChengZhongPlc
+    siemensPLCS: S1200
+  plcList[1]:
+    ip: 172.20.52.22
+    enable: false
+    name: XiMianPlc
+    siemensPLCS: S1500
+  plcList[2]:
+    ip: 172.20.52.24
+    enable: false
+    name: ZaZhiPlc
+    siemensPLCS: S1500
+
+MES:
+  address: http://192.20.2.4:9090
+  #获取批次号
+  getBatchNoUrl: /api/SprayCode/SprayBatchNo
+  #获取批次号回调
+  getBatchNoResultUrl: /api/SprayCode/SprayBatchNoResult
+  #铣面
+  MillingSurfaceUrl: /api/SprayCode/SprayMillingSurface

+ 0 - 45
warewms-admin/src/test/java/TestData.java

@@ -1,45 +0,0 @@
-import com.warewms.WarewmsApplication;
-import com.warewms.common.core.controller.BaseController;
-import com.warewms.common.core.domain.entity.SysDictData;
-import com.warewms.common.core.domain.entity.SysDictType;
-import com.warewms.common.core.domain.entity.SysUser;
-import com.warewms.common.utils.poi.ExcelUtil;
-import com.warewms.system.service.ISysDictDataService;
-import com.warewms.system.service.ISysDictTypeService;
-import com.warewms.system.service.ISysNoticeService;
-import com.warewms.system.service.ISysUserService;
-import lombok.extern.slf4j.Slf4j;
-import org.junit.runner.RunWith;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.springframework.boot.test.context.SpringBootTest;
-import org.springframework.test.context.junit4.SpringRunner;
-
-import javax.servlet.http.HttpServletResponse;
-import java.util.List;
-
-
-@RunWith(SpringRunner.class)
-@SpringBootTest(classes = WarewmsApplication.class, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
-@Slf4j
-public class TestData extends BaseController<SysDictType> {
-
-    @Autowired
-    private ISysUserService userService;
-
-    @Autowired
-    private ISysDictDataService dictDataService;
-
-    @Autowired
-    private ISysDictTypeService dictTypeService;
-
-
-    @Test
-    public void export()
-    {
-        List<SysDictType> list = dictTypeService.selectDictTypeList(new SysDictType());
-        log.info("输出结果{}",list);
-    }
-
-}

+ 0 - 42
warewms-admin/src/test/java/com/ruoyi/admin/test/base/WarehouseTest.java

@@ -1,42 +0,0 @@
-package com.ruoyi.admin.test.base;
-
-import com.google.common.collect.Maps;
-import com.warewms.WarewmsApplication;
-import com.warewms.common.core.domain.entity.SysUser;
-import com.warewms.system.mapper.SysUserMapper;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.boot.test.context.SpringBootTest;
-import org.springframework.test.context.junit4.SpringRunner;
-
-import java.util.List;
-import java.util.Map;
-
-/**
- * Created by IntelliJ IDEA.
- * User: andy.qu
- * Date: 2022/2/9
- */
-@RunWith(SpringRunner.class)
-@SpringBootTest(classes = WarewmsApplication.class, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
-public class WarehouseTest {
-
-    @Autowired
-    private SysUserMapper userMapper;
-
-    @Test
-    public void test() {
-
-        SysUser sysUser = new SysUser();
-        Map<String, Object> param = Maps.newHashMap();
-        param.put("beginTime", "2023-06-01 00:00:00");
-        param.put("endTime", "2023-08-01 23:59:59");
-        sysUser.setParams(param);
-        List<SysUser> sysUsers = userMapper.selectUserList(sysUser);
-        System.out.println(sysUsers);
-    }
-
-
-
-}

+ 6 - 0
warewms-common/pom.xml

@@ -149,6 +149,12 @@
             <groupId>com.github.rholder</groupId>
             <artifactId>guava-retrying</artifactId>
         </dependency>
+
+        <!-- netty -->
+        <dependency>
+            <groupId>io.netty</groupId>
+            <artifactId>netty-all</artifactId>
+        </dependency>
     </dependencies>
 
 </project>

+ 11 - 1
warewms-system/pom.xml

@@ -20,7 +20,17 @@
             <groupId>com.warewms</groupId>
             <artifactId>warewms-framework</artifactId>
         </dependency>
+        <dependency>
+            <groupId>com.jwk</groupId>
+            <artifactId>modbus-spring-boot-starter</artifactId>
+            <version>1.0</version>
+            <scope>compile</scope>
+        </dependency>
 
+        <dependency>
+            <groupId>com.github.dathlin</groupId>
+            <artifactId>HslCommunication</artifactId>
+        </dependency>
     </dependencies>
 
-</project>
+</project>

+ 30 - 0
warewms-system/src/main/java/com/warewms/hailiang/MES/MesService.java

@@ -0,0 +1,30 @@
+package com.warewms.hailiang.MES;
+
+import cn.hutool.json.JSONObject;
+
+/**
+ * Created with IntelliJ IDEA.
+ *
+ * @author: liuzhifei
+ * Date: 2023/8/9
+ * Time: 11:20
+ * To change this template use File | Settings | File Templates.
+ * Description: MES对接服务层
+ **/
+public interface MesService {
+
+    /**
+     * 根据重量获取批次号
+     * @param weight 重量
+     * @param prodLine 产线编号
+     * @return
+     */
+    public JSONObject getBatchNoByWeight(Double weight,String prodLine);
+
+    /**
+     * 获取批次号反馈
+     * @param batchNo
+     * @return
+     */
+    public JSONObject getBatchNoResult(String batchNo,boolean result);
+}

+ 50 - 0
warewms-system/src/main/java/com/warewms/hailiang/MES/impl/MesServiceImpl.java

@@ -0,0 +1,50 @@
+package com.warewms.hailiang.MES.impl;
+
+import cn.hutool.http.HttpRequest;
+import cn.hutool.http.HttpResponse;
+import cn.hutool.http.HttpUtil;
+import cn.hutool.json.JSONObject;
+import cn.hutool.json.JSONUtil;
+import com.warewms.hailiang.MES.MesService;
+import io.swagger.util.Json;
+import org.springframework.beans.factory.annotation.Value;
+
+/**
+ * Created with IntelliJ IDEA.
+ *
+ * @author: liuzhifei
+ * Date: 2023/8/9
+ * Time: 11:20
+ * To change this template use File | Settings | File Templates.
+ * Description: MES对接实现类
+ **/
+public class MesServiceImpl implements MesService {
+    @Value("${MES.address}")
+    private String MESAddress;
+
+    @Value("${MES.getBatchNoUrl}")
+    private String getBatchNoUrl;
+
+    @Value("${MES.getBatchNoResultURl}")
+    private String getBatchNoResultURl;
+
+
+
+    @Override
+    public JSONObject getBatchNoByWeight(Double weight,String prodLine) {
+        JSONObject entries = new JSONObject();
+        entries.set("Weight",weight);
+        entries.set("prodLine",prodLine);
+        String body = HttpRequest.post(MESAddress + getBatchNoUrl).body(entries.toString()).execute().body();
+        return JSONUtil.parseObj(body);
+    }
+
+    @Override
+    public JSONObject getBatchNoResult(String batchNo,boolean result) {
+        JSONObject entries = new JSONObject();
+        entries.set("BatchNo",batchNo);
+        entries.set("Result",result);
+        String body = HttpRequest.post(MESAddress + getBatchNoResultURl).body(entries.toString()).execute().body();
+        return  JSONUtil.parseObj(body);
+    }
+}

+ 32 - 0
warewms-system/src/main/java/com/warewms/hailiang/config/PlcConfig.java

@@ -0,0 +1,32 @@
+package com.warewms.hailiang.config;
+
+import HslCommunication.Profinet.Siemens.SiemensPLCS;
+import lombok.Data;
+
+/**
+ * Created with IntelliJ IDEA.
+ *
+ * @author: liuzhifei
+ * Date: 2023/8/7
+ * Description: pcl配置类
+ **/
+@Data
+public class PlcConfig {
+
+    private String ip;
+
+    private Boolean enable;
+
+    private String name;
+
+    private byte slot;
+
+    private byte rack;
+
+
+    private SiemensPLCS siemensPLCS;
+
+    public void setSiemensPLCS(String  siemensPLCS) {
+        this.siemensPLCS = SiemensPLCS.valueOf(siemensPLCS);
+    }
+}

+ 86 - 0
warewms-system/src/main/java/com/warewms/hailiang/config/PlcConnectServiceRunner.java

@@ -0,0 +1,86 @@
+package com.warewms.hailiang.config;
+
+
+import com.github.rholder.retry.*;
+import com.warewms.hailiang.util.HslTools;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.boot.CommandLineRunner;
+import org.springframework.core.annotation.Order;
+import org.springframework.stereotype.Component;
+
+import javax.annotation.Resource;
+import java.util.HashMap;
+import java.util.concurrent.ExecutionException;
+import java.util.concurrent.TimeUnit;
+
+/**
+ * plc连接
+ */
+@Component
+@Order(1)
+@Slf4j
+public class PlcConnectServiceRunner implements CommandLineRunner {
+
+    @Resource
+    private PlcProperties plcProperties;
+
+    private HashMap<String, HslTools> plcToolsMap = new HashMap<>();
+
+    @Override
+    public void run(String... args) throws Exception {
+        initConnect();
+        log.info("plc初始化完成!");
+    }
+
+    /**
+     * 初始化
+     */
+    private void initConnect() throws InterruptedException {
+        for (PlcConfig plcConfig : plcProperties.getPlcList()) {
+            if (plcConfig.getEnable()) {
+                log.info("初始化:{},ip:{}", plcConfig.getName(), plcConfig.getIp());
+                HslTools hslTools = new HslTools(plcConfig);
+                Thread.sleep(5000);
+                if (hslTools.getSuccess()) {
+                    log.info("plc连接成功:{},ip:{}", plcConfig.getName(), plcConfig.getIp());
+                    plcToolsMap.put(plcConfig.getName(), hslTools);
+                } else {
+                    new Thread(() -> {
+                        retry(plcConfig);
+                    }).start();
+                }
+            }
+        }
+
+    }
+
+    public void retry(PlcConfig plcConfig) {
+        new Thread(() -> {
+            Retryer<Boolean> retryer = RetryerBuilder.<Boolean>newBuilder()
+                    .retryIfResult(Boolean.FALSE::equals)
+                    .retryIfExceptionOfType(Exception.class)
+                    .withStopStrategy(StopStrategies.stopAfterAttempt(5))
+                    .withWaitStrategy(WaitStrategies.fixedWait(3, TimeUnit.SECONDS))
+                    .build();
+            try {
+                retryer.call(() -> {
+                    log.info("重试:{},ip:{}", plcConfig.getName(), plcConfig.getIp());
+                    HslTools hslTools = new HslTools(plcConfig);
+                    Thread.sleep(5000);
+                    if (hslTools.getSuccess()) {
+                        log.info("plc连接成功:{},ip:{}", plcConfig.getName(), plcConfig.getIp());
+                        plcToolsMap.put(plcConfig.getName(), hslTools);
+                        return true;
+                    }
+                    return false;
+                });
+            } catch (RetryException | ExecutionException e) {
+                e.printStackTrace();
+            }
+        }).start();
+    }
+
+    public HslTools getPlcServer(String key){
+      return  plcToolsMap.get(key);
+    }
+}

+ 22 - 0
warewms-system/src/main/java/com/warewms/hailiang/config/PlcProperties.java

@@ -0,0 +1,22 @@
+package com.warewms.hailiang.config;
+
+import lombok.Data;
+import org.springframework.boot.context.properties.ConfigurationProperties;
+import org.springframework.stereotype.Component;
+
+import java.util.List;
+
+/**
+ * Created with IntelliJ IDEA.
+ *
+ * @author: liuzhifei
+ * Date: 2023/8/7.
+ * Description:
+ **/
+@Data
+@Component
+@ConfigurationProperties(prefix = "plc")
+public class PlcProperties {
+
+    private List<PlcConfig> plcList;
+}

+ 24 - 0
warewms-system/src/main/java/com/warewms/hailiang/enums/WeighPlcEnum.java

@@ -0,0 +1,24 @@
+package com.warewms.hailiang.enums;
+
+/**
+ * Created with IntelliJ IDEA.
+ *
+ * @author: liuzhifei
+ * Date: 2023/8/7
+ * Description:称重plc对接枚举
+ **/
+public enum WeighPlcEnum {
+
+    /**
+     * 心跳
+     */
+    heartbeatDB("DB11.0.0");
+
+    private String db;
+
+    WeighPlcEnum(String db) {
+        this.db = db;
+    }
+
+}
+

+ 147 - 0
warewms-system/src/main/java/com/warewms/hailiang/util/HslTools.java

@@ -0,0 +1,147 @@
+package com.warewms.hailiang.util;
+
+import HslCommunication.Core.Types.OperateResult;
+import HslCommunication.Core.Types.OperateResultExOne;
+import HslCommunication.Profinet.Siemens.SiemensPLCS;
+import HslCommunication.Profinet.Siemens.SiemensS7Net;
+import com.warewms.common.exception.ServiceException;
+import com.warewms.hailiang.config.PlcConfig;
+import lombok.extern.slf4j.Slf4j;
+
+import java.nio.charset.StandardCharsets;
+
+@Slf4j
+public class HslTools{
+
+    private SiemensS7Net siemensS7Net;
+    private Boolean IsSuccess;
+
+    public Boolean getSuccess() {
+        return IsSuccess;
+    }
+
+    public HslTools(PlcConfig plcConfig) {
+        log.info("正在创建连接:{},ip:{}",plcConfig.getSiemensPLCS(),plcConfig.getIp());
+        siemensS7Net = new SiemensS7Net(plcConfig.getSiemensPLCS(), plcConfig.getIp());
+        siemensS7Net.setSlot(plcConfig.getSlot());
+        siemensS7Net.setRack(plcConfig.getRack());
+        OperateResult operateResult = siemensS7Net.ConnectServer();
+        this.IsSuccess = operateResult.IsSuccess;
+        if (!this.IsSuccess){
+            log.info("连接结果:{}--{}--{}",operateResult.IsSuccess,operateResult.Message,operateResult.ErrorCode);
+        }
+    }
+
+
+    public OperateResult closeConn() {
+        OperateResult result = OperateResult.CreateSuccessResult();
+        try {
+            result = siemensS7Net.ConnectClose();
+        } catch (Exception e) {
+
+        }
+        siemensS7Net = null;
+        return result;
+    }
+
+    public boolean writeInt(String address, Integer value) {
+        OperateResult result = siemensS7Net.Write(address, value);
+        log.info(result.Message);
+        if (!result.IsSuccess) {
+            closeConn();
+            throw new ServiceException(String.format("写入数据失败,db:%s,数据:%d,错误信息:%s", address, value, result.Message));
+        }
+        return result.IsSuccess;
+    }
+
+    public boolean writeShort(String address, short value) {
+        OperateResult result = siemensS7Net.Write(address, value);
+        log.info(result.Message);
+        if (!result.IsSuccess) {
+            throw new ServiceException(String.format("写入数据失败,db:%s,错误信息:%s", address, result.Message));
+        } else {
+            log.info(String.format("写入数据完成,db:%s,数据:%d", address, value));
+        }
+        return result.IsSuccess;
+    }
+
+    public boolean writeBoolean(String address, Boolean value) {
+        OperateResult result = siemensS7Net.Write(address, value);
+        if (!result.IsSuccess) {
+            throw new ServiceException(String.format("写入数据失败,db:%s,错误信息:%s", address, address, result.Message));
+        } else {
+            log.info(String.format("写入数据完成,db:%s,数据:%b", address, value));
+        }
+        return result.IsSuccess;
+    }
+
+    public boolean writeString(String address, String value) {
+        OperateResult result = siemensS7Net.Write(address, value.getBytes(StandardCharsets.US_ASCII));
+        if (!result.IsSuccess) {
+            throw new ServiceException(String.format("写入数据失败,db:%s,错误信息:%s", address, result.Message));
+        } else {
+            log.info(String.format("写入数据完成,db:%s,数据:%s", address, value));
+        }
+        return result.IsSuccess;
+    }
+
+    public boolean writeStringStr(String address, String value) {
+        OperateResult result = siemensS7Net.Write(address, value);
+        if (!result.IsSuccess) {
+            throw new ServiceException(String.format("写入数据失败,db:%s,错误信息:%s", address, result.Message));
+        } else {
+            log.info(String.format("写入数据完成,db:%s,数据:%s", address, value));
+        }
+        return result.IsSuccess;
+    }
+
+    public String getString(String address) {
+        OperateResultExOne<String> result = siemensS7Net.ReadString(address);
+        if (!result.IsSuccess) {
+            log.error(String.format(String.format("String类型读取数据失败,db:%s,错误信息:%s", address, result.Message)));
+            return "";
+        } else {
+            return result.Content;
+        }
+    }
+
+    public boolean getBool(String address) {
+        OperateResultExOne<Boolean> result = siemensS7Net.ReadBool(address);
+        if (!result.IsSuccess) {
+            log.error(String.format(String.format("Bool类型读取数据失败,db:%s,错误信息:%s", address, result.Message)));
+            return false;
+        } else {
+            return result.Content;
+        }
+    }
+
+    public int getInt(String address) {
+        OperateResultExOne<Integer> result = siemensS7Net.ReadInt32(address);
+        if (!result.IsSuccess) {
+            log.error(String.format(String.format("int类型读取数据失败,db:%s,错误信息:%s", address, result.Message)));
+            return 0;
+        } else {
+            return result.Content;
+        }
+    }
+
+    public Float getFlot(String address) {
+        OperateResultExOne<Float> result = siemensS7Net.ReadFloat(address);
+        if (!result.IsSuccess) {
+            log.error(String.format(String.format("flot类型读取数据失败,db:%s,错误信息:%s", address, result.Message)));
+            return 0F;
+        } else {
+            return result.Content;
+        }
+    }
+
+    public Double getDabble(String address) {
+        OperateResultExOne<Double> result = siemensS7Net.ReadDouble(address);
+        if (!result.IsSuccess) {
+            log.error(String.format(String.format("dabble类型读取数据失败,db:%s,错误信息:%s", address, result.Message)));
+            return 0D;
+        } else {
+            return result.Content;
+        }
+    }
+}

+ 0 - 22
warewms-ui/.editorconfig

@@ -1,22 +0,0 @@
-# 告诉EditorConfig插件,这是根文件,不用继续往上查找
-root = true
-
-# 匹配全部文件
-[*]
-# 设置字符集
-charset = utf-8
-# 缩进风格,可选space、tab
-indent_style = space
-# 缩进的空格数
-indent_size = 2
-# 结尾换行符,可选lf、cr、crlf
-end_of_line = lf
-# 在文件结尾插入新行
-insert_final_newline = true
-# 删除一行中的前后空格
-trim_trailing_whitespace = true
-
-# 匹配md结尾的文件
-[*.md]
-insert_final_newline = false
-trim_trailing_whitespace = false

+ 0 - 11
warewms-ui/.env.development

@@ -1,11 +0,0 @@
-# 页面标题
-VUE_APP_TITLE = 若依管理系统
-
-# 开发环境配置
-ENV = 'development'
-
-# 若依管理系统/开发环境
-VUE_APP_BASE_API = 'http://localhost:8080'
-
-# 路由懒加载
-VUE_CLI_BABEL_TRANSPILE_MODULES = true

+ 0 - 8
warewms-ui/.env.production

@@ -1,8 +0,0 @@
-# 页面标题
-VUE_APP_TITLE = 若依管理系统
-
-# 生产环境配置
-ENV = 'production'
-
-# 若依管理系统/生产环境
-VUE_APP_BASE_API = 'http://localhost:8080'

+ 0 - 10
warewms-ui/.env.staging

@@ -1,10 +0,0 @@
-# 页面标题
-VUE_APP_TITLE = 若依管理系统
-
-NODE_ENV = production
-
-# 测试环境配置
-ENV = 'staging'
-
-# 若依管理系统/测试环境
-VUE_APP_BASE_API = '/stage-api'

+ 0 - 10
warewms-ui/.eslintignore

@@ -1,10 +0,0 @@
-# 忽略build目录下类型为js的文件的语法检查
-build/*.js
-# 忽略src/assets目录下文件的语法检查
-src/assets
-# 忽略public目录下文件的语法检查
-public
-# 忽略当前目录下为js的文件的语法检查
-*.js
-# 忽略当前目录下为vue的文件的语法检查
-*.vue

+ 0 - 199
warewms-ui/.eslintrc.js

@@ -1,199 +0,0 @@
-// ESlint 检查配置
-module.exports = {
-  root: true,
-  parserOptions: {
-    parser: 'babel-eslint',
-    sourceType: 'module'
-  },
-  env: {
-    browser: true,
-    node: true,
-    es6: true,
-  },
-  extends: ['plugin:vue/recommended', 'eslint:recommended'],
-
-  // add your custom rules here
-  //it is base on https://github.com/vuejs/eslint-config-vue
-  rules: {
-    "vue/max-attributes-per-line": [2, {
-      "singleline": 10,
-      "multiline": {
-        "max": 1,
-        "allowFirstLine": false
-      }
-    }],
-    "vue/singleline-html-element-content-newline": "off",
-    "vue/multiline-html-element-content-newline":"off",
-    "vue/name-property-casing": ["error", "PascalCase"],
-    "vue/no-v-html": "off",
-    'accessor-pairs': 2,
-    'arrow-spacing': [2, {
-      'before': true,
-      'after': true
-    }],
-    'block-spacing': [2, 'always'],
-    'brace-style': [2, '1tbs', {
-      'allowSingleLine': true
-    }],
-    'camelcase': [0, {
-      'properties': 'always'
-    }],
-    'comma-dangle': [2, 'never'],
-    'comma-spacing': [2, {
-      'before': false,
-      'after': true
-    }],
-    'comma-style': [2, 'last'],
-    'constructor-super': 2,
-    'curly': [2, 'multi-line'],
-    'dot-location': [2, 'property'],
-    'eol-last': 2,
-    'eqeqeq': ["error", "always", {"null": "ignore"}],
-    'generator-star-spacing': [2, {
-      'before': true,
-      'after': true
-    }],
-    'handle-callback-err': [2, '^(err|error)$'],
-    'indent': [2, 2, {
-      'SwitchCase': 1
-    }],
-    'jsx-quotes': [2, 'prefer-single'],
-    'key-spacing': [2, {
-      'beforeColon': false,
-      'afterColon': true
-    }],
-    'keyword-spacing': [2, {
-      'before': true,
-      'after': true
-    }],
-    'new-cap': [2, {
-      'newIsCap': true,
-      'capIsNew': false
-    }],
-    'new-parens': 2,
-    'no-array-constructor': 2,
-    'no-caller': 2,
-    'no-console': 'off',
-    'no-class-assign': 2,
-    'no-cond-assign': 2,
-    'no-const-assign': 2,
-    'no-control-regex': 0,
-    'no-delete-var': 2,
-    'no-dupe-args': 2,
-    'no-dupe-class-members': 2,
-    'no-dupe-keys': 2,
-    'no-duplicate-case': 2,
-    'no-empty-character-class': 2,
-    'no-empty-pattern': 2,
-    'no-eval': 2,
-    'no-ex-assign': 2,
-    'no-extend-native': 2,
-    'no-extra-bind': 2,
-    'no-extra-boolean-cast': 2,
-    'no-extra-parens': [2, 'functions'],
-    'no-fallthrough': 2,
-    'no-floating-decimal': 2,
-    'no-func-assign': 2,
-    'no-implied-eval': 2,
-    'no-inner-declarations': [2, 'functions'],
-    'no-invalid-regexp': 2,
-    'no-irregular-whitespace': 2,
-    'no-iterator': 2,
-    'no-label-var': 2,
-    'no-labels': [2, {
-      'allowLoop': false,
-      'allowSwitch': false
-    }],
-    'no-lone-blocks': 2,
-    'no-mixed-spaces-and-tabs': 2,
-    'no-multi-spaces': 2,
-    'no-multi-str': 2,
-    'no-multiple-empty-lines': [2, {
-      'max': 1
-    }],
-    'no-native-reassign': 2,
-    'no-negated-in-lhs': 2,
-    'no-new-object': 2,
-    'no-new-require': 2,
-    'no-new-symbol': 2,
-    'no-new-wrappers': 2,
-    'no-obj-calls': 2,
-    'no-octal': 2,
-    'no-octal-escape': 2,
-    'no-path-concat': 2,
-    'no-proto': 2,
-    'no-redeclare': 2,
-    'no-regex-spaces': 2,
-    'no-return-assign': [2, 'except-parens'],
-    'no-self-assign': 2,
-    'no-self-compare': 2,
-    'no-sequences': 2,
-    'no-shadow-restricted-names': 2,
-    'no-spaced-func': 2,
-    'no-sparse-arrays': 2,
-    'no-this-before-super': 2,
-    'no-throw-literal': 2,
-    'no-trailing-spaces': 2,
-    'no-undef': 2,
-    'no-undef-init': 2,
-    'no-unexpected-multiline': 2,
-    'no-unmodified-loop-condition': 2,
-    'no-unneeded-ternary': [2, {
-      'defaultAssignment': false
-    }],
-    'no-unreachable': 2,
-    'no-unsafe-finally': 2,
-    'no-unused-vars': [2, {
-      'vars': 'all',
-      'args': 'none'
-    }],
-    'no-useless-call': 2,
-    'no-useless-computed-key': 2,
-    'no-useless-constructor': 2,
-    'no-useless-escape': 0,
-    'no-whitespace-before-property': 2,
-    'no-with': 2,
-    'one-var': [2, {
-      'initialized': 'never'
-    }],
-    'operator-linebreak': [2, 'after', {
-      'overrides': {
-        '?': 'before',
-        ':': 'before'
-      }
-    }],
-    'padded-blocks': [2, 'never'],
-    'quotes': [2, 'single', {
-      'avoidEscape': true,
-      'allowTemplateLiterals': true
-    }],
-    'semi': [2, 'never'],
-    'semi-spacing': [2, {
-      'before': false,
-      'after': true
-    }],
-    'space-before-blocks': [2, 'always'],
-    'space-before-function-paren': [2, 'never'],
-    'space-in-parens': [2, 'never'],
-    'space-infix-ops': 2,
-    'space-unary-ops': [2, {
-      'words': true,
-      'nonwords': false
-    }],
-    'spaced-comment': [2, 'always', {
-      'markers': ['global', 'globals', 'eslint', 'eslint-disable', '*package', '!', ',']
-    }],
-    'template-curly-spacing': [2, 'never'],
-    'use-isnan': 2,
-    'valid-typeof': 2,
-    'wrap-iife': [2, 'any'],
-    'yield-star-spacing': [2, 'both'],
-    'yoda': [2, 'never'],
-    'prefer-const': 2,
-    'no-debugger': process.env.NODE_ENV === 'production' ? 2 : 0,
-    'object-curly-spacing': [2, 'always', {
-      objectsInObjects: false
-    }],
-    'array-bracket-spacing': [2, 'never']
-  }
-}

+ 0 - 23
warewms-ui/.gitignore

@@ -1,23 +0,0 @@
-.DS_Store
-node_modules/
-dist/
-npm-debug.log*
-yarn-debug.log*
-yarn-error.log*
-**/*.log
-
-tests/**/coverage/
-tests/e2e/reports
-selenium-debug.log
-
-# Editor directories and files
-.idea
-.vscode
-*.suo
-*.ntvs*
-*.njsproj
-*.sln
-*.local
-
-package-lock.json
-yarn.lock

+ 0 - 30
warewms-ui/README.md

@@ -1,30 +0,0 @@
-## 开发
-
-```bash
-# 克隆项目
-git clone https://gitee.com/y_project/RuoYi-Vue
-
-# 进入项目目录
-cd ruoyi-ui
-
-# 安装依赖
-npm install
-
-# 建议不要直接使用 cnpm 安装依赖,会有各种诡异的 bug。可以通过如下操作解决 npm 下载速度慢的问题
-npm install --registry=https://registry.npmmirror.com
-
-# 启动服务
-npm run dev
-```
-
-浏览器访问 http://localhost:80
-
-## 发布
-
-```bash
-# 构建测试环境
-npm run build:stage
-
-# 构建生产环境
-npm run build:prod
-```

+ 0 - 13
warewms-ui/babel.config.js

@@ -1,13 +0,0 @@
-module.exports = {
-  presets: [
-    // https://github.com/vuejs/vue-cli/tree/master/packages/@vue/babel-preset-app
-    '@vue/cli-plugin-babel/preset'
-  ],
-  'env': {
-    'development': {
-      // babel-plugin-dynamic-import-node plugin only does one thing by converting all import() to require().
-      // This plugin can significantly increase the speed of hot updates, when you have a large number of pages.
-      'plugins': ['dynamic-import-node']
-    }
-  }
-}

+ 0 - 12
warewms-ui/bin/build.bat

@@ -1,12 +0,0 @@
-@echo off
-echo.
-echo [信息] 打包Web工程,生成dist文件。
-echo.
-
-%~d0
-cd %~dp0
-
-cd ..
-npm run build:prod
-
-pause

+ 0 - 12
warewms-ui/bin/package.bat

@@ -1,12 +0,0 @@
-@echo off
-echo.
-echo [信息] 安装Web工程,生成node_modules文件。
-echo.
-
-%~d0
-cd %~dp0
-
-cd ..
-npm install --registry=https://registry.npmmirror.com
-
-pause

+ 0 - 12
warewms-ui/bin/run-web.bat

@@ -1,12 +0,0 @@
-@echo off
-echo.
-echo [信息] 使用 Vue CLI 命令运行 Web 工程。
-echo.
-
-%~d0
-cd %~dp0
-
-cd ..
-npm run dev
-
-pause

+ 0 - 35
warewms-ui/build/index.js

@@ -1,35 +0,0 @@
-const { run } = require('runjs')
-const chalk = require('chalk')
-const config = require('../vue.config.js')
-const rawArgv = process.argv.slice(2)
-const args = rawArgv.join(' ')
-
-if (process.env.npm_config_preview || rawArgv.includes('--preview')) {
-  const report = rawArgv.includes('--report')
-
-  run(`vue-cli-service build ${args}`)
-
-  const port = 9526
-  const publicPath = config.publicPath
-
-  var connect = require('connect')
-  var serveStatic = require('serve-static')
-  const app = connect()
-
-  app.use(
-    publicPath,
-    serveStatic('./dist', {
-      index: ['index.html', '/']
-    })
-  )
-
-  app.listen(port, function () {
-    console.log(chalk.green(`> Preview at  http://localhost:${port}${publicPath}`))
-    if (report) {
-      console.log(chalk.green(`> Report at  http://localhost:${port}${publicPath}report.html`))
-    }
-
-  })
-} else {
-  run(`vue-cli-service build ${args}`)
-}

+ 0 - 90
warewms-ui/package.json

@@ -1,90 +0,0 @@
-{
-  "name": "ruoyi",
-  "version": "3.8.5",
-  "description": "若依管理系统",
-  "author": "若依",
-  "license": "MIT",
-  "scripts": {
-    "dev": "vue-cli-service serve",
-    "build:prod": "vue-cli-service build",
-    "build:stage": "vue-cli-service build --mode staging",
-    "preview": "node build/index.js --preview",
-    "lint": "eslint --ext .js,.vue src"
-  },
-  "husky": {
-    "hooks": {
-      "pre-commit": "lint-staged"
-    }
-  },
-  "lint-staged": {
-    "src/**/*.{js,vue}": [
-      "eslint --fix",
-      "git add"
-    ]
-  },
-  "keywords": [
-    "vue",
-    "admin",
-    "dashboard",
-    "element-ui",
-    "boilerplate",
-    "admin-template",
-    "management-system"
-  ],
-  "repository": {
-    "type": "git",
-    "url": "https://gitee.com/y_project/RuoYi-Vue.git"
-  },
-  "dependencies": {
-    "@riophae/vue-treeselect": "0.4.0",
-    "axios": "0.24.0",
-    "clipboard": "2.0.8",
-    "core-js": "3.25.3",
-    "echarts": "5.4.0",
-    "element-ui": "2.15.12",
-    "file-saver": "2.0.5",
-    "fuse.js": "6.4.3",
-    "highlight.js": "9.18.5",
-    "js-beautify": "1.13.0",
-    "js-cookie": "3.0.1",
-    "jsencrypt": "3.0.0-rc.1",
-    "nprogress": "0.2.0",
-    "quill": "1.3.7",
-    "screenfull": "5.0.2",
-    "sortablejs": "1.10.2",
-    "vue": "2.6.12",
-    "vue-count-to": "1.0.13",
-    "vue-cropper": "0.5.5",
-    "vue-meta": "2.4.0",
-    "vue-router": "3.4.9",
-    "vuedraggable": "2.24.3",
-    "vuex": "3.6.0"
-  },
-  "devDependencies": {
-    "@vue/cli-plugin-babel": "4.4.6",
-    "@vue/cli-plugin-eslint": "4.4.6",
-    "@vue/cli-service": "4.4.6",
-    "babel-eslint": "10.1.0",
-    "babel-plugin-dynamic-import-node": "2.3.3",
-    "chalk": "4.1.0",
-    "compression-webpack-plugin": "5.0.2",
-    "connect": "3.6.6",
-    "eslint": "7.15.0",
-    "eslint-plugin-vue": "7.2.0",
-    "lint-staged": "10.5.3",
-    "runjs": "4.4.2",
-    "sass": "1.32.13",
-    "sass-loader": "10.1.1",
-    "script-ext-html-webpack-plugin": "2.1.5",
-    "svg-sprite-loader": "5.1.1",
-    "vue-template-compiler": "2.6.12"
-  },
-  "engines": {
-    "node": ">=8.9",
-    "npm": ">= 3.0.0"
-  },
-  "browserslist": [
-    "> 1%",
-    "last 2 versions"
-  ]
-}

binární
warewms-ui/public/favicon.ico


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 46
warewms-ui/public/html/ie.html


+ 0 - 208
warewms-ui/public/index.html

@@ -1,208 +0,0 @@
-<!DOCTYPE html>
-<html>
-  <head>
-    <meta charset="utf-8">
-    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
-    <meta name="renderer" content="webkit">
-    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
-    <link rel="icon" href="<%= BASE_URL %>favicon.ico">
-    <title><%= webpackConfig.name %></title>
-    <!--[if lt IE 11]><script>window.location.href='/html/ie.html';</script><![endif]-->
-	  <style>
-    html,
-    body,
-    #app {
-      height: 100%;
-      margin: 0px;
-      padding: 0px;
-    }
-    .chromeframe {
-      margin: 0.2em 0;
-      background: #ccc;
-      color: #000;
-      padding: 0.2em 0;
-    }
-
-    #loader-wrapper {
-      position: fixed;
-      top: 0;
-      left: 0;
-      width: 100%;
-      height: 100%;
-      z-index: 999999;
-    }
-
-    #loader {
-      display: block;
-      position: relative;
-      left: 50%;
-      top: 50%;
-      width: 150px;
-      height: 150px;
-      margin: -75px 0 0 -75px;
-      border-radius: 50%;
-      border: 3px solid transparent;
-      border-top-color: #FFF;
-      -webkit-animation: spin 2s linear infinite;
-      -ms-animation: spin 2s linear infinite;
-      -moz-animation: spin 2s linear infinite;
-      -o-animation: spin 2s linear infinite;
-      animation: spin 2s linear infinite;
-      z-index: 1001;
-    }
-
-    #loader:before {
-      content: "";
-      position: absolute;
-      top: 5px;
-      left: 5px;
-      right: 5px;
-      bottom: 5px;
-      border-radius: 50%;
-      border: 3px solid transparent;
-      border-top-color: #FFF;
-      -webkit-animation: spin 3s linear infinite;
-      -moz-animation: spin 3s linear infinite;
-      -o-animation: spin 3s linear infinite;
-      -ms-animation: spin 3s linear infinite;
-      animation: spin 3s linear infinite;
-    }
-
-    #loader:after {
-      content: "";
-      position: absolute;
-      top: 15px;
-      left: 15px;
-      right: 15px;
-      bottom: 15px;
-      border-radius: 50%;
-      border: 3px solid transparent;
-      border-top-color: #FFF;
-      -moz-animation: spin 1.5s linear infinite;
-      -o-animation: spin 1.5s linear infinite;
-      -ms-animation: spin 1.5s linear infinite;
-      -webkit-animation: spin 1.5s linear infinite;
-      animation: spin 1.5s linear infinite;
-    }
-
-
-    @-webkit-keyframes spin {
-      0% {
-        -webkit-transform: rotate(0deg);
-        -ms-transform: rotate(0deg);
-        transform: rotate(0deg);
-      }
-      100% {
-        -webkit-transform: rotate(360deg);
-        -ms-transform: rotate(360deg);
-        transform: rotate(360deg);
-      }
-    }
-
-    @keyframes spin {
-      0% {
-        -webkit-transform: rotate(0deg);
-        -ms-transform: rotate(0deg);
-        transform: rotate(0deg);
-      }
-      100% {
-        -webkit-transform: rotate(360deg);
-        -ms-transform: rotate(360deg);
-        transform: rotate(360deg);
-      }
-    }
-
-
-    #loader-wrapper .loader-section {
-      position: fixed;
-      top: 0;
-      width: 51%;
-      height: 100%;
-      background: #7171C6;
-      z-index: 1000;
-      -webkit-transform: translateX(0);
-      -ms-transform: translateX(0);
-      transform: translateX(0);
-    }
-
-    #loader-wrapper .loader-section.section-left {
-      left: 0;
-    }
-
-    #loader-wrapper .loader-section.section-right {
-      right: 0;
-    }
-
-
-    .loaded #loader-wrapper .loader-section.section-left {
-      -webkit-transform: translateX(-100%);
-      -ms-transform: translateX(-100%);
-      transform: translateX(-100%);
-      -webkit-transition: all 0.7s 0.3s cubic-bezier(0.645, 0.045, 0.355, 1.000);
-      transition: all 0.7s 0.3s cubic-bezier(0.645, 0.045, 0.355, 1.000);
-    }
-
-    .loaded #loader-wrapper .loader-section.section-right {
-      -webkit-transform: translateX(100%);
-      -ms-transform: translateX(100%);
-      transform: translateX(100%);
-      -webkit-transition: all 0.7s 0.3s cubic-bezier(0.645, 0.045, 0.355, 1.000);
-      transition: all 0.7s 0.3s cubic-bezier(0.645, 0.045, 0.355, 1.000);
-    }
-
-    .loaded #loader {
-      opacity: 0;
-      -webkit-transition: all 0.3s ease-out;
-      transition: all 0.3s ease-out;
-    }
-
-    .loaded #loader-wrapper {
-      visibility: hidden;
-      -webkit-transform: translateY(-100%);
-      -ms-transform: translateY(-100%);
-      transform: translateY(-100%);
-      -webkit-transition: all 0.3s 1s ease-out;
-      transition: all 0.3s 1s ease-out;
-    }
-
-    .no-js #loader-wrapper {
-      display: none;
-    }
-
-    .no-js h1 {
-      color: #222222;
-    }
-
-    #loader-wrapper .load_title {
-      font-family: 'Open Sans';
-      color: #FFF;
-      font-size: 19px;
-      width: 100%;
-      text-align: center;
-      z-index: 9999999999999;
-      position: absolute;
-      top: 60%;
-      opacity: 1;
-      line-height: 30px;
-    }
-
-    #loader-wrapper .load_title span {
-      font-weight: normal;
-      font-style: italic;
-      font-size: 13px;
-      color: #FFF;
-      opacity: 0.5;
-    }
-  </style>
-  </head>
-  <body>
-    <div id="app">
-	    <div id="loader-wrapper">
-		    <div id="loader"></div>
-		    <div class="loader-section section-left"></div>
-		    <div class="loader-section section-right"></div>
-		    <div class="load_title">正在加载系统资源,请耐心等待</div>
-        </div>
-	</div>
-  </body>
-</html>

+ 0 - 2
warewms-ui/public/robots.txt

@@ -1,2 +0,0 @@
-User-agent: *
-Disallow: /

+ 0 - 28
warewms-ui/src/App.vue

@@ -1,28 +0,0 @@
-<template>
-  <div id="app">
-    <router-view />
-    <theme-picker />
-  </div>
-</template>
-
-<script>
-import ThemePicker from "@/components/ThemePicker";
-
-export default {
-  name: "App",
-  components: { ThemePicker },
-    metaInfo() {
-        return {
-            title: this.$store.state.settings.dynamicTitle && this.$store.state.settings.title,
-            titleTemplate: title => {
-                return title ? `${title} - ${process.env.VUE_APP_TITLE}` : process.env.VUE_APP_TITLE
-            }
-        }
-    }
-};
-</script>
-<style scoped>
-#app .theme-picker {
-  display: none;
-}
-</style>

+ 0 - 59
warewms-ui/src/api/login.js

@@ -1,59 +0,0 @@
-import request from '@/utils/request'
-
-// 登录方法
-export function login(username, password, code, uuid) {
-  const data = {
-    username,
-    password,
-    code,
-    uuid
-  }
-  return request({
-    url: '/login',
-    headers: {
-      isToken: false
-    },
-    method: 'post',
-    data: data
-  })
-}
-
-// 注册方法
-export function register(data) {
-  return request({
-    url: '/register',
-    headers: {
-      isToken: false
-    },
-    method: 'post',
-    data: data
-  })
-}
-
-// 获取用户详细信息
-export function getInfo() {
-  return request({
-    url: '/getInfo',
-    method: 'get'
-  })
-}
-
-// 退出方法
-export function logout() {
-  return request({
-    url: '/logout',
-    method: 'post'
-  })
-}
-
-// 获取验证码
-export function getCodeImg() {
-  return request({
-    url: '/captchaImage',
-    headers: {
-      isToken: false
-    },
-    method: 'get',
-    timeout: 20000
-  })
-}

+ 0 - 9
warewms-ui/src/api/menu.js

@@ -1,9 +0,0 @@
-import request from '@/utils/request'
-
-// 获取路由
-export const getRouters = () => {
-  return request({
-    url: '/getRouters',
-    method: 'get'
-  })
-}

+ 0 - 57
warewms-ui/src/api/monitor/cache.js

@@ -1,57 +0,0 @@
-import request from '@/utils/request'
-
-// 查询缓存详细
-export function getCache() {
-  return request({
-    url: '/monitor/cache',
-    method: 'get'
-  })
-}
-
-// 查询缓存名称列表
-export function listCacheName() {
-  return request({
-    url: '/monitor/cache/getNames',
-    method: 'get'
-  })
-}
-
-// 查询缓存键名列表
-export function listCacheKey(cacheName) {
-  return request({
-    url: '/monitor/cache/getKeys/' + cacheName,
-    method: 'get'
-  })
-}
-
-// 查询缓存内容
-export function getCacheValue(cacheName, cacheKey) {
-  return request({
-    url: '/monitor/cache/getValue/' + cacheName + '/' + cacheKey,
-    method: 'get'
-  })
-}
-
-// 清理指定名称缓存
-export function clearCacheName(cacheName) {
-  return request({
-    url: '/monitor/cache/clearCacheName/' + cacheName,
-    method: 'delete'
-  })
-}
-
-// 清理指定键名缓存
-export function clearCacheKey(cacheKey) {
-  return request({
-    url: '/monitor/cache/clearCacheKey/' + cacheKey,
-    method: 'delete'
-  })
-}
-
-// 清理全部缓存
-export function clearCacheAll() {
-  return request({
-    url: '/monitor/cache/clearCacheAll',
-    method: 'delete'
-  })
-}

+ 0 - 71
warewms-ui/src/api/monitor/job.js

@@ -1,71 +0,0 @@
-import request from '@/utils/request'
-
-// 查询定时任务调度列表
-export function listJob(query) {
-  return request({
-    url: '/monitor/job/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询定时任务调度详细
-export function getJob(jobId) {
-  return request({
-    url: '/monitor/job/' + jobId,
-    method: 'get'
-  })
-}
-
-// 新增定时任务调度
-export function addJob(data) {
-  return request({
-    url: '/monitor/job',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改定时任务调度
-export function updateJob(data) {
-  return request({
-    url: '/monitor/job',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除定时任务调度
-export function delJob(jobId) {
-  return request({
-    url: '/monitor/job/' + jobId,
-    method: 'delete'
-  })
-}
-
-// 任务状态修改
-export function changeJobStatus(jobId, status) {
-  const data = {
-    jobId,
-    status
-  }
-  return request({
-    url: '/monitor/job/changeStatus',
-    method: 'put',
-    data: data
-  })
-}
-
-
-// 定时任务立即执行一次
-export function runJob(jobId, jobGroup) {
-  const data = {
-    jobId,
-    jobGroup
-  }
-  return request({
-    url: '/monitor/job/run',
-    method: 'put',
-    data: data
-  })
-}

+ 0 - 26
warewms-ui/src/api/monitor/jobLog.js

@@ -1,26 +0,0 @@
-import request from '@/utils/request'
-
-// 查询调度日志列表
-export function listJobLog(query) {
-  return request({
-    url: '/monitor/jobLog/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 删除调度日志
-export function delJobLog(jobLogId) {
-  return request({
-    url: '/monitor/jobLog/' + jobLogId,
-    method: 'delete'
-  })
-}
-
-// 清空调度日志
-export function cleanJobLog() {
-  return request({
-    url: '/monitor/jobLog/clean',
-    method: 'delete'
-  })
-}

+ 0 - 34
warewms-ui/src/api/monitor/logininfor.js

@@ -1,34 +0,0 @@
-import request from '@/utils/request'
-
-// 查询登录日志列表
-export function list(query) {
-  return request({
-    url: '/monitor/logininfor/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 删除登录日志
-export function delLogininfor(infoId) {
-  return request({
-    url: '/monitor/logininfor/' + infoId,
-    method: 'delete'
-  })
-}
-
-// 解锁用户登录状态
-export function unlockLogininfor(userName) {
-  return request({
-    url: '/monitor/logininfor/unlock/' + userName,
-    method: 'get'
-  })
-}
-
-// 清空登录日志
-export function cleanLogininfor() {
-  return request({
-    url: '/monitor/logininfor/clean',
-    method: 'delete'
-  })
-}

+ 0 - 18
warewms-ui/src/api/monitor/online.js

@@ -1,18 +0,0 @@
-import request from '@/utils/request'
-
-// 查询在线用户列表
-export function list(query) {
-  return request({
-    url: '/monitor/online/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 强退用户
-export function forceLogout(tokenId) {
-  return request({
-    url: '/monitor/online/' + tokenId,
-    method: 'delete'
-  })
-}

+ 0 - 26
warewms-ui/src/api/monitor/operlog.js

@@ -1,26 +0,0 @@
-import request from '@/utils/request'
-
-// 查询操作日志列表
-export function list(query) {
-  return request({
-    url: '/monitor/operlog/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 删除操作日志
-export function delOperlog(operId) {
-  return request({
-    url: '/monitor/operlog/' + operId,
-    method: 'delete'
-  })
-}
-
-// 清空操作日志
-export function cleanOperlog() {
-  return request({
-    url: '/monitor/operlog/clean',
-    method: 'delete'
-  })
-}

+ 0 - 9
warewms-ui/src/api/monitor/server.js

@@ -1,9 +0,0 @@
-import request from '@/utils/request'
-
-// 获取服务信息
-export function getServer() {
-  return request({
-    url: '/monitor/server',
-    method: 'get'
-  })
-}

+ 0 - 60
warewms-ui/src/api/system/config.js

@@ -1,60 +0,0 @@
-import request from '@/utils/request'
-
-// 查询参数列表
-export function listConfig(query) {
-  return request({
-    url: '/system/config/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询参数详细
-export function getConfig(configId) {
-  return request({
-    url: '/system/config/' + configId,
-    method: 'get'
-  })
-}
-
-// 根据参数键名查询参数值
-export function getConfigKey(configKey) {
-  return request({
-    url: '/system/config/configKey/' + configKey,
-    method: 'get'
-  })
-}
-
-// 新增参数配置
-export function addConfig(data) {
-  return request({
-    url: '/system/config',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改参数配置
-export function updateConfig(data) {
-  return request({
-    url: '/system/config',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除参数配置
-export function delConfig(configId) {
-  return request({
-    url: '/system/config/' + configId,
-    method: 'delete'
-  })
-}
-
-// 刷新参数缓存
-export function refreshCache() {
-  return request({
-    url: '/system/config/refreshCache',
-    method: 'delete'
-  })
-}

+ 0 - 52
warewms-ui/src/api/system/dept.js

@@ -1,52 +0,0 @@
-import request from '@/utils/request'
-
-// 查询部门列表
-export function listDept(query) {
-  return request({
-    url: '/system/dept/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询部门列表(排除节点)
-export function listDeptExcludeChild(deptId) {
-  return request({
-    url: '/system/dept/list/exclude/' + deptId,
-    method: 'get'
-  })
-}
-
-// 查询部门详细
-export function getDept(deptId) {
-  return request({
-    url: '/system/dept/' + deptId,
-    method: 'get'
-  })
-}
-
-// 新增部门
-export function addDept(data) {
-  return request({
-    url: '/system/dept',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改部门
-export function updateDept(data) {
-  return request({
-    url: '/system/dept',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除部门
-export function delDept(deptId) {
-  return request({
-    url: '/system/dept/' + deptId,
-    method: 'delete'
-  })
-}

+ 0 - 52
warewms-ui/src/api/system/dict/data.js

@@ -1,52 +0,0 @@
-import request from '@/utils/request'
-
-// 查询字典数据列表
-export function listData(query) {
-  return request({
-    url: '/system/dict/data/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询字典数据详细
-export function getData(dictCode) {
-  return request({
-    url: '/system/dict/data/' + dictCode,
-    method: 'get'
-  })
-}
-
-// 根据字典类型查询字典数据信息
-export function getDicts(dictType) {
-  return request({
-    url: '/system/dict/data/type/' + dictType,
-    method: 'get'
-  })
-}
-
-// 新增字典数据
-export function addData(data) {
-  return request({
-    url: '/system/dict/data',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改字典数据
-export function updateData(data) {
-  return request({
-    url: '/system/dict/data',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除字典数据
-export function delData(dictCode) {
-  return request({
-    url: '/system/dict/data/' + dictCode,
-    method: 'delete'
-  })
-}

+ 0 - 60
warewms-ui/src/api/system/dict/type.js

@@ -1,60 +0,0 @@
-import request from '@/utils/request'
-
-// 查询字典类型列表
-export function listType(query) {
-  return request({
-    url: '/system/dict/type/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询字典类型详细
-export function getType(dictId) {
-  return request({
-    url: '/system/dict/type/' + dictId,
-    method: 'get'
-  })
-}
-
-// 新增字典类型
-export function addType(data) {
-  return request({
-    url: '/system/dict/type',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改字典类型
-export function updateType(data) {
-  return request({
-    url: '/system/dict/type',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除字典类型
-export function delType(dictId) {
-  return request({
-    url: '/system/dict/type/' + dictId,
-    method: 'delete'
-  })
-}
-
-// 刷新字典缓存
-export function refreshCache() {
-  return request({
-    url: '/system/dict/type/refreshCache',
-    method: 'delete'
-  })
-}
-
-// 获取字典选择框列表
-export function optionselect() {
-  return request({
-    url: '/system/dict/type/optionselect',
-    method: 'get'
-  })
-}

+ 0 - 60
warewms-ui/src/api/system/menu.js

@@ -1,60 +0,0 @@
-import request from '@/utils/request'
-
-// 查询菜单列表
-export function listMenu(query) {
-  return request({
-    url: '/system/menu/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询菜单详细
-export function getMenu(menuId) {
-  return request({
-    url: '/system/menu/' + menuId,
-    method: 'get'
-  })
-}
-
-// 查询菜单下拉树结构
-export function treeselect() {
-  return request({
-    url: '/system/menu/treeselect',
-    method: 'get'
-  })
-}
-
-// 根据角色ID查询菜单下拉树结构
-export function roleMenuTreeselect(roleId) {
-  return request({
-    url: '/system/menu/roleMenuTreeselect/' + roleId,
-    method: 'get'
-  })
-}
-
-// 新增菜单
-export function addMenu(data) {
-  return request({
-    url: '/system/menu',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改菜单
-export function updateMenu(data) {
-  return request({
-    url: '/system/menu',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除菜单
-export function delMenu(menuId) {
-  return request({
-    url: '/system/menu/' + menuId,
-    method: 'delete'
-  })
-}

+ 0 - 44
warewms-ui/src/api/system/notice.js

@@ -1,44 +0,0 @@
-import request from '@/utils/request'
-
-// 查询公告列表
-export function listNotice(query) {
-  return request({
-    url: '/system/notice/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询公告详细
-export function getNotice(noticeId) {
-  return request({
-    url: '/system/notice/' + noticeId,
-    method: 'get'
-  })
-}
-
-// 新增公告
-export function addNotice(data) {
-  return request({
-    url: '/system/notice',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改公告
-export function updateNotice(data) {
-  return request({
-    url: '/system/notice',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除公告
-export function delNotice(noticeId) {
-  return request({
-    url: '/system/notice/' + noticeId,
-    method: 'delete'
-  })
-}

+ 0 - 44
warewms-ui/src/api/system/post.js

@@ -1,44 +0,0 @@
-import request from '@/utils/request'
-
-// 查询岗位列表
-export function listPost(query) {
-  return request({
-    url: '/system/post/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询岗位详细
-export function getPost(postId) {
-  return request({
-    url: '/system/post/' + postId,
-    method: 'get'
-  })
-}
-
-// 新增岗位
-export function addPost(data) {
-  return request({
-    url: '/system/post',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改岗位
-export function updatePost(data) {
-  return request({
-    url: '/system/post',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除岗位
-export function delPost(postId) {
-  return request({
-    url: '/system/post/' + postId,
-    method: 'delete'
-  })
-}

+ 0 - 119
warewms-ui/src/api/system/role.js

@@ -1,119 +0,0 @@
-import request from '@/utils/request'
-
-// 查询角色列表
-export function listRole(query) {
-  return request({
-    url: '/system/role/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询角色详细
-export function getRole(roleId) {
-  return request({
-    url: '/system/role/' + roleId,
-    method: 'get'
-  })
-}
-
-// 新增角色
-export function addRole(data) {
-  return request({
-    url: '/system/role',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改角色
-export function updateRole(data) {
-  return request({
-    url: '/system/role',
-    method: 'put',
-    data: data
-  })
-}
-
-// 角色数据权限
-export function dataScope(data) {
-  return request({
-    url: '/system/role/dataScope',
-    method: 'put',
-    data: data
-  })
-}
-
-// 角色状态修改
-export function changeRoleStatus(roleId, status) {
-  const data = {
-    roleId,
-    status
-  }
-  return request({
-    url: '/system/role/changeStatus',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除角色
-export function delRole(roleId) {
-  return request({
-    url: '/system/role/' + roleId,
-    method: 'delete'
-  })
-}
-
-// 查询角色已授权用户列表
-export function allocatedUserList(query) {
-  return request({
-    url: '/system/role/authUser/allocatedList',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询角色未授权用户列表
-export function unallocatedUserList(query) {
-  return request({
-    url: '/system/role/authUser/unallocatedList',
-    method: 'get',
-    params: query
-  })
-}
-
-// 取消用户授权角色
-export function authUserCancel(data) {
-  return request({
-    url: '/system/role/authUser/cancel',
-    method: 'put',
-    data: data
-  })
-}
-
-// 批量取消用户授权角色
-export function authUserCancelAll(data) {
-  return request({
-    url: '/system/role/authUser/cancelAll',
-    method: 'put',
-    params: data
-  })
-}
-
-// 授权用户选择
-export function authUserSelectAll(data) {
-  return request({
-    url: '/system/role/authUser/selectAll',
-    method: 'put',
-    params: data
-  })
-}
-
-// 根据角色ID查询部门树结构
-export function deptTreeSelect(roleId) {
-  return request({
-    url: '/system/role/deptTree/' + roleId,
-    method: 'get'
-  })
-}

+ 0 - 135
warewms-ui/src/api/system/user.js

@@ -1,135 +0,0 @@
-import request from '@/utils/request'
-import { parseStrEmpty } from "@/utils/ruoyi";
-
-// 查询用户列表
-export function listUser(query) {
-  return request({
-    url: '/system/user/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询用户详细
-export function getUser(userId) {
-  return request({
-    url: '/system/user/' + parseStrEmpty(userId),
-    method: 'get'
-  })
-}
-
-// 新增用户
-export function addUser(data) {
-  return request({
-    url: '/system/user',
-    method: 'post',
-    data: data
-  })
-}
-
-// 修改用户
-export function updateUser(data) {
-  return request({
-    url: '/system/user',
-    method: 'put',
-    data: data
-  })
-}
-
-// 删除用户
-export function delUser(userId) {
-  return request({
-    url: '/system/user/' + userId,
-    method: 'delete'
-  })
-}
-
-// 用户密码重置
-export function resetUserPwd(userId, password) {
-  const data = {
-    userId,
-    password
-  }
-  return request({
-    url: '/system/user/resetPwd',
-    method: 'put',
-    data: data
-  })
-}
-
-// 用户状态修改
-export function changeUserStatus(userId, status) {
-  const data = {
-    userId,
-    status
-  }
-  return request({
-    url: '/system/user/changeStatus',
-    method: 'put',
-    data: data
-  })
-}
-
-// 查询用户个人信息
-export function getUserProfile() {
-  return request({
-    url: '/system/user/profile',
-    method: 'get'
-  })
-}
-
-// 修改用户个人信息
-export function updateUserProfile(data) {
-  return request({
-    url: '/system/user/profile',
-    method: 'put',
-    data: data
-  })
-}
-
-// 用户密码重置
-export function updateUserPwd(oldPassword, newPassword) {
-  const data = {
-    oldPassword,
-    newPassword
-  }
-  return request({
-    url: '/system/user/profile/updatePwd',
-    method: 'put',
-    params: data
-  })
-}
-
-// 用户头像上传
-export function uploadAvatar(data) {
-  return request({
-    url: '/system/user/profile/avatar',
-    method: 'post',
-    data: data
-  })
-}
-
-// 查询授权角色
-export function getAuthRole(userId) {
-  return request({
-    url: '/system/user/authRole/' + userId,
-    method: 'get'
-  })
-}
-
-// 保存授权角色
-export function updateAuthRole(data) {
-  return request({
-    url: '/system/user/authRole',
-    method: 'put',
-    params: data
-  })
-}
-
-// 查询部门下拉树结构
-export function deptTreeSelect() {
-  return request({
-    url: '/system/user/deptTree',
-    method: 'get'
-  })
-}

+ 0 - 76
warewms-ui/src/api/tool/gen.js

@@ -1,76 +0,0 @@
-import request from '@/utils/request'
-
-// 查询生成表数据
-export function listTable(query) {
-  return request({
-    url: '/tool/gen/list',
-    method: 'get',
-    params: query
-  })
-}
-// 查询db数据库列表
-export function listDbTable(query) {
-  return request({
-    url: '/tool/gen/db/list',
-    method: 'get',
-    params: query
-  })
-}
-
-// 查询表详细信息
-export function getGenTable(tableId) {
-  return request({
-    url: '/tool/gen/' + tableId,
-    method: 'get'
-  })
-}
-
-// 修改代码生成信息
-export function updateGenTable(data) {
-  return request({
-    url: '/tool/gen',
-    method: 'put',
-    data: data
-  })
-}
-
-// 导入表
-export function importTable(data) {
-  return request({
-    url: '/tool/gen/importTable',
-    method: 'post',
-    params: data
-  })
-}
-
-// 预览生成代码
-export function previewTable(tableId) {
-  return request({
-    url: '/tool/gen/preview/' + tableId,
-    method: 'get'
-  })
-}
-
-// 删除表数据
-export function delTable(tableId) {
-  return request({
-    url: '/tool/gen/' + tableId,
-    method: 'delete'
-  })
-}
-
-// 生成代码(自定义路径)
-export function genCode(tableName) {
-  return request({
-    url: '/tool/gen/genCode/' + tableName,
-    method: 'get'
-  })
-}
-
-// 同步数据库
-export function synchDb(tableName) {
-  return request({
-    url: '/tool/gen/synchDb/' + tableName,
-    method: 'get'
-  })
-}

binární
warewms-ui/src/assets/401_images/401.gif


binární
warewms-ui/src/assets/404_images/404.png


binární
warewms-ui/src/assets/404_images/404_cloud.png


+ 0 - 9
warewms-ui/src/assets/icons/index.js

@@ -1,9 +0,0 @@
-import Vue from 'vue'
-import SvgIcon from '@/components/SvgIcon'// svg component
-
-// register globally
-Vue.component('svg-icon', SvgIcon)
-
-const req = require.context('./svg', false, /\.svg$/)
-const requireAll = requireContext => requireContext.keys().map(requireContext)
-requireAll(req)

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/404.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/bug.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/build.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/button.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/cascader.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/chart.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M0 54.857h36.571V128H0V54.857zM91.429 27.43H128V128H91.429V27.429zM45.714 0h36.572v128H45.714V0z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/checkbox.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/clipboard.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/code.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/color.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/component.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/dashboard.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/date-range.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/date.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/dict.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/documentation.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M71.984 44.815H115.9L71.984 9.642v35.173zM16.094.05h63.875l47.906 38.37v76.74c0 3.392-1.682 6.645-4.677 9.044-2.995 2.399-7.056 3.746-11.292 3.746H16.094c-4.236 0-8.297-1.347-11.292-3.746-2.995-2.399-4.677-5.652-4.677-9.044V12.84C.125 5.742 7.23.05 16.094.05zm71.86 102.32V89.58h-71.86v12.79h71.86zm23.952-25.58V64H16.094v12.79h95.812z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/download.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/drag.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M73.137 29.08h-9.209 29.7L63.886.093 34.373 29.08h20.49v27.035H27.238v17.948h27.625v27.133h18.274V74.063h27.41V56.115h-27.41V29.08zm-9.245 98.827l27.518-26.711H36.59l27.302 26.71zM.042 64.982l27.196 27.029V38.167L.042 64.982zm100.505-26.815V92.01l27.41-27.029-27.41-26.815z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/druid.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/edit.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/education.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/email.svg

@@ -1 +0,0 @@
-<svg width="128" height="96" xmlns="http://www.w3.org/2000/svg"><path d="M64.125 56.975L120.188.912A12.476 12.476 0 0 0 115.5 0h-103c-1.588 0-3.113.3-4.513.838l56.138 56.137z"/><path d="M64.125 68.287l-62.3-62.3A12.42 12.42 0 0 0 0 12.5v71C0 90.4 5.6 96 12.5 96h103c6.9 0 12.5-5.6 12.5-12.5v-71a12.47 12.47 0 0 0-1.737-6.35L64.125 68.287z"/></svg>

+ 0 - 1
warewms-ui/src/assets/icons/svg/example.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M96.258 57.462h31.421C124.794 27.323 100.426 2.956 70.287.07v31.422a32.856 32.856 0 0 1 25.971 25.97zm-38.796-25.97V.07C27.323 2.956 2.956 27.323.07 57.462h31.422a32.856 32.856 0 0 1 25.97-25.97zm12.825 64.766v31.421c30.46-2.885 54.507-27.253 57.713-57.712H96.579c-2.886 13.466-13.146 23.726-26.292 26.291zM31.492 70.287H.07c2.886 30.46 27.253 54.507 57.713 57.713V96.579c-13.466-2.886-23.726-13.146-26.291-26.292z"/></svg>

+ 0 - 1
warewms-ui/src/assets/icons/svg/excel.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M78.208 16.576v8.384h38.72v5.376h-38.72v8.704h38.72v5.376h-38.72v8.576h38.72v5.376h-38.72v8.576h38.72v5.376h-38.72v8.576h38.72v5.376h-38.72v8.512h38.72v5.376h-38.72v11.136H128v-94.72H78.208zM0 114.368L72.128 128V0L0 13.632v100.736z"/><path d="M28.672 82.56h-11.2l14.784-23.488-14.08-22.592h11.52l8.192 14.976 8.448-14.976h11.136l-14.08 22.208L58.368 82.56H46.656l-8.768-15.68z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/exit-fullscreen.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/eye-open.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/eye.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/form.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/fullscreen.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M38.47 52L52 38.462l-23.648-23.67L43.209 0H.035L0 43.137l14.757-14.865L38.47 52zm74.773 47.726L89.526 76 76 89.536l23.648 23.672L84.795 128h43.174L128 84.863l-14.757 14.863zM89.538 52l23.668-23.648L128 43.207V.038L84.866 0 99.73 14.76 76 38.472 89.538 52zM38.46 76L14.792 99.651 0 84.794v43.173l43.137.033-14.865-14.757L52 89.53 38.46 76z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/github.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/guide.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M1.482 70.131l36.204 16.18 69.932-65.485-61.38 70.594 46.435 18.735c1.119.425 2.397-.17 2.797-1.363v-.085L127.998.047 1.322 65.874c-1.12.597-1.519 1.959-1.04 3.151.32.511.72.937 1.2 1.107zm44.676 57.821L64.22 107.26l-18.062-7.834v28.527z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/icon.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/input.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/international.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/job.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/language.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/link.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M115.625 127.937H.063V12.375h57.781v12.374H12.438v90.813h90.813V70.156h12.374z"/><path d="M116.426 2.821l8.753 8.753-56.734 56.734-8.753-8.745z"/><path d="M127.893 37.982h-12.375V12.375H88.706V0h39.187z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/list.svg


+ 0 - 1
warewms-ui/src/assets/icons/svg/lock.svg

@@ -1 +0,0 @@
-<svg width="128" height="128" xmlns="http://www.w3.org/2000/svg"><path d="M119.88 49.674h-7.987V39.52C111.893 17.738 90.45.08 63.996.08 37.543.08 16.1 17.738 16.1 39.52v10.154H8.113c-4.408 0-7.987 2.94-7.987 6.577v65.13c0 3.637 3.57 6.577 7.987 6.577H119.88c4.407 0 7.987-2.94 7.987-6.577v-65.13c-.008-3.636-3.58-6.577-7.987-6.577zm-23.953 0H32.065V39.52c0-14.524 14.301-26.295 31.931-26.295 17.63 0 31.932 11.777 31.932 26.295v10.153z"/></svg>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/log.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/logininfor.svg


Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 0 - 1
warewms-ui/src/assets/icons/svg/message.svg


+ 0 - 0
warewms-ui/src/assets/icons/svg/money.svg


Některé soubory nejsou zobrazeny, neboť je v těchto rozdílových datech změněno mnoho souborů