当前位置: 首页>>代码示例>>PHP>>正文


PHP dol_get_fiche_head函数代码示例

本文整理汇总了PHP中dol_get_fiche_head函数的典型用法代码示例。如果您正苦于以下问题:PHP dol_get_fiche_head函数的具体用法?PHP dol_get_fiche_head怎么用?PHP dol_get_fiche_head使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了dol_get_fiche_head函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: setEventMessage

        setEventMessage($object->error, 'errors');
        $action = 'edit';
    } else {
        setEventMessage($langs->trans('CronSaveSucess'), 'mesgs');
        $action = '';
    }
}
/*
 * View
 */
$form = new Form($db);
$formCron = new FormCron($db);
llxHeader('', $langs->trans("CronAdd"));
if ($action == 'edit' || empty($action) || $action == 'delete' || $action == 'execute') {
    $head = cron_prepare_head($object);
    print dol_get_fiche_head($head, 'card', $langs->trans("CronTask"), 0, 'cron');
} elseif ($action == 'create') {
    print_fiche_titre($langs->trans("CronTask"), '', 'setup');
}
if ($conf->use_javascript_ajax) {
    print "\n" . '<script type="text/javascript" language="javascript">';
    print 'jQuery(document).ready(function () {
                    function initfields()
                    {
                        if ($("#jobtype option:selected").val()==\'method\') {
							$(".blockmethod").show();
							$(".blockcommand").hide();
						}
						if ($("#jobtype option:selected").val()==\'command\') {
							$(".blockmethod").hide();
							$(".blockcommand").show();
开发者ID:ADDAdev,项目名称:Dolibarr,代码行数:31,代码来源:card.php

示例2: assign_values

 /**
  *  Assign custom values for canvas
  *
  *  @param	string		&$action    	Type of action
  *  @param	int			$id				Id
  *  @return	void
  */
 function assign_values(&$action, $id)
 {
     global $conf, $db, $langs, $user;
     global $form;
     $ret = $this->getObject($id);
     parent::assign_values($action, $id);
     $this->tpl['title'] = $this->getTitle($action);
     $this->tpl['error'] = $this->error;
     $this->tpl['errors'] = $this->errors;
     if ($action == 'view') {
         // Card header
         $head = contact_prepare_head($this->object);
         $title = $this->getTitle($action);
         $this->tpl['showhead'] = dol_get_fiche_head($head, 'card', $title, 0, 'contact');
         $this->tpl['showend'] = dol_get_fiche_end();
         $objsoc = new Societe($db);
         $objsoc->fetch($this->object->socid);
         $this->tpl['actionstodo'] = show_actions_todo($conf, $langs, $db, $objsoc, $this->object, 1);
         $this->tpl['actionsdone'] = show_actions_done($conf, $langs, $db, $objsoc, $this->object, 1);
     } else {
         // Confirm delete contact
         if ($action == 'delete' && $user->rights->societe->contact->supprimer) {
             $this->tpl['action_delete'] = $form->formconfirm($_SERVER["PHP_SELF"] . "?id=" . $this->object->id, $langs->trans("DeleteContact"), $langs->trans("ConfirmDeleteContact"), "confirm_delete", '', 0, 1);
         }
     }
     if ($action == 'list') {
         $this->LoadListDatas($GLOBALS['limit'], $GLOBALS['offset'], $GLOBALS['sortfield'], $GLOBALS['sortorder']);
     }
 }
开发者ID:nrjacker4,项目名称:crm-php,代码行数:36,代码来源:actions_contactcard_default.class.php

示例3: dol_fiche_head

/**
 *	Show tab header of a card
 *	@param	    links		Array of tabs
 *	@param	    active      Active tab name
 *	@param      title       Title
 *	@param      notab		0=Add tab header, 1=no tab header
 * 	@param		picto		Add a picto on tab title
 */
function dol_fiche_head($links = array(), $active = '0', $title = '', $notab = 0, $picto = '')
{
    print dol_get_fiche_head($links, $active, $title, $notab, $picto);
}
开发者ID:netors,项目名称:dolibarr,代码行数:12,代码来源:functions.lib.php

示例4: dol_include_once

require 'config.php';
dol_include_once('/core/class/html.form.class.php');
if (!$user->rights->mandarin->graph->project_by_user) {
    accessforbidden();
}
$langs->load('mandarin@mandarin');
$userid = GETPOST('userid');
if ($userid != 0) {
    $userdefault = $userid;
} elseif (user_est_responsable_hierarchique()) {
    $userid = $user->id;
}
// Begin of page
llxHeader('', $langs->trans('linkMenuProjectByUserReport'), '');
print dol_get_fiche_head('linkMenuProjectByUserReport');
print_fiche_titre($langs->trans('linkMenuProjectByUserReport'));
print_form_filter($userid);
$TData = get_data_tab($userid);
draw_table($TData, get_list_id_user($TData), get_tab_label_statut_opportunite());
print '<br />';
draw_graphique($TData, get_tab_label_statut_opportunite());
llxFooter();
function print_form_filter($userid)
{
    global $db, $langs;
    $langs->load('users');
    $form = new Form($db);
    print '<form name="filter" methode="GET" action="' . $_SERVER['PHP_SELF'] . '">';
    print $langs->trans('HierarchicalResponsible');
    print $form->select_dolusers($userid, 'userid', 1, '', 0, '', '', 0, 0, 0, '', 0, '', '', 1);
开发者ID:ATM-Consulting,项目名称:dolibarr_module_mandarin,代码行数:30,代码来源:graph_project_by_user.php

示例5: array

}
$arrayofjs = array();
$arrayofcss = array('/opensurvey/css/style.css');
llxHeader('', $object->titre, 0, 0, 0, 0, $arrayofjs, $arrayofcss);
// Define format of choices
$toutsujet = explode(",", $object->sujet);
$listofanswers = array();
foreach ($toutsujet as $value) {
    $tmp = explode('@', $value);
    $listofanswers[] = array('label' => $tmp[0], 'format' => $tmp[1] ? $tmp[1] : 'checkbox');
}
$toutsujet = str_replace("@", "<br>", $toutsujet);
$toutsujet = str_replace("°", "'", $toutsujet);
print '<form name="formulaire4" action="#" method="POST">' . "\n";
$head = opensurvey_prepare_head($object);
print dol_get_fiche_head($head, 'preview', $langs->trans("Survey"), 0, dol_buildpath('/opensurvey/img/object_opensurvey.png', 1), 1);
print '<table class="border" width="100%">';
$linkback = '<a href="' . dol_buildpath('/opensurvey/list.php', 1) . (!empty($socid) ? '?socid=' . $socid : '') . '">' . $langs->trans("BackToList") . '</a>';
// Ref
print '<tr><td width="18%">' . $langs->trans('Ref') . '</td>';
print '<td colspan="3">';
print $form->showrefnav($object, 'id', $linkback, 1, 'id_sondage', 'id_sondage');
print '</td>';
print '</tr>';
// Type
$type = $object->format == "A" ? 'classic' : 'date';
print '<tr><td>' . $langs->trans("Type") . '</td><td colspan="2">';
print img_picto('', dol_buildpath('/opensurvey/img/' . ($type == 'classic' ? 'chart-32.png' : 'calendar-32.png'), 1), 'width="16"', 1);
print ' ' . $langs->trans($type == 'classic' ? "TypeClassic" : "TypeDate") . '</td></tr>';
// Title
print '<tr><td>';
开发者ID:Samara94,项目名称:dolibarr,代码行数:31,代码来源:results.php

示例6: dol_fiche_head

/**
 *	Show tab header of a card
 *	@param	    links		Array of tabs
 *	@param	    active      Active tab name
 *	@param      title       Title
 *	@param      notab		0=Add tab header, 1=no tab header
 * 	@param		picto		Add a picto on tab title
 */
function dol_fiche_head($links = array(), $active = '0', $title = '', $notab = 0, $picto = '')
{
    //fazendo com que todas as paginas com abas de detalhes fiquem sem título, fica melhor somente as abas rafso
    //era print dol_get_fiche_head($links, $active, $title, $notab, $picto);
    print dol_get_fiche_head($links, $active, '', $notab, $picto);
}
开发者ID:rafso,项目名称:cliente,代码行数:14,代码来源:functions.lib.php

示例7: __get

$action = __get('action', 'view');
$page = __get('page', 0);
if ($page < 0) {
    $page = 0;
}
$limit = $conf->liste_limit;
$offset = $limit * $page;
if (!$user->rights->recurrence->all->read) {
    accessforbidden();
}
/*
 * HEADER
 */
llxHeader('', 'Récurrence des charges sociales');
print_fiche_titre('Récurrence des charges sociales', '', 'report.png@report');
print dol_get_fiche_head(array(array(dol_buildpath('/recurrence/gestion.php?action=view', 1), 'Liste des récurrences', 'view'), array(dol_buildpath('/recurrence/gestion.php?action=add', 1), 'Enregistrer une tâche récurrente', 'add')), $action, '');
echo '<form method="POST" action="paiement.php">';
// Formulaire pour la gestion des paiements
_liste_charges_sociales($PDOdb, $action, $page, $limit, $offset);
if ($user->rights->tax->charges->creer) {
    if ($action == 'add') {
        if ($user->rights->tax->charges->creer) {
            echo '<div class="tabsAction">';
            echo '
			<div class="inline-block divButAction">
				<a class="butAction" href="' . DOL_URL_ROOT . '/compta/sociales/charges.php?leftmenu=tax_social&action=create">
					Ajouter une charge sociale
				</a>
			</div>';
            echo '</div>';
        }
开发者ID:ATM-Consulting,项目名称:dolibarr_module_recurence,代码行数:31,代码来源:gestion.php

示例8: dol_include_once

require 'config.php';
dol_include_once('/core/class/html.form.class.php');
if (!$user->rights->mandarin->graph->action_by_user) {
    accessforbidden();
}
$langs->load('mandarin@mandarin');
$userid = GETPOST('userid');
if ($userid != 0) {
    $userdefault = $userid;
} elseif (user_est_responsable_hierarchique()) {
    $userid = $user->id;
}
// Begin of page
llxHeader('', $langs->trans('mandarinTitleGraphEventByUser'), '');
print dol_get_fiche_head('RapportEvenementsParCommerciaux');
print_fiche_titre($langs->trans('RapportEvenementsParCommerciaux'));
print_form_filter($userid);
$TData = get_data_tab($userid);
draw_table($TData, get_list_id_user($TData), get_tab_label_action_comm());
print '<br />';
draw_graphique($TData, get_tab_label_action_comm());
llxFooter();
function print_form_filter($userid)
{
    global $db, $langs;
    $langs->load('users');
    $form = new Form($db);
    print '<form name="filter" methode="GET" action="' . $_SERVER['PHP_SELF'] . '">';
    print $langs->trans('HierarchicalResponsible');
    print $form->select_dolusers($userid, 'userid', 1, '', 0, '', '', 0, 0, 0, '', 0, '', '', 1);
开发者ID:ATM-Consulting,项目名称:dolibarr_module_mandarin,代码行数:30,代码来源:graph_action_by_user.php

示例9: dol_include_once

<?php

require 'config.php';
dol_include_once('/projet/class/project.class.php');
dol_include_once('/projet/class/task.class.php');
dol_include_once('/user/class/user.class.php');
dol_include_once('/core/lib/usergroups.lib.php');
llxHeader('', $langs->trans('RapportCapaciteProduction'));
_print_tab_header();
print dol_get_fiche_head($langs->trans('RapportCapaciteProduction'));
print_fiche_titre($langs->trans("Capacité de production par période"));
_print_filtres();
print_rapport();
function print_rapport()
{
    global $langs;
    $date_d = preg_replace('/\\//', '-', GETPOST('date_deb'));
    $date_f = preg_replace('/\\//', '-', GETPOST('date_fin'));
    $date_deb = date('Y-m-d', strtotime($date_d));
    $date_fin = date('Y-m-d', strtotime($date_f));
    if (empty(GETPOST('date_deb'))) {
        $date_deb = date('Y-m-d', strtotime(date('Y-m-d')) - 60 * 60 * 24 * 7);
    }
    if (empty(GETPOST('date_fin'))) {
        $date_fin = date('Y-m-d');
    }
    $PDOdb = new TPDOdb();
    $interval = (strtotime($date_fin) - strtotime($date_deb)) / 3600 / 24;
    $TDataBrut = get_user_capacity_period($date_deb, $date_fin);
    $TData = array();
    $total_temps_saisi = 0;
开发者ID:ATM-Consulting,项目名称:dolibarr_module_mandarin,代码行数:31,代码来源:graph_time_period.php

示例10: ChargeSociales

    print '</tr>';
    print '</table>';
    print '</form>';
}
/* *************************************************************************** */
/*                                                                             */
/* Mode fiche                                                                  */
/*                                                                             */
/* *************************************************************************** */
if ($id > 0) {
    $object = new ChargeSociales($db);
    $result = $object->fetch($id);
    if ($result > 0) {
        dol_htmloutput_mesg($mesg);
        $head = tax_prepare_head($object);
        print dol_get_fiche_head($head, 'card', $langs->trans("SocialContribution"), 0, 'bill');
        // Confirmation de la suppression de la charge
        if ($action == 'paid') {
            $text = $langs->trans('ConfirmPaySocialContribution');
            print $form->formconfirm($_SERVER["PHP_SELF"] . "?id=" . $object->id, $langs->trans('PaySocialContribution'), $text, "confirm_paid", '', '', 2);
        }
        if ($action == 'delete') {
            $text = $langs->trans('ConfirmDeleteSocialContribution');
            print $form->formconfirm($_SERVER['PHP_SELF'] . '?id=' . $object->id, $langs->trans('DeleteSocialContribution'), $text, 'confirm_delete', '', '', 2);
        }
        if ($action == 'edit') {
            print "<form name=\"charge\" action=\"charges.php?id={$object->id}&amp;action=update\" method=\"post\">";
            print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
        }
        print '<table class="border" width="100%">';
        // Ref
开发者ID:nrjacker4,项目名称:crm-php,代码行数:31,代码来源:charges.php

示例11: _fiche_control

function _fiche_control(&$PDOdb, &$assetOf)
{
    global $langs, $db, $conf;
    llxHeader('', $langs->trans('OFAsset'), '', '');
    print dol_get_fiche_head(ofPrepareHead($assetOf, 'assetOF'), 'controle', $langs->trans('OFAsset'));
    /******/
    $TBS = new TTemplateTBS();
    $TBS->TBS->protect = false;
    $TBS->TBS->noerr = true;
    $form = new TFormCore($_SERVER['PHP_SELF'], 'form', 'POST');
    $form->Set_typeaff('view');
    $TControl = _fiche_ligne_control($PDOdb, $assetOf->getId());
    $TAssetOFControl = _fiche_ligne_control($PDOdb, $assetOf->getId(), $assetOf);
    print $TBS->render('tpl/fiche_of_control.tpl.php', array('TControl' => $TControl, 'TAssetOFControl' => $TAssetOFControl), array('assetOf' => array('id' => (int) $assetOf->getId()), 'view' => array('nbTControl' => count($TControl), 'nbTAssetOFControl' => count($TAssetOFControl), 'url' => DOL_URL_ROOT . '/custom/of/fiche_of.php')));
    $form->end();
    /******/
    llxFooter('$Date: 2011/07/31 22:21:57 $ - $Revision: 1.19 $');
}
开发者ID:ATM-Consulting,项目名称:dolibarr_module_of,代码行数:18,代码来源:fiche_of.php

示例12: assign_values

	/**
	 *    Assign custom values for canvas
	 *    @param      action     Type of action
	 */
	function assign_values($action='')
	{
		global $conf, $db, $langs, $user;
		global $form;

		parent::assign_values($action);

        $this->tpl['title'] = $this->getTitle($action);
        $this->tpl['error'] = $this->error;
        $this->tpl['errors']= $this->errors;

		if ($action == 'view')
		{
            // Card header
            $head = contact_prepare_head($this->object);
            $title = $this->getTitle($action);

		    $this->tpl['showhead']=dol_get_fiche_head($head, 'card', $title, 0, 'contact');
		    $this->tpl['showend']=dol_get_fiche_end();

			// Confirm delete contact
        	if ($user->rights->societe->contact->supprimer)
        	{
        		if ($_GET["action"] == 'delete')
        		{
        			$this->tpl['action_delete'] = $form->formconfirm($_SERVER["PHP_SELF"]."?id=".$this->object->id,$langs->trans("DeleteContact"),$langs->trans("ConfirmDeleteContact"),"confirm_delete",'',0,1);
        		}
        	}

        	$objsoc = new Societe($db);
            $objsoc->fetch($this->object->fk_soc);

            $this->tpl['actionstodo']=show_actions_todo($conf,$langs,$db,$objsoc,$this->object,1);

            $this->tpl['actionsdone']=show_actions_done($conf,$langs,$db,$objsoc,$this->object,1);
		}
	}
开发者ID:remyyounes,项目名称:dolibarr,代码行数:41,代码来源:actions_contactcard_default.class.php

示例13: dol_include_once

<?php

require 'config.php';
dol_include_once('/projet/class/project.class.php');
dol_include_once('/projet/class/task.class.php');
dol_include_once('/user/class/user.class.php');
dol_include_once('/core/lib/usergroups.lib.php');
dol_include_once('/comm/propal/class/propal.class.php');
llxHeader('', $langs->trans('graphProjectCDP'));
print dol_get_fiche_head($langs->trans('graphProjectCDP'));
print_fiche_titre($langs->trans("graphProjectCDP"));
_print_graph();
function _print_graph()
{
    global $db, $langs;
    $PDOdb = new TPDOdb();
    $TDataBrut = $TData = _get_projet_cdp();
    //var_dump($TDataBrut);
    $explorer = new stdClass();
    $explorer->actions = array("dragToZoom", "rightClickToReset");
    $listeview = new TListviewTBS('graphProjectCDP');
    print $listeview->renderArray($PDOdb, $TData, array('type' => 'chart', 'chartType' => 'ColumnChart', 'liste' => array('titre' => $langs->transnoentities('graphProjectCDP')), 'hAxis' => array('title' => 'Chef de projet'), 'vAxis' => array('title' => 'Nombre de projets'), 'explorer' => $explorer));
}
function _get_projet_cdp()
{
    global $db;
    $TData = array();
    $sql = 'SELECT COUNT(p.rowid) AS nombre, ec.fk_socpeople AS user FROM ' . MAIN_DB_PREFIX . 'projet p ';
    $sql .= 'INNER JOIN ' . MAIN_DB_PREFIX . 'element_contact ec ON ec.element_id=p.rowid ';
    $sql .= 'WHERE ec.fk_c_type_contact = 160 AND p.fk_statut=1 ';
    $sql .= 'GROUP BY ec.fk_socpeople ';
开发者ID:ATM-Consulting,项目名称:dolibarr_module_scrumboard,代码行数:31,代码来源:nb_proj_cdp.php

示例14: assign_values

    /**
	 *    Assign custom values for canvas (for example into this->tpl to be used by templates)
	 *
	 *    @param	string	&$action    Type of action
	 *    @param	string	$id			Id of object
	 *    @param	string	$ref		Ref of object
	 *    @return	void
	 */
	function assign_values(&$action, $id=0, $ref='')
	{
        global $conf, $langs, $user, $mysoc, $canvas;
		global $form, $formproduct;

   		$tmpobject = new Product($this->db);
   		if (! empty($id) || ! empty($ref)) $tmpobject->fetch($id,$ref);
        $this->object = $tmpobject;

		//parent::assign_values($action);

	    foreach($this->object as $key => $value)
        {
            $this->tpl[$key] = $value;
        }

        $this->tpl['error'] = get_htmloutput_errors($this->object->error,$this->object->errors);

		// canvas
		$this->tpl['canvas'] = $this->canvas;

		// id
		$this->tpl['id'] = $this->id;

		// Ref
		$this->tpl['ref'] = $this->ref;

		// Label
		$this->tpl['label'] = $this->libelle;

		// Description
		$this->tpl['description'] = nl2br($this->description);

		// Statut
		$this->tpl['status'] = $this->getLibStatut(2);

		// Note
		$this->tpl['note'] = nl2br($this->note);

		if ($action == 'create')
		{
			// Price
			$this->tpl['price'] = $this->price;
			$this->tpl['price_min'] = $this->price_min;
			$this->tpl['price_base_type'] = $form->load_PriceBaseType($this->price_base_type, "price_base_type");

			// VAT
			$this->tpl['tva_tx'] = $form->load_tva("tva_tx",-1,$mysoc,'');
		}

		if ($action == 'create' || $action == 'edit')
		{
			// Status
			$statutarray=array('1' => $langs->trans("OnSell"), '0' => $langs->trans("NotOnSell"));
			$this->tpl['status'] = $form->selectarray('statut',$statutarray,$this->status);

			//To Buy
			$statutarray=array('1' => $langs->trans("Yes"), '0' => $langs->trans("No"));
			$this->tpl['tobuy'] = $form->selectarray('tobuy',$statutarray,$this->status_buy);

            $this->tpl['description'] = $this->description;
            $this->tpl['note'] = $this->note;
		}

		if ($action == 'view')
		{
            $head = product_prepare_head($this->object,$user);

            $this->tpl['showrefnav'] = $form->showrefnav($this->object,'ref','',1,'ref');

    		$titre=$langs->trans("CardProduct".$this->object->type);
    		$picto=($this->object->type==1?'service':'product');
    		$this->tpl['showhead']=dol_get_fiche_head($head, 'card', $titre, 0, $picto);
            $this->tpl['showend']=dol_get_fiche_end();

			// Accountancy buy code
			$this->tpl['accountancyBuyCodeKey'] = $form->editfieldkey("ProductAccountancyBuyCode",'productaccountancycodesell',$this->accountancy_code_sell,$this,$user->rights->produit->creer);
			$this->tpl['accountancyBuyCodeVal'] = $form->editfieldval("ProductAccountancyBuyCode",'productaccountancycodesell',$this->accountancy_code_sell,$this,$user->rights->produit->creer);

			// Accountancy sell code
			$this->tpl['accountancySellCodeKey'] = $form->editfieldkey("ProductAccountancySellCode",'productaccountancycodebuy',$this->accountancy_code_buy,$this,$user->rights->produit->creer);
			$this->tpl['accountancySellCodeVal'] = $form->editfieldval("ProductAccountancySellCode",'productaccountancycodebuy',$this->accountancy_code_buy,$this,$user->rights->produit->creer);
		}

		$this->tpl['finished'] = $this->object->finished;
		$this->tpl['ref'] = $this->object->ref;
		$this->tpl['label'] = $this->object->label;
		$this->tpl['id'] = $this->object->id;
		$this->tpl['type'] = $this->object->type;
		$this->tpl['note'] = $this->object->note;
		$this->tpl['seuil_stock_alerte'] = $this->object->seuil_stock_alerte;

//.........这里部分代码省略.........
开发者ID:nrjacker4,项目名称:crm-php,代码行数:101,代码来源:actions_card_service.class.php

示例15: assign_values

 /**
  *    Assign custom values for canvas (for example into this->tpl to be used by templates)
  *
  *    @param	string	$action    Type of action
  *    @param	string	$id			Id of object
  *    @param	string	$ref		Ref of object
  *    @return	void
  */
 function assign_values(&$action, $id = 0, $ref = '')
 {
     global $conf, $langs, $user, $mysoc, $canvas;
     global $form, $formproduct;
     $tmpobject = new Product($this->db);
     if (!empty($id) || !empty($ref)) {
         $tmpobject->fetch($id, $ref);
     }
     $this->object = $tmpobject;
     //parent::assign_values($action);
     foreach ($this->object as $key => $value) {
         $this->tpl[$key] = $value;
     }
     $this->tpl['error'] = get_htmloutput_errors($this->object->error, $this->object->errors);
     // canvas
     $this->tpl['canvas'] = $this->canvas;
     // id
     $this->tpl['id'] = $this->id;
     // Ref
     $this->tpl['ref'] = $this->ref;
     // Label
     $this->tpl['label'] = $this->libelle;
     // Description
     $this->tpl['description'] = nl2br($this->description);
     // Statut
     $this->tpl['status'] = $this->object->getLibStatut(2);
     // Note
     $this->tpl['note'] = nl2br($this->note);
     if ($action == 'create') {
         // Price
         $this->tpl['price'] = $this->price;
         $this->tpl['price_min'] = $this->price_min;
         $this->tpl['price_base_type'] = $form->load_PriceBaseType($this->price_base_type, "price_base_type");
         // VAT
         $this->tpl['tva_tx'] = $form->load_tva("tva_tx", -1, $mysoc, '');
     }
     if ($action == 'create' || $action == 'edit') {
         // Status
         $statutarray = array('1' => $langs->trans("OnSell"), '0' => $langs->trans("NotOnSell"));
         $this->tpl['status'] = $form->selectarray('statut', $statutarray, $this->status);
         //To Buy
         $statutarray = array('1' => $langs->trans("Yes"), '0' => $langs->trans("No"));
         $this->tpl['tobuy'] = $form->selectarray('tobuy', $statutarray, $this->status_buy);
         $this->tpl['description'] = $this->description;
         $this->tpl['note'] = $this->note;
     }
     if ($action == 'view') {
         $head = product_prepare_head($this->object, $user);
         $this->tpl['showrefnav'] = $form->showrefnav($this->object, 'ref', '', 1, 'ref');
         $titre = $langs->trans("CardProduct" . $this->object->type);
         $picto = $this->object->type == 1 ? 'service' : 'product';
         $this->tpl['showhead'] = dol_get_fiche_head($head, 'card', $titre, 0, $picto);
         $this->tpl['showend'] = dol_get_fiche_end();
         // Accountancy buy code
         $this->tpl['accountancyBuyCodeKey'] = $form->editfieldkey("ProductAccountancyBuyCode", 'productaccountancycodesell', $this->accountancy_code_sell, $this, $user->rights->produit->creer);
         $this->tpl['accountancyBuyCodeVal'] = $form->editfieldval("ProductAccountancyBuyCode", 'productaccountancycodesell', $this->accountancy_code_sell, $this, $user->rights->produit->creer);
         // Accountancy sell code
         $this->tpl['accountancySellCodeKey'] = $form->editfieldkey("ProductAccountancySellCode", 'productaccountancycodebuy', $this->accountancy_code_buy, $this, $user->rights->produit->creer);
         $this->tpl['accountancySellCodeVal'] = $form->editfieldval("ProductAccountancySellCode", 'productaccountancycodebuy', $this->accountancy_code_buy, $this, $user->rights->produit->creer);
     }
     $this->tpl['finished'] = $this->object->finished;
     $this->tpl['ref'] = $this->object->ref;
     $this->tpl['label'] = $this->object->label;
     $this->tpl['id'] = $this->object->id;
     $this->tpl['type'] = $this->object->type;
     $this->tpl['note'] = $this->object->note;
     $this->tpl['seuil_stock_alerte'] = $this->object->seuil_stock_alerte;
     if ($action == 'create') {
         // Title
         $this->tpl['title'] = $langs->trans("NewProduct");
     }
     if ($action == 'edit') {
         $this->tpl['title'] = $langs->trans('Modify') . ' ' . $langs->trans('Product') . ' : ' . $this->object->ref;
     }
     if ($action == 'create' || $action == 'edit') {
         // Status
         $statutarray = array('1' => $langs->trans("OnSell"), '0' => $langs->trans("NotOnSell"));
         $this->tpl['status'] = $form->selectarray('statut', $statutarray, $_POST["statut"]);
         $statutarray = array('1' => $langs->trans("ProductStatusOnBuy"), '0' => $langs->trans("ProductStatusNotOnBuy"));
         $this->tpl['status_buy'] = $form->selectarray('statut_buy', $statutarray, $_POST["statut_buy"]);
         // Finished
         $statutarray = array('1' => $langs->trans("Finished"), '0' => $langs->trans("RowMaterial"));
         $this->tpl['finished'] = $form->selectarray('finished', $statutarray, $this->object->finished);
         // Weight
         $this->tpl['weight'] = $this->object->weight;
         $this->tpl['weight_units'] = $formproduct->load_measuring_units("weight_units", "weight", $this->object->weight_units);
         // Length
         $this->tpl['length'] = $this->object->length;
         $this->tpl['length_units'] = $formproduct->load_measuring_units("length_units", "size", $this->object->length_units);
         // Surface
         $this->tpl['surface'] = $this->object->surface;
         $this->tpl['surface_units'] = $formproduct->load_measuring_units("surface_units", "surface", $this->object->surface_units);
//.........这里部分代码省略.........
开发者ID:LionSystemsSolutions,项目名称:El-Canelo-ERP,代码行数:101,代码来源:actions_card_product.class.php


注:本文中的dol_get_fiche_head函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。