New: Add picto on tab titles

This commit is contained in:
Laurent Destailleur 2009-08-05 17:49:12 +00:00
parent 0baf06d2d1
commit 3ef5f96974
20 changed files with 49 additions and 162 deletions

View File

@ -899,7 +899,7 @@ if ($_GET['action'] == 'down' && $user->rights->propale->creer)
* View * View
*/ */
llxHeader('',$langs->trans('Proposal'),'Proposition'); llxHeader('',$langs->trans('Proposal'),'EN:Commercial_Proposals|FR:Proposition_commerciale|ES:Presupuestos');
$html = new Form($db); $html = new Form($db);
$formfile = new FormFile($db); $formfile = new FormFile($db);
@ -925,7 +925,7 @@ if ($id > 0 || ! empty($ref))
$societe->fetch($propal->socid); $societe->fetch($propal->socid);
$head = propal_prepare_head($propal); $head = propal_prepare_head($propal);
dol_fiche_head($head, 'comm', $langs->trans('Proposal')); dol_fiche_head($head, 'comm', $langs->trans('Proposal'), 0, 'propal');
// Clone confirmation // Clone confirmation
if ($_GET["action"] == 'clone') if ($_GET["action"] == 'clone')

View File

@ -1,106 +0,0 @@
<?php
/* Copyright (C) 2001-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
/**
\file htdocs/comm/propal/aideremise.php
\ingroup propale
\brief Page de simulation des remises
\version $Id$
*/
require("./pre.inc.php");
include_once(DOL_DOCUMENT_ROOT."/propal.class.php");
$propalid = isset($_GET["propalid"])?$_GET["propalid"]:'';
// Security cehck
if ($user->societe_id) $socid=$user->societe_id;
$result = restrictedArea($user, 'propale', $propalid, 'propal');
/******************************************************************************/
/* Actions */
/******************************************************************************/
/******************************************************************************/
/* View */
/******************************************************************************/
llxHeader();
/*
*
* Mode fiche
*
*
*/
if ($_GET["propalid"])
{
$html = new Form($db);
$propal = new Propal($db);
$propal->fetch($_GET["propalid"]);
$societe = new Societe($db);
$societe->fetch($propal->socid);
$head[0][0] = DOL_URL_ROOT.'/comm/propal.php?propalid='.$propal->id;
$head[0][1] = "Proposition commerciale : $propal->ref";
$h = 1;
$a = 0;
$head[$h][0] = DOL_URL_ROOT.'/comm/propal/note.php?propalid='.$propal->id;
$head[$h][1] = "Note";
$h++;
$head[$h][0] = DOL_URL_ROOT.'/comm/propal/info.php?propalid='.$propal->id;
$head[$h][1] = "Info";
dol_fiche_head($head, $a, $societe->nom);
$price = $propal->price + $propal->remise;
print_titre("Simulation des remises sur le prix HT : ".price($price));
print '<table class="border" cellspacing="0" cellpadding="2" width="100%">';
$j=1;
for ($i = 1 ; $i < 100 ; $i= $i+3)
{
$ht1 = $price - ($price * $j / 100 );
$ht2 = $price - ($price * ($j+33) / 100 );
$ht3 = $price - ($price * ($j+66) / 100 );
print "<tr><td>$j %</td><td>".price($ht1)."</td>";
print "<td>".($j+33)." %</td><td>".price($ht2)."</td>";
print "<td>".($j+66)." %</td><td>".price($ht3)."</td></tr>";
$j++;
}
print "</table>";
}
$db->close();
llxFooter("<em>Derni&egrave;re modification $Date$ r&eacute;vision $Revision$</em>");
?>

View File

