esskay
Member
I am trying to setup a form and list with "add limit". I am using Form limit plugin. User is allowed to add only one record to the list unless limit is increased by admin. I have created an element where admins can manually increase the limit. I am running sql query to add the record first time which is INSERT INTO `my_table`(`add_limit`, `created_by`) VALUES ('1', '{$my->id}'). This query adds the record but immediately after clicking "add" user gets the limit reached message. User has to than edit the record. This is confusing.
What I need is as under -
1. Set the default limit to 1 so that the user of a particular group can add record without any warning
2. User cannot add another record unless limit is increased by the admin
In my above setup, if I do not run sql query user cannot add the record at all since the pre filtered table is empty and there is no lookup and max element to watch.
Can someone guide me to the right direction in this situation ?
What I need is as under -
1. Set the default limit to 1 so that the user of a particular group can add record without any warning
2. User cannot add another record unless limit is increased by the admin
In my above setup, if I do not run sql query user cannot add the record at all since the pre filtered table is empty and there is no lookup and max element to watch.
Can someone guide me to the right direction in this situation ?