I need to get the last id that was added or modified in beforeSave function() in one model. I try this:
$this->model->id; and $this->data['model']['short'] but it do not work.
this is correct in cakephp or there is another way to get the id in a model?
I am using this function in the model to store the saved id’s of the model:
Then simply get the saved id by using
$this->ModelName->inserted_ids;