| | |
| | | import com.example.server.DataSync.service.DataSyncService; |
| | | import com.example.server.progressTrack.dao.ExportRecordDao; |
| | | import com.example.server.progressTrack.model.ExportRecord; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | |
| | | btnExport.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | dataSyncService.export(tips); |
| | | } |
| | | }); |
| | |
| | | import com.example.server.progressTrack.dao.ImportRecordDao; |
| | | import com.example.server.progressTrack.model.ExportRecord; |
| | | import com.example.server.progressTrack.model.ImportRecord; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | |
| | | private JTable table; |
| | | |
| | | public JPanel createTable(Integer width, Integer height, JFrame jFrame) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return null; |
| | | } |
| | | JPanel panel = new JPanel(new BorderLayout()); |
| | | panel.setPreferredSize(new Dimension(width-10,height)); |
| | | |
| | |
| | | trackTable.getCellEditor().stopCellEditing(); |
| | | } |
| | | SysUser user = (SysUser) CacheUtils.get("user", "user"); |
| | | if (user == null) { |
| | | JOptionPane.showMessageDialog(null, "当前用户已失效请重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | if (user.getTeamgroup()==null||user.getTeamgroup().equals(nowLevel3.getTeamgroupId().toString())){ |
| | | CommonTable.saveTableList(list, trackTable, columnDto); |
| | | djJdgzDismantTrackService.save(list); |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | }else{ |
| | | JOptionPane.showMessageDialog(null, "当前用户不可操作其他专业数据", "提示", JOptionPane.WARNING_MESSAGE); |
| | | } |
| | |
| | | JComboBoxItem[] teamList = sysTeamGroupClassService.getTeamList(null); |
| | | JComboBoxItem[] cabinList = cabinService.getList(); |
| | | String[] typeList = new String[]{ |
| | | "","改装", "加装", "换装", "改进性修理" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | List<DjJdgzShip> shipList = djJdgzShipService.getList(); |
| | | Map<String, Long> shipMap = new HashMap<>(); |
| | |
| | | import com.example.server.progressTrack.service.DjJdgzNetworkLevel1Service; |
| | | import com.example.server.progressTrack.service.DjJdgzTrackRecordService; |
| | | import com.example.server.sysOss.model.SysOss; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.jdesktop.swingx.JXDatePicker; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | saveButton.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | JComboBoxItem project = (JComboBoxItem) comboBox.getSelectedItem(); |
| | | |
| | | data.setLevel1NetworkId(project.getId()); |
| | |
| | | handoverManageService.tableModelListener(table,jFrame,list); |
| | | frame1.dispose(); |
| | | jFrame.setEnabled(true);//将主界面再设置为可操作的 |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | } |
| | | }); |
| | | |
| | |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(600); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(100); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(550); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(150); |
| | | |
| | | |
| | | table.getColumnModel().getColumn(0).setCellRenderer(new TableViewRenderer()); |
| | |
| | | import com.example.client.utils.*; |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel3; |
| | | import com.example.server.progressTrack.service.*; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import com.example.server.utils.DownLoadTmpFile; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | |
| | | return; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return ; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(600); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(100); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(550); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(150); |
| | | |
| | | |
| | | table.getColumnModel().getColumn(0).setCellRenderer(new TableViewRenderer()); |
| | |
| | | JOptionPane.showMessageDialog(null, "只能上传.xlsx或.xls的文件,且不超过2G\"", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | flag = false; |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(650); |
| | |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel1; |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel2List; |
| | | import com.example.server.progressTrack.service.DjJdgzNetworkLevel2ListService; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import com.mxgraph.view.mxGraph; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.apache.poi.hssf.usermodel.HSSFWorkbook; |
| | |
| | | return; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(600); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(100); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(550); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(150); |
| | | |
| | | |
| | | table.getColumnModel().getColumn(0).setCellRenderer(new TableViewRenderer()); |
| | |
| | | JOptionPane.showMessageDialog(null, "只能上传.xlsx或.xls的文件,且不超过2G\"", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | flag = false; |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(650); |
| | |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel3; |
| | | import com.example.server.progressTrack.service.*; |
| | | import com.example.server.teamGroup.service.SysTeamGroupClassService; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import com.example.server.utils.DownLoadTmpFile; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | |
| | | return; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(600); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(100); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(550); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(150); |
| | | |
| | | |
| | | table.getColumnModel().getColumn(0).setCellRenderer(new TableViewRenderer()); |
| | |
| | | JComboBoxItem[] teamList = sysTeamGroupClassService.getTeamList(null); |
| | | JComboBoxItem[] cabinList = cabinService.getList(); |
| | | String[] typeList = new String[]{ |
| | | "改装", "加装", "换装", "改进性修理","" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | List<DjJdgzNetworkLevel3> list = level3Service.getList(null, deptList[0].getId(), teamList[0].getId(), cabinList[0].getId(), typeList[0],null); |
| | | CommonTable.refreshTable(list, columnDto, subTable); |
| | |
| | | JOptionPane.showMessageDialog(null, "只能上传.xlsx或.xls的文件,且不超过2G\"", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | flag = false; |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(650); |
| | |
| | | import com.example.server.progressTrack.model.DjJdgzTrackRecord; |
| | | import com.example.server.progressTrack.service.*; |
| | | import com.example.server.teamGroup.service.SysTeamGroupClassService; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import com.example.server.utils.DownLoadTmpFile; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | |
| | | for (JComboBoxItem item : selectedItems) { |
| | | selectedIds.append(item.getId()).append(","); |
| | | } |
| | | if (StringUtils.isNotBlank(selectedIds)){ |
| | | selectedIds.deleteCharAt(selectedIds.length()-1); |
| | | } |
| | | List<DjJdgzTrackRecord> list = djJdgzTrackRecordService.getListByImport(level1Id,level2Id,level2NodeId,selectedIds.toString()); |
| | | DownLoadTmpFile.buildTrack(list,tmpPath + "跟踪记录导入模板.xlsx", frame); |
| | | } |
| | |
| | | return; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(600); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(100); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(550); |
| | | table.getColumnModel().getColumn(1).setPreferredWidth(150); |
| | | |
| | | |
| | | table.getColumnModel().getColumn(0).setCellRenderer(new TableViewRenderer()); |
| | |
| | | JComboBoxItem[] teamList = sysTeamGroupClassService.getTeamList(null); |
| | | JComboBoxItem[] cabinList = cabinService.getList(); |
| | | String[] typeList = new String[]{ |
| | | "","改装", "加装", "换装", "改进性修理" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | List<DjJdgzTrackRecord> list = djJdgzTrackRecordService.getList(level1Id[0], deptList[0].getId(), teamList[0].getId(), cabinList[0].getId(), typeList[0], 0, null); |
| | | CommonTable.refreshTable(list, columnDto, subTable); |
| | |
| | | JOptionPane.showMessageDialog(null, "只能上传.xlsx或.xls的文件,且不超过2G\"", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | flag = false; |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return flag; |
| | | } |
| | | |
| | | model.setDataVector(data, columnIdentifiers); |
| | | table.setModel(model); |
| | | table.getColumnModel().getColumn(0).setPreferredWidth(650); |
| | |
| | | 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.CacheUtils; |
| | | import com.mxgraph.swing.mxGraphComponent; |
| | | import com.mxgraph.view.mxGraph; |
| | | import org.apache.poi.ss.usermodel.HorizontalAlignment; |
| | |
| | | btnSave.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.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); |
| | | } |
| | | }); |
| | | } |
| | |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel2; |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel2List; |
| | | import com.example.server.progressTrack.service.*; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import com.mxgraph.swing.mxGraphComponent; |
| | | import com.mxgraph.view.mxGraph; |
| | | import org.apache.commons.lang3.StringUtils; |
| | |
| | | btnSave.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | if (subTable.isEditing()) { |
| | | subTable.getCellEditor().stopCellEditing(); |
| | | } |
| | | CommonTable.saveTableList(list,subTable,columnDto); |
| | | level2ListService.save(list,data.getId(),diagram, finalGraph); |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | |
| | | } |
| | | }); |
| | | |
| | |
| | | import com.example.server.progressTrack.service.DjJdgzNetworkLevel3ListService; |
| | | import com.example.server.progressTrack.service.NetWorkDiagramService; |
| | | import com.example.server.teamGroup.service.SysTeamGroupClassService; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import com.mxgraph.swing.mxGraphComponent; |
| | | import com.mxgraph.view.mxGraph; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | btnSave.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | if (subTable.isEditing()) { |
| | | subTable.getCellEditor().stopCellEditing(); |
| | | } |
| | | CommonTable.saveTableList(finalList, subTable, columnDto); |
| | | level3ListService.save(finalList, data.getId(), diagram, finalGraph1); |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | } |
| | | }); |
| | | |
| | |
| | | JComboBoxItem[] cabinList = cabinService.getList(); |
| | | JComboBoxItem[] deptList = sysTeamGroupClassService.getDeptList(); |
| | | String[] typeList = new String[]{ |
| | | "","改装", "加装", "换装", "改进性修理" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | |
| | | JLabel JLabel0 = new JLabel("工程"); |
| | |
| | | JComboBoxItem[] cabinList = cabinService.getList(); |
| | | JComboBoxItem[] teamList = sysTeamGroupClassService.getTeamList(null); |
| | | String[] typeList = new String[]{ |
| | | "","改装", "加装", "换装", "改进性修理" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | |
| | | JLabel JLabel1 = new JLabel("工程"); |
| | |
| | | JComboBoxItem[] cabinList = cabinService.getList(); |
| | | JComboBoxItem[] deptList = sysTeamGroupClassService.getDeptList(); |
| | | String[] typeList = new String[]{ |
| | | "","改装", "加装", "换装", "改进性修理" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | |
| | | JLabel JLabel0 = new JLabel("工程"); |
| | |
| | | } |
| | | }); |
| | | |
| | | table.setEnabled(false); |
| | | JScrollPane scrollPane = new JScrollPane(table, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS); |
| | | scrollPane.setViewportView(table); |
| | | scrollPane.getViewport().setBackground(Color.WHITE); |
| | |
| | | } |
| | | } else if (nodeName.equals("数据导入")) { |
| | | JPanel dataImport = dataImportManageService.createTable(width, height, frame); |
| | | main.showTab("数据导入", dataImport, tree); |
| | | if(dataImport!=null){ |
| | | main.showTab("数据导入", dataImport, tree); |
| | | } |
| | | } else if (nodeName.equals("数据导出")) { |
| | | JPanel dataExport = dataExportManageService.createTable(width, height, frame); |
| | | main.showTab("数据导出", dataExport, tree); |
| | |
| | | import com.example.server.progressTrack.model.DjJdgzShip; |
| | | import com.example.server.progressTrack.service.DjJdgzNetworkLevel1Service; |
| | | import com.example.server.progressTrack.service.DjJdgzShipService; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.utils.CacheUtils; |
| | | import org.jdesktop.swingx.JXDatePicker; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | |
| | | btnSave.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | if (table.isEditing()) { |
| | | table.getCellEditor().stopCellEditing(); |
| | | } |
| | | CommonTable.saveTableList(shipList,table,columnDto); |
| | | djJdgzShipService.save(shipList); |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | } |
| | | }); |
| | | |
| | |
| | | StatistProductDto data =list.get(i); |
| | | body[i][0] = data.getName(); |
| | | body[i][1] = String.valueOf(data.getCxsl()); |
| | | body[i][2] = String.valueOf(data.getFcsl()); |
| | | body[i][2] = String.valueOf(data.getFjsl()); |
| | | body[i][3] = String.valueOf(data.getJdsl()); |
| | | body[i][4] = String.valueOf(data.getFcsl()); |
| | | body[i][5] = String.valueOf(data.getHzsl()); |
| | |
| | | import com.example.client.model.TableButton; |
| | | import com.example.client.utils.CommonTable; |
| | | import com.example.client.utils.ComplexTable; |
| | | import com.example.client.utils.Compute; |
| | | import com.example.server.progressTrack.Dto.ReportRecordDto; |
| | | import com.example.server.progressTrack.Dto.StatistReportsDto; |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel1; |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel1List; |
| | | import com.example.server.progressTrack.model.DjJdgzShip; |
| | | import com.example.server.progressTrack.model.DjJdgzTrackRecord; |
| | | import com.example.server.progressTrack.service.DjJdgzNetworkLevel1Service; |
| | | import com.example.server.progressTrack.service.DjJdgzShipService; |
| | | import com.example.server.progressTrack.service.DjJdgzTrackRecordService; |
| | |
| | | @Autowired |
| | | private DjJdgzTrackRecordService djJdgzTrackRecordService; |
| | | |
| | | private JTable table; |
| | | |
| | | public void createTable(JFrame jFrame,Long level1NetworkId) { |
| | | public void createTable(JFrame jFrame, Long level1NetworkId) { |
| | | JFrame frame1 = new JFrame("统计报表"); |
| | | frame1.setSize(1200, 700); |
| | | frame1.setResizable(false); |
| | |
| | | } |
| | | }); |
| | | |
| | | List<ColumnDto> columnDto = new ArrayList<>(); |
| | | List<StatistReportsDto> list = djJdgzTrackRecordService.getReport(level1NetworkId); |
| | | |
| | | //columnDto.add(new ColumnDto("ID", "id", -1, null,false)); |
| | |
| | | //frame1.add(scrollTable); |
| | | |
| | | |
| | | |
| | | Object[][] headerRows = new Object[2][7]; |
| | | headerRows[0] = new Object[]{"班组专业","项目总数","未完成",ComplexTable.mergeCellX,ComplexTable.mergeCellX,"已完成",ComplexTable.mergeCellX}; |
| | | headerRows[0] = new Object[]{"班组专业", "项目总数", "未完成", ComplexTable.mergeCellX, ComplexTable.mergeCellX, "已完成", ComplexTable.mergeCellX}; |
| | | //此处2-5是不会显示出来的,因为1-4向下合并了一行 + 向右合并了一列 , 而2-5被这个矩形范围包括了 |
| | | headerRows[1] = new Object[]{ComplexTable.mergeCellY, ComplexTable.mergeCellY ,"进行中","临期","逾期","正常完成","超期完成"}; |
| | | headerRows[1] = new Object[]{ComplexTable.mergeCellY, ComplexTable.mergeCellY, "进行中", "临期", "逾期", "正常完成", "超期完成"}; |
| | | |
| | | String[][] body = new String[list.size()][7]; |
| | | |
| | | for (int i = 0; i < list.size(); i++) { |
| | | StatistReportsDto data =list.get(i); |
| | | StatistReportsDto data = list.get(i); |
| | | body[i][0] = data.getTeamGroupName(); |
| | | body[i][1] = String.valueOf(data.getAllNum()); |
| | | body[i][2] = String.valueOf(data.getJxzNum()); |
| | |
| | | body[i][5] = String.valueOf(data.getZcwcNum()); |
| | | body[i][6] = String.valueOf(data.getCqwcNum()); |
| | | } |
| | | ComplexTable complexTable = new ComplexTable(headerRows, body, 171); |
| | | JScrollPane scrollTable = new JScrollPane(complexTable); |
| | | |
| | | JScrollPane scrollTable = new JScrollPane(new ComplexTable(headerRows , body,171)); |
| | | complexTable.addMouseListener(new MouseAdapter() { |
| | | @Override |
| | | public void mouseClicked(MouseEvent e) { |
| | | |
| | | int row = complexTable.rowAtPoint(e.getPoint()); |
| | | int column = complexTable.columnAtPoint(e.getPoint()); |
| | | |
| | | // 检查是否点击了有效单元格 |
| | | if (row >= 0 && column >= 1) { |
| | | Object cellValue = complexTable.getValueAt(row, column); |
| | | Integer value = Integer.parseInt(cellValue.toString()); |
| | | if (value > 0) { |
| | | Long teamgroupId = list.get(row).getTeamgroupId(); |
| | | reportRecord(column,level1NetworkId,teamgroupId); |
| | | } |
| | | } |
| | | } |
| | | }); |
| | | frame1.add(scrollTable); |
| | | frame1.setVisible(true); |
| | | } |
| | | |
| | | private void reportRecord(int column, Long level1NetworkId,Long teamgroupId) { |
| | | JFrame frame1 = new JFrame("记录"); |
| | | frame1.setSize(500, 400); |
| | | frame1.setResizable(false); |
| | | frame1.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); |
| | | frame1.setLocationRelativeTo(null); |
| | | frame1.setVisible(true); |
| | | |
| | | List<ReportRecordDto> list = djJdgzTrackRecordService.getReportRecord(level1NetworkId,column,teamgroupId); |
| | | |
| | | List<ColumnDto> columnDto = new ArrayList<>(); |
| | | //columnDto.add(new ColumnDto("ID", "id", -1, null,false)); |
| | | columnDto.add(new ColumnDto("序号", "", (500 - 10) / 3, "autoCreate", false, null, null)); |
| | | columnDto.add(new ColumnDto("设备名称", "name", (500 - 10) / 3, null, false, null, null)); |
| | | columnDto.add(new ColumnDto("节点名称", "processName", (500 - 10) / 3, null, false, null, null)); |
| | | |
| | | JTable table = CommonTable.createCommonTable(list, columnDto); |
| | | table.setRowHeight(25); |
| | | |
| | | table.setAutoResizeMode(JTable.AUTO_RESIZE_OFF); |
| | | |
| | | JScrollPane scrollPane = new JScrollPane(table, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS); |
| | | scrollPane.setViewportView(table); |
| | | scrollPane.getViewport().setBackground(Color.WHITE); |
| | | scrollPane.setPreferredSize(new Dimension(500 - 20, 400)); |
| | | |
| | | frame1.add(scrollPane); |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | |
| | | private List<ColumnDto> columnDto; |
| | | private JTable trackTable; |
| | | private DjJdgzNetworkLevel3 nowLevel3; |
| | | private JFrame nowFrame; |
| | | |
| | | public JPanel createTrack(Integer width, Integer height, DjJdgzNetworkLevel3 djJdgzNetworkLevel3,JFrame frame) { |
| | | public JPanel createTrack(Integer width, Integer height, DjJdgzNetworkLevel3 djJdgzNetworkLevel3, JFrame frame) { |
| | | nowLevel3 = djJdgzNetworkLevel3; |
| | | nowFrame = frame; |
| | | JPanel panel = new JPanel(new BorderLayout()); |
| | | panel.setPreferredSize(new Dimension(width, height)); |
| | | JPanel topJpanel = new JPanel(new FlowLayout(FlowLayout.LEFT)); |
| | | topJpanel.setPreferredSize(new Dimension(width - 10, 40)); |
| | | |
| | | JPanel centerJpanel = new JPanel(); |
| | | centerJpanel.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeight(40,frame))); |
| | | centerJpanel.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeight(40, nowFrame))); |
| | | panel.add(topJpanel, BorderLayout.NORTH); |
| | | panel.add(centerJpanel, BorderLayout.CENTER); |
| | | |
| | |
| | | columnDto.add(new ColumnDto("操作", "", 200, "", true, buttonList, null)); |
| | | |
| | | trackTable = CommonTable.createCommonTable(list, columnDto); |
| | | trackTable.setPreferredSize(new Dimension(width , height)); |
| | | trackTable.setPreferredSize(new Dimension(width, height)); |
| | | trackTable.setRowHeight(25); |
| | | |
| | | trackTable.setAutoResizeMode(JTable.AUTO_RESIZE_OFF); |
| | | |
| | | tableModelListener(trackTable, frame,list,columnDto); |
| | | tableModelListener(trackTable, list, columnDto); |
| | | |
| | | btnInsert.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | frame.setEnabled(false); |
| | | nowFrame.setEnabled(false); |
| | | SysUser user = (SysUser) CacheUtils.get("user", "user"); |
| | | if (user.getTeamgroup()==null||user.getTeamgroup().equals(nowLevel3.getTeamgroupId().toString())) { |
| | | if (user == null) { |
| | | nowFrame.setEnabled(true); |
| | | JOptionPane.showMessageDialog(null, "当前用户已失效请重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | if (user.getTeamgroup() == null || user.getTeamgroup().equals(nowLevel3.getTeamgroupId().toString())) { |
| | | DjJdgzDismantTrack djJdgzDismantTrack = new DjJdgzDismantTrack(); |
| | | djJdgzDismantTrack.setLevel3NetworkId(nowLevel3.getId()); |
| | | insert(frame,djJdgzDismantTrack); |
| | | }else{ |
| | | insert(nowFrame, djJdgzDismantTrack); |
| | | } else { |
| | | nowFrame.setEnabled(true); |
| | | JOptionPane.showMessageDialog(null, "当前用户不可操作其他专业数据", "提示", JOptionPane.WARNING_MESSAGE); |
| | | } |
| | | } |
| | |
| | | |
| | | JScrollPane scrollPane = new JScrollPane(trackTable, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS); |
| | | scrollPane.setViewportView(trackTable); |
| | | scrollPane.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeightWithScroll(40,frame))); |
| | | scrollPane.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeightWithScroll(40, nowFrame))); |
| | | centerJpanel.add(scrollPane); |
| | | frame.addComponentListener(new ComponentAdapter() { |
| | | nowFrame.addComponentListener(new ComponentAdapter() { |
| | | @Override |
| | | public void componentResized(ComponentEvent e) { |
| | | centerJpanel.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeightWithScroll(40,frame))); |
| | | scrollPane.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeightWithScroll(40,frame))); |
| | | centerJpanel.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeightWithScroll(40, nowFrame))); |
| | | scrollPane.setPreferredSize(new Dimension(width - 20, Compute.ComputeHeightWithScroll(40, nowFrame))); |
| | | centerJpanel.revalidate(); |
| | | centerJpanel.repaint(); |
| | | scrollPane.revalidate(); |
| | |
| | | } |
| | | |
| | | private void insert(JFrame jFrame, DjJdgzDismantTrack data) { |
| | | if (data.getLevel3NetworkId()==null){ |
| | | if (data.getLevel3NetworkId() == null) { |
| | | JOptionPane.showMessageDialog(null, "没有选择设备", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | |
| | | JComboBox<JComboBoxItem> comboBox0 = new JComboBox<>(cabinList); |
| | | comboBox0.setPreferredSize(new Dimension(185, 28)); |
| | | comboBox0.setSelectedIndex(-1); |
| | | if(data.getCabinId()!=null){ |
| | | if (data.getCabinId() != null) { |
| | | comboBox0.setSelectedItem(BoxIteUtils.GetSelectItemById(cabinList, data.getCabinId())); |
| | | } |
| | | |
| | |
| | | frame1.add(btnSave, new GBC(0, 2, 2, 1).setWeight(1, 0)); |
| | | |
| | | btnSave.addActionListener((e) -> { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | JComboBoxItem cabin = (JComboBoxItem) comboBox0.getSelectedItem(); |
| | | |
| | | String name = subunitName.getText(); |
| | |
| | | List<DjJdgzDismantTrack> list = new ArrayList<>(); |
| | | list.add(data); |
| | | djJdgzDismantTrackService.save(list); |
| | | |
| | | this.refreshTable(data.getLevel3NetworkId(),null); |
| | | //tableModelListener(trackTable, jFrame,list,columnDto); |
| | | this.refreshTable(data.getLevel3NetworkId(), null); |
| | | frame1.dispose(); |
| | | jFrame.setEnabled(true);//将主界面再设置为可操作的 |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | }); |
| | | } |
| | | public void refreshTable(Long level3Id,JFrame jFrame){ |
| | | |
| | | public void refreshTable(Long level3Id, JFrame jFrame) { |
| | | nowLevel3 = level3Service.get(level3Id); |
| | | List<DjJdgzDismantTrack> list = djJdgzDismantTrackService.getList(level3Id, null); |
| | | CommonTable.refreshTable(list, columnDto, trackTable); |
| | | trackTable.setRowHeight(25); |
| | | |
| | | trackTable.setAutoResizeMode(JTable.AUTO_RESIZE_OFF); |
| | | tableModelListener(trackTable, jFrame,list,columnDto); |
| | | tableModelListener(trackTable, list, columnDto); |
| | | } |
| | | |
| | | public void tableModelListener(JTable table,JFrame jFrame,List<DjJdgzDismantTrack> list,List<ColumnDto> columnDto){ |
| | | public void tableModelListener(JTable table, List<DjJdgzDismantTrack> list, List<ColumnDto> columnDto) { |
| | | table.getModel().addTableModelListener(e -> { |
| | | // 检查事件类型 |
| | | if (e.getType() == TableModelEvent.UPDATE) { |
| | |
| | | // 获取新的值 |
| | | Object newValue = table.getModel().getValueAt(row, column); |
| | | // 输出变化信息 |
| | | if (newValue.equals("edit")){ |
| | | jFrame.setEnabled(false); |
| | | if (newValue.equals("edit")) { |
| | | nowFrame.setEnabled(false); |
| | | DjJdgzDismantTrack data = list.get(row); |
| | | insert(jFrame,data); |
| | | }else if(newValue.equals("del")) { |
| | | insert(nowFrame, data); |
| | | } else if (newValue.equals("del")) { |
| | | int n = JOptionPane.showConfirmDialog(null, "是否删除?", "提示", JOptionPane.YES_NO_OPTION); |
| | | if (n == 0) { |
| | | DefaultTableModel model = (DefaultTableModel) table.getModel(); |
| | |
| | | JComboBoxItem[] teamList = sysTeamGroupClassService.getTeamList(null); |
| | | JComboBoxItem[] cabinList = cabinService.getList(); |
| | | String[] typeList = new String[]{ |
| | | "改装", "加装", "换装", "改进性修理","" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | List<DjJdgzShip> shipList = djJdgzShipService.getList(); |
| | | Map<String, Long> shipMap = new HashMap<>(); |
| | |
| | | import com.example.server.teamGroup.service.SysTeamGroupClassService; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.user.service.UserService; |
| | | import com.example.server.utils.CacheUtils; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | |
| | | saveButton.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | String type = comboBox1.getSelectedItem().toString(); |
| | | JComboBoxItem dept = (JComboBoxItem) comboBox2.getSelectedItem(); |
| | | Integer sortMax = 0; |
| | |
| | | teamGroupManageService.tableModelListener(table, jFrame, list); |
| | | frame1.dispose(); |
| | | jFrame.setEnabled(true);//将主界面再设置为可操作的 |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | } |
| | | }); |
| | | |
| | |
| | | trackPersonDesc.setText(data.getTrackPerson()); |
| | | } |
| | | |
| | | JLabel JLabel34 = new JLabel("单位"); |
| | | JLabel JLabel34 = new JLabel("T方单位"); |
| | | JTextField trackPersonUnitDesc = new JTextField(16); |
| | | if (StringUtils.isNotBlank(data.getTrackPersonUnit())) { |
| | | trackPersonUnitDesc.setText(data.getTrackPersonUnit()); |
| | |
| | | trackedPersonDesc.setText(data.getTrackedPerson()); |
| | | } |
| | | |
| | | JLabel JLabel56 = new JLabel("单位"); |
| | | JLabel JLabel56 = new JLabel("厂方单位"); |
| | | JTextField trackedPersonUnitDesc = new JTextField(16); |
| | | if (StringUtils.isNotBlank(data.getTrackedPersonUnit())) { |
| | | trackedPersonUnitDesc.setText(data.getTrackedPersonUnit()); |
| | |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user", "user"); |
| | | if (user == null) { |
| | | JOptionPane.showMessageDialog(null, "当前用户已失效请重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | DjJdgzNetworkLevel3 level3 = djJdgzNetworkLevel3Service.get(data.getLevel3NetworkId()); |
| | | if (user.getTeamgroup() != null && !user.getTeamgroup().equals(level3.getTeamgroupId().toString())) { |
| | | JOptionPane.showMessageDialog(null, "当前用户不可操作其他专业数据", "提示", JOptionPane.WARNING_MESSAGE); |
| | |
| | | trackRecordManageService.tableModelListener(table, jFrame, list); |
| | | frame1.dispose(); |
| | | jFrame.setEnabled(true);//将主界面再设置为可操作的 |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | |
| | | } |
| | | }); |
| | | |
| | |
| | | |
| | | JComboBoxItem[] teamList = sysTeamGroupClassService.getTeamList(null); |
| | | String[] typeList = new String[]{ |
| | | "","改装", "加装", "换装", "改进性修理" |
| | | "","改装", "加装", "换装", "修理","改进性修理" |
| | | }; |
| | | |
| | | JLabel JLabel0 = new JLabel("工程"); |
| | |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | JComboBoxItem project = (JComboBoxItem) comboBox.getSelectedItem(); |
| | | list = djJdgzTrackRecordService.getList(project.getId(), null, null, null, null, null, sb.getText()); |
| | | list = djJdgzTrackRecordService.getList(project.getId(), null, null, null, null, 0, sb.getText()); |
| | | |
| | | CommonTable.refreshTable(list, columnDto, table); |
| | | table.setRowHeight(25); |
| | |
| | | import com.example.server.teamGroup.service.SysTeamGroupClassService; |
| | | import com.example.server.user.model.SysUser; |
| | | import com.example.server.user.service.UserService; |
| | | import com.example.server.utils.CacheUtils; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.jdesktop.swingx.JXDatePicker; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | saveButton.addActionListener(new ActionListener() { |
| | | @Override |
| | | public void actionPerformed(ActionEvent e) { |
| | | SysUser user = (SysUser) CacheUtils.get("user","user"); |
| | | if (user==null){ |
| | | JOptionPane.showMessageDialog(null, "用户失效请退出并重新登录", "提示", JOptionPane.WARNING_MESSAGE); |
| | | return; |
| | | } |
| | | JComboBoxItem dept = (JComboBoxItem) comboBox1.getSelectedItem(); |
| | | JComboBoxItem team = (JComboBoxItem) comboBox2.getSelectedItem(); |
| | | |
| | |
| | | userManageService.tableModelListener(table,jFrame,list); |
| | | frame1.dispose(); |
| | | jFrame.setEnabled(true);//将主界面再设置为可操作的 |
| | | JOptionPane.showMessageDialog(null, "保存成功", "提示", JOptionPane.WARNING_MESSAGE); |
| | | } |
| | | }); |
| | | |
| | |
| | | syncTable("dj_jdgz_network_level3_list"); |
| | | syncTable("dj_jdgz_track_record"); |
| | | syncTable("dj_sys_oss"); |
| | | syncTable("dj_sys_teamgroup_class"); |
| | | syncTable("sys_user"); |
| | | syncTable("dj_jdgz_dismant_track"); |
| | | syncTable("dj_jdgz_ship"); |
| | | } else if (mySite.equals("TD")) { |
| | | if (otherSite.equals("TD")) { |
| | | syncTable("dj_jdgz_network_level3"); |
| | |
| | | syncTable("dj_sys_oss"); |
| | | syncTable("dj_jdgz_dismant_track"); |
| | | syncTable("dj_jdgz_handover"); |
| | | syncTable("dj_sys_teamgroup_class"); |
| | | syncTable("sys_user"); |
| | | syncTable("dj_jdgz_ship"); |
| | | } else if ("工作组".equals(otherSite)) { |
| | | syncTable("dj_jdgz_handover"); |
| | | syncTable("dj_jdgz_network_level1"); |
| | |
| | | import org.apache.ibatis.reflection.MetaObject; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.swing.*; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | |
| | | |
| | | if (object instanceof PlatformLogEntity) { |
| | | PlatformLogEntity entity = (PlatformLogEntity) object; |
| | | entity.setCreator(user.getUserId());// 创建者 |
| | | entity.setCreator(user.getId());// 创建者 |
| | | entity.setCreateDate(date);// 创建时间 |
| | | } |
| | | if (object instanceof PlatformEntity) { |
| | | PlatformEntity entity = (PlatformEntity) object; |
| | | entity.setDelete(false); |
| | | entity.setUpdater(user.getUserId());// 更新者 |
| | | entity.setUpdater(user.getId());// 更新者 |
| | | entity.setUpdateDate(date);// 更新时间 |
| | | } |
| | | if (object instanceof TenantEntity) { |
| | |
| | | Object object = metaObject.getOriginalObject(); |
| | | if (object instanceof PlatformEntity) { |
| | | PlatformEntity entity = (PlatformEntity) object; |
| | | entity.setUpdater(user.getUserId());// 更新者 |
| | | entity.setUpdater(user.getId());// 更新者 |
| | | entity.setUpdateDate(date);// 更新时间 |
| | | } |
| | | |
New file |
| | |
| | | package com.example.server.progressTrack.Dto; |
| | | |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | public class ReportRecordDto { |
| | | private String name; |
| | | private String processName; |
| | | } |
| | |
| | | @Data |
| | | public class StatistReportsDto { |
| | | private String teamGroupName; |
| | | private Long teamgroupId; |
| | | private Integer allNum; |
| | | private Integer jxzNum; |
| | | private Integer lqNum; |
| | |
| | | package com.example.server.progressTrack.dao; |
| | | |
| | | import com.example.server.dao.BaseDao; |
| | | import com.example.server.progressTrack.Dto.ReportRecordDto; |
| | | import com.example.server.progressTrack.Dto.StatistReportsDto; |
| | | import com.example.server.progressTrack.model.DjJdgzTrackRecord; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | |
| | | List<DjJdgzTrackRecord> getListByImport(Long level1Id, Long level2Id, Long level2NodeId, String selectedIds); |
| | | |
| | | void retract(Long id); |
| | | |
| | | List<ReportRecordDto> getReportRecord(Long level1NetworkId, int column, Long teamgroupId); |
| | | } |
| | |
| | | import com.example.client.service.BaseService; |
| | | import com.example.server.ExportExcel.dto.ExprotExcelDto; |
| | | import com.example.server.ExportExcel.method.ExcelExport; |
| | | import com.example.server.progressTrack.Dto.ReportRecordDto; |
| | | import com.example.server.progressTrack.Dto.StatistReportsDto; |
| | | import com.example.server.progressTrack.dao.DjJdgzTrackRecordDao; |
| | | import com.example.server.progressTrack.model.DjJdgzNetworkLevel1; |
| | |
| | | if (isTyRole.equals(true) || isYwzRole.equals(true)) { |
| | | userId = UserContext.getUser().getId(); |
| | | }*/ |
| | | List<DjJdgzTrackRecord> list = baseDao.getList(level1NetworkId,deptId,teamId,cabinId,type, status, name); |
| | | List<DjJdgzTrackRecord> list = baseDao.getList(level1NetworkId, deptId, teamId, cabinId, type, status, name); |
| | | /*if (list != null && list.size() > 0) { |
| | | sysOssService.setListOsses(list, "ProjectProgressFileUpload"); |
| | | }*/ |
| | |
| | | } else { |
| | | List<DjJdgzNetworkLevel3List> list = djJdgzNetworkLevel3ListService.getList(level3.getId()); |
| | | for (DjJdgzNetworkLevel3List item : list) { |
| | | if(item.getProcessName().equals(progressName)){ |
| | | if (item.getProcessName().equals(progressName)) { |
| | | data.setLevel3NodeId(item.getId()); |
| | | data.setEstimatedCompletionTime(item.getRequiredCompletionTime()); |
| | | break; |
| | |
| | | public void retract(Long id) { |
| | | baseDao.retract(id); |
| | | } |
| | | |
| | | public List<ReportRecordDto> getReportRecord(Long level1NetworkId, int column, Long teamgroupId) { |
| | | return baseDao.getReportRecord(level1NetworkId, column, teamgroupId); |
| | | } |
| | | } |
| | |
| | | @ApiModelProperty(value = "T队") |
| | | private String boatfleet; |
| | | |
| | | private Long userId; |
| | | |
| | | @TableField(exist = false) |
| | | private Boolean exist; |
| | | |
| | |
| | | com.example: debug |
| | | file: log/my.log |
| | | |
| | | server: |
| | | port: 3030 |
| | | |
| | | j2cache: |
| | | config-location: classpath:/j2cache.properties |
| | | |
| | |
| | | and a.TEAMGROUP_ID = ${teamId} |
| | | </if> |
| | | <if test="cabinId!=null"> |
| | | and a.cabin_id LIKE '%${cabinId}%' |
| | | and a.cabin_id = ${cabinId} |
| | | </if> |
| | | <if test="type!=null and type!=''"> |
| | | and a.type = #{type} |
| | |
| | | and b.TEAMGROUP_ID = ${teamId} |
| | | </if> |
| | | <if test="cabinId!=null"> |
| | | and b.cabin_id LIKE '%${cabinId}%' |
| | | and b.cabin_id = ${cabinId} |
| | | </if> |
| | | <if test="type!=null and type!=''"> |
| | | and b.type = #{type} |
| | |
| | | UPDATE dj_jdgz_track_record |
| | | SET CURRENT_STATUS = 0 |
| | | WHERE LEVEL3_NETWORK_ID = ( |
| | | SELECT LEVEL3_NETWORK_ID FROM dj_jdgz_track_record WHERE id = ${id} |
| | | SELECT LEVEL3_NETWORK_ID |
| | | FROM dj_jdgz_track_record |
| | | WHERE id = ${id} |
| | | ) |
| | | AND create_date >= ( |
| | | SELECT create_date FROM dj_jdgz_track_record WHERE id = ${id} |
| | | SELECT create_date |
| | | FROM dj_jdgz_track_record |
| | | WHERE id = ${id} |
| | | ); |
| | | </update> |
| | | |
| | |
| | | and c.TEAMGROUP_ID = ${teamId} |
| | | </if> |
| | | <if test="cabinId!=null"> |
| | | and c.cabin_id LIKE '%${cabinId}%' |
| | | and c.cabin_id = ${cabinId} |
| | | </if> |
| | | <if test="type!=null and type!=''"> |
| | | and c.type = #{type} |
| | |
| | | </select> |
| | | <select id="getHistory" resultType="com.example.server.progressTrack.model.DjJdgzTrackRecord"> |
| | | select GENERAL_REPAIR_UNIT || ',' || GENERAL_REPAIR_UNIT_DIRECTOR || ',' || |
| | | GENERAL_REPAIR_UNIT_CONTACT AS generalRepair, |
| | | REPAIR_UNIT || ',' || REPAIR_UNIT_DIRECTOR || ',' || REPAIR_UNIT_CONTACT AS `repair`, |
| | | track_person || ',' || track_person_unit || ',' || track_person_contact AS trackPerson, |
| | | tracked_person || ',' || tracked_person_unit || ',' || tracked_person_contact AS trackedPerson, |
| | | GENERAL_REPAIR_UNIT_CONTACT AS generalRepair, |
| | | REPAIR_UNIT || ',' || REPAIR_UNIT_DIRECTOR || ',' || REPAIR_UNIT_CONTACT AS `repair`, |
| | | track_person || ',' || track_person_unit || ',' || track_person_contact AS trackPerson, |
| | | tracked_person || ',' || tracked_person_unit || ',' || tracked_person_contact AS trackedPerson, |
| | | track_method, |
| | | track_location, |
| | | CURRENT_STATUS, |
| | |
| | | dj_jdgz_track_record where is_delete = 0 ) |
| | | and a.is_delete = 0 |
| | | <if test="userId!=null"> |
| | | AND a.TEAMGROUP_ID in (select teamgroup from sys_user where is_delete=0 and user_id=#{userId}) |
| | | AND a.TEAMGROUP_ID in (select teamgroup from sys_user where is_delete=0 and id=#{userId}) |
| | | </if> |
| | | AND b.IS_DELETE = 0 |
| | | AND c.IS_DELETE = 0 |
| | |
| | | ORDER BY |
| | | a.REQUIRED_COMPLETION_TIME |
| | | </select> |
| | | <select id="getReportRecord" resultType="com.example.server.progressTrack.Dto.ReportRecordDto"> |
| | | select a.NAME,b.PROCESS_NAME |
| | | from dj_jdgz_network_level3 a, |
| | | dj_jdgz_network_level3_list b, |
| | | dj_jdgz_network_level1 c |
| | | where a.IS_DELETE = 0 |
| | | and a.LEVEL1_NETWORK_ID = ${level1NetworkId} |
| | | and a.TEAMGROUP_ID = ${teamgroupId} |
| | | and a.LEVEL1_NETWORK_ID = c.id |
| | | and b.IS_DELETE = 0 |
| | | and b.NETWORK_ID = a.id |
| | | and c.IS_DELETE = 0 |
| | | <if test="column==2"> |
| | | and (b.CURRENT_STATUS = 0 or b.CURRENT_STATUS is null) |
| | | and b.REQUIRED_COMPLETION_TIME >= ( SELECT date( 'now', '-' || c.advent_day || ' days' ) ) |
| | | </if> |
| | | <if test="column==3"> |
| | | and (b.CURRENT_STATUS = 0 or b.CURRENT_STATUS is null) |
| | | and b.REQUIRED_COMPLETION_TIME < ( SELECT date( 'now', '-' || c.advent_day || ' days' ) ) |
| | | </if> |
| | | <if test="column==4"> |
| | | and (b.CURRENT_STATUS = 0 or b.CURRENT_STATUS is null) |
| | | and b.REQUIRED_COMPLETION_TIME < ( SELECT datetime( 'now' ) ) |
| | | </if> |
| | | <if test="column==5"> |
| | | and b.CURRENT_STATUS = 1 |
| | | AND b.REQUIRED_COMPLETION_TIME <= b.ACTUAL_COMPLETION |
| | | </if> |
| | | <if test="column==6"> |
| | | and b.CURRENT_STATUS = 1 |
| | | AND b.REQUIRED_COMPLETION_TIME > b.ACTUAL_COMPLETION |
| | | </if> |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | <select id="getList" resultType="com.example.server.progressTrack.model.ExportRecord"> |
| | | select a.*, b.user_name |
| | | from export_record a |
| | | left join sys_user b on b.user_id = a.creator |
| | | left join sys_user b on b.id = a.creator |
| | | </select> |
| | | </mapper> |
| | |
| | | <select id="getList" resultType="com.example.server.progressTrack.model.ImportRecord"> |
| | | select a.*, b.user_name |
| | | from import_record a |
| | | left join sys_user b on b.user_id = a.creator |
| | | left join sys_user b on b.id = a.creator |
| | | </select> |
| | | </mapper> |
| | |
| | | |
| | | <select id="getList" resultType="com.example.server.user.model.SysUser"> |
| | | SELECT |
| | | a.user_id, |
| | | a.id, |
| | | a.user_name, |
| | | a.nick_name, |
| | | a.password, |