[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpcompta-dev] r4208 - in phpcompta/branches: . rel600-dynamic-menu/htm
From: |
phpcompta-dev |
Subject: |
[Phpcompta-dev] r4208 - in phpcompta/branches: . rel600-dynamic-menu/html rel600-dynamic-menu/include rel600-dynamic-menu/include/template |
Date: |
Thu, 13 Oct 2011 22:00:19 +0200 (CEST) |
Author: danydb
Date: 2011-10-13 22:00:17 +0200 (Thu, 13 Oct 2011)
New Revision: 4208
Added:
phpcompta/branches/rel600-dynamic-menu/
Modified:
phpcompta/branches/rel600-dynamic-menu/html/ajax_misc.php
phpcompta/branches/rel600-dynamic-menu/html/extension.php
phpcompta/branches/rel600-dynamic-menu/html/style-light.css
phpcompta/branches/rel600-dynamic-menu/html/user_login.php
phpcompta/branches/rel600-dynamic-menu/include/ac_common.php
phpcompta/branches/rel600-dynamic-menu/include/action.common.inc.php
phpcompta/branches/rel600-dynamic-menu/include/action.inc.php
phpcompta/branches/rel600-dynamic-menu/include/adm.inc.php
phpcompta/branches/rel600-dynamic-menu/include/adm_card.inc.php
phpcompta/branches/rel600-dynamic-menu/include/balance.inc.php
phpcompta/branches/rel600-dynamic-menu/include/balance_card.inc.php
phpcompta/branches/rel600-dynamic-menu/include/class_acc_ledger.php
phpcompta/branches/rel600-dynamic-menu/include/class_action.php
phpcompta/branches/rel600-dynamic-menu/include/class_dossier.php
phpcompta/branches/rel600-dynamic-menu/include/class_fiche.php
phpcompta/branches/rel600-dynamic-menu/include/client.inc.php
phpcompta/branches/rel600-dynamic-menu/include/client_card.inc.php
phpcompta/branches/rel600-dynamic-menu/include/compta_fin.inc.php
phpcompta/branches/rel600-dynamic-menu/include/constant.php
phpcompta/branches/rel600-dynamic-menu/include/fiche.inc.php
phpcompta/branches/rel600-dynamic-menu/include/impress_bilan.inc.php
phpcompta/branches/rel600-dynamic-menu/include/impress_fiche.inc.php
phpcompta/branches/rel600-dynamic-menu/include/impress_gl_comptes.inc.php
phpcompta/branches/rel600-dynamic-menu/include/impress_jrn.inc.php
phpcompta/branches/rel600-dynamic-menu/include/impress_poste.inc.php
phpcompta/branches/rel600-dynamic-menu/include/impress_rapport.inc.php
phpcompta/branches/rel600-dynamic-menu/include/impress_rec.inc.php
phpcompta/branches/rel600-dynamic-menu/include/lettering.gestion.inc.php
phpcompta/branches/rel600-dynamic-menu/include/stock.inc.php
phpcompta/branches/rel600-dynamic-menu/include/stock_inc.php
phpcompta/branches/rel600-dynamic-menu/include/suivi_adm.inc.php
phpcompta/branches/rel600-dynamic-menu/include/suivi_client.inc.php
phpcompta/branches/rel600-dynamic-menu/include/suivi_supplier.inc.php
phpcompta/branches/rel600-dynamic-menu/include/supplier.inc.php
phpcompta/branches/rel600-dynamic-menu/include/supplier_card.inc.php
phpcompta/branches/rel600-dynamic-menu/include/template/dashboard.php
phpcompta/branches/rel600-dynamic-menu/include/user_action_gl.php
phpcompta/branches/rel600-dynamic-menu/include/user_menu.php
Log:
****************************************************
* Modules and Menu are in tables
****************************************************
Copied: phpcompta/branches/rel600-dynamic-menu (from rev 4207, phpcompta/trunk)
Modified: phpcompta/branches/rel600-dynamic-menu/html/ajax_misc.php
===================================================================
--- phpcompta/trunk/html/ajax_misc.php 2011-09-28 14:19:20 UTC (rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/html/ajax_misc.php 2011-10-13
20:00:17 UTC (rev 4208)
@@ -21,7 +21,7 @@
// Copyright Author Dany De Bontridder address@hidden
/*!\file
- * \brief this file respond to an ajax request
+ * \brief this file respond to an ajax request
* The parameters are
* - gDossier
* - $op operation the file has to execute
@@ -286,7 +286,7 @@
$r.='<div style="float:left;">';
// needed hidden var
$r.=dossier::hidden();
- if ( isset($_REQUEST['p_action']))
$r.=HtmlInput::hidden('p_action',$_REQUEST['p_action']);
+ if ( isset($_REQUEST['ac']))
$r.=HtmlInput::hidden('ac',$_REQUEST['ac']);
if ( isset($_REQUEST['sa']))
$r.=HtmlInput::hidden('sa',$_REQUEST['sa']);
if ( isset($_REQUEST['acc']))
$r.=HtmlInput::hidden('acc',$_REQUEST['acc']);
$r.=HtmlInput::hidden('j_id',$j_id);
Modified: phpcompta/branches/rel600-dynamic-menu/html/extension.php
===================================================================
--- phpcompta/trunk/html/extension.php 2011-09-28 14:19:20 UTC (rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/html/extension.php 2011-10-13
20:00:17 UTC (rev 4208)
@@ -55,7 +55,7 @@
$hidden=dossier::hidden();
echo '
<div style="position:absolute;top:3px;right:30px" class="noprint">
- <form method="get" action="access.php" style="display:inline">'.
+ <form method="get" action="do.php" style="display:inline">'.
$hidden;
echo HtmlInput::button_anchor(_('Préférence'),'user_pref.php');
@@ -72,7 +72,7 @@
$msg=_('Retour accueil');
?>
<div style="position:absolute;top:3px;right:30px" class="noprint">
- <form method="get" action="access.php"
style="display:inline">
+ <form method="get" action="do.php"
style="display:inline">
<?php
if ($only_plugin !='P')
echo HtmlInput::button_anchor('Retour Accueil','user_login.php');
Modified: phpcompta/branches/rel600-dynamic-menu/html/style-light.css
===================================================================
--- phpcompta/trunk/html/style-light.css 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/html/style-light.css 2011-10-13
20:00:17 UTC (rev 4208)
@@ -2,7 +2,7 @@
BODY {
background-color:#EDF3FF;
- font-size:10;
+ font-size:10px;
font-family:helvetica,arial,sans-serif;
padding: 0px 10px 0px 10px ;
margin:0;
@@ -18,26 +18,26 @@
width:100%;
border-spacing: 0px;
border-collapse:collapse;
-
+
}
table.resultfooter tfoot {
font-size:110%;
font-weight: bold;
-
-
+
+
}
-table.result th {
+table.result th {
font-weight:bold;
font-family:helvetica,arial,sans-serif;
- border-bottom:2px solid #0000ff;
+ border-bottom:2px solid #0000ff;
border-top:0;
-
+
color:#25238F;
text-align: left;
background-color:#bdbaba;
-
+
font-style: italic;
-
+
}
h2 {
@@ -76,7 +76,7 @@
padding:0px;
margin:0px;
border:1px solid grey;
-
+
}
h3.info {
@@ -107,10 +107,10 @@
div.u_tmenu {
margin-top:0px;
- width:100%;
+ width:100%;
/* background-color:#879ED4; */
-
-
+
+
}
div.u_subtmenu {
background-color:white ;
@@ -121,12 +121,12 @@
}
div.u_tmenu div.u_tool {
float:left;
-
+
}
div.u_tool {
float:left;
width: 100%;
-
+
}
div.u_tool div.name {
float:left;
@@ -136,12 +136,12 @@
float:right;
margin-right:10px;
text-align:right;
-
+
}
div.u_subt2menu {
background-color:lightgrey;
- left:1%;
+ left:1%;
}
div.lmenu {
@@ -172,37 +172,37 @@
border-width:1px;
}
-div.u_redcontent{
- float:left;
+div.u_redcontent{
+ float:left;
padding-top:7px;
padding-left:8px;
- font-size:9px;
- font-family:helvetica,arial,sans-serif;
+ font-size:9px;
+ font-family:helvetica,arial,sans-serif;
width:75%;
}
-div.content{
- float:left;
+div.content{
+ float:left;
padding-top:7px;
- width:100%;
- font-family:helvetica,arial,sans-serif;
+ width:100%;
+ font-family:helvetica,arial,sans-serif;
clear:both;
-
+
}
-div.content30{
- float:left;
+div.content30{
+ float:left;
padding-top:7px;
- width:35%;
- font-family:helvetica,arial,sans-serif;
+ width:35%;
+ font-family:helvetica,arial,sans-serif;
}
div.no span{
position:static;
- font-family:helvetica,arial,sans-serif;
+ font-family:helvetica,arial,sans-serif;
font-weight:bold;
- color:red;
-
+ color:red;
+
}
table.document {
@@ -225,7 +225,7 @@
.error {
width:60%;
margin-left:20%;
-color:white;
+color:white;
background-color:red;
text-align: center;
font-weight: bolder;
@@ -236,7 +236,7 @@
border:0;
text-align:center
}
-td.mshort {
+td.mshort {
height:15px;
width:60px;
text-align:center;
@@ -247,7 +247,7 @@
td.mtitle {
text-align:center;
width:95px;
- height :30px;
+ height :30px;
font-size:10px;
background-color:#DDE6FF;
border:1px solid #99B1DF;
@@ -264,11 +264,11 @@
font-size:10px;
border-style:groove
}
-span.odd {
+span.odd {
background-color:#ECF3FF;
display:block;
}
-span.even {
+span.even {
background-color:#DDE6FF;
display:block;
}
@@ -276,7 +276,7 @@
tr.odd {
background-color:#DDE6FF;
font-size:10px;
- border-width:0px;
+ border-width:0px;
}
tr {
font-size:10px;
@@ -309,16 +309,16 @@
text-decoration:none;
display:inline;
color: #0000ff;
-
+
}
a.mtitle:hover {
font-size:10px;
text-decoration:none;
display:inline;
-
+
color: darkblue;
background-color:#5D90CD;
-
+
}
td.selectedcell a.mtitle {
font-size:1em;
@@ -331,7 +331,7 @@
text-decoration:none;
display:block;
color: #202267;
-
+
}
tr.odd:hover td
{
@@ -339,7 +339,7 @@
background-color: #a9d6e4;
color:white;
}
-tr.even:hover td
+tr.even:hover td
{
text-decoration:none;
background-color: #a9d6e4;
@@ -401,7 +401,7 @@
color: #0000ff;
}
-a.detail:hover
+a.detail:hover
{
font-size:9px;
font-family:helvetica,arial,sans-serif;
@@ -437,7 +437,7 @@
display: block;
color: #0000ff;
padding: 1px ;
-
+
}
@@ -454,7 +454,7 @@
text-decoration:none;
display:inline;
-
+
color:black;
}
@@ -472,9 +472,9 @@
text-decoration:none;
display:inline;
color:#0000ff;
-
+
}
div.content a.mtitle:hover {
@@ -482,17 +482,17 @@
display:inline;
background-color:darkblue;
color:white;
-
+
}
div.u_redcontent input.text {
font-family:helvetica,arial,sans-serif;
font-weight:normal;
border-color:336699;
border-style:solid;
- background-color:orange;
+ background-color:orange;
border-width:1px;
- color:#0000ff;
+ color:#0000ff;
}
div.content input.text {
font-family:helvetica,arial,sans-serif;
@@ -501,7 +501,7 @@
border-style:solid;
border-width:1px;
background-color:orange;
- color:#0000ff;
+ color:#0000ff;
}
@@ -538,12 +538,12 @@
font-weight: bold;
font-style: italic;
font-size: 120% ;
-
+
}
-fieldset fieldset legend {
+fieldset fieldset legend {
font-size:110%;
color:grey;
- }
+ }
select {
border: 1px solid #0000ff;
margin:2px;
@@ -562,12 +562,12 @@
visibility:hidden;
z-index:2;
width:25em;
-
+
}
span.action {
height:3em;
-
+
}
td.num {
text-align:right;
@@ -581,7 +581,7 @@
padding-right:3px;
text-decoration:none;
font-size:14px;
-
+
display:inline;
color:black;
background-color:lightgrey;
@@ -603,7 +603,7 @@
z-index:1;
/*background-color:lightgrey;*/
background-color: rgba(203, 203,203, 0.2);
- display:none;
+ display:none;
}
div.popup_border_title {
@@ -611,7 +611,7 @@
top:20%;
left:10%;
width:60%;
- height:80%;
+ height:80%;
/*background:lightgrey;*/
z-index:10;
/*border:dotted 1px black;*/
@@ -622,19 +622,19 @@
font-style: italic;
font-weight: bolder;
text-align:center;
- /*border-bottom: 2px solid #201e87;*/
+ /*border-bottom: 2px solid #201e87;*/
color: white;
display:none;
/*opacity:1;
filter:alpha(opacity=100);*/
-
+
}
div.popup_border_notitle {
position:absolute;
top:20%;
left:20%;
width:60%;
- height:80% ;
+ height:80% ;
/*background:lightgrey;*/
z-index:10;
/*border:dotted 1px black;*/
@@ -658,9 +658,9 @@
left:0;
right:0;
width:100%;
- height:96%;
+ height:96%;
overflow: auto;
- background-color:#e4e7ed;
+ background-color:#e4e7ed;
font-size:10px ;
font-family: helvetica,arial,sans-serif;
font-style: normal;
@@ -681,7 +681,7 @@
padding:0;
text-align:left;
font-size:12px;
-
+
}
div.autocomplete em {
color:#0000ff;
@@ -729,20 +729,20 @@
margin: 0px;
padding: 0px;
}
-
+
div.pc_calendar{
border:1px groove grey;
float:left;
-
+
}
div.pc_calendar table {
text-align:center;
-
+
}
div.pc_calendar tr{
height:40;
-
-
+
+
}
div.pc_calendar td{
width:10em;
@@ -750,26 +750,26 @@
div.pc_calendar td.weekend {
background-color:#cce0e6;
-
+
}
div.pc_calendar td.workday{
background-color:inherit;
-
-
+
+
}
div.pc_calendar span.day{
font-weight: bold;
display:block;
-
+
}
div.pc_calendar span.event{
font-weight: bolder;
-
+
}
span.todo {
text-align: left;
background-color:yellow;
-
+
}
input[disabled], textarea[disabled], option[disabled], optgroup[disabled],
select[disabled] {
-moz-user-focus:ignore;
@@ -783,13 +783,13 @@
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: #0000ff ;
border-width:0;
@@ -797,7 +797,7 @@
cursor:pointer;
margin:1 2 1 2;
-moz-border-radius:2 2;
-
+
}
.button:hover {
cursor:pointer;
@@ -807,19 +807,20 @@
margin:1 2 1 2;
}
td.tool {
+ background: white;
border: solid 1px gray;
-
+
}
div.topmenu {
float:left;
width:100%;
-
+
}
h2.dossier {
color:darkblue;
font-style: italic;
-
+
font-size:20px;
margin:0;
padding:0;
@@ -829,13 +830,13 @@
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: #0000ff ;
border-width:1;
@@ -843,18 +844,18 @@
cursor:pointer;
margin:1 2 1 2;
-moz-border-radius:2 2;
-
+
}
a#anchorbutton:hover {
cursor:pointer;
background-color:white;
border-style: inset ;
color:#0000ff;
-
+
margin:1 2 1 2;
}
/* </style> */
-div.add_todo_list {
+div.add_todo_list {
border:1px solid #0000ff;
display:none;
background-color:#BFD0FF;
@@ -879,10 +880,10 @@
padding: 5px;
}
div.op_detail_frame {
- background-color:#e4e7ed;
+ background-color:#e4e7ed;
height:100%; width:100%;
-
-
+
+
}
div.op_detail {
background-color:#e4e7ed;
@@ -892,21 +893,21 @@
margin:0;
overflow:hidden;
z-index:3;
-
+
position:absolute;
left:10%;
-border:1px solid darkblue;
+border:1px solid darkblue;
}
div.op_detail_title {
background-color:grey;
/* width:500;*/
-
-
+
+
}
-div#div_jrn{
+div#div_jrn{
position:absolute;
border:1px solid black;
top:15%;left:100;
@@ -914,9 +915,9 @@
z-index:2;
width:50em;
background-color:#EDF3FF;
-
+
}
- div#div_cat{
+ div#div_cat{
position:absolute;
border:1px solid black;
top:15%;left:100;
@@ -924,15 +925,15 @@
z-index:2;
width:50em;
background-color:#EDF3FF;
-
+
}
-
+
div.divinfo
{
color:red;text-align:right;display:block;width:30em;height:13;font-weight:bold}
div#search_form
-{
+{
position:absolute;
border:1px solid black;
top:15%;left:100;
@@ -942,7 +943,7 @@
display:none;
background-color:#e4e7ed;
}
-table.result td
+table.result td
{
padding-left:5px;
padding-right:5px;
Modified: phpcompta/branches/rel600-dynamic-menu/html/user_login.php
===================================================================
--- phpcompta/trunk/html/user_login.php 2011-09-28 14:19:20 UTC (rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/html/user_login.php 2011-10-13
20:00:17 UTC (rev 4208)
@@ -102,7 +102,7 @@
}
else
{
- redirect('access.php?gDossier='.$folder[0]['dos_id']);
+ redirect('do.php?gDossier='.$folder[0]['dos_id']);
exit();
}
}
Modified: phpcompta/branches/rel600-dynamic-menu/include/ac_common.php
===================================================================
--- phpcompta/trunk/include/ac_common.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/ac_common.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -602,7 +602,7 @@
/**
address@hidden try to determine on what os you are running the pĥpcompte
*server
- address@hidden
+ address@hidden
* 0 it is a windows
* 1 it is a Unix like
*/
@@ -687,4 +687,46 @@
exit();
}
}
+/**
+ *
+ * @param int $selected module selected
+ */
+function show_module($selected)
+{
+ $cn=Dossier::connect();
+ $amodule=$cn->get_array("select m_code,m_menu,m_url from module order by
m_order");
+ require_once('template/module.php');
+ if ( $selected != -1 )
+ {
+ $file=$cn->get_value("select m_file from module where
m_code=$1",array($selected));
+ if ($file != '')
+ require_once $file;
+ }
+
+}
+/**
+ * show default module
+ */
+function show_default()
+{
+ $cn=Dossier::connect();
+ $file=$cn->get_array('SELECT m_code FROM module where m_default=1');
+ if (! empty ($file) )
+ {
+ $selected=$file[0]['m_code'];
+ show_module($selected);
+ }
+}
+/**
+ *
+ */
+function show_menu($module)
+{
+ $cn=Dossier::connect();
+ $amenu=$cn->get_array("select me_id,me_menu from menu
+ join menu_ref using (me_code)
+ join module using (m_code) where
+ m_code=$1 order by me_order",array($module[0]));
+ require_once 'template/menu.php';
+}
?>
Modified: phpcompta/branches/rel600-dynamic-menu/include/action.common.inc.php
===================================================================
--- phpcompta/trunk/include/action.common.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/action.common.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -25,7 +25,6 @@
* administration.
* The needed variables are
* - $cn for the database connection
- * - $p_action the $_REQUEST['p_action']
* - $sub_action sa from suivi courrier but sc from Suivi client,
fournisseur...
*
*/
@@ -37,6 +36,7 @@
$supl_hidden.=HtmlInput::hidden('f_id',$_REQUEST['f_id']);
if( isset($_REQUEST['sb']))
$supl_hidden.=HtmlInput::hidden('sb',$_REQUEST['sb']);
+ $supl_hidden.=HtmlInput::hidden('ac',$_REQUEST['ac']);
/*---------------------------------------------------------------------------
*/
/* We ask to generate the document */
@@ -114,14 +114,14 @@
echo '<div class="content">';
// Add hidden tag
- echo '<form enctype="multipart/form-data" action="commercial.php"
method="post"">';
+ echo '<form enctype="multipart/form-data" action="do.php"
method="post"">';
echo dossier::hidden();
$act->ag_comment="";
if (isset($_REQUEST['qcode_dest']))
$act->qcode_dest=$_REQUEST['qcode_dest'];
echo $act->Display('NEW',false,$base,$retour);
- echo '<input type="hidden" name="p_action" value="'.$p_action.'">';
+ echo '<input type="hidden" name="ac" value="'.$_REQUEST['ac'].'">';
echo '<input type="hidden" name="sa" value="save_action_st2">';
echo '<input type="submit" class="button" name="save_action_st2"
value="'._('Enregistrer').'">';
echo '<input type="submit" class="button" name="generate"
value="'._('Génère le document').'"></p>';
@@ -143,12 +143,11 @@
$act->ag_id=$ag_id;
echo $act->get();
$act->ag_comment=Decode($act->ag_comment);
- echo '<form enctype="multipart/form-data" class="print"
action="commercial.php" method="post" >';
+ echo '<form enctype="multipart/form-data" class="print" action="do.php"
method="post" >';
echo $supl_hidden;
- echo HtmlInput::hidden('p_action',$_REQUEST['p_action']);
+ echo HtmlInput::hidden('ac',$_REQUEST['ac']);
echo dossier::hidden();
echo $act->Display('UPD',false,$base,$retour);
- echo '<input type="hidden" name="p_action" value="'.$p_action.'">';
echo '<input type="hidden" name="sa" value="update">';
echo HtmlInput::submit("save","Sauve");
echo HtmlInput::submit("add_action_here",_("Ajoute une action à
celle-ci"));
@@ -191,7 +190,7 @@
$act->d_id=0;
echo '<div class="content">';
// Add hidden tag
- echo '<form method="post" action="commercial.php" name="form_add"
id="form_add" enctype="multipart/form-data" >';
+ echo '<form method="post" action="do.php" name="form_add" id="form_add"
enctype="multipart/form-data" >';
echo $supl_hidden;
echo dossier::hidden();
@@ -200,7 +199,7 @@
if (isset($_REQUEST['qcode'])) $act->qcode_dest=$_REQUEST['qcode'];
echo $act->Display('NEW',false,$base,$retour);
- echo '<input type="hidden" name="p_action" value="'.$p_action.'">';
+ echo '<input type="hidden" name="ac" value="'.$_REQUEST["ac"].'">';
echo '<input type="hidden" name="sa" value="save_action_st2">';
echo '<input type="hidden" name="save_action_st2"
value="save_action_st2">';
echo '<input type="submit" class="button" name="save_action_st2"
value="'._('Enregistrer').'">';
@@ -224,8 +223,8 @@
echo $act->save();
$url="?$base&sa=detail&ag_id=".$act->ag_id.'&'.dossier::get();
echo '<p><a class="mtitle" href="'.$url.'">'.hb('Action Sauvée :
'.$act->ag_ref).'</a></p>';
-
+
ShowActionList($cn,$base);
$url="?$base&sa=detail&ag_id=".$act->ag_id.'&'.dossier::get();
echo '<p><a class="mtitle" href="'.$url.'">'.hb('Action Sauvée :
'.$act->ag_ref).'</a></p>';
@@ -240,7 +239,7 @@
<legend>
<?=_('Recherche avancée')?>
</legend>
- <form method="get" action="commercial.php">
+ <form method="get" action="do.php">
<?php
echo dossier::hidden();
$a=(isset($_GET['query']))?$_GET['query']:"";
@@ -257,6 +256,7 @@
}
if( isset($_REQUEST['sb']))
$supl_hidden.=HtmlInput::hidden('sb',$_REQUEST['sb']);
+ $supl_hidden.=HtmlInput::hidden('ac',$_REQUEST['ac']);
$w=new ICard();
$w->name='qcode';
@@ -284,7 +284,10 @@
$see_all=new ICheckBox('see_all');
$my_action=new ICheckBox('all_action');
- if ( $_REQUEST ['p_action'] != 'suivi_courrier')
+/**
+ * @todo
+ * if ( $_REQUEST ['p_action'] != 'suivi_courrier')
+ *
{
$see_all->selected=true;
$my_action->selected= true;
@@ -294,13 +297,15 @@
$see_all->selected=(isset($_REQUEST ['see_all']))?true:false;
$my_action->selected= (isset($_REQUEST ['all_action']))?true:false;
}
+ *
+ */
echo _('les actions fermées aussi:').$see_all->input().'<br/>';
echo _('affecté à d\'autre:').$my_action->input().'<br/>';
?>
<input type="submit" class="button" name="submit_query"
value="<?=_('recherche')?>">
<input type="hidden" name="sa" value="list">
- <input type="hidden" name="p_action" value="<?=$_REQUEST['p_action']?>">
+
<?=$supl_hidden?>
</form>
@@ -309,11 +314,11 @@
<div class="content" >
<span style="float:left">
- <form method="get" action="commercial.php">
+ <form method="get" action="do.php">
<?php echo dossier::hidden();
?>
<input type="submit" class="button" name="submit_query"
value="<?=_("Ajout Action")?>">
- <input type="hidden" name="p_action"
value="<?=$_REQUEST['p_action']?>">
+ <input type="hidden" name="ac" value="<?=$_REQUEST['ac']?>">
<input type="hidden" name="sa" value="add_action">
<?=$supl_hidden?>
<input id="bt_search" type="button" class="button"
onclick="toggleShow(this,'<?=_('Afficher Recherche')?>','<?=_('Cache
Recherche')?>','search_action')" value="">
Modified: phpcompta/branches/rel600-dynamic-menu/include/action.inc.php
===================================================================
--- phpcompta/trunk/include/action.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/action.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -22,7 +22,7 @@
* \brief Page who manage the different actions (meeting, letter)
*/
require_once('class_ipopup.php');
-
+global $User;
$User->can_request(GECOUR);
$retour=HtmlInput::button_anchor(_('Retour'),'?p_action=suivi_courrier&my_action&'.dossier::get());
@@ -53,8 +53,8 @@
* with the generation of document
*/
$ag_id=(isset($_REQUEST['ag_id']))?$_REQUEST['ag_id']:0;
-$p_action=$_REQUEST['p_action'];
-$base='p_action='.$p_action;
+$ac=$_REQUEST['ac'];
+$base='ac='.$ac;
require_once('action.common.inc.php');
echo "</div>";
Modified: phpcompta/branches/rel600-dynamic-menu/include/adm.inc.php
===================================================================
--- phpcompta/trunk/include/adm.inc.php 2011-09-28 14:19:20 UTC (rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/adm.inc.php 2011-10-13
20:00:17 UTC (rev 4208)
@@ -31,13 +31,9 @@
require_once('class_fiche_def.php');
require_once('class_ipopup.php');
require_once('class_admin.php');
-echo js_include('accounting_item.js');
-echo js_include('prototype.js');
-echo js_include('scriptaculous.js');
-echo js_include('effects.js');
-echo js_include('controls.js');
-echo js_include('dragdrop.js');
+global $User;
+
$low_action=(isset($_REQUEST['sb']))?$_REQUEST['sb']:"list";
/*! \file
* \brief Called from the module "Gestion" to manage the customer
@@ -136,7 +132,7 @@
}
/*----------------------------------------------------------------------
* Detail for a card, Suivi, Contact, Operation,... *
- * cc stands for customer card
+ * cc stands for customer card
*----------------------------------------------------------------------*/
if ( $low_action == 'detail')
{
Modified: phpcompta/branches/rel600-dynamic-menu/include/adm_card.inc.php
===================================================================
--- phpcompta/trunk/include/adm_card.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/adm_card.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -28,14 +28,15 @@
*/
require_once('class_contact.php');
require_once('class_ipopup.php');
+$str_dossier=Dossier::get();
/* $sub_action = sb = detail */
/* $cn database conx */
$return=new IAction();
$return->name='retour';
$return->label='Retour';
-$return->value='?p_action=adm&'.$str_dossier;
-$root="?p_action=adm&sb=detail&f_id=".$_REQUEST["f_id"].'&'.$str_dossier;
+$return->value='?ac='.$_REQUEST['ac'].'&'.$str_dossier;
+$root='?ac='.$_REQUEST['ac']."&sb=detail&f_id=".$_REQUEST["f_id"].'&'.$str_dossier;
$ss_action=( isset ($_REQUEST['sc'] ))? $_REQUEST['sc']: '';
switch ($ss_action)
{
@@ -70,7 +71,7 @@
array($root.'&sc=op',_('Opérations'),_('Toutes les
opérations'),4),
array($root.'&sc=bal',_('Balance'),_('Balance du
fournisseur'),7),
array($root.'&sc=let',_('Lettrage'),_('Opérations &
Lettrages'),6),
- array('?p_action=adm&'.dossier::get(),_('Retour
liste'),_('Retour à la liste des administration'),5)
+ array('?ac='.$_REQUEST['ac']."&".dossier::get(),_('Retour
liste'),_('Retour à la liste des administration'),5)
),
'H',"mtitle","mtitle",$def,' ');
echo '</div>';
Modified: phpcompta/branches/rel600-dynamic-menu/include/balance.inc.php
===================================================================
--- phpcompta/trunk/include/balance.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/balance.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -34,6 +34,7 @@
require_once('class_acc_ledger.php');
require_once('class_periode.php');
require_once('class_exercice.php');
+global $User;
$User->can_request(IMPBAL);
$exercice=(isset($_GET['exercice']))?$_GET['exercice']:$User->get_exercice();
@@ -50,14 +51,14 @@
$wex=$ex->select('exercice',$exercice,' onchange="submit(this)"');
echo $wex->input();
echo dossier::hidden();
-echo HtmlInput::get_to_hidden(array('p_action','type'));
+echo HtmlInput::get_to_hidden(array('ac','type'));
echo '</form>';
echo '</fieldset>';
// Show the form for period
echo '<FORM method="get">';
-echo HtmlInput::hidden('p_action','impress');
+echo HtmlInput::get_to_hidden(array('ac'));
echo HtmlInput::hidden('type','bal');
echo HtmlInput::get_to_hidden(array('exercice'));
echo dossier::hidden();
@@ -177,7 +178,7 @@
echo '<TD><form method="GET" ACTION="export.php">'.
dossier::hidden().
HtmlInput::submit('bt_pdf',"Export PDF").
- HtmlInput::hidden("p_action","impress").
+ HtmlInput::hidden("ac",$_REQUEST['ac']).
HtmlInput::hidden("act","PDF/balance").
HtmlInput::hidden("from_periode",$_GET['from_periode']).
@@ -199,10 +200,10 @@
echo '<TD><form method="GET" ACTION="export.php">'.
HtmlInput::submit('bt_csv',"Export CSV").
dossier::hidden().
- HtmlInput::hidden("p_action","impress").
HtmlInput::hidden("act","CSV/balance").
HtmlInput::hidden("from_periode",$_GET['from_periode']).
HtmlInput::hidden("to_periode",$_GET['to_periode']);
+ echo HtmlInput::get_to_hidden(array('ac'));
echo HtmlInput::hidden('p_filter',$_GET['p_filter']);
if (isset($_GET ['r_jrn']))
if (isset($selected[$e]))
@@ -288,12 +289,12 @@
* level x
*/
foreach (array(3,2,1) as $ind)
- {
+ {
if ( ! isset($_GET['lvl'.$ind]))continue;
if (${'lvl'.$ind.'_old'} == '')
${'lvl'.$ind.'_old'}=substr($r['poste'],0,$ind);
if ( ${'lvl'.$ind.'_old'} != substr($r['poste'],0,$ind))
{
-
+
echo '<tr style="font-size:12px;font-height:bold">';
echo td("Total niveau ".$ind);
echo td(${'lvl'.$ind.'_old'});
@@ -301,7 +302,7 @@
echo
td(nbm(${'lvl'.$ind}['sum_cred']),'style="text-align:right"');
echo
td(nbm(${'lvl'.$ind}['solde_deb']),'style="text-align:right"');
echo
td(nbm(${'lvl'.$ind}['solde_cred']),'style="text-align:right"');
-
+
echo '</tr>';
${'lvl'.$ind.'_old'}=substr($r['poste'],0,$ind);
foreach(array('sum_cred','sum_deb','solde_deb','solde_cred') as
$a)
Modified: phpcompta/branches/rel600-dynamic-menu/include/balance_card.inc.php
===================================================================
--- phpcompta/trunk/include/balance_card.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/balance_card.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -24,6 +24,7 @@
* \brief show the status of a card
*/
require_once('class_exercice.php');
+global $User;
echo '<div class="content" style="width:80%;margin-left:10%">';
$exercice=new Exercice($cn);
$old='';
@@ -53,11 +54,11 @@
$default=(isset($_GET['ex']))?$_GET['ex']:$year;
$dossier=dossier::id();
- $old='<form method="get" action="commercial.php">';
+ $old='<form method="get" action="do.php">';
$is=$exercice->select('ex',$default,'onchange = "submit(this)"');
$old.="Autre exercice ".$is->input();
$old.=HtmlInput::hidden('f_id',$_GET['f_id']);
- $old.=HtmlInput::hidden('p_action',$_GET['p_action']);
+ $old.=HtmlInput::hidden('ac',$_GET['ac']);
$old.=HtmlInput::hidden('sb',$_GET['sb']);
$old.=HtmlInput::hidden('sc',$_GET['sc']);
$old.=dossier::hidden();
@@ -70,5 +71,5 @@
echo $old;
}
-
+
echo '</div>';
Modified: phpcompta/branches/rel600-dynamic-menu/include/class_acc_ledger.php
===================================================================
--- phpcompta/trunk/include/class_acc_ledger.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/class_acc_ledger.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -110,7 +110,7 @@
}
/**
*let you delete a operation
- address@hidden by cascade it will delete also in
+ address@hidden by cascade it will delete also in
* - jrnx
* - stock
* - quant_purchase
@@ -134,7 +134,7 @@
}
/**
* reverse the operation by creating the opposite one,
- * the result is to avoid it
+ * the result is to avoid it
* it must be done in
* - jrn
* - jrnx
@@ -792,7 +792,7 @@
{
$positive = $this->db->get_value("select qf_amount from
quant_fin where jr_id=$1",
array($row['jr_id']));
- if ( $this->db->count() != 0)
+ if ( $this->db->count() != 0)
$positive=($positive < 0)?1:0;
}
$r.="<TD align=\"right\">";
@@ -1149,7 +1149,7 @@
* writing, reading or simply accessing.
* \param $p_type = ALL or the type of the ledger (ACH,VEN,FIN,ODS)
* \param $p_access =3 for READ and WRITE, 2 for write and 1 for readonly
- * \return object HtmlInput select
+ * \return object HtmlInput select
*/
function select_ledger($p_type="ALL",$p_access=3)
{
@@ -2223,6 +2223,7 @@
$r.=dossier::hidden();
$r.=HtmlInput::hidden('ledger_type',$this->type);
+ $r.=HtmlInput::hidden('ac',$_REQUEST['ac']);
ob_start();
require_once('template/ledger_search.php');
$r.=ob_get_contents();
@@ -2466,7 +2467,7 @@
$r.='<FORM METHOD="GET">';
$r.=$this->search_form($type);
$r.=HtmlInput::submit('search',_('Rechercher'));
- $r.=HtmlInput::hidden('p_action',$_REQUEST['p_action']);
+ $r.=HtmlInput::hidden('ac',$_REQUEST['ac']);
/* when called from commercial.php some hidden values are needed */
if (isset($_REQUEST['sa'])) $r.=
HtmlInput::hidden("sa",$_REQUEST['sa']);
@@ -2520,10 +2521,10 @@
}
}
/**
- address@hidden retrieve operation from jrn
- address@hidden $p_from periode (id)
+ address@hidden retrieve operation from jrn
+ address@hidden $p_from periode (id)
address@hidden $p_to periode (id)
- address@hidden an array
+ address@hidden an array
*/
function get_operation($p_from,$p_to)
{
@@ -2644,17 +2645,17 @@
'vat' => string '21.7600' (length=7)
'priv' => string '0.0000' (length=6)
'tva_nd_recup' => string '0.0000' (length=6)
- 'tva' =>
+ 'tva' =>
array
- 0 =>
+ 0 =>
array
'sum_vat' => string '13.7200' (length=7)
'tva_id' => string '1' (length=1)
- 1 =>
+ 1 =>
array
'sum_vat' => string '8.0400' (length=6)
'tva_id' => string '3' (length=1)
- 2 =>
+ 2 =>
array
'sum_vat' => string '0.0000' (length=6)
'tva_id' => string '4' (length=1)
@@ -2858,7 +2859,7 @@
return $r;
}
/**
- *Retrieve the third : supplier for purchase, customer for sale, bank for
fin,
+ *Retrieve the third : supplier for purchase, customer for sale, bank for
fin,
address@hidden $p_jrn_type type of the ledger FIN, VEN ACH or ODS
*/
function get_tiers($p_jrn_type,$jr_id)
Modified: phpcompta/branches/rel600-dynamic-menu/include/class_action.php
===================================================================
--- phpcompta/trunk/include/class_action.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/class_action.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -89,18 +89,18 @@
//----------------------------------------------------------------------
/*!
* \brief Display the object, the tags for the FORM
- * are in the caller. It will be used for adding and updating
- * action
+ * are in the caller. It will be used for adding and updating
+ * action
*\note If ag_id is not equal to zero then it is an update otherwise
* it is a new document
*
- * \param $p_view if set to true the form will be in readonly mode (value:
true or false)
+ * \param $p_view if set to true the form will be in readonly mode (value:
true or false)
* \param $p_gen true we show the tag for generating a doc (value : true
or false)
- *\param $p_base is the p_action parameter
+ *\param $p_base is the ac parameter
*\param $retour is the html code for the return button
* \note update the reference number or the document type is not allowed
- *
*
+ *
* \return string containing the html code
*/
function Display($p_view,$p_gen,$p_base,$retour="")
@@ -297,7 +297,7 @@
if( isset($_REQUEST['sb']))
$supl_hidden.='&sb='.$_REQUEST['sb'];
- $lag_ref_ag_id='<a class="mtitle"
href="?p_action='.$_REQUEST['p_action'].$supl_hidden.'&sa=detail&ag_id='.
+ $lag_ref_ag_id='<a class="mtitle"
href="?ac='.$_REQUEST['ac'].$supl_hidden.'&sa=detail&ag_id='.
$this->ag_ref_ag_id.'&'.dossier::get().'">'.
$this->db->get_value("select ag_ref from
action_gestion where ag_id=$1",array($this->ag_ref_ag_id)).
"</A>";
@@ -568,7 +568,7 @@
}
/*!
- * \brief Save the document and propose to save the generated document or
+ * \brief Save the document and propose to save the generated document or
* to upload one, the data are included except the file. Temporary the
generated
* document is save
*
@@ -644,7 +644,7 @@
}
/*! myList($p_filter="")
* \brief Show list of action by default if sorted on date
- *\param $p_base base url with p_action...
+ *\param $p_base base url with ac...
* \param $p_filter filters on the document_type
* \param $p_search must a valid sql command ( ex 'and ag_title like
upper('%hjkh%'))
* \return string containing html code
@@ -822,7 +822,7 @@
//show the sub_action
foreach ($a_row as $row )
{
- $href='<A class="document"
HREF="commercial.php?'.$p_base.'&sa=detail&ag_id='.$row['ag_id'].'&'.$str_dossier.'">';
+ $href='<A class="document"
HREF="do.php?'.$p_base.'&sa=detail&ag_id='.$row['ag_id'].'&'.$str_dossier.'&ac='.$_REQUEST['ac'].'">';
$i++;
$tr=($i%2==0)?'even':'odd';
if ($row['ag_priority'] < 2) $tr='priority1';
@@ -858,7 +858,7 @@
{
foreach ($retSql as $line)
{
- $ref.='<A
href="commercial.php?'.$p_base.'&query='.$line['ag_ref'].'&'.$str_dossier.'">'.
+ $ref.='<A
href="do.php?'.$p_base.'&query='.$line['ag_ref'].'&'.$str_dossier.'">'.
$line['ag_ref']."<A>";
}
}
@@ -870,7 +870,7 @@
/*
* State
*/
- switch ( $row['ag_state'] )
+ switch ( $row['ag_state'] )
{
case 1:
$state='Fermé';
@@ -889,7 +889,7 @@
/*
* State
*/
- switch ( $row['ag_priority'] )
+ switch ( $row['ag_priority'] )
{
case 1:
$priority='Haute';
Modified: phpcompta/branches/rel600-dynamic-menu/include/class_dossier.php
===================================================================
--- phpcompta/trunk/include/class_dossier.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/class_dossier.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -55,9 +55,9 @@
}
/*!
- * \param p_type string : all for all dossiers lim for only the
+ * \param p_type string : all for all dossiers lim for only the
* dossier where we've got rights
- *
+ *
* Show the folder where user have access. Return : nothing
++*/
function show_dossier($p_type,$p_first=0,$p_max=10,$p_Num=0)
@@ -230,4 +230,10 @@
{
return $p_cn->get_value('select val from version');
}
+ static function connect()
+ {
+ $id=Dossier::id();
+ $cn= new Database($id);
+ return $cn;
+ }
}
Modified: phpcompta/branches/rel600-dynamic-menu/include/class_fiche.php
===================================================================
--- phpcompta/trunk/include/class_fiche.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/class_fiche.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -71,7 +71,7 @@
*/
function get_bk_account()
{
-
+
$user=new User($this->cn);
$sql_ledger=$user->get_ledger_sql('FIN',3);
$avail=$this->cn->get_array("select jrn_def_id,jrn_def_bank from jrn_def
where jrn_def_type='FIN' and $sql_ledger
@@ -105,7 +105,7 @@
if ( $p_qcode == null )
$p_qcode=$this->quick_code;
$p_qcode=trim($p_qcode);
- $sql="select f_id from fiche_detail
+ $sql="select f_id from fiche_detail
where ad_id=23 and ad_value=upper($1)";
$this->id=$this->cn->get_value($sql,array($p_qcode));
if ( $this->cn->count()==0)
@@ -149,8 +149,8 @@
return;
}
$sql="select *
- from
- fiche
+ from
+ fiche
natural join fiche_detail
join jnt_fic_attr on (jnt_fic_attr.fd_id=fiche.fd_id and
fiche_detail.ad_id=jnt_fic_attr.ad_id)
join attr_def on (attr_def.ad_id=fiche_detail.ad_id) where
f_id=".$this->id.
@@ -214,7 +214,7 @@
*/
function seek($p_attribut,$p_value)
{
- $sql="select jft_id,f_id,fd_id,ad_id,ad_value from fiche join
fiche_detail using (f_id)
+ $sql="select jft_id,f_id,fd_id,ad_id,ad_value from fiche join
fiche_detail using (f_id)
where ad_id=$1 and upper(ad_value)=upper($2)";
$res=$this->cn->get_array($sql,array($p_attribut,$p_value));
return $res;
@@ -662,7 +662,7 @@
$msg=$w->search();
$msg.=$label->input();
break;
-
+
default:
var_dump($r);
throw new Exception("Type invalide");
@@ -732,7 +732,7 @@
list ($id) = sscanf ($name,"av_text%d");
if ( $id == null ) continue;
-
+
// Special traitement
// quickcode
if ( $id == ATTR_DEF_QUICKCODE)
@@ -833,7 +833,7 @@
foreach ($p_array as $name=>$value )
{
if ( preg_match('/^av_text[0-9]+$/',$name) == 0) continue;
-
+
list ($id) = sscanf ($name,"av_text%d");
if ( $id == null ) continue;
@@ -1248,7 +1248,7 @@
* \brief HtmlTable, display a HTML of a card for the asked period
* \param $p_array default = null keys = from_periode, to_periode
*\param $op_let 0 all operation, 1 only lettered one, 2 only unlettered
one
- *\return -1 if nothing is found otherwise 0
+ *\return -1 if nothing is found otherwise 0
*\see get_row_date
*/
function HtmlTable($p_array=null,$op_let=0,$from_div=1)
@@ -1461,7 +1461,7 @@
( select j_poste,
case when j_debit='t' then j_montant else 0
end as deb,
case when j_debit='f' then j_montant else 0
end as cred
- from jrnx
+ from jrnx
join jrn on (jr_grpt_id=j_grpt)
where
j_qcode = ('$qcode'::text)
@@ -1476,7 +1476,7 @@
return array('debit'=>$r['sum_deb'],
'credit'=>$r['sum_cred'],
'solde'=>abs($r['sum_deb']-$r['sum_cred']));
-
+
}
/*!\brief check if an attribute is empty
*\param $p_attr the id of the attribut to check (ad_id)
@@ -1576,8 +1576,8 @@
if ( $p_amount && $amount['debit']==0 && $amount['credit'] == 0 &&
$amount['solde'] == 0 ) continue;
$r.="<TR $odd>";
- $e=sprintf('<A HREF="%s?p_action=%s&sb=detail&f_id=%d&%s&sc=sv"
title="Détail"> ',
- $script,$p_action,$tiers->id,$str_dossier);
+ $e=sprintf('<A HREF="%s?ac=%s&sb=detail&f_id=%d&%s&sc=sv"
title="Détail"> ',
+ $script,$_REQUEST['ac'],$tiers->id,$str_dossier);
$r.="<TD> $e".$tiers->strAttribut(ATTR_DEF_QUICKCODE)."</A></TD>";
$r.="<TD>".h($tiers->strAttribut(ATTR_DEF_NAME))."</TD>";
@@ -1589,8 +1589,8 @@
$r.='<TD align="right">
'.(($amount['debit']==0)?0:nbm($amount['debit'])).'€</TD>';
$r.='<TD align="right">
'.(($amount['credit']==0)?0:nbm($amount['credit'])).'€</TD>';
$r.='<TD align="right"> '.nbm($amount['solde'])."€</TD>";
-
+
$r.="</TR>";
}
@@ -1747,7 +1747,7 @@
{
// Remove from attr_value
$Res=$this->cn->exec_sql("delete from fiche_detail
- where
+ where
f_id=".$this->id);
// Remove from fiche
Modified: phpcompta/branches/rel600-dynamic-menu/include/client.inc.php
===================================================================
--- phpcompta/trunk/include/client.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/client.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -47,7 +47,6 @@
/*! \file
* \brief Called from the module "Gestion" to manage the customer
*/
-$User->can_request(GECUST);
$href=basename($_SERVER['PHP_SELF']);
// by default open liste
@@ -103,7 +102,7 @@
?>
<input type="submit" class="button" name="submit_query"
value="<?=_('recherche')?>">
- <input type="hidden"
name="p_action" value="client">
+ <input type="hidden" name="ac"
value="<?=$_REQUEST['ac']?>">
</form>
</span>
<?php
@@ -145,7 +144,7 @@
}
/*----------------------------------------------------------------------
* Detail for a card, Suivi, Contact, Operation,... *
- * cc stands for customer card
+ * cc stands for customer card
*----------------------------------------------------------------------*/
if ( $low_action == 'detail')
{
@@ -171,7 +170,7 @@
echo "</table>";
$retour=new IAction();
$retour->label="Retour";
- $retour->value="?p_action=client&".dossier::get();
+ $retour->value="?ac=".$_REQUEST["ac"]."&".dossier::get();
echo $retour->input();
echo '</div>';
Modified: phpcompta/branches/rel600-dynamic-menu/include/client_card.inc.php
===================================================================
--- phpcompta/trunk/include/client_card.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/client_card.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -32,8 +32,9 @@
/* $sub_action = sb = detail */
/* $cn database conx */
+$str_dossier=Dossier::get();
$return= HtmlInput::button_anchor('Retour','?p_action=client&'.$str_dossier);
-$root="?p_action=client&sb=detail&f_id=".$_REQUEST["f_id"].'&'.$str_dossier;
+$root="?p_action=client&sb=detail&f_id=".$_REQUEST["f_id"].'&'.$str_dossier."&ac=".$_REQUEST["ac"];
$ss_action=( isset ($_REQUEST['sc'] ))? $_REQUEST['sc']: '';
switch ($ss_action)
{
@@ -68,7 +69,7 @@
array($root.'&sc=op',_('Opérations'),_('Toutes les
opérations'),4),
array($root.'&sc=bal',_('Balance'),_('Balance du client'),7),
array($root.'&sc=let',_('Lettrage'),_('Opérations &
Lettrages'),6),
- array('?p_action=client&'.dossier::get(),_('Retour
liste'),_('Retour à la liste des clients'),5)
+ array('?ac='.$_REQUEST['ac'].'&'.dossier::get(),_('Retour
liste'),_('Retour à la liste des clients'),5)
),
'H',"mtitle","mtitle",$def,'');
echo '</div>';
Modified: phpcompta/branches/rel600-dynamic-menu/include/compta_fin.inc.php
===================================================================
--- phpcompta/trunk/include/compta_fin.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/compta_fin.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -25,6 +25,7 @@
*/
require_once ('class_acc_ledger_fin.php');
require_once('class_ipopup.php');
+global $g_user;
$gDossier=dossier::id();
$p_action=(isset ($_REQUEST['p_action']))?$_REQUEST['p_action']:'';
@@ -80,7 +81,7 @@
$def_ledger=$Ledger->get_first('fin');
$Ledger->id=$def_ledger['jrn_def_id'];
}
- $jrn_priv=$User->get_ledger_access($Ledger->id);
+ $jrn_priv=$g_user->get_ledger_access($Ledger->id);
// Check privilege
if ( isset($_REQUEST['p_jrn']) && ( $jrn_priv == 'X'))
{
@@ -190,7 +191,7 @@
/* by default we should the default period */
if ( ! isset($p_array['date_start']))
{
- $period=$User->get_periode();
+ $period=$g_user->get_periode();
$per=new Periode($cn,$period);
list($date_start,$date_end)=$per->get_date_limit();
$p_array['date_start']=$date_start;
@@ -250,7 +251,7 @@
.th('différence',' style="text-align:right"'));
// Filter the saldo
// on the current year
- $filter_year=" j_tech_per in (select p_id from parm_periode where
p_exercice='".$User->get_exercice()."')";
+ $filter_year=" j_tech_per in (select p_id from parm_periode where
p_exercice='".$g_user->get_exercice()."')";
// for highligting tje line
$idx=0;
bcscale(2);
@@ -269,7 +270,7 @@
$saldo_not_reconcilied=$array[$i]->get_bk_balance($filter_year."
and (trim(jr_pj_number) ='' or jr_pj_number is null)" );
/* get saldo for reconcilied operation */
-
+
$saldo_reconcilied=$array[$i]->get_bk_balance($filter_year." and (
trim(jr_pj_number) != '' and jr_pj_number is not null)" );
if ( $idx%2 != 0 )
@@ -318,7 +319,7 @@
}
else
$Ledger->id=$_REQUEST['p_jrn'];
- $jrn_priv=$User->get_ledger_access($Ledger->id);
+ $jrn_priv=$g_user->get_ledger_access($Ledger->id);
if ( isset($_GET["p_jrn"]) && $jrn_priv=="X")
{
NoAccess();
@@ -355,7 +356,7 @@
echo HtmlInput::get_to_hidden(array('gDossier','p_action','sa'));
$wLedger=$Ledger->select_ledger('FIN',3);
if ($wLedger == null ) exit ('Pas de journal disponible');
-
+
$wLedger->javascript="onchange='this.form.submit()';";
echo $wLedger->input();
echo HtmlInput::submit('ref','Rafraîchir');
@@ -414,7 +415,7 @@
echo '</table>';
$bk_card=new Fiche($cn);
$bk_card->id=$Ledger->get_bank();
- $filter_year=" j_tech_per in (select p_id from parm_periode where
p_exercice='".$User->get_exercice()."')";
+ $filter_year=" j_tech_per in (select p_id from parm_periode where
p_exercice='".$g_user->get_exercice()."')";
/* get saldo for not reconcilied operations */
$saldo_not_reconcilied=$bk_card->get_solde_detail($filter_year." and
j_grpt in (select jr_grpt_id from jrn where trim(jr_pj_number) ='' or
jr_pj_number is null)" );
Modified: phpcompta/branches/rel600-dynamic-menu/include/constant.php
===================================================================
--- phpcompta/trunk/include/constant.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/constant.php 2011-10-13
20:00:17 UTC (rev 4208)
@@ -35,8 +35,8 @@
/*set to none for production */
/* uncomment for production */
-$version_phpcompta=SVNINFO;
-define ("DEBUG",false);
+$version_phpcompta=9999;
+define ("DEBUG",true);
define ("DBVERSION",97);
define ("DBVERSIONREPO",13);
Modified: phpcompta/branches/rel600-dynamic-menu/include/fiche.inc.php
===================================================================
--- phpcompta/trunk/include/fiche.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/fiche.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -34,12 +34,14 @@
$gDossier=dossier::id();
$str_dossier=dossier::get();
+global $User;
$pop_tva=new IPopup('popup_tva');
$pop_tva->title=_('Choix TVA');
$pop_tva->value='';
echo $pop_tva->input();
+
$cn=new Database($gDossier);
// Security check
$write=$User->check_action(FICADD);
@@ -58,6 +60,8 @@
$h=new IHidden();
echo $h->input('p_action','fiche');
echo $h->input('action','search');
+ echo $h->input('ac',$_REQUEST['ac']);
+
echo _("Recherche :").$w->input('search_text',$search_text);
echo HtmlInput::submit('submit',_('Rechercher'));
echo '</form>';
@@ -92,6 +96,7 @@
$r.='<form method="post">';
$r.=dossier::hidden();
$r.=HtmlInput::hidden("fd_id",$p_fiche_def->id);
+ $r.=HtmlInput::hidden("ac",$_REQUEST['ac']);
$r.=HtmlInput::hidden("p_action","fiche");
$r.= $p_fiche_def->input_base();
$r.='<hr>';
@@ -101,9 +106,10 @@
/* attributes */
$r.='<fieldset><legend>Détails</legend>';
- $r.= '<FORM action="?p_action=fiche" method="POST">';
+ $r.= '<FORM action="do.php" method="POST">';
$r.=dossier::hidden();
$r.=HtmlInput::hidden("fd_id",$p_fiche_def->id);
+ $r.=HtmlInput::hidden("ac",$_REQUEST['ac']);
$r.= $p_fiche_def->DisplayAttribut("remove");
$r.= HtmlInput::submit('add_line',_('Ajoutez cet élément'));
$r.= HtmlInput::submit("save_line",_("Sauvez"));
Modified: phpcompta/branches/rel600-dynamic-menu/include/impress_bilan.inc.php
===================================================================
--- phpcompta/trunk/include/impress_bilan.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/impress_bilan.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -32,7 +32,7 @@
// Show the jrn and date
//-----------------------------------------------------
require_once('class_database.php');
-
+global $User;
//-----------------------------------------------------
// Form
//-----------------------------------------------------
@@ -52,18 +52,17 @@
$wex=$ex->select('exercice',$exercice,' onchange="submit(this)"');
echo $wex->input();
echo dossier::hidden();
-echo HtmlInput::get_to_hidden(array('p_action','type'));
+echo HtmlInput::get_to_hidden(array('ac','type'));
echo '</form>';
echo '</fieldset>';
$filter_year=" where p_exercice='".FormatString($exercice)."'";
echo '<FORM METHOD="GET">';
-echo HtmlInput::hidden('p_action','impress');
echo HtmlInput::hidden('type','bilan');
echo dossier::hidden();
echo $bilan->display_form ($filter_year);
echo HtmlInput::submit('verif',_('Verification comptabilite'));
-echo HtmlInput::get_to_hidden(array('exercice'));
+echo HtmlInput::get_to_hidden(array('ac','exercice'));
echo '</FORM>';
Modified: phpcompta/branches/rel600-dynamic-menu/include/impress_fiche.inc.php
===================================================================
--- phpcompta/trunk/include/impress_fiche.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/impress_fiche.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -27,6 +27,8 @@
$gDossier=dossier::id();
$cn=new Database($gDossier);
+global $User;
+
/**
* Show first the form
*/
@@ -69,8 +71,7 @@
echo '<div class="content">';
echo '<FORM method="GET">';
echo dossier::hidden();
-echo HtmlInput::hidden('p_action',$_GET['p_action']);
-echo HtmlInput::hidden('type',$_GET['type']);
+echo HtmlInput::hidden('ac',$_GET['ac']);
require_once('template/impress_cat_card.php');
echo HtmlInput::submit('cat_display',_('Recherche'));
echo '</FORM>';
@@ -106,7 +107,7 @@
HtmlInput::submit('bt_csv',"Export CSV").
HtmlInput::hidden('act',"CSV/fiche").
$hid->input("type","fiche").
- $hid->input("p_action","impress").
+ $hid->input("ac",$_REQUEST['ac']).
$hid->input("fd_id",$_REQUEST['cat']);
echo "</form>";
Modified:
phpcompta/branches/rel600-dynamic-menu/include/impress_gl_comptes.inc.php
===================================================================
--- phpcompta/trunk/include/impress_gl_comptes.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/impress_gl_comptes.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -34,14 +34,14 @@
// Show the jrn and date
//-----------------------------------------------------
require_once('class_database.php');
-
+global $User;
//-----------------------------------------------------
// Form
//-----------------------------------------------------
echo '<div class="content">';
echo '<FORM action="?" METHOD="GET">';
-echo HtmlInput::hidden('p_action','impress');
+echo HtmlInput::hidden('ac',$_REQUEST['ac']);
echo HtmlInput::hidden('type','gl_comptes');
echo dossier::hidden();
echo '<TABLE><TR>';
@@ -117,7 +117,7 @@
$sql='select pcm_val from tmp_pcmn ';
$cond_poste='';
- if ($from_poste->value != '')
+ if ($from_poste->value != '')
{
$cond_poste = ' where ';
$cond_poste .=' pcm_val >= upper
(\''.Database::escape_string($from_poste->value).'\')';
@@ -125,7 +125,7 @@
if ( $to_poste->value != '')
{
- if ( $cond_poste == '')
+ if ( $cond_poste == '')
{
$cond_poste = ' where pcm_val <= upper
(\''.Database::escape_string($to_poste->value).'\')';
}
@@ -155,13 +155,13 @@
echo '<table class="result">';
$l=(isset($_REQUEST['letter']))?2:0;
$s=(isset($_REQUEST['solded']))?1:0;
-
+
foreach ($a_poste as $poste_id )
{
$Poste=new Acc_Account_Ledger ($cn, $poste_id['pcm_val']);
$Poste->load();
-
+
$Poste->get_row_date( $_GET['from_periode'],
$_GET['to_periode'],$l,$s);
if ( empty($Poste->row))
{
Modified: phpcompta/branches/rel600-dynamic-menu/include/impress_jrn.inc.php
===================================================================
--- phpcompta/trunk/include/impress_jrn.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/impress_jrn.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -29,6 +29,7 @@
require_once('class_dossier.php');
load_all_script();
$gDossier=dossier::id();
+global $User;
//-----------------------------------------------------
// Show the jrn and date
//-----------------------------------------------------
@@ -86,14 +87,14 @@
$wex=$ex->select('exercice',$exercice,' onchange="submit(this)"');
echo $wex->input();
echo dossier::hidden();
-echo HtmlInput::get_to_hidden(array('p_action','type'));
+echo HtmlInput::get_to_hidden(array('ac','type'));
echo '</form>';
echo '</fieldset>';
echo '<FORM METHOD="GET">'.dossier::hidden();
-echo HtmlInput::hidden('p_action','impress');
+echo HtmlInput::get_to_hidden(array('ac','type'));
echo HtmlInput::hidden('type','jrn');
echo HtmlInput::get_to_hidden(array('exercice'));
echo '<TABLE ><TR>';
@@ -171,22 +172,22 @@
HtmlInput::submit('bt_pdf',"Export PDF").
HtmlInput::hidden('act','PDF/ledger').
$hid->input("type","jrn").
- $hid->input("p_action","impress").
$hid->input("jrn_id",$Jrn->id).
$hid->input("from_periode",$_GET['from_periode']).
$hid->input("to_periode",$_GET['to_periode']);
echo $hid->input("p_simple",$_GET['p_simple']);
+ echo HtmlInput::get_to_hidden(array('ac','type'));
+ echo "</form></TD>";
- echo "</form></TD>";
echo '<TD><form method="GET" ACTION="export.php">'.dossier::hidden().
HtmlInput::submit('bt_csv',"Export CSV").
HtmlInput::hidden('act','CSV/ledger').
$hid->input("type","jrn").
- $hid->input("p_action","impress").
$hid->input("jrn_id",$Jrn->id).
$hid->input("from_periode",$_GET['from_periode']).
$hid->input("to_periode",$_GET['to_periode']);
echo $hid->input("p_simple",$_GET['p_simple']);
+ echo HtmlInput::get_to_hidden(array('ac','type'));
echo "</form></TD>";
echo "</TR>";
Modified: phpcompta/branches/rel600-dynamic-menu/include/impress_poste.inc.php
===================================================================
--- phpcompta/trunk/include/impress_poste.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/impress_poste.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -28,13 +28,14 @@
* file included from user_impress
*
* some variable are already defined $cn, $User ...
- *
+ *
*/
//-----------------------------------------------------
// Show the jrn and date
//-----------------------------------------------------
require_once('class_database.php');
require_once('class_ipopup.php');
+global $User;
echo IPoste::ipopup('ipop_account');
echo ICard::ipopup('ipopcard');
@@ -49,7 +50,7 @@
echo '<div class="content">';
echo '<FORM action="?" METHOD="GET">';
-echo HtmlInput::hidden('p_action','impress');
+echo HtmlInput::hidden('ac',$_REQUEST['ac']);
echo HtmlInput::hidden('type','poste');
echo dossier::hidden();
echo '<TABLE><TR>';
Modified: phpcompta/branches/rel600-dynamic-menu/include/impress_rapport.inc.php
===================================================================
--- phpcompta/trunk/include/impress_rapport.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/impress_rapport.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -28,7 +28,7 @@
require_once("class_idate.php");
require_once("class_acc_report.php");
require_once('class_exercice.php');
-
+global $User;
//-----------------------------------------------------
// If print is asked
// First time in html
@@ -90,14 +90,14 @@
echo '<TD><form method="GET" ACTION="?">'.
dossier::hidden().
HtmlInput::submit('bt_other',"Autre Rapport").
-
$hid->input("type","rapport").$hid->input("p_action","impress")."</form></TD>";
+ $hid->input("type","rapport").$hid->input("ac",$_GET['ac'])."</form></TD>";
echo '<TD><form method="GET" ACTION="export.php">'.
HtmlInput::submit('bt_pdf',"Export PDF").
HtmlInput::hidden('act','PDF/report').
dossier::hidden().
$hid->input("type","rapport").
- $hid->input("p_action","impress").
+ $hid->input("ac",$_GET['ac']).
$hid->input("form_id",$Form->id);
if ( isset($_GET['from_periode'])) echo
$hid->input("from_periode",$_GET['from_periode']);
if ( isset($_GET['to_periode'])) echo
$hid->input("to_periode",$_GET['to_periode']);
@@ -115,7 +115,7 @@
HtmlInput::submit('bt_csv',"Export CSV").
dossier::hidden().
$hid->input("type","form").
- $hid->input("p_action","impress").
+ $hid->input("ac",$_GET['ac']).
$hid->input("form_id",$Form->id);
if ( isset($_GET['from_periode'])) echo
$hid->input("from_periode",$_GET['from_periode']);
if ( isset($_GET['to_periode'])) echo
$hid->input("to_periode",$_GET['to_periode']);
@@ -186,14 +186,14 @@
$wex=$ex->select('exercice',$exercice,' onchange="submit(this)"');
echo $wex->input();
echo dossier::hidden();
-echo HtmlInput::get_to_hidden(array('p_action','type'));
+echo HtmlInput::get_to_hidden(array('ac','type'));
echo '</form>';
echo '</fieldset>';
echo '<FORM METHOD="GET">';
$hidden=new IHidden();
-echo $hidden->input("p_action","impress");
+echo $hidden->input("ac",$_GET['ac']);
echo $hidden->input("type","rapport");
echo dossier::hidden();
Modified: phpcompta/branches/rel600-dynamic-menu/include/impress_rec.inc.php
===================================================================
--- phpcompta/trunk/include/impress_rec.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/impress_rec.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -25,7 +25,8 @@
*/
require_once ('class_acc_reconciliation.php');
require_once('function_javascript.php');
-echo load_all_script();
+global $User;
+
/**
address@hidden
address@hidden add the export to PDF
@@ -38,7 +39,7 @@
$choice=(isset($_GET['choice']))?$_GET['choice']:0;
$r_jrn=(isset($_GET['r_jrn']))?$_GET['r_jrn']:'';
echo '<form method="GET">';
-echo
dossier::hidden().HtmlInput::hidden('p_action','impress').HtmlInput::hidden('type','rec');
+echo
dossier::hidden().HtmlInput::hidden('ac',$_GET['ac']).HtmlInput::hidden('type','rec');
echo 'Filtre par journal :'.HtmlInput::select_ledger($aledger,$r_jrn );
echo '<br/>';
/*
Modified:
phpcompta/branches/rel600-dynamic-menu/include/lettering.gestion.inc.php
===================================================================
--- phpcompta/trunk/include/lettering.gestion.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/lettering.gestion.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -1,10 +1,11 @@
<?php
require_once('class_lettering.php');
+global $User;
echo '<div class="content">';
echo '<div id="search">';
echo '<FORM METHOD="GET">';
echo dossier::hidden();
-echo HtmlInput::hidden('p_action',$_REQUEST['p_action']);
+echo HtmlInput::hidden('ac',$_REQUEST['ac']);
echo HtmlInput::hidden('sb',$_REQUEST['sb']);
echo HtmlInput::hidden('sc',$_REQUEST['sc']);
echo HtmlInput::hidden('f_id',$_REQUEST['f_id']);
Modified: phpcompta/branches/rel600-dynamic-menu/include/stock.inc.php
===================================================================
--- phpcompta/trunk/include/stock.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/stock.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -34,26 +34,13 @@
html_page_start($_SESSION['g_theme']);
require_once('class_database.php');
-/* Admin. Dossier */
-$gDossier=dossier::id();
$cn=new Database($gDossier);
include_once ("class_user.php");
-$User=new User($cn);
-$User->Check();
+global $User;
-
$href=basename($_SERVER['PHP_SELF']);
-if ($href=='compta.php')
-{
- //Show the top menu
- include_once ("user_menu.php");
- // Show Menu Left
- $left_menu=ShowMenuAdvanced(5);
- //echo '<div class="lmenu">';
- echo $left_menu;
-}
// Get The priv on the selected folder
$User->can_request(STOLE,1);
@@ -159,16 +146,16 @@
echo '<fieldset><legend>';
echo 'Entrer la valeur qui doit augmenter ou diminuer le stock';
echo '</legend>';
- echo '<form action="?p_action=stock" method="POST">';
+ echo '<form action="?ac='.$_GET['ac'].'" method="POST">';
echo ChangeStock($sg_code,$year);
echo HtmlInput::submit("sub_change" ,"Valider");
echo dossier::hidden();
- echo
HtmlInput::button_anchor('Retour','?p_action=stock&'.dossier::get());
+ echo
HtmlInput::button_anchor('Retour','?ac='.$_REQUEST['ac'].'&'.dossier::get());
echo '</form>';
echo '</fieldset>';
}
else
- echo
HtmlInput::button_anchor('Retour','?p_action=stock&'.dossier::get());
+ echo
HtmlInput::button_anchor('Retour','?ac='.$_REQUEST['ac'].'&'.dossier::get());
echo '</div>';
@@ -185,7 +172,7 @@
for ( $i = 0; $i < Database::num_row($Res);$i++)
{
$l=Database::fetch_array($Res,$i);
- $url=sprintf("?p_action=stock&year=%d&".dossier::get(),
+ $url=sprintf("?ac=".$_REQUEST['ac']."&year=%d&".dossier::get(),
$l['exercice']);
$r.=HtmlInput::button_anchor($l['exercice'],$url);
}
Modified: phpcompta/branches/rel600-dynamic-menu/include/stock_inc.php
===================================================================
--- phpcompta/trunk/include/stock_inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/stock_inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -25,9 +25,9 @@
/*!
**************************************************
- * \brief show the listing of all goods
- *
+ * \brief show the listing of all goods
*
+ *
*\param $cn database connection
* \param $p_year exercice
* -
@@ -38,7 +38,7 @@
// build sql -- get the different merchandise sold or bought
// during the p_year
/* $sql=" select distinct sg_code
- from stock_goods
+ from stock_goods
left outer join jrnx on (stock_goods.j_id=jrnx.j_id)
right outer join parm_periode on (parm_periode.p_id=jrnx.j_tech_per)
where
@@ -75,7 +75,7 @@
// sg_code and link to details
$result.="<td>".'<a class="one"
-
HREF="?p_action=stock&action=detail&sg_code='.$r['sg_code'].'&year='.$p_year.
+
HREF="?ac='.$_REQUEST['ac'].'&action=detail&sg_code='.$r['sg_code'].'&year='.$p_year.
'&'.dossier::get().'">'.
$r['sg_code']."</A></td>";
@@ -116,12 +116,12 @@
/*!
************************************************************
* \brief return an array of f_id and f_name
- *
- *
+ *
+ *
* \param $p_cn database connection
* \param _sg_code stock_goods.sg_code
* \return
- * - array (f_id, f_label) or null if nothing is found
+ * - array (f_id, f_label) or null if nothing is found
*/
function getFicheNameCode ($p_cn,$p_sg_code)
{
@@ -153,9 +153,9 @@
}
/*!
**************************************************
- * \brief View the details of a stock
- *
- *
+ * \brief View the details of a stock
+ *
+ *
*\param $p_cn database connection
* \param$p_sg_code
* \param $p_year
@@ -315,9 +315,9 @@
}
/*!
**************************************************
- * \brief
- *
- * parm :
+ * \brief
+ *
+ * parm :
* -
* gen :
* -
@@ -344,7 +344,7 @@
}
/*!
- * \brief return the quantity of a sg_code for the period
+ * \brief return the quantity of a sg_code for the period
*
* \return number or NULL
*/
Modified: phpcompta/branches/rel600-dynamic-menu/include/suivi_adm.inc.php
===================================================================
--- phpcompta/trunk/include/suivi_adm.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/suivi_adm.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -22,11 +22,10 @@
/*!\file
* \brief this file is used for the follow up of the customer (mail,
meeting...)
- * - p_action = adm
- * - sb = detail
+ * - sb = detail
* - sc = sv
* - sd = this parameter is used here
- * - $cn = database connection
+ * - $cn = database connection
*/
require_once('class_action.php');
$User->can_request(GECOUR);
@@ -38,8 +37,8 @@
*/
$sub_action=(isset($_REQUEST['sa']))?$_REQUEST['sa']:"list";
$ag_id=(isset($_REQUEST['ag_id']))?$_REQUEST['ag_id']:0;
-$p_action=$_REQUEST['p_action'];
-$base="p_action=$p_action&sc=sv&sb=detail&f_id=".$_REQUEST['f_id'];
+$ac=$_REQUEST['ac'];
+$base="ac=ac&sc=sv&sb=detail&f_id=".$_REQUEST['f_id'];
$retour=HtmlInput::button_anchor('Retour','?'.dossier::get().'&'.$base);
$fiche=new Fiche($cn,$_REQUEST['f_id']);
Modified: phpcompta/branches/rel600-dynamic-menu/include/suivi_client.inc.php
===================================================================
--- phpcompta/trunk/include/suivi_client.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/suivi_client.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -23,13 +23,12 @@
/*!\file
* \brief this file is used for the follow up of the customer (mail,
meeting...)
* - p_action = client
- * - sb = detail
+ * - sb = detail
* - sc = sv
* - sd = this parameter is used here
- * - $cn = database connection
+ * - $cn = database connection
*/
require_once('class_action.php');
-$User->can_request(GECOUR);
load_all_script();
/**
@@ -39,8 +38,8 @@
*/
$sub_action=(isset($_REQUEST['sa']))?$_REQUEST['sa']:"list";
$ag_id=(isset($_REQUEST['ag_id']))?$_REQUEST['ag_id']:0;
-$p_action=$_REQUEST['p_action'];
-$base="p_action=$p_action&sc=sv&sb=detail&f_id=".$_REQUEST['f_id'];
+//$p_action=$_REQUEST['p_action'];
+$base="ac=".$_REQUEST['ac']."&sc=sv&sb=detail&f_id=".$_REQUEST['f_id'];
$retour=HtmlInput::button_anchor('Retour','?'.dossier::get().'&'.$base);
$fiche=new Fiche($cn,$_REQUEST['f_id']);
Modified: phpcompta/branches/rel600-dynamic-menu/include/suivi_supplier.inc.php
===================================================================
--- phpcompta/trunk/include/suivi_supplier.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/suivi_supplier.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -22,11 +22,10 @@
/*!\file
* \brief this file is used for the follow up of the customer (mail,
meeting...)
- * - p_action = supplier
- * - sb = detail
+ * - sb = detail
* - sc = sv
* - sd = this parameter is used here
- * - $cn = database connection
+ * - $cn = database connection
*/
require_once('class_action.php');
$User->can_request(GECOUR);
@@ -38,8 +37,8 @@
*/
$sub_action=(isset($_REQUEST['sa']))?$_REQUEST['sa']:"list";
$ag_id=(isset($_REQUEST['ag_id']))?$_REQUEST['ag_id']:0;
-$p_action=$_REQUEST['p_action'];
-$base="p_action=$p_action&sc=sv&sb=detail&f_id=".$_REQUEST['f_id'];
+$p_action=$_REQUEST['ac'];
+$base="ac=$p_action&sc=sv&sb=detail&f_id=".$_REQUEST['f_id'];
$retour=HtmlInput::button_anchor('Retour','?'.dossier::get().'&'.$base);
$fiche=new Fiche($cn,$_REQUEST['f_id']);
Modified: phpcompta/branches/rel600-dynamic-menu/include/supplier.inc.php
===================================================================
--- phpcompta/trunk/include/supplier.inc.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/supplier.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -30,6 +30,7 @@
require_once('class_iaction.php');
require_once('class_fiche_def.php');
require_once('class_ipopup.php');
+global $User;
$low_action=(isset($_REQUEST['sb']))?$_REQUEST['sb']:"list";
/*! \file
@@ -90,7 +91,7 @@
?>
<input type="submit" class="button" name="submit_query"
value="<?=_('recherche')?>">
- <input type="hidden"
name="p_action" value="supplier">
+ <input type="hidden" name="ac"
value="<?=$_REQUEST['ac']?>">
</form>
</span>
<?php
@@ -133,7 +134,7 @@
}
/*----------------------------------------------------------------------
* Detail for a card, Suivi, Contact, Operation,... *
- * cc stands for supplier card
+ * cc stands for supplier card
*----------------------------------------------------------------------*/
if ( $low_action == 'detail')
{
Modified: phpcompta/branches/rel600-dynamic-menu/include/supplier_card.inc.php
===================================================================
--- phpcompta/trunk/include/supplier_card.inc.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/supplier_card.inc.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -28,14 +28,14 @@
*/
require_once('class_contact.php');
-
+$str_dossier=Dossier::get();
/* $sub_action = sb = detail */
/* $cn database conx */
$return=new IAction();
$return->name='retour';
$return->label='Retour';
-$return->value='?p_action=supplier&'.$str_dossier;
-$root="?p_action=supplier&sb=detail&f_id=".$_REQUEST["f_id"].'&'.$str_dossier;
+$return->value='?ac='.$_REQUEST['ac'].'&'.$str_dossier;
+$root='?ac='.$_REQUEST['ac']."&sb=detail&f_id=".$_REQUEST["f_id"].'&'.$str_dossier;
$ss_action=( isset ($_REQUEST['sc'] ))? $_REQUEST['sc']: '';
switch ($ss_action)
{
@@ -71,7 +71,7 @@
array($root.'&sc=op',_('Opérations'),_('Toutes les
opérations'),4),
array($root.'&sc=bal',_('Balance'),_('Balance du
fournisseur'),7),
array($root.'&sc=let',_('Lettrage'),_('Opérations &
Lettrages'),6),
- array('?p_action=supplier&'.dossier::get(),_('Retour
liste'),_('Retour à la liste des fournisseurs'),5)
+ array('?ac='.$_REQUEST['ac'].'&'.dossier::get(),_('Retour
liste'),_('Retour à la liste des fournisseurs'),5)
),
'H',"mtitle","mtitle",$def,' ');
echo '</div>';
Modified: phpcompta/branches/rel600-dynamic-menu/include/template/dashboard.php
===================================================================
--- phpcompta/trunk/include/template/dashboard.php 2011-09-28 14:19:20 UTC
(rev 4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/template/dashboard.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -2,7 +2,10 @@
<fieldset>
<legend><?=_('Calendrier')?>
</legend>
-<?php echo $cal->display(); ?>
+<?php
+
+echo $cal->display();
+?>
</fieldset>
</div>
<?php
@@ -74,19 +77,19 @@
/*
* Mini Report
*/
-$report=$user->get_mini_report();
+$report=$g_user->get_mini_report();
$rapport=new Acc_Report($cn);
$rapport->id=$report;
if ( $rapport->exist() == false ) {
- $user->set_mini_report(0);
+ $g_user->set_mini_report(0);
$report=0;
}
if ( $report != 0 ) {
echo '<div style="float:left;width:30%">';
echo '<fieldset
style="background-color:white"><legend>'.$rapport->get_name().'</legend>';
- $exercice=$user->get_exercice();
+ $exercice=$g_user->get_exercice();
if ( $exercice == 0 ) {
alert(_('Aucune periode par defaut'));
} else {
Modified: phpcompta/branches/rel600-dynamic-menu/include/user_action_gl.php
===================================================================
--- phpcompta/trunk/include/user_action_gl.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/user_action_gl.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -59,6 +59,7 @@
if (isset($_REQUEST['sb'])) echo HtmlInput::hidden("sb",$_REQUEST['sb']);
if (isset($_REQUEST['sc'])) echo HtmlInput::hidden("sc",$_REQUEST['sc']);
if (isset($_REQUEST['f_id'])) echo HtmlInput::hidden("f_id",$_REQUEST['f_id']);
+if (isset($_REQUEST['ac'])) echo HtmlInput::hidden("ac",$_REQUEST['ac']);
echo dossier::hidden();
Modified: phpcompta/branches/rel600-dynamic-menu/include/user_menu.php
===================================================================
--- phpcompta/trunk/include/user_menu.php 2011-09-28 14:19:20 UTC (rev
4207)
+++ phpcompta/branches/rel600-dynamic-menu/include/user_menu.php
2011-10-13 20:00:17 UTC (rev 4208)
@@ -61,7 +61,7 @@
else $tr="even";
if ( $user->check_dossier($id)!='P')
{
- $target="access.php?gDossier=$id";
+ $target="do.php?gDossier=$id";
}
else
{
@@ -235,7 +235,7 @@
//('rapprt.php','Rapprochement'),
array('user_advanced.php?'.$str_dossier.'&p_action=preod',_('Ecritures
definies'),"",9),
-
+
array('compta.php?p_action=stock&'.$str_dossier,'Stock',_("Gestion des
stocks"),5),
array('user_advanced.php?p_action=defreport&'.$str_dossier,_('Rapport'),_("Rapport"),6),
array('user_advanced.php?p_action=ouv&'.$str_dossier,_('Ecriture
ouverture'),"",8),
@@ -442,7 +442,7 @@
* \note must include javascript : acc_ledger.js
* \return string
*/
-function menu_tool($p_from)
+function menu_tool_deprecated($p_from)
{
if ( ! isset ($_REQUEST['gDossier']))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpcompta-dev] r4208 - in phpcompta/branches: . rel600-dynamic-menu/html rel600-dynamic-menu/include rel600-dynamic-menu/include/template,
phpcompta-dev <=