@ -1,6 +1,6 @@
<?php <?php
/* Copyright (C) 2002-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org> /* Copyright (C) 2002-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004 Éric Seigne <eric.seigne@ryxeo.com> * Copyright (C) 2004 <EFBFBD>ric Seigne <eric.seigne@ryxeo.com>
* Copyright (C) 2004-2007 Laurent Destailleur <eldy@users.sourceforge.net> * Copyright (C) 2004-2007 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr> * Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
* *
@ -22,7 +22,7 @@
/** /**
\file htdocs/comm/propal/apercu.php \file htdocs/comm/propal/apercu.php
\ingroup propal \ingroup propal
\brief Page de l'onglet aperçu d'une propal \brief Page de l'onglet aper<EFBFBD>u d'une propal
\version $Id$ \version $Id$
*/ */
@ -66,7 +66,7 @@ if ($_GET["propalid"] > 0)
$soc->fetch($propal->socid); $soc->fetch($propal->socid);
$head = propal_prepare_head($propal); $head = propal_prepare_head($propal);
dol_fiche_head($head, 'preview', $langs->trans('Proposal')); dol_fiche_head($head, 'preview', $langs->trans('Proposal'), 0, 'propal');
/* /*
@ -141,7 +141,7 @@ if ($_GET["propalid"] > 0)
$relativepath = "${propalref}/${propalref}.pdf"; $relativepath = "${propalref}/${propalref}.pdf";
$relativepathdetail = "${propalref}/${propalref}-detail.pdf"; $relativepathdetail = "${propalref}/${propalref}-detail.pdf";
// Chemin vers png aperçus // Chemin vers png aper<EFBFBD>us
$relativepathimage = "${propalref}/${propalref}.pdf.png"; $relativepathimage = "${propalref}/${propalref}.pdf.png";
$fileimage = $file.".png"; // Si PDF d'1 page $fileimage = $file.".png"; // Si PDF d'1 page
$fileimagebis = $file.".png.0"; // Si PDF de plus d'1 page $fileimagebis = $file.".png.0"; // Si PDF de plus d'1 page
@ -163,8 +163,8 @@ if ($_GET["propalid"] > 0)
print '</tr>'; print '</tr>';
// Si fichier detail PDF existe // Si fichier detail PDF existe
if (file_exists($filedetail)) { // propal détaillée supplémentaire if (file_exists($filedetail)) { // propal d<EFBFBD>taill<EFBFBD>e suppl<70>mentaire
print "<tr $bc[$var]><td>Propal détaillée</td>"; print "<tr $bc[$var]><td>Propal d<EFBFBD>taill<EFBFBD>e</td>";
print '<td><a href="'.DOL_URL_ROOT . '/document.php?modulepart=propal&file='.urlencode($relativepathdetail).'">'.$propal->ref.'-detail.pdf</a></td>'; print '<td><a href="'.DOL_URL_ROOT . '/document.php?modulepart=propal&file='.urlencode($relativepathdetail).'">'.$propal->ref.'-detail.pdf</a></td>';
print '<td align="right">'.filesize($filedetail). ' bytes</td>'; print '<td align="right">'.filesize($filedetail). ' bytes</td>';
@ -213,17 +213,17 @@ if ($_GET["propalid"] > 0)
dol_print_error($db); dol_print_error($db);
} }
} else { } else {
// Propal non trouvée // Propal non trouv<EFBFBD>e
print $langs->trans("ErrorPropalNotFound",$_GET["propalid"]); print $langs->trans("ErrorPropalNotFound",$_GET["propalid"]);
} }
} }
// Si fichier png PDF d'1 page trouvé // Si fichier png PDF d'1 page trouv<EFBFBD>
if (file_exists($fileimage)) if (file_exists($fileimage))
{ {
print '<img src="'.DOL_URL_ROOT . '/viewimage.php?modulepart=apercupropal&file='.urlencode($relativepathimage).'">'; print '<img src="'.DOL_URL_ROOT . '/viewimage.php?modulepart=apercupropal&file='.urlencode($relativepathimage).'">';
} }
// Si fichier png PDF de plus d'1 page trouvé // Si fichier png PDF de plus d'1 page trouv<EFBFBD>
elseif (file_exists($fileimagebis)) elseif (file_exists($fileimagebis))
{ {
$multiple = $relativepathimage . "."; $multiple = $relativepathimage . ".";

View File

@ -173,7 +173,7 @@ if ($id > 0)
$head = propal_prepare_head($propal); $head = propal_prepare_head($propal);
dol_fiche_head($head, 'contact', $langs->trans("Proposal")); dol_fiche_head($head, 'contact', $langs->trans("Proposal"), 0, 'propal');
/* /*

View File

@ -125,7 +125,7 @@ if ($propalid > 0)
$societe->fetch($propal->socid); $societe->fetch($propal->socid);
$head = propal_prepare_head($propal); $head = propal_prepare_head($propal);
dol_fiche_head($head, 'document', $langs->trans('Proposal')); dol_fiche_head($head, 'document', $langs->trans('Proposal'), 0, 'propal');
// Construit liste des fichiers // Construit liste des fichiers

View File

@ -41,8 +41,7 @@ $result = restrictedArea($user, 'propale', $propalid, 'propal');
/* /*
* * View
*
*/ */
llxHeader(); llxHeader();
@ -54,7 +53,7 @@ $societe = new Societe($db);
$societe->fetch($propal->socid); $societe->fetch($propal->socid);
$head = propal_prepare_head($propal); $head = propal_prepare_head($propal);
dol_fiche_head($head, 'info', $langs->trans('Proposal')); dol_fiche_head($head, 'info', $langs->trans('Proposal'), 0, 'propal');
$propal->info($propal->id); $propal->info($propal->id);

