29$a_repo=
$cn->get_array(
"select distinct t.r_id,r_name,r_adress,r_city,r_country,r_phone from stock_repository as s join tmp_stockgood_detail as t
39<
p><?php echo _(
"Adresse")?> <?php echo
$a_repo[
$r][
'r_adress']?></
p>
40<
p><?php echo _(
"Ville")?> <?php echo
$a_repo[
$r][
'r_city']?></
p>
41<
p><?php echo _(
"Pays")?> <?php echo
$a_repo[
$r][
'r_country']?></
p>
42<
p><?php echo _(
"Téléphone")?> <?php echo
$a_repo[
$r][
'r_phone']?></
p>
45 <
th><?php echo _(
"Code")?></
th>
46 <
th><?php echo _(
"Détail")?></
th>
47 <
th style=
"text-align: right"><?php echo _(
"IN")?></
th>
48 <
th style=
"text-align: right"><?php echo _(
"OUT")?></
th>
49 <
th style=
"text-align: right"><?php echo _(
"En Stock")?></
th>
52 $a_stock=
$cn->get_array(
54 select coalesce(sum(s_qin),0) as qin,coalesce(sum(s_qout),0) as qout,sg_code
55 from tmp_stockgood_detail where r_id=$1 and s_id=$2
60 for (
$s=0;
$s<count($a_stock);
$s++):
63 select f_id,vw_name,quick_code
68 from tmp_stockgood_detail
73 order by vw_name,quick_code
83 for ( $c=0;$c<count(
$a_card);$c++):
84 echo
$sep.HtmlInput::card_detail(
$a_card[$c][
'quick_code'],
$a_card[$c][
'vw_name'],
' class="line" ');
87 if ( count(
$a_card)== 0 ) echo
'<span class="notice">'._(
"Changement manuel").
'</span>';
91 <?php echo
nbm($a_stock[
$s][
'qin'])?>
94 <?php echo
nbm($a_stock[
$s][
'qout'])?>
98 <?php echo
nbm(bcsub($a_stock[
$s][
'qin'],$a_stock[
$s][
'qout']))?>
th($p_string, $p_extra='', $raw='')
h1($p_string, $p_class="")
tr($p_string, $p_extra='')
td($p_string='', $p_extra='')
surround the string with td
nbm($p_number, $p_dec=2)
format the number with a sep.
catch(Exception $exc) if(! $g_user->can_write_action($ag_id)) $r