From a3fe79e605b07a5a908599aaa830a0860e9423d2 Mon Sep 17 00:00:00 2001
From: jinlin <jinlin>
Date: 星期三, 14 五月 2025 17:34:27 +0800
Subject: [PATCH] 修改
---
src/main/java/com/example/client/service/TrackRecordManageService.java | 78 ++++++++++++++++++++++++--------------
1 files changed, 49 insertions(+), 29 deletions(-)
diff --git a/src/main/java/com/example/client/service/TrackRecordManageService.java b/src/main/java/com/example/client/service/TrackRecordManageService.java
index f38194d..a2fca00 100644
--- a/src/main/java/com/example/client/service/TrackRecordManageService.java
+++ b/src/main/java/com/example/client/service/TrackRecordManageService.java
@@ -79,45 +79,54 @@
JComboBoxItem[] teamList = sysTeamGroupClassService.getTeamList(null);
String[] typeList = new String[]{
- "","鏀硅", "鍔犺", "鎹㈣", "淇悊","鏀硅繘鎬т慨鐞�"
+ "","鏀规崲瑁�","淇悊","鏀硅繘鎬т慨鐞�","涓嶅瑁呰澶�"
};
JComboBoxItem[] isealCabin = {
+ new JComboBoxItem(10000L, ""),
new JComboBoxItem(0L, "鍚�"),
new JComboBoxItem(1L, "鏄�"),
};
JLabel JLabel0 = new JLabel("宸ョ▼");
JComboBox<JComboBoxItem> comboBox = new JComboBox<>(projectList);
- comboBox.setPreferredSize(new Dimension(200, 28));
+ comboBox.setPreferredSize(new Dimension(210, 28));
JLabel JLabel1 = new JLabel("閮ㄩ棬");
JComboBox<JComboBoxItem> comboBox1 = new JComboBox<>(deptList);
comboBox1.setPreferredSize(new Dimension(140, 28));
+ comboBox1.setMaximumSize(new Dimension(140, 28));
JComboBoxItem[] teamList1 = sysTeamGroupClassService.getTeamList(deptList[0].getId());
JLabel JLabel2 = new JLabel("涓撲笟");
JComboBox<JComboBoxItem> comboBox2 = new JComboBox<>(teamList1);
comboBox2.setPreferredSize(new Dimension(140, 28));
+ comboBox2.setMaximumSize(new Dimension(140, 28));
JLabel JLabel3 = new JLabel("鑸卞");
JComboBox<JComboBoxItem> comboBox3 = new JComboBox<>(cabinList);
- comboBox3.setPreferredSize(new Dimension(140, 28));
+ comboBox3.setPreferredSize(new Dimension(120, 28));
+ comboBox3.setMaximumSize(new Dimension(120, 28));
JLabel JLabel4 = new JLabel("绫诲埆");
JComboBox<String> comboBox4 = new JComboBox<>(typeList);
comboBox4.setPreferredSize(new Dimension(140, 28));
+ comboBox4.setMaximumSize(new Dimension(140, 28));
JLabel JLabel5 = new JLabel("鐘舵��");
JComboBox<JComboBoxItem> comboBox5 = new JComboBox<>(statusList);
- comboBox5.setPreferredSize(new Dimension(140, 28));
+ comboBox5.setPreferredSize(new Dimension(120, 28));
+ comboBox5.setMaximumSize(new Dimension(120, 28));
JLabel JLabel78 = new JLabel("鏄惁褰卞搷灏佽埍");
JComboBox<JComboBoxItem> comboBox7 = new JComboBox<>(isealCabin);
- comboBox7.setPreferredSize(new Dimension(140, 28));
+ comboBox7.setPreferredSize(new Dimension(120, 28));
+ comboBox7.setMaximumSize(new Dimension(120, 28));
JTextField sb = new JTextField(16);
sb.setPreferredSize(new Dimension(140, 28));
+ sb.setMaximumSize(new Dimension(140, 28));
+
JButton query = new JButton("鏌ヨ");
JButton btnTj = new JButton("缁熻鎶ヨ〃");
@@ -275,7 +284,14 @@
@Override
public void actionPerformed(ActionEvent e) {
JComboBoxItem project = (JComboBoxItem) comboBox.getSelectedItem();
- list = djJdgzTrackRecordService.getList(project.getId(), null, null, null, null, 0, 0,sb.getText());
+ JComboBoxItem dept = (JComboBoxItem) comboBox1.getSelectedItem();
+ JComboBoxItem team = (JComboBoxItem) comboBox2.getSelectedItem();
+ JComboBoxItem cabin = (JComboBoxItem) comboBox3.getSelectedItem();
+ String type = comboBox4.getSelectedItem().toString();
+ JComboBoxItem status = (JComboBoxItem) comboBox5.getSelectedItem();
+ JComboBoxItem isealCabinItem = (JComboBoxItem) comboBox7.getSelectedItem();
+
+ list = djJdgzTrackRecordService.getList(project.getId(), dept.getId(), team.getId(), cabin.getId(), type, Math.toIntExact(status.getId()),Math.toIntExact(isealCabinItem.getId()),sb.getText());
CommonTable.refreshTable(list, columnDto, table);
table.setRowHeight(25);
@@ -314,6 +330,7 @@
columnDto.add(new ColumnDto("浜岀骇鑺傜偣", "level2NodeName", 120, null, false, null, null));
columnDto.add(new ColumnDto("璁惧鍚嶇О", "level3NetworkName", 120, null, false, null, null));
columnDto.add(new ColumnDto("鏄惁褰卞搷灏佽埍", "isealCabin", 180, "dict", false, null, isealCabin));
+ columnDto.add(new ColumnDto("鏄惁鑱旇皟", "islt", 180, "dict", false, null, isealCabin));
columnDto.add(new ColumnDto("褰撳墠鑺傜偣", "level3NodeName", 150, null, false, null, null));
columnDto.add(new ColumnDto("璁″垝瀹屾垚鏃堕棿", "requiredCompletionTime", 180, null, false, null, null));
columnDto.add(new ColumnDto("璺熻釜璁板綍", "", 100, "", true, buttonList, null));
@@ -360,20 +377,19 @@
});*/
topJpanel.add(JLabel0, new GBC(0, 0, 1, 1).setAnchor(GBC.SOUTHEAST).setInsets(5));
- topJpanel.add(comboBox, new GBC(1, 0, 3, 1).setAnchor(GBC.SOUTHWEST).setInsets(5));
+ topJpanel.add(comboBox, new GBC(1, 0, 3, 1).setAnchor(GBC.SOUTHWEST).setInsets(5).setWeight(0,0));
topJpanel.add(JLabel1, new GBC(4, 0, 1, 1).setAnchor(GBC.SOUTHEAST).setInsets(5));
- topJpanel.add(comboBox1, new GBC(5, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5));
+ topJpanel.add(comboBox1, new GBC(5, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5).setWeight(0,0));
topJpanel.add(JLabel2, new GBC(7, 0, 1, 1).setAnchor(GBC.SOUTHEAST).setInsets(5));
- topJpanel.add(comboBox2, new GBC(8, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5));
+ topJpanel.add(comboBox2, new GBC(8, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5).setWeight(0,0));
topJpanel.add(JLabel3, new GBC(10, 0, 1, 1).setAnchor(GBC.SOUTHEAST).setInsets(5));
- topJpanel.add(comboBox3, new GBC(11, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5));
+ topJpanel.add(comboBox3, new GBC(11, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5).setWeight(0,0));
topJpanel.add(JLabel4, new GBC(13, 0, 1, 1).setAnchor(GBC.SOUTHEAST).setInsets(5));
- topJpanel.add(comboBox4, new GBC(14, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5));
+ topJpanel.add(comboBox4, new GBC(14, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5).setWeight(0,0));
topJpanel.add(JLabel5, new GBC(16, 0, 1, 1).setAnchor(GBC.SOUTHEAST).setInsets(5));
- topJpanel.add(comboBox5, new GBC(17, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5));
+ topJpanel.add(comboBox5, new GBC(17, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5).setWeight(0,0));
topJpanel.add(JLabel78, new GBC(19, 0, 3, 1).setAnchor(GBC.SOUTHEAST).setInsets(5));
- topJpanel.add(comboBox7, new GBC(22, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5));
-
+ topJpanel.add(comboBox7, new GBC(22, 0, 2, 1).setAnchor(GBC.SOUTHWEST).setInsets(5).setWeight(0,0));
topJpanel.add(btnTj, new GBC(1, 1, 3, 1).setInsets(5));
topJpanel.add(btnJc, new GBC(4, 1, 3, 1).setInsets(5));
@@ -392,7 +408,7 @@
// 妫�鏌ユ槸鍚︾偣鍑讳簡鏈夋晥鍗曞厓鏍�
if (row >= 0 && column >= 0) {
- if (column == 13) { // 鍒楃储寮曚粠0寮�濮�
+ if (column == 15) { // 鍒楃储寮曚粠0寮�濮�
// 鑾峰彇璇ュ崟鍏冩牸鐨勫��
Object cellValue = table.getValueAt(row, column);
Integer value = Integer.parseInt(cellValue.toString());
@@ -448,13 +464,17 @@
}
});
+ System.out.println("comboBox width: " + comboBox.getPreferredSize().height);
+ System.out.println("comboBox2 width: " + comboBox2.getPreferredSize().height);
+ System.out.println("topJpanel width: " + topJpanel.getPreferredSize().height);
+
return panel;
}
public void history(JFrame jFrame, Long level3NodeId) {
jFrame.setEnabled(false);
JFrame frame1 = new JFrame("鍘嗗彶璺熻釜璁板綍");
- frame1.setSize(1500, 800);
+ frame1.setSize(2000, 800);
frame1.setResizable(true);
frame1.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
frame1.setLocationRelativeTo(null);
@@ -482,19 +502,19 @@
new JComboBoxItem(1L, "鏈�"),
};
- columnDto.add(new ColumnDto("搴忓彿", "", 50, "autoCreate", false, null, null));
- columnDto.add(new ColumnDto("璺熻釜鏂瑰紡", "trackMethod", 80, "dict", false, null, trackList));
- columnDto.add(new ColumnDto("璺熻釜鍦扮偣", "trackLocation", 160, null, false, null, null));
- columnDto.add(new ColumnDto("鍔╀慨浜哄強鍏惰仈绯绘柟寮�", "trackPerson", 160, null, false, null, null));
- columnDto.add(new ColumnDto("鍘傛柟鍙婂叾鑱旂郴鏂瑰紡", "trackedPerson", 160, null, false, null, null));
- columnDto.add(new ColumnDto("鎬绘壙淇崟浣�", "generalRepair", 160, null, false, null, null));
- columnDto.add(new ColumnDto("鍒嗘壙淇崟浣�", "repair", 160, null, false, null, null));
- columnDto.add(new ColumnDto("鑺傜偣杩涘睍", "currentStatus", 100, "dict", false, null, statusList));
- columnDto.add(new ColumnDto("鏈夋棤鑴辨湡椋庨櫓", "hasDelayRisk", 50, "dict", false, null, hasDelayRiskList));
- columnDto.add(new ColumnDto("棰勮瀹屾垚鏃堕棿", "estimatedCompletionTime", 120, "selectDate", false, null, null));
- columnDto.add(new ColumnDto("瀛樺湪闂", "problem", 120, null, false, null, null));
- columnDto.add(new ColumnDto("鍚庣画璁″垝", "followupPlan", 120, null, false, null, null));
- columnDto.add(new ColumnDto("澶囨敞", "remark", 120, null, false, null, null));
+ columnDto.add(new ColumnDto("搴忓彿", "", 80, "autoCreate", false, null, null));
+ columnDto.add(new ColumnDto("璺熻釜鏂瑰紡", "trackMethod", 120, "dict", false, null, trackList));
+ columnDto.add(new ColumnDto("璺熻釜鍦扮偣", "trackLocation", 180, null, false, null, null));
+ columnDto.add(new ColumnDto("鍔╀慨浜�", "trackPerson", 180, null, false, null, null));
+ columnDto.add(new ColumnDto("鍘傛柟", "trackedPerson", 180, null, false, null, null));
+ columnDto.add(new ColumnDto("鎬绘壙淇崟浣�", "generalRepair", 180, null, false, null, null));
+ columnDto.add(new ColumnDto("鍒嗘壙淇崟浣�", "repair", 180, null, false, null, null));
+ columnDto.add(new ColumnDto("鑺傜偣杩涘睍", "currentStatus", 120, "dict", false, null, statusList));
+ columnDto.add(new ColumnDto("鑴辨湡椋庨櫓", "hasDelayRisk", 120, "dict", false, null, hasDelayRiskList));
+ columnDto.add(new ColumnDto("棰勮瀹屾垚鏃堕棿", "estimatedCompletionTime", 200, "selectDate", false, null, null));
+ columnDto.add(new ColumnDto("瀛樺湪闂", "problem", 180, null, false, null, null));
+ columnDto.add(new ColumnDto("鍚庣画璁″垝", "followupPlan", 180, null, false, null, null));
+ columnDto.add(new ColumnDto("澶囨敞", "remark", 180, null, false, null, null));
JTable subTable = CommonTable.createCommonTable(list, columnDto);
subTable.setRowHeight(25);
--
Gitblit v1.9.1