New: Add menu new shipment

This commit is contained in:
Laurent Destailleur 2011-08-21 11:00:43 +00:00
parent 450f9e2617
commit 37cf63870f
5 changed files with 19 additions and 15 deletions

View File

@ -25,7 +25,7 @@
* \file htdocs/expedition/fiche.php * \file htdocs/expedition/fiche.php
* \ingroup expedition * \ingroup expedition
* \brief Fiche descriptive d'une expedition * \brief Fiche descriptive d'une expedition
* \version $Id: fiche.php,v 1.210 2011/07/10 20:03:39 eldy Exp $ * \version $Id: fiche.php,v 1.211 2011/08/21 11:00:43 eldy Exp $
*/ */
require("../main.inc.php"); require("../main.inc.php");
@ -479,6 +479,13 @@ $html = new Form($db);
$formfile = new FormFile($db); $formfile = new FormFile($db);
$formproduct = new FormProduct($db); $formproduct = new FormProduct($db);
if ($action == 'create2')
{
print_fiche_titre($langs->trans("CreateASending")).'<br>';
print $langs->trans("ShipmentCreationIsDoneFromOrder");
$action=''; $id=''; $ref='';
}
/********************************************************************* /*********************************************************************
* *
* Mode creation * Mode creation
@ -494,10 +501,7 @@ if ($action == 'create')
$mesg='<div class="error">'.$langs->trans("ErrorBadParameters").'</div>'; $mesg='<div class="error">'.$langs->trans("ErrorBadParameters").'</div>';
} }
if ($mesg) dol_htmloutput_mesg($mesg);
{
print $mesg.'<br>';
}
if ($origin) if ($origin)
{ {
@ -1373,13 +1377,9 @@ else
show_list_sending_receive($object->origin,$object->origin_id); show_list_sending_receive($object->origin,$object->origin_id);
} }
} }
else
{
print "Expedition inexistante ou acces refuse";
}
} }
$db->close(); $db->close();
llxFooter('$Date: 2011/07/10 20:03:39 $ - $Revision: 1.210 $'); llxFooter('$Date: 2011/08/21 11:00:43 $ - $Revision: 1.211 $');
?> ?>

View File

@ -1,6 +1,6 @@
-- --
-- $Id: init_menu_auguria.sql,v 1.127 2011/08/11 01:39:15 eldy Exp $ -- $Id: init_menu_auguria.sql,v 1.128 2011/08/21 11:00:58 eldy Exp $
-- $Revision: 1.127 $ -- $Revision: 1.128 $
-- --
-- Menu base entries -- Menu base entries
-- This file is loaded when a menu handler base is activated (auguria, etc..) -- This file is loaded when a menu handler base is activated (auguria, etc..)
@ -109,8 +109,9 @@ insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk
insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->categorie->enabled', __HANDLER__, 'left', 3201__+MAX_llx_menu__, 'products', '', 3200__+MAX_llx_menu__, '/categories/fiche.php?action=create&amp;type=0', 'NewCategory', 1, 'categories', '$user->rights->categorie->creer', '', 2, 0, __ENTITY__); insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->categorie->enabled', __HANDLER__, 'left', 3201__+MAX_llx_menu__, 'products', '', 3200__+MAX_llx_menu__, '/categories/fiche.php?action=create&amp;type=0', 'NewCategory', 1, 'categories', '$user->rights->categorie->creer', '', 2, 0, __ENTITY__);
-- Product - Shipment -- Product - Shipment
insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->expedition->enabled', __HANDLER__, 'left', 1300__+MAX_llx_menu__, 'commercial', '', 3__+MAX_llx_menu__, '/expedition/index.php?leftmenu=sendings', 'Shipments', 0, 'sendings', '$user->rights->expedition->lire', '', 2, 6, __ENTITY__); insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->expedition->enabled', __HANDLER__, 'left', 1300__+MAX_llx_menu__, 'commercial', '', 3__+MAX_llx_menu__, '/expedition/index.php?leftmenu=sendings', 'Shipments', 0, 'sendings', '$user->rights->expedition->lire', '', 2, 6, __ENTITY__);
insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->expedition->enabled && $leftmenu=="sendings"', __HANDLER__, 'left', 1301__+MAX_llx_menu__, 'commercial', '', 1300__+MAX_llx_menu__, '/expedition/liste.php?leftmenu=sendings', 'List', 1, 'sendings', '$user->rights->expedition->lire', '', 2, 0, __ENTITY__); insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->expedition->enabled && $leftmenu=="sendings"', __HANDLER__, 'left', 1301__+MAX_llx_menu__, 'commercial', '', 1300__+MAX_llx_menu__, '/expedition/fiche.php?action=create2&leftmenu=sendings', 'NewSending', 1, 'sendings', '$user->rights->expedition->creer', '', 2, 0, __ENTITY__);
insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->expedition->enabled && $leftmenu=="sendings"', __HANDLER__, 'left', 1302__+MAX_llx_menu__, 'commercial', '', 1300__+MAX_llx_menu__, '/expedition/stats/index.php?leftmenu=sendings', 'Statistics', 1, 'sendings', '$user->rights->expedition->lire', '', 2, 1, __ENTITY__); insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->expedition->enabled && $leftmenu=="sendings"', __HANDLER__, 'left', 1302__+MAX_llx_menu__, 'commercial', '', 1300__+MAX_llx_menu__, '/expedition/liste.php?leftmenu=sendings', 'List', 1, 'sendings', '$user->rights->expedition->lire', '', 2, 1, __ENTITY__);
insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->expedition->enabled && $leftmenu=="sendings"', __HANDLER__, 'left', 1303__+MAX_llx_menu__, 'commercial', '', 1300__+MAX_llx_menu__, '/expedition/stats/index.php?leftmenu=sendings', 'Statistics', 1, 'sendings', '$user->rights->expedition->lire', '', 2, 2, __ENTITY__);
-- Commercial - Proposals -- Commercial - Proposals
insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->propal->enabled', __HANDLER__, 'left', 1100__+MAX_llx_menu__, 'commercial', '', 5__+MAX_llx_menu__, '/comm/propal/index.php?leftmenu=propals', 'Prop', 0, 'propal', '$user->rights->propale->lire', '', 2, 4, __ENTITY__); insert into llx_menu (enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('$conf->propal->enabled', __HANDLER__, 'left', 1100__+MAX_llx_menu__, 'commercial', '', 5__+MAX_llx_menu__, '/comm/propal/index.php?leftmenu=propals', 'Prop', 0, 'propal', '$user->rights->propale->lire', '', 2, 4, __ENTITY__);

View File

@ -20,7 +20,7 @@
/** /**
* \file htdocs/includes/menus/standard/eldy.lib.php * \file htdocs/includes/menus/standard/eldy.lib.php
* \brief Library for file eldy menus * \brief Library for file eldy menus
* \version $Id: eldy.lib.php,v 1.64 2011/08/10 23:48:25 eldy Exp $ * \version $Id: eldy.lib.php,v 1.65 2011/08/21 11:00:50 eldy Exp $
*/ */
@ -1117,6 +1117,7 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after)
{ {
$langs->load("sendings"); $langs->load("sendings");
$newmenu->add("/expedition/index.php?leftmenu=sendings", $langs->trans("Shipments"), 0, $user->rights->expedition->lire); $newmenu->add("/expedition/index.php?leftmenu=sendings", $langs->trans("Shipments"), 0, $user->rights->expedition->lire);
if ($leftmenu=="sendings") $newmenu->add("/expedition/fiche.php?action=create2&leftmenu=sendings", $langs->trans("NewSending"), 1 ,$user->rights->expedition->creer);
if ($leftmenu=="sendings") $newmenu->add("/expedition/liste.php?leftmenu=sendings", $langs->trans("List"), 1 ,$user->rights->expedition->lire); if ($leftmenu=="sendings") $newmenu->add("/expedition/liste.php?leftmenu=sendings", $langs->trans("List"), 1 ,$user->rights->expedition->lire);
if ($leftmenu=="sendings") $newmenu->add("/expedition/stats/index.php?leftmenu=sendings", $langs->trans("Statistics"), 1 ,$user->rights->expedition->lire); if ($leftmenu=="sendings") $newmenu->add("/expedition/stats/index.php?leftmenu=sendings", $langs->trans("Statistics"), 1 ,$user->rights->expedition->lire);
} }

