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


PHP img_warning函数代码示例

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


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

示例1: loadBox

 /**
  *  Load data into info_box_contents array to show array later.
  *
  *  @param	int		$max        Maximum number of records to load
  *  @return	void
  */
 function loadBox($max = 5)
 {
     global $user, $langs, $db, $conf;
     $this->max = $max;
     include_once DOL_DOCUMENT_ROOT . '/comm/propal/class/propal.class.php';
     $propalstatic = new Propal($db);
     $this->info_box_head = array('text' => $langs->trans("BoxTitleLastPropals", $max));
     if ($user->rights->propale->lire) {
         $sql = "SELECT s.nom, s.rowid as socid,";
         $sql .= " p.rowid, p.ref, p.fk_statut, p.datep as dp, p.datec, p.fin_validite, p.date_cloture";
         $sql .= " FROM " . MAIN_DB_PREFIX . "societe as s";
         $sql .= ", " . MAIN_DB_PREFIX . "propal as p";
         if (!$user->rights->societe->client->voir && !$user->societe_id) {
             $sql .= ", " . MAIN_DB_PREFIX . "societe_commerciaux as sc";
         }
         $sql .= " WHERE p.fk_soc = s.rowid";
         $sql .= " AND p.entity = " . $conf->entity;
         if (!$user->rights->societe->client->voir && !$user->societe_id) {
             $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = " . $user->id;
         }
         if ($user->societe_id) {
             $sql .= " AND s.rowid = " . $user->societe_id;
         }
         $sql .= " ORDER BY p.datep DESC, p.ref DESC ";
         $sql .= $db->plimit($max, 0);
         $result = $db->query($sql);
         if ($result) {
             $num = $db->num_rows($result);
             $now = dol_now();
             $i = 0;
             while ($i < $num) {
                 $objp = $db->fetch_object($result);
                 $datec = $db->jdate($objp->datec);
                 $dateterm = $db->jdate($objp->fin_validite);
                 $dateclose = $db->jdate($objp->date_cloture);
                 $late = '';
                 if ($objp->fk_statut == 1 && $dateterm < $now - $conf->propal->cloture->warning_delay) {
                     $late = img_warning($langs->trans("Late"));
                 }
                 $this->info_box_contents[$i][0] = array('td' => 'align="left" width="16"', 'logo' => $this->boximg, 'url' => DOL_URL_ROOT . "/comm/propal.php?id=" . $objp->rowid);
                 $this->info_box_contents[$i][1] = array('td' => 'align="left"', 'text' => $objp->ref, 'text2' => $late, 'url' => DOL_URL_ROOT . "/comm/propal.php?id=" . $objp->rowid);
                 $this->info_box_contents[$i][2] = array('td' => 'align="left" width="16"', 'logo' => 'company', 'url' => DOL_URL_ROOT . "/comm/fiche.php?socid=" . $objp->socid);
                 $this->info_box_contents[$i][3] = array('td' => 'align="left"', 'text' => dol_trunc($objp->nom, 40), 'url' => DOL_URL_ROOT . "/comm/fiche.php?socid=" . $objp->socid);
                 $this->info_box_contents[$i][4] = array('td' => 'align="right"', 'text' => dol_print_date($datec, 'day'));
                 $this->info_box_contents[$i][5] = array('td' => 'align="right" width="18"', 'text' => $propalstatic->LibStatut($objp->fk_statut, 3));
                 $i++;
             }
             if ($num == 0) {
                 $this->info_box_contents[$i][0] = array('td' => 'align="center"', 'text' => $langs->trans("NoRecordedProposals"));
             }
             $db->free($result);
         } else {
             $this->info_box_contents[0][0] = array('td' => 'align="left"', 'maxlength' => 500, 'text' => $db->error() . ' sql=' . $sql);
         }
     } else {
         $this->info_box_contents[0][0] = array('td' => 'align="left"', 'text' => $langs->trans("ReadPermissionNotAllowed"));
     }
 }
开发者ID:LionSystemsSolutions,项目名称:El-Canelo-ERP,代码行数:64,代码来源:box_propales.php

