- /**
- * @brief
- * @param plugin_uuid
- * @param header
- * @param field
- * @param selected_str
- * @param disabled_str
- */
- this.checkbox = function(plugin_uuid, header, field, selected_str, disabled_str) {
- /* Prefix id with plugin_uuid */
- return "<input class='hazelnut-checkbox-" + plugin_uuid + "' id='hazelnut-checkbox-" + plugin_uuid + "-" + get_value(header) + "' name='" + get_value(field) + "' type='checkbox' " + selected_str + disabled_str + "autocomplete='off' value='" + get_value(header) + "'></input>";
- }
+ this.update_plugin = function(e, rows) {
+ if (debug) console.log("entering update_plugin");
+ // e.data is what we passed in second argument to subscribe
+ // so here it is the jquery object attached to the plugin <div>
+ var $plugindiv=e.data;
+ console.log("incoming plugindiv= " + $plugindiv);
+ // clear the spinning wheel: look up an ancestor that has the need-spin class
+ // do this before we might return
+ $plugindiv.closest('.need-spin').spin(false);
+
+ var options = this.options;
+ var hazelnut = this;