From efce7ce3e63712ecc8b4c3039a73b508fc3ea880 Mon Sep 17 00:00:00 2001 From: jinlin <jinlin> Date: 星期一, 28 四月 2025 10:20:37 +0800 Subject: [PATCH] 修改 --- src/main/java/com/example/client/service/Level1AddOrUpdate.java | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-) diff --git a/src/main/java/com/example/client/service/Level1AddOrUpdate.java b/src/main/java/com/example/client/service/Level1AddOrUpdate.java index c6f34df..2e0c0c5 100644 --- a/src/main/java/com/example/client/service/Level1AddOrUpdate.java +++ b/src/main/java/com/example/client/service/Level1AddOrUpdate.java @@ -7,6 +7,8 @@ import com.example.server.progressTrack.model.DjJdgzNetworkLevel1List; import com.example.server.progressTrack.service.DjJdgzNetworkLevel1ListService; import com.example.server.progressTrack.service.NetWorkDiagramService; +import com.example.server.user.model.SysUser; +import com.example.server.utils.UserAndSiteUtils; import com.mxgraph.swing.mxGraphComponent; import com.mxgraph.view.mxGraph; import org.apache.poi.ss.usermodel.HorizontalAlignment; @@ -124,7 +126,7 @@ frame1.setVisible(true); mxGraph graph = new mxGraph(); - graph = netWorkDiagramService.getCsDiagram(graph,data.getContent(),null,diagram.getWidth(),diagram.getHeight()); + graph = netWorkDiagramService.getCsDiagram(graph,data.getContent(),null,diagram.getWidth(),diagram.getHeight(),null); mxGraphComponent graphComponent = new mxGraphComponent(graph); graphComponent.setConnectable(false); graphComponent.setDragEnabled(false); @@ -159,11 +161,17 @@ btnSave.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { + SysUser user = (SysUser) UserAndSiteUtils.get("user","user"); + if (user==null){ + JOptionPane.showMessageDialog(null, "鐢ㄦ埛澶辨晥璇烽��鍑哄苟閲嶆柊鐧诲綍", "鎻愮ず", JOptionPane.WARNING_MESSAGE); + return; + } if (subTable.isEditing()) { subTable.getCellEditor().stopCellEditing(); } CommonTable.saveTableList(list,subTable,columnDto); level1ListService.save(list,data.getId(),diagram, finalGraph1); + JOptionPane.showMessageDialog(null, "淇濆瓨鎴愬姛", "鎻愮ず", JOptionPane.WARNING_MESSAGE); } }); } -- Gitblit v1.9.1