Project

General

Profile

Actions

Bug #16674

closed

tcemain: Hook processDatamap_afterDatabaseOperations and insert operations

Added by Ingo Schmitt about 18 years ago. Updated over 17 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2006-10-29
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.0
PHP Version:
4
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

When using the hook processDatamap_afterDatabaseOperations to execute your own code after the databse operation, not the new insert_id ist given to the hook, but the temporarily ID NEW......
Sinve insertDB already returns the new insert _id, the new ID should be stored in $id, to have it availiabe in the hook.

(issue imported from #M4446)


Files

patch_t3lib_tcemain.php.txt (758 Bytes) patch_t3lib_tcemain.php.txt Administrator Admin, 2006-10-29 18:16
Actions #1

Updated by Jens Mittag almost 18 years ago

I would really like to see this problem solved in the next minor/major release. An extension of mine (jm_gallery) makes use of this "feature" to provide a better usability to the user...

Actions #2

Updated by Michael Stucki almost 18 years ago

Ingmar, can I close this bug? Seems like you and Ingo found a different solution, didn't you?

Actions #3

Updated by Ingo Schmitt almost 18 years ago

Could be closed, since Ingmar wanted to update teh documentation:

See bugs newsgroup:

You can easily translate from the NEW... id to the real id by using the
$tce->substNEWwithIDs array.

Actions #4

Updated by Ingo Schmitt almost 18 years ago

Could be closed, since Ingmar wanted to update teh documentation:

See bugs newsgroup:

You can easily translate from the NEW... id to the real id by using the
$tce->substNEWwithIDs array.

Actions #5

Updated by Ingmar Schlecht almost 18 years ago

Fixed by NOT changing the behavior but adding this comment to the code:

/* * Note: When using the hook after INSERT operations, you will only get the temporary NEW... id passed to your hook as $id, * but you can easily translate it to the real uid of the inserted record using the $this->substNEWwithIDs array.
*/

Actions

Also available in: Atom PDF