示例2: loadBox

 /**
  *  Load data for box to show them later
  *
  *  @param	int		$max        Maximum number of records to load
  *  @return	void
  */
 function loadBox($max = 5)
 {
     global $user, $langs, $db, $conf;
     $this->max = $max;
     $now = dol_now();
     $this->info_box_head = array('text' => $langs->trans("BoxLastExpiredServices", $max));
     if ($user->rights->contrat->lire) {
         // Select contracts with at least one expired service
         $sql = "SELECT ";
         $sql .= " c.rowid, c.ref, c.statut as fk_statut, c.date_contrat,";
         $sql .= " s.nom as name, s.rowid as socid,";
         $sql .= " MIN(cd.date_fin_validite) as date_line, COUNT(cd.rowid) as nb_services";
         $sql .= " FROM " . MAIN_DB_PREFIX . "contrat as c, " . MAIN_DB_PREFIX . "societe s, " . MAIN_DB_PREFIX . "contratdet as cd";
         if (!$user->rights->societe->client->voir && !$user->societe_id) {
             $sql .= ", " . MAIN_DB_PREFIX . "societe_commerciaux as sc";
         }
         $sql .= " WHERE cd.statut = 4 AND cd.date_fin_validite <= '" . $db->idate($now) . "'";
         $sql .= " AND c.fk_soc=s.rowid AND cd.fk_contrat=c.rowid AND c.statut > 0";
         if ($user->societe_id) {
             $sql .= ' AND c.fk_soc = ' . $user->societe_id;
         }
         if (!$user->rights->societe->client->voir && !$user->societe_id) {
             $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = " . $user->id;
         }
         $sql .= " GROUP BY c.rowid, c.ref, c.statut, c.date_contrat, s.nom, s.rowid";
         $sql .= " ORDER BY date_line ASC";
         $sql .= $db->plimit($max, 0);
         $resql = $db->query($sql);
         if ($resql) {
             $num = $db->num_rows($resql);
             $i = 0;
             while ($i < $num) {
                 $late = '';
                 $objp = $db->fetch_object($resql);
                 $dateline = $db->jdate($objp->date_line);
                 if ($dateline + $conf->contrat->services->expires->warning_delay < $now) {
                     $late = img_warning($langs->trans("Late"));
                 }
                 $this->info_box_contents[$i][0] = array('td' => 'align="left" width="16"', 'logo' => $this->boximg, 'url' => DOL_URL_ROOT . "/contrat/card.php?id=" . $objp->rowid);
                 $this->info_box_contents[$i][1] = array('td' => 'align="left"', 'text' => $objp->ref ? $objp->ref : $objp->rowid, 'url' => DOL_URL_ROOT . "/contrat/card.php?id=" . $objp->rowid);
                 $this->info_box_contents[$i][2] = array('td' => 'align="left" width="16"', 'logo' => 'company', 'url' => DOL_URL_ROOT . "/comm/card.php?socid=" . $objp->socid);
                 $this->info_box_contents[$i][3] = array('td' => 'align="left"', 'text' => dol_trunc($objp->name, 40), 'url' => DOL_URL_ROOT . "/comm/card.php?socid=" . $objp->socid);
                 $this->info_box_contents[$i][4] = array('td' => 'align="center"', 'text' => dol_print_date($dateline, 'day'), 'text2' => $late);
                 $this->info_box_contents[$i][5] = array('td' => 'align="right"', 'text' => $objp->nb_services);
                 $i++;
             }
             if ($num == 0) {
                 $this->info_box_contents[$i][0] = array('td' => 'align="center"', 'text' => $langs->trans("NoExpiredServices"));
             }
             $db->free($resql);
         } else {
             $this->info_box_contents[0][0] = array('td' => 'align="left"', 'maxlength' => 500, 'text' => $db->error() . ' sql=' . $sql);
         }
     } else {
         $this->info_box_contents[0][0] = array('td' => 'align="left"', 'text' => $langs->trans("ReadPermissionNotAllowed"));
     }
 }
开发者ID:Samara94,项目名称:dolibarr,代码行数:63,代码来源:box_services_expired.php

