[ic] Admin New Entry Problem
peter at pajamian.dhs.org
Tue Dec 12 02:00:00 EST 2006
On 12/11/2006 09:15 PM, Cameron B. Prince wrote:
> I'm having a problem with the Admin's New Entry function. This is using a
> default standard catalog on IC v5.4.1 with MySQL. When you edit a table that
> uses the autonumber counter files as a key, such as products, you can
> duplicate the problem by clicking New Entry. Leave the pre-filled key intact
> and click Ok to create the new entry. You will see that you are returned to
> the flex_editor but instead of it having the next key pre-filled, all the
> fields are empty.
> You can click New Entry again to create another item, but you will find that
> the counter has been incremented twice. I updated the meta for the New Entry
> menu item and added a ui_return_to=admin/flex_select to cause the Ok to take
> you back to the edit page rather than having the empty flex_editor but was
> surprised to find the counter was still incremented twice after creating a
> new entry.
I've seen this exact issue and never had the time to look into it. If I
get the time I'll be happy to look into it, or if someone either (1)
finds the problem themselves and gives me an idea where to look so I
don't have to spend all day and a half tracking it down or (2) pays me
to do it then I'll be likely to commit a fix for it in the near future,
otherwise may not happen for a while (I'm pretty swamped with other
things that take priority). That's speaking for me, someone else may
FWIW this problem goes back at least as far as 5.2.0 and is not specific
to MySQL (I get the same problem with PostgreSQL). It's not specific to
standard, either, I see it in Foundation-based sites.
> 1) Is there a logical reason that I'm not realizing for incrementing the
> counter twice? If not, how can this be prevented?
Probably not, it's just a minor bug.
> 2) I understand this will not be ideal in every case, but I'd like the New
> Entry function to return to the flex_editor to edit the item I just created.
> Can you tell me if this is possible?
That sounds like a good idea. It should be possible.
More information about the interchange-users