| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168 |
- package com.mes.config;
- import org.springframework.boot.context.properties.ConfigurationProperties;
- import java.util.ArrayList;
- import java.util.List;
- /**
- * 凸焊客户端配置,对应 application.yml 中 {@code mes.*}。
- */
- @ConfigurationProperties(prefix = "mes")
- public class MesClientProperties {
- /** 主窗口标题 */
- private String appTitle = "MES 凸焊客户端";
- /** MES 服务 IP(拼 HTTP/SSE 地址) */
- private String serverIp = "";
- /** 过站工号;system 跳过服务端绑员工校验 */
- private String userCode = "system";
- /** 过程参数上传路径(凸焊批追走 /upload,不过站) */
- private String uploadPath = "/js/a/mes/mesFlexHg/upload";
- /** 参数档标识,凸焊为 tuhan */
- private String paramProfile = "tuhan";
- /** 默认设备类型文案 */
- private String deviceType = "凸焊";
- /** 收到入队 SSE 后是否自动 next 取码 */
- private boolean autoNextOnPush = true;
- /** 本机工位列表(一拖多) */
- private List<StationConfig> stations = new ArrayList<StationConfig>();
- /** 单工位:编码 + S7 PLC */
- public static class StationConfig {
- /** 工位序号(界面/日志用) */
- private int id;
- /** 工位编码(与 MES 队列 stationSn 一致) */
- private String stationSn = "";
- /** Tab/面板显示标题 */
- private String title = "";
- /** 是否启用 PLC 通讯 */
- private boolean plcEnabled = true;
- /** PLC IP,如 192.168.0.10 */
- private String plcIp = "192.168.0.10";
- /** PLC 型号:S1200 / S1500 / S200_SMART 等 */
- private String plcType = "S1200";
- /** PLC 读写超时(毫秒) */
- private int plcTimeoutMs = 3000;
- public int getId() {
- return id;
- }
- public void setId(int id) {
- this.id = id;
- }
- public String getStationSn() {
- return stationSn;
- }
- public void setStationSn(String stationSn) {
- this.stationSn = stationSn;
- }
- public String getTitle() {
- return title;
- }
- public void setTitle(String title) {
- this.title = title;
- }
- public boolean isPlcEnabled() {
- return plcEnabled;
- }
- public void setPlcEnabled(boolean plcEnabled) {
- this.plcEnabled = plcEnabled;
- }
- public String getPlcIp() {
- return plcIp;
- }
- public void setPlcIp(String plcIp) {
- this.plcIp = plcIp;
- }
- public String getPlcType() {
- return plcType;
- }
- public void setPlcType(String plcType) {
- this.plcType = plcType;
- }
- public int getPlcTimeoutMs() {
- return plcTimeoutMs;
- }
- public void setPlcTimeoutMs(int plcTimeoutMs) {
- this.plcTimeoutMs = plcTimeoutMs;
- }
- }
- public String getAppTitle() {
- return appTitle;
- }
- public void setAppTitle(String appTitle) {
- this.appTitle = appTitle;
- }
- public String getServerIp() {
- return serverIp;
- }
- public void setServerIp(String serverIp) {
- this.serverIp = serverIp;
- }
- public String getUserCode() {
- return userCode;
- }
- public void setUserCode(String userCode) {
- this.userCode = userCode;
- }
- public String getUploadPath() {
- return uploadPath;
- }
- public void setUploadPath(String uploadPath) {
- this.uploadPath = uploadPath;
- }
- public String getParamProfile() {
- return paramProfile;
- }
- public void setParamProfile(String paramProfile) {
- this.paramProfile = paramProfile;
- }
- public String getDeviceType() {
- return deviceType;
- }
- public void setDeviceType(String deviceType) {
- this.deviceType = deviceType;
- }
- public boolean isAutoNextOnPush() {
- return autoNextOnPush;
- }
- public void setAutoNextOnPush(boolean autoNextOnPush) {
- this.autoNextOnPush = autoNextOnPush;
- }
- public List<StationConfig> getStations() {
- return stations;
- }
- public void setStations(List<StationConfig> stations) {
- this.stations = stations;
- }
- }
|