[TYPO3-core] RFC #11684: Add support for flash messages in the backend
Ingo Renner
ingo at typo3.org
Sun Aug 23 22:12:40 CEST 2009
Rupert Germann wrote:
Hi Rupi,
>> The flash messages are supposed to generalize and unify all these
>> messages in one consistent look and feel. A RFC doing this will follow
>> after this one's in.
>
> great
great you agree :)
>>> 1. tcemain printLogErrorMessages()
>>> which collects its messages in the syslog table
>>
>> How do I trigger this one?
>
> a search through the core (doesn't your IDE have this feature, too? ;) )
> shows that this function exists twice: in t3lib_tcemain and in
> t3lib_extfilefunc.
> it's called in alt_doc.php, db_list.php, file_list.php and tce_db.php
of course I read the code and understood what it does, but that's not
what my question was. What I meant is: How can I make this one appear
and where?
>>> 2. t3lib_BEfunc::isRecordLocked()
>>> which displays the "locked" icons and the beautyful yellow warning box
>>> on top of editforms.
>>>
>>> 3. t3lib_BEfunc::displayWarningMessages()
>>> used in alt_intro
>>
>> Especially these two are supposed to be replaced by flash messages.
>
> the latter one is not possible currently, because alt_intro doesn't use
> template.php
Ah, so let me proof you wrong ;)
See the attached patch, it replaces the old and ugly warning boxes with
flash messages, even for case 3. - don't forget about the render()
method of the flash messages ;)
The attached patch also fixes the unnecessary UPDATE queries. That would
the be part of the commit. The rest would be a separate RFC (actually
replacing the warning boxes with flash messages).
>>> at least in the current implementation both frames will display the same
>>> messages, which doesn't make much sense.
>>
>> So, could you explain what you did to make the messages show up in
>> both frames?
>
> I read the code ;-)
> and the code says that the same function is called with the same input
> in 2 different frames. That makes me sure that both frames will show the
> same message-content. No need to test.
Due to the short living nature of the messages and the way they work
it's ensentially not possible to make the same messages (== same
objects) show up in both frames at the same time. I tried hard
refreshing both frames at the same time, but failed due to being not
able to be faster than MySQL.
Please show me a working scenario where messages show up in both frames,
to me it's (technically) not possible. Now it's your turn to proof me
wrong. ;)
>> It could make sense though to display messages that are directly
>> related to the tree only. I can't think of a scenario for that though.
>
> even if there would be a scenario it would not work to get different
> output per frame because currently all messages are stored in the same
> be_session field.
As Francois already pointed out already that might be solved with
"typing" of messages. As agreed with him I'd put that in a separate RFC,
too as it would require more complex testing.
all the best
Ingo
--
Ingo Renner
TYPO3 Core Developer, Release Manager TYPO3 4.2
More information about the TYPO3-team-core
mailing list