mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
default to create on card.php if $action is empty
This commit is contained in:
parent
6386432263
commit
e0b664066b
|
|
@ -220,7 +220,7 @@ llxheader('', $title, $help_url);
|
|||
|
||||
|
||||
// Create mode
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans('NewAccountingAccount'));
|
||||
|
||||
print '<form name="add" action="'.$_SERVER["PHP_SELF"].'" method="POST">'."\n";
|
||||
|
|
|
|||
|
|
@ -154,7 +154,7 @@ $help_url = "EN:Module_Double_Entry_Accounting";
|
|||
|
||||
llxHeader('', $title, $help_url);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewFiscalYear"));
|
||||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
|
|
|
|||
|
|
@ -340,7 +340,7 @@ if ($action == 'delete') {
|
|||
print $formconfirm;
|
||||
}
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("CreateMvts"));
|
||||
|
||||
$object = new BookKeeping($db);
|
||||
|
|
|
|||
|
|
@ -920,7 +920,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
|||
// -----------------------------------------
|
||||
|
||||
// Create mode
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$object->canvas = $canvas;
|
||||
$object->state_id = GETPOST('state_id', 'int');
|
||||
|
||||
|
|
|
|||
|
|
@ -253,7 +253,7 @@ $help_url = "EN:Module_EMail_Collector|FR:Module_Collecteur_de_courrier_électro
|
|||
llxHeader('', 'EmailCollector', $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewEmailCollector", $langs->transnoentitiesnoconv("EmailCollector")));
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -166,7 +166,7 @@ $help_url = '';
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("Asset")), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -138,7 +138,7 @@ $help_url = '';
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("AssetModel")), '', 'object_' . $object->picto);
|
||||
|
||||
print '<form method="POST" action="' . $_SERVER["PHP_SELF"] . '">';
|
||||
|
|
|
|||
|
|
@ -268,7 +268,7 @@ $help_url ='EN:Module_BOM';
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewBOM"), '', 'bom');
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -144,7 +144,7 @@ $h++;
|
|||
$hselected = 'card';
|
||||
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
/*
|
||||
* Fact bookmark creation mode
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -923,7 +923,7 @@ $arrayrecurrulefreq = array(
|
|||
$help_url = 'EN:Module_Agenda_En|FR:Module_Agenda|ES:M&omodulodulo_Agenda';
|
||||
llxHeader('', $langs->trans("Agenda"), $help_url);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$contact = new Contact($db);
|
||||
|
||||
$socpeopleassigned = GETPOST("socpeopleassigned", 'array');
|
||||
|
|
|
|||
|
|
@ -704,7 +704,7 @@ llxHeader(
|
|||
array()
|
||||
);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
// EMailing in creation mode
|
||||
print '<form name="new_mailing" action="'.$_SERVER['PHP_SELF'].'" method="POST">'."\n";
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
|
|
|
|||
|
|
@ -1533,7 +1533,7 @@ llxHeader('', $title, $help_url);
|
|||
$now = dol_now();
|
||||
|
||||
// Add new proposal
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$currency_code = $conf->currency;
|
||||
|
||||
print load_fiche_titre($langs->trans("NewProp"), '', 'propal');
|
||||
|
|
|
|||
|
|
@ -341,7 +341,7 @@ llxHeader("", $title, $help_url);
|
|||
|
||||
// Creation
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$object = new Account($db);
|
||||
|
||||
print load_fiche_titre($langs->trans("NewFinancialAccount"), '', 'bank_account');
|
||||
|
|
|
|||
|
|
@ -335,7 +335,7 @@ foreach ($bankcateg->fetchAll() as $bankcategory) {
|
|||
}
|
||||
|
||||
// Create mode
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
// Update fields properties in realtime
|
||||
if (!empty($conf->use_javascript_ajax)) {
|
||||
print "\n".'<script type="text/javascript">';
|
||||
|
|
|
|||
|
|
@ -194,7 +194,7 @@ $form = new Form($db);
|
|||
/*
|
||||
* Action create
|
||||
*/
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
//WYSIWYG Editor
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||
|
||||
|
|
|
|||
|
|
@ -2888,7 +2888,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
// Mode creation
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$facturestatic = new Facture($db);
|
||||
$extrafields->fetch_name_optionals_label($facturestatic->table_element);
|
||||
|
||||
|
|
|
|||
|
|
@ -145,7 +145,7 @@ $title = $langs->trans("LT".$object->ltt)." - ".$langs->trans("Card");
|
|||
$help_url = '';
|
||||
llxHeader('', $title, $helpurl);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->transcountry($lttype == 2 ? "newLT2Payment" : "newLT1Payment", $mysoc->country_code));
|
||||
|
||||
print '<form name="add" action="'.$_SERVER["PHP_SELF"].'" name="formlocaltax" method="post">'."\n";
|
||||
|
|
|
|||
|
|
@ -343,7 +343,7 @@ llxHeader("", $title, $help_url);
|
|||
|
||||
|
||||
// Form to create a social contribution
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewSocialContribution"));
|
||||
|
||||
print '<form name="charge" method="post" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -398,7 +398,7 @@ if ($id) {
|
|||
}
|
||||
|
||||
// Form to enter VAT
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("VAT").' - '.$langs->trans("New"));
|
||||
|
||||
if (!empty($conf->use_javascript_ajax)) {
|
||||
|
|
|
|||
|
|
@ -627,7 +627,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
|||
}
|
||||
|
||||
if ($user->rights->societe->contact->creer) {
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
/*
|
||||
* Fiche en mode creation
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -1017,7 +1017,7 @@ if ($result > 0) {
|
|||
}
|
||||
|
||||
// Create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans('AddContract'), '', 'contract');
|
||||
|
||||
$soc = new Societe($db);
|
||||
|
|
|
|||
|
|
@ -258,7 +258,7 @@ llxHeader('', $langs->trans("CronTask"));
|
|||
|
||||
$head = cron_prepare_head($object);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("CronTask"), '', 'title_setup');
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -259,7 +259,7 @@ llxHeader('', $title, 'Livraison');
|
|||
$form = new Form($db);
|
||||
$formfile = new FormFile($db);
|
||||
|
||||
if ($action == 'create') { // Create. Seems to no be used
|
||||
if ($action == 'create' || (empty($action) && empty($id))) { // Create. Seems to no be used
|
||||
} else // View
|
||||
{
|
||||
if ($object->id > 0) {
|
||||
|
|
|
|||
|
|
@ -386,7 +386,7 @@ if (!empty($conf->project->enabled)) {
|
|||
$formproject = new FormProjets($db);
|
||||
}
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("AddDonation"), '', 'object_donation');
|
||||
|
||||
print '<form name="add" action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
|
|
|
|||
|
|
@ -206,7 +206,7 @@ llxHeader('', $langs->trans("ECMNewSection"));
|
|||
$form = new Form($db);
|
||||
$formecm = new FormEcm($db);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
//***********************
|
||||
// Create
|
||||
//***********************
|
||||
|
|
|
|||
|
|
@ -166,7 +166,7 @@ $title = $langs->trans("ConferenceOrBooth");
|
|||
$help_url = '';
|
||||
llxHeader('', $title, $help_url);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$result = $projectstatic->fetch(GETPOST('fk_project'));
|
||||
} else {
|
||||
$result = $projectstatic->fetch($object->fk_project);
|
||||
|
|
@ -392,7 +392,7 @@ if (!empty($withproject)) {
|
|||
}
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("ConferenceOrBooth")), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -420,7 +420,7 @@ if (!empty($withproject)) {
|
|||
}
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("ConferenceOrBoothAttendee")), '', 'object_'.$object->picto);
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -831,7 +831,7 @@ if ($action == 'create2') {
|
|||
}
|
||||
|
||||
// Mode creation.
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$expe = new Expedition($db);
|
||||
|
||||
print load_fiche_titre($langs->trans("CreateShipment"), '', 'dolly');
|
||||
|
|
|
|||
|
|
@ -1389,7 +1389,7 @@ $ecmfilesstatic = new EcmFiles($db);
|
|||
$formexpensereport = new FormExpenseReport($db);
|
||||
|
||||
// Create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewTrip"), '', 'trip');
|
||||
|
||||
print '<form action="'.$_SERVER['PHP_SELF'].'" method="post" name="create">';
|
||||
|
|
|
|||
|
|
@ -796,7 +796,7 @@ $help_url = 'EN:Module_Interventions';
|
|||
|
||||
llxHeader('', $langs->trans("Intervention"), $help_url);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
// Create new intervention
|
||||
|
||||
$soc = new Societe($db);
|
||||
|
|
|
|||
|
|
@ -1544,7 +1544,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
$now = dol_now();
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans('NewOrderSupplier'), '', 'supplier_order');
|
||||
|
||||
dol_htmloutput_events();
|
||||
|
|
|
|||
|
|
@ -1899,7 +1899,7 @@ $help_url = 'EN:Module_Suppliers_Invoices|FR:Module_Fournisseurs_Factures|ES:Mó
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Mode creation
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$facturestatic = new FactureFournisseur($db);
|
||||
|
||||
print load_fiche_titre($langs->trans('NewBill'), '', 'supplier_invoice');
|
||||
|
|
|
|||
|
|
@ -159,7 +159,7 @@ $formcompany = new FormCompany($db);
|
|||
/*
|
||||
* Action create
|
||||
*/
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewEstablishment"));
|
||||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
|
|
|
|||
|
|
@ -255,7 +255,7 @@ print '<script type="text/javascript" language="javascript">
|
|||
</script>';
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewEval"), '', 'object_' . $object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -180,7 +180,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentities('Job')), '', 'object_' . $object->picto);
|
||||
|
||||
print '<form method="POST" action="' . $_SERVER["PHP_SELF"] . '">';
|
||||
|
|
|
|||
|
|
@ -187,7 +187,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewSkill"), '', 'object_' . $object->picto);
|
||||
|
||||
print '<form method="POST" action="' . $_SERVER["PHP_SELF"] . '">';
|
||||
|
|
|
|||
|
|
@ -156,7 +156,7 @@ if ($action == 'add' && $permissiontoadd) {
|
|||
*/
|
||||
|
||||
// Creation mode
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$title = $langs->trans("IntracommReportTitle");
|
||||
llxHeader("", $title);
|
||||
print load_fiche_titre($langs->trans("IntracommReportTitle"));
|
||||
|
|
|
|||
|
|
@ -169,7 +169,7 @@ $help_url = '';
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewKnowledgeRecord"), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -254,7 +254,7 @@ llxHeader("", $title, $help_url);
|
|||
|
||||
|
||||
// Create mode
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
//WYSIWYG Editor
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
if (empty($permissiontoadd)) {
|
||||
accessforbidden($langs->trans('NotEnoughPermissions'), 0, 1);
|
||||
exit;
|
||||
|
|
|
|||
|
|
@ -241,7 +241,7 @@ llxHeader('', $title, '');
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
if (GETPOST('fk_bom', 'int') > 0) {
|
||||
$titlelist = $langs->trans("ToConsume");
|
||||
if ($objectbom->bomtype == 1) {
|
||||
|
|
|
|||
|
|
@ -259,7 +259,7 @@ $help_url = '';
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewPartnership"), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -181,7 +181,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewInventory"), '', 'product');
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -285,7 +285,7 @@ $help_url = 'EN:Module_Stocks_En|FR:Module_Stock|ES:Módulo_Stocks';
|
|||
llxHeader("", $langs->trans("WarehouseCard"), $help_url);
|
||||
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewWarehouse"), '', 'stock');
|
||||
|
||||
dol_set_focus('input[name="libelle"]');
|
||||
|
|
|
|||
|
|
@ -378,7 +378,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("Batch"), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -413,7 +413,7 @@ print '});
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("StockTransfer")), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -728,7 +728,7 @@ if ($action == 'create2') {
|
|||
}
|
||||
|
||||
// Mode creation.
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$recept = new Reception($db);
|
||||
|
||||
print load_fiche_titre($langs->trans("CreateReception"));
|
||||
|
|
|
|||
|
|
@ -283,7 +283,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("RecruitmentCandidature")), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -202,7 +202,7 @@ $help_url = '';
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewPositionToBeFilled"), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -197,7 +197,7 @@ $form = new Form($db);
|
|||
$formresource = new FormResource($db);
|
||||
|
||||
if ($action == 'create' || $object->fetch($id, $ref) > 0) {
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($title, '', 'object_resource');
|
||||
print dol_get_fiche_head('');
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -457,7 +457,7 @@ if ($id > 0) {
|
|||
}
|
||||
|
||||
// Create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$year_current = strftime("%Y", dol_now());
|
||||
$pastmonth = strftime("%m", dol_now()) - 1;
|
||||
$pastmonthyear = $year_current;
|
||||
|
|
|
|||
|
|
@ -979,7 +979,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
|||
// -----------------------------------------
|
||||
// When used in standard mode
|
||||
// -----------------------------------------
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
/*
|
||||
* Creation
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -1138,7 +1138,7 @@ if (!empty($conf->project->enabled)) {
|
|||
$now = dol_now();
|
||||
|
||||
// Add new askprice
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
$currency_code = $conf->currency;
|
||||
|
||||
print load_fiche_titre($langs->trans("NewAskPrice"), '', 'supplier_proposal');
|
||||
|
|
|
|||
|
|
@ -254,7 +254,7 @@ $fuserstatic = new User($db);
|
|||
$form = new Form($db);
|
||||
$formfile = new FormFile($db);
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewGroup"), '', 'object_group');
|
||||
|
||||
dol_set_focus('#nom');
|
||||
|
|
|
|||
|
|
@ -272,7 +272,7 @@ if ($result > 0) {
|
|||
print '</tr>';
|
||||
|
||||
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
// $listofemails=$object->thirdparty_and_contact_email_array();
|
||||
if ($object->email) {
|
||||
$actions = array();
|
||||
|
|
|
|||
|
|
@ -158,7 +158,7 @@ $help_url = 'EN:Module_Products#Variants';
|
|||
llxHeader('', $title, $help_url);
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("ProductAttribute")), '', 'object_' . $object->picto);
|
||||
|
||||
print '<form method="POST" action="' . $_SERVER["PHP_SELF"] . '">';
|
||||
|
|
|
|||
|
|
@ -240,7 +240,7 @@ llxHeader('', $title, $help_url);
|
|||
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
if (empty($permissiontoadd)) {
|
||||
accessforbidden($langs->trans('NotEnoughPermissions'), 0, 1);
|
||||
exit;
|
||||
|
|
|
|||
|
|
@ -118,7 +118,7 @@ $formfile = new FormFile($db);
|
|||
llxHeader('', 'WebsiteAccount', '');
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("WebsiteAccount")));
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
|
|
@ -186,7 +186,7 @@ llxHeader('', $title, $help_url);
|
|||
<?php
|
||||
|
||||
// Part to create
|
||||
if ($action == 'create') {
|
||||
if ($action == 'create' || (empty($action) && empty($id))) {
|
||||
print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("Workstation")), '', 'object_'.$object->picto);
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user