mainframe.java
字号:
WelcomePanel.setBackground(maincolor);
WelcomePanel.setBorder(titledBorder1);
WelcomePanel.setLayout(gridLayout1);
jLabel1.setForeground(new Color(160, 0, 0));
jLabel1.setText("欢迎:");
jLabel1.setBounds(new Rectangle(13, 56, 53, 15));
UserText.setBackground(maincolor);
UserText.setBounds(new Rectangle(47, 53, 62, 19));
JbtnZC.setBackground(maincolor);
JbtnZC.setBorder(null);
JbtnZC.addActionListener(new MainFrame_JbtnZC_actionAdapter(this));
JbtnZG.setBackground(maincolor);
JbtnZG.setBorder(null);
JbtnZG.addActionListener(new MainFrame_JbtnZG_actionAdapter(this));
JbtnLB.setBackground(maincolor);
JbtnLB.setBorder(null);
JbtnLB.addActionListener(new MainFrame_JbtnLB_actionAdapter(this));
JbtnJY.setBackground(maincolor);
JbtnJY.setBorder(null);
JbtnJY.addActionListener(new MainFrame_JbtnJY_actionAdapter(this));
JbtnEXIT.setBackground(maincolor);
JbtnEXIT.setBorder(null);
JbtnEXIT.addActionListener(new MainFrame_JbtnEXIT_actionAdapter(this));
jLabel2.setForeground(Color.blue);
jLabel2.setText("登陆日期:");
jLabel2.setBounds(new Rectangle(123, 56, 71, 15));
ZCMenu.setBackground(menucolor);
ZCMenu.setActionCommand("固定资产管理");
ZCMenu.setText("固定资产管理");
ZCinsertMnu.setText("增加");
ZCinsertMnu.addActionListener(new MainFrame_ZCinsertMnu_actionAdapter(this));
ZCchangeMnu.setText("修改");
ZCchangeMnu.addActionListener(new MainFrame_ZCchangeMnu_actionAdapter(this));
ZCdelMnu.setText("删除");
ZCdelMnu.addActionListener(new MainFrame_ZCdelMnu_actionAdapter(this));
ZGMenu.setBackground(menucolor);
ZGMenu.setText("职工管理");
LBMenu.setBackground(menucolor);
LBMenu.setText("资产类别管理");
JYGHMenu.setBackground(menucolor);
JYGHMenu.setText("借用归还管理");
SelectMenu.setBackground(menucolor);
SelectMenu.setActionCommand("查询/浏览");
SelectMenu.setText("查询/浏览");
UserAdminMenu.setBackground(menucolor);
UserAdminMenu.setText("用户管理");
AboutMenu.setBackground(menucolor);
AboutMenu.setText("关于");
AboutsystemMnu.setText("关于本系统");
AboutsystemMnu.addActionListener(new MainFrame_AboutsystemMnu_actionAdapter(this));
HelpMenu.setText("帮助");
HelpMenu.addActionListener(new MainFrame_HelpMenu_actionAdapter(this));
ZGinsertMnu.setText("增加");
ZGinsertMnu.addActionListener(new MainFrame_ZGinsertMnu_actionAdapter(this));
ZGdelMnu.setText("删除");
ZGdelMnu.addActionListener(new MainFrame_ZGdelMnu_actionAdapter(this));
ZGchangeMnu.setText("修改");
ZGchangeMnu.addActionListener(new MainFrame_ZGchangeMnu_actionAdapter(this));
LBinsertMnu.setText("增加");
LBinsertMnu.addActionListener(new MainFrame_LBinsertMnu_actionAdapter(this));
LBdelMnu.setText("删除");
LBdelMnu.addActionListener(new MainFrame_LBdelMnu_actionAdapter(this));
LBchangeMnu.setText("修改");
LBchangeMnu.addActionListener(new MainFrame_LBchangeMnu_actionAdapter(this));
JYMnu.setText("借用");
JYMnu.addActionListener(new MainFrame_JYMnu_actionAdapter(this));
GHMnu.setText("归还");
GHMnu.addActionListener(new MainFrame_GHMnu_actionAdapter(this));
ZCSelectMenu.setText("固定资产查询");
ZCSelectMenu.addActionListener(new MainFrame_ZCSelectMenu_actionAdapter(this));
ZGSelectMenu.setText("职工信息查询");
ZGSelectMenu.addActionListener(new MainFrame_ZGSelectMenu_actionAdapter(this));
UserpasswordchangeMnu.setText("修改密码");
UserpasswordchangeMnu.addActionListener(new
MainFrame_UserpasswordchangeMnu_actionAdapter(this));
NewuserMnu.setText("增加新用户");
NewuserMnu.addActionListener(new MainFrame_NewuserMnu_actionAdapter(this));
LBSelectMenu.setText("资产类别查询");
LBSelectMenu.addActionListener(new MainFrame_LBSelectMenu_actionAdapter(this));
JYGHSelectMenu.setText("借用归还查询");
JYGHSelectMenu.addActionListener(new MainFrame_JYGHSelectMenu_actionAdapter(this));
Menu.setBackground(menucolor);
DateText.setBackground(maincolor);
DateText.setBorder(null);
DateText.setBounds(new Rectangle(183, 52, 85, 21));
Calendar obj = Calendar.getInstance(); //import java.util.Calendar; 日历字段之间的转换
DateText.setText(new String("" + obj.get(Calendar.YEAR) + "-" +
(obj.get(Calendar.MONTH) + 1) + "-" +
obj.get(Calendar.DAY_OF_MONTH))); //获得登陆日期
JspanelFortable.getViewport().setBackground(maincolor);
ZCEditPanel.setBackground( (maincolor));
ZCEditPanel.setBorder(titledBorder1);
ZCEditPanel.setLayout(null);
jLabel3.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel3.setText("录入日期:");
jLabel3.setBounds(new Rectangle(389, 79, 66, 29));
jLabel4.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel4.setText("大 类:");
jLabel4.setBounds(new Rectangle(389, 41, 66, 29));
jLabel5.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel5.setText("样 式:");
jLabel5.setBounds(new Rectangle(12, 79, 66, 29));
jLabel6.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel6.setText("资产编号:");
jLabel6.setBounds(new Rectangle(12, 41, 66, 29));
jLabel7.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel7.setText("价 格:");
jLabel7.setBounds(new Rectangle(196, 83, 62, 25));
jLabel8.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel8.setText("备 注:");
jLabel8.setBounds(new Rectangle(196, 123, 66, 29));
jLabel9.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel9.setText("经 办 人:");
jLabel9.setBounds(new Rectangle(12, 123, 66, 29));
jLabel10.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel10.setText("资产名称:");
jLabel10.setBounds(new Rectangle(196, 41, 66, 29));
JtextZCNNum.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZCNNum.setMinimumSize(new Dimension(2, 20));
JtextZCNNum.setPreferredSize(new Dimension(2, 20));
JtextZCNNum.setBounds(new Rectangle(72, 43, 110, 24));
JtextZCName.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZCName.setMinimumSize(new Dimension(2, 20));
JtextZCName.setPreferredSize(new Dimension(2, 20));
JtextZCName.setBounds(new Rectangle(259, 43, 110, 24));
JtextZCprice.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZCprice.setMinimumSize(new Dimension(2, 20));
JtextZCprice.setPreferredSize(new Dimension(2, 20));
JtextZCprice.setBounds(new Rectangle(260, 83, 110, 24));
JtextZCuser.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZCuser.setMinimumSize(new Dimension(2, 20));
JtextZCuser.setPreferredSize(new Dimension(2, 20));
JtextZCuser.setBounds(new Rectangle(72, 126, 110, 24));
JtextZCbz.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZCbz.setMinimumSize(new Dimension(2, 20));
JtextZCbz.setPreferredSize(new Dimension(2, 20));
JtextZCbz.setBounds(new Rectangle(260, 126, 110, 24));
JtextZCdate.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZCdate.setMinimumSize(new Dimension(2, 20));
JtextZCdate.setPreferredSize(new Dimension(2, 20));
JtextZCdate.setBounds(new Rectangle(451, 83, 110, 24));
JtextZCcss.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZCcss.setMinimumSize(new Dimension(2, 20));
JtextZCcss.setPreferredSize(new Dimension(2, 20));
JtextZCcss.setBounds(new Rectangle(72, 83, 110, 24));
Jcboxmanclass.setBackground(new Color(255, 249, 236));
Jcboxmanclass.setBorder(BorderFactory.createLineBorder(Color.black));
Jcboxmanclass.setBounds(new Rectangle(452, 43, 111, 24));
//资产管理按钮自定义开始---------------------------------------------------------------
JbtnZCinsert.setBackground(maincolor);
JbtnZCinsert.setBorder(null);
JbtnZCinsert.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZCinsert.setIcon(new ImageIcon(getClass().getResource(
"img/btninsert.gif")));
JbtnZCinsert.addActionListener(new MainFrame_JbtnZCinsert_actionAdapter(this));
JbtnZCselect.setBackground(maincolor);
JbtnZCselect.setBorder(null);
JbtnZCselect.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZCselect.setIcon(new ImageIcon(getClass().getResource(
"img/btnselect.gif")));
JbtnZCselect.addActionListener(new MainFrame_JbtnZCselect_actionAdapter(this));
JbtnZCchange.setBackground(maincolor);
JbtnZCchange.setBorder(null);
JbtnZCchange.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZCchange.setIcon(new ImageIcon(getClass().getResource(
"img/btnchange.gif")));
JbtnZCchange.addActionListener(new MainFrame_JbtnZCchange_actionAdapter(this));
JbtnZCdel.setBackground(maincolor);
JbtnZCdel.setBorder(null);
JbtnZCdel.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZCdel.setIcon(new ImageIcon(getClass().getResource("img/btndel.gif")));
JbtnZCdel.addActionListener(new MainFrame_JbtnZCdel_actionAdapter(this));
//资产管理按钮美化结束---------------------------------------------------------------
CboxforZCselect.setBackground(maincolor);
CboxforZCselect.setToolTipText("");
CboxforZCselect.addItem("--根据资产名称");
CboxforZCselect.addItem("--根据录入日期");
CboxforZCselect.addItem("--根据资产状态");
ZCeditbtnpanel.setBackground(maincolor);
ZCeditbtnpanel.setBounds(new Rectangle(171, 160, 600, 40)); //资产管理按钮容器大小及位置
ZCeditbtnpanel.setLayout(flowLayout3);
ZGEditPanel.setBackground(maincolor);
ZGEditPanel.setBorder(titledBorder1);
ZGEditPanel.setLayout(null);
ZGeditbtnpanel.setBackground(maincolor);
ZGeditbtnpanel.setBounds(new Rectangle(171, 160, 600, 40)); //职工管理按钮容器大小及位置
ZGeditbtnpanel.setLayout(flowLayout2);
//-------------------------------职工管理按钮美化开始--------------------------------
JbtnZGinsert.setBackground(maincolor);
JbtnZGinsert.setBorder(null);
JbtnZGinsert.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZGinsert.setIcon(new ImageIcon(getClass().getResource(
"img/btninsert.gif")));
JbtnZGinsert.addActionListener(new MainFrame_JbtnZGinsert_actionAdapter(this));
JbtnZGchange.setBackground(maincolor);
JbtnZGchange.setBorder(null);
JbtnZGchange.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZGchange.setIcon(new ImageIcon(getClass().getResource(
"img/btnchange.gif")));
JbtnZGchange.addActionListener(new MainFrame_JbtnZGchange_actionAdapter(this));
JbtnZGdel.setBackground(maincolor);
JbtnZGdel.setBorder(null);
JbtnZGdel.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZGdel.setIcon(new ImageIcon(getClass().getResource("img/btndel.gif")));
JbtnZGdel.addActionListener(new MainFrame_JbtnZGdel_actionAdapter(this));
JbtnZGselect.setBackground(maincolor);
JbtnZGselect.setBorder(null);
JbtnZGselect.setHorizontalTextPosition(SwingConstants.CENTER);
JbtnZGselect.setIcon(new ImageIcon(getClass().getResource(
"img/btnselect.gif")));
JbtnZGselect.addActionListener(new MainFrame_JbtnZGselect_actionAdapter(this));
//------------------------------职工管理按钮美化结束-----------------------------------
CboxforZGselect.setBackground(maincolor);
CboxforZGselect.setToolTipText("");
CboxforZGselect.addItem("--根据职工姓名");
CboxforZGselect.addItem("--根据职工职位");
jLabel11.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel11.setText("职 务:");
jLabel11.setBounds(new Rectangle(184, 96, 74, 28));
jLabel12.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel12.setText("职工编号:");
jLabel12.setBounds(new Rectangle(184, 44, 74, 28));
jLabel13.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel13.setText("备 注:");
jLabel13.setBounds(new Rectangle(433, 96, 74, 28));
jLabel14.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel14.setText("职工姓名:");
jLabel14.setBounds(new Rectangle(433, 44, 74, 28));
JtextZGnum.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZGnum.setBounds(new Rectangle(258, 48, 110, 24));
JtextZGwork.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZGwork.setBounds(new Rectangle(258, 100, 110, 24));
JtextZGname.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZGname.setBounds(new Rectangle(508, 48, 110, 24));
JtextZGbz.setBorder(BorderFactory.createLineBorder(Color.black));
JtextZGbz.setBounds(new Rectangle(508, 100, 110, 24));
LBEditPanel.setBackground(maincolor);
LBEditPanel.setBorder(titledBorder1);
LBEditPanel.setLayout(null);
MainLBid.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
MainLBid.setBorder(BorderFactory.createLineBorder(Color.black));
MainLBid.setBounds(new Rectangle(245, 45, 110, 24));
jLabel15.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel15.setText("小类名称:");
jLabel15.setBounds(new Rectangle(428, 96, 74, 28));
MainLBname.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
MainLBname.setBorder(BorderFactory.createLineBorder(Color.black));
MainLBname.setBounds(new Rectangle(489, 48, 110, 24));
SonLBid.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
SonLBid.setBorder(BorderFactory.createLineBorder(Color.black));
SonLBid.setBounds(new Rectangle(245, 96, 110, 24));
jLabel16.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel16.setText("大类编号:");
jLabel16.setBounds(new Rectangle(179, 44, 74, 28));
jLabel17.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel17.setText("大类名称:");
jLabel17.setBounds(new Rectangle(428, 44, 74, 28));
LBeditbtnpanel.setBackground(maincolor);
LBeditbtnpanel.setBounds(new Rectangle(171, 160, 600, 40)); //类别按钮容器大小及位置
LBeditbtnpanel.setLayout(flowLayout4);
//资产类别按钮美化开始-----------------------------------------------------------------
JbtnLBinsert.setBackground(maincolor);
JbtnLBinsert.setBorder(null);
JbtnLBinsert.setIcon(new ImageIcon(getClass().getResource(
"img/btninsert.gif")));
JbtnLBinsert.addActionListener(new MainFrame_JbtnLBinsert_actionAdapter(this));
JbtnLBdel.setBackground(maincolor);
JbtnLBdel.setBorder(null);
JbtnLBdel.setIcon(new ImageIcon(getClass().getResource("img/btndel.gif")));
JbtnLBdel.addActionListener(new MainFrame_JbtnLBdel_actionAdapter(this));
JbtnLBchange.setBackground(maincolor);
JbtnLBchange.setBorder(null);
JbtnLBchange.setIcon(new ImageIcon(getClass().getResource(
"img/btnchange.gif")));
JbtnLBchange.addActionListener(new MainFrame_JbtnLBchange_actionAdapter(this));
JbtnLBselect.setBackground(maincolor);
JbtnLBselect.setBorder(null);
JbtnLBselect.setIcon(new ImageIcon(getClass().getResource(
"img/btnselect.gif")));
JbtnLBselect.addActionListener(new MainFrame_JbtnLBselect_actionAdapter(this));
//资产类别按钮美化结束-----------------------------------------------------------------
CboxforLBselect.setBackground(maincolor);
CboxforLBselect.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
CboxforLBselect.addItem("--根据大类编号");
CboxforLBselect.addItem("--根据小类编号");
CboxforLBselect.addItem("--根据大类名称");
CboxforLBselect.addItem("--根据小类名称");
jLabel18.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel18.setText("小类编号:");
jLabel18.setBounds(new Rectangle(179, 96, 74, 28));
SonLBname.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
SonLBname.setBorder(BorderFactory.createLineBorder(Color.black));
SonLBname.setBounds(new Rectangle(490, 96, 110, 24));
JYGHEditPanel.setBackground(maincolor);
JYGHEditPanel.setBorder(titledBorder1);
JYGHEditPanel.setLayout(null);
jLabel19.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel19.setText("借用日期:");
jLabel19.setBounds(new Rectangle(399, 49, 73, 16));
jLabel20.setFont(new java.awt.Font("Dialog", Font.PLAIN, 12));
jLabel20.setText("资产编号:");
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -