Merged revisions 3280-3284 via svnmerge from

svn+ssh://danydb@svn/svn/phpcompta/branches/rel510

........
  r3280 | danydb | 2010-06-11 14:50:28 +0200 (Fri, 11 Jun 2010) | 2 lines
  
  Print the accounting in PDF in the right order
........
  r3281 | danydb | 2010-06-11 17:37:07 +0200 (Fri, 11 Jun 2010) | 2 lines
  
  Improve cosmetic
........
  r3282 | danydb | 2010-06-11 17:38:09 +0200 (Fri, 11 Jun 2010) | 1 line
  
  Add check for restore of folder or template
........
  r3283 | danydb | 2010-06-11 17:46:21 +0200 (Fri, 11 Jun 2010) | 2 lines
  
  truncate table quant_*
........
  r3284 | danydb | 2010-06-11 17:55:18 +0200 (Fri, 11 Jun 2010) | 1 line
  
  Cosmetic : anchorbutton style
........
This commit is contained in:
Dany De Bontridder 2010-06-11 20:01:43 +00:00
parent 110335b08c
commit 002d4ce01a
11 changed files with 198 additions and 28 deletions

BIN
html/image/bg-submit2.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
html/image/bg-submit3.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 982 B

View file

@ -44,7 +44,7 @@ $User->can_request(IMPPOSTE,0);
extract($_GET);
if ( isset ( $poste_fille) ){ //choisit de voir tous les postes
$a_poste=$cn->get_array("select pcm_val from tmp_pcmn where pcm_val::text like '$poste_id%'");
$a_poste=$cn->get_array("select pcm_val from tmp_pcmn where pcm_val::text like '$poste_id%' order by pcm_val");
} else
$a_poste=$cn->get_array("select pcm_val from tmp_pcmn where pcm_val::text = '$poste_id'");

View file

@ -518,6 +518,7 @@ fieldset fieldset legend {
select {
border: 1px solid blue;
margin:2px;
background-color:white;
}
@ -771,4 +772,45 @@ cursor:inherit;
font-color:blue;
margin:1 2 1 2;
}
td.tool {
border: 0;
}
div.topmenu {
float:left;
width:100%;
}
h2.dossier {
color:white;
font-style: oblique;
font-size:15px;
margin:0;
padding:0;
text-align:center;
}
a#anchorbutton {
font-size:10;
color:black;
text-decoration:none;
font-family: helvetica,arial,sans-serif;
background-color:#DFDFDF;
border-style: outset ;
border-color: blue ;
border-width:1;
padding:2 4 2 4;
cursor:pointer;
margin:1 2 1 2;
-moz-border-radius:2 2;
}
a#anchorbutton :hover {
cursor:pointer;
background-color:white;
border-style: inset ;
font-color:blue;
margin:1 2 1 2;
}
/* </style> */

View file

@ -90,9 +90,9 @@ h1.title {
div.u_tmenu {
position: float;
margin-top:1px;
margin-top:0px;
width:100%;
background-color:#879ED4;
/* background-color:#879ED4; */
}
@ -104,7 +104,6 @@ div.u_subtmenu {
}
div.u_tmenu div.u_tool {
background-color:#879ED4;
float:left;
}
@ -753,10 +752,15 @@ cursor:inherit;
.button {
font-size:10;
color:black;
color:white;
font-weight: bold;
text-decoration:none;
font-family: helvetica,arial,sans-serif;
background-color:#DFDFDF;
background-image: url("image/bg-submit3.gif");
background-repeat: repeat-x;
background-position: left;
border-style: outset ;
border-color: blue ;
border-width:1;
@ -773,4 +777,50 @@ cursor:inherit;
font-color:blue;
margin:1 2 1 2;
}
td.tool {
border: solid 1px gray;
}
div.topmenu {
float:left;
width:100%;
}
h2.dossier {
color:darkblue;
font-style: italic;
font-size:14px;
margin:0;
padding:0;
text-align:center;
}
a#anchorbutton {
font-size:10;
color:white;
font-weight: bold;
text-decoration:none;
font-family: helvetica,arial,sans-serif;
background-image: url("image/bg-submit3.gif");
background-repeat: repeat-x;
background-position: left;
border-style: outset ;
border-color: blue ;
border-width:1;
padding:2 4 2 4;
cursor:pointer;
margin:1 2 1 2;
-moz-border-radius:2 2;
}
a#anchorbutton:hover {
cursor:pointer;
background-color:white;
border-style: inset ;
font-color:blue;
margin:1 2 1 2;
}
/* </style> */

View file

@ -17,14 +17,17 @@ table.result {
color:blue;
border:blue solid 1px;
width:100%;
}
table.result th {
font-weight:bold;
font-family:helvetica,arial,sans-serif;
border-bottom:1px solid blue;
border-bottom:0;
padding-left:10px;
padding-right:10px;
background-color: silver;
background-color: #7CBBFF;
color:darkblue;
}
h2 {
@ -210,10 +213,7 @@ table.document th{
background-color:lightgrey;
color:darkblue;
}
table.result th{
background-color:lightgrey;
color:darkblue;
}
span.error {
color:black;
background-color:red;
@ -523,6 +523,7 @@ fieldset fieldset legend {
select {
border: 1px solid blue;
margin:2px;
background-color:white;
}
@ -751,10 +752,17 @@ cursor:inherit;
.button {
font-size:10;
color:black;
color:white;
font-weight: bold;
text-decoration:none;
font-family: helvetica,arial,sans-serif;
background-color:#DFDFDF;
background-image: url("image/bg-submit2.gif");
background-repeat: repeat-x;
background-position: left;
text-decoration:none;
font-family: helvetica,arial,sans-serif;
border-style: outset ;
border-color: blue ;
border-width:1;
@ -771,4 +779,55 @@ cursor:inherit;
font-color:blue;
margin:1 2 1 2;
}
td.tool {
border: 0;
}
div.topmenu {
float:left;
width:100%;
}
h2.dossier {
color:white;
font-style: italic;
font-size:14px;
margin:0;
padding:0;
text-align:center;
}
a#anchorbutton {
font-size:10;
color:white;
font-weight: bold;
text-decoration:none;
font-family: helvetica,arial,sans-serif;
background-image: url("image/bg-submit2.gif");
background-repeat: repeat-x;
background-position: left;
text-decoration:none;
font-family: helvetica,arial,sans-serif;
border-style: outset ;
border-color: blue ;
border-width:1;
padding:2 4 2 4;
cursor:pointer;
margin:1 2 1 2;
-moz-border-radius:2 2;
display:inline;
}
a#anchorbutton:hover{
cursor:pointer;
background-color:white;
border-style: inset ;
font-color:blue;
margin:1 2 1 2;
}
/* </style> */

View file

@ -206,7 +206,7 @@ echo $string => {'prop':'1','prop2':'2','prop3':'3'};
*\return string with htmlcode
*/
static function button_anchor($p_label,$p_value,$p_name="") {
$r=sprintf('<span id="%s"> <A class="button" href="%s" style="color:black;width:75;display:inline">%s</A></span>',
$r=sprintf('<span id="%s"> <A id="anchorbutton" style="display:inline;" href="%s" >%s</A></span>',
$p_name,
$p_value,
$p_label);

View file

@ -118,8 +118,11 @@ if ( isset ($_POST["FMOD_NAME"]) ) {
$Res=$cn_mod->exec_sql('delete from operation_analytique');
// TODO
// Nettoyage table quant_*
$Res=$cn_mod->exec_sql("truncate table jrn_rapt");
$Res=$cn_mod->exec_sql("truncate table quant_fin");
$Res=$cn_mod->exec_sql("truncate table quant_purchase");
$Res=$cn_mod->exec_sql("truncate table quant_sold");
$Res=$cn_mod->exec_sql("truncate table import_tmp");
// Reset the closed periode
$Res=$cn_mod->exec_sql("update parm_periode set p_closed='f'");

View file

@ -36,11 +36,7 @@ echo '<DIV class="content">';
if ( isset($_POST['pass_1'])
&& strlen(trim($_POST['pass_1'])) != 0 ) {
if ($_POST['pass_1'] != $_POST['pass_2'] ) {
?>
<script>
alert(_("Les mots de passe ne correspondent pas. Mot de passe inchangé"));
</script>
<?php
}
else {
$Rep=new Database();

View file

@ -85,9 +85,18 @@ if ( isset ($_REQUEST['sa'] )) {
$cn->exec_sql("create database ".$name." encoding='utf8'");
$args=" --no-owner -d $name ".$_FILES['file']['tmp_name'];
$status=passthru(PG_RESTORE.$args);
echo '<h2 class="info"> Restauration réussie du dossier '.$lname.'</h2>';
exec(PG_RESTORE.$args);
$test=new Database($id);
if ( $test->exist_table('version') ){
echo '<h2 class="info"> Restauration réussie du dossier '.$lname.'</h2>';
$test->close();
} else {
$test->close();
echo '<h2 class="error"> Problème lors de la restauration '.$lname.'</h2>';
$cn->exec_sql('delete from ac_dossier where dos_id=$1',array($id));
$cn->exec_sql('drop database '.$name);
exit();
}
$new_cn=new Database($id);
$new_cn->apply_patch($name,0);
@ -131,7 +140,18 @@ if ( isset ($_REQUEST['sa'] )) {
$args=" -d $name ".$_FILES['file']['tmp_name'];
$status=exec(PG_RESTORE.$args);
echo '<h2 class="info"> Restauration réussie du modèle '.$lname.'</h2>';
$test=new Database($id,'mod');
if ( $test->exist_table('version') ){
echo '<h2 class="info"> Restauration réussie du dossier '.$lname.'</h2>';
$test->close();
} else {
$test->close();
echo '<h2 class="error"> Problème lors de la restauration '.$lname.'</h2>';
$cn->exec_sql('delete from modeledef where mod_id=$1',array($id));
$cn->exec_sql('drop database '.$name);
exit();
}
$new_cn=new Database($id,'mod');
$new_cn->apply_patch($name,0);

View file

@ -202,7 +202,7 @@ function ShowMenuCompta($p_high="")
$str_dossier=dossier::get();
$r="";
$r.=menu_tool("compta.php");
$r.='<div style="float:left;background-color:#879ED4;width:100%;">';
$r.='<div class="topmenu">';
$r.=$result;
$r.='</div>';
@ -431,7 +431,7 @@ function menu_tool($p_from) {
$r.= '<div class="u_tool">';
$r.= '<div class="name">';
$r.= "<H2 class=\"info\"> Dossier : ".h(dossier::name())."</h2> ";
$r.= "<H2 class=\"dossier\"> Dossier : ".h(dossier::name())."</h2> ";
$r.= '</div>';
$r.= '<div class="acces_direct">';
if ( $p_from == 'compta') $view='E';
@ -465,13 +465,13 @@ function menu_tool($p_from) {
$r.='</tr><tr>';
continue;
}
$r.= '<td>'.
$r.= '<td class="tool">'.
'<a class="cell" href="'.$url.'" >'.$col['label'].'</a>'.
'</td>';
}
}
$r.='<td class="mtitle2">';
$r.='<td class="tool">';
$r.= '<A class="cell" HREF="javascript:openRecherche('.$gDossier.')">'.
_('Recherche').'</a></td>';
$r.='</tr>';