View File

@ -54,6 +54,7 @@ SendShippingByEMail=Send shipping by EMail
SendShippingRef=Send shipping %s SendShippingRef=Send shipping %s
ActionsOnShipping=Acions on shipping ActionsOnShipping=Acions on shipping
LinkToTrackYourPackage=Link to track your package LinkToTrackYourPackage=Link to track your package
ShipmentCreationIsDoneFromOrder=For the moment, creation of a new shipment is done from the order card.
# Sending methods # Sending methods
SendingMethodCATCH=Catch by customer SendingMethodCATCH=Catch by customer

View File

@ -54,6 +54,7 @@ SendShippingByEMail=Envoi bon d'expédition par EMail
SendShippingRef=Envoi bon d'expédition %s SendShippingRef=Envoi bon d'expédition %s
ActionsOnShipping=Événements sur l'expédition ActionsOnShipping=Événements sur l'expédition
LinkToTrackYourPackage=Lien pour suivi de votre colis LinkToTrackYourPackage=Lien pour suivi de votre colis
ShipmentCreationIsDoneFromOrder=Pour le moment, la création d'une nouvelle expédition se fait depuis la fiche commande.
# Sending methods # Sending methods
SendingMethodCATCH=Enlèvement par le client SendingMethodCATCH=Enlèvement par le client