tutos-commits Mailing List for TUTOS (Page 452)
Projects / CRM / PLM / Calendar / Tasks / SCRUM / Test / Inventory
Brought to you by:
gokohnert
You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(13) |
Aug
(214) |
Sep
(144) |
Oct
(22) |
Nov
(22) |
Dec
(93) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(25) |
Feb
(31) |
Mar
(92) |
Apr
(70) |
May
(103) |
Jun
(130) |
Jul
(265) |
Aug
(325) |
Sep
(233) |
Oct
(244) |
Nov
(261) |
Dec
(157) |
2003 |
Jan
(101) |
Feb
(135) |
Mar
(148) |
Apr
(164) |
May
(53) |
Jun
(116) |
Jul
(149) |
Aug
(126) |
Sep
(45) |
Oct
(109) |
Nov
(36) |
Dec
(61) |
2004 |
Jan
(131) |
Feb
(236) |
Mar
(278) |
Apr
(259) |
May
(92) |
Jun
(110) |
Jul
(150) |
Aug
(64) |
Sep
(141) |
Oct
(141) |
Nov
(146) |
Dec
(65) |
2005 |
Jan
(70) |
Feb
(77) |
Mar
(129) |
Apr
(153) |
May
(161) |
Jun
(63) |
Jul
(42) |
Aug
(16) |
Sep
(30) |
Oct
(3) |
Nov
(8) |
Dec
(40) |
2006 |
Jan
(114) |
Feb
(16) |
Mar
(12) |
Apr
(15) |
May
(4) |
Jun
(9) |
Jul
(69) |
Aug
(27) |
Sep
(12) |
Oct
(80) |
Nov
(62) |
Dec
(41) |
2007 |
Jan
(34) |
Feb
(2) |
Mar
(38) |
Apr
(82) |
May
(61) |
Jun
(37) |
Jul
(16) |
Aug
(64) |
Sep
(7) |
Oct
(52) |
Nov
(18) |
Dec
(28) |
2008 |
Jan
(168) |
Feb
(26) |
Mar
(27) |
Apr
(19) |
May
(10) |
Jun
(58) |
Jul
(58) |
Aug
(91) |
Sep
(14) |
Oct
(23) |
Nov
(56) |
Dec
(38) |
2009 |
Jan
(58) |
Feb
(90) |
Mar
(204) |
Apr
(90) |
May
(27) |
Jun
(177) |
Jul
(116) |
Aug
(53) |
Sep
(42) |
Oct
(120) |
Nov
(51) |
Dec
(58) |
2010 |
Jan
(117) |
Feb
(231) |
Mar
(163) |
Apr
(90) |
May
(40) |
Jun
(139) |
Jul
(49) |
Aug
(118) |
Sep
(25) |
Oct
(80) |
Nov
(102) |
Dec
(99) |
2011 |
Jan
(176) |
Feb
(42) |
Mar
(60) |
Apr
(52) |
May
(30) |
Jun
(29) |
Jul
(27) |
Aug
(16) |
Sep
(51) |
Oct
(70) |
Nov
(63) |
Dec
(58) |
2012 |
Jan
(28) |
Feb
(26) |
Mar
(7) |
Apr
(12) |
May
(41) |
Jun
(61) |
Jul
(59) |
Aug
(38) |
Sep
(30) |
Oct
(28) |
Nov
(14) |
Dec
(31) |
2013 |
Jan
(24) |
Feb
(54) |
Mar
(45) |
Apr
(22) |
May
(35) |
Jun
(8) |
Jul
(18) |
Aug
(38) |
Sep
(11) |
Oct
(8) |
Nov
(19) |
Dec
(20) |
2014 |
Jan
(20) |
Feb
(22) |
Mar
(4) |
Apr
(6) |
May
(13) |
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
(6) |
2015 |
Jan
|
Feb
(1) |
Mar
(4) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
(1) |
2016 |
Jan
(4) |
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
(2) |
Aug
(4) |
Sep
(1) |
Oct
(1) |
Nov
(1) |
Dec
|
2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(3) |
Jul
(8) |
Aug
(13) |
Sep
(12) |
Oct
|
Nov
|
Dec
|
2018 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(2) |
2021 |
Jan
|
Feb
(1) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Gero K. <gok...@us...> - 2001-09-12 13:01:54
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv18704 Modified Files: watchlist_ins.php Log Message: fixed bug #460842 Index: watchlist_ins.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/watchlist_ins.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** watchlist_ins.php 2001/09/10 16:37:54 1.5 --- watchlist_ins.php 2001/09/12 13:01:51 1.6 *************** *** 12,15 **** --- 12,16 ---- include("file.pinc"); include("appointment.pinc"); + include("timetrack.pinc"); /* Check if user is allowed to use it */ |
From: Gero K. <gok...@us...> - 2001-09-11 21:06:56
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv4587/php Modified Files: file_show.php Log Message: added reference description Index: file_show.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/file_show.php,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -r1.15 -r1.16 *** file_show.php 2001/09/10 16:39:04 1.15 --- file_show.php 2001/09/11 21:06:53 1.16 *************** *** 44,48 **** echo "<TR>\n"; showfield($lang['FileReference']); ! echo " <TD COLSPAN=3>". $f->getRefLink() ."</TD>\n"; echo "</TR>\n"; --- 44,48 ---- echo "<TR>\n"; showfield($lang['FileReference']); ! echo " <TD COLSPAN=3>". $lang[$f->ref->gettype()] ." ". $f->getRefLink() ."</TD>\n"; echo "</TR>\n"; |
From: Gero K. <gok...@us...> - 2001-09-11 21:05:41
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv3970/php Modified Files: team_overview.php Log Message: added back/forward navigation Index: team_overview.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/team_overview.php,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -r1.8 -r1.9 *** team_overview.php 2001/09/10 16:35:44 1.8 --- team_overview.php 2001/09/11 21:05:39 1.9 *************** *** 12,31 **** * */ ! Function info(&$dbconn,&$result) { ! global $lang; ! $n = DB_NumRows($result); if ( 0 == $n) { return; } echo "<TABLE CLASS=single BORDER=1 CELLPADDING=3 CELLSPACING=0>\n"; echo "<TR>\n"; ! echo "<TH>". $lang['Team'] ."</TH><TH>". $lang['TeamManager'] ."</TH><TH>". $lang['TeamCount'] ."</TH>\n"; echo "</TR>\n"; - $a = 0; - while ( $a < $n ) { - $t = new team($dbconn); - $t->read_result($result,$a); echo "<TR>\n"; echo " <TD>". $t->getLink() ."</TD>\n"; --- 12,60 ---- * */ ! Function info(&$dbconn,&$result,$start) { ! global $tutos,$lang,$link1; ! $n = $dbconn->NumRows($result); if ( 0 == $n) { + echo "<SPAN CLASS=warn>". $lang['Err0048'] ."</SPAN>"; return; } + # Make a big array of all visible bugs + $x = 0; + while ( $x < $n ) { + $b = new team($dbconn); + $b->read_result($result,$x); + $x++; + if ( ! $b->see_ok() ) { + continue; + } + $tlist[] = $b; + } + $n = count($tlist); + if ( 0 == $n) { + echo "<SPAN CLASS=warn>". $lang['Err0048'] ."</SPAN>"; + return; + } + + echo "<TABLE CLASS=single BORDER=1 CELLPADDING=3 CELLSPACING=0>\n"; echo "<TR>\n"; ! echo order_header("name",$lang['Team']); ! echo order_header("",$lang['TeamManager']); ! echo order_header("",$lang['TeamCount']); echo "</TR>\n"; + + if ( $start == -1 ) { + $a = $n - $tutos[maxshow]; + $end = $n; + $start = $a; + } else { + $a = $start; + $end = $start + $tutos[maxshow]; + } + + while ( ($a < $n) && ($a < $end) ) { + $t = $tlist[$a]; echo "<TR>\n"; echo " <TD>". $t->getLink() ."</TD>\n"; *************** *** 35,38 **** --- 64,68 ---- $a++; } + ShowBackForwardNav($link1,3,$start,$a,$n); echo "</TABLE>\n"; *************** *** 42,51 **** */ Function navigate() { ! global $lang; echo "<TABLE>"; echo "<TR><TD>"; echo menulink("address_select.php",$lang['Search'],$lang['SearchForAdr']) ."<BR>\n"; ! echo menulink("team_new.php",$lang['NewEntry'],$lang['TeamCreateI']) . "<BR>\n"; echo "</TD></TR>"; --- 72,83 ---- */ Function navigate() { ! global $lang,$current_user; echo "<TABLE>"; echo "<TR><TD>"; echo menulink("address_select.php",$lang['Search'],$lang['SearchForAdr']) ."<BR>\n"; ! if ( $current_user->admin != 0) { ! echo menulink("team_new.php",$lang['NewEntry'],$lang['TeamCreateI']) . "<BR>\n"; ! } echo "</TD></TR>"; *************** *** 55,74 **** HTML_Header($lang['TeamOverview']); ! $query = "SELECT * FROM teams"; $pre = " WHERE "; if ( isset($name) && ($name != "*") && ($name != "") ) { ! $query .= $pre . $dbconn->Like("name",$name); $pre = " AND "; } ! $query .= " ORDER by name"; ! $result = $dbconn->Exec($query); HTML_Base1(); navigate(); HTML_Base2($msg); ! info($dbconn,$result); HTML_Base3(); --- 87,123 ---- HTML_Header($lang['TeamOverview']); ! $link1 = "team_overview.php"; ! $q = "SELECT * FROM teams"; $pre = " WHERE "; if ( isset($name) && ($name != "*") && ($name != "") ) { ! $q .= $pre . $dbconn->Like("name",$name); $pre = " AND "; } ! # sorting ! if ( isset($xf) && isset($xo) ) { ! $q .= " ORDER by " . $xf; ! if ( $xo == 1 ) { ! $q .= " ASC "; ! } else { ! $q .= " DESC "; ! } ! $link1 = addUrlParameter($link1,"xf=".UrlEncode($xf)); ! $link1 = addUrlParameter($link1,"xo=". $xo); ! } else { ! $q .= " ORDER by name"; ! } ! ! $result = $dbconn->Exec($q); + if ( ! isset($start) ) { + $start = 0; + } HTML_Base1(); navigate(); HTML_Base2($msg); ! info($dbconn,$result,$start); HTML_Base3(); |
From: Gero K. <gok...@us...> - 2001-09-11 21:04:58
|
Update of /cvsroot/tutos/tutos In directory usw-pr-cvs1:/tmp/cvs-serv3680 Modified Files: Makefile.in Log Message: added new holiday definition files Index: Makefile.in =================================================================== RCS file: /cvsroot/tutos/tutos/Makefile.in,v retrieving revision 1.63 retrieving revision 1.64 diff -C2 -r1.63 -r1.64 *** Makefile.in 2001/09/10 16:31:56 1.63 --- Makefile.in 2001/09/11 21:04:56 1.64 *************** *** 11,14 **** --- 11,17 ---- # # $Log$ + # Revision 1.64 2001/09/11 21:04:56 gokohnert + # added new holiday definition files + # # Revision 1.63 2001/09/10 16:31:56 gokohnert # added new DB handling files *************** *** 274,277 **** --- 277,285 ---- php/history.pinc \ php/history_show.php \ + php/holiday_de.pinc \ + php/holiday_de_at.pinc \ + php/holiday_hu.pinc \ + php/holiday_it.pinc \ + php/holiday_us.pinc \ php/installation.pinc \ php/installation_ins.php \ |
From: Gero K. <gok...@us...> - 2001-09-11 21:00:12
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv1856/php Modified Files: timetrack.pinc Log Message: moved transaction locking to .._del.php scripts Index: timetrack.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/timetrack.pinc,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -r1.17 -r1.18 *** timetrack.pinc 2001/09/10 16:37:54 1.17 --- timetrack.pinc 2001/09/11 21:00:09 1.18 *************** *** 187,192 **** function delete() { $msg = ""; - $this->dbconn->Begin("WORK"); - $this->dbconn->Lock("timetrack"); $q = "DELETE FROM timetrack WHERE id = ". $this->id; --- 187,190 ---- *************** *** 203,208 **** ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 201,204 ---- |
From: Gero K. <gok...@us...> - 2001-09-11 20:58:28
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv1124/php Modified Files: Date.pinc Added Files: holiday_de.pinc holiday_de_at.pinc holiday_hu.pinc holiday_it.pinc holiday_us.pinc Log Message: moved holiday definitions to own files --- NEW FILE: holiday_de.pinc --- <? /* * Copyright 2001 by Gero Kohnert * * CVS Info: $Id: holiday_de.pinc,v 1.1 2001/09/11 20:58:25 gokohnert Exp $ * $Author: gokohnert $ */ $tutos[cal][] = array( array( Date => "01-01", Desc => "Neujahr (D)"), array( Date => "06-01", Desc => "Heilige drei Könige (D*)"), array( Date => "01-05", Desc => "Tag der Arbeit (D)"), array( Date => "15-08", Desc => "Maria Himmelfahrt (D*)"), array( Date => "03-10", Desc => "Tag der deutschen Einheit (D)"), array( Date => "31-10", Desc => "Reformationstag (D*)"), array( Date => "01-11", Desc => "Allerheiligen (D*)"), array( Date => "25-12", Desc => "Weihnachten (D)"), array( Date => "26-12", Desc => "Weihnachten (D)"), array( Date => "GOODFRIDAY", Desc => "Karfreitag (D)"), array( Date => "EASTERSUNDAY", Desc => "Ostersonntag (D)"), array( Date => "EASTERMONDAY", Desc => "Ostermontag (D)"), array( Date => "ASCENSIONDAY", Desc => "Christi Himmelfahrt (D)"), array( Date => "WHITSUNDAY", Desc => "Pfingstsonntag (D)"), array( Date => "WHITMONDAY", Desc => "Pfingstmontag (D)"), array( Date => "FRONLEICHNAHM", Desc => "Fronleichnahm (D*)") ); ?> --- NEW FILE: holiday_de_at.pinc --- <? /* * Copyright 2001 by Gero Kohnert * * CVS Info: $Id: holiday_de_at.pinc,v 1.1 2001/09/11 20:58:25 gokohnert Exp $ * $Author: gokohnert $ */ $tutos[cal][] = array( array( Date => "01-01", Desc => "Neujahr (A)"), array( Date => "06-01", Desc => "Heilige drei Könige (A)"), array( Date => "01-05", Desc => "Tag der Arbeit (A)"), array( Date => "15-08", Desc => "Maria Himmelfahrt (A)"), array( Date => "26-10", Desc => "Nationalfeiertag (A)"), array( Date => "01-11", Desc => "Allerheiligen (A)"), array( Date => "08-12", Desc => "Maria Empfängnis (A)"), array( Date => "25-12", Desc => "Weihnachten (A)"), array( Date => "26-12", Desc => "Stephanstag (A)"), array( Date => "EASTERSUNDAY", Desc => "Ostersonntag (A)"), array( Date => "EASTERMONDAY", Desc => "Ostermontag (A)"), array( Date => "ASCENSIONDAY", Desc => "Christi Himmelfahrt (A)"), array( Date => "WHITSUNDAY", Desc => "Pfingstsonntag (A)"), array( Date => "WHITMONDAY", Desc => "Pfingstmontag (A)"), array( Date => "FRONLEICHNAHM", Desc => "Fronleichnahm (A)") ); ?> --- NEW FILE: holiday_hu.pinc --- <? /* * Copyright 2001 by Gero Kohnert * * CVS Info: $Id: holiday_hu.pinc,v 1.1 2001/09/11 20:58:25 gokohnert Exp $ * $Author: gokohnert $ */ $tutos[cal][] = array( array( Date => "01-01", Desc => "Újév (H)"), array( Date => "15-03", Desc => "Nemzeti ünnep 1848 (H)"), array( Date => "01-05", Desc => "Munka ünnepe (H)"), array( Date => "15-08", Desc => "Mária mennybemenetele (H)"), array( Date => "20-08", Desc => "Szt. István (H)"), array( Date => "23-10", Desc => "Nemzeti ünnep 1956 (H)"), array( Date => "25-12", Desc => "Karácsony (H)"), array( Date => "26-12", Desc => "Karácsony (H)"), array( Date => "EASTERSUNDAY", Desc => "Húsvét (H)"), array( Date => "EASTERMONDAY", Desc => "Húsvét hétfö (H)"), array( Date => "WHITSUNDAY", Desc => "Pünkösd (H)"), array( Date => "WHITMONDAY", Desc => "Pünkösd hétfö (H)") ); ?> --- NEW FILE: holiday_it.pinc --- <? /* * Copyright 2001 by Gero Kohnert * * CVS Info: $Id: holiday_it.pinc,v 1.1 2001/09/11 20:58:25 gokohnert Exp $ * $Author: gokohnert $ */ $tutos[cal][] = array( array( Date => "01-01", Desc => "Capodanno (I)"), array( Date => "06-01", Desc => "Epifania (I)"), array( Date => "25-04", Desc => "Festa Nazionale (I)"), array( Date => "01-05", Desc => "Festa del lavoro (I)"), array( Date => "15-08", Desc => "Assunzione (I)"), array( Date => "01-11", Desc => "Ognissanti (I)"), array( Date => "08-12", Desc => "Immacolata Concezione (I)"), array( Date => "25-12", Desc => "Natale (I)"), array( Date => "26-12", Desc => "S.Stefano (I)"), array( Date => "EASTERSUNDAY", Desc => "Pasqua (I)"), array( Date => "EASTERMONDAY", Desc => "Lunedi dell'Angelo (I)"), array( Date => "WHITSUNDAY", Desc => "Pentecoste (I)"), array( Date => "WHITMONDAY", Desc => "Lunedì di Pentecoste (I [Südtirol])") ); ?> --- NEW FILE: holiday_us.pinc --- <? /* * Copyright 2001 by Gero Kohnert * * CVS Info: $Id: holiday_us.pinc,v 1.1 2001/09/11 20:58:25 gokohnert Exp $ * $Author: gokohnert $ */ $tutos[cal][] = array( array( Date => "01-01", Desc => "New Year (US)"), array( Date => "04-07", Desc => "Independence Day (US)"), array( Date => "31-10", Desc => "Nevada Admissions Day (US)"), array( Date => "11-11", Desc => "Veterans Day (US)"), array( Date => "25-12", Desc => "Christmas (US)"), array( Date => "MARTINLUTHERKING", Desc => "Martin Luther King (US)"), array( Date => "WASHINGTON", Desc => "Washington's Birthday (US)"), array( Date => "MEMORIALDAY", Desc => "Memorial Day (US)"), array( Date => "LABORDAY", Desc => "Labor Day (US)"), array( Date => "COLUMBUSDAY", Desc => "Columbus Day (US)"), array( Date => "THANKSGIVING", Desc => "Thanksgiving Day (US)"), ); ?> Index: Date.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/Date.pinc,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -r1.33 -r1.34 *** Date.pinc 2001/09/10 16:34:41 1.33 --- Date.pinc 2001/09/11 20:58:25 1.34 *************** *** 53,145 **** $tutos[cal] = array(); if ($tutos[holiday]['AT'] == 1) { ! $tutos[cal][] = array( ! array( Date => "01-01", Desc => "Neujahr (A)"), ! array( Date => "06-01", Desc => "Heilige drei Könige (A)"), ! array( Date => "01-05", Desc => "Tag der Arbeit (A)"), ! array( Date => "15-08", Desc => "Maria Himmelfahrt (A)"), ! array( Date => "26-10", Desc => "Nationalfeiertag (A)"), ! array( Date => "01-11", Desc => "Allerheiligen (A)"), ! array( Date => "08-12", Desc => "Maria Empfängnis (A)"), ! array( Date => "25-12", Desc => "Weihnachten (A)"), ! array( Date => "26-12", Desc => "Stephanstag (A)"), ! array( Date => "EASTERSUNDAY", Desc => "Ostersonntag (A)"), ! array( Date => "EASTERMONDAY", Desc => "Ostermontag (A)"), ! array( Date => "ASCENSIONDAY", Desc => "Christi Himmelfahrt (A)"), ! array( Date => "WHITSUNDAY", Desc => "Pfingstsonntag (A)"), ! array( Date => "WHITMONDAY", Desc => "Pfingstmontag (A)"), ! array( Date => "FRONLEICHNAHM", Desc => "Fronleichnahm (A)") ! ); } if ($tutos[holiday]['DE'] == 1) { ! $tutos[cal][] = array( ! array( Date => "01-01", Desc => "Neujahr (D)"), ! array( Date => "06-01", Desc => "Heilige drei Könige (D*)"), ! array( Date => "01-05", Desc => "Tag der Arbeit (D)"), ! array( Date => "15-08", Desc => "Maria Himmelfahrt (D*)"), ! array( Date => "03-10", Desc => "Tag der deutschen Einheit (D)"), ! array( Date => "31-10", Desc => "Reformationstag (D*)"), ! array( Date => "01-11", Desc => "Allerheiligen (D*)"), ! array( Date => "25-12", Desc => "Weihnachten (D)"), ! array( Date => "26-12", Desc => "Weihnachten (D)"), ! array( Date => "GOODFRIDAY", Desc => "Karfreitag (D)"), ! array( Date => "EASTERSUNDAY", Desc => "Ostersonntag (D)"), ! array( Date => "EASTERMONDAY", Desc => "Ostermontag (D)"), ! array( Date => "ASCENSIONDAY", Desc => "Christi Himmelfahrt (D)"), ! array( Date => "WHITSUNDAY", Desc => "Pfingstsonntag (D)"), ! array( Date => "WHITMONDAY", Desc => "Pfingstmontag (D)"), ! array( Date => "FRONLEICHNAHM", Desc => "Fronleichnahm (D*)") ! ); } if ($tutos[holiday]['HU'] == 1) { ! $tutos[cal][] = array( ! array( Date => "01-01", Desc => "Újév (H)"), ! array( Date => "15-03", Desc => "Nemzeti ünnep 1848 (H)"), ! array( Date => "01-05", Desc => "Munka ünnepe (H)"), ! array( Date => "20-08", Desc => "Szt. István (H)"), ! array( Date => "23-10", Desc => "Nemzeti ünnep 1956 (H)"), ! array( Date => "25-12", Desc => "Karácsony (H)"), ! array( Date => "26-12", Desc => "Karácsony (H)"), ! array( Date => "EASTERSUNDAY", Desc => "Húsvét (H)"), ! array( Date => "EASTERMONDAY", Desc => "Húsvét hétfö (H)"), ! array( Date => "WHITSUNDAY", Desc => "Pünkösd (H)"), ! array( Date => "WHITMONDAY", Desc => "Pünkösd hétfö (H)") ! ); } if ($tutos[holiday]['IT'] == 1) { ! $tutos[cal][] = array( ! array( Date => "01-01", Desc => "Capodanno (I)"), ! array( Date => "06-01", Desc => "Epifania (I)"), ! array( Date => "25-04", Desc => "Festa Nazionale (I)"), ! array( Date => "01-05", Desc => "Festa del lavoro (I)"), ! array( Date => "15-08", Desc => "Assunzione (I)"), ! array( Date => "01-11", Desc => "Ognissanti (I)"), ! array( Date => "08-12", Desc => "Immacolata Concezione (I)"), ! array( Date => "25-12", Desc => "Natale (I)"), ! array( Date => "26-12", Desc => "S.Stefano (I)"), ! array( Date => "EASTERSUNDAY", Desc => "Pasqua (I)"), ! array( Date => "EASTERMONDAY", Desc => "Lunedi dell'Angelo (I)"), ! array( Date => "WHITSUNDAY", Desc => "Pentecoste (I)"), ! array( Date => "WHITMONDAY", Desc => "Lunedì di Pentecoste (I [Südtirol])") ! ); } if ($tutos[holiday]['US'] == 1) { ! $tutos[cal][] = array( ! array( Date => "01-01", Desc => "New Year (US)"), ! array( Date => "04-07", Desc => "Independence Day (US)"), ! array( Date => "31-10", Desc => "Nevada Admissions Day (US)"), ! array( Date => "11-11", Desc => "Veterans Day (US)"), ! array( Date => "25-12", Desc => "Christmas (US)"), ! array( Date => "MARTINLUTHERKING", Desc => "Martin Luther King (US)"), ! array( Date => "WASHINGTON", Desc => "Washington's Birthday (US)"), ! array( Date => "MEMORIALDAY", Desc => "Memorial Day (US)"), ! array( Date => "LABORDAY", Desc => "Labor Day (US)"), ! array( Date => "COLUMBUSDAY", Desc => "Columbus Day (US)"), ! array( Date => "THANKSGIVING", Desc => "Thanksgiving Day (US)"), ! ); } return; --- 53,79 ---- $tutos[cal] = array(); + # Read Custom Holidays , like company anniversary etc. + if ( file_exists("holiday_custom.pinc") && is_readable("holiday_custom.pinc") ) { + include "holiday_custom.pinc"; + } + if ($tutos[holiday]['AT'] == 1) { ! include "holiday_de_at.pinc"; } if ($tutos[holiday]['DE'] == 1) { ! include "holiday_de.pinc"; } if ($tutos[holiday]['HU'] == 1) { ! include "holiday_hu.pinc"; } if ($tutos[holiday]['IT'] == 1) { ! include "holiday_it.pinc"; } if ($tutos[holiday]['US'] == 1) { ! include "holiday_us.pinc"; } return; |
From: Gero K. <gok...@us...> - 2001-09-11 19:53:06
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv3927/php Modified Files: timetrack_del.php watchlist_del.php mailbox.pinc mailbox_del.php team_del.php team.pinc Log Message: moved transaction locking to .._del.php scripts Index: timetrack_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/timetrack_del.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -r1.6 -r1.7 *** timetrack_del.php 2001/09/10 16:37:54 1.6 --- timetrack_del.php 2001/09/11 19:53:03 1.7 *************** *** 36,41 **** } } else { - $msg .= $obj->delete(); $gotourl = $obj->ref->getUrl(); } --- 36,44 ---- } } else { $gotourl = $obj->ref->getUrl(); + + $dbconn->Begin("WORK"); + $msg .= $obj->delete(); + $dbconn->Commit("WORK"); } Index: watchlist_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/watchlist_del.php,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -r1.8 -r1.9 *** watchlist_del.php 2001/09/10 16:37:54 1.8 --- watchlist_del.php 2001/09/11 19:53:03 1.9 *************** *** 27,31 **** --- 27,33 ---- } if ( $msg == "" ) { + $dbconn->Begin("WORK"); $msg .= watchlist_remove($id,$adr); + $dbconn->Commit("WORK"); } Index: mailbox.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/mailbox.pinc,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -r1.17 -r1.18 *** mailbox.pinc 2001/09/10 16:40:40 1.17 --- mailbox.pinc 2001/09/11 19:53:03 1.18 *************** *** 397,402 **** function delete() { $msg = ""; - $this->dbconn->Begin("WORK"); - $this->dbconn->Lock("mailboxes"); $q = "DELETE FROM mailboxes WHERE id = ". $this->id; --- 397,400 ---- *************** *** 408,413 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 406,409 ---- Index: mailbox_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/mailbox_del.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** mailbox_del.php 2001/09/10 16:40:40 1.5 --- mailbox_del.php 2001/09/11 19:53:03 1.6 *************** *** 33,38 **** if ( $msg == "" ) { - $msg .= $m->delete(); $gotourl= $m->parent->getURL(); } --- 33,41 ---- if ( $msg == "" ) { $gotourl= $m->parent->getURL(); + + $dbconn->Begin("WORK"); + $msg .= $m->delete(); + $dbconn->Commit("WORK"); } Index: team_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/team_del.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** team_del.php 2001/09/10 16:35:44 1.5 --- team_del.php 2001/09/11 19:53:03 1.6 *************** *** 30,35 **** if ( $msg == "" ) { - $msg .= $t->delete(); $gotourl= "team_overview.php"; } --- 30,38 ---- if ( $msg == "" ) { $gotourl= "team_overview.php"; + + $dbconn->Begin("WORK"); + $msg .= $t->delete(); + $dbconn->Commit("WORK"); } Index: team.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/team.pinc,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -r1.31 -r1.32 *** team.pinc 2001/09/10 16:35:44 1.31 --- team.pinc 2001/09/11 19:53:03 1.32 *************** *** 267,271 **** function delete() { $msg = ""; - $this->dbconn->Begin("WORK"); $q = "DELETE FROM teams WHERE id = ". $this->id; --- 267,270 ---- *************** *** 286,291 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 285,288 ---- |
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv30856/php Modified Files: app_del.php appointment.pinc resource.pinc resource_del.php task.pinc task_del.php url.pinc url_del.php Log Message: moved transaction locking to .._del.php scripts Index: app_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/app_del.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** app_del.php 2001/09/10 16:40:40 1.2 --- app_del.php 2001/09/11 19:41:36 1.3 *************** *** 36,40 **** --- 36,43 ---- if ( $msg == "" ) { $gotourl = "calendar.php?t=". $a->start->getYYYYMMDD(); + + $dbconn->Begin("WORK"); $msg .= $a->delete(); + $dbconn->Commit("WORK"); } $gotourl = addSessionKey($gotourl); Index: appointment.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/appointment.pinc,v retrieving revision 1.56 retrieving revision 1.57 diff -C2 -r1.56 -r1.57 *** appointment.pinc 2001/09/10 16:40:40 1.56 --- appointment.pinc 2001/09/11 19:41:36 1.57 *************** *** 487,493 **** function delete() { $msg = ""; - $this->dbconn->Begin("WORK"); - $this->dbconn->Lock("calendar"); - $this->dbconn->Lock("participants"); $q = "DELETE FROM calendar WHERE id = ". $this->id; --- 487,490 ---- *************** *** 506,511 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 503,506 ---- Index: resource.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/resource.pinc,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -r1.17 -r1.18 *** resource.pinc 2001/09/10 16:37:54 1.17 --- resource.pinc 2001/09/11 19:41:36 1.18 *************** *** 324,330 **** $msg = ""; - $this->dbconn->Begin("WORK"); - $this->dbconn->Lock("urls"); - $q = "DELETE FROM resources WHERE id = ". $this->id; $this->dbconn->Exec($q); --- 324,327 ---- *************** *** 339,344 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->gettype() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 336,339 ---- Index: resource_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/resource_del.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** resource_del.php 2001/09/10 16:37:54 1.2 --- resource_del.php 2001/09/11 19:41:36 1.3 *************** *** 28,32 **** --- 28,35 ---- if ( $msg == "" ) { $gotourl = "resource_overview.php"; + + $dbconn->Begin("WORK"); $msg .= $obj->delete(); + $dbconn->Commit("WORK"); } Index: task.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/task.pinc,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -r1.44 -r1.45 *** task.pinc 2001/09/10 16:35:44 1.44 --- task.pinc 2001/09/11 19:41:36 1.45 *************** *** 482,489 **** } - $this->dbconn->Begin("WORK"); - $this->dbconn->Lock("urls"); - $this->dbconn->Lock("notes"); - $q = "UPDATE tasks SET p_id = ". $this->p_id ." WHERE p_id = ". $this->id; $this->dbconn->Exec($q); --- 482,485 ---- *************** *** 505,510 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->gettype() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 501,504 ---- Index: task_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/task_del.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -r1.6 -r1.7 *** task_del.php 2001/09/10 16:35:44 1.6 --- task_del.php 2001/09/11 19:41:36 1.7 *************** *** 32,37 **** } if ($msg == "") { - $msg .= $t->delete(); $gotourl = $t->parent->getUrl(); } $gotourl = addUrlParameter($gotourl,"msg=". UrlEncode($msg)); --- 32,40 ---- } if ($msg == "") { $gotourl = $t->parent->getUrl(); + + $dbconn->Begin("WORK"); + $msg .= $t->delete(); + $dbconn->Commit("WORK"); } $gotourl = addUrlParameter($gotourl,"msg=". UrlEncode($msg)); Index: url.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/url.pinc,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -r1.23 -r1.24 *** url.pinc 2001/09/10 16:37:54 1.23 --- url.pinc 2001/09/11 19:41:36 1.24 *************** *** 105,111 **** } ! $q = "SELECT * from urls where id = $id"; $r = $this->dbconn->Exec($q); ! $n = DB_NumRows($r); if ( 0 == $n) { $this->id = -1; --- 105,111 ---- } ! $q = "SELECT * from urls where id = ". $id; $r = $this->dbconn->Exec($q); ! $n = $this->dbconn->NumRows($r); if ( 0 == $n) { $this->id = -1; *************** *** 172,177 **** function delete() { $msg = ""; - $this->dbconn->Begin("WORK"); - $this->dbconn->Lock("urls"); $q = "DELETE FROM urls WHERE id = ". $this->id; --- 172,175 ---- *************** *** 183,188 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->gettype() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 181,184 ---- Index: url_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/url_del.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** url_del.php 2001/09/10 16:37:54 1.4 --- url_del.php 2001/09/11 19:41:36 1.5 *************** *** 23,28 **** if ( $msg == "" ) { $u = new url($dbconn); ! $u->id = $id; $msg .= $u->delete(); } --- 23,31 ---- if ( $msg == "" ) { $u = new url($dbconn); ! $u->read($id); ! ! $dbconn->Begin("WORK"); $msg .= $u->delete(); + $dbconn->Commit("WORK"); } |
From: Gero K. <gok...@us...> - 2001-09-11 19:32:20
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv26488/php Modified Files: address.pinc address_del.php location.pinc location_del.php user.pinc user_del.php Log Message: moved transaction locking to .._del.php scripts Index: address.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/address.pinc,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -r1.42 -r1.43 *** address.pinc 2001/09/10 16:35:44 1.42 --- address.pinc 2001/09/11 19:32:17 1.43 *************** *** 340,344 **** $this->read_locs_data(); - $this->dbconn->Begin("WORK"); $this->dbconn->Lock("location"); $this->dbconn->Lock("adrloc"); --- 340,343 ---- *************** *** 378,383 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 377,380 ---- Index: address_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/address_del.php,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -r1.7 -r1.8 *** address_del.php 2001/09/10 16:35:44 1.7 --- address_del.php 2001/09/11 19:32:17 1.8 *************** *** 26,33 **** if ( $msg == "" ) { $a->delete(); $gotourl = "address_select.php"; } ! $gotourl= addUrlParameter($gotourl,"msg=". UrlEncode($msg)); $gotourl = addSessionKey($gotourl); --- 26,36 ---- if ( $msg == "" ) { + $dbconn->Begin("WORK"); $a->delete(); + $dbconn->Commit("WORK"); + $gotourl = "address_select.php"; } ! $gotourl = addUrlParameter($gotourl,"msg=". UrlEncode($msg)); $gotourl = addSessionKey($gotourl); Index: location.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/location.pinc,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -r1.13 -r1.14 *** location.pinc 2001/09/10 16:39:04 1.13 --- location.pinc 2001/09/11 19:32:17 1.14 *************** *** 225,229 **** function delete () { $msg = ""; ! $this->dbconn->Begin("WORK"); $this->dbconn->Lock("location"); $this->dbconn->Lock("adrloc"); --- 225,229 ---- function delete () { $msg = ""; ! $this->dbconn->Lock("location"); $this->dbconn->Lock("adrloc"); *************** *** 237,242 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 237,240 ---- Index: location_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/location_del.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** location_del.php 2001/09/10 16:39:04 1.3 --- location_del.php 2001/09/11 19:32:17 1.4 *************** *** 10,13 **** --- 10,14 ---- check_user(); + $msg = ""; $l = new location($dbconn); $l->read($id); *************** *** 15,20 **** $ref = getObject($dbconn,$ref); ! $l->delete(); $gotourl = $ref->getUrl(); $gotourl = addSessionKey($gotourl); --- 16,26 ---- $ref = getObject($dbconn,$ref); ! ! $dbconn->Begin("WORK"); ! $msg .= $l->delete(); ! $dbconn->Commit("WORK"); ! $gotourl = $ref->getUrl(); + $gotourl = addUrlParameter($gotourl,"msg=". UrlEncode($msg)); $gotourl = addSessionKey($gotourl); Index: user.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/user.pinc,v retrieving revision 1.47 retrieving revision 1.48 diff -C2 -r1.47 -r1.48 *** user.pinc 2001/09/10 16:35:44 1.47 --- user.pinc 2001/09/11 19:32:17 1.48 *************** *** 122,126 **** #echo "<BR>LAST: ". $this->last_seen->getDateTime(); $this->prefteam = DB_Result($result, $pos, "prefteam"); ! $this->p[useoverlib] = DB_Result($result, $pos, "overlib"); $this->lang = StripSlashes(DB_Result($result, $pos, "lang")); if ( $this->lang == "" ) { --- 122,126 ---- #echo "<BR>LAST: ". $this->last_seen->getDateTime(); $this->prefteam = DB_Result($result, $pos, "prefteam"); ! # $this->p[useoverlib] = DB_Result($result, $pos, "overlib"); $this->lang = StripSlashes(DB_Result($result, $pos, "lang")); if ( $this->lang == "" ) { *************** *** 552,559 **** $flds .= ",admin"; ! $vals .= ",". $this->admin; ! $flds .= ",overlib"; ! $vals .= ",". $this->p[useoverlib]; $flds .= ",last_seen"; --- 552,559 ---- $flds .= ",admin"; ! $vals .= ",". sprintf("%d",$this->admin); ! # $flds .= ",overlib"; ! # $vals .= ",". $this->p[useoverlib]; $flds .= ",last_seen"; *************** *** 590,594 **** } $q .= ",admin = ". $this->admin; ! $q .= ",overlib = ". $this->p[useoverlib]; $q .= ",lang = ". $this->dbconn->String($this->lang); $q .= ",tz = ". $this->dbconn->String($this->tz); --- 590,594 ---- } $q .= ",admin = ". $this->admin; ! # $q .= ",overlib = ". $this->p[useoverlib]; $q .= ",lang = ". $this->dbconn->String($this->lang); $q .= ",tz = ". $this->dbconn->String($this->tz); *************** *** 611,615 **** $msg = ""; unset ($this->modified); ! $this->dbconn->Begin("WORK"); $q = "DELETE FROM people WHERE adr_id =". $this->id ." AND id = ". $this->uid; $this->dbconn->Exec($q); --- 611,615 ---- $msg = ""; unset ($this->modified); ! $q = "DELETE FROM people WHERE adr_id =". $this->id ." AND id = ". $this->uid; $this->dbconn->Exec($q); *************** *** 630,635 **** $this->modified[] = array ( "obj_id" => $this->uid , "field" => "Delete" , "old" => $this->gettype() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 630,633 ---- Index: user_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/user_del.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -r1.6 -r1.7 *** user_del.php 2001/09/10 16:35:44 1.6 --- user_del.php 2001/09/11 19:32:17 1.7 *************** *** 30,34 **** --- 30,37 ---- if ( $msg == "" ) { + $dbconn->Begin("WORK"); $msg .= $u->delete(); + $dbconn->Commit("WORK"); + $msg .= "User (not address!) ". $u->getFullName() ." was deleted<BR>"; } |
From: Gero K. <gok...@us...> - 2001-09-11 18:51:47
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv7976/php Modified Files: department_del.php company_del.php file.pinc file_del.php note.pinc note_del.php product.pinc product_del.php bug.pinc bug_del.php installation.pinc installation_del.php Log Message: moved transaction locking to .._del.php scripts Index: department_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/department_del.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** department_del.php 2001/09/10 16:40:40 1.5 --- department_del.php 2001/09/11 18:51:44 1.6 *************** *** 8,11 **** --- 8,12 ---- include("note.pinc"); include("url.pinc"); + include("file.pinc"); /* Check if user is allowed to use it */ *************** *** 28,32 **** --- 29,36 ---- if ( $msg == "" ) { + $dbconn->Begin("WORK"); $msg = $d->delete(); + $dbconn->Commit("WORK"); + $gotourl = "address_select.php" ; } else { Index: company_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/company_del.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** company_del.php 2001/09/10 16:40:40 1.5 --- company_del.php 2001/09/11 18:51:44 1.6 *************** *** 8,11 **** --- 8,12 ---- include("note.pinc"); include("url.pinc"); + include("file.pinc"); /* Check if user is allowed to use it */ *************** *** 28,32 **** --- 29,36 ---- if ( $msg == "" ) { + $dbconn->Begin("WORK"); $msg = $c->delete(); + $dbconn->Commit("WORK"); + $gotourl = "address_select.php" ; } else { Index: file.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/file.pinc,v retrieving revision 1.39 retrieving revision 1.40 diff -C2 -r1.39 -r1.40 *** file.pinc 2001/09/10 19:41:24 1.39 --- file.pinc 2001/09/11 18:51:44 1.40 *************** *** 668,672 **** $msg = ""; - $this->dbconn->Begin("WORK"); $this->dbconn->Lock("files"); $this->dbconn->Lock("addresses"); --- 668,671 ---- *************** *** 685,690 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); # Delete the file --- 684,687 ---- Index: file_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/file_del.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -r1.6 -r1.7 *** file_del.php 2001/09/10 16:39:04 1.6 --- file_del.php 2001/09/11 18:51:44 1.7 *************** *** 34,38 **** --- 34,42 ---- if ( $msg == "" ) { $f->read_reference(); + + $dbconn->Begin("WORK"); $msg = $f->delete(); + $dbconn->Commit("WORK"); + $gotourl = $f->ref->getURL(); } Index: note.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/note.pinc,v retrieving revision 1.37 retrieving revision 1.38 diff -C2 -r1.37 -r1.38 *** note.pinc 2001/09/10 16:39:04 1.37 --- note.pinc 2001/09/11 18:51:44 1.38 *************** *** 347,352 **** function delete() { $msg = ""; - $this->dbconn->Begin("WORK"); - $this->dbconn->Lock("notes"); $q = "DELETE FROM notes WHERE id = ". $this->id; --- 347,350 ---- *************** *** 358,363 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->gettype() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 356,359 ---- Index: note_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/note_del.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -r1.6 -r1.7 *** note_del.php 2001/09/10 16:39:04 1.6 --- note_del.php 2001/09/11 18:51:44 1.7 *************** *** 38,42 **** --- 38,45 ---- $u->read_reference(); $gotourl = $u->ref->getURL(); + + $dbconn->Begin("WORK"); $msg .= $u->delete(); + $dbconn->Commit("WORK"); } Index: product.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/product.pinc,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -r1.42 -r1.43 *** product.pinc 2001/09/10 16:39:04 1.42 --- product.pinc 2001/09/11 18:51:44 1.43 *************** *** 887,891 **** } - $this->dbconn->Begin("WORK"); $this->dbconn->Lock("products"); $this->dbconn->Lock("urls"); --- 887,890 ---- *************** *** 930,935 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 929,932 ---- Index: product_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/product_del.php,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -r1.7 -r1.8 *** product_del.php 2001/09/10 16:39:04 1.7 --- product_del.php 2001/09/11 18:51:44 1.8 *************** *** 39,43 **** --- 39,46 ---- if ( $msg == "" ) { + $dbconn->Begin("WORK"); $msg .= $p->delete($id); + $dbconn->Commit("WORK"); + $gotourl = "product_overview.php"; } Index: bug.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/bug.pinc,v retrieving revision 1.39 retrieving revision 1.40 diff -C2 -r1.39 -r1.40 *** bug.pinc 2001/09/10 16:39:04 1.39 --- bug.pinc 2001/09/11 18:51:44 1.40 *************** *** 669,673 **** function delete() { $msg = ""; ! $this->dbconn->Begin("WORK"); $this->dbconn->Lock("bugs"); $this->dbconn->Lock("files"); --- 669,673 ---- function delete() { $msg = ""; ! $this->dbconn->Lock("bugs"); $this->dbconn->Lock("files"); *************** *** 693,698 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 693,696 ---- Index: bug_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/bug_del.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** bug_del.php 2001/09/10 16:39:04 1.5 --- bug_del.php 2001/09/11 18:51:44 1.6 *************** *** 32,36 **** --- 32,38 ---- } if ($msg == "") { + $dbconn->Begin("WORK"); $msg .= $b->delete(); + $dbconn->Commit("WORK"); } $gotourl = addUrlParameter($gotourl,"msg=". UrlEncode($msg)); Index: installation.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/installation.pinc,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -r1.29 -r1.30 *** installation.pinc 2001/09/10 16:39:04 1.29 --- installation.pinc 2001/09/11 18:51:44 1.30 *************** *** 439,443 **** function delete() { $msg = ""; ! $this->dbconn->Begin("WORK"); $this->dbconn->Lock("installations"); $this->dbconn->Lock("bugs"); --- 439,443 ---- function delete() { $msg = ""; ! $this->dbconn->Lock("installations"); $this->dbconn->Lock("bugs"); *************** *** 464,469 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->getType() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 464,467 ---- Index: installation_del.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/installation_del.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** installation_del.php 2001/09/10 16:39:04 1.4 --- installation_del.php 2001/09/11 18:51:44 1.5 *************** *** 33,37 **** --- 33,39 ---- } if ($msg == "") { + $dbconn->Begin("WORK"); $msg .= $i->delete(); + $dbconn->Commit("WORK"); } $gotourl = addUrlParameter($gotourl,"msg=". UrlEncode($msg)); |
From: Gero K. <gok...@us...> - 2001-09-11 18:46:41
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv5806/php Modified Files: company_show.php company.pinc department.pinc department_show.php Log Message: added document support Index: company_show.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/company_show.php,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -r1.17 -r1.18 *** company_show.php 2001/09/10 16:40:40 1.17 --- company_show.php 2001/09/11 18:46:38 1.18 *************** *** 1,5 **** <? /* ! * Copyright 1999/2000 by Gero Kohnert */ include("webelements.p3"); --- 1,5 ---- <? /* ! * Copyright 1999/2000/2001 by Gero Kohnert */ include("webelements.p3"); *************** *** 12,15 **** --- 12,16 ---- include("product.pinc"); include("bug.pinc"); + include("file.pinc"); include("timetrack.pinc"); *************** *** 155,158 **** --- 156,176 ---- } + # Files + if ( ($current_user->p[usedocmanagement] == 1) && ($tutos[usedocmanagement] == 1) ) { + $c->readFiles(); + if ( count($c->filelist) >0 ) { + @reset($c->filelist); + echo "<TR>\n"; + showfield($lang['ProdFiles']); + echo " <TD VALIGN=top COLSPAN=3>\n"; + if ( $format == "paper" ) { + showFiles($c,-1); + } else { + showFiles($c); + } + echo " </TD>\n"; + echo "</TR>\n"; + } + } echo "</TABLE>\n"; *************** *** 173,177 **** --- 191,197 ---- } } + echo "<BR>\n"; + if ( ($obj->id > 0) && $obj->see_ok() ) { echo menulink("department_new.php?company=". UrlEncode($obj->name) ,$lang['DepartmentCreate'],$lang['DepCreateInfo']) ."<BR>\n"; *************** *** 184,188 **** echo menulink("note_select.php",$lang['NoteSearch'],$lang['SearchForNote']) ."<BR>\n"; } ! echo "</TD></TR>"; --- 204,210 ---- echo menulink("note_select.php",$lang['NoteSearch'],$lang['SearchForNote']) ."<BR>\n"; } ! if ( ($current_user->p[usedocmanagement] == 1) && ($tutos[usedocmanagement] == 1) ) { ! echo menulink("file_new.php?link_id=". $obj->id ,$lang['FileCreate'],sprintf($lang['FileCreateInfo'],$obj->getFullName())) ." <BR>\n"; ! } echo "</TD></TR>"; Index: company.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/company.pinc,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -r1.23 -r1.24 *** company.pinc 2001/09/10 16:40:40 1.23 --- company.pinc 2001/09/11 18:46:38 1.24 *************** *** 180,183 **** --- 180,190 ---- } /* --------------------------------------------------------------------------- + * Return Info about connected files of this company + */ + function readFiles() { + readFiles($this); + return; + } + /* --------------------------------------------------------------------------- * */ *************** *** 223,228 **** $this->read_departments(); - $this->dbconn->Begin("WORK"); - @reset($this->departments); if ( count($this->departments) > 0 ) { --- 230,233 ---- *************** *** 231,234 **** --- 236,248 ---- } } + + $this->readFiles(); + if ( isset($this->filelist) && (count($this->filelist) > 0) ) { + @reset ($this->buglist); + while ( list ($i,$f) = @each ($this->filelist) ) { + $msg .= $f->delete(); + } + } + $this->dbconn->Lock("companies"); $this->dbconn->Lock("location"); *************** *** 254,259 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->gettype() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 268,271 ---- Index: department.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/department.pinc,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -r1.23 -r1.24 *** department.pinc 2001/09/10 16:40:40 1.23 --- department.pinc 2001/09/11 18:46:38 1.24 *************** *** 152,155 **** --- 152,162 ---- } /* --------------------------------------------------------------------------- + * Return Info about connected files of this department + */ + function readFiles() { + readFiles($this); + return; + } + /* --------------------------------------------------------------------------- * */ *************** *** 194,200 **** $this->read_locs(); - $this->dbconn->Begin("WORK"); $this->dbconn->Lock("location"); $r = $this->dbconn->Exec("DELETE from departments WHERE id =" .$this->id); $r = $this->dbconn->Exec("UPDATE location SET d_id = null WHERE d_id =" .$this->id); --- 201,214 ---- $this->read_locs(); $this->dbconn->Lock("location"); + $this->readFiles(); + if ( isset($this->filelist) && (count($this->filelist) > 0) ) { + @reset ($this->buglist); + while ( list ($i,$f) = @each ($this->filelist) ) { + $msg .= $f->delete(); + } + } + $r = $this->dbconn->Exec("DELETE from departments WHERE id =" .$this->id); $r = $this->dbconn->Exec("UPDATE location SET d_id = null WHERE d_id =" .$this->id); *************** *** 221,226 **** $this->modified[] = array ( "field" => "Delete" , "old" => $this->gettype() , "new" => -1 ); $msg .= history_save($this); - - $this->dbconn->Commit("WORK"); return $msg; --- 235,238 ---- Index: department_show.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/department_show.php,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -r1.14 -r1.15 *** department_show.php 2001/09/10 16:40:40 1.14 --- department_show.php 2001/09/11 18:46:38 1.15 *************** *** 1,5 **** <? /* ! * Copyright 1999/2000 by Gero Kohnert */ include("webelements.p3"); --- 1,5 ---- <? /* ! * Copyright 1999/2000/2001 by Gero Kohnert */ include("webelements.p3"); *************** *** 7,13 **** --- 7,17 ---- include("note.pinc"); include("url.pinc"); + include("installation.pinc"); include("address_tools.p3"); include("appointment.pinc"); include("product.pinc"); + include("bug.pinc"); + include("file.pinc"); + include("timetrack.pinc"); /* Check if user is allowed to use it */ *************** *** 17,21 **** * */ ! Function info($d,&$ra) { global $tutos,$lang, $current_user; --- 21,25 ---- * */ ! Function info(&$d,&$ra) { global $tutos,$lang, $current_user; *************** *** 122,125 **** --- 126,147 ---- } } + + # Files + if ( ($current_user->p[usedocmanagement] == 1) && ($tutos[usedocmanagement] == 1) ) { + $d->readFiles(); + if ( count($d->filelist) >0 ) { + @reset($d->filelist); + echo "<TR>\n"; + showfield($lang['ProdFiles']); + echo " <TD VALIGN=top COLSPAN=3>\n"; + if ( $format == "paper" ) { + showFiles($d,-1); + } else { + showFiles($d); + } + echo " </TD>\n"; + echo "</TR>\n"; + } + } echo "</TABLE>\n"; } *************** *** 128,132 **** * */ ! Function navigate($d) { global $tutos,$lang, $current_user; --- 150,154 ---- * */ ! Function navigate(&$obj) { global $tutos,$lang, $current_user; *************** *** 135,149 **** echo menulink("address_select.php",$lang['Search'],"Search for a department in the Database") ."<BR>\n"; echo menulink("department_new.php",$lang['NewEntry'],$lang['DepCreateInfo'] ) ."<BR>\n"; ! if ( $d->id != -1 ) { ! if ( $d->mod_ok() ) { ! echo menulink("department_new.php?id=".$d->id,$lang['Change'],sprintf($lang['DepChgInfo'],$d->getFullName())) ."<BR>\n"; ! } ! if ( $d->del_ok() ) { ! echo confirmlink("department_del.php?id=".$d->id,$lang['Delete'],sprintf($lang['DepDelInfo'],$d->getFullName())) ."<BR>\n"; } } if ( ($current_user->p[usenotes] == 1) && ($tutos[usenotes] == 1) ) { ! echo menulink("note_new.php?link_id=". $d->id ,$lang['NoteCreate'],sprintf($lang['NoteCreateInfo'],$d->getFullName())) ." <BR>\n"; } --- 157,175 ---- echo menulink("address_select.php",$lang['Search'],"Search for a department in the Database") ."<BR>\n"; echo menulink("department_new.php",$lang['NewEntry'],$lang['DepCreateInfo'] ) ."<BR>\n"; ! if ( $obj->id != -1 ) { ! if ( $obj->mod_ok() ) { ! echo menulink("department_new.php?id=".$obj->id,$lang['Change'],sprintf($lang['DepChgInfo'],$obj->getFullName())) ."<BR>\n"; } } + echo "<BR>\n"; + if ( ($current_user->p[usenotes] == 1) && ($tutos[usenotes] == 1) ) { ! echo menulink("note_new.php?link_id=". $obj->id ,$lang['NoteCreate'],sprintf($lang['NoteCreateInfo'],$obj->getFullName())) ." <BR>\n"; ! echo "<BR>\n"; ! echo menulink("note_select.php",$lang['NoteSearch'],$lang['SearchForNote']) ."<BR>\n"; ! } ! if ( ($current_user->p[usedocmanagement] == 1) && ($tutos[usedocmanagement] == 1) ) { ! echo menulink("file_new.php?link_id=". $obj->id ,$lang['FileCreate'],sprintf($lang['FileCreateInfo'],$obj->getFullName())) ." <BR>\n"; } |
From: Boris W. <bw...@us...> - 2001-09-11 15:29:16
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv23230 Modified Files: de.p3 Log Message: Translation and consistency fixes Index: de.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/de.p3,v retrieving revision 1.69 retrieving revision 1.70 diff -C2 -r1.69 -r1.70 *** de.p3 2001/09/10 19:39:23 1.69 --- de.p3 2001/09/11 15:29:10 1.70 *************** *** 221,225 **** $lang['UserDelInfo'] = "Benutzereintrag von %s löschen"; $lang['UserUnknown'] = "Unbekannter Benutzer"; ! $lang['UserLastSeen'] = "Letztes Login"; $lang['UserLastHost'] = "Letzter Rechner"; $lang['UserAdmin'] = "Administrator"; --- 221,225 ---- $lang['UserDelInfo'] = "Benutzereintrag von %s löschen"; $lang['UserUnknown'] = "Unbekannter Benutzer"; ! $lang['UserLastSeen'] = "Letzte Anmeldung"; $lang['UserLastHost'] = "Letzter Rechner"; $lang['UserAdmin'] = "Administrator"; *************** *** 387,394 **** # ACL ! $lang['AclModify'] = "Rechte ändern"; ! $lang['AclModifyI'] = "Rechte für %s ändern"; ! $lang['AclDetail'] = "Rechte anzeigen"; ! $lang['AclDetailI'] = "Rechte für %s anzeigen"; $lang['permissions'] = "Berechtigungen"; $lang['ACLsee'] = "Berechtigungen anzeigen"; --- 387,394 ---- # ACL ! $lang['AclModify'] = "Berechtigungen ändern"; ! $lang['AclModifyI'] = "Berechtigungen für %s ändern"; ! $lang['AclDetail'] = "Berechtigungen anzeigen"; ! $lang['AclDetailI'] = "Berechtigungen für %s anzeigen"; $lang['permissions'] = "Berechtigungen"; $lang['ACLsee'] = "Berechtigungen anzeigen"; *************** *** 400,405 **** $lang['ACLmodI'] = "Obige Benutzer/Gruppen dürfen %s ändern"; $lang['ACLdelI'] = "Obige Benutzer/Gruppen dürfen %s löschen"; ! $lang['ACLOverview'] = "Rechteübersicht"; ! $lang['ACLOverviewI'] = "alle Rechte ansehen"; # Tasks --- 400,405 ---- $lang['ACLmodI'] = "Obige Benutzer/Gruppen dürfen %s ändern"; $lang['ACLdelI'] = "Obige Benutzer/Gruppen dürfen %s löschen"; ! $lang['ACLOverview'] = "Berechtigunsübersicht"; ! $lang['ACLOverviewI'] = "Alle Berechtigungen anzeigen"; # Tasks *************** *** 740,764 **** $lang['AdminDBHost'] = "Rechner"; $lang['AdminDBPort'] = "Port"; ! $lang['AdminDBType'] = "Type"; $lang['AdminDBHome'] = "ORA_HOME"; ! $lang['AdminLoginInfo'] = "Letzte Logins"; ! $lang['AdminDBSync'] = "Database Sync"; ! $lang['AdminDBSource'] = "Source DB"; ! $lang['AdminDBWhat'] = "What/How"; ! $lang['AdminDBTarget'] = "Target DB"; ! $lang['AdminDBRep'] = "File Repository"; # Database ! $lang['DB'] = "Database"; $lang['DBInit'] = "Datenbankinitialisierung"; ! $lang['DBModify'] = "Database Modify"; ! $lang['DBModifyI'] = "Modify DB %s"; ! $lang['DBCreate'] = "Database Create"; ! $lang['DBDetail'] = "Database Detail"; ! $lang['DBLastDate'] = "LastSync Date"; $lang['DBCurrID'] = "ID"; ! $lang['DBLastID'] = "LastSync ID"; ! $lang['DBrelogin'] = "use Database"; ! $lang['DBreloginI'] = "relogin on %s"; # Permissions --- 740,764 ---- $lang['AdminDBHost'] = "Rechner"; $lang['AdminDBPort'] = "Port"; ! $lang['AdminDBType'] = "Typ"; $lang['AdminDBHome'] = "ORA_HOME"; ! $lang['AdminLoginInfo'] = "Letzte Anmeldungen"; ! $lang['AdminDBSync'] = "Datenbanksynchronisation"; ! $lang['AdminDBSource'] = "Quelldatenbank"; ! $lang['AdminDBWhat'] = "Was/Wie"; ! $lang['AdminDBTarget'] = "Zieldatenbank"; ! $lang['AdminDBRep'] = "Dateilager"; # Database ! $lang['DB'] = "Datenbank"; $lang['DBInit'] = "Datenbankinitialisierung"; ! $lang['DBModify'] = "Datenbank ändern"; ! $lang['DBModifyI'] = "Datenbank %s ändern"; ! $lang['DBCreate'] = "Datenbank erzeugen"; ! $lang['DBDetail'] = "Datenbankdetails"; ! $lang['DBLastDate'] = "Letzte Synchronisation"; $lang['DBCurrID'] = "ID"; ! $lang['DBLastID'] = "Letzte Sync-ID"; ! $lang['DBrelogin'] = "Datenbank benutzen"; ! $lang['DBreloginI'] = "Anmelden mit Datenbank %s"; # Permissions |
From: Gero K. <gok...@us...> - 2001-09-10 19:53:16
|
Update of /cvsroot/tutos/tutos In directory usw-pr-cvs1:/tmp/cvs-serv9857 Modified Files: .cvsignore ChangeLog ToDo tutos.properties.in Log Message: update Index: .cvsignore =================================================================== RCS file: /cvsroot/tutos/tutos/.cvsignore,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -r1.13 -r1.14 *** .cvsignore 2001/08/21 21:57:11 1.13 --- .cvsignore 2001/09/10 19:53:13 1.14 *************** *** 5,8 **** --- 5,9 ---- apache.conf tutos.properties + tutos.spec Makefile config.log Index: ChangeLog =================================================================== RCS file: /cvsroot/tutos/tutos/ChangeLog,v retrieving revision 1.59 retrieving revision 1.60 diff -C2 -r1.59 -r1.60 *** ChangeLog 2001/08/31 12:24:44 1.59 --- ChangeLog 2001/09/10 19:53:13 1.60 *************** *** 1,3 **** --- 1,43 ---- $Header$ + September 9 2001 + * added a new database table "tutos_dbs" to store info about + synced remote tutos databases. + To add this to existing installations please do + + create table tutos_dbs ( + id int4 primary key, -- a ID + dbname varchar(30) not null, -- database name + dbalias varchar(60), -- short text + dbhost varchar(30), -- hostname + dbuser varchar(30), -- username + dbpass varchar(30), -- password + dbhome varchar(60), -- path of ora_inst + dbtype int4, -- type pg = 1 or 4 mysql = 2 oracle = 3 msql = 5 sybase = 6 + repository varchar(60), -- path for files + last_date $TS_TYPE, -- date of last sync + last_id int4, -- sequencer id at last sync + creator int4, -- who is responsible see adresses(id) + creation $TS_TYPE not null -- when was it created + ); + + where $TS_TYPE is timestamp in postgres ,datetime in mysql and + date in oracle + for oracle also change the int4 to number(30,0) + + This feature will hopefully allow database synchronisation in the + next release. + TUTOS on mobile clients and resync after work. Cool !! + September 7 2001 + * new file search page file_select.php + September 6 2001 + * new usage of the jpgraph tool for statistic graphs (if + available). Make a [tutosdir]/php/jpgraph directory and put the jpgraph + files in there. You'll find jpgraph here + http://www.aditus.nu/jpgraph/ + * new watchlist support for documents + * fix bug with task_overviews + September 5 2001 + * new users watchlist overview via the mytutos page + * updated polish translation (serek) August 31 2001 * RELEASE 20010831 Index: ToDo =================================================================== RCS file: /cvsroot/tutos/tutos/ToDo,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -r1.10 -r1.11 *** ToDo 2001/08/30 16:55:04 1.10 --- ToDo 2001/09/10 19:53:13 1.11 *************** *** 71,74 **** --- 71,76 ---- Shareable Tasks between Projects ( idea by Dave Davies <Dav...@re...> ) + + Move Tasks from one Project to another one # # Index: tutos.properties.in =================================================================== RCS file: /cvsroot/tutos/tutos/tutos.properties.in,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** tutos.properties.in 2000/11/06 17:01:22 1.5 --- tutos.properties.in 2001/09/10 19:53:13 1.6 *************** *** 11,14 **** --- 11,17 ---- # # $Log$ + # Revision 1.6 2001/09/10 19:53:13 gokohnert + # update + # # Revision 1.5 2000/11/06 17:01:22 gokohnert # Prepare Release 20001106 *************** *** 50,54 **** # # repositories=[JAR/DIR],[JAR/DIR]....... ! repositories=%prefix%/,%ORACLE_CLASSES%,%ECS_CLASSES%,%POSTGRES_CLASSES%,%MYSQL_CLASSES%,%JAVA_HOME%/lib/tools.jar # ,/home/java/javalibs/libs/cocoon.jar,/home/java/javalibs/libs/xerces.jar,/home/java/javalibs/libs/xalan.jar,/home/java/javalibs/libs/fop.jar --- 53,57 ---- # # repositories=[JAR/DIR],[JAR/DIR]....... ! repositories=%PREFIX%/,%ORACLE_CLASSES%,%ECS_CLASSES%,%POSTGRES_CLASSES%,%MYSQL_CLASSES%,%JAVA_HOME%/lib/tools.jar # ,/home/java/javalibs/libs/cocoon.jar,/home/java/javalibs/libs/xerces.jar,/home/java/javalibs/libs/xalan.jar,/home/java/javalibs/libs/fop.jar *************** *** 188,192 **** # Default: NONE # servlet.org.fool.Dummy.initArgs=message=I'm a dummy servlet ! servlet.org.apache.cocoon.Cocoon.initArgs=properties=%prefix%/cocoon.properties # Aliased Servlet Init Parameters --- 191,195 ---- # Default: NONE # servlet.org.fool.Dummy.initArgs=message=I'm a dummy servlet ! servlet.org.apache.cocoon.Cocoon.initArgs=properties=%PREFIX%/cocoon.properties # Aliased Servlet Init Parameters *************** *** 201,203 **** ! # EOF \ No newline at end of file --- 204,206 ---- ! # EOF |
From: Gero K. <gok...@us...> - 2001-09-10 19:53:16
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv9857/php Modified Files: admin_sync.php Log Message: update Index: admin_sync.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/admin_sync.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** admin_sync.php 2001/09/10 16:30:47 1.1 --- admin_sync.php 2001/09/10 19:53:13 1.2 *************** *** 9,12 **** --- 9,158 ---- check_user(); + $table[] = "addresses"; + $table[] = "companies"; + $table[] = "departments"; + $table[] = "location"; + $table[] = "adrloc"; + $table[] = "people"; + $table[] = "teams"; + $table[] = "adrteam"; + $table[] = "calendar"; + $table[] = "products"; + $table[] = "projectclass1"; + $table[] = "projectclass2"; + $table[] = "projectroles"; + $table[] = "installations"; + $table[] = "tasks"; + $table[] = "bugs"; + $table[] = "resources"; + $table[] = "res_use"; + $table[] = "timetrack"; + $table[] = "notes"; + $table[] = "files"; + $table[] = "acl"; + $table[] = "history"; + + /* --------------------------------------------------------------------------- + * + */ + Function copy_all(&$dbconn1,&$dbconn2) { + global $lang,$tutos,$table; + + $dbconn2->Begin("WORK"); + # delete targets + @reset($table); + while ( list ($i,$f) = @each ($table) ) { + $q = "SELECT * from ". $f; + $r = $dbconn1->Exec("SELECT * from ". $f); + $n = $dbconn1->numrows($r); + $fc = $dbconn1->numfields($r); + echo "<B>SOURCE:</B> ". $q ." ===> ". $n ." Entries <BR>\n"; + + $q = "DELETE from ". $f; + $dbconn2->Exec($q); + echo "<B>TARGET:</B> ". $q ."<BR>\n"; + + $a = 0; + while ( $a < $n ) { + $b = 0; + $flds = "INSERT into ". $f .""; + $vals = " VALUES "; + $pre = "("; + while ( $b < $fc ) { + $fv = $dbconn1->result($r,$a,$b); + if ( $fv == "" ) { + $b++; + continue; + } + $ft = $dbconn1->fieldtype($r,$b); + $fn = $dbconn1->fieldname($r,$b); + # OLD VERSION + if ( ($f == "products") && ( ($fn == "manager") || ($fn == "seller") || ($fn == "manager2") ) ) { + $b++; + continue; + } + + $flds .= $pre. $fn; + + if ( ($ft == "varchar") || ($ft == "string") || ($ft == "blob") || ($ft == "text") ) { + $vals .= $pre. $dbconn2->String($fv); + } else if ( $ft == "date" ) { + $dt = new DateTime($fv); + $vals .= $pre. $dbconn2->Date($dt); + } else if ( ($ft == "timestamp") || ($ft == "datetime") ) { + $dt = new DateTime($fv); + $vals .= $pre. $dbconn2->DateTime($dt); + } else if ( eregi("^int",$ft) || ($ft == "real") || ($ft == "float8") ) { + $vals .= $pre. $fv; + } else { + $vals .= $pre."<SPAN CLASS=warn>". $ft. "</SPAN> ". $dbconn1->result($r,$a,$b); + echo $flds . $vals ; + exit; + } + $pre = ","; + $b++; + } + $flds .= ")"; + $vals .= ")"; + $q2 = $flds . $vals; + $dbconn2->Exec($q2); + # echo " $fc ". $q2 ."<BR>\n"; + flush(); + $a++; + } + echo " <===<BR>\n"; + + $dbconn1->freeresult($r); + + flush(); + } + + # Create a tutos_dbs entry of the source database in the target + # there we store the info about this action + + # Delete all other databases + $q = "DELETE from ". $f; + $dbconn2->Exec($q); + echo "<B>TARGET:</B> ". $q ."<BR>\n"; + + # The database is that of dbconn1 but it should use dbconn2 for saving + $dbconn1->db->dbconn = $dbconn2; + # The sync happens now + $dbconn1->db->lastsync = new DateTime(); + $dbconn1->db->save(); + + $dbconn2->Commit("WORK"); + } + /* --------------------------------------------------------------------------- + * + */ + Function info3(&$dbconn,$from,$to,$what) { + global $lang,$tutos; + + $db1 = new database($dbconn); + $db2 = new database($dbconn); + + $db1->read($from); + $db2->read($to); + + echo "<SPAN CLASS=warn>". $lang['AdminDBSyncM'][$what] ."</SPAN><P><P>\n"; + echo "connecting to databases ...<BR>\n"; + flush(); + + $dbconn1 = $db1->getConnection(); + $dbconn2 = $db2->getConnection(); + + if ( $what == 1 ) { + # copyall($dbconn1,$dbconn2); + } else { + echo "<SPAN CLASS=warn>Action :". $lang['AdminDBSyncM'][$what] ." not yet implemented </SPAN>\n"; + } + + echo "disconnecting from databases ...<BR>\n"; + flush(); + + $dbconn1->Close(); + $dbconn2->Close(); + } /* --------------------------------------------------------------------------- * *************** *** 15,18 **** --- 161,177 ---- global $lang,$tutos; + $db1 = new database($dbconn); + $db2 = new database($dbconn); + + $db1->read($from); + $db2->read($to); + + echo "connecting to databases ...<BR>\n"; + flush(); + + $dbconn1 = $db1->getConnection(); + $dbconn2 = $db2->getConnection(); + + $stop = 0; echo "<TABLE CLASS=single BORDER=0 CELLPADDING=3 CELLSPACING=0>\n"; echo "<TR>\n"; *************** *** 25,37 **** echo "</TR>\n"; - $db1 = new database($dbconn); - $db2 = new database($dbconn); - $db1->read($from); - $db2->read($to); - - $dbconn1 = $db1->getConnection(); - $dbconn2 = $db2->getConnection(); - echo "<TR>\n"; echo " <TD> </TD>\n"; --- 184,188 ---- *************** *** 54,59 **** echo "<TR>\n"; showfield($lang['DBCurrID']); ! $seq1 = $dbconn1->getSeqID(); ! $seq2 = $dbconn2->getSeqID(); echo " <TD>". $seq1 ."</TD>\n"; echo " <TD>". $seq2 ."</TD>\n"; --- 205,210 ---- echo "<TR>\n"; showfield($lang['DBCurrID']); ! $seq1 = $dbconn1->NextID(); ! $seq2 = $dbconn2->NextID(); echo " <TD>". $seq1 ."</TD>\n"; echo " <TD>". $seq2 ."</TD>\n"; *************** *** 95,207 **** echo " <TD>". $dbconn2->numrows($r4) ."</TD>\n"; echo "</TR>\n"; - - - echo "</TABLE>\n"; - - $table[] = "addresses"; - $table[] = "companies"; - $table[] = "departments"; - $table[] = "location"; - $table[] = "adrloc"; - $table[] = "people"; - $table[] = "teams"; - $table[] = "adrteam"; - - $table[] = "calendar"; - - $table[] = "products"; - $table[] = "projectclass1"; - $table[] = "projectclass2"; - $table[] = "projectroles"; - $table[] = "installations"; - $table[] = "tasks"; - $table[] = "bugs"; - $table[] = "resources"; - $table[] = "res_use"; - $table[] = "timetrack"; ! $table[] = "notes"; ! # $table[] = "files"; ! ! $table[] = "acl"; ! $table[] = "history"; ! ! return; ! if ( $what == 1 ) { ! $dbconn2->Begin("WORK"); ! # delete targets ! @reset($table); ! while ( list ($i,$f) = @each ($table) ) { ! $q = "SELECT * from ". $f; ! $r = $dbconn1->Exec("SELECT * from ". $f); ! $n = $dbconn1->numrows($r); ! $fc = $dbconn1->numfields($r); ! echo "<B>SOURCE:</B> ". $q ." ===> ". $n ."<BR>\n"; ! ! $q = "DELETE from ". $f; ! $dbconn2->Exec($q); ! echo "<B>TARGET:</B> ". $q ."<BR>\n"; ! ! $a = 0; ! while ( $a < $n ) { ! $b = 0; ! $flds = "INSERT into ". $f .""; ! $vals = " VALUES "; ! $pre = "("; ! while ( $b < $fc ) { ! $fv = $dbconn1->result($r,$a,$b); ! if ( $fv == "" ) { ! $b++; ! continue; ! } ! $ft = $dbconn1->fieldtype($r,$b); ! $fn = $dbconn1->fieldname($r,$b); ! # OLD VERSION ! if ( ($f == "products") && ( ($fn == "manager") || ($fn == "seller") || ($fn == "manager2") ) ) { ! $b++; ! continue; ! } - $flds .= $pre. $fn; - - if ( ($ft == "varchar") || ($ft == "string") || ($ft == "blob") || ($ft == "text") ) { - $vals .= $pre. $dbconn2->String($fv); - } else if ( $ft == "date" ) { - $dt = new DateTime($fv); - $vals .= $pre. $dbconn2->Date($dt); - } else if ( ($ft == "timestamp") || ($ft == "datetime") ) { - $dt = new DateTime($fv); - $vals .= $pre. $dbconn2->DateTime($dt); - } else if ( eregi("^int",$ft) || ($ft == "real") || ($ft == "float8") ) { - $vals .= $pre. $fv; - } else { - $vals .= $pre."<SPAN CLASS=warn>". $ft. "</SPAN> ". $dbconn1->result($r,$a,$b); - echo $flds . $vals ; - exit; - } - $pre = ","; - $b++; - } - $flds .= ")"; - $vals .= ")"; - $q2 = $flds . $vals; - $dbconn2->Exec($q2); - # echo " $fc ". $q2 ."<BR>\n"; - flush(); - $a++; - } - echo " <===<BR>\n"; - - $dbconn1->freeresult($r); ! flush(); ! } ! $dbconn2->Commit("WORK"); } ! $dbconn1->Close(); $dbconn2->Close(); - } /* --------------------------------------------------------------------------- --- 246,301 ---- echo " <TD>". $dbconn2->numrows($r4) ."</TD>\n"; echo "</TR>\n"; ! # Does this make sense ? ! if ( ($what != 1 ) && ($db1->lastsync->notime) ) { ! echo "<TR>\n"; ! showfield(" "); ! echo " <TD COLSPAN=2><SPAN CLASS=warn>You must first sync before update</SPAN></TD>\n"; ! echo "</TR>\n"; ! $stop = 1; ! } ! # Check IDs ! # if the current source ID is below its last sync then a update sync is not possible ! # because it the source was reinstalled or something like this ! if ( ($what != 1 ) && ($seq1 < $db1->lastid) ) { ! echo "<TR>\n"; ! showfield(" "); ! echo " <TD COLSPAN=2><SPAN CLASS=warn>Source out of sync (". $seq1 ." < ". $db1->lastid .")</SPAN></TD>\n"; ! echo "</TR>\n"; ! $stop = 1; ! } ! # if the current target ID is below its last sync then a update sync is not possible ! # because it the target was reinstalled or something like this ! if ( ($what != 1 ) && ($seq2 < $db1->lastid) ) { ! echo "<TR>\n"; ! showfield(" "); ! echo " <TD COLSPAN=2><SPAN CLASS=warn>Target out of sync (". $seq2 ." < ". $db1->lastid .")</SPAN></TD>\n"; ! echo "</TR>\n"; ! $stop = 1; ! } ! if ( $stop == 0 ) { ! echo "<TR>\n"; ! showfield($lang['AdminDBWhat']); ! echo " <TD COLSPAN=2><SPAN CLASS=warn>". $lang['AdminDBSyncM'][$what] ."</SPAN></TD>\n"; ! echo "</TR>\n"; ! ! echo "<TR>\n"; ! echo " <TH COLSPAN=3>\n"; ! echo confirmlink("admin_sync.php?step=3&from=". $from ."&to=". $to ."&what=". $what ,"Are you sure ?","Are you sure"); ! echo " </TH>\n"; ! echo "</TR>\n"; ! } else { ! echo "<TR>\n"; ! echo " <TD COLSPAN=3>\n"; ! echo makelink("admin_sync.php?step=1&from=". $from ."&to=". $to ."&what=". $what ,"Go back","Go back"); ! echo " </TD>\n"; ! echo "</TR>\n"; } ! echo "</TABLE>\n"; $dbconn1->Close(); $dbconn2->Close(); } /* --------------------------------------------------------------------------- *************** *** 209,213 **** */ Function info(&$dbconn) { ! global $lang,$tutos; if ( count($tutos[dbname]) <= 1 ) { --- 303,307 ---- */ Function info(&$dbconn) { ! global $lang,$tutos,$current_user; if ( count($tutos[dbname]) <= 1 ) { *************** *** 243,263 **** echo " <TD>\n"; echo " <SELECT SIZE=5 name=\"what\">\n"; ! echo " <OPTION VALUE=1>remove target than copy all from source</OPTION>\n"; ! echo " <OPTION VALUE=2>copy all new (since last sync) to target</OPTION>\n"; ! echo " <OPTION VALUE=3>copy selected new (since last sync) to target</OPTION>\n"; echo " </SELECT>\n"; echo " </TD>\n"; echo " <TD>\n"; ! echo " <SELECT SIZE=5 name=\"to\">\n"; ! @reset($tutos[dbname]); ! while ( list ($i,$f) = @each ($tutos[dbname]) ) { ! if ( isset($tutos[dbalias][$i]) ) { ! echo "<OPTION VALUE=". $i .">". $tutos[dbalias][$i] ."</OPTION>\n"; ! } else { ! echo "<OPTION VALUE=". $i .">". $tutos[dbname][$i] ."@". $tutos[dbhost][$i] ."</OPTION>\n"; } } - echo " </SELECT>\n"; echo " </TD>\n"; echo "</TR>\n"; --- 337,361 ---- echo " <TD>\n"; echo " <SELECT SIZE=5 name=\"what\">\n"; ! echo " <OPTION VALUE=1>". $lang['AdminDBSyncM'][1]."</OPTION>\n"; ! # echo " <OPTION VALUE=1>". $lang['AdminDBSyncM'][2]."</OPTION>\n"; ! # echo " <OPTION VALUE=1>". $lang['AdminDBSyncM'][3]."</OPTION>\n"; echo " </SELECT>\n"; echo " </TD>\n"; echo " <TD>\n"; ! ! if ( ($current_user->admin != 1) || (count($tutos[dbname]) == 1) ) { ! echo $current_user->dbconn->db->getLink(); ! } else { ! # show local available DBs ! echo " <SELECT SIZE=5 name=\"to\">\n"; ! @reset($dblist); ! while ( list ($i,$f) = @each ($dblist) ) { ! if ( $i < 1000 ) { ! echo "<OPTION VALUE=". $i .">". $i .": ". $f->getFullName() ."</OPTION>\n"; ! } } + echo " </SELECT>\n"; } echo " </TD>\n"; echo "</TR>\n"; *************** *** 285,288 **** --- 383,391 ---- HTML_Select(); } + + # SyncModes + $lang['AdminDBSyncM'][1] = "remove target than copy all from source"; + $lang['AdminDBSyncM'][2] = "copy all new (since last sync) to target"; + $lang['AdminDBSyncM'][3] = "copy selected new (since last sync) to target"; if ( ! isset($step) ) { *************** *** 290,298 **** } if ( !isset($from) ) { ! $from = 0; $step = 1; } if ( !isset($to) ) { ! $to = 0; $step = 1; } --- 393,401 ---- } if ( !isset($from) ) { ! $from = -1; $step = 1; } if ( !isset($to) ) { ! $to = -2; $step = 1; } *************** *** 302,305 **** --- 405,409 ---- } if ( $from == $to ) { + $msg .= "Source and Target must be different !"; $from = 0; $to = 1; *************** *** 316,319 **** --- 420,425 ---- } else if ($step == 2) { info2($dbconn,$from,$to,$what); + } else if ($step == 3) { + info3($dbconn,$from,$to,$what); } HTML_Base3(); |
From: Gero K. <gok...@us...> - 2001-09-10 19:52:53
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv9736/php Modified Files: install.php gantt.php gantt.pinc Log Message: use new db access methods Index: install.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/install.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** install.php 2001/08/22 22:15:01 1.3 --- install.php 2001/09/10 19:52:51 1.4 *************** *** 47,53 **** echo "(you have to create the database or change config.pinc if this test failed !<BR>\n"; $out = 0; ! $conn = DB_Open(0); ! if ( $conn ) { ! echo " Looks OK <I>(". gettype($conn) ." -> ". $conn .")</I> !<BR>\n"; } else { echo "failed to open Database <BR>"; --- 47,53 ---- echo "(you have to create the database or change config.pinc if this test failed !<BR>\n"; $out = 0; ! $dbconn = DB_Open(0); ! if ( $dbconn->conn != -1 ) { ! echo " Looks OK <I>(". $dbconn->gettype() ." -> ". $dbconn->conn .")</I> !<BR>\n"; } else { echo "failed to open Database <BR>"; *************** *** 107,111 **** $q = "SELECT count(*) as c from addresses"; echo " <I>$q</I><BR>\n"; ! $r = @DB_Exec($conn,$q); if ( 1 != DB_NumRows($r)) { echo " <SPAN CLASS=warn>failed</SPAN><BR>\n"; --- 107,111 ---- $q = "SELECT count(*) as c from addresses"; echo " <I>$q</I><BR>\n"; ! $r = $dbconn->Exec($q); if ( 1 != DB_NumRows($r)) { echo " <SPAN CLASS=warn>failed</SPAN><BR>\n"; *************** *** 126,130 **** echo "Start here <A HREF=mytutos.php>mytutos.php</A>"; ! DB_Close($conn); } --- 126,130 ---- echo "Start here <A HREF=mytutos.php>mytutos.php</A>"; ! $dbconn->Close(); } Index: gantt.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/gantt.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** gantt.php 2001/08/30 15:54:51 1.2 --- gantt.php 2001/09/10 19:52:51 1.3 *************** *** 1,278 **** ! <? ! /* ! * Copyright 2001 by Gero Kohnert ! * contributed by Dimitri Manchuelle <dma...@sq...> ! * ! * Display a gantt diagram for tasks/projects ! */ ! include("webelements.p3"); ! include("permission.p3"); ! include("note.pinc"); ! include("url.pinc"); ! include("task.pinc"); ! ! ! if (!Isset($Width) || $Width == 0) { ! //Width of the page ! $PAGEWIDTH = 600; ! } else { ! switch ($Width) { ! case 1: ! $PAGEWIDTH = 600; ! break; ! ! case 2: ! $PAGEWIDTH = 900; ! break; ! ! case 3: ! $PAGEWIDTH = 1200; ! break; ! default: ! $PAGEWIDTH = 600; ! } ! } ! ! if ($chk_Detail == 0) ! //don't want details ! $DETAILS = FALSE; ! else ! // want details ! $DETAILS = TRUE; ! ! if (!Isset($VariableHeight)) { ! $VariableHeight = 2; ! } ! ! // Check if user is allowed to use it ! check_user(); ! ! function Formulaire() { ! global $PHP_SELF, $QUERY_STRING, $chk_Detail,$Width, $VariableHeight; ! $Form = "<br>"; ! $Form .= "<table><tr><td>"; ! $Form .= "<form action=".$PHP_SELF."?".$QUERY_STRING." method=post>"; ! $Form .= " Détail des dates </td>"; ! if ($chk_Detail == 1) ! { ! $Form .= " <td> <input type=checkbox name=chk_Detail value=1 checked></td></tr>"; ! } ! else ! { ! $Form .= " <td> <input type=checkbox name=chk_Detail value=1> </td></tr>"; ! } ! ! $Form .= "<tr><td> Taille d'écran :</td>"; ! $Form .= " <td> <input type=radio name=Width value=1".($Width==1? " checked":"").">petite"; ! $Form .= " <input type=radio name=Width value=2".(($Width==2)||!isset($Width)? " checked":"").">moyenne"; ! $Form .= " <input type=radio name=Width value=3".($Width==3? " checked":"").">grande</td>"; ! $Form .= "</tr>"; ! ! $Form .= "<tr><td> Hauteur des barres :</td>"; ! $Form .= " <td> <input type=radio name=VariableHeight value=1".($VariableHeight==1? " checked":"").">petite"; ! $Form .= " <input type=radio name=VariableHeight value=2".($VariableHeight==2? " checked":"").">moyenne"; ! $Form .= " <input type=radio name=VariableHeight value=3".($VariableHeight==3? " checked":"").">grande"; ! $Form .= " <input type=radio name=VariableHeight value=0".($VariableHeight==0? " checked":"").">proportionnelle au volume horaire</td></tr>"; ! $Form .= "<tr><td> <input type=submit name=button value=\"Modifier l'affichage\"></td>"; ! ! $Form .= "</form>"; ! $Form .= "</table></tr></td>"; ! return $Form; ! } ! ! function getColor(&$task) { ! if ($task->state == 0) ! return "../html/blue.png"; ! if ($task->state == 3) ! return "../html/red.png"; ! if ($task->state == 2) ! return "../html/black.png"; ! if ($task->getcompletion() <= 80) ! return "../html/green.png"; ! ! return "../html/orange.png"; ! } ! ! function getHeight(&$task) { ! global $VariableHeight; ! if ($VariableHeight == 0) { ! return $task->volume; ! } else { ! return $VariableHeight*10; ! } ! } ! ! function diffDate(&$start_date, &$end_date) { ! $length = mktime($end_date->hour, $end_date->min, $end_date->sec, $end_date->month, $end_date->day, $end_date->year) ! - mktime($start_date->hour, $start_date->min, $start_date->sec, $start_date->month, $start_date->day, $start_date->year) ; ! return $length; ! } ! ! function getWidth(&$start_date, &$end_date, $lengthproduct) { ! global $PAGEWIDTH; ! $length = diffDate($start_date, $end_date); ! return round($PAGEWIDTH*($length/$lengthproduct)); ! } ! ! function getInfos(&$task) { ! global $lang; ! ! $Infos = $lang['GanttStart']." : ". $task->s_start->getDate() ."\n"; ! $Infos .= $lang['GanttEnd']." : ". $task->s_end->getDate() ."\n"; ! $Infos .= $lang['GanttVolume']." : ".$task->volume."\n"; ! $Infos .= $lang['GanttCompletion']." : ".$task->getcompletion()." %"; ! return $Infos; ! } ! ! function Diagramme(&$product) { ! global $lang , $conn, $PAGEWIDTH, $DETAILS; ! $workers = array(); ! $order_gantt = array(); ! $start_product = new DateTime(); ! $end_product = new DateTime(); ! ! $product->readTasks(); ! $index_gantt = 0; ! ! if (isset($product->tasklist) && (count($product->tasklist) >0)) { ! //there is at least on task ! @reset($product->tasklist); ! ! //On va compter le nombre d'intervenants et même les coller dans un tableau. si. on est comme ça nous. ! foreach ($product->tasklist as $task) { ! //start of task ! $order_gantt[$index_gantt] = $task->s_start; ! $index_gantt++; ! //end of task ! $order_gantt[$index_gantt] = $task->s_end; ! $index_gantt++; ! } ! @reset($product->tasklist); ! ! //ordering by dates ascending ! asort($order_gantt); ! $start_product = array_shift($order_gantt); ! $end_product = array_pop($order_gantt); ! $lengthproduct = diffDate($start_product, $end_product); ! ! unset($order_gantt); ! ! $Gantt = ""; ! $Gantt .= "<TABLE CELLSPACING=0 CELLSPADING=0 BORDER=".($DETAIL? "1":"0").">"; ! $Gantt .= "<TR>\n"; ! $Gantt .= " <TD WIDTH=150>".$lang[$product->getType()]."</TD>\n"; ! $Gantt .= " <TD ALIGN=LEFT>". $product->getlink() ."</TD>\n"; ! $Gantt .= "</TR>\n"; ! $Gantt .= "<TR><TD COLSPAN=2> </TD></TR>\n"; ! $Gantt .= "<TR><TD COLSPAN=2> </TD></TR>\n"; ! ! //Scale of time ! $Gantt .= "<TR><TD WIDTH=150> </TD><TD>\n"; ! $Gantt .= "<TABLE CELLSPACING=0 CELLSPADING=0 BORDER=0 WIDTH=".($PAGEWIDTH)."><TR>\n"; ! ! //Compute the total number of dates displayed on the scale ! //we assume that we display a date on 50 pixels ! $NumberDates = floor($PAGEWIDTH/50) + 1; ! $step = Round($lengthproduct/$NumberDates); ! ! $start_ts = mktime($start_product->hour, $start_product->min, $start_product->sec, $start_product->month, $start_product->day, $start_product->year); ! $end_ts = mktime($start_product->hour, $end_product->min, $end_product->sec, $end_product->month, $end_product->day, $end_product->year); ! $current_ts = $start_ts; ! ! while ($current_ts < $end_ts) { ! $Gantt .= "<TD><FONT SIZE=1>|".strftime("%d-%m", $current_ts)."</FONT></TD>\n"; ! $current_ts += $step; ! } ! ! $Gantt .= "</TR></TABLE>\n"; ! $Gantt .= "</TD></TR>\n"; ! ! foreach($product->tasklist as $task) { ! $Gantt .= "<TR><TD COLSPAN=2>\n"; ! $Gantt .= "<TABLE CELLSPACING=0 CELLSPADING=0 BORDER=0 WIDTH=".($PAGEWIDTH+150)."><TR>"; ! $Gantt .= "<TD ALIGN=LEFT VALIGN=CENTER ".($DETAILS? " ROWSPAN=2":"")."><FONT SIZE=1>".$task->getLink()." (".$task->worker->getLink().")</FONT></TD>\n"; ! $Height = getHeight($task); ! ! if ($DETAILS) { ! if (diffDate($start_product,$task->s_start) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($start_product, $task->s_start, $lengthproduct)."> </TD>\n"; ! } ! $Gantt .= "<TD ALIGN=LEFT><FONT SIZE=1>|". $task->s_start->getDateShort() ."</FONT></TD>\n"; ! $Gantt .= "<TD ALIGN=RIGHT><FONT SIZE=1>". $task->s_end->getDateShort() ."|</FONT></TD>\n"; ! if (diffDate($task->s_end, $end_product) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($task->s_end, $end_product, $lengthproduct)."> </TD>\n"; ! } ! ! $Gantt .= "</TR>\n"; ! $Gantt .= "<TR>\n"; ! ! if (diffDate($start_product,$task->s_start) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($start_product, $task->s_start, $lengthproduct)."> </TD>\n"; ! } ! ! $Gantt .= "<TD COLSPAN=2><A HREF=".$task->getURL()."><IMG BORDER=0 ALT=\"".getInfos($task)."\" SRC=".getColor($task)." HEIGHT=".$Height." WIDTH=".getWidth($task->s_start, $task->s_end, $lengthproduct)."></A></TD>\n"; ! ! if (diffDate($task->s_end, $end_product) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($task->s_end, $end_product, $lengthproduct)."> </TD>\n"; ! } ! ! } else { ! if (diffDate($start_product,$task->s_start) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($start_product, $task->s_start, $lengthproduct)."> </TD>\n"; ! } ! $Gantt .= "<TD COLSPAN=2><A HREF=".$task->getURL()."><IMG BORDER=0 ALT=\"".getInfos($task)."\" SRC=".getColor($task)." HEIGHT=".$Height." WIDTH=".getWidth($task->s_start, $task->s_end, $lengthproduct)."></A></TD>\n"; ! if (diffDate($task->s_end, $end_product) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($task->s_end, $end_product, $lengthproduct)."> </TD>\n"; ! } ! } ! $Gantt .= "</TR></TABLE></TD></TR>\n"; ! } ! ! $Gantt .= "</TABLE>\n"; ! $Gantt .= "</TD></TR></TABLE>\n"; ! ! return $Gantt; ! } ! return $lang['Err0048']; ! } ! ! ! ! Function navigate($p) { ! global $lang; ! ! echo "<TABLE>"; ! echo "<TR><TD>"; ! echo "</TD></TR>"; ! ! HTML_Select(); ! } ! ! ! HTML_Header($lang['GanttTitle']); ! ! if (isset($id)) { ! $obj = GetObject($id); ! $msg = ""; ! } else { ! $msg = $msg . $lang['Err0048']; ! } ! ! ! HTML_Base1(); ! navigate($obj); ! HTML_Base2($msg); ! ! if ( $msg == "" ) { ! echo Diagramme($obj); ! } ! echo Formulaire(); ! ! HTML_Base3(); ! ! DB_Close($conn); ! ?> ! <!-- ! CVS Info: $Id$ ! $Author$ ! --> --- 1,278 ---- ! <? ! /* ! * Copyright 2001 by Gero Kohnert ! * contributed by Dimitri Manchuelle <dma...@sq...> ! * ! * Display a gantt diagram for tasks/projects ! */ ! include("webelements.p3"); ! include("permission.p3"); ! include("note.pinc"); ! include("url.pinc"); ! include("task.pinc"); ! ! ! if (!Isset($Width) || $Width == 0) { ! //Width of the page ! $PAGEWIDTH = 600; ! } else { ! switch ($Width) { ! case 1: ! $PAGEWIDTH = 600; ! break; ! ! case 2: ! $PAGEWIDTH = 900; ! break; ! ! case 3: ! $PAGEWIDTH = 1200; ! break; ! default: ! $PAGEWIDTH = 600; ! } ! } ! ! if ($chk_Detail == 0) ! //don't want details ! $DETAILS = FALSE; ! else ! // want details ! $DETAILS = TRUE; ! ! if (!Isset($VariableHeight)) { ! $VariableHeight = 2; ! } ! ! // Check if user is allowed to use it ! check_user(); ! ! function Formulaire() { ! global $PHP_SELF, $QUERY_STRING, $chk_Detail,$Width, $VariableHeight; ! $Form = "<br>"; ! $Form .= "<table><tr><td>"; ! $Form .= "<form action=".$PHP_SELF."?".$QUERY_STRING." method=post>"; ! $Form .= " Détail des dates </td>"; ! if ($chk_Detail == 1) ! { ! $Form .= " <td> <input type=checkbox name=chk_Detail value=1 checked></td></tr>"; ! } ! else ! { ! $Form .= " <td> <input type=checkbox name=chk_Detail value=1> </td></tr>"; ! } ! ! $Form .= "<tr><td> Taille d'écran :</td>"; ! $Form .= " <td> <input type=radio name=Width value=1".($Width==1? " checked":"").">petite"; ! $Form .= " <input type=radio name=Width value=2".(($Width==2)||!isset($Width)? " checked":"").">moyenne"; ! $Form .= " <input type=radio name=Width value=3".($Width==3? " checked":"").">grande</td>"; ! $Form .= "</tr>"; ! ! $Form .= "<tr><td> Hauteur des barres :</td>"; ! $Form .= " <td> <input type=radio name=VariableHeight value=1".($VariableHeight==1? " checked":"").">petite"; ! $Form .= " <input type=radio name=VariableHeight value=2".($VariableHeight==2? " checked":"").">moyenne"; ! $Form .= " <input type=radio name=VariableHeight value=3".($VariableHeight==3? " checked":"").">grande"; ! $Form .= " <input type=radio name=VariableHeight value=0".($VariableHeight==0? " checked":"").">proportionnelle au volume horaire</td></tr>"; ! $Form .= "<tr><td> <input type=submit name=button value=\"Modifier l'affichage\"></td>"; ! ! $Form .= "</form>"; ! $Form .= "</table></tr></td>"; ! return $Form; ! } ! ! function getColor(&$task) { ! if ($task->state == 0) ! return "../html/blue.png"; ! if ($task->state == 3) ! return "../html/red.png"; ! if ($task->state == 2) ! return "../html/black.png"; ! if ($task->getcompletion() <= 80) ! return "../html/green.png"; ! ! return "../html/orange.png"; ! } ! ! function getHeight(&$task) { ! global $VariableHeight; ! if ($VariableHeight == 0) { ! return $task->volume; ! } else { ! return $VariableHeight*10; ! } ! } ! ! function diffDate(&$start_date, &$end_date) { ! $length = mktime($end_date->hour, $end_date->min, $end_date->sec, $end_date->month, $end_date->day, $end_date->year) ! - mktime($start_date->hour, $start_date->min, $start_date->sec, $start_date->month, $start_date->day, $start_date->year) ; ! return $length; ! } ! ! function getWidth(&$start_date, &$end_date, $lengthproduct) { ! global $PAGEWIDTH; ! $length = diffDate($start_date, $end_date); ! return round($PAGEWIDTH*($length/$lengthproduct)); ! } ! ! function getInfos(&$task) { ! global $lang; ! ! $Infos = $lang['GanttStart']." : ". $task->s_start->getDate() ."\n"; ! $Infos .= $lang['GanttEnd']." : ". $task->s_end->getDate() ."\n"; ! $Infos .= $lang['GanttVolume']." : ".$task->volume."\n"; ! $Infos .= $lang['GanttCompletion']." : ".$task->getcompletion()." %"; ! return $Infos; ! } ! ! function Diagramme(&$product) { ! global $lang , $PAGEWIDTH, $DETAILS; ! $workers = array(); ! $order_gantt = array(); ! $start_product = new DateTime(); ! $end_product = new DateTime(); ! ! $product->readTasks(); ! $index_gantt = 0; ! ! if (isset($product->tasklist) && (count($product->tasklist) >0)) { ! //there is at least on task ! @reset($product->tasklist); ! ! //On va compter le nombre d'intervenants et même les coller dans un tableau. si. on est comme ça nous. ! foreach ($product->tasklist as $task) { ! //start of task ! $order_gantt[$index_gantt] = $task->s_start; ! $index_gantt++; ! //end of task ! $order_gantt[$index_gantt] = $task->s_end; ! $index_gantt++; ! } ! @reset($product->tasklist); ! ! //ordering by dates ascending ! asort($order_gantt); ! $start_product = array_shift($order_gantt); ! $end_product = array_pop($order_gantt); ! $lengthproduct = diffDate($start_product, $end_product); ! ! unset($order_gantt); ! ! $Gantt = ""; ! $Gantt .= "<TABLE CELLSPACING=0 CELLSPADING=0 BORDER=".($DETAIL? "1":"0").">"; ! $Gantt .= "<TR>\n"; ! $Gantt .= " <TD WIDTH=150>".$lang[$product->getType()]."</TD>\n"; ! $Gantt .= " <TD ALIGN=LEFT>". $product->getlink() ."</TD>\n"; ! $Gantt .= "</TR>\n"; ! $Gantt .= "<TR><TD COLSPAN=2> </TD></TR>\n"; ! $Gantt .= "<TR><TD COLSPAN=2> </TD></TR>\n"; ! ! //Scale of time ! $Gantt .= "<TR><TD WIDTH=150> </TD><TD>\n"; ! $Gantt .= "<TABLE CELLSPACING=0 CELLSPADING=0 BORDER=0 WIDTH=".($PAGEWIDTH)."><TR>\n"; ! ! //Compute the total number of dates displayed on the scale ! //we assume that we display a date on 50 pixels ! $NumberDates = floor($PAGEWIDTH/50) + 1; ! $step = Round($lengthproduct/$NumberDates); ! ! $start_ts = mktime($start_product->hour, $start_product->min, $start_product->sec, $start_product->month, $start_product->day, $start_product->year); ! $end_ts = mktime($start_product->hour, $end_product->min, $end_product->sec, $end_product->month, $end_product->day, $end_product->year); ! $current_ts = $start_ts; ! ! while ($current_ts < $end_ts) { ! $Gantt .= "<TD><FONT SIZE=1>|".strftime("%d-%m", $current_ts)."</FONT></TD>\n"; ! $current_ts += $step; ! } ! ! $Gantt .= "</TR></TABLE>\n"; ! $Gantt .= "</TD></TR>\n"; ! ! foreach($product->tasklist as $task) { ! $Gantt .= "<TR><TD COLSPAN=2>\n"; ! $Gantt .= "<TABLE CELLSPACING=0 CELLSPADING=0 BORDER=0 WIDTH=".($PAGEWIDTH+150)."><TR>"; ! $Gantt .= "<TD ALIGN=LEFT VALIGN=CENTER ".($DETAILS? " ROWSPAN=2":"")."><FONT SIZE=1>".$task->getLink()." (".$task->worker->getLink().")</FONT></TD>\n"; ! $Height = getHeight($task); ! ! if ($DETAILS) { ! if (diffDate($start_product,$task->s_start) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($start_product, $task->s_start, $lengthproduct)."> </TD>\n"; ! } ! $Gantt .= "<TD ALIGN=LEFT><FONT SIZE=1>|". $task->s_start->getDateShort() ."</FONT></TD>\n"; ! $Gantt .= "<TD ALIGN=RIGHT><FONT SIZE=1>". $task->s_end->getDateShort() ."|</FONT></TD>\n"; ! if (diffDate($task->s_end, $end_product) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($task->s_end, $end_product, $lengthproduct)."> </TD>\n"; ! } ! ! $Gantt .= "</TR>\n"; ! $Gantt .= "<TR>\n"; ! ! if (diffDate($start_product,$task->s_start) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($start_product, $task->s_start, $lengthproduct)."> </TD>\n"; ! } ! ! $Gantt .= "<TD COLSPAN=2><A HREF=".$task->getURL()."><IMG BORDER=0 ALT=\"".getInfos($task)."\" SRC=".getColor($task)." HEIGHT=".$Height." WIDTH=".getWidth($task->s_start, $task->s_end, $lengthproduct)."></A></TD>\n"; ! ! if (diffDate($task->s_end, $end_product) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($task->s_end, $end_product, $lengthproduct)."> </TD>\n"; ! } ! ! } else { ! if (diffDate($start_product,$task->s_start) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($start_product, $task->s_start, $lengthproduct)."> </TD>\n"; ! } ! $Gantt .= "<TD COLSPAN=2><A HREF=".$task->getURL()."><IMG BORDER=0 ALT=\"".getInfos($task)."\" SRC=".getColor($task)." HEIGHT=".$Height." WIDTH=".getWidth($task->s_start, $task->s_end, $lengthproduct)."></A></TD>\n"; ! if (diffDate($task->s_end, $end_product) > 0) { ! $Gantt .= "<TD WIDTH=".getWidth($task->s_end, $end_product, $lengthproduct)."> </TD>\n"; ! } ! } ! $Gantt .= "</TR></TABLE></TD></TR>\n"; ! } ! ! $Gantt .= "</TABLE>\n"; ! $Gantt .= "</TD></TR></TABLE>\n"; ! ! return $Gantt; ! } ! return $lang['Err0048']; ! } ! ! ! ! Function navigate($p) { ! global $lang; ! ! echo "<TABLE>"; ! echo "<TR><TD>"; ! echo "</TD></TR>"; ! ! HTML_Select(); ! } ! ! ! HTML_Header($lang['GanttTitle']); ! ! if (isset($id)) { ! $obj = GetObject($dbconn,$id); ! $msg = ""; ! } else { ! $msg = $msg . $lang['Err0048']; ! } ! ! ! HTML_Base1(); ! navigate($obj); ! HTML_Base2($msg); ! ! if ( $msg == "" ) { ! echo Diagramme($obj); ! } ! echo Formulaire(); ! ! HTML_Base3(); ! ! $dbconn->Close(); ! ?> ! <!-- ! CVS Info: $Id$ ! $Author$ ! --> Index: gantt.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/gantt.pinc,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** gantt.pinc 2001/08/30 15:54:52 1.2 --- gantt.pinc 2001/09/10 19:52:51 1.3 *************** *** 1,19 **** ! <? include("Date.pinc"); //constants for gantt.php ! //colors for tasks status ! $taskstatus = array('blank'=>'#FFFFFF', 'blue'=>'#0000FF', 'green'=>'#00FF00', 'orange'=>'#F08000', red=>'FF0000'); ! ! class gantt_avancement ! { ! cfunction gantt_avancement() ! { global $taskstatus; ! $this->gantt_color = $taskstatus['blank']; ! $this->enddate = new DateTime(); ! } ! } ! class gantt_elem { --- 1,19 ---- ! <? include("Date.pinc"); //constants for gantt.php ! //colors for tasks status ! $taskstatus = array('blank'=>'#FFFFFF', 'blue'=>'#0000FF', 'green'=>'#00FF00', 'orange'=>'#F08000', red=>'FF0000'); ! ! class gantt_avancement ! { ! cfunction gantt_avancement() ! { global $taskstatus; ! $this->gantt_color = $taskstatus['blank']; ! $this->enddate = new DateTime(); ! } ! } ! class gantt_elem { *************** *** 32,45 **** /* CLASS GANTT */ /*********************************************************/ ! class gantt ! { ! cfunction gantt(&$product) ! { ! global $lang , $conn; ! $this->workers = array(); ! $this->order_gantt = array(); ! $this->array_gantt = array(); ! $this->productlink = ""; ! $product->readTasks(); $this->productlink = $product->getlink(); --- 32,45 ---- /* CLASS GANTT */ /*********************************************************/ ! class gantt ! { ! cfunction gantt(&$product) ! { ! global $lang; ! $this->workers = array(); ! $this->order_gantt = array(); ! $this->array_gantt = array(); ! $this->productlink = ""; ! $product->readTasks(); $this->productlink = $product->getlink(); |
From: Gero K. <gok...@us...> - 2001-09-10 19:44:11
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv7576/php Modified Files: history_show.php Log Message: new db structure Index: history_show.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/history_show.php,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -r1.15 -r1.16 *** history_show.php 2001/09/10 16:37:54 1.15 --- history_show.php 2001/09/10 19:44:03 1.16 *************** *** 84,88 **** } else if ( $f['field'] == "BugCreate" ) { echo " <TD> </TD>\n"; ! $b = new bug($obj->conn); $b->read($f["new"]); if ( $b->id > 0 ) { --- 84,88 ---- } else if ( $f['field'] == "BugCreate" ) { echo " <TD> </TD>\n"; ! $b = new bug($obj->dbconn); $b->read($f["new"]); if ( $b->id > 0 ) { *************** *** 93,97 **** } else if ( $f['field'] == "InstCreate" ) { echo " <TD> </TD>\n"; ! $b = new installation($obj->conn); $b->read($f["new"]); if ( $b->id > 0 ) { --- 93,97 ---- } else if ( $f['field'] == "InstCreate" ) { echo " <TD> </TD>\n"; ! $b = new installation($obj->dbconn); $b->read($f["new"]); if ( $b->id > 0 ) { *************** *** 102,106 **** } else if ( $f['field'] == "NoteCreate" ) { echo " <TD> </TD>\n"; ! $b = new note($obj->conn); $b->read($f["new"]); if ( $b->id > 0 ) { --- 102,106 ---- } else if ( $f['field'] == "NoteCreate" ) { echo " <TD> </TD>\n"; ! $b = new note($obj->dbconn); $b->read($f["new"]); if ( $b->id > 0 ) { *************** *** 111,115 **** } else if ( $f['field'] == "FileCreate" ) { echo " <TD> </TD>\n"; ! $b = new file($obj->conn); $b->read($f["new"]); if ( $b->id > 0 ) { --- 111,115 ---- } else if ( $f['field'] == "FileCreate" ) { echo " <TD> </TD>\n"; ! $b = new file($obj->dbconn); $b->read($f["new"]); if ( $b->id > 0 ) { *************** *** 120,124 **** } else if ( $f['field'] == "URLAdd" ) { echo " <TD> </TD>\n"; ! $b = new url($obj->conn); $b->read($f["new"]); if ( $b->id > 0 ) { --- 120,124 ---- } else if ( $f['field'] == "URLAdd" ) { echo " <TD> </TD>\n"; ! $b = new url($obj->dbconn); $b->read($f["new"]); if ( $b->id > 0 ) { *************** *** 129,133 **** } else if ( $f['field'] == "TaskCreate" ) { echo " <TD> </TD>\n"; ! $b = new task($obj->conn); $b->read($f["new"]); if ( $b->id > 0 ) { --- 129,133 ---- } else if ( $f['field'] == "TaskCreate" ) { echo " <TD> </TD>\n"; ! $b = new task($obj->dbconn); $b->read($f["new"]); if ( $b->id > 0 ) { |
From: Gero K. <gok...@us...> - 2001-09-10 19:43:29
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv7418/php Modified Files: admin_show.php Log Message: added link to sync Index: admin_show.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/admin_show.php,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -r1.16 -r1.17 *** admin_show.php 2001/09/10 16:57:32 1.16 --- admin_show.php 2001/09/10 19:43:26 1.17 *************** *** 165,169 **** echo "<TABLE>"; echo "<TR><TD>"; ! echo menulink("acl_overview.php","ACL overview","See all access control lists"); echo "</TD></TR>"; --- 165,170 ---- echo "<TABLE>"; echo "<TR><TD>"; ! echo menulink("acl_overview.php",$lang['ACLOverview'],$lang['ACLOverviewI']) ."<BR>\n"; ! echo menulink("admin_sync.php",$lang['AdminDBSync'],$lang['AdminDBSync']) ."<BR>"; echo "</TD></TR>"; |
From: Gero K. <gok...@us...> - 2001-09-10 19:42:52
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv7287/php Modified Files: acl_overview.php Log Message: using language files Index: acl_overview.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/acl_overview.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** acl_overview.php 2001/09/10 16:40:40 1.5 --- acl_overview.php 2001/09/10 19:42:49 1.6 *************** *** 169,173 **** } ! HTML_Header("ACL overview"); $link1 = "acl_overview.php"; --- 169,173 ---- } ! HTML_Header($lang['ACLOverview']); $link1 = "acl_overview.php"; |
From: Gero K. <gok...@us...> - 2001-09-10 19:41:27
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv6834/php Modified Files: database.pinc database_ins.php database_new.php database_show.php scheme.php config.pinc file.pinc Log Message: repository is part of database description Index: database.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/database.pinc,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** database.pinc 2001/09/10 16:30:47 1.1 --- database.pinc 2001/09/10 19:41:24 1.2 *************** *** 56,59 **** --- 56,60 ---- $this->home = ""; $this->type = -1; + $this->repository = "../repository"; $this->creator = $current_user; *************** *** 76,79 **** --- 77,83 ---- $this->home = StripSlashes(DB_Result($result, $pos, "dbhome")); $this->type = StripSlashes(DB_Result($result, $pos, "dbtype")); + $this->repository = StripSlashes(DB_Result($result, $pos, "repository")); + $this->lastsync = new DateTime(DB_Result($result, $pos, "last_date")); + $this->lastid = DB_Result($result, $pos, "last_id"); $this->creator->read(DB_Result($result, $pos, "creator")); *************** *** 163,166 **** --- 167,179 ---- $vals = sprintf("%s,%d",$vals,$this->type); + $flds .= ",repository"; + $vals = sprintf("%s,%s",$vals,$this->dbconn->String($this->repository)); + + $flds .= ",last_date"; + $vals = sprintf("%s,%s",$vals,$this->dbconn->DateTime($this->lastsync)); + + $flds .= ",last_id"; + $vals = sprintf("%s,%d",$vals,$this->lastid); + $flds .= ",creation"; $vals = sprintf("%s,%s",$vals,$this->dbconn->DateTime($this->creation)); *************** *** 190,193 **** --- 203,209 ---- $q .= ",dbhome = ". $this->dbconn->String($this->home); $q .= ",dbtype = ". $this->type; + $q .= ",last_date = ". $this->dbconn->DateTime($this->lastsync); + $q .= ",last_id = ". $this->lastid; + $q .= ",repository = ". $this->dbconn->String($this->repository); $q .= " WHERE id = ". $this->id ; } Index: database_ins.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/database_ins.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** database_ins.php 2001/09/10 16:30:47 1.1 --- database_ins.php 2001/09/10 19:41:24 1.2 *************** *** 46,49 **** --- 46,55 ---- $gotourl = addUrlParameter($gotourl,"pass=". UrlEncode(StripSlashes($pass))); + $pass = trim($home); + $gotourl = addUrlParameter($gotourl,"home=". UrlEncode(StripSlashes($home))); + + $pass = trim($rep); + $gotourl = addUrlParameter($gotourl,"rep=". UrlEncode(StripSlashes($rep))); + if ( $msg == "" ) { $b->name = $name; *************** *** 54,57 **** --- 60,64 ---- $b->pass = $pass; $b->home = $home; + $b->repository = $rep; $b->type = $type; Index: database_new.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/database_new.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** database_new.php 2001/09/10 16:30:47 1.1 --- database_new.php 2001/09/10 19:41:24 1.2 *************** *** 37,41 **** echo "<TR>\n"; showfieldc($lang['AdminDBAlias'],0); ! echo "<TD COLSPAN=4><INPUT SIZE=30 MAXLENGTH=30 name=\"alias\" value=\"". $obj->alias ."\"></TD>\n"; echo "</TR>\n"; --- 37,41 ---- echo "<TR>\n"; showfieldc($lang['AdminDBAlias'],0); ! echo "<TD COLSPAN=4><INPUT SIZE=60 MAXLENGTH=60 name=\"alias\" value=\"". $obj->alias ."\"></TD>\n"; echo "</TR>\n"; *************** *** 49,57 **** echo "<TR>\n"; showfieldc($lang['AdminDBType'],1); ! echo "<TD COLSPAN=1><SELECT SIZE=3 name=\"type\">\n"; echo "<OPTION VALUE=1>Postgres</OPTION>\n"; echo "<OPTION VALUE=4>Postgres 7.1</OPTION>\n"; echo "<OPTION VALUE=2>MySQL</OPTION>\n"; echo "<OPTION VALUE=3>Oracle</OPTION>\n"; echo "</SELECT></TD>\n"; echo "</TR>\n"; --- 49,59 ---- echo "<TR>\n"; showfieldc($lang['AdminDBType'],1); ! echo "<TD COLSPAN=1><SELECT SIZE=1 name=\"type\">\n"; echo "<OPTION VALUE=1>Postgres</OPTION>\n"; echo "<OPTION VALUE=4>Postgres 7.1</OPTION>\n"; echo "<OPTION VALUE=2>MySQL</OPTION>\n"; echo "<OPTION VALUE=3>Oracle</OPTION>\n"; + echo "<OPTION VALUE=5>MS SQL</OPTION>\n"; + echo "<OPTION VALUE=6>Sybase</OPTION>\n"; echo "</SELECT></TD>\n"; echo "</TR>\n"; *************** *** 59,65 **** echo "<TR>\n"; showfieldc($lang['AdminDBUser'],1); ! echo "<TD COLSPAN=1><INPUT SIZE=10 MAXLENGTH=10 name=\"user\" value=\"". $obj->user ."\"></TD>\n"; showfieldc($lang['AdminDBPass'],0); ! echo "<TD COLSPAN=1><INPUT SIZE=10 MAXLENGTH=10 name=\"pass\" value=\"". $obj->pass ."\"></TD>\n"; echo "</TR>\n"; --- 61,77 ---- echo "<TR>\n"; showfieldc($lang['AdminDBUser'],1); ! echo "<TD COLSPAN=1><INPUT SIZE=10 MAXLENGTH=30 name=\"user\" value=\"". $obj->user ."\"></TD>\n"; showfieldc($lang['AdminDBPass'],0); ! echo "<TD COLSPAN=1><INPUT SIZE=10 MAXLENGTH=30 name=\"pass\" value=\"". $obj->pass ."\"></TD>\n"; ! echo "</TR>\n"; ! ! echo "<TR>\n"; ! showfieldc($lang['AdminDBRep'],0); ! echo "<TD COLSPAN=3><INPUT SIZE=60 MAXLENGTH=60 name=\"rep\" value=\"". $obj->repository ."\"></TD>\n"; ! echo "</TR>\n"; ! ! echo "<TR>\n"; ! showfieldc($lang['AdminDBHome'],0); ! echo "<TD COLSPAN=3><INPUT SIZE=60 MAXLENGTH=60 name=\"rep\" value=\"". $obj->home ."\"></TD>\n"; echo "</TR>\n"; Index: database_show.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/database_show.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** database_show.php 2001/09/10 16:30:47 1.1 --- database_show.php 2001/09/10 19:41:24 1.2 *************** *** 35,50 **** echo " <TD COLSPAN=3>". $obj->alias ."</TD>\n"; ! echo "</TR><TR>\n"; ! showfield($lang['AdminDBHost']); ! echo " <TD COLSPAN=1>". $obj->host ." </TD>\n"; ! showfield($lang['AdminDBPort']); ! echo " <TD COLSPAN=1>". $obj->port ." </TD>\n"; ! ! echo "</TR><TR>\n"; ! showfield($lang['AdminDBUser']); ! echo " <TD COLSPAN=1>". $obj->user ." </TD>\n"; ! showfield($lang['AdminDBPass']); ! echo " <TD COLSPAN=1>". $obj->pass ." </TD>\n"; ! echo "</TR><TR>\n"; showfield($lang['DBLastDate']); --- 35,52 ---- echo " <TD COLSPAN=3>". $obj->alias ."</TD>\n"; ! # Do not show sensitive infos ! if ( $current_user->admin == 1 ) { ! echo "</TR><TR>\n"; ! showfield($lang['AdminDBHost']); ! echo " <TD COLSPAN=1>". $obj->host ." </TD>\n"; ! showfield($lang['AdminDBPort']); ! echo " <TD COLSPAN=1>". $obj->port ." </TD>\n"; ! ! echo "</TR><TR>\n"; ! showfield($lang['AdminDBUser']); ! echo " <TD COLSPAN=1>". $obj->user ." </TD>\n"; ! showfield($lang['AdminDBPass']); ! echo " <TD COLSPAN=1>". $obj->pass ." </TD>\n"; ! } echo "</TR><TR>\n"; showfield($lang['DBLastDate']); *************** *** 53,56 **** --- 55,68 ---- echo " <TD COLSPAN=1>". $obj->lastid ."</TD>\n"; + if ( $orbj->type == 3 ) { + echo "</TR><TR>\n"; + showfield($lang['AdminDBHome']); + echo " <TD COLSPAN=3>". $obj->home ."</TD>\n"; + } + if ( ($tutos[usedocmanagement] == 1) ) { + echo "</TR><TR>\n"; + showfield($lang['AdminDBRep']); + echo " <TD COLSPAN=3>". $obj->repository ."</TD>\n"; + } echo "</TR>\n"; *************** *** 93,96 **** --- 105,111 ---- echo menulink("logout.php?db=". $obj->id ,$lang['DBrelogin'],sprintf($lang['DBreloginI'],$obj->getFullName())) ."\n"; } + + echo menulink("admin_sync.php",$lang['AdminDBSync'],$lang['AdminDBSync']) ."<BR>"; + echo "</TD></TR>"; Index: scheme.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/scheme.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** scheme.php 2001/09/10 16:58:13 1.5 --- scheme.php 2001/09/10 19:41:24 1.6 *************** *** 449,452 **** --- 449,453 ---- dbhome varchar(60), dbtype ID_TYPE, + repository varchar(60), last_date TS_TYPE, last_id ID_TYPE, Index: config.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/config.pinc,v retrieving revision 1.68 retrieving revision 1.69 diff -C2 -r1.68 -r1.69 *** config.pinc 2001/08/31 21:29:05 1.68 --- config.pinc 2001/09/10 19:41:24 1.69 *************** *** 43,48 **** # # 1 = "Postgres" 2 = "MySQL" 3 = "Oracle" 4 = "Postgres 7.0" ! $tutos[dbtype][0] = 2; ! $tutos[dbalias][0] = "Test database"; # # Should tutos encrypt passwords with crypt (see db.pinc) --- 43,48 ---- # # 1 = "Postgres" 2 = "MySQL" 3 = "Oracle" 4 = "Postgres 7.0" ! $tutos[dbtype][0] = 1; ! $tutos[dbalias][0] = "Postgres Test database"; # # Should tutos encrypt passwords with crypt (see db.pinc) *************** *** 52,68 **** # this setting !! # ! $tutos[cryptpw][0] = 1; # # You can add more database connections here # (Use comment sign to enable/disable) # ! # $tutos[dbname][1] = "tutos"; ! # $tutos[dbhost][1] = "localhost"; ! # $tutos[dbport][1] = 5432; ! # $tutos[dbuser][1] = "wwwrun"; ! # $tutos[dbpasswd][1] = ""; ! # $tutos[dbtype][1] = 2; ! # $tutos[dbalias][1] = "MYSQL test database"; ! # $tutos[cryptpw][1] = 1; # -------------------------- # $tutos[dbname][2] = "tutos"; --- 52,78 ---- # this setting !! # ! $tutos[cryptpw][0] = 0; # + # The path where tutos stores files + # + # Please create the directory so that the apache user + # can access it and is allowed to make subdirectories + # + # Relative paths start at [tutoshome]/php/ + # + $tutos[repository][0] = "../repository"; + # # You can add more database connections here # (Use comment sign to enable/disable) # ! $tutos[dbname][1] = "tutos"; ! $tutos[dbhost][1] = "localhost"; ! $tutos[dbport][1] = 5432; ! $tutos[dbuser][1] = "wwwrun"; ! $tutos[dbpasswd][1] = ""; ! $tutos[dbtype][1] = 2; ! $tutos[dbalias][1] = "MYSQL test database"; ! $tutos[cryptpw][1] = 1; ! $tutos[repository][1] = "../repository1"; # -------------------------- # $tutos[dbname][2] = "tutos"; *************** *** 74,77 **** --- 84,88 ---- # $tutos[dbalias][2] = "FAUST"; # $tutos[cryptpw][2] = 1; + # $tutos[repository][2] = "../repository2"; # -------------------------- # $tutos[dbname][3] = "webber"; *************** *** 83,86 **** --- 94,98 ---- # $tutos[dbalias][3] = "EA1"; # $tutos[cryptpw][3] = 0; + # $tutos[repository][3] = "../repository3"; # -------------------------- # *************** *** 215,227 **** $tutos[ci] = "/usr/bin/ci"; # - # The path where tutos stores files - # - # Please create the directory so that the apache user - # can access it and is allowed to make subdirectories - # - # Relative paths start at [tutoshome]/php - # - $tutos[repository] = "../repository"; - # # Currencies we know (first one will be default) # (4 Characters) --- 227,230 ---- *************** *** 376,380 **** # (This will fill the messages table and the file $tutos[errlog]) # ! $tutos[debug]=0; # # Where to put the output --- 379,383 ---- # (This will fill the messages table and the file $tutos[errlog]) # ! $tutos[debug]=1; # # Where to put the output *************** *** 402,406 **** # The TUTOS Version number # ! $tutos[version]="20010831"; # $includes[config.pinc] = 1; --- 405,409 ---- # The TUTOS Version number # ! $tutos[version]="20010907"; # $includes[config.pinc] = 1; Index: file.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/file.pinc,v retrieving revision 1.38 retrieving revision 1.39 diff -C2 -r1.38 -r1.39 *** file.pinc 2001/09/10 16:39:04 1.38 --- file.pinc 2001/09/10 19:41:24 1.39 *************** *** 76,85 **** */ function file(&$dbconn) { ! global $current_user, $tutos; $this->id = -1; $this->dbconn = $dbconn; ! $this->base = $tutos[repository]; $this->link_id = -1; $this->name = ""; --- 76,85 ---- */ function file(&$dbconn) { ! global $current_user; $this->id = -1; $this->dbconn = $dbconn; ! $this->base = $dbconn->db->repository; $this->link_id = -1; $this->name = ""; |
From: Gero K. <gok...@us...> - 2001-09-10 19:41:27
|
Update of /cvsroot/tutos/tutos In directory usw-pr-cvs1:/tmp/cvs-serv6834 Modified Files: scheme.sh Log Message: repository is part of database description Index: scheme.sh =================================================================== RCS file: /cvsroot/tutos/tutos/scheme.sh,v retrieving revision 1.28 retrieving revision 1.29 diff -C2 -r1.28 -r1.29 *** scheme.sh 2001/09/10 16:58:13 1.28 --- scheme.sh 2001/09/10 19:41:24 1.29 *************** *** 451,455 **** -- emote TUTOS Databases for syncing -- ! drop table $droparg timetrack; create table tutos_dbs ( id $ID_TYPE primary key, -- a ID --- 451,455 ---- -- emote TUTOS Databases for syncing -- ! drop table $droparg tutos_dbs; create table tutos_dbs ( id $ID_TYPE primary key, -- a ID *************** *** 461,464 **** --- 461,465 ---- dbhome varchar(60), -- path of ora_inst dbtype $ID_TYPE, -- type pg = 1 or 4 mysql = 2 oracle = 3 msql = 5 sybase = 6 + repository varchar(60), -- path for files last_date $TS_TYPE, -- date of last sync last_id $ID_TYPE, -- sequencer id at last sync *************** *** 466,470 **** creation $TS_TYPE not null -- when was it created ); ! create index tutos_dbs_idx1 on tutos_dbs (id); -- -- --- 467,471 ---- creation $TS_TYPE not null -- when was it created ); ! -- -- |
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv6202/php Modified Files: de.p3 en.p3 es.p3 fr.p3 it.p3 ko.p3 nl.p3 pl.p3 ru.p3 tw.p3 zh.p3 pt-br.p3 Log Message: new database strings Index: de.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/de.p3,v retrieving revision 1.68 retrieving revision 1.69 diff -C2 -r1.68 -r1.69 *** de.p3 2001/09/07 09:40:46 1.68 --- de.p3 2001/09/10 19:39:23 1.69 *************** *** 400,403 **** --- 400,405 ---- $lang['ACLmodI'] = "Obige Benutzer/Gruppen dürfen %s ändern"; $lang['ACLdelI'] = "Obige Benutzer/Gruppen dürfen %s löschen"; + $lang['ACLOverview'] = "Rechteübersicht"; + $lang['ACLOverviewI'] = "alle Rechte ansehen"; # Tasks *************** *** 733,741 **** --- 735,764 ---- $lang['AdminDBCount'] = "Einträge"; $lang['AdminDBName'] = "Datenbankname"; + $lang['AdminDBAlias'] = "Datenbankalias"; $lang['AdminDBUser'] = "Datenbankbenutzer"; + $lang['AdminDBPass'] = "Datenbankpasswort"; $lang['AdminDBHost'] = "Rechner"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Letzte Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Datenbankinitialisierung"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: en.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/en.p3,v retrieving revision 1.63 retrieving revision 1.64 diff -C2 -r1.63 -r1.64 *** en.p3 2001/09/07 09:40:46 1.63 --- en.p3 2001/09/10 19:39:23 1.64 *************** *** 400,403 **** --- 400,405 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 733,741 **** --- 735,764 ---- $lang['AdminDBCount'] = "Entries"; $lang['AdminDBName'] = "Database Name"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database User"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recent Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: es.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/es.p3,v retrieving revision 1.48 retrieving revision 1.49 diff -C2 -r1.48 -r1.49 *** es.p3 2001/09/07 09:40:46 1.48 --- es.p3 2001/09/10 19:39:23 1.49 *************** *** 402,405 **** --- 402,407 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 735,743 **** --- 737,767 ---- $lang['AdminDBCount'] = "Entries"; $lang['AdminDBName'] = "Database Name"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database User"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recent Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: fr.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/fr.p3,v retrieving revision 1.47 retrieving revision 1.48 diff -C2 -r1.47 -r1.48 *** fr.p3 2001/09/07 09:40:46 1.47 --- fr.p3 2001/09/10 19:39:23 1.48 *************** *** 402,405 **** --- 402,407 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 735,743 **** --- 737,766 ---- $lang['AdminDBCount'] = "Entrees"; $lang['AdminDBName'] = "Nom de la Base"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Utilisateur de la base"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Hote"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Messages recents"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: it.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/it.p3,v retrieving revision 1.56 retrieving revision 1.57 diff -C2 -r1.56 -r1.57 *** it.p3 2001/09/07 09:40:46 1.56 --- it.p3 2001/09/10 19:39:23 1.57 *************** *** 400,403 **** --- 400,405 ---- $lang['ACLmodI'] = "gli utenti/teams elncati sopra potranno modificare %s"; $lang['ACLdelI'] = "gli utenti/teams elncati sopra potranno cancellare %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 733,741 **** --- 735,764 ---- $lang['AdminDBCount'] = "Voci"; $lang['AdminDBName'] = "Nome del Database"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Utente del Database"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Porta"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Logins recenti"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: ko.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/ko.p3,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -r1.22 -r1.23 *** ko.p3 2001/09/07 09:40:46 1.22 --- ko.p3 2001/09/10 19:39:23 1.23 *************** *** 400,403 **** --- 400,405 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 733,741 **** --- 735,764 ---- $lang['AdminDBCount'] = "Entries"; $lang['AdminDBName'] = "Database Name"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database User"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recent Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: nl.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/nl.p3,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -r1.15 -r1.16 *** nl.p3 2001/09/07 09:40:46 1.15 --- nl.p3 2001/09/10 19:39:23 1.16 *************** *** 402,405 **** --- 402,407 ---- $lang['ACLmodI'] = "Bovenstaande gebruikers/teams mogen wijzigen %s"; $lang['ACLdelI'] = "Bovenstaande gebruikers/teams mogen wissen %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 735,743 **** --- 737,766 ---- $lang['AdminDBCount'] = "Ingaves"; $lang['AdminDBName'] = "Database Naam"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database Gebruiker"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Poort"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recente Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: pl.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/pl.p3,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -r1.20 -r1.21 *** pl.p3 2001/09/07 09:40:46 1.20 --- pl.p3 2001/09/10 19:39:23 1.21 *************** *** 406,409 **** --- 406,411 ---- $lang['ACLmodI'] = "powy¿si u¿ytkownicy/grupy bêd± mogli modyfikowaæ %s"; $lang['ACLdelI'] = "powy¿si u¿ytkownicy/grupy bêd± mogli kasowaæ %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 739,747 **** --- 741,770 ---- $lang['AdminDBCount'] = "Wpisy"; $lang['AdminDBName'] = "Nazwa bazy"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "U¿ytkownik bazy"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Serwer"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Ostatnie logowania"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Inicjalizacja"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: ru.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/ru.p3,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -r1.42 -r1.43 *** ru.p3 2001/09/07 09:40:46 1.42 --- ru.p3 2001/09/10 19:39:23 1.43 *************** *** 400,403 **** --- 400,405 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 733,741 **** --- 735,764 ---- $lang['AdminDBCount'] = "Entries"; $lang['AdminDBName'] = "Database Name"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database User"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recent Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: tw.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/tw.p3,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -r1.42 -r1.43 *** tw.p3 2001/09/07 09:40:46 1.42 --- tw.p3 2001/09/10 19:39:23 1.43 *************** *** 404,407 **** --- 404,409 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 737,745 **** --- 739,768 ---- $lang['AdminDBCount'] = "Entries"; $lang['AdminDBName'] = "Database Name"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database User"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recent Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: zh.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/zh.p3,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -r1.42 -r1.43 *** zh.p3 2001/09/07 09:40:46 1.42 --- zh.p3 2001/09/10 19:39:23 1.43 *************** *** 404,407 **** --- 404,409 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 737,745 **** --- 739,768 ---- $lang['AdminDBCount'] = "Entries"; $lang['AdminDBName'] = "Database Name"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database User"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recent Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions Index: pt-br.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/pt-br.p3,v retrieving revision 1.35 retrieving revision 1.36 diff -C2 -r1.35 -r1.36 *** pt-br.p3 2001/09/07 09:40:46 1.35 --- pt-br.p3 2001/09/10 19:39:23 1.36 *************** *** 402,405 **** --- 402,407 ---- $lang['ACLmodI'] = "above users/teams will be allowed to modify %s"; $lang['ACLdelI'] = "above users/teams will be allowed to delete %s"; + $lang['ACLOverview'] = "Permissions Overview"; + $lang['ACLOverviewI'] = "see all permissions"; # Tasks *************** *** 735,743 **** --- 737,766 ---- $lang['AdminDBCount'] = "Entries"; $lang['AdminDBName'] = "Database Name"; + $lang['AdminDBAlias'] = "Database Alias"; $lang['AdminDBUser'] = "Database User"; + $lang['AdminDBPass'] = "Password"; $lang['AdminDBHost'] = "Host"; $lang['AdminDBPort'] = "Port"; + $lang['AdminDBType'] = "Type"; + $lang['AdminDBHome'] = "ORA_HOME"; $lang['AdminLoginInfo'] = "Recent Logins"; + $lang['AdminDBSync'] = "Database Sync"; + $lang['AdminDBSource'] = "Source DB"; + $lang['AdminDBWhat'] = "What/How"; + $lang['AdminDBTarget'] = "Target DB"; + $lang['AdminDBRep'] = "File Repository"; + + # Database + $lang['DB'] = "Database"; $lang['DBInit'] = "Database Initialization"; + $lang['DBModify'] = "Database Modify"; + $lang['DBModifyI'] = "Modify DB %s"; + $lang['DBCreate'] = "Database Create"; + $lang['DBDetail'] = "Database Detail"; + $lang['DBLastDate'] = "LastSync Date"; + $lang['DBCurrID'] = "ID"; + $lang['DBLastID'] = "LastSync ID"; + $lang['DBrelogin'] = "use Database"; + $lang['DBreloginI'] = "relogin on %s"; # Permissions |
From: Gero K. <gok...@us...> - 2001-09-10 16:58:16
|
Update of /cvsroot/tutos/tutos In directory usw-pr-cvs1:/tmp/cvs-serv26315 Modified Files: scheme.sh Log Message: new DB access and new tutos_dbs table Index: scheme.sh =================================================================== RCS file: /cvsroot/tutos/tutos/scheme.sh,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -r1.27 -r1.28 *** scheme.sh 2001/05/12 05:54:33 1.27 --- scheme.sh 2001/09/10 16:58:13 1.28 *************** *** 449,453 **** --- 449,472 ---- create index timetrack_idx2 on timetrack (link_id); -- + -- emote TUTOS Databases for syncing -- + drop table $droparg timetrack; + create table tutos_dbs ( + id $ID_TYPE primary key, -- a ID + dbname varchar(30) not null, -- database name + dbalias varchar(60), -- short text + dbhost varchar(30), -- hostname + dbuser varchar(30), -- username + dbpass varchar(30), -- password + dbhome varchar(60), -- path of ora_inst + dbtype $ID_TYPE, -- type pg = 1 or 4 mysql = 2 oracle = 3 msql = 5 sybase = 6 + last_date $TS_TYPE, -- date of last sync + last_id $ID_TYPE, -- sequencer id at last sync + creator $ID_TYPE not null, -- who is responsible see adresses(id) + creation $TS_TYPE not null -- when was it created + ); + create index tutos_dbs_idx1 on tutos_dbs (id); + -- + -- -- drop table $droparg messages; *************** *** 508,510 **** # ! # End of file scheme.sh \ No newline at end of file --- 527,529 ---- # ! # End of file scheme.sh |
From: Gero K. <gok...@us...> - 2001-09-10 16:58:16
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv26315/php Modified Files: scheme.php Log Message: new DB access and new tutos_dbs table Index: scheme.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/scheme.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** scheme.php 2001/08/22 22:12:57 1.4 --- scheme.php 2001/09/10 16:58:13 1.5 *************** *** 26,45 **** * */ ! Function createindex($table,$name,$column,$type = "") { ! global $dbtype,$conn; echo "Trying to create index on table <B>". $table ."</B> \n"; flush(); ! DB_Begin($conn,"WORK"); $q = "CREATE ". $type ." index ". $name ." on ". $table ."(". $column .")"; [...1007 lines suppressed...] - ReadLang($lang); - - HTML_Header($lang['DBInit']); if ( ! isset($step) ) { --- 735,738 ---- *************** *** 750,754 **** navigate(); HTML_Base2($msg); ! info($step); HTML_Base3(); ?> --- 743,747 ---- navigate(); HTML_Base2($msg); ! info($dbconn,$step); HTML_Base3(); ?> |
From: Gero K. <gok...@us...> - 2001-09-10 16:57:35
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv26135/php Modified Files: admin_show.php check.php logout.php mytutos.php permission.p3 Log Message: new DB access structure Index: admin_show.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/admin_show.php,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -r1.15 -r1.16 *** admin_show.php 2001/09/07 09:40:46 1.15 --- admin_show.php 2001/09/10 16:57:32 1.16 *************** *** 13,17 **** */ Function getinfo() { ! global $conn, $counts; $counts['calendar'] = 0; --- 13,17 ---- */ Function getinfo() { ! global $dbconn, $counts; $counts['calendar'] = 0; *************** *** 36,47 **** while ( list ($i,$f) = @each ($counts) ) { $q = "SELECT count(*) as c from ". $i; ! $r = @DB_Exec($conn,$q); ! if ( 1 != DB_NumRows($r)) { HTML_Footer(); ! DB_Close($conn); exit; } ! $counts[$i] = DB_Result($r, 0, "c"); ! DB_FreeResult ($r); } } --- 36,47 ---- while ( list ($i,$f) = @each ($counts) ) { $q = "SELECT count(*) as c from ". $i; ! $r = $dbconn->exec($q); ! if ( 1 != $dbconn->NumRows($r)) { HTML_Footer(); ! $dbconn->Close(); exit; } ! $counts[$i] = $dbconn->result($r, 0, "c"); ! $dbconn->FreeResult($r); } } *************** *** 50,54 **** */ Function info() { ! global $current_user,$lang,$counts,$conn,$tutos; if ( $current_user->admin == 0) { --- 50,54 ---- */ Function info() { ! global $current_user,$lang,$counts,$dbconn,$tutos; if ( $current_user->admin == 0) { *************** *** 75,95 **** echo "<TABLE CLASS=single BORDER=0 CELLPADDING=3 CELLSPACING=0>\n"; echo "<TR>\n"; ! echo " <TH COLSPAN=4>". $lang['AdminDBInfo'] ."</TH>\n"; echo "</TR>\n"; echo "<TR>\n"; showfield($lang['AdminDBName']); ! echo " <TD>". $tutos[dbname][$tutos[dbnr]] ."</TD>\n"; showfield($lang['AdminDBUser']); ! echo " <TD>". $tutos[dbuser][$tutos[dbnr]] ."</TD>\n"; echo "</TR>\n"; echo "<TR>\n"; ! if ( $tutos[dbtype][$tutos[dbnr]] == 3 ) { showfield($lang['ProdPath']); ! echo " <TD COLSPAN=3>". $tutos[dbhome][$tutos[dbnr]] ."</TD>\n"; } else { showfield($lang['AdminDBHost']); ! echo " <TD>". $tutos[dbhost][$tutos[dbnr]] ."</TD>\n"; ! showfield($lang['AdminDBPort']); ! echo " <TD>". $tutos[dbport][$tutos[dbnr]] ."</TD>\n"; } echo "</TR>\n"; --- 75,99 ---- echo "<TABLE CLASS=single BORDER=0 CELLPADDING=3 CELLSPACING=0>\n"; echo "<TR>\n"; ! echo " <TH COLSPAN=4>". $lang['AdminDBInfo'] ." : ". $dbconn->db->alias ."</TH>\n"; echo "</TR>\n"; echo "<TR>\n"; showfield($lang['AdminDBName']); ! echo " <TD>". $dbconn->db->name ."</TD>\n"; showfield($lang['AdminDBUser']); ! echo " <TD>". $dbconn->db->user ."</TD>\n"; echo "</TR>\n"; echo "<TR>\n"; ! if ( $dbconn->gettype() == "Oracle" ) { showfield($lang['ProdPath']); ! echo " <TD COLSPAN=3>". $dbconn->db->path ."</TD>\n"; } else { showfield($lang['AdminDBHost']); ! echo " <TD>". $dbconn->db->host ."</TD>\n"; ! if ( $dbconn->gettype() == "Postgres" ) { ! showfield($lang['AdminDBPort']); ! echo " <TD>". $dbconn->db->port ."</TD>\n"; ! } else { ! echo " <TD COLSPAN=2> </TD>\n"; ! } } echo "</TR>\n"; *************** *** 129,134 **** echo "</TR>\n"; $q = "SELECT * from people order by last_seen DESC"; ! $r = @DB_Exec($conn,$q); ! $n = DB_NumRows($r); $a = 0; $line = 1; --- 133,138 ---- echo "</TR>\n"; $q = "SELECT * from people order by last_seen DESC"; ! $r = $dbconn->Exec($q); ! $n = $dbconn->NumRows($r); $a = 0; $line = 1; *************** *** 140,151 **** } echo "<TR CLASS=line". $line .">\n"; ! $adr = new tutos_address($conn); ! $adr->read(DB_Result($r, $a, "adr_id")); ! $uid = DB_Result($r, $a, "id"); echo " <TD>". $adr->getLink() ."</TD>"; ! echo " <TD ALIGN=right>". makelink("user_new.php?id=".$adr->id ,DB_Result($r, $a, "login")) ."</TD>"; ! $ls = new DateTime(DB_Result($r, $a, "last_seen")); echo " <TD>". $ls->getLinkDateTime() ."</TD>"; ! echo " <TD> ". DB_Result($r, $a, "last_host") ."</TD>"; echo "</TR>\n"; $a++; --- 144,155 ---- } echo "<TR CLASS=line". $line .">\n"; ! $adr = new tutos_address($dbconn); ! $adr->read($dbconn->Result($r, $a, "adr_id")); ! $uid = $dbconn->Result($r, $a, "id"); echo " <TD>". $adr->getLink() ."</TD>"; ! echo " <TD ALIGN=right>". makelink("user_new.php?id=".$adr->id ,$dbconn->Result($r, $a, "login")) ."</TD>"; ! $ls = new DateTime($dbconn->Result($r, $a, "last_seen")); echo " <TD>". $ls->getLinkDateTime() ."</TD>"; ! echo " <TD> ". $dbconn->Result($r, $a, "last_host") ."</TD>"; echo "</TR>\n"; $a++; *************** *** 174,180 **** info(); HTML_Base3(); - - DB_Close($conn); ?> <!-- --- 178,183 ---- info(); HTML_Base3(); + $dbconn->close(); ?> <!-- Index: check.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/check.php,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -r1.14 -r1.15 *** check.php 2001/09/04 20:21:28 1.14 --- check.php 2001/09/10 16:57:32 1.15 *************** *** 19,24 **** include("resource.pinc"); ! $conn = DB_Open(); ! $current_user = new tutos_user($conn); $current_user->f_name = "TUTOS"; $current_user->l_name = "(remember service)"; --- 19,24 ---- include("resource.pinc"); ! $dbconn = DB_Open(); ! $current_user = new tutos_user($dbconn); $current_user->f_name = "TUTOS"; $current_user->l_name = "(remember service)"; *************** *** 32,40 **** # $q = "SELECT * FROM calendar WHERE remember > 0 AND remembered = 0"; ! $r = DB_Exec($conn,$q); $n = DB_NumRows($r); $a = 0; while ($a < $n) { ! $app = new appointment($conn); $app->read_result($r,$a); $a++; --- 32,40 ---- # $q = "SELECT * FROM calendar WHERE remember > 0 AND remembered = 0"; ! $r = $dbconn->Exec($q); $n = DB_NumRows($r); $a = 0; while ($a < $n) { ! $app = new appointment($dbconn); $app->read_result($r,$a); $a++; *************** *** 65,69 **** if ( $f->getType() == "address" ) { ! $u = new tutos_user($conn); $u->read($f->id); $appmailtxt = "../html/app_remember.proto.". $u->lang; --- 65,69 ---- if ( $f->getType() == "address" ) { ! $u = new tutos_user($dbconn); $u->read($f->id); $appmailtxt = "../html/app_remember.proto.". $u->lang; *************** *** 96,102 **** # Update the remembered field $q = "UPDATE calendar SET remembered = ". ($app->remembered + 1) ." WHERE ID = ". $app->id; ! $r2 = DB_Exec($conn,$q); } ! DB_FreeResult ($r); # # Checking for OPEN bugs that stay for too long --- 96,102 ---- # Update the remembered field $q = "UPDATE calendar SET remembered = ". ($app->remembered + 1) ." WHERE ID = ". $app->id; ! $r2 = $dbconn->Exec($q); } ! $dbconn->FreeResult ($r); # # Checking for OPEN bugs that stay for too long *************** *** 104,112 **** if ( $tutos[bugremember] > 0 ) { $q = "SELECT * FROM bugs WHERE state = 1"; ! $r = DB_Exec($conn,$q); $n = DB_NumRows($r); $a = 0; while ($a < $n) { ! $b = new bug($conn); $b->read_result($r,$a); $a++; --- 104,112 ---- if ( $tutos[bugremember] > 0 ) { $q = "SELECT * FROM bugs WHERE state = 1"; ! $r = $dbconn->Exec($q); $n = DB_NumRows($r); $a = 0; while ($a < $n) { ! $b = new bug($dbconn); $b->read_result($r,$a); $a++; *************** *** 121,125 **** $q1 = "SELECT * FROM bugremember WHERE id = ". $b->id; ! $r1 = DB_Exec($conn,$q1); $n1 = DB_NumRows($r1); $a1 = 0; --- 121,125 ---- $q1 = "SELECT * FROM bugremember WHERE id = ". $b->id; ! $r1 = $dbconn->Exec($q1); $n1 = DB_NumRows($r1); $a1 = 0; *************** *** 131,136 **** if ( $diff < 0 ) { # still or again need to remember ! $q2 = "INSERT INTO bugremember (id,r_time) VALUES(". $b->id .",". $d->DB_DateTime() .")"; ! $r2 = DB_Exec($conn,$q2); // echo "(new) remember nr ". ($n1 + 1) ."<BR>"; --- 131,136 ---- if ( $diff < 0 ) { # still or again need to remember ! $q2 = "INSERT INTO bugremember (id,r_time) VALUES(". $b->id .",". $dbconn->DateTime($d) .")"; ! $r2 = $dbconn->Exec($q2); // echo "(new) remember nr ". ($n1 + 1) ."<BR>"; *************** *** 151,155 **** if ( $f->getType() == "address" ) { ! $u = new tutos_user($conn); $u->read($f->id); $mailtxt = $bugmailtxt . $u->lang; --- 151,155 ---- if ( $f->getType() == "address" ) { ! $u = new tutos_user($dbconn); $u->read($f->id); $mailtxt = $bugmailtxt . $u->lang; *************** *** 179,183 **** } } ! DB_FreeResult ($r); } --- 179,183 ---- } } ! $dbconn->FreeResult ($r); } *************** *** 187,196 **** $notemailtxt = "../html/note_remember.proto."; $r = new DateTime(); ! $q = "SELECT * FROM notes WHERE remember < ". $r->DB_DateTime() ." "; ! $r = DB_Exec($conn,$q); $n = DB_NumRows($r); $a = 0; while ($a < $n) { ! $x = new note($conn); $x->read_result($r,$a); $x->read_reference(); --- 187,196 ---- $notemailtxt = "../html/note_remember.proto."; $r = new DateTime(); ! $q = "SELECT * FROM notes WHERE remember < ". $dbconn->DateTime($r) ." "; ! $r = $dbconn->Exec($q); $n = DB_NumRows($r); $a = 0; while ($a < $n) { ! $x = new note($dbconn); $x->read_result($r,$a); $x->read_reference(); *************** *** 201,205 **** if ( $x->creator->getType() == "address" ) { ! $u = new tutos_user($conn); $u->read($x->creator->id); $mailtxt = $notemailtxt . $x->creator->lang; --- 201,205 ---- if ( $x->creator->getType() == "address" ) { ! $u = new tutos_user($dbconn); $u->read($x->creator->id); $mailtxt = $notemailtxt . $x->creator->lang; *************** *** 230,234 **** $a++; } ! DB_FreeResult ($r); # # --- 230,234 ---- $a++; } ! $dbconn->FreeResult ($r); # # *************** *** 238,242 **** echo "--> ". $current_user->getFullName() ."<BR>"; } ! DB_Close($conn); session_destroy(); ?> --- 238,242 ---- echo "--> ". $current_user->getFullName() ."<BR>"; } ! $dbconn->Close(); session_destroy(); ?> Index: logout.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/logout.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** logout.php 2001/08/22 22:18:24 1.4 --- logout.php 2001/09/10 16:57:32 1.5 *************** *** 46,52 **** logout(); # Redirect Header("Status: 302 Moved Temporarily"); Header("Location: ". $HTTP_REFERER); ! DB_Close($conn); return; } --- 46,57 ---- logout(); # Redirect + $gotourl = $HTTP_REFERER; + if ( isset($db) ) { + $gotourl= addUrlParameter($gotourl,"db=". $db); + $gotourl= addUrlParameter($gotourl,"msg=RELOGIN"); + } Header("Status: 302 Moved Temporarily"); Header("Location: ". $HTTP_REFERER); ! $dbconn->Close(); return; } *************** *** 57,60 **** info(); HTML_Base3(); ! DB_Close($conn); ?> --- 62,65 ---- info(); HTML_Base3(); ! $dbconn->Close(); ?> Index: mytutos.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/mytutos.php,v retrieving revision 1.36 retrieving revision 1.37 diff -C2 -r1.36 -r1.37 *** mytutos.php 2001/09/07 09:40:46 1.36 --- mytutos.php 2001/09/10 16:57:32 1.37 *************** *** 34,38 **** */ Function calendar_info(&$adr,$t) { ! global $lang,$conn, $tutos, $current_user; $ts = mktime(12,0,0,substr($t,4,2),substr($t,6,2),substr($t,0,4)); --- 34,38 ---- */ Function calendar_info(&$adr,$t) { ! global $lang, $tutos, $current_user; $ts = mktime(12,0,0,substr($t,4,2),substr($t,6,2),substr($t,0,4)); *************** *** 148,152 **** */ Function project_info(&$adr) { ! global $lang,$conn, $tutos; $s = array(); --- 148,152 ---- */ Function project_info(&$adr) { ! global $lang, $tutos; $s = array(); *************** *** 156,160 **** $q .= " (r.adr_id = ". $adr->id .")"; $q .= ") order by creation DESC"; ! $r = @DB_Exec($conn,$q); $n = DB_NumRows($r); $a = 0; --- 156,160 ---- $q .= " (r.adr_id = ". $adr->id .")"; $q .= ") order by creation DESC"; ! $r = $adr->dbconn->Exec($q); $n = DB_NumRows($r); $a = 0; *************** *** 167,171 **** echo " </TR>\n"; while ( ($a < $n) and (count($s) < 2* $tutos[maxshort]) ) { ! $f = new product($conn); $f->read_result($r,$a); if ( isset($s[$f->id]) && ($s[$f->id] == 1) ) { --- 167,171 ---- echo " </TR>\n"; while ( ($a < $n) and (count($s) < 2* $tutos[maxshort]) ) { ! $f = new product($adr->dbconn); $f->read_result($r,$a); if ( isset($s[$f->id]) && ($s[$f->id] == 1) ) { *************** *** 187,191 **** } info_table_end(); ! DB_FreeResult($r); } /* --------------------------------------------------------------------------- --- 187,191 ---- } info_table_end(); ! $adr->dbconn->FreeResult($r); } /* --------------------------------------------------------------------------- *************** *** 193,200 **** */ Function bug_info(&$adr) { ! global $lang,$conn, $tutos; $q = "SELECT * from bugs where (creator = ". $adr->id ." or solver = ". $adr->id .") and state <> 4 order by creation DESC"; ! $r = @DB_Exec($conn,$q); $n = DB_NumRows($r); $a = 0; --- 193,200 ---- */ Function bug_info(&$adr) { ! global $lang, $tutos; $q = "SELECT * from bugs where (creator = ". $adr->id ." or solver = ". $adr->id .") and state <> 4 order by creation DESC"; ! $r = $adr->dbconn->Exec($q); $n = DB_NumRows($r); $a = 0; *************** *** 207,211 **** echo " </TR>\n"; while ( ($a < $n) and ($a < 2* $tutos[maxshort]) ) { ! $f = new bug($conn); $f->read_result($r,$a); echo " <TR>\n"; --- 207,211 ---- echo " </TR>\n"; while ( ($a < $n) and ($a < 2* $tutos[maxshort]) ) { ! $f = new bug($adr->dbconn); $f->read_result($r,$a); echo " <TR>\n"; *************** *** 217,221 **** } info_table_end(); ! DB_FreeResult($r); } /* --------------------------------------------------------------------------- --- 217,221 ---- } info_table_end(); ! $adr->dbconn->FreeResult($r); } /* --------------------------------------------------------------------------- *************** *** 223,230 **** */ Function note_info(&$adr) { ! global $lang, $conn, $tutos; $q = "SELECT * from notes where creator = ". $adr->id ." or link_id = ". $adr->id ." order by creation DESC"; ! $r = @DB_Exec($conn,$q); $n = DB_NumRows($r); $a = 0; --- 223,230 ---- */ Function note_info(&$adr) { ! global $lang, $tutos; $q = "SELECT * from notes where creator = ". $adr->id ." or link_id = ". $adr->id ." order by creation DESC"; ! $r = $adr->dbconn->Exec($q); $n = DB_NumRows($r); $a = 0; *************** *** 237,241 **** echo " </TR>\n"; while ( ($a < $n) and ($a < 2* $tutos[maxshort]) ) { ! $f = new note($conn); $f->read_result($r,$a); $f->read_reference(); --- 237,241 ---- echo " </TR>\n"; while ( ($a < $n) and ($a < 2* $tutos[maxshort]) ) { ! $f = new note($adr->dbconn); $f->read_result($r,$a); $f->read_reference(); *************** *** 248,252 **** } info_table_end(); ! DB_FreeResult($r); } /* --------------------------------------------------------------------------- --- 248,252 ---- } info_table_end(); ! $adr->dbconn->FreeResult($r); } /* --------------------------------------------------------------------------- *************** *** 254,261 **** */ Function file_info(&$adr) { ! global $lang,$conn, $tutos; $q = "SELECT * from files where author = ". $adr->id ." or creator = ". $adr->id ." or link_id = ". $adr->id ." order by creation DESC"; ! $r = @DB_Exec($conn,$q); $n = DB_NumRows($r); $a = 0; --- 254,261 ---- */ Function file_info(&$adr) { ! global $lang, $tutos; $q = "SELECT * from files where author = ". $adr->id ." or creator = ". $adr->id ." or link_id = ". $adr->id ." order by creation DESC"; ! $r = $adr->dbconn->Exec($q); $n = DB_NumRows($r); $a = 0; *************** *** 268,272 **** echo " </TR>\n"; while ( ($a < $n) and ($a < 2* $tutos[maxshort]) ) { ! $f = new file($conn); $f->read_result($r,$a); echo " <TR>\n"; --- 268,272 ---- echo " </TR>\n"; while ( ($a < $n) and ($a < 2* $tutos[maxshort]) ) { ! $f = new file($adr->dbconn); $f->read_result($r,$a); echo " <TR>\n"; *************** *** 278,282 **** } info_table_end(); ! DB_FreeResult($r); } /* --------------------------------------------------------------------------- --- 278,282 ---- } info_table_end(); ! $adr->dbconn->FreeResult($r); } /* --------------------------------------------------------------------------- *************** *** 284,288 **** */ Function mailbox_info(&$adr) { ! global $lang,$conn, $tutos; $adr->readMailboxes(); --- 284,288 ---- */ Function mailbox_info(&$adr) { ! global $lang, $tutos; $adr->readMailboxes(); *************** *** 455,459 **** HTML_Base3(); ! DB_Close($conn); ?> <!-- --- 455,459 ---- HTML_Base3(); ! $dbconn->Close(); ?> <!-- Index: permission.p3 =================================================================== RCS file: /cvsroot/tutos/tutos/php/permission.p3,v retrieving revision 1.40 retrieving revision 1.41 diff -C2 -r1.40 -r1.41 *** permission.p3 2001/09/07 18:47:51 1.40 --- permission.p3 2001/09/10 16:57:32 1.41 *************** *** 26,40 **** session_register('dbnr'); - # session_register(uname); - /* --------------------------------------------------------------------------- * login form */ Function logout () { ! global $current_user, $userid; logmessage("logout: ". $userid); session_unregister('userid'); $userid = -1; session_destroy(); $current_user->id = -1; --- 26,40 ---- session_register('dbnr'); /* --------------------------------------------------------------------------- * login form */ Function logout () { ! global $current_user, $userid, $dbnr; logmessage("logout: ". $userid); session_unregister('userid'); + session_unregister('dbnr'); $userid = -1; + $dbnr = -1; session_destroy(); $current_user->id = -1; *************** *** 45,49 **** */ Function login_form ($gotourl,$msg) { ! global $HTTP_REFERER,$HTTP_GET_VARS,$HTTP_POST_VARS,$uname , $lang,$tutos; if ( !isset($gotourl) ) { --- 45,49 ---- */ Function login_form ($gotourl,$msg) { ! global $HTTP_REFERER,$HTTP_GET_VARS,$HTTP_POST_VARS , $lang,$tutos; if ( !isset($gotourl) ) { *************** *** 71,75 **** # echo $gotourl ."<BR>\n"; ! echo "<FORM ACTION=\"". $gotourl ."\" method=\"POST\">"; hiddenFormElements(); --- 71,75 ---- # echo $gotourl ."<BR>\n"; ! echo "<FORM name=\"login\" ACTION=\"". $gotourl ."\" method=\"POST\">"; hiddenFormElements(); *************** *** 77,81 **** @reset($HTTP_GET_VARS); while ( list ($i,$f) = @each ($HTTP_GET_VARS) ) { ! if ( ($i != "uname") && ($i != "pw") ) { echo "<INPUT type=hidden name=\"". $i ."\" value=\"". $f ."\">"; } --- 77,81 ---- @reset($HTTP_GET_VARS); while ( list ($i,$f) = @each ($HTTP_GET_VARS) ) { ! if ( ($i != "uname") && ($i != "pw") && ($i != "db") ) { echo "<INPUT type=hidden name=\"". $i ."\" value=\"". $f ."\">"; } *************** *** 85,93 **** @reset($HTTP_POST_VARS); while ( list ($i,$f) = @each ($HTTP_POST_VARS) ) { ! if ( ($i != "uname") && ($i != "pw") ) { echo "<INPUT type=hidden name=\"". $i ."\" value=\"". $f ."\">"; } } } DoubleTableStart(); --- 85,99 ---- @reset($HTTP_POST_VARS); while ( list ($i,$f) = @each ($HTTP_POST_VARS) ) { ! if ( ($i != "uname") && ($i != "pw") && ($i != "db") ) { echo "<INPUT type=hidden name=\"". $i ."\" value=\"". $f ."\">"; } } } + if ( isset($HTTP_POST_VARS['db']) ) { + $db = $HTTP_POST_VARS['db']; + } else if ( isset($HTTP_GET_VARS['db']) ) { + $db = $HTTP_GET_VARS['db']; + } + DoubleTableStart(); *************** *** 97,116 **** echo "</TR><TR>\n"; echo " <TD>". $lang['Username'] ."</TD>\n"; ! echo " <TD><INPUT type=text name=uname value=\"". $uname ."\"></TD>\n"; echo "</TR><TR>\n"; echo " <TD>". $lang['Password'] ."</TD>\n"; echo " <TD><INPUT type=password name=pw></TD>\n"; echo "</TR><TR>\n"; ! if ( count($tutos[dbname]) > 1 ) { ! echo " <TD COLSPAN=2 ALIGN=center><SELECT name=\"dbnr\">\n"; ! while ( list ($i,$f) = @each ($tutos[dbname]) ) { ! if ( isset($tutos[dbalias][$i]) ) { ! echo "<OPTION VALUE=$i>". $tutos[dbalias][$i] ."</OPTION>\n"; ! } else { ! echo "<OPTION VALUE=$i>". $tutos[dbname][$i] ."@". $tutos[dbhost][$i] ."</OPTION>\n"; } } - echo "</SELECT></TD>\n"; - echo "</TR><TR>\n"; } echo " <TD COLSPAN=2><INPUT type=submit value=\"". $lang['Login'] ."\"></TD>\n"; --- 103,128 ---- echo "</TR><TR>\n"; echo " <TD>". $lang['Username'] ."</TD>\n"; ! echo " <TD><INPUT type=text name=uname value=\"\"></TD>\n"; echo "</TR><TR>\n"; echo " <TD>". $lang['Password'] ."</TD>\n"; echo " <TD><INPUT type=password name=pw></TD>\n"; echo "</TR><TR>\n"; ! if ( isset($db) ) { ! echo "<INPUT type=hidden name=\"dbnr\" value=\"". $db ."\">"; ! } else { ! if ( count($tutos[dbname]) > 1 ) { ! echo " <TD COLSPAN=2 ALIGN=center><SELECT name=\"dbnr\">\n"; ! while ( list ($i,$f) = @each ($tutos[dbname]) ) { ! if ( isset($tutos[dbalias][$i]) ) { ! echo "<OPTION VALUE=". $i .">". $tutos[dbalias][$i] ."</OPTION>\n"; ! } else { ! echo "<OPTION VALUE=". $i .">". $tutos[dbname][$i] ."@". $tutos[dbhost][$i] ."</OPTION>\n"; ! } } + echo "</SELECT></TD>\n"; + echo "</TR><TR>\n"; + } else { + echo "<INPUT type=hidden name=\"dbnr\" value=\"0\">"; } } echo " <TD COLSPAN=2><INPUT type=submit value=\"". $lang['Login'] ."\"></TD>\n"; *************** *** 142,146 **** */ Function logmessage ($msg) { ! global $conn, $tutos; if ( $tutos[debug] == 0 ) { --- 154,158 ---- */ Function logmessage ($msg) { ! global $dbconn, $tutos; if ( $tutos[debug] == 0 ) { *************** *** 148,158 **** } - # $conn = DB_Open(); $now = new DateTime(); ! $query = "INSERT into messages (ts,message) values (". $now->DB_DateTime() .",". DB_String($msg) .")"; ! $r = DB_Exec($conn,$query); ! ! #@DB_FreeResult ($r); } --- 160,167 ---- } $now = new DateTime(); ! $query = "INSERT into messages (ts,message) values (". $dbconn->DateTime($now) .",". $dbconn->String($msg) .")"; ! $r = $dbconn->Exec($query); } *************** *** 161,204 **** */ Function check_user() { ! global $PHP_SELF ,$PHPSESSID; ! global $lang ,$conn , $current_user,$userid,$uname,$pw,$dbnr,$tutos; set_magic_quotes_runtime(0); ! if ( isset($dbnr) ) { ! $conn = DB_Open($dbnr); ! } else { ! $conn = DB_Open(); } ! ! if ( $tutos[debug] != 0 ) { ! error_reporting(E_ERROR|E_WARNING|E_PARSE); ! set_error_handler("PHP_Error"); } if ( isset($PHPSESSID) ) { session_id($PHPSESSID); ! logmessage("check_user: session ". session_id() ." : ". $PHP_SELF ." userid=". $userid); } else { $PHPSESSID=session_id(); ! logmessage("check_user: new session ". $PHPSESSID ." : ". $PHP_SELF ." userid=". $userid); } if ( ($userid == -1) OR ($userid == "") ) { if ( $uname == "" || $pw == "" ) { /* No Username or no password supplied */ ReadLang($lang); ! logmessage("missing uname or pw "); login_form($PHP_SELF,$lang['Err0025']); HTML_Close(); ! DB_Close($conn); exit; } # logmessage("check_user: ". $uname ."/". $pw ); ! $query = "SELECT a.* ,p.*,p.id as u_id FROM addresses a, people p WHERE p.login = '". trim($uname) ."' AND p.pw = ". DB_Password(trim($pw)) ." AND p.adr_id = a.id"; ! $result = @DB_Exec($conn,$query); if ( ! $result ) { ReadLang($lang); --- 170,226 ---- */ Function check_user() { ! global $PHP_SELF ,$PHPSESSID,$HTTP_POST_VARS,$HTTP_GET_VARS; ! global $lang ,$dbconn , $current_user,$userid,$dbnr,$tutos; + if ( $tutos[debug] != 0 ) { + error_reporting(E_ERROR|E_WARNING|E_PARSE); + set_error_handler("PHP_Error"); + } set_magic_quotes_runtime(0); ! if ( isset($HTTP_POST_VARS['dbnr']) ) { ! $db = $HTTP_POST_VARS['dbnr']; } ! if ( isset($HTTP_POST_VARS['uname']) ) { ! $uname = $HTTP_POST_VARS['uname']; } + if ( isset($HTTP_POST_VARS['pw']) ) { + $pw = $HTTP_POST_VARS['pw']; + } + if ( isset($PHPSESSID) ) { session_id($PHPSESSID); ! #logmessage("check_user: session ". session_id() ." : ". $PHP_SELF ." userid=". $dbnr); } else { $PHPSESSID=session_id(); ! #logmessage("check_user: new session ". $PHPSESSID ." : ". $PHP_SELF ." userid=". $userid); } + if ( ! isset($db) || ($db < 0) ) { + # ReadLang($lang); + # login_form($PHP_SELF,"what db"); + # HTML_Close(); + # exit; + } + + if ( ($userid == -1) OR ($userid == "") ) { if ( $uname == "" || $pw == "" ) { /* No Username or no password supplied */ ReadLang($lang); ! # logmessage("missing uname or pw "); login_form($PHP_SELF,$lang['Err0025']); HTML_Close(); ! # $dbconn->Close(); exit; } + $dbconn = DB_Open($db); # logmessage("check_user: ". $uname ."/". $pw ); ! $query = "SELECT a.* ,p.*,p.id as u_id FROM addresses a, people p WHERE p.login = '". trim($uname) ."' AND p.pw = ". $dbconn->Password(trim($pw)) ." AND p.adr_id = a.id"; ! $result = $dbconn->Exec($query); if ( ! $result ) { ReadLang($lang); *************** *** 206,223 **** login_form($PHP_SELF,$lang['Err0026']); HTML_Close(); ! DB_Close($conn); exit; } /* OK there is a user and a Password so lets check */ ! if ( 1 != DB_NumRows($result)) { ReadLang($lang); ! logmessage("not unique ". DB_NumRows($result) ." Result for ". $uname ." / ". $pw); logmessage($query); login_form($PHP_SELF,$lang['Err0027']); HTML_Close(); ! DB_Close($conn); exit; } ! $current_user= new tutos_user($conn); $current_user->read_result($result,0); $current_user->read_permissions(); --- 228,245 ---- login_form($PHP_SELF,$lang['Err0026']); HTML_Close(); ! $dbconn->Close(); exit; } /* OK there is a user and a Password so lets check */ ! if ( 1 != $dbconn->NumRows($result)) { ReadLang($lang); ! logmessage("not unique ". $dbconn->NumRows($result) ." Result for ". $uname ." / ". $pw); logmessage($query); login_form($PHP_SELF,$lang['Err0027']); HTML_Close(); ! $dbconn->Close(); exit; } ! $current_user= new tutos_user($dbconn); $current_user->read_result($result,0); $current_user->read_permissions(); *************** *** 225,228 **** --- 247,251 ---- $userid = $current_user->id; + $dbnr = $db; $uname = $current_user->login; ReadLang($lang); *************** *** 231,235 **** logmessage("check_user: Logged in ". $userid .":". $uname .":". $current_user->getFullname()); } else { ! $current_user= new tutos_user($conn); $current_user->read($userid); ReadLang($lang); --- 254,260 ---- logmessage("check_user: Logged in ". $userid .":". $uname .":". $current_user->getFullname()); } else { ! # echo "UID:" .$userid ."<BR>\n"; ! $dbconn = DB_Open($dbnr); ! $current_user= new tutos_user($dbconn); $current_user->read($userid); ReadLang($lang); *************** *** 240,244 **** login_form($PHP_SELF,$msg); HTML_Close(); ! DB_Close($conn); exit; } --- 265,269 ---- login_form($PHP_SELF,$msg); HTML_Close(); ! $dbconn->Close(); exit; } *************** *** 260,264 **** login_form($PHP_SELF,$msg); HTML_Close(); ! DB_Close($conn); exit; } --- 285,289 ---- login_form($PHP_SELF,$msg); HTML_Close(); ! $dbconn->Close(); exit; } *************** *** 269,276 **** $x = Date("Z"); # this happens in Default TZ ! DB_TimeZone($current_user->tz); $y = Date("Z"); ! if ( ($tutos[dbtype][$tutos[dbnr]] == 2) || ($tutos[dbtype][$tutos[dbnr]] == 3) ) { $current_user->offset = ($y - $x); } else { --- 294,301 ---- $x = Date("Z"); # this happens in Default TZ ! $dbconn->TimeZone($current_user->tz); $y = Date("Z"); ! if ( ($dbconn->gettype() == "MySQL") || ($dbconn->gettype() == "Oracle") ) { $current_user->offset = ($y - $x); } else { |
From: Gero K. <gok...@us...> - 2001-09-10 16:51:59
|
Update of /cvsroot/tutos/tutos In directory usw-pr-cvs1:/tmp/cvs-serv24420 Modified Files: tutos.spec.in Log Message: first working version ?? Index: tutos.spec.in =================================================================== RCS file: /cvsroot/tutos/tutos/tutos.spec.in,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** tutos.spec.in 2001/09/08 09:41:58 1.1 --- tutos.spec.in 2001/09/10 16:51:56 1.2 *************** *** 3,10 **** # Name: TUTOS ! Version: 20010907 Summary: the ultimate team organisation software Release: 1 ! Source0: tutos-php-%{version}.tar.gz Group: Web/Applications Copyright: GNU GENERAL PUBLIC LICENSE --- 3,10 ---- # Name: TUTOS ! Version: %VERSION% Summary: the ultimate team organisation software Release: 1 ! Source0: tutos-all-%{version}.tar.gz Group: Web/Applications Copyright: GNU GENERAL PUBLIC LICENSE *************** *** 13,20 **** BuildRoot: /var/tmp/%{name}-%{version}.root Packager: Gero Kohnert ! Prefix: /usr/local %description ! TUTOS is a webbased groupware suite that provides the users with - personal and group calendars - addressbook --- 13,20 ---- BuildRoot: /var/tmp/%{name}-%{version}.root Packager: Gero Kohnert ! Prefix: %PREFIX% %description ! TUTOS is a webbased groupware or ERP/CRM suite that provides the users with - personal and group calendars - addressbook *************** *** 36,40 **** #make mv apache.conf apache.conf.orig ! sed -e 's;/home/gero/src/tutos;/usr/local/tutos;g' < apache.conf.orig > apache.conf chmod 755 *.sh --- 36,40 ---- #make mv apache.conf apache.conf.orig ! sed -e 's;/home/gero/src/tutos;%PREFIX%;g' < apache.conf.orig > apache.conf chmod 755 *.sh *************** *** 43,92 **** %install rm -rf $RPM_BUILD_ROOT ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/php ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/html ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/html/blue ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/html/red ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/html/visual ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/html/help ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/homepage ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/documentation ! mkdir -m 755 -p $RPM_BUILD_ROOT/usr/local/tutos/documentation/book0 ! mkdir -m 777 -p $RPM_BUILD_ROOT/usr/local/tutos/repository ! ! ! cp -a php/*.php $RPM_BUILD_ROOT/usr/local/tutos/php/ ! cp -a php/*.p3 $RPM_BUILD_ROOT/usr/local/tutos/php/ ! cp -a php/*.pinc $RPM_BUILD_ROOT/usr/local/tutos/php/ ! cp -a php/.htaccess $RPM_BUILD_ROOT/usr/local/tutos/php/ ! ! cp -a html/blue/* $RPM_BUILD_ROOT/usr/local/tutos/html/blue ! cp -a html/red/* $RPM_BUILD_ROOT/usr/local/tutos/html/red ! cp -a html/visual/* $RPM_BUILD_ROOT/usr/local/tutos/html/visual ! cp -a html/help/* $RPM_BUILD_ROOT/usr/local/tutos/html/help ! cp -a html/.htaccess $RPM_BUILD_ROOT/usr/local/tutos/html ! cp -a html/help/.htaccess $RPM_BUILD_ROOT/usr/local/tutos/html/help ! ! cp -a homepage/install*html $RPM_BUILD_ROOT/usr/local/tutos/homepage ! cp -a documentation/book0/* $RPM_BUILD_ROOT/usr/local/tutos/documentation/book0 ! ! cp -a *.sh $RPM_BUILD_ROOT/usr/local/tutos/ ! cp -a README $RPM_BUILD_ROOT/usr/local/tutos/ ! cp -a INSTALL $RPM_BUILD_ROOT/usr/local/tutos/ ! cp -a apache.conf $RPM_BUILD_ROOT/usr/local/tutos/ %files ! /usr/local/tutos/php ! /usr/local/tutos/html ! /usr/local/tutos/createdb.sh ! /usr/local/tutos/scheme.sh ! /usr/local/tutos/shellfunc.sh ! ! %config /usr/local/tutos/apache.conf ! %doc /usr/local/tutos/README ! %doc /usr/local/tutos/INSTALL ! %doc /usr/local/tutos/homepage/install*html ! %doc /usr/local/tutos/documentation ! %dir /usr/local/tutos/repository %clean --- 43,92 ---- %install rm -rf $RPM_BUILD_ROOT ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/php ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/html ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/html/blue ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/html/red ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/html/visual ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/html/help ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/homepage ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/documentation ! mkdir -m 755 -p $RPM_BUILD_ROOT%PREFIX%/documentation/book0 ! mkdir -m 777 -p $RPM_BUILD_ROOT%PREFIX%/repository ! ! ! cp -a php/*.php $RPM_BUILD_ROOT%PREFIX%/php/ ! cp -a php/*.p3 $RPM_BUILD_ROOT%PREFIX%/php/ ! cp -a php/*.pinc $RPM_BUILD_ROOT%PREFIX%/php/ ! cp -a php/.htaccess $RPM_BUILD_ROOT%PREFIX%/php/ ! ! cp -a html/blue/* $RPM_BUILD_ROOT%PREFIX%/html/blue ! cp -a html/red/* $RPM_BUILD_ROOT%PREFIX%/html/red ! cp -a html/visual/* $RPM_BUILD_ROOT%PREFIX%/html/visual ! cp -a html/help/* $RPM_BUILD_ROOT%PREFIX%/html/help ! cp -a html/.htaccess $RPM_BUILD_ROOT%PREFIX%/html ! cp -a html/help/.htaccess $RPM_BUILD_ROOT%PREFIX%/html/help ! ! cp -a homepage/install*html $RPM_BUILD_ROOT%PREFIX%/homepage ! cp -a documentation/book0/* $RPM_BUILD_ROOT%PREFIX%/documentation/book0 ! ! cp -a *.sh $RPM_BUILD_ROOT%PREFIX%/ ! cp -a README $RPM_BUILD_ROOT%PREFIX%/ ! cp -a INSTALL $RPM_BUILD_ROOT%PREFIX%/ ! cp -a apache.conf $RPM_BUILD_ROOT%PREFIX%/ %files ! %PREFIX%/php ! %PREFIX%/html ! %PREFIX%/createdb.sh ! %PREFIX%/scheme.sh ! %PREFIX%/shellfunc.sh ! ! %config %PREFIX%/apache.conf ! %doc %PREFIX%/README ! %doc %PREFIX%/INSTALL ! %doc %PREFIX%/homepage/install*html ! %doc %PREFIX%/documentation ! %dir %PREFIX%/repository %clean |