Page 1 of 1

You are not permitted to use that link to directly access that page

Posted: Thu Feb 21, 2019 10:12 am
by radhoine
I have this save method in the "operation" controller.

Code: Select all

$model->save($data);// i call the model operation and save data
 $lastIdOperation = $model->getLastInsertedId();
// here I create a new item in the same model  but in another table  and i get the last inserted id        $model->creeNouvelleTransactionDeboureLieeAOperation($lastIdOperation);

        $idTransaction = $model->getLastInsertedIdTransactionDeboure();

// and here is set the redirect to another controller (view)
        $app = JFactory::getApplication();
        $url = JRoute::_('index.php?option=com_tktransit&view=transaction_deboure&layout=edit&is_from_operation=1&id='.(int)$idTransaction, false);
        $app->redirect($url);
    }
In the "transaction_deboure" View when I try to edit the new item that I create and click on SAVE and CLOSE I got this error

You are not permitted to use that link to directly access that page {the id of the item that I edit}