企业在线工作日志管理系统论文_第1页
企业在线工作日志管理系统论文_第2页
企业在线工作日志管理系统论文_第3页
企业在线工作日志管理系统论文_第4页
企业在线工作日志管理系统论文_第5页
已阅读5页,还剩260页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、PAGE PAGE 265河北大学工商学院河北大学工商学院学年论文题目: 企业在线工作日志管理系统 代码清单学 部 信息科学与工程学部 班 级 2010级网络工程1班 专 业 电气信息二类 学 号 2010482160 姓 名 李晓虹 指导教师 罗文杰 2012年 06月 06日目录Admin 部分4Head部分4Chart 部分项目表格7用户表格8Index部分10Announcement部分通告添加23通告删除27通稿编辑29通告查看33通告详情39Log部分日志添加41日志删除49日志编辑51完成日志59日志查看60Project部分项目添加62项目删除69项目编辑71项目查看78项目详

2、情87Task部分任务详情107任务添加149任务编辑161任务计划176任务日历190任务用户编辑196任务删除201User部分用户查看202用户编辑211修改用户密码216用户添加222用户删除229用户登录231查看用户详情232用户登陆错误253Session部分254成功页面257admin部分: , a href=default_user_edit.php?UID=a href=Head部分:(标头)?phpif (!function_exists(GetSQLValueString) function GetSQLValueString($theValue, $theType,

3、 $theDefinedValue = , $theNotDefinedValue = ) if (PHP_VERSION a href=index.php class=logourl title= , a href=default_user_edit.php?UID= a href= if(location.href.toLowerCase().indexOf(index.php)-1)document.getElementById(headerlink).getElementsByTagName(A)1.className=nav_select;else if(location.href.

4、toLowerCase().indexOf(default_project.php)-1)document.getElementById(headerlink).getElementsByTagName(A)2.className=nav_select;else if(location.href.toLowerCase().indexOf(default_user.php)-1)document.getElementById(headerlink).getElementsByTagName(A)3.className=nav_select;else if(location.href.toLow

5、erCase().indexOf(default_announcement.php)-1)document.getElementById(headerlink).getElementsByTagName(A)4.className=nav_select; 0) / Show if recordset not empty ? : a href=announcement_view.php?recordID= ( ) a href=index.php class=logourl title=chart 部分:项目表格:set_style(font-size:12px; font-weight:bol

6、d;); $pie = new pie(); $pie-set_alpha(0.6); $pie-set_start_angle( 32 ); $pie-add_animation( new pie_fade() ); $pie-set_tooltip( #val# .$multilingual_project_hour ); $pie-set_colours( array(#99C754,#54C7C5,#999999,#996699,#009900,#77C600,#ff7400, #FF0000,#4096ee,#c79810) ); $projectid = $_GETrecordID

7、;mysql_select_db($database_tankdb, $tankdb);$query_Recordset_sumtotal = sprintf(SELECT sum(csa_tb_manhour) as sum_hour FROM tk_task_byday WHERE csa_tb_backup3 = .$projectid.);$Recordset_sumtotal = mysql_query($query_Recordset_sumtotal, $tankdb) or die(mysql_error();$row_Recordset_sumtotal = mysql_fe

8、tch_assoc($Recordset_sumtotal);$t=$row_Recordset_sumtotalsum_hour; $sql=sprintf(SELECT * , sum(csa_tb_manhour) as summ1 FROM tk_task_byday inner join tk_task_tpye on tk_task_byday.csa_tb_backup4=tk_task_tpye.idWHERE csa_tb_backup3 = .$projectid. GROUP BY csa_tb_backup4 ORDER BY summ1 DESC); $query =

9、 mysql_query($sql, $tankdb) or die(mysql_error();while($row=mysql_fetch_assoc($query) $total=$rowsumm1; if(!empty($t) $v=round($total/$t,2)*100; else $v=0; $dis=array(name=$rowtask_tpye,total=$rowsumm1,v=$v); $len_dis=count($dis); for($i=0;$iset_values($dis_value); $chart = new open_flash_chart(); $

10、chart-set_title( $title ); $chart-add_element( $pie ); $chart-x_axis = null; $chart-bg_colour = ( #FFFFFF ); echo $chart-toPrettyString(); ?用户表格:set_style(font-size:12px; font-weight:bold;); $pie = new pie(); $pie-set_alpha(0.6); $pie-set_start_angle( 32 ); $pie-add_animation( new pie_fade() ); $pie

11、-set_tooltip( #val# .$multilingual_project_hour ); $pie-set_colours( array(#99C754,#54C7C5,#999999,#996699,#009900,#77C600,#ff7400, #FF0000,#4096ee,#c79810) ); $projectid = $_GETrecordID;mysql_select_db($database_tankdb, $tankdb);$query_Recordset_sumtotal = sprintf(SELECT sum(csa_tb_manhour) as sum_

12、hour FROM tk_task_byday WHERE csa_tb_backup2 = $projectid);$Recordset_sumtotal = mysql_query($query_Recordset_sumtotal, $tankdb) or die(mysql_error();$row_Recordset_sumtotal = mysql_fetch_assoc($Recordset_sumtotal);$t=$row_Recordset_sumtotalsum_hour; $sql=sprintf(SELECT * , sum(csa_tb_manhour) as su

13、mm1 FROM tk_task_byday inner join tk_task_tpye on tk_task_byday.csa_tb_backup4=tk_task_tpye.idWHERE csa_tb_backup2 = $projectid GROUP BY csa_tb_backup4 ORDER BY summ1 DESC); $query = mysql_query($sql, $tankdb) or die(mysql_error();while($row=mysql_fetch_assoc($query) $total=$rowsumm1; if(!empty($t)

14、$v=round($total/$t,2)*100; else $v=0; $dis=array(name=$rowtask_tpye,total=$rowsumm1,v=$v); $len_dis=count($dis); for($i=0;$iset_values($dis_value); $chart = new open_flash_chart(); $chart-set_title( $title ); $chart-add_element( $pie ); $chart-x_axis = null; $chart-bg_colour = ( #FFFFFF ); echo $cha

15、rt-toPrettyString(); ?index 部分:(索引):?php/$url_back = http:/.$_SERVER HTTP_HOST.$_SERVERPHP_SELF;/$_SESSIONurlback = $url_back;if (!function_exists(GetSQLValueString) function GetSQLValueString($theValue, $theType, $theDefinedValue = , $theNotDefinedValue = ) if (PHP_VERSION WSS - !- function TuneHei

16、ght() var frm = document.getElementById(frame_content); var subWeb = document.frames ? document.framesmain_frame.document : frm.contentDocument; if(frm != null & subWeb != null) frm.height = subWeb.body.scrollHeight; function clickTxt(obj)if(obj.innerHTML = )obj.innerHTML=elseobj.innerHTML=/- $(func

17、tion()$(.btn).click(function()$(.hideTr).toggle();););function searchtask() document.myform.action= default_task.php ; document.myform.target= main_frame; document.myform.submit(); return true; function exportexcel() document.myform.action= excel.php ; document.myform.target= main_frame; document.my

18、form.submit(); return false; option value= 0) mysql_data_seek($Recordset_project, 0); $row_Recordset_project = mysql_fetch_assoc($Recordset_project); ? option value=2009 2009 option value=2010 2010 option value=2011 2011 option value=2012 2012 option value=2013 2013 option value=2014 2014 option val

19、ue=2015 2015 option value=2016 2016 option value=2017 2017 option value=2018 2018 option value=2019 2019 option value=2020 2020 / option value=01 01 option value=02 02 option value=03 03 option value=04 04 option value=05 05 option value=06 06 option value=07 07 option value=08 08 option value=09 09

20、 option value=10 10 option value=11 11 option value=12 12 option value= 0) mysql_data_seek($tkstatus, 0); $row_tkstatus = mysql_fetch_assoc($tkstatus); ? input type=checkbox name=select_stf value= / option value= 0) mysql_data_seek($Recordset2, 0); $row_Recordset2 = mysql_fetch_assoc($Recordset2); ?

21、 option value= 0) mysql_data_seek($Recordset_type, 0); $row_Recordset_type = mysql_fetch_assoc($Recordset_type); ? input type=text name=inputtitle id=inputtitle value= / option value= 0) mysql_data_seek($Recordset2, 0); $row_Recordset2 = mysql_fetch_assoc($Recordset2); ? option value= option value=

22、option value= option value= option value= input type=text name=inputid id=inputid value=/ option value= 0) mysql_data_seek($Recordset2, 0); $row_Recordset2 = mysql_fetch_assoc($Recordset2); ? : option value= option value= option value= option value= option value= : input type=text name=inputtag id=i

23、nputtag value=/ input type=submit name=search id=search value= class=button onclick= return searchtask(); /input type=button name=export id=export value= class=button onclick= return exportexcel(); / iframe id=frame_content name=main_frame frameborder=0 height= width=100% src=default_task.php? onLoa

24、d=TuneHeight() scrolling=noannouncement 部分:(通告)通告添加:?phpif (!function_exists(GetSQLValueString) function GetSQLValueString($theValue, $theType, $theDefinedValue = , $theNotDefinedValue = ) if (PHP_VERSION WSS - J.check.rules = name: tk_anc_title, mid: anntitle, type: limit, requir: true, min: 2, max

25、: 30, warn: ;window.onload = function() J.check.regform(form1); var editor; KindEditor.ready(function(K) editor = K.create(#tk_anc_text, width : 100%,height: 350px,items: source, |, undo, redo, |, preview, print, template, cut, copy, paste, plainpaste, wordpaste, |, justifyleft, justifycenter, justi

26、fyright, justifyfull, insertorderedlist, insertunorderedlist, indent, outdent, subscript, superscript, clearhtml, quickformat, selectall, |, fullscreen, /, formatblock, fontname, fontsize, |, forecolor, hilitecolor, bold, italic, underline, strikethrough, lineheight, removeformat, |, image, flash, m

27、edia, insertfile, table, hr, map, code, pagebreak, anchor, link, unlink, |, about); ); form action= method=post name=form1 id=form1 : * : : option value= option value= selected=selected option value= : input name=tk_anc_create type=text class=gray value= size=32 readonly=readonly / input type=submit

28、 value= / input name=button type=button id=button onClick=javascript:history.go(-1) value= / 通告删除:?phpif (!function_exists(GetSQLValueString) function GetSQLValueString($theValue, $theType, $theDefinedValue = , $theNotDefinedValue = ) if (PHP_VERSION 6) $theValue = get_magic_quotes_gpc() ? stripslas

29、hes($theValue) : $theValue; $theValue = function_exists(mysql_real_escape_string) ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue); switch ($theType) case text: $theValue = ($theValue != ) ? . $theValue . : NULL; break; case long: case int: $theValue = ($theValue != ) ? intval(

30、$theValue) : NULL; break; case double: $theValue = ($theValue != ) ? doubleval($theValue) : NULL; break; case date: $theValue = ($theValue != ) ? . $theValue . : NULL; break; case defined: $theValue = ($theValue != ) ? $theDefinedValue : $theNotDefinedValue; break; return $theValue;if (isset($_GETde

31、lAID) & ($_GETdelAID != ) & ($_SESSIONMM_Username $multilingual_dd_user_readonly) $deleteSQL = sprintf(DELETE FROM tk_announcement WHERE AID=%s, GetSQLValueString($_GETdelAID, int); mysql_select_db($database_tankdb, $tankdb); $Result1 = mysql_query($deleteSQL, $tankdb) or die(mysql_error(); $deleteG

32、oTo = default_announcement.php; if (isset($_SERVERQUERY_STRING) $deleteGoTo .= (strpos($deleteGoTo, ?) ? & : ?; $deleteGoTo .= $_SERVERQUERY_STRING; header(sprintf(Location: %s, $deleteGoTo);?通告编辑:?phpif (!function_exists(GetSQLValueString) function GetSQLValueString($theValue, $theType, $theDefined

33、Value = , $theNotDefinedValue = ) if (PHP_VERSION WSS - J.check.rules = name: tk_anc_title, mid: anntitle, type: limit, requir: true, min: 2, max: 30, warn: ;window.onload = function() J.check.regform(form1); var editor; KindEditor.ready(function(K) editor = K.create(#tk_anc_text, width : 100%,heigh

34、t: 350px,items: source, |, undo, redo, |, preview, print, template, cut, copy, paste, plainpaste, wordpaste, |, justifyleft, justifycenter, justifyright, justifyfull, insertorderedlist, insertunorderedlist, indent, outdent, subscript, superscript, clearhtml, quickformat, selectall, |, fullscreen, /,

35、 formatblock, fontname, fontsize, |, forecolor, hilitecolor, bold, italic, underline, strikethrough, lineheight, removeformat, |, image, flash, media, insertfile, table, hr, map, code, pagebreak, anchor, link, unlink, |, about); ); form action= method=post name=form1 id=form1 : input type=text name=

36、tk_anc_title id=tk_anc_title value= size=32 / * : : option value= option value= option value= input type=submit value= / input name=button type=button id=button onclick=javascript:history.go(-1) value= / input type=hidden name=AID value= /通告查看:?phpif (!function_exists(GetSQLValueString) function Get

37、SQLValueString($theValue, $theType, $theDefinedValue = , $theNotDefinedValue = ) if (PHP_VERSION 6) $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue; $theValue = function_exists(mysql_real_escape_string) ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

38、switch ($theType) case text: $theValue = ($theValue != ) ? . $theValue . : NULL; break; case long: case int: $theValue = ($theValue != ) ? intval($theValue) : NULL; break; case double: $theValue = ($theValue != ) ? doubleval($theValue) : NULL; break; case date: $theValue = ($theValue != ) ? . $theVa

39、lue . : NULL; break; case defined: $theValue = ($theValue != ) ? $theDefinedValue : $theNotDefinedValue; break; return $theValue;$currentPage = $_SERVERPHP_SELF;$maxRows_Recordset1 = get_item( maxrows_announcement );$pageNum_Recordset1 = 0;if (isset($_GETpageNum_Recordset1) $pageNum_Recordset1 = $_G

40、ETpageNum_Recordset1;$startRow_Recordset1 = $pageNum_Recordset1 * $maxRows_Recordset1;$colname_Recordset1 = $multilingual_dd_announcement_offline;if (isset($_GETselect1) $colname_Recordset1 = $_GETselect1;mysql_select_db($database_tankdb, $tankdb);$query_Recordset1 = sprintf(SELECT * FROM tk_announc

41、ement inner join tk_user on tk_announcement.tk_anc_create=tk_user.tk_user_login WHERE tk_anc_type %s ORDER BY tk_anc_lastupdate DESC, GetSQLValueString($colname_Recordset1, text);$query_limit_Recordset1 = sprintf(%s LIMIT %d, %d, $query_Recordset1, $startRow_Recordset1, $maxRows_Recordset1);$Records

42、et1 = mysql_query($query_limit_Recordset1, $tankdb) or die(mysql_error();$row_Recordset1 = mysql_fetch_assoc($Recordset1);if (isset($_GETtotalRows_Recordset1) $totalRows_Recordset1 = $_GETtotalRows_Recordset1; else $all_Recordset1 = mysql_query($query_Recordset1); $totalRows_Recordset1 = mysql_num_r

43、ows($all_Recordset1);$totalPages_Recordset1 = ceil($totalRows_Recordset1/$maxRows_Recordset1)-1;$queryString_Recordset1 = ;if (!empty($_SERVERQUERY_STRING) $params = explode(&, $_SERVERQUERY_STRING); $newParams = array(); foreach ($params as $param) if (stristr($param, pageNum_Recordset1) = false &

44、stristr($param, totalRows_Recordset1) = false) array_push($newParams, $param); if (count($newParams) != 0) $queryString_Recordset1 = & . htmlentities(implode(&, $newParams); $queryString_Recordset1 = sprintf(&totalRows_Recordset1=%d%s, $totalRows_Recordset1, $queryString_Recordset1);?WSS - 0) / Show

45、 if recordset not empty ? input name= type=button class=button onclick=javascript:self.location=announcement_add.php; value= / input type=submit name=button11 id=button11 class=button value= / ( ) a href=announcement_view.php?recordID= a href=user_view.php?recordID= 0) / Show if not first page ? a h

46、ref= 0) / Show if not first page ? a href= ?php if ($pageNum_Recordset1 a href= ?php if ($pageNum_Recordset1 a href= ( ) input name= type=button class=button onclick=javascript:self.location=announcement_add.php; value= / input type=submit name=button11 class=button id=button11 value= / 通告详情:WSS - i

47、nput name= type=button class=button onclick=javascript:self.location=announcement_edit.php?editAID=; value= / input name= type=button class=button onclick=javascript:if(confirm( )self.location=announcement_del.php?delAID=; value= / input name= type=button onclick=javascript:history.go(-1) value= cla

48、ss=button / ?php if($row_DetailRS1tk_anc_text null) ? : : input name= type=button class=button onclick=javascript:self.location=announcement_edit.php?editAID=; value= / input name= type=button class=button onclick=javascript:if(confirm( )self.location=announcement_del.php?delAID=; value= / input nam

49、e= type=button onclick=javascript:history.go(-1) value= class=button / log部分:日志添加:?php$logdate = $_GETdate;$taskid = $_GETtaskid;$userid = $_GETuserid;$projectid = $_GETprojectid;$tasktype = $_GETtasktype;$nowuser = $_SESSIONMM_Username;$self_url = http:/.$_SERVER HTTP_HOST.$_SERVERPHP_SELF;$self =

50、substr($self_url , strrpos($self_url , /) + 1);$host_url=str_replace($self,$self_url);if (!function_exists(GetSQLValueString) function GetSQLValueString($theValue, $theType, $theDefinedValue = , $theNotDefinedValue = ) if (PHP_VERSION 6) $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) :

51、 $theValue; $theValue = function_exists(mysql_real_escape_string) ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue); switch ($theType) case text: $theValue = ($theValue != ) ? . $theValue . : NULL; break; case long: case int: $theValue = ($theValue != ) ? intval($theValue) : NUL

52、L; break; case double: $theValue = ($theValue != ) ? doubleval($theValue) : NULL; break; case date: $theValue = ($theValue != ) ? . $theValue . : NULL; break; case defined: $theValue = ($theValue != ) ? $theDefinedValue : $theNotDefinedValue; break; return $theValue;mysql_select_db($database_tankdb,

53、 $tankdb);$query_log = SELECT *, tk_user1.tk_user_email as tk_user_email1, tk_user2.tk_display_name as tk_display_name2 FROM tk_task inner join tk_user as tk_user2 on tk_task.csa_to_user=tk_user2.tk_user_login inner join tk_user as tk_user1 on tk_task.csa_from_user=tk_user1.tk_user_login WHERE TID=$

54、taskid;$log = mysql_query($query_log, $tankdb) or die(mysql_error();$row_log = mysql_fetch_assoc($log);$totalRows_log = mysql_num_rows($log);$mailto = $row_logtk_user_email1; $title = $row_logcsa_text; $user = $row_logtk_display_name2; $statusid = -1;if (isset($_POSTcsa_tb_status) $statusid = $_POST

55、csa_tb_status;mysql_select_db($database_tankdb, $tankdb);$query_tkstatus1 = SELECT * FROM tk_status WHERE id = $statusid;$tkstatus1 = mysql_query($query_tkstatus1, $tankdb) or die(mysql_error();$row_tkstatus1 = mysql_fetch_assoc($tkstatus1);$totalRows_tkstatus1 = mysql_num_rows($tkstatus1);/ * Redir

56、ect if username exists$editFormAction = $_SERVERPHP_SELF;if (isset($_SERVERQUERY_STRING) $editFormAction .= ? . htmlentities($_SERVERQUERY_STRING);if (isset($_POSTlog_insert) & ($_POSTlog_insert = form1) $insertSQL = sprintf(INSERT INTO tk_task_byday (csa_tb_year, csa_tb_status, csa_tb_manhour, csa_

57、tb_text, csa_tb_backup1, csa_tb_backup2, csa_tb_backup3, csa_tb_backup4) VALUES (%s, %s, %s, %s, %s, %s, %s, %s), GetSQLValueString($_POSTcsa_tb_year, text), GetSQLValueString($_POSTcsa_tb_status, text), GetSQLValueString($_POSTcsa_tb_manhour, text), GetSQLValueString($_POSTcsa_tb_text, text), GetSQ

58、LValueString($_POSTcsa_tb_backup1, text), GetSQLValueString($_POSTcsa_tb_backup2, text), GetSQLValueString($_POSTcsa_tb_backup3, text), GetSQLValueString($_POSTcsa_tb_backup4, text); mysql_select_db($database_tankdb, $tankdb); $Result1 = mysql_query($insertSQL, $tankdb) or die(mysql_error(); $newID

59、= $taskid; $newName = $_SESSIONMM_Username; $lyear = $_POSTcsa_tb_year; $lgyear = str_split($lyear,4); $lgmonth = str_split($lgyear1,2); $ldate = $lgyear0.-.$lgmonth0.-.$lgmonth1; $logstatus = $row_tkstatus1task_status; $logtext = $_POSTcsa_tb_text; $manhour = $_POSTcsa_tb_manhour; $action = $multil

60、ingual_log_addlog1.$ldate.$multilingual_log_addlog2.$logstatus.$multilingual_log_costlog.$manhour.$multilingual_global_hour.$logtext;$insertSQL2 = sprintf(INSERT INTO tk_log (tk_log_user, tk_log_action, tk_log_type) VALUES (%s, %s, %s ), GetSQLValueString($newName, text), GetSQLValueString($action,

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论