• 基于JavaGUI的大学生竞赛管理系统


    目录

    一、需求分析

    1.系统背景

    2. 系统功能结构(需包含功能结构框图和模块说明)

    3. 系统功能简介

    二、 概念模型设计

    三、逻辑模型设计

    1.ER模型向关系模型转换规则

    1实体间的联系是1:1

    2如实体间的联系是1:N

    3如实体间的联系是M:N

    2.转换后的关系模型

    3.关系模型优化(达到3NF)

    四、物理设计

    1.创建数据库的SQL语句或截图

    五、数据库实施

    3.数据处理

    六、数据库应用系统实现

    2.和数据库连接的程序语句

    3.具体实现代码(注意排版)

    3.1 JDBCUtil.java

    3.2 MemberDao.java

    七、总结
    一、需求分析
    1.系统背景
    全国各地举办的大学生竞赛活动数目也是逐年增加,报名参加各个竞赛的大学生数量也是逐年地大批增长。面对如此大的数目的参赛方信息的录入,原始的数据采集系统已经远远不能满足要求,如何利用现代信息技术使得举办方拥有快速、高效的参赛者信息反馈能力和高度的效率,已经是竞赛举办方特别关心的问题。通过开发这个高校竞赛信息管理系统,使参赛者信息的录入和管理工作系统化,规范化,自动化,从而达到提高管理效率的目的。满足日常管理的需要,并达到操作过程中的直观,方便,实用,安全等要求;系统采用模块化程序设计方法,这样既便于系统功能的各种组合,又便于未参与开发的技术维护人员补充,维护;系统应具备数据库维护功能,及时根据用户需求进行数据的添加,删除,修改等操作。
    2.系统功能结构(需包含功能结构框图和模块说明)

    (1)功能结构图
    (2)模块说明
    高校竞赛信息管理系统分为三个模块:参赛队伍信息模块,校方信息管理模块,主办方信息管理模块。
    参赛队伍信息模块包括:参赛队伍成员的登录,以及对密码的修改;参赛成员查看本队详细信息,并对其有修改、删除权限;提交竞赛作品;查看该队竞赛作品信息的修改、删除权限;访问查询本校其他参赛队伍基本信息。
    校方信息管理模块:校方管理员的登录、以及对密码的修改;对本校参赛信息的查询、统计权限;对参赛队伍信息的查看、修改权限。
    主办方信息管理模块:校方管理员的登录;增删查改删除队伍;增删查改校方管理员信息;增删查改主办方管理员信息。
    3.系统功能简介
    高校竞赛管理系统所涉及的用户包括:参赛学生、校方信息管理员、主办方信息管理员。
    参赛学生可以根据主办方管理员注册的登录用户名和密码进行登录,及对密码的修改;到系统内部关于本队的内容进行查看、修改和删除;对竞赛作品提交信息的输入、查看、修改和删除;对该校其他参赛队伍的参赛信息进行访问、查询。
    校方信息管理员可以根据主办方管理员注册的登录用户名和密码进行登录,及对密码的修改;根据需要对参赛队伍进行查看、修改和删除操作。
    主办方终端信息管理员可以对全部的参赛信息新增、查看、修改和删除;对全部的作品信息进行查看;对所有参赛作品进行打分;新增、删除、查看、修改校方管理员信息;新增、删除、查看、修改主办方管理员信息。
    本文转载自:http://www.biyezuopin.vip/onews.asp?id=16545

    /*
     * Created by JFormDesigner on Sun Dec 22 09:40:54 CST 2019
     */
    
    package competition.management.system.view.hoster;
    
    import competition.management.system.dao.*;
    import competition.management.system.entity.*;
    import competition.management.system.util.JDBCUtil;
    
    import java.awt.*;
    import java.awt.event.*;
    import java.sql.SQLException;
    import java.util.*;
    import java.util.List;
    import javax.swing.*;
    
    /**
     * @author zzc
     */
    public class AddTeamFrame extends JFrame {
        private HosterMainFrame hosterMainFrame;
    
        private final SchoolAdminDao schoolAdminDao = JDBCUtil.getSchoolAdminDao();
        private final TeamDao teamDao = JDBCUtil.getTeamDao();
        private final MemberDao memberDao = JDBCUtil.getMemberDao();
        private final GradeDao gradeDao = JDBCUtil.getGradeDao();
        private final ProductionDao productionDao = JDBCUtil.getProductionDao();
        private final TeacherDao teacherDao = JDBCUtil.getTeacherDao();
        private final HosterAdminDao hosterAdminDao = JDBCUtil.getHosterAdminDao();
    
        public AddTeamFrame() {
            initComponents();
        }
    
        public void load(){
            textField_team_id.setText(UUID.randomUUID().toString());
            textField_teacher_id.setText(UUID.randomUUID().toString());
            textField_captain_id.setText(UUID.randomUUID().toString());
            textField_member1_id.setText(UUID.randomUUID().toString());
            textField_member2_id.setText(UUID.randomUUID().toString());
    
            setExtendedState(JFrame.MAXIMIZED_BOTH);
        }
    
        public HosterMainFrame getHosterMainFrame() {
            return hosterMainFrame;
        }
    
        public void setHosterMainFrame(HosterMainFrame hosterMainFrame) {
            this.hosterMainFrame = hosterMainFrame;
        }
    
        private void button1ActionPerformed(ActionEvent e) {
            ResourceBundle bundle = ResourceBundle.getBundle("competition.management.system.view.hoster.AddTeamFrame");
    
            try {
                JDBCUtil.getConnection().setAutoCommit(false);
                Teacher teacher = new Teacher();
                teacher.setId(textField_teacher_id.getText());
                teacher.setCode(textField_teacher_code.getText());
                teacher.setName(textField_teacher_name.getText());
                teacher.setTitle(textField_teacher_title.getText());
                teacher.setEmail(textField_teacher_email.getText());
                teacher.setPhone(textField_teacher_phone.getText());
                teacher.setSchool(textField_teacher_school.getText());
                teacher.setDepartment(textField_teacher_department.getText());
    
                teacherDao.insert(teacher);
    
                Team team = new Team();
                team.setId(textField_team_id.getText());
                team.setCode(textField_team_code.getText());
                team.setName(textField_team_name.getText());
                team.setGroup((String) comboBox_team_group.getSelectedItem());
                team.setSchool(textField_team_school.getText());
                List<SchoolAdmin> schoolAdmins = schoolAdminDao.findBySchoolName(team.getSchool());
                team.setSchoolAdmin(schoolAdmins.get(new Random().nextInt(schoolAdmins.size())));
                team.setTeacher(teacher);
                team.setProduction(new Production());
    
                teamDao.insert(team);
    
                Member cap = new Member();
                cap.setId(textField_captain_id.getText());
                cap.setIdCard(textField_captain_idCard.getText());
                cap.setName(textField_captain_name.getText());
                cap.setEmail(textField_captain_email.getText());
                cap.setPhone(textField_captain_phone.getText());
                cap.setSchool(textField_captain_school.getText());
                cap.setDepartment(textField_captain_department.getText());
                cap.setCls(textField_captain_class.getText());
                cap.setTeam(team);
                cap.setLeader(true);
                memberDao.insert(cap);
    
                Member member1 = new Member();
                member1.setId(textField_member1_id.getText());
                member1.setIdCard(textField_member1_idCard.getText());
                member1.setName(textField_member1_name.getText());
                member1.setEmail(textField_member1_email.getText());
                member1.setPhone(textField_member1_phone.getText());
                member1.setSchool(textField_member1_school.getText());
                member1.setDepartment(textField_member1_department.getText());
                member1.setCls(textField_member1_class.getText());
                member1.setTeam(team);
                member1.setLeader(true);
                memberDao.insert(member1);
    
                Member member2 = new Member();
                member2.setId(textField_member2_id.getText());
                member2.setIdCard(textField_member2_idCard.getText());
                member2.setName(textField_member2_name.getText());
                member2.setEmail(textField_member2_email.getText());
                member2.setPhone(textField_member2_phone.getText());
                member2.setSchool(textField_member2_school.getText());
                member2.setDepartment(textField_member2_department.getText());
                member2.setCls(textField_member2_class.getText());
                member2.setTeam(team);
                member2.setLeader(true);
                memberDao.insert(member2);
    
                JDBCUtil.getConnection().commit();
                setVisible(false);
                hosterMainFrame.load();
            } catch (SQLException ex) {
                try {
                    JDBCUtil.getConnection().rollback();
                } catch (SQLException exc) {
                    exc.printStackTrace();
                }
                ex.printStackTrace();
                JOptionPane.showMessageDialog(this, bundle.getString("AddTeamFrame.alert.add.error") + "\n" + ex.getMessage(), "", JOptionPane.ERROR_MESSAGE);
            }
        }
    
        private void initComponents() {
            // JFormDesigner - Component initialization - DO NOT MODIFY  //GEN-BEGIN:initComponents
            ResourceBundle bundle = ResourceBundle.getBundle("competition.management.system.view.hoster.AddTeamFrame");
            scrollPane1 = new JScrollPane();
            panel1 = new JPanel();
            label1 = new JLabel();
            textField_team_id = new JTextField();
            label2 = new JLabel();
            textField_team_code = new JTextField();
            textField_team_name = new JTextField();
            label4 = new JLabel();
            label5 = new JLabel();
            textField_team_school = new JTextField();
            label7 = new JLabel();
            label8 = new JLabel();
            label9 = new JLabel();
            comboBox_team_group = new JComboBox<>();
            label3 = new JLabel();
            label6 = new JLabel();
            textField_teacher_id = new JTextField();
            label10 = new JLabel();
            textField_teacher_code = new JTextField();
            label11 = new JLabel();
            textField_teacher_name = new JTextField();
            label12 = new JLabel();
            label13 = new JLabel();
            label14 = new JLabel();
            label15 = new JLabel();
            label16 = new JLabel();
            textField_teacher_phone = new JTextField();
            textField_teacher_email = new JTextField();
            textField_teacher_title = new JTextField();
            textField_teacher_school = new JTextField();
            textField_teacher_department = new JTextField();
            label18 = new JLabel();
            textField_captain_id = new JTextField();
            label19 = new JLabel();
            textField_captain_idCard = new JTextField();
            label20 = new JLabel();
            textField_captain_name = new JTextField();
            label21 = new JLabel();
            textField_captain_phone = new JTextField();
            label22 = new JLabel();
            textField_captain_email = new JTextField();
            label23 = new JLabel();
            textField_captain_school = new JTextField();
            label24 = new JLabel();
            textField_captain_department = new JTextField();
            label25 = new JLabel();
            textField_captain_class = new JTextField();
            label26 = new JLabel();
            textField_member1_id = new JTextField();
            label27 = new JLabel();
            textField_member1_idCard = new JTextField();
            label28 = new JLabel();
            textField_member1_name = new JTextField();
            label29 = new JLabel();
            textField_member1_phone = new JTextField();
            label30 = new JLabel();
            textField_member1_email = new JTextField();
            label31 = new JLabel();
            textField_member1_school = new JTextField();
            label32 = new JLabel();
            textField_member1_department = new JTextField();
            label33 = new JLabel();
            textField_member1_class = new JTextField();
            label34 = new JLabel();
            textField_member2_id = new JTextField();
            label35 = new JLabel();
            textField_member2_idCard = new JTextField();
            label36 = new JLabel();
            textField_member2_name = new JTextField();
            label37 = new JLabel();
            textField_member2_phone = new JTextField();
            label38 = new JLabel();
            textField_member2_email = new JTextField();
            label39 = new JLabel();
            textField_member2_school = new JTextField();
            label40 = new JLabel();
            textField_member2_department = new JTextField();
            label41 = new JLabel();
            textField_member2_class = new JTextField();
            toolBar1 = new JToolBar();
            button1 = new JButton();
    
            //======== this ========
            Container contentPane = getContentPane();
            contentPane.setLayout(new BorderLayout());
    
            //======== scrollPane1 ========
            {
                scrollPane1.setAutoscrolls(true);
    
                //======== panel1 ========
                {
                    panel1.setLayout(null);
    
                    //---- label1 ----
                    label1.setText(bundle.getString("AddTeamFrame.label1.text"));
                    panel1.add(label1);
                    label1.setBounds(25, 55, 40, 17);
    
                    //---- textField_team_id ----
                    textField_team_id.setEditable(false);
                    panel1.add(textField_team_id);
                    textField_team_id.setBounds(80, 45, 165, 30);
    
                    //---- label2 ----
                    label2.setText(bundle.getString("AddTeamFrame.label2.text_3"));
                    panel1.add(label2);
                    label2.setBounds(310, 50, 39, 17);
                    panel1.add(textField_team_code);
                    textField_team_code.setBounds(375, 45, 165, 30);
                    panel1.add(textField_team_name);
                    textField_team_name.setBounds(675, 45, 165, 30);
    
                    //---- label4 ----
                    label4.setText(bundle.getString("AddTeamFrame.label4.text_4"));
                    panel1.add(label4);
                    label4.setBounds(20, 100, 50, 17);
    
                    //---- label5 ----
                    label5.setText(bundle.getString("AddTeamFrame.label5.text_4"));
                    panel1.add(label5);
                    label5.setBounds(310, 100, 39, 17);
                    panel1.add(textField_team_school);
                    textField_team_school.setBounds(375, 95, 165, 30);
    
                    //---- label7 ----
                    label7.setText(bundle.getString("AddTeamFrame.label7.text_3"));
                    label7.setFont(new Font("Microsoft YaHei UI", Font.PLAIN, 20));
                    panel1.add(label7);
                    label7.setBounds(0, 0, 80, 27);
    
                    //---- label8 ----
                    label8.setText(bundle.getString("AddTeamFrame.label8.text_2"));
                    label8.setFont(new Font("Microsoft YaHei UI", Font.PLAIN, 20));
                    panel1.add(label8);
                    label8.setBounds(0, 145, 80, 27);
    
                    //---- label9 ----
                    label9.setText(bundle.getString("AddTeamFrame.label9.text_2"));
                    label9.setFont(new Font("Microsoft YaHei UI", Font.PLAIN, 20));
                    panel1.add(label9);
                    label9.setBounds(0, 310, 80, 27);
    
                    //---- comboBox_team_group ----
                    comboBox_team_group.setModel(new DefaultComboBoxModel<>(new String[] {
                        "A",
                        "B",
                        "C",
                        "D",
                        "E",
                        "F"
                    }));
                    panel1.add(comboBox_team_group);
                    comboBox_team_group.setBounds(80, 95, 165, 30);
    
                    //---- label3 ----
                    label3.setText(bundle.getString("AddTeamFrame.label3.text_3"));
                    panel1.add(label3);
                    label3.setBounds(615, 50, 39, 17);
    
                    //---- label6 ----
                    label6.setText(bundle.getString("AddTeamFrame.label6.text_2"));
                    panel1.add(label6);
                    label6.setBounds(40, 190, 25, 17);
    
                    //---- textField_teacher_id ----
                    textField_teacher_id.setEditable(false);
                    panel1.add(textField_teacher_id);
                    textField_teacher_id.setBounds(80, 180, 165, 30);
    
                    //---- label10 ----
                    label10.setText(bundle.getString("AddTeamFrame.label10.text_2"));
                    panel1.add(label10);
                    label10.setBounds(310, 185, 39, 17);
                    panel1.add(textField_teacher_code);
                    textField_teacher_code.setBounds(375, 175, 165, 30);
    
                    //---- label11 ----
                    label11.setText(bundle.getString("AddTeamFrame.label11.text_2"));
                    panel1.add(label11);
                    label11.setBounds(615, 185, 39, 17);
                    panel1.add(textField_teacher_name);
                    textField_teacher_name.setBounds(675, 180, 165, 30);
    
                    //---- label12 ----
                    label12.setText(bundle.getString("AddTeamFrame.label12.text_2"));
                    panel1.add(label12);
                    label12.setBounds(30, 230, 40, 17);
    
                    //---- label13 ----
                    label13.setText(bundle.getString("AddTeamFrame.label13.text_2"));
                    panel1.add(label13);
                    label13.setBounds(310, 230, 39, 17);
    
                    //---- label14 ----
                    label14.setText(bundle.getString("AddTeamFrame.label14.text_2"));
                    panel1.add(label14);
                    label14.setBounds(615, 225, 39, 17);
    
                    //---- label15 ----
                    label15.setText(bundle.getString("AddTeamFrame.label15.text_2"));
                    panel1.add(label15);
                    label15.setBounds(30, 275, 40, 17);
    
                    //---- label16 ----
                    label16.setText(bundle.getString("AddTeamFrame.label16.text_2"));
                    panel1.add(label16);
                    label16.setBounds(310, 270, 39, 17);
                    panel1.add(textField_teacher_phone);
                    textField_teacher_phone.setBounds(80, 225, 165, 30);
                    panel1.add(textField_teacher_email);
                    textField_teacher_email.setBounds(375, 225, 165, 30);
                    panel1.add(textField_teacher_title);
                    textField_teacher_title.setBounds(675, 220, 165, 30);
                    panel1.add(textField_teacher_school);
                    textField_teacher_school.setBounds(80, 270, 165, 30);
                    panel1.add(textField_teacher_department);
                    textField_teacher_department.setBounds(375, 265, 165, 30);
    
                    //---- label18 ----
                    label18.setText(bundle.getString("AddTeamFrame.label18.text_2"));
                    panel1.add(label18);
                    label18.setBounds(15, 355, 50, 17);
    
                    //---- textField_captain_id ----
                    textField_captain_id.setEditable(false);
                    panel1.add(textField_captain_id);
                    textField_captain_id.setBounds(80, 345, 165, 30);
    
                    //---- label19 ----
                    label19.setText(bundle.getString("AddTeamFrame.label19.text_2"));
                    panel1.add(label19);
                    label19.setBounds(300, 350, 70, 17);
                    panel1.add(textField_captain_idCard);
                    textField_captain_idCard.setBounds(375, 340, 165, 30);
    
                    //---- label20 ----
                    label20.setText(bundle.getString("AddTeamFrame.label20.text_2"));
                    panel1.add(label20);
                    label20.setBounds(625, 350, 40, 17);
                    panel1.add(textField_captain_name);
                    textField_captain_name.setBounds(675, 345, 165, 30);
    
                    //---- label21 ----
                    label21.setText(bundle.getString("AddTeamFrame.label21.text_2"));
                    panel1.add(label21);
                    label21.setBounds(30, 395, 40, 17);
                    panel1.add(textField_captain_phone);
                    textField_captain_phone.setBounds(80, 390, 165, 30);
    
                    //---- label22 ----
                    label22.setText(bundle.getString("AddTeamFrame.label22.text_2"));
                    panel1.add(label22);
                    label22.setBounds(325, 395, 40, 17);
                    panel1.add(textField_captain_email);
                    textField_captain_email.setBounds(375, 390, 165, 30);
    
                    //---- label23 ----
                    label23.setText(bundle.getString("AddTeamFrame.label23.text_2"));
                    panel1.add(label23);
                    label23.setBounds(625, 395, 40, 17);
                    panel1.add(textField_captain_school);
                    textField_captain_school.setBounds(675, 390, 165, 30);
    
                    //---- label24 ----
                    label24.setText(bundle.getString("AddTeamFrame.label24.text_2"));
                    panel1.add(label24);
                    label24.setBounds(30, 440, 35, 17);
                    panel1.add(textField_captain_department);
                    textField_captain_department.setBounds(80, 435, 165, 30);
    
                    //---- label25 ----
                    label25.setText(bundle.getString("AddTeamFrame.label25.text_2"));
                    panel1.add(label25);
                    label25.setBounds(325, 440, 40, 17);
                    panel1.add(textField_captain_class);
                    textField_captain_class.setBounds(375, 435, 165, 30);
    
                    //---- label26 ----
                    label26.setText(bundle.getString("AddTeamFrame.label26.text_2"));
                    panel1.add(label26);
                    label26.setBounds(25, 495, 40, 17);
    
                    //---- textField_member1_id ----
                    textField_member1_id.setEditable(false);
                    panel1.add(textField_member1_id);
                    textField_member1_id.setBounds(80, 485, 165, 30);
    
                    //---- label27 ----
                    label27.setText(bundle.getString("AddTeamFrame.label27.text_2"));
                    panel1.add(label27);
                    label27.setBounds(300, 490, 70, 17);
                    panel1.add(textField_member1_idCard);
                    textField_member1_idCard.setBounds(375, 480, 165, 30);
    
                    //---- label28 ----
                    label28.setText(bundle.getString("AddTeamFrame.label28.text_2"));
                    panel1.add(label28);
                    label28.setBounds(630, 490, 35, 17);
                    panel1.add(textField_member1_name);
                    textField_member1_name.setBounds(675, 485, 165, 30);
    
                    //---- label29 ----
                    label29.setText(bundle.getString("AddTeamFrame.label29.text_2"));
                    panel1.add(label29);
                    label29.setBounds(30, 535, 35, 17);
                    panel1.add(textField_member1_phone);
                    textField_member1_phone.setBounds(80, 530, 165, 30);
    
                    //---- label30 ----
                    label30.setText(bundle.getString("AddTeamFrame.label30.text_2"));
                    panel1.add(label30);
                    label30.setBounds(325, 535, 35, 17);
                    panel1.add(textField_member1_email);
                    textField_member1_email.setBounds(375, 530, 165, 30);
    
                    //---- label31 ----
                    label31.setText(bundle.getString("AddTeamFrame.label31.text_2"));
                    panel1.add(label31);
                    label31.setBounds(625, 535, 35, 17);
                    panel1.add(textField_member1_school);
                    textField_member1_school.setBounds(675, 530, 165, 30);
    
                    //---- label32 ----
                    label32.setText(bundle.getString("AddTeamFrame.label32.text_2"));
                    panel1.add(label32);
                    label32.setBounds(30, 580, 35, 17);
                    panel1.add(textField_member1_department);
                    textField_member1_department.setBounds(80, 575, 165, 30);
    
                    //---- label33 ----
                    label33.setText(bundle.getString("AddTeamFrame.label33.text_2"));
                    panel1.add(label33);
                    label33.setBounds(325, 580, 35, 17);
                    panel1.add(textField_member1_class);
                    textField_member1_class.setBounds(375, 575, 165, 30);
    
                    //---- label34 ----
                    label34.setText(bundle.getString("AddTeamFrame.label34.text_2"));
                    panel1.add(label34);
                    label34.setBounds(25, 635, 40, 17);
    
                    //---- textField_member2_id ----
                    textField_member2_id.setEditable(false);
                    panel1.add(textField_member2_id);
                    textField_member2_id.setBounds(80, 625, 165, 30);
    
                    //---- label35 ----
                    label35.setText(bundle.getString("AddTeamFrame.label35.text_2"));
                    panel1.add(label35);
                    label35.setBounds(300, 630, 70, 17);
                    panel1.add(textField_member2_idCard);
                    textField_member2_idCard.setBounds(375, 620, 165, 30);
    
                    //---- label36 ----
                    label36.setText(bundle.getString("AddTeamFrame.label36.text_2"));
                    panel1.add(label36);
                    label36.setBounds(630, 630, 35, 17);
                    panel1.add(textField_member2_name);
                    textField_member2_name.setBounds(675, 625, 165, 30);
    
                    //---- label37 ----
                    label37.setText(bundle.getString("AddTeamFrame.label37.text_2"));
                    panel1.add(label37);
                    label37.setBounds(30, 675, 35, 17);
                    panel1.add(textField_member2_phone);
                    textField_member2_phone.setBounds(80, 670, 165, 30);
    
                    //---- label38 ----
                    label38.setText(bundle.getString("AddTeamFrame.label38.text_2"));
                    panel1.add(label38);
                    label38.setBounds(325, 675, 35, 17);
                    panel1.add(textField_member2_email);
                    textField_member2_email.setBounds(375, 670, 165, 30);
    
                    //---- label39 ----
                    label39.setText(bundle.getString("AddTeamFrame.label39.text_2"));
                    panel1.add(label39);
                    label39.setBounds(625, 675, 35, 17);
                    panel1.add(textField_member2_school);
                    textField_member2_school.setBounds(675, 670, 165, 30);
    
                    //---- label40 ----
                    label40.setText(bundle.getString("AddTeamFrame.label40.text_2"));
                    panel1.add(label40);
                    label40.setBounds(30, 720, 35, 17);
                    panel1.add(textField_member2_department);
                    textField_member2_department.setBounds(80, 715, 165, 30);
    
                    //---- label41 ----
                    label41.setText(bundle.getString("AddTeamFrame.label41.text_2"));
                    panel1.add(label41);
                    label41.setBounds(325, 720, 35, 17);
                    panel1.add(textField_member2_class);
                    textField_member2_class.setBounds(375, 715, 165, 30);
    
                    {
                        // compute preferred size
                        Dimension preferredSize = new Dimension();
                        for(int i = 0; i < panel1.getComponentCount(); i++) {
                            Rectangle bounds = panel1.getComponent(i).getBounds();
                            preferredSize.width = Math.max(bounds.x + bounds.width, preferredSize.width);
                            preferredSize.height = Math.max(bounds.y + bounds.height, preferredSize.height);
                        }
                        Insets insets = panel1.getInsets();
                        preferredSize.width += insets.right;
                        preferredSize.height += insets.bottom;
                        panel1.setMinimumSize(preferredSize);
                        panel1.setPreferredSize(preferredSize);
                    }
                }
                scrollPane1.setViewportView(panel1);
            }
            contentPane.add(scrollPane1, BorderLayout.CENTER);
    
            //======== toolBar1 ========
            {
    
                //---- button1 ----
                button1.setText(bundle.getString("AddTeamFrame.button1.text"));
                button1.addActionListener(e -> button1ActionPerformed(e));
                toolBar1.add(button1);
            }
            contentPane.add(toolBar1, BorderLayout.NORTH);
            pack();
            setLocationRelativeTo(getOwner());
            // JFormDesigner - End of component initialization  //GEN-END:initComponents
        }
    
        // JFormDesigner - Variables declaration - DO NOT MODIFY  //GEN-BEGIN:variables
        private JScrollPane scrollPane1;
        private JPanel panel1;
        private JLabel label1;
        private JTextField textField_team_id;
        private JLabel label2;
        private JTextField textField_team_code;
        private JTextField textField_team_name;
        private JLabel label4;
        private JLabel label5;
        private JTextField textField_team_school;
        private JLabel label7;
        private JLabel label8;
        private JLabel label9;
        private JComboBox<String> comboBox_team_group;
        private JLabel label3;
        private JLabel label6;
        private JTextField textField_teacher_id;
        private JLabel label10;
        private JTextField textField_teacher_code;
        private JLabel label11;
        private JTextField textField_teacher_name;
        private JLabel label12;
        private JLabel label13;
        private JLabel label14;
        private JLabel label15;
        private JLabel label16;
        private JTextField textField_teacher_phone;
        private JTextField textField_teacher_email;
        private JTextField textField_teacher_title;
        private JTextField textField_teacher_school;
        private JTextField textField_teacher_department;
        private JLabel label18;
        private JTextField textField_captain_id;
        private JLabel label19;
        private JTextField textField_captain_idCard;
        private JLabel label20;
        private JTextField textField_captain_name;
        private JLabel label21;
        private JTextField textField_captain_phone;
        private JLabel label22;
        private JTextField textField_captain_email;
        private JLabel label23;
        private JTextField textField_captain_school;
        private JLabel label24;
        private JTextField textField_captain_department;
        private JLabel label25;
        private JTextField textField_captain_class;
        private JLabel label26;
        private JTextField textField_member1_id;
        private JLabel label27;
        private JTextField textField_member1_idCard;
        private JLabel label28;
        private JTextField textField_member1_name;
        private JLabel label29;
        private JTextField textField_member1_phone;
        private JLabel label30;
        private JTextField textField_member1_email;
        private JLabel label31;
        private JTextField textField_member1_school;
        private JLabel label32;
        private JTextField textField_member1_department;
        private JLabel label33;
        private JTextField textField_member1_class;
        private JLabel label34;
        private JTextField textField_member2_id;
        private JLabel label35;
        private JTextField textField_member2_idCard;
        private JLabel label36;
        private JTextField textField_member2_name;
        private JLabel label37;
        private JTextField textField_member2_phone;
        private JLabel label38;
        private JTextField textField_member2_email;
        private JLabel label39;
        private JTextField textField_member2_school;
        private JLabel label40;
        private JTextField textField_member2_department;
        private JLabel label41;
        private JTextField textField_member2_class;
        private JToolBar toolBar1;
        private JButton button1;
        // JFormDesigner - End of variables declaration  //GEN-END:variables
    }
    
    
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 7
    • 8
    • 9
    • 10
    • 11
    • 12
    • 13
    • 14
    • 15
    • 16
    • 17
    • 18
    • 19
    • 20
    • 21
    • 22
    • 23
    • 24
    • 25
    • 26
    • 27
    • 28
    • 29
    • 30
    • 31
    • 32
    • 33
    • 34
    • 35
    • 36
    • 37
    • 38
    • 39
    • 40
    • 41
    • 42
    • 43
    • 44
    • 45
    • 46
    • 47
    • 48
    • 49
    • 50
    • 51
    • 52
    • 53
    • 54
    • 55
    • 56
    • 57
    • 58
    • 59
    • 60
    • 61
    • 62
    • 63
    • 64
    • 65
    • 66
    • 67
    • 68
    • 69
    • 70
    • 71
    • 72
    • 73
    • 74
    • 75
    • 76
    • 77
    • 78
    • 79
    • 80
    • 81
    • 82
    • 83
    • 84
    • 85
    • 86
    • 87
    • 88
    • 89
    • 90
    • 91
    • 92
    • 93
    • 94
    • 95
    • 96
    • 97
    • 98
    • 99
    • 100
    • 101
    • 102
    • 103
    • 104
    • 105
    • 106
    • 107
    • 108
    • 109
    • 110
    • 111
    • 112
    • 113
    • 114
    • 115
    • 116
    • 117
    • 118
    • 119
    • 120
    • 121
    • 122
    • 123
    • 124
    • 125
    • 126
    • 127
    • 128
    • 129
    • 130
    • 131
    • 132
    • 133
    • 134
    • 135
    • 136
    • 137
    • 138
    • 139
    • 140
    • 141
    • 142
    • 143
    • 144
    • 145
    • 146
    • 147
    • 148
    • 149
    • 150
    • 151
    • 152
    • 153
    • 154
    • 155
    • 156
    • 157
    • 158
    • 159
    • 160
    • 161
    • 162
    • 163
    • 164
    • 165
    • 166
    • 167
    • 168
    • 169
    • 170
    • 171
    • 172
    • 173
    • 174
    • 175
    • 176
    • 177
    • 178
    • 179
    • 180
    • 181
    • 182
    • 183
    • 184
    • 185
    • 186
    • 187
    • 188
    • 189
    • 190
    • 191
    • 192
    • 193
    • 194
    • 195
    • 196
    • 197
    • 198
    • 199
    • 200
    • 201
    • 202
    • 203
    • 204
    • 205
    • 206
    • 207
    • 208
    • 209
    • 210
    • 211
    • 212
    • 213
    • 214
    • 215
    • 216
    • 217
    • 218
    • 219
    • 220
    • 221
    • 222
    • 223
    • 224
    • 225
    • 226
    • 227
    • 228
    • 229
    • 230
    • 231
    • 232
    • 233
    • 234
    • 235
    • 236
    • 237
    • 238
    • 239
    • 240
    • 241
    • 242
    • 243
    • 244
    • 245
    • 246
    • 247
    • 248
    • 249
    • 250
    • 251
    • 252
    • 253
    • 254
    • 255
    • 256
    • 257
    • 258
    • 259
    • 260
    • 261
    • 262
    • 263
    • 264
    • 265
    • 266
    • 267
    • 268
    • 269
    • 270
    • 271
    • 272
    • 273
    • 274
    • 275
    • 276
    • 277
    • 278
    • 279
    • 280
    • 281
    • 282
    • 283
    • 284
    • 285
    • 286
    • 287
    • 288
    • 289
    • 290
    • 291
    • 292
    • 293
    • 294
    • 295
    • 296
    • 297
    • 298
    • 299
    • 300
    • 301
    • 302
    • 303
    • 304
    • 305
    • 306
    • 307
    • 308
    • 309
    • 310
    • 311
    • 312
    • 313
    • 314
    • 315
    • 316
    • 317
    • 318
    • 319
    • 320
    • 321
    • 322
    • 323
    • 324
    • 325
    • 326
    • 327
    • 328
    • 329
    • 330
    • 331
    • 332
    • 333
    • 334
    • 335
    • 336
    • 337
    • 338
    • 339
    • 340
    • 341
    • 342
    • 343
    • 344
    • 345
    • 346
    • 347
    • 348
    • 349
    • 350
    • 351
    • 352
    • 353
    • 354
    • 355
    • 356
    • 357
    • 358
    • 359
    • 360
    • 361
    • 362
    • 363
    • 364
    • 365
    • 366
    • 367
    • 368
    • 369
    • 370
    • 371
    • 372
    • 373
    • 374
    • 375
    • 376
    • 377
    • 378
    • 379
    • 380
    • 381
    • 382
    • 383
    • 384
    • 385
    • 386
    • 387
    • 388
    • 389
    • 390
    • 391
    • 392
    • 393
    • 394
    • 395
    • 396
    • 397
    • 398
    • 399
    • 400
    • 401
    • 402
    • 403
    • 404
    • 405
    • 406
    • 407
    • 408
    • 409
    • 410
    • 411
    • 412
    • 413
    • 414
    • 415
    • 416
    • 417
    • 418
    • 419
    • 420
    • 421
    • 422
    • 423
    • 424
    • 425
    • 426
    • 427
    • 428
    • 429
    • 430
    • 431
    • 432
    • 433
    • 434
    • 435
    • 436
    • 437
    • 438
    • 439
    • 440
    • 441
    • 442
    • 443
    • 444
    • 445
    • 446
    • 447
    • 448
    • 449
    • 450
    • 451
    • 452
    • 453
    • 454
    • 455
    • 456
    • 457
    • 458
    • 459
    • 460
    • 461
    • 462
    • 463
    • 464
    • 465
    • 466
    • 467
    • 468
    • 469
    • 470
    • 471
    • 472
    • 473
    • 474
    • 475
    • 476
    • 477
    • 478
    • 479
    • 480
    • 481
    • 482
    • 483
    • 484
    • 485
    • 486
    • 487
    • 488
    • 489
    • 490
    • 491
    • 492
    • 493
    • 494
    • 495
    • 496
    • 497
    • 498
    • 499
    • 500
    • 501
    • 502
    • 503
    • 504
    • 505
    • 506
    • 507
    • 508
    • 509
    • 510
    • 511
    • 512
    • 513
    • 514
    • 515
    • 516
    • 517
    • 518
    • 519
    • 520
    • 521
    • 522
    • 523
    • 524
    • 525
    • 526
    • 527
    • 528
    • 529
    • 530
    • 531
    • 532
    • 533
    • 534
    • 535
    • 536
    • 537
    • 538
    • 539
    • 540
    • 541
    • 542
    • 543
    • 544
    • 545
    • 546
    • 547
    • 548
    • 549
    • 550
    • 551
    • 552
    • 553
    • 554
    • 555
    • 556
    • 557
    • 558
    • 559
    • 560
    • 561
    • 562
    • 563
    • 564
    • 565
    • 566
    • 567
    • 568
    • 569
    • 570
    • 571
    • 572
    • 573
    • 574
    • 575
    • 576
    • 577
    • 578
    • 579
    • 580
    • 581
    • 582
    • 583
    • 584
    • 585
    • 586
    • 587
    • 588
    • 589
    • 590
    • 591
    • 592
    • 593
    • 594
    • 595
    • 596
    • 597
    • 598
    • 599
    • 600
    • 601
    • 602
    • 603
    • 604
    • 605
    • 606
    • 607
    • 608
    • 609
    • 610
    • 611
    • 612
    • 613
    • 614
    • 615
    • 616
    • 617
    • 618
    • 619
    • 620
    • 621
    • 622
    • 623
    • 624
    • 625
    • 626
    • 627
    • 628
    • 629
    • 630
    • 631
    • 632
    • 633
    • 634
    • 635
    • 636
    • 637
    • 638
    • 639
    • 640
    • 641
    • 642
    • 643
    • 644
    • 645
    • 646
    • 647
    • 648
    • 649
    • 650
    • 651
    • 652
    • 653

    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述

  • 相关阅读:
    2.Seq2Seq注意力机制
    C++学习--泛型编程---模版
    linux paddle For C++环境搭建
    链表、栈、队列
    ArrayList与顺序表
    274. H 指数
    评价——模糊综合评价
    QoS服务质量六拥塞管理原理
    RTOS 中 Task 之间资源共享示例
    Shell-AI:基于LLM实现自然语言理解的CLI工具
  • 原文地址:https://blog.csdn.net/newlw/article/details/126084243