View File

@ -107,7 +107,7 @@ if ($_GET['propalid'])
if ( $societe->fetch($propal->socid) ) if ( $societe->fetch($propal->socid) )
{ {
$head = propal_prepare_head($propal); $head = propal_prepare_head($propal);
dol_fiche_head($head, 'note', $langs->trans('Proposal')); dol_fiche_head($head, 'note', $langs->trans('Proposal'), 0, 'propal');
print '<table class="border" width="100%">'; print '<table class="border" width="100%">';

View File

@ -147,7 +147,7 @@ if ($id > 0 || ! empty($ref))
$societe->fetch($propal->socid); $societe->fetch($propal->socid);
$head = propal_prepare_head($propal); $head = propal_prepare_head($propal);
dol_fiche_head($head, 'compta', $langs->trans('Proposal')); dol_fiche_head($head, 'compta', $langs->trans('Proposal'), 0, 'propal');
/* /*

View File

@ -48,12 +48,9 @@ $contact = new Contact($db);
$contact->fetch($_GET["id"], $user); $contact->fetch($_GET["id"], $user);
/*
* Affichage onglets
*/
$head = contact_prepare_head($contact); $head = contact_prepare_head($contact);
dol_fiche_head($head, 'exportimport', $langs->trans("Contact")); dol_fiche_head($head, 'exportimport', $langs->trans("Contact"), 0, 'contact');
/* /*

View File

@ -218,7 +218,7 @@ if ($_GET["id"] > 0)
*/ */
$head = contact_prepare_head($contact); $head = contact_prepare_head($contact);
dol_fiche_head($head, 'general', $langs->trans("Contact")); dol_fiche_head($head, 'general', $langs->trans("Contact"), 0, 'contact');
} }

View File

@ -51,7 +51,7 @@ $contact->fetch($_GET["id"], $user);
$head = contact_prepare_head($contact); $head = contact_prepare_head($contact);
dol_fiche_head($head, 'info', $langs->trans("Contact")); dol_fiche_head($head, 'info', $langs->trans("Contact"), 0, 'contact');
print '<table width="100%"><tr><td>'; print '<table width="100%"><tr><td>';

View File

@ -52,12 +52,9 @@ $contact = new Contact($db);
$contact->fetch($_GET["id"], $user); $contact->fetch($_GET["id"], $user);
/*
* Affichage onglets
*/
$head = contact_prepare_head($contact); $head = contact_prepare_head($contact);
dol_fiche_head($head, 'ldap', $langs->trans("Contact")); dol_fiche_head($head, 'ldap', $langs->trans("Contact"), 0, 'contact');
/* /*
@ -97,7 +94,7 @@ print '</td></tr>';
// LDAP DN // LDAP DN
print '<tr><td>LDAP '.$langs->trans("LDAPContactDn").'</td><td class="valeur" colspan="3">'.$conf->global->LDAP_CONTACT_DN."</td></tr>\n"; print '<tr><td>LDAP '.$langs->trans("LDAPContactDn").'</td><td class="valeur" colspan="3">'.$conf->global->LDAP_CONTACT_DN."</td></tr>\n";
// LDAP Clé // LDAP Cl<EFBFBD>
print '<tr><td>LDAP '.$langs->trans("LDAPNamingAttribute").'</td><td class="valeur" colspan="3">'.$conf->global->LDAP_KEY_CONTACTS."</td></tr>\n"; print '<tr><td>LDAP '.$langs->trans("LDAPNamingAttribute").'</td><td class="valeur" colspan="3">'.$conf->global->LDAP_KEY_CONTACTS."</td></tr>\n";
// LDAP Server // LDAP Server

View File

@ -82,7 +82,7 @@ $contact->fetch($_GET["id"], $user);
*/ */
$head = contact_prepare_head($contact); $head = contact_prepare_head($contact);
dol_fiche_head($head, 'perso', $langs->trans("Contact")); dol_fiche_head($head, 'perso', $langs->trans("Contact"), 0, 'contact');

View File

@ -2054,7 +2054,7 @@ class Propal extends CommonObject
} }
$lienfin='</a>'; $lienfin='</a>';
$picto='order'; $picto='propal';
$label=$langs->trans("ShowPropal").': '.$this->ref; $label=$langs->trans("ShowPropal").': '.$this->ref;
if ($withpicto) $result.=($lien.img_object($label,$picto).$lienfin); if ($withpicto) $result.=($lien.img_object($label,$picto).$lienfin);

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB