Java固定资产管理系统源代码.docx

上传人:b****5 文档编号:4390511 上传时间:2022-12-01 格式:DOCX 页数:27 大小:19.75KB
下载 相关 举报
Java固定资产管理系统源代码.docx_第1页
第1页 / 共27页
Java固定资产管理系统源代码.docx_第2页
第2页 / 共27页
Java固定资产管理系统源代码.docx_第3页
第3页 / 共27页
Java固定资产管理系统源代码.docx_第4页
第4页 / 共27页
Java固定资产管理系统源代码.docx_第5页
第5页 / 共27页
点击查看更多>>
下载资源
资源描述

Java固定资产管理系统源代码.docx

《Java固定资产管理系统源代码.docx》由会员分享,可在线阅读,更多相关《Java固定资产管理系统源代码.docx(27页珍藏版)》请在冰豆网上搜索。

Java固定资产管理系统源代码.docx

Java固定资产管理系统源代码

;

importpublicclassuser_landextendsJFrameimplementsActionListener{

staticConnectionconn=null;

staticStatementstat=null;

staticResultSetrs=null;

staticStringurl="jdbc:

";

staticStringuser="sa";

staticStringpassword="";

JPanelp1,p2,p3,p4,p5;

JLabellbl1,lbl2,lbl3,lbl4;

JTextFieldtxt_name;

JPasswordFieldtxt_pwd;

JButtonbtn1,btn2,btn3;

static{

try{

("");

}catch(Exceptione){

"加载驱动失败");

();

}

}

publicuser_land(){

("固定资产及设备用户登录");

p1=newJPanel();

p2=newJPanel();

p3=newJPanel();

p4=newJPanel();

p5=newJPanel();

lbl1=newJLabel("欢迎登录");

lbl2=newJLabel("用户名:

");

lbl3=newJLabel("密码:

");

lbl4=newJLabel();

txt_name=newJTextField(10);

txt_pwd=newJPasswordField(10);

btn1=newJButton("登录");

btn2=newJButton("清空");

btn3=newJButton("退出");

(lbl1);

(lbl2);

(txt_name);

(lbl3);

(txt_pwd);

(btn1);

(btn2);

(btn3);

(lbl4);

(newGridLayout(5,1));

(p1);

(p2);

(p3);

(p4);

(p5);

(400,300,400,300);

(EXIT_ON_CLOSE);

(true);

quals("")==true)&&().equals("")==false))

("登录失败,用户名不能为空");

if(().equals("")==false)&&().equals("")==true))

("登录失败,密码不能为空");

if(().equals("")==true)&&().equals("")==true))

("登录失败,用户名/密码不能为空");

if(is_Property()){

newSys_interface().show();

}

elseif(().equals("")==false)&&().equals("")==false))

("登录失败,用户名/密码错误");

}

}

);

(this);

how();

}

}

);

(this);

(newActionListener(){

@Override

publicvoidactionPerformed(ActionEventarg0){

newuser_land().show();

}

});

newActionListener(){

publicvoidactionPerformed(ActionEvente){

newPass_word().show();

}

}

);

newActionListener(){

publicvoidactionPerformed(ActionEvente){

(0);

}

}

);

newActionListener(){

publicvoidactionPerformed(ActionEvente){

newloan_prop_manage().show();

}

}

);

newActionListener(){

publicvoidactionPerformed(ActionEvente){

newproperty_Info().show();

}

}

);

newActionListener(){

publicvoidactionPerformed(ActionEvente){

newprop_info_select().show();

}

}

);

newActionListener(){

publicvoidactionPerformed(ActionEvente){

newLoan_prop_select().show();

}

}

);

newActionListener(){

publicvoidactionPerformed(ActionEvente){

newback_prop_select().show();

}

}

);

newActionListener(){

publicvoidactionPerformed(ActionEvente){

newabout().show();

}

}

);

(200,200,500,400);

(EXIT_ON_CLOSE);

}

publicvoidactionPerformed(ActionEvente){

how();

}

}

;

importimportimport.*;

importimport.*;

importimportimportimportimportimportimportimportimportimport

publicclassloan_prop_manageextendsJFrameimplementsActionListener{

Vectordata=null;

DefaultTableModelmodel=null;

Connectionconn=null;

Statementstat=null;

ResultSetrs1=null;

JTableloan_prop=null;

JLabellabel;

JTextFieldtext;

JTextFieldtxt01,txt02,txt03,txt04,txt05,txt06;

JPanelp1=null,p2=null,p3=null,p4,p5,p6,p7,p8,p9,p10;

Choicec1=null,c2=null;

JLabellb1=null,lb2=null,lb3=null,lb4=null,lb5=null,lb6=null;

JButtonbtn_ok=null;

JButtonbtn_exit=null;

JButtonbtn_fresh=null;

JButtonbtn_save=null;

JButtonbtn_del=null;

VectorcolumnName=newVector();

publicloan_prop_manage(){

text=newJTextField();

("资产编号");

("资产名称");

("资产型号");

("借出时间");

("借出数量");

("借出人");

p1=newJPanel();

p2=newJPanel();

p3=newJPanel();

p4=newJPanel();

p5=newJPanel();

p6=newJPanel();

p7=newJPanel();

p8=newJPanel();

p9=newJPanel();

p10=newJPanel();

lb1=newJLabel("资产编号");

lb2=newJLabel("资产名称");

lb3=newJLabel("资产型号");

lb4=newJLabel("借出时间");

lb5=newJLabel("借出数量");

lb6=newJLabel("借出人");

txt01=newJTextField(8);

txt02=newJTextField(8);

txt03=newJTextField(8);

txt04=newJTextField(8);

txt05=newJTextField(8);

txt06=newJTextField(8);

c1=newChoice();

c2=newChoice();

text=newJTextField(5);

("资产编号");

("=");

btn_ok=newJButton("确定");

btn_exit=newJButton("退出");

btn_fresh=newJButton("刷新");

btn_save=newJButton("保存");

btn_del=newJButton("删除");

(newJLabel("查询字段"));

(c1);

(newJLabel("运算符"));

(c2);

(newJLabel("输入数据"));

(text);

(btn_ok);

(btn_exit);

("请操作"));

(lb1);

(txt01);

(lb2);

(txt02);

(lb3);

(txt03);

(lb4);

(txt04);

(lb5);

(txt05);

(lb6);

(txt06);

(btn_fresh);

(btn_save);

(btn_del);

(newGridLayout(3,2));

(p3);

(p4);

(p5);

(p6);

(p7);

(p8);

loan_prop=newJTable(),columnName);

