Forums

[SOLVED] Custom list checkbox to delete record

skittle 28 May, 2013
Hi

I am new to ChronoConnectivity and ChronoForms. I have looked at the Tutorials and read the forums but can't find an answer to my question. I have successfully added a checkbox column to a Custom Listing that I have created. I used the {checkbox} option in each line of my HTML table. The Custom Listing also has the toolbar showing at the top of the page. When I click a checkbox that is beside a record and then click Remove (on the toolbar), the system tells me to "Please select a record". I guess the checkbox variable needs to grab the cf_id of the appropriate record before any deletion can take place. How can I get the remove button to see the record ID that the checkbox is flagging (or get the checkbox to get the correct record ID)?

Thanks in advance.

John
skittle 29 May, 2013
Problem solved. I should probably struggle with these challenges longer before posting a question!
faros 14 Jun, 2013
Hi skittle
I have the some problem in the admin list, please can you post me the solution?
Thanks in advance
Fabrizio
skittle 14 Jun, 2013
Hi Fabrizio,

I ended up not using the checkbox column. Instead, I used the _DELETE_ function. If you add _DELETE_:Delete as the last column in the Admin List Settings/General tab/List View Fields a link (that says Delete) for each record will appear in a column called Delete. Simply clicking on the word Delete will delete the associated record.

If you are using the Frontend Settings/Custom Listing Settings then just add a column to your HTML table that includes the function _DELETE_ like this - <td>{_DELETE_}</td>.

You can then remove the _DELETE_:Delete option from your Admin Settings/Toolbar Setting or just turn off the toolbar.

You can also use _EDIT_ to retrieve the appropriate Chronoform with the current record. Today, I just learned about _SAVE_LIST_. If you have enabled frontend editing (General/Data Listing Fields) you can use _SAVE_LIST_ to save edits from the frontend listing without ever loading the Chronform.

I hope this makes sense and gets you started.

John
faros 18 Jun, 2013
Thanks a lot john i followed your solution and now it works well.
Fabrizio
trykar 26 Aug, 2013
Hello,
i nedd help. I#s searching for hours but couldn't find a solution.
i have my own styled table - and "show toolbar" - "No" in the settings.

in my custom listing settings i have a header, body and footer.

i want a delete, edit button or. link per line ...
i read you solved it with

<td>_DELETE_</td>

but when i add this row in my body ... i only see _DELETE_ - no link for some action.

i think i have forgot something to render <td>_DELETE_</td>

maybe some one can help me .... for me ist also ok not to work with tags or some link/url ...
skittle 26 Aug, 2013
Hi,

Try

<td>{_DELETE_}</td>


John
trykar 26 Aug, 2013
Hi, thank you for your quick answer, but it doesn't realy render.

When i write <td>{_DELETE_}</td> in my body so in the front end there ist now "nothing" ...
it feels like the correct syntax but it doesn't show maybe there is a permission to set ??

i logged in in the frontend with superadmin, and the date was submit also by super admin ... i can't see a link for delete.

but toolbar witch checkbox work normal ...

i use joomla 2.5 (german) and the cc 4.0 RC3.2

i read something abaout the Linkable Field(s) ... should i put some information/sytax here ?

thanks for every help
skittle 26 Aug, 2013
From the Frontend Listings tab, select the General tab. Add _DELETE_ to your list of List View Fields.
trykar 26 Aug, 2013
Thank you skittle ... now it works ...
This information was missing๐Ÿ™‚
applebox 06 Nov, 2013
These seem like great instructions.
I am trying to delete a single record. The "Remove" button with using the checkbox doesn't work. I found this solution and implemented the "_DELETE_" code. The link appears and when I click on the link, it just removes it from the page. But it doesn't delete the record. I can go back to the listings and it's still there. Am I missing something? Like putting in some code into the "Delete Data Task Control" section?

I would really love to be able to select multiple checkboxes and then click the "Remove" button to accomplish this.
applebox 13 Nov, 2013
No reply in a while. Gonna make a new post for my question.
skittle 22 Dec, 2013
I know this is not a timely response but maybe it's better late than never.

Have you tried checking the Front-end Permissions of the Chronoconnection? The simplest reason for this would be a permissions issue. If the permissions are set properly the delete record checkbox should work fine.

John
applebox 14 Jan, 2014
Things are still not good. I was told that upgrading to v5 should take care of this issue. However, this is not an upgrade. I was reading about being able to backup and restore to v5 but I don't see the instructions for that. I have over a month poured into developing this section of the site and it's looking like I have to start all over again if I go the v5 route. I'm thinking that's not going to work. I don't have the time to do this without pay and I certainly can't ask the client to pay for my time to do the upgrade. And, there is still no guarantee that this will work. There has to be a way to get the Delete function to work on v4. It's not a permission issue because I checked the permissions and they are set properly. It has to be something with the Delete Data Task Control area of the Frontend Editing. It seems to me that there is probably just some missing code that belongs in the Admin section to allow this to happen. Am I to assume that nobody else is trying to delete a record from the front end or that nobody else has any issues with doing so? Getting a little frustrated at this. My client needs to get busy populating this database and needs this function to work. Trying to delete a record from the Joomla side is not an option as all you get back there is "Record1", "Record2" and so on. They can't even match things up 1-1 with the name or ID of the record. You don't know what the record is until you click on the link. Not very user-friendly.

Does anyone have any other suggestions? BTW, someone marked this one as [SOLVED]. Not sure why - this is far from solved.
applebox 14 Jan, 2014
Answer
1 Likes
The problem is officially solved.
It was in the ToolBar Tasks. I posted the following code: _DELETE_:Remove:1:cf_id:ID (where the cf_id was the entry to delete). Tested it and it worked perfectly!! Now we can mark this as [SOLVED]๐Ÿ™‚
This topic is locked and no more replies can be posted.