Closed (outdated)
Project:
Editable Fields
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
13 Sep 2012 at 09:44 UTC
Updated:
3 Aug 2017 at 17:50 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
kristen polYeah, I find it a bit odd that the other non-checkbox fields all do an auto-update (e.g. add text and go out of the field and the text gets updated via ajax). Hope this gets in ;) Wish I had time to look at it.
Comment #2
Zorga Lina commentedWell, a general issue w/Ajax and checkbox event handling is posted here: http://drupal.org/node/556438#comment-form
But that isn't just w/in EditableFields. I am using checkboxes in a View, selecting the Editable formatter which then adds a 'Save' button. I would like a checkbox where checkchanged event would trigger a save of the field value/node. I don't want to 'hide' the Save button, I would like to dispense w/it.
Comment #3
Zorga Lina commentedI was trying to use the #ajax 'trigger_as' to no avail; in the end, I simply modified the jQuery (editablefields.js) to include the input type 'checkbox', where the submit button will be hidden, and the checkbox 'click' triggers submit.
HTH someone else! I feel that this is a good approach as stylistically, that is how js/jQuery is meant to be used within Drupal.
Comment #4
reevo commentedHave found myself applying the same fix for this issue a few times, attaching a patch
Comment #5
guschilds commentedAttached is a patch similar to #4 that only deals with checkboxes. #4 checks for more than 1 radio button and improperly assumes that means there is only one editable field.
Comment #6
apotek commentedReview:
From a style perspective, aren't we supposed to put spaces in JS function calls between params, ie:
Not this:
+ $this.find('input[type=text],input[type=checkbox],textarea,select').change(function() {but this:
+ $this.find('input[type=text], input[type=checkbox], textarea, select').change(function() {Testing:
This patch has been working nicely for us in production for well over a year. If the above style comment is a non-blocker I don't see any reason to not move this into the 7.x mainline of this project.
Comment #7
apotek commentedForgot to change status.
Comment #8
joelpittetLooks like this has been committed or is much different.