




版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)
文檔簡介
1、 經(jīng)濟管理學院 程序設(shè)計訓練a(二)課程設(shè)計課程設(shè)計題目: 高等院??蒲泄芾硇畔⑾到y(tǒng) 專 業(yè) 班 級: 信管101班 學 生 姓 名: 張沛梅 學 號: 100201138 指 導 教 師: 李慶恒 王玉恒 陳軍霞 董紹輝 2013年 1 月 18 日1. 系統(tǒng)描述1.1背景某高等學校擬建立一套科研管理信息系統(tǒng),實現(xiàn)對科研工作的信息化管理,要求系統(tǒng)對數(shù)據(jù)的存儲完整,查詢迅速,操作方便。教職員工分屬于各個學院下的系或行政機關(guān),在學院的教職員工分屬于不同的系,在行政機關(guān)的教職員工分屬于不同的部門如教務(wù)處,人事處,財務(wù)處等。各級單位均有單位名稱,單位地址,電話等屬性。教職員工基本信息包括姓名,性別,
2、出生年月,政治面貌,籍貫,畢業(yè)院校,所學專業(yè),學歷,學位,研究方向,聯(lián)系電話等信息;教職員工的科研工作主要包括撰寫論文,著作和承擔課題的研究,發(fā)明創(chuàng)造等工作,其研究成果主要包括論文,著作,課題,專利四大類。撰寫的論文信息包括論文名稱,所有作者姓名,出版刊物名稱,刊號,時間,刊物級別(核心期刊,一般期刊,報紙雜志,會議論文),是否被三大索引收錄等信息。著作主要包括書名,出版社,出版時間,著作類別(專著、編著、教材、譯著),字數(shù),作者姓名及其分工等。課題包括三個環(huán)節(jié),立項,鑒定,獲獎。課題基本情況包括課題名稱,編號,承擔單位,合作單位,課題立項情況包括課題來源分為縱向(國家,省部,廳局,一般)橫向
3、(其他單位),課題性質(zhì)(自然科學,軟科學,社會科學等),還包括立項時間,完成時間,課題成員,經(jīng)費等;鑒定包括鑒定時間,鑒定級別(國家,省部,廳局,一般),人員,成果等級(國際先進,國際領(lǐng)先,國內(nèi)先進,國內(nèi)領(lǐng)先)等;獲獎包括獲獎時間,級別(國家,省部,廳局),等級(一等獎,二等獎,三等獎),人員等。專利包括專利號,名稱,專利類型(發(fā)明,實用新型,外觀設(shè)計等),授予時間,人員等。每位教職員工會參與多項課題,論文,著作和專利。每項科研也會有多人參加。教職員工的科研工作成果評價和他參與科研的數(shù)量和質(zhì)量都有關(guān)系。根據(jù)科研參與人數(shù)的不同和該教職員工的排名不同,他可以獲得相應(yīng)的科研分數(shù),所以科研的總體信息和
4、各人的對應(yīng)信息必須完整。最終提供的數(shù)據(jù)模式可以使用戶按照不同年份,人員,單位等各種口徑進行查詢及統(tǒng)計工作,要求信息完整,設(shè)計規(guī)范。1.2目的和意義目的是使教職員工科研管理工作更加的簡捷,管理更加先進。其意義是通過系統(tǒng)開發(fā)使學生更深入的理解相關(guān)編程知識,同時開發(fā)出有實際作用的系統(tǒng),用實踐帶動學習積極性。2. 程序功能介紹程序從登陸窗口進入,根據(jù)角色不同進入的主頁不同。當是用戶登錄時,進入到個人科研信息系統(tǒng)頁面,在這個頁面教職員工可以實現(xiàn)以下功能:(1) 查看個人的詳細信息;(2) 修改個人的密碼;(3) 可以進行參加論文,著作,課題,專利信息的錄入;(4) 可以查詢個人參加不同科研項目的基本信息
5、與得分。當是管理員登錄時,進入到管理員的主頁,可以實現(xiàn)以下功能: (1)可以查看管理員自己的詳細信息; (2)修改個人密碼; (3)可以查看全部教職員工的登錄密碼; (4)可以查看參加不同科研項目的詳細情況,進行錄入,刪除,更新科研信息的操作; (5)可以按時間段對不同項目進行時間檢索,查看某個時間段某個項目的具體信息; (6)對科研項目的評分規(guī)則進行修改。3. 系統(tǒng)實現(xiàn)3.1開發(fā)環(huán)境軟硬件本系統(tǒng)適用于微型機,內(nèi)存容量2g,應(yīng)配備的外部設(shè)備有鼠標、鍵盤、顯示器、主機等. 軟件環(huán)境microsoft visual studio 2010和sql server 2005.本系統(tǒng)的設(shè)計采用的是asp
6、.net語言,在windows 7操作系統(tǒng)下microsoft visual studio 2010和sql server 2005軟件環(huán)境下使用。3.2程序調(diào)試情況1、調(diào)試登陸窗口遇到的問題在寫登陸按鈕的單擊事件代碼是出現(xiàn)了錯誤,此登陸功能是:如果輸入的職工號是管理員,就倒轉(zhuǎn)到管理員的界面,如果輸入職工號是用戶,就跳轉(zhuǎn)到用戶界面。因為沒有寫對代碼,導致沒有跳轉(zhuǎn)正確。解決方案:if(eid1!=null) && (paw1!=null) &&(js1="管¨¹理¤¨ª員¡À"
7、;) session"currentvalue" = user.text; response.redirect("liuyidefault2.aspx"); if(eid1!=null) && (paw1!=null) &&(js1="用®?戶¡ì") session"currentvalue" = user.text; response.redirect("liuyidefault.aspx"); 2.調(diào)試按時間檢索參加各項項目的具
8、體情況出現(xiàn)的問題如上圖,我以論文時間檢索為例,時間檢索論文的詳細情況,需要調(diào)用數(shù)據(jù)庫的存儲過程。但是起初沒有調(diào)用,導致檢索不出結(jié)果。解決方案: mycommand.commandtext = "time_select_eplw" sqlparameter parinput = mycommand.parameters.add("time1", sqldbtype.datetime); parinput.direction = parameterdirection.input; parinput.value = convert.todatetime(dro
9、pdownlist1.text + "/" + dropdownlist2.text + "/" + dropdownlist3.text); sqlparameter parinput2 = mycommand.parameters.add("time2", sqldbtype.datetime); parinput2.direction = parameterdirection.input; parinput2.value = convert.todatetime(dropdownlist4.text + "/"
10、; + dropdownlist5.text + "/" + dropdownlist6.text);3.調(diào)試評分規(guī)則管理時出現(xiàn)的問題如上圖,以著作評分規(guī)則修改為例,要修改評分規(guī)則需要查詢出數(shù)據(jù)庫中原始的評分,但是在查詢單擊事件的代碼沒有寫對,執(zhí)行了很多次都沒有成功。解決方案:sqlconnection mycon = null; sqlcommand mycom = null; try string myconstr = "data source=s-pc;initial catalog=kyglsystem;user id=sa;password=sa&quo
11、t; mycon = new sqlconnection(myconstr); mycon.open(); string sql = "select zzgrade from zz_sum where zzlx='"+dropdownlistzzjb.text+"'" mycom = new sqlcommand(sql ,mycon); sqldatareader result = mycom.executereader(); if (result.read() textboxzzfz.text = result"zzgrad
12、e".tostring(); catch (exception oe) response.write("數(shù)ºy據(jù)y庫a操¨´作Á¡Â失º¡ì敗㨹" + oe); finally if (mycon != null) mycon.close(); 3.3 結(jié)論本系統(tǒng)是高等院校教職員工科研管理信息系統(tǒng),能夠簡單的處理個人科研信息,界面清晰,易于理解,操作簡單方便。用戶可以進入用戶界面查詢個人參加項目的情況,修改密碼,可以進行科研申報。管理員通過進
13、入管理界面查詢各個項目的具體情況,可以對參加項目的人員或其他信息進行更新,刪除等工作,管理參加人員。管理員還可以根據(jù)需要更改各項目的評分規(guī)則。但是還存在一些問題,不能做到按折線圖或餅圖的形式輸出,也不能按報表的形式輸出。完善方案如下:(1)應(yīng)該做到用折線圖或餅圖輸出各項目的情況; (2)應(yīng)該做到各個工能靈活使用。 4. 結(jié)束語通過做本次課程設(shè)計,我有很大的感受,也學到了很多的東西。首先,我明白了自身所處的位置,我掌握的知識還很有限,在課程設(shè)計過程遇到很多問題,常常需要花很多時間去解決一個問題,這是因為沒有充分掌握相關(guān)知識,這就需要我在課下多學習。如果畢業(yè)后想從事這方面的工作,課余時間還應(yīng)該多看
14、看有關(guān)的知識。另外,還應(yīng)該在課余多做一些類似的系統(tǒng),多接觸這種做系統(tǒng)的練習,讓自己對數(shù)據(jù)庫和編程這方面做到熟練,總結(jié)出經(jīng)驗,以便于在以后做系統(tǒng)時能處理好,出現(xiàn)類似的錯誤能盡快的解決。 其次,我明白了自己在做界面和編寫代碼時還是做得不夠好,還是經(jīng)常出現(xiàn)錯誤,在編程方面的能力也還是十分有限的,不能靈活掌握課本的知識。自己有不明白的問題時,應(yīng)該盡快的詢問老師或者參考其他資料。自己編寫代碼時考慮問題還欠缺全面性,不能做到令人很滿意。最后,我明白了開發(fā)一個系統(tǒng)不是一朝一夕的事情,雖然三個星期的時間不算太長,但是也有很多其他的同學做的很好。經(jīng)過這次訓練,自己要加油,下次能做得更好。 附錄:源代碼清單1.
15、登陸頁面using system;using system.data;using system.configuration;using system.collections;using system.web;using system.web.security;using system.web.ui;using system.web.ui.webcontrols;using system.web.ui.webcontrols.webparts;using system.web.ui.htmlcontrols;using system.data.sqlclient;public partial c
16、lass dl : system.web.ui.page protected void buttsure_click(object sender, eventargs e) string eid1 = null; string paw1 = null; string js1 = null; string sqlconn = "data source=s-pc;initial catalog=kyglsystem;user id=sa;password=sa" sqlconnection myconnection = new sqlconnection(sqlconn); m
17、yconnection.open(); string sqlsel="select eid,paw,js from dl where eid='"+user.text+"'and paw='"+paw.text+"'" sqlcommand mycommand = new sqlcommand(sqlsel,myconnection); sqldatareader result = mycommand.executereader(); if(result.read() eid1 = result&quo
18、t;eid".tostring(); paw1 = result"paw".tostring(); js1= result"js".tostring(); if(user.text=null)&&(paw.text=null)response.write("請?輸º?入¨?用®?戶¡ì名?和¨ª密¨¹碼?!ê?!ê?!ê?"); if(eid1!=user.text) &&(
19、paw1!=paw.text) response.write("<script language=javascript>if(confirm('用®?戶¡ì名?或¨°密¨¹碼?不?正y確¨¡¤!ê?!ê?!ê?')window.navigate('dl.aspx'); </script>"); if(eid1!=null) && (paw1!=null) &&
20、(js1="管¨¹理¤¨ª員¡À") session"currentvalue" = user.text; response.redirect("liuyidefault2.aspx"); if(eid1!=null) && (paw1!=null) &&(js1="用®?戶¡ì") session"currentvalue" = user.text; respon
21、se.redirect("liuyidefault.aspx"); myconnection.close(); protected void buttoncz_click(object sender, eventargs e) user.text = "" paw.text = "" 2. 管理員界面2.1 管理員人員基本信息using system;using system.data;using system.configuration;using system.collections;using system.web;using
22、system.web.security;using system.web.ui;using system.web.ui.webcontrols;using system.web.ui.webcontrols.webparts;using system.web.ui.htmlcontrols;using system.data.sqlclient;public partial class glyjbxinix : system.web.ui.page protected void page_load(object sender, eventargs e) string sqlconn = &qu
23、ot;data source=s-pc;initial catalog=kyglsystem;user id=sa;password=sa" sqlconnection myconnection = new sqlconnection(sqlconn); myconnection.open(); sqlcommand mycommand = new sqlcommand("select employee.*,section.sname,department.dname from employee,section,department where employee.eid=&
24、#39;" + session"currentvalue" + "' and section.sid= employee.sid and department.did=section.did", myconnection); sqldatareader myreader; myreader = mycommand.executereader(); if (myreader.read() label4.text = myreader"eid".tostring(); label2.text = myreader&quo
25、t;ename".tostring(); label6.text = myreader"esex".tostring(); label14.text = myreader"sname".tostring(); label8.text = myreader"ebri".tostring(); label20.text = myreader"esxzy".tostring(); label10.text = myreader"emm".tostring(); label12.text =
26、myreader"ejg".tostring(); label18.text = myreader"ebyxy".tostring(); label16.text = myreader"dname".tostring(); label22.text = myreader"exw".tostring(); label24.text = myreader"exl".tostring(); label26.text = myreader"eyjfx".tostring(); lab
27、el28.text = myreader"etel".tostring(); myreader.close(); myconnection.close(); 2.2管理員密碼修改using system;using system.data;using system.configuration;using system.collections;using system.web;using system.web.security;using system.web.ui;using system.web.ui.webcontrols;using system.web.ui.web
28、controls.webparts;using system.web.ui.htmlcontrols;using system.data.sqlclient;public partial class glymima1 : system.web.ui.page protected void page_load(object sender, eventargs e) protected void button1_click(object sender, eventargs e) sqlconnection mycon = null; sqlcommand mycom = null; sqldata
29、reader result=null; sqlcommand comm=null; string paw1=null; try string myconstr = "data source=s-pc;initial catalog=kyglsystem;user id=sa;password=sa" mycon = new sqlconnection(myconstr); mycon.open(); mycom = new sqlcommand(); mycom.connection = mycon; string oldmm = ysmm.text.trim(); str
30、ing newmm = xmm.text.trim(); string sqlsel="select paw from dl where eid='"+session"currentvalue"+"'" comm = new sqlcommand(sqlsel,mycon); result = comm.executereader(); if(result.read() paw1 = result"paw".tostring(); if (paw1 = ysmm.text) if (result !
31、= null) result.close(); /string strupdate = "update stu set stuname='李¤?芳¤?',xydm='02',zydm='0201' where stunum='091001'" string strupdate = "update dl set paw='0' where eid='1'" string sql = string.format(strupdate, newmm
32、, session"currentvalue"); mycom.commandtype = commandtype.text; mycom.commandtext = sql; mycom.executenonquery(); response.write("<script language=javascript>alert('數(shù)ºy據(jù)y庫a內(nèi)¨²容¨y修t改?成¨¦功|!ê?!ê?!ê?') </script>"); els
33、e if (result != null) result.close(); response.write("<script language=javascript>if(confirm('此ä?原-始º?密¨¹碼?與®?數(shù)ºy據(jù)y庫a中d的Ì?不?符¤?!ê?!ê?!ê?請?重?新?輸º?入¨?!ê?!ê?')window.navigate('glymima1.aspx'); </scr
34、ipt>"); catch (exception oe) response.write("數(shù)ºy據(jù)y庫a操¨´作Á¡Â失º¡ì敗㨹" + oe); finally if (mycon != null) mycon.close(); /try 結(jié)¨¢束º? protected void button2_click(object sender, eventargs e) response.redirect(&q
35、uot;liuyidefault2.aspx"); 3. 用戶密碼修改代碼(同管理員密碼修改的代碼)using system;using system.data;using system.configuration;using system.collections;using system.web;using system.web.security;using system.web.ui;using system.web.ui.webcontrols;using system.web.ui.webcontrols.webparts;using system.web.ui.htmlco
36、ntrols;using system.data.sqlclient;public partial class mima : system.web.ui.page protected void qd_click(object sender, eventargs e) /定義要使用的對象 sqlconnection mycon = null; sqlcommand mycom = null; try string myconstr = "data source=s-pc;initial catalog=kyglsystem;user id=sa;password=sa" my
37、con = new sqlconnection(myconstr); mycon.open(); mycom = new sqlcommand(); mycom.connection = mycon; string oldmm = ysmm.text.trim(); string newmm = xmm.text.trim(); /eid1 = "e000000022" /string strupdate = "update stu set stuname='李芳',xydm='02',zydm='0201' whe
38、re stunum='091001'" string strupdate = "update dl set paw='0' where eid='1'" string sql = string.format(strupdate, newmm, session"currentvalue"); mycom.commandtype = commandtype.text; mycom.commandtext = sql; mycom.executenonquery(); response.write(&q
39、uot;<script language=javascript>alert('數(shù)據(jù)庫內(nèi)容修改成功!') </script>"); /response.write("<script language=javascript>if(confirm('數(shù)據(jù)庫內(nèi)容修改成功')window.navigate('liuyidefault.aspx'); </script>"); catch (exception oe) response.write("數(shù)據(jù)庫操作失敗&quo
40、t; + oe); finally if (mycon != null) mycon.close(); protected void page_load(object sender, eventargs e) protected void qx_click(object sender, eventargs e) requiredfieldvalidator1.visible = false; requiredfieldvalidator2.visible = false; requiredfieldvalidator3.visible = false; comparevalidator1.vi
41、sible = false; xmm.text = "" zsr.text = "" ysmm.text = "" response.redirect("liuyidefault.aspx"); 4.論文信息錄入代碼using system;using system.collections.generic;using system.web;using system.web.ui;using system.web.ui.webcontrols;using system.data.sqlclient;using sys
42、tem.data;public partial class lwsb : system.web.ui.page protected void page_load(object sender, eventargs e) for (int i = 2000; i < 2014; i+) this.dropdownlist2.items.add(i.tostring(); for (int i = 1; i < 13; i+) this.dropdownlist3.items.add(i.tostring(); for (int i = 1; i <= 31; i+) this.d
43、ropdownlist4.items.add(i.tostring(); this.label2.visible = false; this.textbox8.visible = false; this.label7.visible = false; this.textbox13.visible = false; this.label3.visible = false; this.textbox9.visible = false; this.label8.visible = false; this.textbox14.visible = false; this.label4.visible =
44、 false; this.textbox10.visible = false; this.label9.visible = false; this.textbox15.visible = false; this.label5.visible = false; this.textbox11.visible = false; this.label10.visible = false; this.textbox16.visible = false; protected void dropdownlist1_selectedindexchanged(object sender, eventargs e
45、) if (dropdownlist1.selectedindex = 1) dfh1.text = "lw_ l1" if (dropdownlist1.selectedindex = 2) dfh1.text = "lw_l4" if (dropdownlist1.selectedindex = 3) dfh1.text = "lw_l2" if (dropdownlist1.selectedindex = 0) dfh1.text = "lw_l3" protected void button2_click(
46、object sender, eventargs e) string cbsj = dropdownlist2.text + "/" + dropdownlist3.text + "/" + dropdownlist4.text; string sqlconn = "data source=s-pc;initial catalog=kyglsystem;user id=sa;password=sa" sqlconnection conn = new sqlconnection(sqlconn); conn.open(); /sqlco
47、mmand comm0 = new sqlcommand("select * from kylw where lwbh='" + lwbh.text.trim() + "'",conn); /int j = comm0.executenonquery(); /if (j = 0) / string sfsl; if (radiobutton1.checked) sfsl = "是" else sfsl = "否" string strsql = "insert into lw(lwid,l
48、wname,lwpublic,lwlx,rank,kan_no,lwtime,lwrecord)values('0','1','2','3','4','5','6','7')" string str = string.format(strsql, textbox1.text.trim(), textbox2.text.trim(), textbox4.text.trim(), dropdownlist1.text,dfh1.text.trim(), text
49、box5.text.trim(), cbsj, sfsl); sqlcommand comm1 = new sqlcommand(str, conn); int n = convert.toint32(textbox6.text.trim(); string zzbh = new stringn - 1; string fgh = new stringn - 1; switch (n) case 1: zzbh = new string1 textbox7.text.trim() ; fgh = new string1 textbox12.text.trim() ; break; case 2
50、: zzbh = new string2 textbox7.text.trim(), textbox8.text.trim() ; fgh = new string2 textbox12.text.trim(), textbox13.text.trim() ; break; case 3: zzbh = new string3 textbox7.text.trim(), textbox8.text.trim(), textbox9.text.trim() ; fgh = new string3 textbox12.text.trim(), textbox13.text.trim(), text
51、box14.text.trim() ; break; case 4: zzbh = new string4 textbox7.text.trim(), textbox8.text.trim(), textbox9.text.trim(), textbox10.text.trim() ; fgh = new string4 textbox12.text.trim(), textbox13.text.trim(), textbox14.text.trim(), textbox15.text.trim() ; break; case 5: zzbh = new string5 textbox7.text.trim(), textbox8.text.trim(), textbox9.text.trim(), textbox10.text.trim(), textbox11.text.trim() ; fgh = new string5 textbox12.text.trim(), textbox13.text.trim(), textbox14.text.trim(), textbox15.text.trim(), textbox16.text.trim() ; break; default: response.write("請?
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
- 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 果洛環(huán)保塑膠跑道施工方案
- 白云區(qū)五下數(shù)學試卷
- 山東城市電梯燈施工方案
- 洋浦疏港高速公路工程SG01標段水穩(wěn)拌合站環(huán)境影響報告表(公示稿)環(huán)評報告表
- 現(xiàn)場道路清理方案
- 弘景光電:盈利預(yù)測報告及審核報告
- 烏海市環(huán)氧自流平施工方案
- 山東省泰安市2025屆高三一輪檢測(泰安一模)日語參考答案
- 智能制造對勞動市場的影響
- ?;髽I(yè)安全生產(chǎn)監(jiān)控與檢查方案
- 股骨頸置換術(shù)后護理
- 《教育強國建設(shè)規(guī)劃綱要(2024-2035年)》解讀專題講座
- 2025湖北省建筑安全員考試題庫及答案
- 2025年《中央一號文件》參考試題庫資料100題及答案(含單選、多選、判斷題)
- 18 文言文二則 鐵杵成針 教學設(shè)計-2023-2024學年四年級語文下冊統(tǒng)編版
- 《影視照明技術(shù)》課件:照亮影視作品的靈魂
- 《酒店前廳設(shè)計》課件
- 老年醫(yī)學科建設(shè)與發(fā)展
- 2025年貴州能礦錳業(yè)集團有限公司招聘筆試參考題庫含答案解析
- 公司積分制管理實施方案
- 2024年湖南科技職業(yè)學院高職單招語文歷年參考題庫含答案解析
評論
0/150
提交評論