jQWidgets Forums
Forum Replies Created
-
Author
-
May 11, 2013 at 3:23 pm in reply to: jqxTree Load on Demand with Ajax: re-open issue jqxTree Load on Demand with Ajax: re-open issue #20978
I don’t understand this. First is OK and second is with error.
tree.jqxTree('addTo', { label: 'Item', value: 'value' }, $element[0]); //OKtree.jqxTree('addTo', { label: 'Item', value: 'value', items: [{label: "Nalagam...", value: "nalagam"}]}, $element[0]); //error
May 11, 2013 at 1:46 pm in reply to: jqxTree Load on Demand with Ajax: re-open issue jqxTree Load on Demand with Ajax: re-open issue #20977Why is this not OK?
var items = new Array();items.push({label: 'l', value: 'v', items: [{label: "Nalagam...", value: "nalagam"}]})tree.jqxTree('addTo', items, $element[0]);
I am loading all kind of staff on demand. So I want to create items manually. I don’t see any difference between my code and the example code. My code is based on: load on demand example.
May 10, 2013 at 2:58 pm in reply to: jqxTree Load on Demand with Ajax: re-open issue jqxTree Load on Demand with Ajax: re-open issue #20956I get error: Uncaught TypeError: Cannot set property ‘level’ of undefined.
Details:Uncaught TypeError: Cannot set property ‘level’ of undefined jqx-all.js:7
a.extend._refreshMapping jqx-all.js:7
e jqx-all.js:7
a.extend.addTo jqx-all.js:7
a.jqx.invoke jqx-all.js:7
a.jqx.jqxWidgetProxy jqx-all.js:7
(anonymous function) jqx-all.js:7
b.extend.each jquery-1.9.1.min.js:3
b.fn.b.each jquery-1.9.1.min.js:3
a.fn.(anonymous function) jqx-all.js:7
(anonymous function) test.php:39
b.event.dispatch jquery-1.9.1.min.js:3
v.handle jquery-1.9.1.min.js:3
b.event.trigger jquery-1.9.1.min.js:3
(anonymous function) jquery-1.9.1.min.js:4
b.extend.each jquery-1.9.1.min.js:3
b.fn.b.each jquery-1.9.1.min.js:3
b.fn.extend.trigger jquery-1.9.1.min.js:4
a.extend._raiseEvent jqx-all.js:7
(anonymous function) jqx-all.js:7
r.complete jquery-1.9.1.min.js:5
c jquery-1.9.1.min.js:3
p.fireWith jquery-1.9.1.min.js:3
u jquery-1.9.1.min.js:5
b.fx.tick jquery-1.9.1.min.js:5Source code:
<!DOCTYPE html><html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title></title> <script src="Framework/Scripts/jquery-1.9.1.min.js"></script> <script src="Framework/Scripts/jqwidgets/jqx-all.js"></script> <link rel="stylesheet" href="Framework/Styles/jqx.base.css" type="text/css" /> <script type="text/javascript"> $(document).ready(function () { // Create jqxTree var tree = $('#jqxTree'); var source = [{ label: "Root", expanded: true, items: [ { label: "Root Folder 1", items: [{ value: "ajax1.htm", label: 'Loading...'}] }, { label: "Root Folder 2", items: [{ value: "ajax2.htm", label: 'Loading...'}] } ] }]; tree.jqxTree({ source: source, width: 200 }); tree.bind('expand', function (event) { var label = tree.jqxTree('getItem', event.args.element).label; var $element = $(event.args.element); var loader = false; var loaderItem = null; var children = $element.find('ul:first').children(); $.each(children, function () { var item = tree.jqxTree('getItem', this); if (item && item.label == 'Loading...') { loaderItem = item; loader = true; return false }; }); if (loader) { var items = new Array(); items.push({label: 'l', value: 'v', items: [{label: "Nalagam...", value: "nalagam"}]}) tree.jqxTree('addTo', items, $element[0]); tree.jqxTree('removeItem', loaderItem.element); } }); }); </script></head><body class='default'> <div id="jqxTree"> </div></body></html>
May 10, 2013 at 2:36 pm in reply to: Use addTo method to add items with children Use addTo method to add items with children #20955Has these feature been implemented.
I get:Uncaught TypeError: Cannot set property ‘level’ of undefined jqx-all.js:7
a.extend._refreshMapping jqx-all.js:7
a.extend.addTo.e jqx-all.js:7
a.extend.addTo jqx-all.js:7
a.jqx.invoke jqx-all.js:7
a.jqx.jqxWidgetProxy jqx-all.js:7
a.jqx.jqxWidget.a.fn.(anonymous function) jqx-all.js:7
b.extend.each jquery-1.9.1.min.js:3
b.fn.b.each jquery-1.9.1.min.js:3
a.jqx.jqxWidget.a.fn.(anonymous function) jqx-all.js:7when trying this:
ColumnsTreePluses.jqxTree(‘addTo’, {label: ‘Hi’, value: ‘v1’, items: [{label: “Loading…”, “test_value”]}, element[0]);I am sorry. My mistake. It does clear all sources.
Works as expected.Apparently Destroy removes any childs html from DOM, but not the Window itself. Is this correct?
To do that I need to manually remove<div id="window1">
from body, or there is another way?
April 2, 2013 at 6:54 pm in reply to: Renderstatusbar not fired (knockout) Renderstatusbar not fired (knockout) #18464Understand. I also try to manually reference function on document load:
<!DOCTYPE html><html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Pametna hiša</title> <script src="Framework/Scripts/jquery-1.9.1.min.js"></script> <script src="Framework/Scripts/date.format.js"></script> <script src="Framework/Scripts/knockout-2.2.1.js"></script> <script src="Framework/Scripts/FormModel.js"></script> <script src="Framework/Scripts/jqwidgets/jqx-all.js"></script> <script type="text/javascript" src="Framework/Scripts/jqwidgets/jquery.global.js"></script> <link rel="stylesheet" href="Framework/Styles/jqx.base.css" type="text/css" /> <link rel="stylesheet" href="Framework/Styles/jqx.ui-sunny.css" type="text/css" /> <script type="text/javascript"> $(document).ready(function () { var initialData = [ { name: "Well-Travelled Kitten", sales: 352, price: 75.95 }, { name: "Speedy Coyote", sales: 89, price: 190.00 }, { name: "Furious Lizard", sales: 152, price: 25.00 }, { name: "Indifferent Monkey", sales: 1, price: 99.95 }, { name: "Brooding Dragon", sales: 0, price: 6350 }, { name: "Ingenious Tadpole", sales: 39450, price: 0.35 }, { name: "Optimistic Snail", sales: 420, price: 1.50 } ]; var GridModel = function (items) { this.items = ko.observableArray(items); }; ko.applyBindings(new GridModel(initialData)); $('#jqxGrid').jqxGrid({ renderstatusbar: function(statusbar) { var container = $('<div ></div>'); var addButton = $('<div ><span >Add</span></div>'); container.append(addButton); statusbar.append(container); }}); });</script></head><body class='default'><div id='jqxWidget'> <div id="jqxGrid" data-bind="jqxGrid: { source: items, autoheight: true, showstatusbar: true, columns: [ { text: 'Name', dataField: 'name', width: 200 }, { text: 'Sales', dataField: 'sales', width: 200, cellsalign: 'right' }, { text: 'Price', dataField: 'price', width: 200, cellsformat: 'c2', cellsalign: 'right' } ]}"> </div> </div></body></html>
but it is not working either.
I know this. My question is can I manually do it? Set cell selection but set background colour of selected row to something.
March 26, 2013 at 7:20 am in reply to: Resizing cursor is over scroll Resizing cursor is over scroll #18014No, I don’t want to disable it. The problem is that I can not scroll without also resizing.
Link to screen shot.March 26, 2013 at 7:10 am in reply to: columntype: 'number' sets field to AutoIncrement columntype: 'number' sets field to AutoIncrement #18011Understand. Maybe it would be a good think to add in documentation ” in the column starting from 1.”
Thank you.March 26, 2013 at 7:08 am in reply to: Input value in window not change with knockout Input value in window not change with knockout #18010I almost think that this solved my problem. But it didn’t. Anyway, thanks for that.
Just copy the code and try entering something inside textbox and then click button. If everything is OK, remove text from textbox and click the button again. Repeat the steps. Eventually the input text will not matched the allerted text.
Understand. What if I prohibit (if this is possible) to enter own data. Will then be cleared?
I only now discovered that anything can be typed in. The user must enter something from listbox (listbox shows data from table and I need ID).Edited: I think I found solution: DropDownList.
Thanks.
March 17, 2013 at 6:54 pm in reply to: Bug on render – setting check in code Bug on render – setting check in code #17236Yes, but it should.
March 17, 2013 at 6:53 pm in reply to: Bug getselectedrowindex after source changed Bug getselectedrowindex after source changed #17235I know. I am saying that it should.
-
AuthorPosts