Beispiel #1
0
 function export_stock_summary_list_form()
 {
     echo '<form style="display:inline"  method="GET" action="export.php">';
     echo HtmlInput::get_to_hidden(array("gDossier", "state_exercice"));
     echo HtmlInput::hidden('act', 'CSV:StockResmList');
     echo HtmlInput::submit('stockresm', 'Export CSV');
     echo '</form>';
 }
Beispiel #2
0
    } else {
        $array = $_GET;
    }
    $array['p_action'] = 'ALL';
    list($sql, $where) = $ledger->build_search_sql($array);
    // Count nb of line
    $max_line = $cn->count_sql($sql);
    list($count, $a) = $ledger->list_operation($sql, $offset, 0);
    $bar = navigation_bar($offset, $max_line, $step, $page);
    echo $bar;
    echo $a;
    echo $bar;
    /*
     * Export to csv
     */
    $r = HtmlInput::get_to_hidden(array('l', 'date_start', 'date_end', 'desc', 'amount_min', 'amount_max', 'qcode', 'accounting', 'unpaid', 'gDossier', 'ledger_type'));
    if (isset($_GET['r_jrn'])) {
        foreach ($_GET['r_jrn'] as $k => $v) {
            $r .= HtmlInput::hidden('r_jrn[' . $k . ']', $v);
        }
    }
    echo '<form action="export.php" method="get">';
    echo $r;
    echo HtmlInput::hidden('act', 'CSV:histo');
    echo HtmlInput::submit('viewsearch', _('Export vers CSV'));
    echo HtmlInput::hidden('p_action', 'ALL');
    ?>
    <input type="button" class="smallbutton" onclick="window.close()" value="<?php 
    echo _('Fermer');
    ?>
">
 */
/* $Revision$ */
// Copyright Author Dany De Bontridder danydb@aevalys.eu
/**
 * @file
 * @brief show box for search
 *
 */
?>
<div id="histo_search_d" class="inner_box" style="width:60%;height:380px;display:none">
	<?php 
echo HtmlInput::title_box(_("Recherche"), "histo_search_d", "hide");
?>
	<form method="GET">
		<?php 
echo HtmlInput::get_to_hidden(array("gDossier", "ac"));
?>
		<table>
			<tr>
				<td> <?php 
echo _("Code Stock");
?>
 </td>
				<td> <?php 
echo $wcode_stock->input();
echo $wcode_stock->search();
?>
 </td>
			</tr>
			<tr>
				<td> <?php 
        }
    } else {
        alert(_("Opération non effacée: vous n'avez pas confirmé"));
    }
}
$profile = $g_user->get_profile();
$gDossier = dossier::id();
$default_exercice = $g_user->get_exercice();
$p_exercice = HtmlInput::default_value_get("p_exercice", $default_exercice);
$a_change = $cn->get_array("select *,to_char(c_date,'DD.MM.YY') as str_date from stock_change as sc\n\t\t\tjoin stock_repository as sr on (sc.r_id=sr.r_id)\n\t\t\twhere sc.r_id in (select r_id from profile_sec_repository where p_id=\$1)\n                         and c_date >= (select min(p_start) from parm_periode where p_exercice = \$2)\n                        and c_date <= (select max(p_end) from parm_periode where p_exercice = \$2)\n\t\torder by c_date", array($profile, $p_exercice));
$exercice = new Exercice($cn);
?>
<div class="content">
    <form method="get" class="print">
      <?php 
echo HtmlInput::get_to_hidden(array('gDossier', 'ac'));
?>
      <?php 
echo $exercice->select('p_exercice', $p_exercice)->input();
?>
      <?php 
echo HtmlInput::submit("filter", _('Valider'));
?>
    </form>
<table class="result">
	<tr>

		<th>
			<?php 
echo _('Date');
?>
echo '<li>' . $radio->input() . _('Opérations rapprochées avec des montants identiques') . '</li>';
$radio->selected = $choice == 3 ? true : false;
$radio->value = 3;
echo '<li>' . $radio->input() . _('Opérations non rapprochées') . '</li>';
echo '</ol>';
echo HtmlInput::submit('vis', _('Visualisation'));
echo '</form>';
echo '<hr>';
echo '</div>';
echo '</div>';
echo '<div class="content">';
if (!isset($_GET['vis'])) {
    return;
}
$acc_reconciliation = new Acc_Reconciliation($cn);
$acc_reconciliation->a_jrn = $r_jrn;
$acc_reconciliation->start_day = $dstart->value;
$acc_reconciliation->end_day = $dend->value;
$array = $acc_reconciliation->get_data($choice);
$gDossier = Dossier::id();
?>
<form method="get" action="export.php">
    <?php 
