function __construct(DatabaseDataField $paramDataField)
 {
     $this->setDataField($paramDataField);
     //Déclaration des propriétés générique (classe parent)
     parent::__construct();
     parent::initAbstractHtmlInput($this->getHtmlName(), $this->getDataField()->getFieldLabel(), $this->getDataField()->getFieldValue(), $this->getDataField()->isFieldDiff());
     $this->getEventsForm()->setOnChangeWithAjaxAutoSave($this->getDataField()->getTableName(), $this->getDataField()->getKeyName(), $this->getDataField()->getKeyValue(), $this->getDataField()->getFieldName());
     $this->setHtmlResultOnClick();
     /**
      * Détermine si le datafield encours doit être non éditiable
      */
     $this->setContentLocked($paramDataField->getFieldsToLock());
 }
Example #2
0
 /**
  * Chapitre non actif
  * @return string
  */
 public static function buildChapitreIdentiteTraiteur()
 {
     $bloc = '';
     $id_fta = self::$id_fta;
     $synthese_action = self::$synthese_action;
     $is_editable = self::$is_editable;
     $is_editable_false = false;
     //        if ($is_editable) {
     //            $bloc .= self::$html_submit_button;
     //        }
     //Classification
     $bloc .= ObjectFta::showClassification($id_fta, $id_version_dossier_fta = self::$objectFta->getFieldValue(ObjectFta::TABLE_FTA_NAME, 'id_version_dossier_fta'), $last_id_fta = self::$objectFta->getFieldValue(ObjectFta::TABLE_FTA_NAME, 'last_id_fta'), $FAMILLE_ARTICLE = self::$objectFta->getFieldValue(ObjectFta::TABLE_ARTI_NAME, 'FAMILLE_ARTICLE'), $FAMILLE_MKTG = self::$objectFta->getFieldValue(ObjectFta::TABLE_ARTI_NAME, 'FAMILLE_MKTG'), $id_access_familles_gammes = self::$objectFta->getFieldValue(ObjectFta::TABLE_ARTI_NAME, 'id_access_familles_gammes'), $is_editable, $synthese_action);
     //Type de FTA
     $htmlObject = new OldHtmlList($data_field = self::$objectFta->getFieldDescription(ObjectFta::TABLE_FTA_NAME, 'id_fta_categorie'), $content_label_field = self::$objectFta->getFieldDescription(ObjectFta::TABLE_WORKFLOW_NAME, 'nom_fta_categorie'), $default_value = 1, $is_editable, $warning_update = ${'diff_' . $table_name}[$field_name]);
     $bloc .= $htmlObject->getHtmlResultSubForm();
     //Désignation Commerciale de l'Article
     $htmlObject = new htmlInputText($field_name = 'designation_commerciale_fta', $table_name = ObjectFta::TABLE_FTA_NAME, $value = self::$objectFta->getFieldValue($table_name, $field_name), $is_editable, $warning_update = ${'diff_' . $table_name}[$field_name], $size = 110, $maxlength = 150);
     $bloc .= $htmlObject->getHtmlResult();
     //Poids élémentaire
     $htmlObject = new htmlInputKg($field_name = 'Poids_ELEM', $table_name = ObjectFta::TABLE_ARTI_NAME, $value = self::$objectFta->getFieldValue($table_name, $field_name), $is_editable, $warning_update = ${'diff_' . $table_name}[$field_name], $size = 20, $maxlength = 150);
     $bloc .= $htmlObject->getHtmlResult();
     //PCB
     $htmlObject = new htmlInputText($field_name = 'NB_UNIT_ELEM', $table_name = ObjectFta::TABLE_ARTI_NAME, $value = self::$objectFta->getFieldValue($table_name, $field_name), $is_editable, $warning_update = ${'diff_' . $table_name}[$field_name]);
     $bloc .= $htmlObject->getHtmlResult();
     //Durée de vie Garantie Client
     $htmlObject = new htmlInputNumber($field_name = 'Duree_de_vie', $table_name = ObjectFta::TABLE_ARTI_NAME, $value = self::$objectFta->getFieldValue($table_name, $field_name), $is_editable, $warning_update = ${'diff_' . $table_name}[$field_name]);
     $bloc .= $htmlObject->getHtmlResult();
     //Créateur
     $htmlObject = new htmlInputText($field_name = 'createur_fta', $table_name = ObjectFta::TABLE_CREATEUR_NAME, $value = self::$objectFta->getFieldValue($table_name, 'prenom') . ' ' . strtoupper(self::$objectFta->getFieldValue($table_name, 'nom')), $is_editable_false, $warning_update = ${'diff_' . $table_name}[$field_name], $size = 110, $maxlength = 150);
     $bloc .= $htmlObject->getHtmlResult();
     //Date d'échéance de la FTA
     $htmlObject = new HtmlInputCalendar($field_name = 'date_echeance_fta', $table_name = ObjectFta::TABLE_FTA_NAME, $value = self::$objectFta->getFieldValue($table_name, $field_name), $is_editable, $warning_update = ${'diff_' . $table_name}[$field_name]);
     $bloc .= $htmlObject->getHtmlResult();
     //Date d'échéance des processus
     $bloc .= ObjectFta::showDatesEcheanceProcessus($id_fta, $abreviation_fta_etat = self::$objectFta->getFieldValue(ObjectFta::TABLE_ETAT_NAME, 'abreviation_fta_etat'), $date_echeance_fta = self::$objectFta->getFieldValue(ObjectFta::TABLE_FTA_NAME, 'date_echeance_fta'), $is_editable);
     $bloc .= '</table>';
     return $bloc;
 }
Example #3
0
 /**
  * Affiche la date d'échéance
  * @param boolean $paramUpdateFta
  * @return string
  */
 function getHtmlDateEcheance($paramUpdateFta)
 {
     $htmlInputCalendar = new HtmlInputCalendar();
     $dataFieldDateEcheance = $this->getDataField(self::FIELDNAME_DATE_ECHEANCE_FTA);
     /**
      * Contrôle de la date d'échéance
      */
     $dateEcheValue = $this->checkDateEcheance($paramUpdateFta);
     /**
      * Changement du format de date
      */
     if (!$this->getIsEditable()) {
         $dateEcheValue = FtaController::changementDuFormatDeDateFR($dateEcheValue);
     }
     /**
      * Mise en forme
      */
     $HtmlTableName = self::TABLENAME . '_' . self::FIELDNAME_DATE_ECHEANCE_FTA . '_' . $this->getKeyValue();
     $htmlInputCalendar->setIsEditable($this->getIsEditable());
     $htmlInputCalendar->initAbstractHtmlInput($HtmlTableName, $dataFieldDateEcheance->getFieldLabel(), $dateEcheValue, $dataFieldDateEcheance->isFieldDiff());
     $htmlInputCalendar->getEventsForm()->setOnChangeWithAjaxAutoSave($dataFieldDateEcheance->getTableName(), $dataFieldDateEcheance->getKeyName(), $dataFieldDateEcheance->getKeyValue(), $dataFieldDateEcheance->getFieldName());
     $htmlInputCalendar->setHtmlResultOnClick();
     return $htmlInputCalendar->getHtmlResult();
 }