function input_value() { $code_invoice = new IText('code_invoice', $this->a_menu_def['code_invoice']); $code_follow = new IText('code_follow', $this->a_menu_def['code_follow']); echo '<p>' . _('Code pour création facture depuis gestion') . $code_invoice->input() . '</p>'; echo '<p>' . _('Code pour appel gestion') . $code_follow->input() . '</p>'; }
/** * @brief Propose to save the operation into a predefined operation * @return HTML string */ static function save_propose() { $r = ""; $r .= '<p class="decale">'; $r .= _("Donnez un nom pour sauver cette opération comme modèle") . " <br>"; $opd_name = new IText('opd_name'); $r .= "Nom du modèle " . $opd_name->input(); $opd_description = new ITextarea('od_description'); $opd_description->style = ' class="itextarea" style="width:30em;height:4em;vertical-align:top"'; $r .= '</p>'; $r .= '<p class="decale">'; $r .= _('Description (max 50 car.)'); $r .= '<br>'; $r .= $opd_description->input(); $r .= '</p>'; return $r; }
if (isset($_POST['add'])) { $obj = new Anc_Group($cn); $obj->get_from_array($_POST); echo $obj->insert(); } $array = $r->myList(); echo '<div class="content" >'; echo '<form method="post">'; echo dossier::hidden(); echo '<table class="result" >'; echo '<tr> <th>' . _("Code") . " </th><th>" . _("Plan") . " </td><th>" . _("Description") . '</th></tr>'; foreach ($array as $idx => $m) { echo '<tr>'; echo '<td>' . h($m->ga_id) . '</td>'; echo '<td>' . h($m->pa_name) . '</td>'; echo '<td>' . h($m->ga_description) . '</td>'; echo '<td> Effacer <input type="Checkbox" name="ck[]" value="' . $m->ga_id . '">' . '</td>'; echo '</tr>'; } $w = new IText("ga_id"); $wDesc = new IText("ga_description"); $val_pa_id = $cn->make_array("select pa_id,pa_name from plan_analytique"); $wPa_id = new ISelect("pa_id"); $wPa_id->value = $val_pa_id; echo "<td>" . $w->input() . "</td>"; echo "<td>" . $wPa_id->input("pa_id") . "</td>"; echo "<td>" . $wDesc->input("ga_description") . HtmlInput::submit('add', _('Ajouter')) . "</td>"; echo '</table>'; echo "<hr>"; echo HtmlInput::submit('remove', _('Effacer')); echo '</div>';
<table> <tr> <td><?php echo _(" Bon de commande"); ?> :</td><td> <?php echo HtmlInput::infobulle(31) . " " . $cmd->input(); ?> </td> </tr> <tr> <td> <?php echo _("Autre information"); ?> : </td><td><?php echo HtmlInput::infobulle(30) . " " . $other->input(); ?> </td> </tr> </table> </div> <div id="linked_operation_div<?php echo $div; ?> " style="display:<?php echo $a_tab['linked_operation_div']['display']; ?> " class="myfieldset"> <?php // display title only in popup if ($div == 'popup') {
echo HtmlInput::title_box("Modèle de document", "mod_doc", 'hide'); ?> <form method="post" enctype="multipart/form-data"> <table> <tr> <td><?php echo _("Nom du document"); ?> </td> <td> <?php $a = new IText('md_name'); $a->value = $doc->md_name; echo $a->input(); ?> </td> </tr> <tr> <td> <?php echo _("Catégorie de document"); ?> </td> <td> <?php // Load all the category $w = new ISelect(); $w->name = "md_type";
function display_form($p_string = '') { $r = parent::display_form($p_string); // show the second plan $r .= '<span style="padding:5px;margin:5px;border:2px double blue;display:block;">'; $plan = new Anc_Plan($this->db); $plan_id = new ISelect("pa_id2"); $plan_id->value = $this->db->make_array("select pa_id, pa_name from plan_analytique order by pa_name"); $plan_id->selected = $this->pa_id2; $r .= "Plan Analytique :" . $plan_id->input(); $r .= HtmlInput::request_to_hidden(array('ac')); $poste = new IText(); $poste->size = 10; $r .= "Entre le poste " . $poste->input("from_poste2", $this->from_poste2); $choose = new IButton(); $choose->name = "Choix Poste"; $choose->label = _("Recherche"); $choose->javascript = "onClick=search_ca(" . dossier::id() . ",'from_poste2','pa_id2')"; $r .= $choose->input(); $r .= " et le poste " . $poste->input("to_poste2", $this->to_poste2); $choose->javascript = "onClick=search_ca(" . dossier::id() . ",'to_poste2','pa_id2')"; $r .= $choose->input(); $r .= '<span class="notice" style="display:block">' . _('Selectionnez le plan qui vous intéresse avant de cliquer sur Recherche') . '</span>'; $r .= '</span>'; $r .= HtmlInput::submit('Affiche', _('Rechercher')); return $r; }
</tr> <tr> <td> <?php $itext = new IText('npj'); $itext->value = strip_tags($obj->det->jr_pj_number); echo td(_('Pièce')) . td($itext->input()); ?> </td> <tr> <td> <?php $itext = new IText('lib'); $itext->value = strip_tags($obj->det->jr_comment); $itext->size = 40; echo td(_('Libellé')) . td($itext->input(), ' colspan="2" '); ?> </td> </tr> <tr> <td></td> <td>Payé</td> <td> <?php $ipaid = new ICheckBox("ipaid", 'paid'); $ipaid->selected = $obj->det->jr_rapt == 'paid'; echo $ipaid->input(); ?> </td> </tr>
require_once NOALYSS_INCLUDE . '/template/impress_cat_card.php'; echo HtmlInput::submit('cat_display', _('Recherche')); echo '</FORM>'; $search_card = new IText('card_search'); $search_card_js = sprintf('onclick="boxsearch_card(\'%d\')"', dossier::id()); ?> <div id="box_search_card"> <?php echo _('Recherche de fiche'); ?> <?php echo HtmlInput::infobulle(18); ?> :<?php echo $search_card->input(); ?> <?php echo HtmlInput::button_anchor(_("Chercher"), "javascript:void(0)", "", $search_card_js, 'smallbutton'); ?> </div> <?php echo '</div>'; $str = "if (g('histo').value==3 || g('histo').value== -1 ) {\n g('trstart').style.display='none';g('trend').style.display='none';g('allcard').style.display='none';}\n else {g('trstart').style.display='';g('trend').style.display='';g('allcard').style.display='';}\n\t if ( g('histo').value== -1 ) { g('allcard').style.display='';}\n\n\t"; echo create_script($str); echo '<hr>'; //----------------------------------------------------- if (!isset($_GET['cat_display'])) { return; } $fd_id = $_GET['cat'];
function Input() { $r = ""; $h = new IHidden(); $r .= '<li>Id :' . $h->input('frd_id', $this->frd_id) . $this->frd_id . "</li>"; $w = new IText(); $r .= '<li>' . _('Commentaire ') . ' :' . $w->input('frd_text', $this->frd_text) . "</li>"; $t = new IText(); $r .= '<li>' . _('Poste de base') . ':' . $t->input('frd_class_base', $this->frd_class_base) . "</li>"; return $r; }
/** * display screen to enter a new ledger */ function input_new() { $retry = HtmlInput::default_value_post("sa", ""); // if ( $retry == "add") { $default_type = HtmlInput::default_value_post("p_jrn_type", -1); $previous_jrn_def_pj_pref = HtmlInput::default_value_post("jrn_def_pj_pref", ""); $previous_p_description = HtmlInput::default_value_post("p_description", ""); $previous_p_jrn_name = HtmlInput::default_value_post('p_jrn_name', ''); $previous_p_jrn_type = HtmlInput::default_value_post("p_jrn_type", ""); // } global $g_user; $f_add_button = new ISmallButton('add_card'); $f_add_button->label = _('Créer une nouvelle fiche'); $f_add_button->tabindex = -1; $f_add_button->set_attribute('jrn', -1); $f_add_button->javascript = " this.jrn=-1;select_card_type({type_cat:4});"; $str_add_button = ""; if ($g_user->check_action(FICADD) == 1) { $str_add_button = $f_add_button->input(); } $wSearch = new IPoste(); $wSearch->table = 3; $wSearch->set_attribute('ipopup', 'ipop_account'); $wSearch->set_attribute('account', 'p_jrn_class_deb'); $wSearch->set_attribute('no_overwrite', '1'); $wSearch->set_attribute('noquery', '1'); $wSearch->name = "p_jrn_class_deb"; $wSearch->size = 20; $search = $wSearch->input(); // default for ACH $default_deb_purchase = $this->get_default_card('ACH', 'D'); $default_cred_purchase = $this->get_default_card('ACH', 'C'); // default for VEN $default_deb_sale = $this->get_default_card('VEN', 'D'); $default_cred_sale = $this->get_default_card('VEN', 'C'); // default for FIN $default_fin = $this->get_default_card("FIN", ""); //default ods $default_ods = $this->get_default_card("ODS", ""); /* construct all the hidden */ $hidden = HtmlInput::hidden('p_jrn', -1); $hidden .= HtmlInput::hidden('p_action', 'jrn'); $hidden .= HtmlInput::hidden('sa', 'add'); $hidden .= dossier::hidden(); $hidden .= HtmlInput::hidden('p_jrn_deb_max_line', 10); $hidden .= HtmlInput::hidden('p_ech_lib', 'echeance'); /* properties of the ledger */ $name = $previous_p_jrn_name; $code = ""; $wType = new ISelect(); $a_jrn = $this->db->make_array("select '-1',' -- " . _("choix du type de journal") . " -- ' union select jrn_type_id,jrn_desc from jrn_type"); $wType->selected = '-1'; $wType->value = $a_jrn; $wType->name = "p_jrn_type"; $wType->id = "p_jrn_type_select_id"; $wType->javascript = ' onchange="show_ledger_div()"'; $wType->selected = $default_type; $type = $wType->input(); $rcred = $rdeb = array(); $wPjPref = new IText(); $wPjPref->name = 'jrn_def_pj_pref'; $wPjPref->value = $previous_jrn_def_pj_pref; $pj_pref = $wPjPref->input(); $pj_seq = ''; $last_seq = 0; $new = 1; $description = new ITextarea('p_description'); $description->style = 'class="itextarea" style="margin:0px;"'; $description->value = $previous_p_description; $str_description = $description->input(); /* bank card */ $qcode_bank = ''; /* Numbering (only FIN) */ $num_op = new ICheckBox('numb_operation'); echo dossier::hidden(); echo HtmlInput::hidden('ac', $_REQUEST['ac']); echo $hidden; $cn = $this->db; $min_row = new INum("min_row", MAX_ARTICLE); $min_row->prec = 0; require_once NOALYSS_INCLUDE . '/template/param_jrn.php'; }
/** *@brief return an html with a form to add a new middle of payment */ public function blank() { //label $lib = new IText('mp_lib'); $f_lib = $lib->input(); $ledger_source = new ISelect('jrn_def_id'); $ledger_source->value = $this->cn->make_array("select jrn_def_id,jrn_Def_name from\n jrn_def where jrn_def_type in ('ACH','VEN') order by jrn_def_name"); $f_source = $ledger_source->input(); // type of card $tcard = new ISelect('mp_fd_id'); $tcard->value = $this->cn->make_array('select fd_id,fd_label from fiche_def join fiche_def_ref ' . ' using (frd_id) where frd_id in (25,4) order by fd_label'); $f_type_fiche = $tcard->input(); $ledger_record = new ISelect('mp_jrn_def_id'); $ledger_record->value = $this->cn->make_array("select jrn_def_id,jrn_Def_name from\n jrn_def where jrn_def_type in ('ODS','FIN')"); $f_ledger_record = $ledger_record->input(); // the card $qcode = new ICard(); $qcode->noadd = true; $qcode->name = 'mp_qcode'; $list = $this->cn->make_list('select fd_id from fiche_def where frd_id in (25,4)'); $qcode->typecard = $list; $qcode->dblclick = 'fill_ipopcard(this);'; $f_qcode = $qcode->input(); $msg = "Ajout d'un nouveau moyen de paiement"; ob_start(); require_once NOALYSS_INCLUDE . '/template/new_mod_payment.php'; $r = ob_get_contents(); ob_end_clean(); return $r; }
$alpha_num->selected = $my->MY_ALPHANUM; $updlab = new ISelect(); $updlab->table = 1; $updlab->value = $updlab_array; $updlab->selected = $my->MY_UPDLAB; $stock = new ISelect('p_stock'); $stock->value = array(array('value' => 'N', 'label' => _('Non')), array('value' => 'Y', 'label' => _('Oui'))); $stock->selected = $my->MY_STOCK; $stock->table = 1; // other parameters $all = new IText(); $all->table = 1; echo '<form method="post" >'; echo dossier::hidden(); echo "<table class=\"result\" style=\"width:auto\">"; echo "<tr>" . td(_('Nom société'), 'style="text-align:right"') . $all->input("p_name", $my->MY_NAME) . "</tr>"; $all->value = ''; echo "<tr>" . td(_("Téléphone"), 'style="text-align:right"') . $all->input("p_tel", $my->MY_TEL) . "</tr>"; $all->value = ''; echo "<tr>" . td(_("Fax"), 'style="text-align:right"') . $all->input("p_fax", $my->MY_FAX) . "</tr>"; $all->value = ''; echo "<tr>" . td(_("Rue "), 'style="text-align:right"') . $all->input("p_street", $my->MY_STREET) . "</tr>"; $all->value = ''; echo "<tr>" . td(_("Numéro"), 'style="text-align:right"') . $all->input("p_no", $my->MY_NUMBER) . "</tr>"; $all->value = ''; echo "<tr>" . td(_("Code Postal"), 'style="text-align:right"') . $all->input("p_cp", $my->MY_CP) . "</tr>"; $all->value = ''; echo "<tr>" . td(_("Commune"), 'style="text-align:right"') . $all->input("p_Commune", $my->MY_COMMUNE) . "</tr>"; $all->value = ''; echo "<tr>" . td(_("Pays"), 'style="text-align:right"') . $all->input("p_pays", $my->MY_PAYS) . "</tr>"; $all->value = '';
//see licence.txt echo Dossier::hidden(); echo HtmlInput::hidden('t_id', $data->t_id); echo HtmlInput::hidden('ac', $_REQUEST['ac']); $uos = new Tool_Uos('tag'); echo $uos->hidden(); $t_tag = new IText('t_tag', $data->t_tag); $t_description = new ITextarea('t_description', $data->t_description); $t_description->style = ' class="itextarea" style="height:5em;vertical-align: top;"'; ?> <p> <?php echo _("Etiquette (tag)"); ?> : <?php echo $t_tag->input(); ?> </p> <p> <?php echo _("Description"); ?> : <?php echo $t_description->input(); ?> </p> <?php // If exist you can remove it if ($data->t_id != '-1') { ?> <p><?php
/** * @brief show the form for loading a template * @param p_action for the field action = destination url * * * @return string containing the forms */ function form() { $r = '<p class="notice">'; $r .= 'Veuillez introduire les modèles servant à générer vos documents'; $r .= '</p>'; $r .= '<form enctype="multipart/form-data" method="post">'; $r .= dossier::hidden(); // we need to add the sub action as hidden $h = new IHidden(); $h->name = "sa"; $h->value = "add_document"; $r .= $h->input(); $r .= '<table>'; $t = new IText(); $t->name = "md_name"; $r .= "<tr><td> Nom </td><td>" . $t->input() . "</td>"; $r .= "</tr>"; $r .= "<tr><td>Catégorie de document </td>"; $w = new ISelect(); $w->name = "md_type"; $w->value = $this->cn->make_array('select dt_id,dt_value from document_type order by dt_value'); $r .= "<td>" . $w->input() . "</td></tr>"; $r .= '<tr>'; $r .= td(_('Affectation')); $waffect = new ISelect(); $waffect->name = 'md_affect'; $waffect->value = array(array('value' => 'ACH', 'label' => _('Uniquement journaux achat')), array('value' => 'VEN', 'label' => _('Uniquement journaux vente')), array('value' => 'GES', 'label' => _('Partie gestion'))); $r .= td($waffect->input()); $r .= '</tr>'; $f = new IFile(); $f->name = "doc"; $r .= "<tr><td>fichier</td><td> " . $f->input() . "</td></tr>"; $start = new IText(); $start->name = "start_seq"; $start->size = 9; $start->value = "0"; $r .= "<tr><td> Numerotation commence a</td><td> " . $start->input() . "</td>"; $r .= '<td class="notice">Si vous laissez à 0, la numérotation ne changera pas, la prochaine facture sera n+1, n étant le n° que vous avez donné</td>'; $r .= "</tr>"; $r .= '</table>'; $r .= HtmlInput::submit('add_document', 'Ajout'); $r .= "</form></p>"; return $r; }
if (!defined('ALLOWED')) { die('Appel direct ne sont pas permis'); } require_once NOALYSS_INCLUDE . '/class_document_type.php'; if (isset($_POST['add'])) { $catDoc = new Document_Type($cn); $catDoc->insert($_POST['cat'], $_POST['prefix']); } if (isset($_POST['save'])) { $catDoc = new Document_Type($cn, $_POST['dt_id']); $catDoc->get(); $catDoc->dt_value = trim($_POST['dt_name']); $catDoc->dt_prefix = trim($_POST['dt_prefix']); if ($catDoc->dt_value == "") { alert(_("Le nom ne peut pas être vide")); } else { $catDoc->update(); } if ($_POST['seq'] != 0 && isNumber($_POST['seq']) == 1) { $catDoc->set_number($_POST['seq']); } } $aList = Document_Type::get_list($cn); $addCat = new IText('cat'); $addPrefix = new IText('prefix'); $str_addCat = $addCat->input(); $str_addPrefix = $addPrefix->input(); $str_submit = HtmlInput::submit('add', _('Ajout')); echo '<div class="content">'; require_once NOALYSS_INCLUDE . '/template/list_category_document.php'; echo '</div>';
?> </td> </tr> <tr> <td> <?php echo td(_('Montant')) . td(nbm($obj->det->jr_montant), ' class="inum"'); ?> </td> </tr> <tr> <td> <?php $itext = new IText('npj'); $itext->value = strip_tags($obj->det->jr_pj_number); echo td(_('Pièce')) . td($itext->input()); ?> </td> </tr> </table> </td> <td style="width:50%;height:100%;vertical-align:top;text-align: center"> <table style="width:99%;height:8rem;vertical-align:top;"> <tr style="height: 5%"> <td style="text-align:center;vertical-align: top"> Note </td></tr> <tr> <td style="text-align:center;vertical-align: top"> <?php $inote = new ITextarea('jrn_note');
function DisplayAttribut($str = "") { if ($this->id == 0) { return; } $this->cn->exec_sql('select fiche_attribut_synchro($1)', array($this->id)); $MaxLine = sizeof($this->attribut); $r = "<TABLE>"; $r .= "<tr>" . th('Nom attribut') . th('') . th('Ordre', 'style="text-align:right"') . '</tr>'; // Display each attribute $add_action = ""; for ($i = 0; $i < $MaxLine; $i++) { $class = "even"; if ($i % 2 == 0) { $class = "odd"; } $r .= '<TR class="' . $class . '"><td>'; // Can change the name if ($this->attribut[$i]->ad_id == ATTR_DEF_NAME) { continue; } else { if ($str == "remove") { //Only for the not mandatory attribute (not defined in attr_min) if ($this->cn->count_sql("select * from attr_min where frd_id=" . $this->fiche_def . " and ad_id = " . $this->attribut[$i]->ad_id) == 0 && $this->attribut[$i]->ad_id != ATTR_DEF_QUICKCODE && $this->attribut[$i]->ad_id != ATTR_DEF_ACCOUNT) { $add_action = sprintf('</TD><TD> Supprimer <input type="checkbox" name="chk_remove[]" value="%d">', $this->attribut[$i]->ad_id); } else { $add_action = "</td><td>"; } } // The attribut. $a = sprintf('%s ', $this->attribut[$i]->ad_text); $r .= $a . $add_action; /*---------------------------------------- */ /* ORDER OF THE CARD */ /*---------------------------------------- */ $order = new IText(); $order->name = 'jnt_order' . $this->attribut[$i]->ad_id; $order->size = 3; $order->value = $this->attribut[$i]->jnt_order; $r .= '</td><td> ' . $order->input(); } $r .= '</td></tr>'; } // Show the possible attribute which are not already attribute of the model // of card $Res = $this->cn->exec_sql("select ad_id,ad_text from attr_def\n where\n ad_id not in (select ad_id from fiche_def natural join jnt_fic_attr\n where fd_id=\$1) order by ad_text", array($this->id)); $M = Database::num_row($Res); // Show the unused attribute $r .= '<TR> <TD>'; $r .= '<SELECT NAME="ad_id">'; for ($i = 0; $i < $M; $i++) { $l = Database::fetch_array($Res, $i); $a = sprintf('<OPTION VALUE="%s"> %s', $l['ad_id'], $l['ad_text']); $r .= $a; } $r .= '</SELECT>'; $r .= "</TABLE>"; return $r; }
<?php $name = new IText('dt_name', $doc_type->dt_value); echo $name->input(); ?> </td> </tr> <tr> <td><?php echo _('Préfixe'); ?> </td> <td> <?php $prefix = new IText('dt_prefix', $doc_type->dt_prefix); echo $prefix->input(); ?> </td> </tr> <tr> <td><?php echo _('numéro actuel'); ?> </td> <td> <?php $ret = $cn->get_array("select last_value,is_called from seq_doc_type_" . $doc_type->dt_id); $last = $ret[0]['last_value']; /*! *\note With PSQL sequence , the last_value column is 1 when before AND after the first call, to make the difference between them
<tr> <td> Pays </td> <td> <?php $name = new IText("r_country", ""); echo $name->input(); ?> </td> </tr> <tr> <td> Téléphone </td> <td> <?php $name = new IText("r_phone", ""); echo $name->input(); ?> </td> </tr> </table> <?php echo HtmlInput::submit("add_stock", "Sauver"); ?> </form> </div> </div>
public function input($p_name = null, $p_value = null) { $this->name = $p_name == null ? $this->name : $p_name; $this->value = $p_value == null ? $this->value : $p_value; if ($this->readOnly == true) { return $this->display(); } //-- if (!isset($this->ctrl)) { $this->ctrl = 'none'; } if (!isset($this->javascript)) { $this->javascript = ""; } $this->id = $this->id == "" ? $this->name : $this->id; /* create the text */ $itext = new IText($this->name, $this->value, $this->id); if (isset($this->css_size)) { $itext->css_size = $this->css_size; } else { $itext->size = $this->size; } $itext->javascript = $this->javascript; /* create the button */ $ibutton = $this->dsp_button(); if ($this->table == 3) { $r = '<table>' . tr(td($itext->input()) . td($ibutton)); $r .= '</table>'; return $r; } $r = $itext->input() . $ibutton; if ($this->table == 1) { $r = td($r); } return $r; //-- }
<div id="add_todo_list" class="box" style="display:none"> <script charset="utf-8" type="text/javascript" language="javascript"> new Draggable($('add_todo_list'),{}); </script> <form method="post"> <?php $wDate = new IDate('p_date_todo'); $wDate->id = 'p_date_todo'; $wTitle = new IText('p_title'); $wDesc = new ITextArea('p_desc'); $wDesc->heigh = 5; $wDesc->width = 40; echo HtmlInput::title_box("Note", "add_todo_list", "hide"); echo _("Date") . " " . $wDate->input() . '<br>'; echo _("Titre") . " " . $wTitle->input() . '<br>'; echo _("Description") . "<br>" . $wDesc->input() . '<br>'; echo dossier::hidden(); echo HtmlInput::hidden('tl_id', 0); echo HtmlInput::submit('save_todo_list', _('Sauve'), 'onClick="Effect.Fold(\'add_todo_list\');return true;"'); echo HtmlInput::button('hide', _('Annuler'), 'onClick="Effect.Fold(\'add_todo_list\');return true;"'); ?> </form> </div> <script type="text/javascript" language="javascript" charset="utf-8"> function display_detail(div) { $(div).style.display="block"; // $(div).style.top=calcy('150')+'px'; //Effect.Grow(div,{}); }
if ($cn->get_value("select count(*) from profile join profile_user using (p_id)\n\t\twhere user_name=\$1 and with_direct_form=true", array($_SESSION['g_user'])) == 1) { ?> <div id="direct"> <form method="get"> <?php echo HtmlInput::default_value('ac', '', $_REQUEST); ?> <?php echo Dossier::hidden(); ?> <?php $direct = new IText('ac'); $direct->style = 'class="input_text"'; $direct->value = ''; $direct->size = 20; echo $direct->input(); $gDossier = dossier::id(); ?> <div id="ac_choices" class="autocomplete" style="width:150"></div> <?php echo HtmlInput::submit('go', _('Aller')); ?> </form> <script> try { new Ajax.Autocompleter("ac","ac_choices","direct.php?gDossier=<?php echo $gDossier; ?> ",
$select_type->selected = $row->get_parameter('type'); $desc->value = $row->get_parameter('desc'); $size->value = $row->get_parameter('size'); $extra->value = $row->get_parameter('extra'); $remove = new IButton('rmfa' . $e); $remove->label = _('Effacer'); if ($row->get_parameter('id') >= 9000) { $select_type->readOnly = false; $desc->readOnly = false; $size->readOnly = false; $extra->readOnly = false; $desc->style = ' class="input_text" '; $r .= td($desc->input()); $r .= td($select_type->input()); $r .= td($size->input()); $r .= td($extra->input()); $remove->javascript = sprintf('confirm_box(\'tb_rmfa\',\'Vous confirmez ?\',function() { removeCardAttribut(%d,%d,\'tb_rmfa\',$(\'rmfa%d\') );})', $row->get_parameter('id'), $gDossier, $e); $msg = '<span class="notice">' . _("Attention : effacera les données qui y sont liées") . ' </span>'; $r .= td($remove->input() . $msg); } else { $select_type->readOnly = true; $desc->readOnly = true; $size->readOnly = true; $extra->readOnly = true; $r .= td($desc->input() . HtmlInput::hidden('type[]', '')); $r .= td($select_type->input()); $r .= td($size->input()); $r .= td($extra->input()); $r .= td(""); } echo tr($r);
?> </td> <td> <INPUT class="input_text" type="text" NAME="email" value="<?php echo $UserChange->email; ?> "> </td> </tr> <tr> <td> Mot de passe :<span class="info">Laisser à VIDE pour ne PAS le changer</span> </td> <td> <?php echo $it_pass->input(); ?> </td> </tr> <tr> <td> <?php echo _('Actif'); ?> </td> <td> <?php $select_actif = new ISelect('Actif'); $select_actif->value = array(array('value' => 0, 'label' => _('Non')), array('value' => 1, 'label' => _('Oui'))); $select_actif->selected = $UserChange->active; echo $select_actif->input();
*/ if (!defined('ALLOWED')) { die('Appel direct ne sont pas permis'); } ob_start(); require_once NOALYSS_INCLUDE . '/class_pre_operation.php'; $op = new Pre_Operation($cn, $_GET['id']); $array = $op->load(); echo HtmlInput::anchor_close('mod_predf_op'); echo h2(_('Modification du nom'), ' class="title"'); echo ' <form method="POST" onsubmit="save_predf_op(this);return false;">'; $name = new IText('opd_name'); $name->value = $op->od_name; $name->size = 60; echo "Nom =" . $name->input(); $opd_description = new ITextarea('od_description'); $opd_description->style = ' class="itextarea" style="width:30em;height:4em;vertical-align:top"'; $opd_description->value = $op->od_description; echo '<p>'; echo _("Description (max 50 car.)"); echo $opd_description->input(); echo '</p>'; echo dossier::hidden() . HtmlInput::hidden('od_id', $_GET['id']); echo "<hr>"; ////////////////////////////////////////////////////////////////////////////// // Detail operation ////////////////////////////////////////////////////////////////////////////// echo $op->display(); echo HtmlInput::submit('save', _('Sauve')); echo HtmlInput::button('close', _('Annuler'), 'onclick="removeDiv(\'mod_predf_op\')"');
if (!defined('ALLOWED')) { die('Appel direct ne sont pas permis'); } ob_start(); $ag_id = HtmlInput::default_value_get("ag_id", "0"); if ($ag_id == 0) { throw new Exception('ag_id is null'); } require_once 'class_acc_ledger.php'; $r = HtmlInput::title_box(_("Détail fiche"), 'search_card'); $r .= '<form id="search_card1_frm" method="GET" onsubmit="action_add_concerned_card(this);return false;">'; $q = new IText('query'); $q->value = isset($query) ? $query : ''; $r .= '<span style="margin-left:50px">'; $r .= _('Fiche contenant') . HtmlInput::infobulle(19); $r .= $q->input(); $r .= HtmlInput::submit('fs', _('Recherche'), "", "smallbutton"); $r .= '</span>'; $r .= dossier::hidden() . HtmlInput::hidden('op', 'add_concerned_card'); $r .= HtmlInput::request_to_hidden(array('ag_id')); $r .= '</form>'; $query = HtmlInput::default_value_get("query", ""); $sql_array['query'] = $query; $sql_array['typecard'] = 'all'; $fiche = new Fiche($cn); /* Build the SQL and show result */ $sql = $fiche->build_sql($sql_array); /* We limit the search to MAX_SEARCH_CARD records */ $sql = $sql . ' order by vw_name limit ' . MAX_SEARCH_CARD; $a = $cn->get_array($sql); for ($i = 0; $i < count($a); $i++) {
function form($p_line = 0) { $r = ""; if ($p_line == 0) { $p_line = count($this->aAcc_Report_row); } $r .= dossier::hidden(); $r .= HtmlInput::hidden('line', $p_line); $r .= HtmlInput::hidden('fr_id', $this->id); $wForm = new IText(); $r .= "Nom du rapport : "; $r .= $wForm->input('form_nom', $this->name); $r .= '<TABLE id="rap1" width="100%">'; $r .= "<TR>"; $r .= "<TH> Position </TH>"; $r .= "<TH> Texte </TH>"; $r .= "<TH> Formule</TH>"; $r .= '</TR>'; $wName = new IText(); $wName->size = 40; $wPos = new IText(); $wPos->size = 3; $wForm = new IText(); $wForm->size = 35; for ($i = 0; $i < $p_line; $i++) { $r .= "<TR>"; $r .= "<TD>"; $wPos->value = isset($this->aAcc_Report_row[$i]->fo_pos) ? $this->aAcc_Report_row[$i]->fo_pos : $i + 1; $r .= $wPos->input("pos" . $i); $r .= '</TD>'; $r .= "<TD>"; $wName->value = isset($this->aAcc_Report_row[$i]->fo_label) ? $this->aAcc_Report_row[$i]->fo_label : ""; $r .= $wName->input("text" . $i); $r .= '</TD>'; $r .= '<td>'; $search = new IPoste("form" . $i); $search->size = 50; $search->value = isset($this->aAcc_Report_row[$i]->fo_formula) ? $this->aAcc_Report_row[$i]->fo_formula : ""; $search->label = _("Recherche poste"); $search->set_attribute('gDossier', dossier::id()); $search->set_attribute('bracket', 1); $search->set_attribute('no_overwrite', 1); $search->set_attribute('noquery', 1); $search->set_attribute('account', $search->name); $search->set_attribute('ipopup', 'ipop_card'); $r .= $search->input(); $r .= '</td>'; $r .= "</TR>"; } $r .= "</TABLE>"; $wButton = new IButton(); $wButton->javascript = " rapport_add_row('" . dossier::id() . "')"; $wButton->label = "Ajout d'une ligne"; $r .= $wButton->input(); return $r; }
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']; } echo "Extrait / relevé :" . $iextrait->input(); echo 'solde Début' . $nstart_extrait->input(); echo 'solde Fin' . $nend_extrait->input(); echo IButton::tooggle_checkbox('rec1'); echo '</p>'; echo '<p>'; echo _('Filtre') . HtmlInput::infobulle(25); echo HtmlInput::filter_table("t_rec_bk", "0,1,2,3", "1"); echo '</p>'; echo HtmlInput::submit('save', 'Mettre à jour le n° de relevé bancaire'); echo '<span style="display:block">'; echo '</span>'; echo '<table id="t_rec_bk" class="sortable" style="width:90%;margin-left:5%">'; $r = '<th class=" sorttable_sorted_reverse">' . 'Date ' . HtmlInput::infobulle(17) . '<span id="sorttable_sortrevind"> ▴</span>' . '</th>'; $r .= th('Libellé'); $r .= th('N° interne');
function form() { $comment = new IText(); $comment->name = 'p_comment'; $comment->value = $this->p_comment; $comment->size = 45; $value = new IPoste(); $value->name = 'p_value'; $value->value = $this->p_value; $value->size = 7; $value->set_attribute('ipopup', 'ipop_account'); $value->set_attribute('account', 'p_value'); $poste = new IText(); $poste->setReadOnly(true); $poste->size = strlen($this->p_code) + 1; $poste->name = 'p_code'; $poste->value = $this->p_code; $r = ""; $r .= '<tr>'; $r .= '<td align="right"> Code </td>'; $r .= '<TD>' . $poste->input() . '</TD>'; $r .= '</tr>'; $r .= '<tr>'; $r .= '<td align="right"> Commentaire </td>'; $r .= '<TD>' . $comment->input() . '</TD>'; $r .= '</tr>'; $r .= '<tr>'; $r .= '<td align="right"> Poste comptable </td>'; $r .= '<TD>' . $value->input(); $r .= '<span id="p_value_label"></span></td>'; $r .= '</tr>'; $r .= Dossier::hidden(); return $r; }
function display($p_array) { global $g_parameter, $g_user; require_once NOALYSS_INCLUDE . '/class_acc_ledger.php'; $legder = new Acc_Ledger($this->db, $this->jrn_def_id); $legder->nb = $legder->get_min_row(); if ($p_array != null) { extract($p_array); } $add_js = ""; $ret = ""; if ($g_user->check_action(FICADD) == 1) { /* Add button */ $f_add_button = new IButton('add_card'); $f_add_button->label = _('Créer une nouvelle fiche'); $f_add_button->set_attribute('ipopup', 'ipop_newcard'); $f_add_button->set_attribute('jrn', $legder->id); $f_add_button->javascript = " this.jrn=\$('p_jrn').value;select_card_type(this);"; $f_add_button->input(); } $nb_row = isset($nb_item) ? $nb_item : $legder->nb; $ret .= HtmlInput::hidden('nb_item', $nb_row); $ret .= HtmlInput::hidden('p_jrn', $this->jrn_def_id); $ret .= dossier::hidden(); $ret .= dossier::hidden(); $ret .= HtmlInput::hidden('jrn_type', $legder->get_type()); $info = HtmlInput::infobulle(0); $info_poste = HtmlInput::infobulle(9); if ($g_user->check_action(FICADD) == 1) { $ret .= $f_add_button->input(); } $ret .= '<table id="quick_item" style="width:100%">'; $ret .= '<tr>' . '<th style="text-align:left">Quickcode' . $info . '</th>' . '<th style="text-align:left">' . _('Poste') . $info_poste . '</th>' . '<th style="text-align:left">' . _('Libellé') . '</th>' . '<th style="text-align:left">' . _('Montant') . '</th>' . '<th style="text-align:left">' . _('Débit') . '</th>' . '</tr>'; for ($i = 0; $i < $nb_row; $i++) { // Quick Code $quick_code = new ICard('qc_' . $i); $quick_code->set_dblclick("fill_ipopcard(this);"); $quick_code->set_attribute('ipopup', 'ipopcard'); // name of the field to update with the name of the card $quick_code->set_attribute('label', "ld" . $i); $quick_code->set_attribute('jrn', $legder->id); // name of the field to update with the name of the card $quick_code->set_attribute('typecard', 'filter'); // Add the callback function to filter the card on the jrn $quick_code->set_callback('filter_card'); $quick_code->set_function('fill_data'); $quick_code->javascript = sprintf(' onchange="fill_data_onchange(\'%s\');" ', $quick_code->name); $quick_code->jrn = $legder->id; $quick_code->value = isset(${'qc_' . $i}) ? ${'qc_' . $i} : ""; $label = ''; if ($quick_code->value != '') { $Fiche = new Fiche($legder->db); $Fiche->get_by_qcode($quick_code->value); $label = $Fiche->strAttribut(ATTR_DEF_NAME); } // Account $poste = new IPoste(); $poste->name = 'poste' . $i; $poste->set_attribute('jrn', $legder->id); $poste->set_attribute('ipopup', 'ipop_account'); $poste->set_attribute('label', 'ld' . $i); $poste->set_attribute('account', 'poste' . $i); $poste->set_attribute('dossier', Dossier::id()); $poste->value = isset(${'poste' . $i}) ? ${"poste" . $i} : ''; $poste->dbl_click_history(); if ($poste->value != '') { $Poste = new Acc_Account($legder->db); $Poste->set_parameter('value', $poste->value); $label = $Poste->get_lib(); } // Description of the line $line_desc = new IText(); $line_desc->name = 'ld' . $i; $line_desc->size = 30; $line_desc->value = isset(${"ld" . $i}) ? ${"ld" . $i} : $label; // Amount $amount = new INum(); $amount->size = 10; $amount->name = 'amount' . $i; $amount->value = isset(${'amount' . $i}) ? ${"amount" . $i} : ''; $amount->javascript = ' onChange="format_number(this);checkTotalDirect()"'; // D/C $deb = new ICheckBox(); $deb->name = 'ck' . $i; $deb->selected = isset(${'ck' . $i}) ? true : false; $deb->javascript = ' onChange="checkTotalDirect()"'; $ret .= '<tr>'; $ret .= '<td>' . $quick_code->input() . $quick_code->search() . '</td>'; $ret .= '<td>' . $poste->input() . '<script> document.getElementById(\'poste' . $i . '\').onblur=function(){ if (trim(this.value) !=\'\') {document.getElementById(\'qc_' . $i . '\').value="";}}</script>' . '</td>'; $ret .= '<td>' . $line_desc->input() . '</td>'; $ret .= '<td>' . $amount->input() . '</td>'; $ret .= '<td>' . $deb->input() . '</td>'; $ret .= '</tr>'; // If readonly == 1 then show CA } $ret .= '</table>'; return $ret; }