[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Noalyss-commit] [noalyss] 09/27: Distribution key : add button new
From: |
Dany De Bontridder |
Subject: |
[Noalyss-commit] [noalyss] 09/27: Distribution key : add button new |
Date: |
Thu, 02 Oct 2014 14:23:10 +0000 |
sparkyx pushed a commit to branch master
in repository noalyss.
commit 9a0c52c1112fae407394a23e142ef0dd70bfc17a
Author: Dany De Bontridder <address@hidden>
Date: Tue Sep 16 21:53:07 2014 +0200
Distribution key : add button new
---
include/template/anc_key_display_list.php | 6 ----
include/template/anc_key_input.php | 43 ++++++++++++++++++++++-------
2 files changed, 33 insertions(+), 16 deletions(-)
diff --git a/include/template/anc_key_display_list.php
b/include/template/anc_key_display_list.php
index a2dff19..8ea60ac 100644
--- a/include/template/anc_key_display_list.php
+++ b/include/template/anc_key_display_list.php
@@ -32,12 +32,6 @@
'op'=>'consult',
'key'=>$a_key[$i]['kd_id']
));
-
- /*sprintf(' onclick="anc_key_compute(%s,\'%s\',%s,%s)"',
- Dossier::id(),
- $p_target,
- $p_amount,
- $a_key[$i]['kd_id']);*/
?>
<tr>
<td>
diff --git a/include/template/anc_key_input.php
b/include/template/anc_key_input.php
index caa6180..dde2e59 100644
--- a/include/template/anc_key_input.php
+++ b/include/template/anc_key_input.php
@@ -22,22 +22,27 @@
* all the pa_id and analytic plan
*/
?>
-<form method="post">
+<form method="post" action="do.php">
<?php
echo HtmlInput::request_to_hidden(array('gDossier', 'ac'));
- echo HtmlInput::hidden('key_id', $this->key->getp('id'));
+ echo HtmlInput::hidden('op','consult');
+ echo HtmlInput::hidden('key', $this->key->getp('id'));
+ $name=HtmlInput::default_value_post("name_key",$this->key->getp('name'));
+
$description_text=HtmlInput::default_value_post("description_key",$this->key->getp('description'));
?>
<div class="content">
<div style="width:30%;display:inline-block;min-height: 75px">
- <h1 class="legend">
- <?php echo $this->key->getp('name'); ?>
- </h1>
+ <?php
+ $name=new IText('name_key',$name);
+ echo $name->input();
+ ?>
</div>
<div style="width: 65%;display:inline-block;min-height: 75px">
- <p>
- <?php echo $this->key->getp('description'); ?>
- </p>
-
+ <?php
+ $description=new
IText('description_key',$description_text);
+ $description->css_size='70%';
+ echo $description->input();
+ ?>
</div>
<h2>
<?php echo _('Répartition'); ?>
@@ -61,6 +66,13 @@
</th>
</tr>
<?php
+ $count_row=count($a_row);
+ if ($count_row == 0 ) {
+ $a_row [0]['ke_row']=1;
+ $a_row [0]['ke_percent']=0;
+ $a_row [0]['ke_id']=-1;
+
+ }
for ($j=0; $j<count($a_row); $j++):
?>
<tr>
@@ -133,10 +145,21 @@
</div>
<div style="margin-left: 8%;width:84%;margin-right:8%">
- <?php $jrn=$cn->get_array('select
kl_id,jrn_def_id,jrn_def_name,jrn_def_description from jrn_def
+ <?php
+ if ( $this->key->getp("id") == -1 )
+ {
+ // for a new key
+ $jrn=$cn->get_array('select null as
kl_id,jrn_def_id,jrn_def_name,jrn_def_description
+ from jrn_def
+ order by jrn_def_name ');
+ }else {
+ // for an existing one
+ $jrn=$cn->get_array('select
kl_id,jrn_def_id,jrn_def_name,jrn_def_description
+ from jrn_def
left join key_distribution_ledger
using (jrn_def_id)
where kd_id=$1 or kd_id is null
order by jrn_def_name ',
array($this->key->getp('id')));
+ }
?>
<table id="jrn_def_tb" class="result">
<?php for ($i=0; $i<count($jrn); $i++): ?>
- [Noalyss-commit] [noalyss] branch master updated (59e76cb -> 5864835), Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 04/27: Documentation, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 05/27: Possibilité d'utiliser la comptabilité analytique en mode linéaire (non croisée) Task #1020 - Comptabilité analytique : utilisation non croisée des plans, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 10/27: Distribution key ; bug cosmetique, rappel des valeurs incorrectes, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 07/27: Javascript script : posY, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 08/27: Add new keys, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 12/27: Add documentation add_row_key Task #1021 - Comptabilité analytique : clef de répartition : bouton ajout, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 06/27: Possibilité d'utiliser la comptabilité analytique en mode linéaire (non croisée) Task #1020 - Comptabilité analytique : utilisation non croisée des plans, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 11/27: Distribution key ; bouton ajout ligne Task #1021 - Comptabilité analytique : clef de répartition : bouton ajout, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 02/27: Ajout des clef de répartition pour la comptabilité analytique, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 09/27: Distribution key : add button new,
Dany De Bontridder <=
- [Noalyss-commit] [noalyss] 17/27: remove debug info, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 03/27: Database::make_array ajoute un paramètre dans le cas où le SQL admet une condition, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 16/27: Add p_jrn is the bottom of the popup, to allow the use of distribution key, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 21/27: Ajout fonction pour calculer pourcentage répartition clef, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 20/27: Cosmetique : alignement colonne pourcent, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 14/27: remove debug info, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 13/27: Add documentation add_row_key, remove secund parameter, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 01/27: Ajout des clef de répartition pour la comptabilité analytique, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 24/27: Task #0001030: PRINTBAL : mettre le numéro de compte en première colonne Task #1030 - PRINTBAL : mettre le numéro de compte en première colonne, Dany De Bontridder, 2014/10/02
- [Noalyss-commit] [noalyss] 27/27: Task #1024 : add a message Task #1024 - Comptabiltié analytique : table activité lors confirmation, Dany De Bontridder, 2014/10/02