[TYPO3-irre] IRRE + dbal without pid :)

Oliver Hader oh at inpublica.de
Thu May 3 08:14:43 CEST 2007


Hi Nikolas,

Nikolas Hagelstein wrote:
> I am currently integrating a 3rd party table which doesnt onws a PID
> field.
> I was able to prepend a pid by using dbal mapping but obviously it
> doesnt work common with 
> IRRE (to be honest a very special situation but may be intressting
> anyway).
> 
> "Create new record" results in an access denied error due to fact that
> "parseStructureString()" recieves :
> 
> "data[][tx_myext_cost_centres][8][fe_groups][tx_myext_cost_centres_fe_gr
> oups]" 
> (not the missing PID within the first brackets.) 

I'm wondering if it is possible to create new records for the table
without the pid field e.g. via list module. TCEmain tries to check
access to the page by pid - currently I don't know how this will work
without a proper pid. But possibly there's a way and I have to dig
deeper in DBAL.

> This obviously screws up the whole thing since e.g.
> $this->inlineFirstPid becomes something like:
> "][tx_myext_cost_centres" etc.

The identifiert "data[...][<table>][<uid>][<field>]..." is split for
AJAX calls. Currently IRRE expects to have something set as pid and
fails if this is empty. I think this could be fixed with no bigger efforts.

> I do not expect any help since as i mentioned above this is a very
> special "environment" i just wondered if there is a way to "preset" the
> PID instead of inheritating it from  the parent record. Furhter more i
> am conviced that the current pid should be avaible "somewhere" else
> within the "environment" so it is probably worth thinking about
> something like a fallback mechanismn (e.g. withing
> getSingleField_typeInline). (Which should actually already exist for
> inline records of "new parent records").

$this->inlineFirstPid is set to the pid of the first parent record (the
one you select in the list module to edit).

> If all else fails i could set a "fake PID" via
> "processDatamap_preProcessFieldArray" but i thought it would  a good
> idea to ask you guys first :)

Thus you would set the pid to a fixed value - but if the involved
records (parent, children, etc.) don't have pids at all, how should the
system automatically determine this value?

You can send me your extension via PM. Maybe it would also possible to
change the DBAL to use MySQL only, because I don't have PostgreSQL or
any other DBMS installed. Thanks in advance!


olly
-- 
Oliver Hader
http://inpublica.de/


More information about the TYPO3-project-irre mailing list