echo HtmlInput::get_to_hidden(array('ac', 'gDossier', 'p_end', 'p_start', 'choice', 'r_jrn'));
echo HtmlInput::hidden('act', 'CSV:Reconciliation');
echo HtmlInput::submit("csv_bt", "Export CSV");
?>
</form>
<?php 
require_once NOALYSS_INCLUDE . '/template/impress_reconciliation.php';
return;
echo HtmlInput::get_to_hidden(array('gDossier', 'ledger_type', 'ac', 'sa'));
$wLedger = $Ledger->select_ledger('FIN', 3);
if ($wLedger == null) {
    exit('Pas de journal disponible');
}
echo '<div id="jrn_name_div">';
echo '<h2 id="jrn_name" style="display:inline">' . $Ledger->get_name() . '</h2>';
echo '</div>';
$wLedger->javascript = "onchange='this.form.submit()';";
echo $wLedger->input();
echo HtmlInput::submit('ref', 'Rafraîchir');
echo '</form>';
echo '<span id="bkname" style="display:block">' . hb(h($Ledger->get_bank_name())) . '</span>';
echo '<form method="post" id="rec1">';
echo dossier::hidden();
echo HtmlInput::get_to_hidden(array('sa', 'p_action', 'p_jrn'));
$operation = $cn->get_array("select jr_id,jr_internal,\n\t\t\t\t\t\t\t\tjr_comment,\n\t\t\t\t\t\t\t\tto_char(jr_date,'DD.MM.YYYY') as fmt_date,\n\t\t\t\t\t\t\t\tjr_montant,\n\t\t\t\t\t\t\t\tto_char(jr_date,'YYYYMMDD') as raw_date\n                              from jrn where jr_def_id=\$1 and (jr_pj_number is null or jr_pj_number='') order by jr_date", array($Ledger->id));
echo '<p>';
$iextrait = new IText('ext');
if (isset($_POST['ext'])) {
    $iextrait->value = $_POST['ext'];
} else {
    $iextrait->value = $Ledger->guess_pj();
}
$nstart_extrait = new INum('start_extrait');
if (isset($_POST['start_extrait'])) {
    $nstart_extrait->value = $_POST['start_extrait'];
}
$nend_extrait = new INum('end_extrait');
if (isset($_POST['end_extrait'])) {
    $nend_extrait->value = $_POST['end_extrait'];
Beispiel #7
0
    echo "</form></TD>";
    echo '<TD><form method="GET" ACTION="export.php">' . HtmlInput::submit('bt_csv', "Export CSV") . dossier::hidden() . 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']);
    for ($e = 0; $e < count($selected); $e++) {
        if (isset($selected[$e]) && in_array($selected[$e], $array)) {
            echo HtmlInput::hidden("r_jrn[{$e}]", $selected[$e]);
        }
    }
    for ($e = 0; $e < count($array_cat); $e++) {
        if (isset($select_cat[$e])) {
            echo HtmlInput::hidden("r_cat[{$e}]", $e);
        }
    }
    echo HtmlInput::hidden("from_poste", $_GET['from_poste']) . HtmlInput::hidden("to_poste", $_GET['to_poste']);
    echo HtmlInput::get_to_hidden(array('unsold', 'previous_exc'));
    echo "</form></TD>";
    echo '<td style="vertical-align:top">';
    echo HtmlInput::print_window();
    echo '</td>';
    echo "</TR>";
    echo "</table>";
}
//-----------------------------------------------------
// Display result
//-----------------------------------------------------
if (isset($_GET['view'])) {
    $bal = new Acc_Balance($cn);
    if ($_GET['p_filter'] == 1) {
        for ($e = 0; $e < count($selected); $e++) {
            if (isset($selected[$e]) && in_array($selected[$e], $array)) {
    echo '<span class="notice"> ' . _('Attention : si le bilan n\'est pas équilibré.<br> Vérifiez <ul>
       <li>L\'affectation du résultat est fait</li>
       <li>Vos comptes actifs ont  un solde débiteur (sauf les comptes dit inversés)</li>
       <li> les comptes passifs ont un solde créditeur (sauf les comptes dit inversés) </li>
       </ul>
       Utilisez la balance des comptes pour vérifier.') . ' </span>';
    echo HtmlInput::submit('verif', _('Verification comptabilite'));
    echo HtmlInput::get_to_hidden(array('ac', 'exercice'));
    echo '</FORM>';
}
if (isset($_GET['verif'])) {
    $periode = new Periode($cn);
    $date_from = $periode->first_day($bilan->from);
    $date_to = $periode->last_day($bilan->to);
    echo '<h2>' . _('Etape 2 :Impression') . "   " . $date_from . '-' . $date_to . '</h2>';
    $bilan->get_request_get();
    $bilan->verify();
    $url_verify = http_build_query(array('ac' => 'VERIFBIL', 'gDossier' => dossier::id()));
    echo _('Pour une vérification complète, allez dans ') . '<a class="line" TARGET="_blank" href="?' . $url_verify . '"> VERIFBIL</a>';
    echo '<FORM METHOD="GET" ACTION="export.php">';
    echo dossier::hidden();
    echo HtmlInput::get_to_hidden(array('exercice'));
    echo HtmlInput::hidden('b_id', $_GET['b_id']);
    echo HtmlInput::hidden('act', 'OTH:Bilan');
    echo HtmlInput::hidden('from_periode', $bilan->from);
    echo HtmlInput::hidden('to_periode', $bilan->to);
    echo HtmlInput::submit('Impression', 'Impression');
    echo '</form>';
}
echo '<hr>';
echo '</div>';
//-----------------------------------------------------
// Form
//-----------------------------------------------------
echo '<div class="content">';
$exercice = isset($_GET['exercice']) ? $_GET['exercice'] : $g_user->get_exercice();
/*
 * Let you change the exercice
 */
echo '<fieldset><legend>' . _('Exercice') . '</legend>';
echo '<form method="GET">';
echo 'Choisissez un autre exercice :';
$ex = new Exercice($cn);
$wex = $ex->select('exercice', $exercice, ' onchange="submit(this)"');
echo $wex->input();
echo dossier::hidden();
echo HtmlInput::get_to_hidden(array('ac', 'type'));
echo '</form>';
echo '</fieldset>';
echo '<FORM METHOD="GET">';
$hidden = new IHidden();
echo $hidden->input("ac", $_GET['ac']);
echo $hidden->input("type", "rapport");
echo dossier::hidden();
echo '<TABLE><TR>';
$w = new ISelect();
$w->table = 1;
print td(_("Choisissez le rapport"));
print $w->input("form_id", $ret);
print '</TR>';
//-- calendrier ou periode comptable
$aCal = array(array('value' => 0, 'label' => _('P&eacute;riode comptable')), array('value' => 1, 'label' => _('Calendrier')));