示例3: min

 $nbofloop = min($num, empty($conf->global->MAIN_MAXLIST_OVERLOAD) ? 500 : $conf->global->MAIN_MAXLIST_OVERLOAD);
 while ($i < $nbofloop) {
     $obj = $db->fetch_object($result);
     $var = !$var;
     print '<tr ' . $bc[$var] . '>';
     // Ref
     print '<td class="nowrap" width="140">';
     $supplier_proposalstatic->id = $obj->supplier_proposalid;
     $supplier_proposalstatic->ref = $obj->ref;
     print '<table class="nobordernopadding"><tr class="nocellnopadd">';
     print '<td class="nobordernopadding nowrap">';
     print $supplier_proposalstatic->getNomUrl(1);
     print '</td>';
     print '<td width="18" class="nobordernopadding nowrap">';
     if ($db->jdate($obj->dfv) < $now - $conf->supplier_proposal->cloture->warning_delay) {
         print img_warning($langs->trans("Late"));
     }
     print '</td>';
     print '<td width="16" align="center" class="nobordernopadding">';
     $filename = dol_sanitizeFileName($obj->ref);
     $filedir = $conf->supplier_proposal->dir_output . '/' . dol_sanitizeFileName($obj->ref);
     $urlsource = $_SERVER['PHP_SELF'] . '?id=' . $obj->supplier_proposalid;
     print $formfile->getDocumentsLink($supplier_proposalstatic->element, $filename, $filedir);
     print '</td></tr></table>';
     print "</td>";
     $companystatic->id = $obj->socid;
     $companystatic->name = $obj->socname;
     $companystatic->client = $obj->client;
     $companystatic->canvas = $obj->canvas;
     print '<td align="left">' . $companystatic->getNomUrl(1, 'customer', 44) . '</td>' . "\n";
     print '<td align="right">';
开发者ID:Samara94,项目名称:dolibarr,代码行数:31,代码来源:index.php

示例4:

				$var=!$var;

				print "<tr $bc[$var]>";
				$classname = "impayee";

				print '<td nowrap>';
				$facturestatic->id=$objp->facid;
				$facturestatic->ref=$objp->ref;
				print $facturestatic->getNomUrl(1);
				print "</td>\n";

				print "<td nowrap>".dol_trunc($objp->facnumber,12)."</td>\n";

				print "<td nowrap align=\"center\">".dol_print_date($db->jdate($objp->df))."</td>\n";
				print "<td nowrap align=\"center\">".dol_print_date($db->jdate($objp->datelimite));
				if ($db->jdate($objp->datelimite) < ($now - $conf->facture->fournisseur->warning_delay) && ! $objp->paye && $objp->fk_statut == 1) print img_warning($langs->trans("Late"));
				print "</td>\n";

				print '<td>';
				$companystatic->id=$objp->socid;
				$companystatic->nom=$objp->nom;
				print $companystatic->getNomUrl(1,'supplier',32);
				print '</td>';

				print "<td align=\"right\">".price($objp->total_ht)."</td>";
				print "<td align=\"right\">".price($objp->total_ttc)."</td>";
				print "<td align=\"right\">".price($objp->am)."</td>";

				// Affiche statut de la facture
				print '<td align="right" nowrap="nowrap">';
				print $facturestatic->LibStatut($objp->paye,$objp->fk_statut,5,$objp->am);
开发者ID:remyyounes,项目名称:dolibarr,代码行数:31,代码来源:impayees.php

示例5: img_picto

     $nameRemain = 'remain_' . $objp->facid;
     if ($action != 'add_paiement') {
         if ($conf->use_javascript_ajax && !empty($conf->global->MAIN_JS_ON_PAYMENT)) {
             print img_picto($langs->trans('AddRemind'), 'rightarrow.png', 'id="' . $objp->facid . '" "');
         }
         print '<input type=hidden name="' . $nameRemain . '" value="' . $remaintopay . '">';
         print '<input type="text" size="8" name="' . $namef . '" value="' . $_POST[$namef] . '">';
     } else {
         print '<input type="text" size="8" name="' . $namef . '_disabled" value="' . $_POST[$namef] . '" disabled="true">';
         print '<input type="hidden" name="' . $namef . '" value="' . $_POST[$namef] . '">';
     }
     print "</td>";
     // Warning
     print '<td align="center" width="16">';
     if ($amounts[$invoice->id] && $amounts[$invoice->id] > $amountsresttopay[$invoice->id]) {
         print ' ' . img_warning($langs->trans("PaymentHigherThanReminderToPay"));
     }
     print '</td>';
     print "</tr>\n";
     $total += $objp->total;
     $total_ttc += $objp->total_ttc;
     $totalrecu += $paiement;
     $totalrecucreditnote += $creditnotes;
     $totalrecudeposits += $deposits;
     $i++;
 }
 if ($i > 1) {
     // Print total
     print '<tr class="liste_total">';
     print '<td colspan="2" align="left">' . $langs->trans('TotalTTC') . '</td>';
     print '<td align="right"><b>' . price($total_ttc) . '</b></td>';
开发者ID:netors,项目名称:dolibarr,代码行数:31,代码来源:paiement.php

示例6: img_edit

 print '<tr><td>';
 print '<table class="nobordernopadding" width="100%"><tr><td>';
 print $langs->trans('DateMaxPayment');
 print '</td>';
 if ($object->type != Facture::TYPE_CREDIT_NOTE && $action != 'editpaymentterm' && !empty($object->brouillon) && $user->rights->facture->creer) {
     print '<td align="right"><a href="' . $_SERVER["PHP_SELF"] . '?action=editpaymentterm&amp;facid=' . $object->id . '">' . img_edit($langs->trans('SetDate'), 1) . '</a></td>';
 }
 print '</tr></table>';
 print '</td><td colspan="3">';
 if ($object->type != Facture::TYPE_CREDIT_NOTE) {
     if ($action == 'editpaymentterm') {
         $form->form_date($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->date_lim_reglement, 'paymentterm');
     } else {
         print dol_print_date($object->date_lim_reglement, 'daytext');
         if ($object->hasDelay()) {
             print img_warning($langs->trans('Late'));
         }
     }
 } else {
     print '&nbsp;';
 }
 print '</td></tr>';
 // Payment mode
 print '<tr><td>';
 print '<table class="nobordernopadding" width="100%"><tr><td>';
 print $langs->trans('PaymentMode');
 print '</td>';
 if ($action != 'editmode' && !empty($object->brouillon) && $user->rights->facture->creer) {
     print '<td align="right"><a href="' . $_SERVER["PHP_SELF"] . '?action=editmode&amp;facid=' . $object->id . '">' . img_edit($langs->trans('SetMode'), 1) . '</a></td>';
 }
 print '</tr></table>';
开发者ID:Samara94,项目名称:dolibarr,代码行数:31,代码来源:facture.php

示例7: loadBox

	/**
	 *      \brief      Charge les donnees en memoire pour affichage ulterieur
	 *      \param      $max        Nombre maximum d'enregistrements a charger
	 */
	function loadBox($max=5)
	{
		global $conf, $user, $langs, $db;

		$this->max=$max;

		include_once(DOL_DOCUMENT_ROOT."/compta/facture/class/facture.class.php");
		$facturestatic=new Facture($db);

		$text = $langs->trans("BoxTitleLastCustomerBills",$max);
		$this->info_box_head = array(
				'text' => $text,
				'limit'=> dol_strlen($text)
		);

		if ($user->rights->facture->lire)
		{
			$sql = "SELECT f.rowid as facid, f.facnumber, f.type, f.amount, f.datef as df";
			$sql.= ", f.paye, f.fk_statut, f.datec, f.tms";
			$sql.= ", s.nom, s.rowid as socid";
			$sql.= ", f.date_lim_reglement as datelimite";
			$sql.= " FROM (".MAIN_DB_PREFIX."societe as s,".MAIN_DB_PREFIX."facture as f";
			if (!$user->rights->societe->client->voir && !$user->societe_id) $sql.= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
			$sql.= ")";
			$sql.= " WHERE f.fk_soc = s.rowid";
			$sql.= " AND s.entity = ".$conf->entity;
			if (!$user->rights->societe->client->voir && !$user->societe_id) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
			if($user->societe_id)	$sql.= " AND s.rowid = ".$user->societe_id;
			$sql.= " ORDER BY f.tms DESC";
			$sql.= $db->plimit($max, 0);

			$result = $db->query($sql);
			if ($result)
			{
				$num = $db->num_rows($result);
				$now=gmmktime();

				$i = 0;
				$l_due_date = $langs->trans('Late').' ('.strtolower($langs->trans('DateEcheance')).': %s)';

				while ($i < $num)
				{
					$objp = $db->fetch_object($result);
					$datelimite=$db->jdate($objp->datelimite);
					$datec=$db->jdate($objp->datec);

					$picto='bill';
					if ($objp->type == 1) $picto.='r';
					if ($objp->type == 2) $picto.='a';
					$late = '';
					if ($objp->paye == 0 && ($objp->fk_statut != 2 && $objp->fk_statut != 3) && $datelimite < ($now - $conf->facture->client->warning_delay)) { $late = img_warning(sprintf($l_due_date,dol_print_date($datelimite,'day')));}

					$this->info_box_contents[$i][0] = array('td' => 'align="left" width="16"',
                    'logo' => $picto,
                    'url' => DOL_URL_ROOT."/compta/facture.php?facid=".$objp->facid);

					$this->info_box_contents[$i][1] = array('td' => 'align="left"',
                    'text' => $objp->facnumber,
                    'text2'=> $late,
                    'url' => DOL_URL_ROOT."/compta/facture.php?facid=".$objp->facid);

					$this->info_box_contents[$i][2] = array('td' => 'align="left" width="16"',
                    'logo' => 'company',
                    'url' => DOL_URL_ROOT."/comm/fiche.php?socid=".$objp->socid);

					$this->info_box_contents[$i][3] = array('td' => 'align="left"',
                    'text' => $objp->nom,
                    'maxlength'=>40,
                    'url' => DOL_URL_ROOT."/comm/fiche.php?socid=".$objp->socid);

					$this->info_box_contents[$i][4] = array('td' => 'align="right"',
                    'text' => dol_print_date($datec,'day'),
					);

					$this->info_box_contents[$i][5] = array('td' => 'align="right" width="18"',
                    'text' => $facturestatic->LibStatut($objp->paye,$objp->fk_statut,3));

					$i++;
				}

				if ($num==0) $this->info_box_contents[$i][0] = array('td' => 'align="center"','text'=>$langs->trans("NoRecordedInvoices"));
			}
			else
			{
				$this->info_box_contents[0][0] = array(	'td' => 'align="left"',
    	        										'maxlength'=>500,
	            										'text' => ($db->error().' sql='.$sql));
			}

		}
		else {
			$this->info_box_contents[0][0] = array('td' => 'align="left"',
            'text' => $langs->trans("ReadPermissionNotAllowed"));
		}
	}
开发者ID:remyyounes,项目名称:dolibarr,代码行数:99,代码来源:box_factures.php

示例8: Task

 // Confirmation close
 if ($action == 'close') {
     print $form->formconfirm($_SERVER["PHP_SELF"] . "?id=" . $object->id, $langs->trans("CloseAProject"), $langs->trans("ConfirmCloseAProject"), "confirm_close", '', '', 1);
 }
 // Confirmation reopen
 if ($action == 'reopen') {
     print $form->formconfirm($_SERVER["PHP_SELF"] . "?id=" . $object->id, $langs->trans("ReOpenAProject"), $langs->trans("ConfirmReOpenAProject"), "confirm_reopen", '', '', 1);
 }
 // Confirmation delete
 if ($action == 'delete') {
     $text = $langs->trans("ConfirmDeleteAProject");
     $task = new Task($db);
     $taskarray = $task->getTasksArray(0, 0, $object->id, 0, 0);
     $nboftask = count($taskarray);
     if ($nboftask) {
         $text .= '<br>' . img_warning() . ' ' . $langs->trans("ThisWillAlsoRemoveTasks", $nboftask);
     }
     print $form->formconfirm($_SERVER["PHP_SELF"] . "?id=" . $object->id, $langs->trans("DeleteAProject"), $text, "confirm_delete", '', '', 1);
 }
 // Clone confirmation
 if ($action == 'clone') {
     $formquestion = array('text' => $langs->trans("ConfirmClone"), array('type' => 'checkbox', 'name' => 'clone_contacts', 'label' => $langs->trans("CloneContacts"), 'value' => true), array('type' => 'checkbox', 'name' => 'clone_tasks', 'label' => $langs->trans("CloneTasks"), 'value' => true), array('type' => 'checkbox', 'name' => 'move_date', 'label' => $langs->trans("CloneMoveDate"), 'value' => true), array('type' => 'checkbox', 'name' => 'clone_notes', 'label' => $langs->trans("CloneNotes"), 'value' => true), array('type' => 'checkbox', 'name' => 'clone_project_files', 'label' => $langs->trans("CloneProjectFiles"), 'value' => false), array('type' => 'checkbox', 'name' => 'clone_task_files', 'label' => $langs->trans("CloneTaskFiles"), 'value' => false));
     print $form->formconfirm($_SERVER["PHP_SELF"] . "?id=" . $object->id, $langs->trans("CloneProject"), $langs->trans("ConfirmCloneProject"), "confirm_clone", $formquestion, '', 1, 240);
 }
 print '<form action="' . $_SERVER["PHP_SELF"] . '" method="POST">';
 print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
 print '<input type="hidden" name="action" value="update">';
 print '<input type="hidden" name="id" value="' . $object->id . '">';
 print '<input type="hidden" name="comefromclone" value="' . $comefromclone . '">';
 $head = project_prepare_head($object);
 dol_fiche_head($head, 'project', $langs->trans("Project"), 0, $object->public ? 'projectpub' : 'project');
开发者ID:TAASA,项目名称:Dolibarr-ERP-3.8.1,代码行数:31,代码来源:card.php

示例9: info

 /**
  * Return description of a module
  *
  * @param	Translate	$langs		Object language
  * @return	string      			Description
  */
 function info($langs)
 {
     global $conf, $langs;
     $langs->load("companies");
     $langs->load("errors");
     $form = new Form($db);
     $texte = $this->description . ".<br>\n";
     $texte .= '<form action="' . $_SERVER["PHP_SELF"] . '" method="POST">';
     $texte .= '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
     $texte .= '<input type="hidden" name="action" value="setModuleOptions">';
     $texte .= '<input type="hidden" name="param1" value="COMPANY_ADDON_PDF_ODT_PATH">';
     $texte .= '<table class="nobordernopadding" width="100%">';
     // List of directories area
     $texte .= '<tr><td>';
     $texttitle = $langs->trans("ListOfDirectories");
     $listofdir = explode(',', preg_replace('/[\\r\\n]+/', ',', trim($conf->global->COMPANY_ADDON_PDF_ODT_PATH)));
     $listoffiles = array();
     foreach ($listofdir as $key => $tmpdir) {
         $tmpdir = trim($tmpdir);
         $tmpdir = preg_replace('/DOL_DATA_ROOT/', DOL_DATA_ROOT, $tmpdir);
         if (!$tmpdir) {
             unset($listofdir[$key]);
             continue;
         }
         if (!is_dir($tmpdir)) {
             $texttitle .= img_warning($langs->trans("ErrorDirNotFound", $tmpdir), 0);
         } else {
             $tmpfiles = dol_dir_list($tmpdir, 'files', 0, '\\.odt');
             if (count($tmpfiles)) {
                 $listoffiles = array_merge($listoffiles, $tmpfiles);
             }
         }
     }
     $texthelp = $langs->trans("ListOfDirectoriesForModelGenODT");
     // Add list of substitution keys
     $texthelp .= '<br>' . $langs->trans("FollowingSubstitutionKeysCanBeUsed") . '<br>';
     $texthelp .= $langs->transnoentitiesnoconv("FullListOnOnlineDocumentation");
     // This contains an url, we don't modify it
     $texte .= $form->textwithpicto($texttitle, $texthelp, 1, 'help', '', 1);
     $texte .= '<table><tr><td>';
     $texte .= '<textarea class="flat" cols="60" name="value1">';
     $texte .= $conf->global->COMPANY_ADDON_PDF_ODT_PATH;
     $texte .= '</textarea>';
     $texte .= '</td>';
     $texte .= '<td align="center">&nbsp; ';
     $texte .= '<input type="submit" class="button" value="' . $langs->trans("Modify") . '" name="Button">';
     $texte .= '</td>';
     $texte .= '</tr>';
     $texte .= '</table>';
     // Scan directories
     if (count($listofdir)) {
         $texte .= $langs->trans("NumberOfModelFilesFound") . ': <b>' . count($listoffiles) . '</b>';
     }
     $texte .= '</td>';
     $texte .= '<td valign="top" rowspan="2">';
     $texte .= $langs->trans("ExampleOfDirectoriesForModelGen");
     $texte .= '</td>';
     $texte .= '</tr>';
     /*$texte.= '<tr><td align="center">';
     		$texte.= '<input type="submit" class="button" value="'.$langs->trans("Modify").'" name="Button">';
     		$texte.= '</td>';
     		$texte.= '</tr>';*/
     $texte .= '</table>';
     $texte .= '</form>';
     return $texte;
 }
开发者ID:nrjacker4,项目名称:crm-php,代码行数:72,代码来源:doc_generic_contract_odt.modules.php

示例10: foreach

                			print '<input name="idl'.$indiceAsked.'" type="hidden" value="'.$line->id.'">';
                			print '<input name="qtyl'.$indiceAsked.'" type="text" size="4" value="'.$quantityToBeDelivered.'">';
                			print '</td>';
                			if ($line->product_type == 1) print '<td>&nbsp;</td>';
                		}*/
                print "</tr>\n";
                // Show subproducts of product
                if (!empty($conf->global->PRODUIT_SOUSPRODUITS) && $line->fk_product > 0) {
                    $product->get_sousproduits_arbo();
                    $prods_arbo = $product->get_arbo_each_prod($qtyProdCom);
                    if (sizeof($prods_arbo) > 0) {
                        foreach ($prods_arbo as $key => $value) {
                            //print $value[0];
                            $img = '';
                            if ($value['stock'] < $value['stock_alert']) {
                                $img = img_warning($langs->trans("StockTooLow"));
                            }
                            print "<tr " . $bc[$var] . "><td>&nbsp; &nbsp; &nbsp; ->\n                                <a href=\"" . DOL_URL_ROOT . "/product/fiche.php?id=" . $value['id'] . "\">" . $value['fullpath'] . "\n                                </a> (" . $value['nb'] . ")</td><td align=\"center\"> " . $value['nb_total'] . "</td><td>&nbsp</td><td>&nbsp</td>\n                                <td align=\"center\">" . $value['stock'] . " " . $img . "</td></tr>";
                        }
                    }
                }
                $indiceAsked++;
            }
            print '<tr><td align="center" colspan="5"><br><input type="submit" class="button" value="' . $langs->trans("Create") . '"></td></tr>';
            print "</table>";
            print '</form>';
        } else {
            dol_print_error($db);
        }
    }
} else {
开发者ID:netors,项目名称:dolibarr,代码行数:31,代码来源:fiche.php

示例11: preg_replace

print '</td>';
print '</tr>';
// Use anti virus
$var = !$var;
print "<tr " . $bc[$var] . ">";
print '<td colspan="2">' . $langs->trans("AntiVirusCommand") . '<br>';
print $langs->trans("AntiVirusCommandExample");
// Check command in inside safe_mode
print '</td>';
print '<td>';
if (ini_get('safe_mode') && !empty($conf->global->MAIN_ANTIVIRUS_COMMAND)) {
    $langs->load("errors");
    $basedir = preg_replace('/"/', '', dirname($conf->global->MAIN_ANTIVIRUS_COMMAND));
    $listdir = explode(';', ini_get('safe_mode_exec_dir'));
    if (!in_array($basedir, $listdir)) {
        print img_warning($langs->trans('WarningSafeModeOnCheckExecDir'));
        dol_syslog("safe_mode is on, basedir is " . $basedir . ", safe_mode_exec_dir is " . ini_get('safe_mode_exec_dir'), LOG_WARNING);
    }
}
print '<input type="text" name="MAIN_ANTIVIRUS_COMMAND" size="72" value="' . (!empty($conf->global->MAIN_ANTIVIRUS_COMMAND) ? dol_htmlentities($conf->global->MAIN_ANTIVIRUS_COMMAND) : '') . '">';
print "</td>";
print '</tr>';
// Use anti virus
$var = !$var;
print "<tr " . $bc[$var] . ">";
print '<td colspan="2">' . $langs->trans("AntiVirusParam") . '<br>';
print $langs->trans("AntiVirusParamExample");
print '</td>';
print '<td>';
print '<input type="text" name="MAIN_ANTIVIRUS_PARAM" size="72" value="' . (!empty($conf->global->MAIN_ANTIVIRUS_PARAM) ? dol_htmlentities($conf->global->MAIN_ANTIVIRUS_PARAM) : '') . '">';
print "</td>";
开发者ID:ADDAdev,项目名称:Dolibarr,代码行数:31,代码来源:security_other.php

示例12: img_warning

                    print '<td align="right" width="10%">' . $pdluo->qty . ($pdluo->qty < 0 ? ' ' . img_warning() : '') . '</td>';
                    print '<td colspan="4"><input type="submit" class="button" id="savelinebutton" name="save" value="' . $langs->trans("Save") . '">';
                    print '<input type="submit" class="button" id="cancellinebutton" name="Cancel" value="' . $langs->trans("Cancel") . '"></td></tr>';
                    print '</table></form>';
                } else {
                    print "\n" . '<tr><td align="right">';
                    print img_picto($langs->trans("Tranfer"), 'uparrow', 'class="hideonsmartphone"') . ' ';
                    print '<a href="' . $_SERVER["PHP_SELF"] . '?id=' . $product->id . '&amp;action=transfert&amp;pdluoid=' . $pdluo->id . '">' . $langs->trans("StockMovement") . '</a>';
                    // Disabled, because edition of stock content must use the "Correct stock menu".
                    // Do not use this, or data will be wrong (bad tracking of movement label, inventory code, ...
                    //print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$id.'&amp;action=editline&amp;lineid='.$pdluo->id.'#'.$pdluo->id.'">';
                    //print img_edit().'</a></td>';
                    print '<td align="right">' . $pdluo->batch . '</td>';
                    print '<td align="center">' . dol_print_date($pdluo->eatby, 'day') . '</td>';
                    print '<td align="center">' . dol_print_date($pdluo->sellby, 'day') . '</td>';
                    print '<td align="right">' . $pdluo->qty . ($pdluo->qty < 0 ? ' ' . img_warning() : '') . '</td>';
                    print '<td colspan="4"></td></tr>';
                }
            }
        }
        $i++;
        $var = !$var;
    }
} else {
    dol_print_error($db);
}
print '<tr class="liste_total"><td align="right" class="liste_total" colspan="4">' . $langs->trans("Total") . ':</td>';
print '<td class="liste_total" align="right">' . $total . '</td>';
print '<td class="liste_total" align="right">';
print $totalwithpmp ? price(price2num($totalvalue / $totalwithpmp, 'MU')) : '&nbsp;';
// This value may have rounding errors
开发者ID:TAASA,项目名称:Dolibarr-ERP-3.8.1,代码行数:31,代码来源:product.php