model=newDefaultTableModel(getDate(),columnName);

(newJScrollPane(loan_prop));

(newGridLayout(4,1));

(p1);

(p9);

(p2);

(p10);

(400,300,500,400);

(EXIT_ON_CLOSE);

("资产借出管理");

(newActionListener(){

publicvoidactionPerformed(ActionEventarg0){

try{

("");

conn=("jdbc:

","sa","");

stat=();

Stringsql="insertintoloan_info(prop_name,prop_type,loan_time,loan_num)"+"values('"+()+"','"+()+"','"+()+"','"+()+"')";

(sql);

DefaultTableModelmod=newDefaultTableModel(getDate(),columnName);

(mod);

();

();

}catch(Exceptione){

}

try{

if(rs1!

=null){

();

}

if(stat!

=null){

();

}

if(conn!

=null){

();

}

}catch(Exceptione2){

"关闭失败");

();

}

}

});

newActionListener(){

publicvoidactionPerformed(ActionEvente){

DefaultTableModeldtb=newDefaultTableModel(selectDate(),columnName);

(dtb);

();

();

}

});

/*(newActionListener(){

publicvoidactionPerformed(ActionEventarg0){

}

});*/

(this);

(newActionListener(){

publicvoidactionPerformed(ActionEventarg0){

DefaultTableModelmod=newDefaultTableModel(getDate(),columnName);

(mod);

();

();

}

});

().addListSelectionListener(

newListSelectionListener(){

publicvoidvalueChanged(ListSelectionEvente){

(newActionListener(){

publicvoidactionPerformed(ActionEventarg0){

try{

intj=();

("");

conn=("jdbc:

","sa","");

stat=();

Stringsql1="deletefromloan_infowhereprop_id="+""+(j).get(0)+"";

(sql1);

}catch(Exceptionee){

}finally{

try{

if(rs1!

=null){

();

}

if(stat!

=null){

();

}

if(conn!

=null){

();

}

}

catch(Exceptione2){

"关闭失败");

();

}

}

DefaultTableModelmod=newDefaultTableModel(getDate(),columnName);

(mod);

();

();

}

});

}

});

().addListSelectionListener(

newListSelectionListener(){

publicvoidvalueChanged(ListSelectionEvente){

inti=();

(i).get(0).toString());

((String)(i).get

(1));

((String)(i).get

(2));

(i).get(3).toString());

(i).get(4).toString());

(i).get(5).toString());

}

});

}

publicVectorselectDate(){

data=newVector();

try{

("");

conn=("jdbc:

","sa","");

stat=();

intx=().trim());

how();

}

publicvoidactionPerformed(ActionEvente){

;

importclassLoan_prop_selectextendsJFrameimplementsActionListener{

Connectionconn=null;

Statementstat=null;

ResultSetrs=null;

JTabletable=null;

JLabellabel;

JTextFieldtext;

JButtonbtn_ok=null,btn_exit=null;

JPanelp1=null,p2=null;

VectorcolumnName=newVector();

publicLoan_prop_select(){

("资产借出查询");

("流水号");

("资产编号");

("借用人");

("借出数量");

("借出时间");

p1=newJPanel();

p2=newJPanel();

text=newJTextField();

text=newJTextField(5);

btn_ok=newJButton("查询");

btn_exit=newJButton("退出");

(newJLabel("资产编号"));

(text);

(btn_ok);

(btn_exit);

("数据查询"));

(this);

table=newJTable(),columnName);

(newBorderLayout());

(p1,;

(newJScrollPane(table),;

(400,300,500,400);

(EXIT_ON_CLOSE);

(newActionListener(){

@Override

publicvoidactionPerformed(ActionEventarg0){

DefaultTableModeldtm=newDefaultTableModel(selectDate(),columnName);

(dtm);

();

();

}

});

}

publicVectorselectDate(){

Vectordata=newVector();

try{

("");

conn=("jdbc:

","sa","");

stat=();

intx=().trim());

how();

}

publicvoidactionPerformed(ActionEvente){

;

importclassback_prop_selectextendsJFrameimplementsActionListener{

Vectordata=null;

DefaultTableModelmodel=null;

Connectionconn=null;

Statementstat=null;

ResultSetrs=null;

JPanelpa1,pa2;

JButtonbtn1,btn2;

JTabletab=null;

JTextFieldtex=null;

JTextFieldtxt1,txt2,txt3,txt4,txt5;

JLabellab1,lab2,lab3;

VectorcolumnName=newVector();

publicback_p

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 高中教育 > 数学

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1