|
|
@@ -84,7 +84,13 @@ public class MesClient extends JFrame {
|
|
|
public static MesWebView jfxPanel = null;
|
|
|
public static JPanel indexPanelC;
|
|
|
public static JPanel indexPanelD;
|
|
|
- public static MesWebView jfxPanel2 = null;
|
|
|
+ public static JPanel indexPanelCheck; // 开班点检页签面板(独立于「记录查询」)
|
|
|
+ public static JPanel panelCheckA; // 工位A 点检 WebView 容器
|
|
|
+ public static JPanel panelCheckB; // 工位B 点检 WebView 容器
|
|
|
+ public static JLabel labCheckA; // 工位A 标题(显示工位号)
|
|
|
+ public static JLabel labCheckB; // 工位B 标题(显示工位号)
|
|
|
+ public static MesWebView jfxPanel2 = null; // 工位A 点检页面
|
|
|
+ public static MesWebView jfxPanelCheckB = null; // 工位B 点检页面
|
|
|
public static MesWebView jfxPanel3 = null;
|
|
|
public static MesRadio mesRadioHj;
|
|
|
|
|
|
@@ -372,10 +378,6 @@ public class MesClient extends JFrame {
|
|
|
}
|
|
|
|
|
|
public static void initWarehouseData(){
|
|
|
- resetScanA();
|
|
|
- }
|
|
|
-
|
|
|
- public static void resetScanA() {
|
|
|
if (stationA != null) {
|
|
|
stationA.resetScan();
|
|
|
}
|
|
|
@@ -391,6 +393,13 @@ public class MesClient extends JFrame {
|
|
|
MesClient.setMenuStatus("请扫工件码",0);
|
|
|
}
|
|
|
|
|
|
+ /** 仅刷新工位A,不影响B */
|
|
|
+ public static void resetScanA() {
|
|
|
+ if (stationA != null) {
|
|
|
+ stationA.resetScan();
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
public static int userLoginHours;//用户登录所处小时
|
|
|
public static JTextField param1;
|
|
|
public static JTextField param2;
|
|
|
@@ -436,6 +445,7 @@ public class MesClient extends JFrame {
|
|
|
public static JTextField taskMaxSoutB;
|
|
|
public static JTextField taskMinSoutB;
|
|
|
public static JComboBox taskLeakage;
|
|
|
+ public static JComboBox taskLeakageB;
|
|
|
|
|
|
public static JTextField barcodeSpec;
|
|
|
public static JTextField barcodeSpecStart;
|
|
|
@@ -530,8 +540,11 @@ public class MesClient extends JFrame {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+ /** 仅刷新工位B,不影响A */
|
|
|
public static void resetScanB() {
|
|
|
-
|
|
|
+ if (stationB != null) {
|
|
|
+ stationB.resetScan();
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
//获取用户20位
|
|
|
@@ -712,17 +725,29 @@ public class MesClient extends JFrame {
|
|
|
});
|
|
|
// settingMenu.add(resetTcpMenu);
|
|
|
|
|
|
- JMenuItem resetTcpMenu_1 = new JMenuItem("刷新工件");
|
|
|
- resetTcpMenu_1.setIcon(new ImageIcon(MesClient.class.getResource("/bg/reset_logo.png")));
|
|
|
- resetTcpMenu_1.setFont(new Font("微软雅黑", Font.PLAIN, 20));
|
|
|
- resetTcpMenu_1.addMouseListener(new MouseAdapter() {
|
|
|
+ JMenuItem resetWorkAMenu = new JMenuItem("刷新工件A");
|
|
|
+ resetWorkAMenu.setIcon(new ImageIcon(MesClient.class.getResource("/bg/reset_logo.png")));
|
|
|
+ resetWorkAMenu.setFont(new Font("微软雅黑", Font.PLAIN, 20));
|
|
|
+ resetWorkAMenu.addMouseListener(new MouseAdapter() {
|
|
|
@Override
|
|
|
public void mousePressed(MouseEvent e) {
|
|
|
super.mouseClicked(e);
|
|
|
resetScanA();
|
|
|
}
|
|
|
});
|
|
|
- settingMenu.add(resetTcpMenu_1);
|
|
|
+ settingMenu.add(resetWorkAMenu);
|
|
|
+
|
|
|
+ JMenuItem resetWorkBMenu = new JMenuItem("刷新工件B");
|
|
|
+ resetWorkBMenu.setIcon(new ImageIcon(MesClient.class.getResource("/bg/reset_logo.png")));
|
|
|
+ resetWorkBMenu.setFont(new Font("微软雅黑", Font.PLAIN, 20));
|
|
|
+ resetWorkBMenu.addMouseListener(new MouseAdapter() {
|
|
|
+ @Override
|
|
|
+ public void mousePressed(MouseEvent e) {
|
|
|
+ super.mouseClicked(e);
|
|
|
+ resetScanB();
|
|
|
+ }
|
|
|
+ });
|
|
|
+ settingMenu.add(resetWorkBMenu);
|
|
|
|
|
|
contentPane = new JPanel();
|
|
|
contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
|
|
|
@@ -1000,6 +1025,28 @@ public class MesClient extends JFrame {
|
|
|
|
|
|
tabbedPane.addTab("记录查询", new ImageIcon(MesClient.class.getResource("/bg/menu_data_preprocess.png")), searchScrollPaneDj, null);
|
|
|
|
|
|
+ // 开班点检页签:A/B 双工位左右分屏,各自独立加载/提交点检记录
|
|
|
+ indexPanelCheck = new JPanel();
|
|
|
+ indexPanelCheck.setLayout(null);
|
|
|
+ indexPanelCheck.setPreferredSize(new Dimension(990, 600));
|
|
|
+
|
|
|
+ labCheckA = new JLabel("工位A 开班点检");
|
|
|
+ labCheckA.setBounds(0, 0, 470, 28);
|
|
|
+ indexPanelCheck.add(labCheckA);
|
|
|
+ labCheckB = new JLabel("工位B 开班点检");
|
|
|
+ labCheckB.setBounds(500, 0, 470, 28);
|
|
|
+ indexPanelCheck.add(labCheckB);
|
|
|
+
|
|
|
+ panelCheckA = new JPanel(new BorderLayout());
|
|
|
+ panelCheckA.setBounds(0, 30, 485, 555);
|
|
|
+ indexPanelCheck.add(panelCheckA);
|
|
|
+ panelCheckB = new JPanel(new BorderLayout());
|
|
|
+ panelCheckB.setBounds(500, 30, 485, 555);
|
|
|
+ indexPanelCheck.add(panelCheckB);
|
|
|
+
|
|
|
+ JScrollPane searchScrollPaneCheck = new JScrollPane(indexPanelCheck);
|
|
|
+ tabbedPane.addTab("开班点检", new ImageIcon(MesClient.class.getResource("/bg/menu_data_preprocess.png")), searchScrollPaneCheck, null);
|
|
|
+
|
|
|
|
|
|
// indexPanelB = new JPanel();
|
|
|
// searchScrollPane = new JScrollPane(indexPanelB);
|
|
|
@@ -1227,11 +1274,17 @@ public class MesClient extends JFrame {
|
|
|
MesClient.curTaskParam.setBarcodeSpec(barcodeSpec.getText().trim());
|
|
|
MesClient.curTaskParam.setBarcodeLength(barcodeLength.getText().trim());
|
|
|
|
|
|
+ MesClient.curTaskParam.setTaskProgramNoA(taskMaxNumA.getText().trim());
|
|
|
+ MesClient.curTaskParam.setTaskLabelNameA(taskMaxFoutA.getText().trim());
|
|
|
+ MesClient.curTaskParam.setTaskLeakageA(taskLeakage.getSelectedItem().toString());
|
|
|
+ MesClient.curTaskParam.setTaskProgramNoB(taskMaxNumB.getText().trim());
|
|
|
+ MesClient.curTaskParam.setTaskLabelNameB(taskMaxFoutB.getText().trim());
|
|
|
+ MesClient.curTaskParam.setTaskLeakageB(taskLeakageB.getSelectedItem().toString());
|
|
|
+ // 兼容旧字段
|
|
|
MesClient.curTaskParam.setTaskProgramNo(taskMaxNumA.getText().trim());
|
|
|
MesClient.curTaskParam.setTaskLabelName(taskMaxFoutA.getText().trim());
|
|
|
MesClient.curTaskParam.setTaskLeakage(taskLeakage.getSelectedItem().toString());
|
|
|
|
|
|
-
|
|
|
JdbcUtils.updateTask(MesClient.curTaskParam.getId(),MesClient.curTaskParam);
|
|
|
getTask();
|
|
|
formatTaskParam();
|
|
|
@@ -1250,6 +1303,18 @@ public class MesClient extends JFrame {
|
|
|
taskName.setBounds(700, 10, 283, 40);
|
|
|
indexPanelTask.add(taskName);
|
|
|
|
|
|
+ JLabel stationAHead = new JLabel("工位A");
|
|
|
+ stationAHead.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
+ stationAHead.setFont(new Font("微软雅黑", Font.BOLD, 18));
|
|
|
+ stationAHead.setBounds(310, 60, 222, 28);
|
|
|
+ indexPanelTask.add(stationAHead);
|
|
|
+
|
|
|
+ JLabel stationBHead = new JLabel("工位B");
|
|
|
+ stationBHead.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
+ stationBHead.setFont(new Font("微软雅黑", Font.BOLD, 18));
|
|
|
+ stationBHead.setBounds(580, 60, 222, 28);
|
|
|
+ indexPanelTask.add(stationBHead);
|
|
|
+
|
|
|
JLabel taskMaxNumLabelA = new JLabel("程序号");
|
|
|
taskMaxNumLabelA.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
taskMaxNumLabelA.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
@@ -1286,130 +1351,90 @@ public class MesClient extends JFrame {
|
|
|
taskLeakage.setBounds(422, 173, 110, 30);
|
|
|
indexPanelTask.add(taskLeakage);
|
|
|
|
|
|
-// taskMinFoutA = new JTextField();
|
|
|
-// taskMinFoutA.setColumns(10);
|
|
|
-// taskMinFoutA.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
-// taskMinFoutA.setBounds(422, 173, 110, 30);
|
|
|
-// indexPanelTask.add(taskMinFoutA);
|
|
|
-
|
|
|
- JLabel taskMaxSoutLabelA = new JLabel("A枪最大行程");
|
|
|
- taskMaxSoutLabelA.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
- taskMaxSoutLabelA.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMaxSoutLabelA.setBounds(310, 213, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxSoutLabelA);
|
|
|
-
|
|
|
taskMaxSoutA = new JTextField();
|
|
|
- taskMaxSoutA.setColumns(10);
|
|
|
- taskMaxSoutA.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMaxSoutA.setBounds(422, 213, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxSoutA);
|
|
|
-
|
|
|
- JLabel taskMinSoutLabelA = new JLabel("A枪最小行程");
|
|
|
- taskMinSoutLabelA.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
- taskMinSoutLabelA.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMinSoutLabelA.setBounds(310, 253, 110, 30);
|
|
|
-// indexPanelTask.add(taskMinSoutLabelA);
|
|
|
-
|
|
|
taskMinSoutA = new JTextField();
|
|
|
- taskMinSoutA.setColumns(10);
|
|
|
- taskMinSoutA.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMinSoutA.setBounds(422, 253, 110, 30);
|
|
|
-// indexPanelTask.add(taskMinSoutA);
|
|
|
+ taskMinFoutA = new JTextField();
|
|
|
|
|
|
- JLabel taskMaxNumLabelB = new JLabel("B枪预算数量");
|
|
|
+ JLabel taskMaxNumLabelB = new JLabel("程序号");
|
|
|
taskMaxNumLabelB.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
taskMaxNumLabelB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
taskMaxNumLabelB.setBounds(580, 93, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxNumLabelB);
|
|
|
+ indexPanelTask.add(taskMaxNumLabelB);
|
|
|
|
|
|
taskMaxNumB = new JTextField();
|
|
|
taskMaxNumB.setColumns(10);
|
|
|
taskMaxNumB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
taskMaxNumB.setBounds(692, 93, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxNumB);
|
|
|
+ indexPanelTask.add(taskMaxNumB);
|
|
|
|
|
|
- JLabel taskMaxFoutLabelB = new JLabel("B枪最大拉力");
|
|
|
+ JLabel taskMaxFoutLabelB = new JLabel("标签名称");
|
|
|
taskMaxFoutLabelB.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
taskMaxFoutLabelB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
taskMaxFoutLabelB.setBounds(580, 133, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxFoutLabelB);
|
|
|
+ indexPanelTask.add(taskMaxFoutLabelB);
|
|
|
|
|
|
taskMaxFoutB = new JTextField();
|
|
|
taskMaxFoutB.setColumns(10);
|
|
|
taskMaxFoutB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
taskMaxFoutB.setBounds(692, 133, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxFoutB);
|
|
|
+ indexPanelTask.add(taskMaxFoutB);
|
|
|
|
|
|
- JLabel taskMinFoutLabelB = new JLabel("B枪最小拉力");
|
|
|
+ JLabel taskMinFoutLabelB = new JLabel("泄漏值取值");
|
|
|
taskMinFoutLabelB.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
taskMinFoutLabelB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
taskMinFoutLabelB.setBounds(580, 173, 110, 30);
|
|
|
-// indexPanelTask.add(taskMinFoutLabelB);
|
|
|
-
|
|
|
- taskMinFoutB = new JTextField();
|
|
|
- taskMinFoutB.setColumns(10);
|
|
|
- taskMinFoutB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMinFoutB.setBounds(692, 173, 110, 30);
|
|
|
-// indexPanelTask.add(taskMinFoutB);
|
|
|
+ indexPanelTask.add(taskMinFoutLabelB);
|
|
|
|
|
|
- JLabel taskMaxSoutLabelB = new JLabel("B枪最大行程");
|
|
|
- taskMaxSoutLabelB.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
- taskMaxSoutLabelB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMaxSoutLabelB.setBounds(580, 213, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxSoutLabelB);
|
|
|
+ taskLeakageB = new JComboBox();
|
|
|
+ taskLeakageB.setModel(new DefaultComboBoxModel(new String[] {"压降", "泄漏率"}));
|
|
|
+ taskLeakageB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
+ taskLeakageB.setBounds(692, 173, 110, 30);
|
|
|
+ indexPanelTask.add(taskLeakageB);
|
|
|
|
|
|
+ taskMinFoutB = new JTextField();
|
|
|
taskMaxSoutB = new JTextField();
|
|
|
- taskMaxSoutB.setColumns(10);
|
|
|
- taskMaxSoutB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMaxSoutB.setBounds(692, 213, 110, 30);
|
|
|
-// indexPanelTask.add(taskMaxSoutB);
|
|
|
-
|
|
|
- JLabel taskMinSoutLabelB = new JLabel("B枪最小行程");
|
|
|
- taskMinSoutLabelB.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
- taskMinSoutLabelB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMinSoutLabelB.setBounds(580, 253, 110, 30);
|
|
|
-// indexPanelTask.add(taskMinSoutLabelB);
|
|
|
-
|
|
|
taskMinSoutB = new JTextField();
|
|
|
- taskMinSoutB.setColumns(10);
|
|
|
- taskMinSoutB.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- taskMinSoutB.setBounds(692, 253, 110, 30);
|
|
|
-// indexPanelTask.add(taskMinSoutB);
|
|
|
+
|
|
|
+ JLabel barcodeSharedTip = new JLabel("条码规则(A/B共用)");
|
|
|
+ barcodeSharedTip.setHorizontalAlignment(SwingConstants.LEFT);
|
|
|
+ barcodeSharedTip.setFont(new Font("微软雅黑", Font.BOLD, 16));
|
|
|
+ barcodeSharedTip.setBounds(310, 230, 300, 28);
|
|
|
+ indexPanelTask.add(barcodeSharedTip);
|
|
|
|
|
|
JLabel barcodeSpecLabel = new JLabel("条码固定位");
|
|
|
barcodeSpecLabel.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
barcodeSpecLabel.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- barcodeSpecLabel.setBounds(310, 293, 110, 30);
|
|
|
+ barcodeSpecLabel.setBounds(310, 268, 110, 30);
|
|
|
indexPanelTask.add(barcodeSpecLabel);
|
|
|
|
|
|
barcodeSpec = new JTextField();
|
|
|
barcodeSpec.setColumns(10);
|
|
|
barcodeSpec.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- barcodeSpec.setBounds(422, 293, 110, 30);
|
|
|
+ barcodeSpec.setBounds(422, 268, 110, 30);
|
|
|
indexPanelTask.add(barcodeSpec);
|
|
|
|
|
|
JLabel barcodeSpecStartLabel = new JLabel("起始位数");
|
|
|
barcodeSpecStartLabel.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
barcodeSpecStartLabel.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- barcodeSpecStartLabel.setBounds(310, 333, 110, 30);
|
|
|
+ barcodeSpecStartLabel.setBounds(310, 308, 110, 30);
|
|
|
indexPanelTask.add(barcodeSpecStartLabel);
|
|
|
|
|
|
barcodeSpecStart = new JTextField();
|
|
|
barcodeSpecStart.setColumns(10);
|
|
|
barcodeSpecStart.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- barcodeSpecStart.setBounds(422, 333, 110, 30);
|
|
|
+ barcodeSpecStart.setBounds(422, 308, 110, 30);
|
|
|
indexPanelTask.add(barcodeSpecStart);
|
|
|
|
|
|
JLabel barcodeLengthLabel = new JLabel("条码长度");
|
|
|
barcodeLengthLabel.setHorizontalAlignment(SwingConstants.CENTER);
|
|
|
barcodeLengthLabel.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- barcodeLengthLabel.setBounds(310, 373, 110, 30);
|
|
|
+ barcodeLengthLabel.setBounds(310, 348, 110, 30);
|
|
|
indexPanelTask.add(barcodeLengthLabel);
|
|
|
|
|
|
barcodeLength = new JTextField();
|
|
|
barcodeLength.setColumns(10);
|
|
|
barcodeLength.setFont(new Font("微软雅黑", Font.PLAIN, 16));
|
|
|
- barcodeLength.setBounds(422, 373, 110, 30);
|
|
|
+ barcodeLength.setBounds(422, 348, 110, 30);
|
|
|
indexPanelTask.add(barcodeLength);
|
|
|
|
|
|
|
|
|
@@ -1424,11 +1449,77 @@ public class MesClient extends JFrame {
|
|
|
if(selectedIndex == 1){
|
|
|
|
|
|
}
|
|
|
+ // 切到「开班点检」页签时按当前软件设置重新加载,保证 A/B 工位号改动即时生效
|
|
|
+ if(selectedIndex >= 0 && "开班点检".equals(tabbedPane.getTitleAt(selectedIndex))){
|
|
|
+ refreshCheckPage();
|
|
|
+ }
|
|
|
JdbcUtils.getTestData();
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * 加载/刷新「开班点检」页面:A/B 各自使用软件设置里本工位的 oprno/lineSn,
|
|
|
+ * 生成独立 URL、独立 WebView,点检记录分别提交到各自工位。
|
|
|
+ */
|
|
|
+ public static void refreshCheckPage(){
|
|
|
+ if(sessionid == null || sessionid.isEmpty()) return; // 未登录不加载
|
|
|
+ if(stationA == null || stationB == null) return;
|
|
|
+ loadStationCheck(true);
|
|
|
+ loadStationCheck(false);
|
|
|
+ }
|
|
|
+
|
|
|
+ private static void loadStationCheck(boolean isA){
|
|
|
+ QmStation station = isA ? stationA : stationB;
|
|
|
+ ConfigParam cfg = station.configParam;
|
|
|
+ if(cfg == null) cfg = new ConfigParam();
|
|
|
+
|
|
|
+ String oprno = cfg.getOprno();
|
|
|
+ if(oprno == null || oprno.trim().isEmpty()){
|
|
|
+ // 不回退到 mes_gw,否则 A/B 会提交到同一个工位;A/B 各自独立判断
|
|
|
+ JLabel labEmpty = isA ? labCheckA : labCheckB;
|
|
|
+ if(labEmpty != null){
|
|
|
+ labEmpty.setText((isA ? "工位A" : "工位B") + " 开班点检 - 未配置工位号,请在「软件设置」中配置后切回本页签");
|
|
|
+ }
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ String lineSn = cfg.getLineSn();
|
|
|
+ if(lineSn == null || lineSn.trim().isEmpty()) lineSn = mes_line_sn;
|
|
|
+
|
|
|
+ String url = "http://" + mes_server_ip + ":8980/js/a/mes/mesProcessCheckRecord/ulist?__sid="
|
|
|
+ + sessionid + "&oprno=" + oprno.trim() + "&lineSn=" + lineSn.trim();
|
|
|
+
|
|
|
+ JLabel lab = isA ? labCheckA : labCheckB;
|
|
|
+ JPanel panel = isA ? panelCheckA : panelCheckB;
|
|
|
+ if(lab != null){
|
|
|
+ lab.setText((isA ? "工位A" : "工位B") + " 开班点检 - " + oprno.trim() + "(来自软件设置)");
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ if(isA){
|
|
|
+ if(jfxPanel2 == null){
|
|
|
+ jfxPanel2 = new MesWebView(url);
|
|
|
+ panel.add(jfxPanel2, BorderLayout.CENTER);
|
|
|
+ panel.revalidate();
|
|
|
+ panel.repaint();
|
|
|
+ }else{
|
|
|
+ jfxPanel2.loadUrl(url);
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ if(jfxPanelCheckB == null){
|
|
|
+ jfxPanelCheckB = new MesWebView(url);
|
|
|
+ panel.add(jfxPanelCheckB, BorderLayout.CENTER);
|
|
|
+ panel.revalidate();
|
|
|
+ panel.repaint();
|
|
|
+ }else{
|
|
|
+ jfxPanelCheckB.loadUrl(url);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ } catch (Exception ex) {
|
|
|
+ System.err.println((isA ? "工位A" : "工位B") + " 开班点检页面加载失败: " + ex.getMessage());
|
|
|
+ ex.printStackTrace();
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
public static void setMenuStatus(String msg,int error){
|
|
|
if(error == 0){
|
|
|
MesClient.status_menu.setForeground(Color.GREEN);
|
|
|
@@ -1462,21 +1553,15 @@ public class MesClient extends JFrame {
|
|
|
if(MesClient.curTaskParam != null){
|
|
|
taskName.setText(MesClient.curTaskParam.getTitle());
|
|
|
|
|
|
- if(MesClient.curTaskParam.getTaskProgramNo() == null || MesClient.curTaskParam.getTaskProgramNo().equals("")){
|
|
|
- MesClient.curTaskParam.setTaskProgramNo("");
|
|
|
- }
|
|
|
- taskMaxNumA.setText(MesClient.curTaskParam.getTaskProgramNo());
|
|
|
+ taskMaxNumA.setText(MesClient.curTaskParam.resolveProgramNo("A"));
|
|
|
+ taskMaxFoutA.setText(MesClient.curTaskParam.resolveLabelName("A"));
|
|
|
+ taskLeakage.setSelectedItem(MesClient.curTaskParam.resolveLeakage("A"));
|
|
|
|
|
|
- if(MesClient.curTaskParam.getTaskLabelName() == null || MesClient.curTaskParam.getTaskLabelName().equals("")){
|
|
|
- MesClient.curTaskParam.setTaskLabelName("");
|
|
|
+ taskMaxNumB.setText(MesClient.curTaskParam.resolveProgramNo("B"));
|
|
|
+ taskMaxFoutB.setText(MesClient.curTaskParam.resolveLabelName("B"));
|
|
|
+ if (taskLeakageB != null) {
|
|
|
+ taskLeakageB.setSelectedItem(MesClient.curTaskParam.resolveLeakage("B"));
|
|
|
}
|
|
|
- taskMaxFoutA.setText(MesClient.curTaskParam.getTaskLabelName());
|
|
|
-
|
|
|
-
|
|
|
- if(MesClient.curTaskParam.getTaskLeakage() == null || MesClient.curTaskParam.getTaskLeakage().equals("")){
|
|
|
- MesClient.curTaskParam.setTaskLeakage("压降");
|
|
|
- }
|
|
|
- taskLeakage.setSelectedItem(MesClient.curTaskParam.getTaskLeakage());
|
|
|
|
|
|
if(MesClient.curTaskParam.getBarcodeSpec() == null || MesClient.curTaskParam.getBarcodeSpec().equals("")){
|
|
|
MesClient.curTaskParam.setBarcodeSpec("");
|
|
|
@@ -1499,12 +1584,12 @@ public class MesClient extends JFrame {
|
|
|
taskMaxNumB.setText("");
|
|
|
taskMaxFoutA.setText("");
|
|
|
taskMaxFoutB.setText("");
|
|
|
- taskMaxSoutA.setText("");
|
|
|
- taskMaxSoutB.setText("");
|
|
|
- taskMinFoutA.setText("");
|
|
|
- taskMinFoutB.setText("");
|
|
|
- taskMinSoutA.setText("");
|
|
|
- taskMinSoutB.setText("");
|
|
|
+ if (taskLeakage != null) {
|
|
|
+ taskLeakage.setSelectedItem("压降");
|
|
|
+ }
|
|
|
+ if (taskLeakageB != null) {
|
|
|
+ taskLeakageB.setSelectedItem("压降");
|
|
|
+ }
|
|
|
|
|
|
barcodeLength.setText("");
|
|
|
barcodeSpec.setText("");
|