示例13: loadBox

 /**
  *  Load data into info_box_contents array to show array later.
  *
  *  @param	int		$max        Maximum number of records to load
  *  @return	void
  */
 function loadBox($max = 5)
 {
     global $user, $langs, $db, $conf;
     $this->max = $max;
     include_once DOL_DOCUMENT_ROOT . '/comm/propal/class/propal.class.php';
     include_once DOL_DOCUMENT_ROOT . '/societe/class/societe.class.php';
     $propalstatic = new Propal($db);
     $societestatic = new Societe($db);
     $this->info_box_head = array('text' => $langs->trans("BoxTitleLast" . ($conf->global->MAIN_LASTBOX_ON_OBJECT_DATE ? "" : "Modified") . "Propals", $max));
     if ($user->rights->propale->lire) {
         $sql = "SELECT s.nom as name, s.rowid as socid, s.code_client, s.logo,";
         $sql .= " p.rowid, p.ref, p.fk_statut, p.datep as dp, p.datec, p.fin_validite, p.date_cloture, p.total_ht, p.tva as total_tva, p.total as total_ttc, p.tms";
         $sql .= " FROM " . MAIN_DB_PREFIX . "societe as s";
         $sql .= ", " . MAIN_DB_PREFIX . "propal as p";
         if (!$user->rights->societe->client->voir && !$user->societe_id) {
             $sql .= ", " . MAIN_DB_PREFIX . "societe_commerciaux as sc";
         }
         $sql .= " WHERE p.fk_soc = s.rowid";
         $sql .= " AND p.entity = " . $conf->entity;
         if (!$user->rights->societe->client->voir && !$user->societe_id) {
             $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = " . $user->id;
         }
         if ($user->societe_id) {
             $sql .= " AND s.rowid = " . $user->societe_id;
         }
         if ($conf->global->MAIN_LASTBOX_ON_OBJECT_DATE) {
             $sql .= " ORDER BY p.datep DESC, p.ref DESC ";
         } else {
             $sql .= " ORDER BY p.tms DESC, p.ref DESC ";
         }
         $sql .= $db->plimit($max, 0);
         $result = $db->query($sql);
         if ($result) {
             $num = $db->num_rows($result);
             $now = dol_now();
             $line = 0;
             while ($line < $num) {
                 $objp = $db->fetch_object($result);
                 $date = $db->jdate($objp->dp);
                 $datec = $db->jdate($objp->datec);
                 $datem = $db->jdate($objp->tms);
                 $dateterm = $db->jdate($objp->fin_validite);
                 $dateclose = $db->jdate($objp->date_cloture);
                 $propalstatic->id = $objp->rowid;
                 $propalstatic->ref = $objp->ref;
                 $propalstatic->total_ht = $objp->total_ht;
                 $propalstatic->total_tva = $objp->total_tva;
                 $propalstatic->total_ttc = $objp->total_ttc;
                 $societestatic->id = $objp->socid;
                 $societestatic->name = $objp->name;
                 $societestatic->code_client = $objp->code_client;
                 $societestatic->logo = $objp->logo;
                 $late = '';
                 if ($objp->fk_statut == 1 && $dateterm < $now - $conf->propal->cloture->warning_delay) {
                     $late = img_warning($langs->trans("Late"));
                 }
                 $this->info_box_contents[$line][] = array('td' => 'align="left"', 'text' => $propalstatic->getNomUrl(1), 'text2' => $late, 'asis' => 1);
                 $this->info_box_contents[$line][] = array('td' => 'align="left"', 'text' => $societestatic->getNomUrl(1, '', 40), 'asis' => 1);
                 $this->info_box_contents[$line][] = array('td' => 'align="right"', 'text' => price($objp->total_ht, 0, $langs, 0, -1, -1, $conf->currency));
                 $this->info_box_contents[$line][] = array('td' => 'align="right"', 'text' => dol_print_date($date, 'day'));
                 $this->info_box_contents[$line][] = array('td' => 'align="right" width="18"', 'text' => $propalstatic->LibStatut($objp->fk_statut, 3));
                 $line++;
             }
             if ($num == 0) {
                 $this->info_box_contents[$line][0] = array('td' => 'align="center"', 'text' => $langs->trans("NoRecordedProposals"));
             }
             $db->free($result);
         } else {
             $this->info_box_contents[0][0] = array('td' => 'align="left"', 'maxlength' => 500, 'text' => $db->error() . ' sql=' . $sql);
         }
     } else {
         $this->info_box_contents[0][0] = array('td' => 'align="left"', 'text' => $langs->trans("ReadPermissionNotAllowed"));
     }
 }
开发者ID:Samara94,项目名称:dolibarr,代码行数:80,代码来源:box_propales.php

示例14: img_warning

         print '. ' . $langs->transnoentitiesnoconv("ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS", $prodtmp->getNomUrl(1));
         // must use noentitiesnoconv to avoid to encode html into getNomUrl of product
     }
     print '<br>';
 }
 // Add invoice with payments
 if (!empty($conf->banque->enabled) && !empty($conf->societe->enabled) && !empty($conf->facture->enabled)) {
     print '<input type="radio" class="moreaction" id="bankviainvoice" name="paymentsave" value="bankviainvoice"' . (!empty($bankviainvoice) ? ' checked' : '');
     //if (empty($object->fk_soc)) print ' disabled';
     print '> ' . $langs->trans("MoreActionBankViaInvoice");
     if ($object->fk_soc) {
         print ' (' . $langs->trans("ThirdParty") . ': ' . $company->getNomUrl(1) . ')';
     } else {
         print ' (';
         if (empty($object->fk_soc)) {
             print img_warning($langs->trans("NoThirdPartyAssociatedToMember"));
         }
         print $langs->trans("NoThirdPartyAssociatedToMember");
         print ' - <a href="' . $_SERVER["PHP_SELF"] . '?rowid=' . $object->id . '&amp;action=create_thirdparty">';
         print $langs->trans("CreateDolibarrThirdParty");
         print '</a>)';
     }
     if (empty($conf->global->ADHERENT_VAT_FOR_SUBSCRIPTIONS) || $conf->global->ADHERENT_VAT_FOR_SUBSCRIPTIONS != 'defaultforfoundationcountry') {
         print '. ' . $langs->trans("NoVatOnSubscription", 0);
     }
     if (!empty($conf->global->ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS) && (!empty($conf->product->enabled) || !empty($conf->service->enabled))) {
         $prodtmp = new Product($db);
         $prodtmp->fetch($conf->global->ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS);
         print '. ' . $langs->transnoentitiesnoconv("ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS", $prodtmp->getNomUrl(1));
         // must use noentitiesnoconv to avoid to encode html into getNomUrl of product
     }
开发者ID:Albertopf,项目名称:prueba,代码行数:31,代码来源:card_subscriptions.php

示例15: GETPOST

         continue;
     }
     $param = 'NOTIFICATION_FIXEDEMAIL_' . $notifiedevent['code'] . '_THRESHOLD_HIGHER_' . $reg[1];
     $value = GETPOST('NOTIF_' . $notifiedevent['code'] . '_old_' . $reg[1] . '_key') ? GETPOST('NOTIF_' . $notifiedevent['code'] . '_old_' . $reg[1] . '_key', 'alpha') : $conf->global->{$param};
     $s = '<input type="text" size="32" name="NOTIF_' . $notifiedevent['code'] . '_old_' . $reg[1] . '_key" value="' . dol_escape_htmltag($value) . '">';
     // Do not use type="email" here, we must be able to enter a list of email with , separator.
     $arrayemail = explode(',', $value);
     $showwarning = 0;
     foreach ($arrayemail as $key => $valuedet) {
         $valuedet = trim($valuedet);
         if (!empty($valuedet) && !isValidEmail($valuedet, 1)) {
             $showwarning++;
         }
     }
     if (!empty($conf->global->{$param}) && $showwarning) {
         $s .= ' ' . img_warning($langs->trans("ErrorBadEMail"));
     }
     print $form->textwithpicto($s, $langs->trans("YouCanUseCommaSeparatorForSeveralRecipients") . '<br>' . $langs->trans("YouCanAlsoUseSupervisorKeyword"), 1, 'help', '', 0, 2);
     print '<br>';
 }
 // New entry input fields
 $s = '<input type="text" size="32" name="NOTIF_' . $notifiedevent['code'] . '_new_key" value="">';
 // Do not use type="email" here, we must be able to enter a list of email with , separator.
 print $form->textwithpicto($s, $langs->trans("YouCanUseCommaSeparatorForSeveralRecipients") . '<br>' . $langs->trans("YouCanAlsoUseSupervisorKeyword"), 1, 'help', '', 0, 2);
 print '</td>';
 print '<td>';
 // Notification with threshold
 foreach ($conf->global as $key => $val) {
     if ($val == '' || !preg_match('/^NOTIFICATION_FIXEDEMAIL_' . $notifiedevent['code'] . '_THRESHOLD_HIGHER_(.*)/', $key, $reg)) {
         continue;
     }
开发者ID:Samara94,项目名称:dolibarr,代码行数:31,代码来源:notification.php


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