dojo

Dojo Uploader with Drag and Drop

倾然丶 夕夏残阳落幕 提交于 2019-12-11 10:36:20
问题 I am trying to recreate this example in my project, to add the drag and drop feature to the dojo uploader: http://archive.dojotoolkit.org/nightly/dojotoolkit/dojox/form/tests/test_Uploader.html Copying the exact same code in jsfiddle or in my application the line if(uploader.addDropTarget && uploader.uploadType=='html5'){ returns undefined for addDropTarget and iframe for the uploadType. I tried it with various browsers, and even added force: html5 in the uploader but nothing changed. Please,

Dojo nested requires on IE7 and IE8 causes Invalid Argument Exception

怎甘沉沦 提交于 2019-12-11 10:28:41
问题 Here is the simplest example I could come up with. I keep getting an Invalid Argument exception being thrown on the second require call in IE7 and IE8. This works fine in IE9+, Chrome and Firefox. Very frustrating. Debugging this through IE developer tools has not been helpful. <script type="text/javascript"> require(["dojo/request/xhr", "dojo/domReady"], function(xhr){ xhr("Servlet?arg=1") .then(function(data) { try { test() } catch(e) { cpb.consoleLog(e.number); cpb.consoleLog(e.description

Dijit combobox not rendering in custom widget

房东的猫 提交于 2019-12-11 10:17:49
问题 I am trying to use the combobox provided by Dijit inside of a custom-made widget. I have been using Dojo's tutorial on comboboxes to guide me. When I implement a stand-alone webpage similar to their tutorial examples, everything worked fine; but when I ported the code into my custom-made widget, it just renders the combobox as a plain HTML text box. Here's what my custom widget's template looks like: <div class='customWidget'> ... <div dojoAttachPoint="mainDiv" class="mainDiv"> <div dojoType=

Dojo using deferred functions to get data in ajax callback function

流过昼夜 提交于 2019-12-11 09:48:40
问题 I have a function with a return however in the function there is an async request which holds the value that is suppose to be returned by the function. I understand with the nature of async request the function will complete and not return a value while waiting on the async function to complete. I attempted to use dojo deferred functions to have my function PostInformation() to return a value within the ajax request callback. I am having some issues and i am not sure where my issue is. Under

Dijit Menu (bar) with link

懵懂的女人 提交于 2019-12-11 09:48:32
问题 I am using Dijit Menu bar with declartive markup. The Menu items contains links ('a'): <li dojoType="dijit.MenuItem" id="i_car_new"> <a href="/RooTest/cars?form">Create new Car</a> </li> The menu is rendered correct, and even the link is display as link, but when one click on this link in the menu, noting happens. ( My actual workaround is to add an 'onClick' event with an 'window.location'. ) But I would expect that the links work like normal (user click, browswer request new page). So is my

Making dijit.Dialog Transparent when it shows up

末鹿安然 提交于 2019-12-11 09:34:44
问题 I have a Dojo Dialog box using dijit.Dialog library. It shows up on a Rowclick event of a Dojo grid . Now when it shows up I want it to be Transparent or reduce its opacity so that Whatever was in my background i can see it and it will look good. My Dialog box is a simple <div> with data-dojo-type="dijit.Dialog" . The code is :: <div id="terms" name ="hi" data-dojo-type="dijit.Dialog" style="height:580px;width:900px;" data-dojo-props="title:'Control Activities'" preload="true"> <center><p>

Problems with adding/removing ContentPanes in AccordionContainer

做~自己de王妃 提交于 2019-12-11 09:29:04
问题 I'm a complete newbie at Dojo, and Adobe AIR, which is my target. I'm trying to put some panes into an AccordionContainer like so: var mainview = dijit.byId("mainview"); var rand = randomString(); var widg = gtd_create_entry_widget(rand) air.trace(mainview); air.trace(widg); mainview.addChild(widg); "mainview" is my AccordionContainer, and gtd_create_entry_widget() is: function gtd_create_entry_widget(id) { var entry = new dijit.layout.ContentPane(); entry.attr("id",id); entry.attr("title",

Cannot read property 'value' of undefined" on dojo/request/iframe post

混江龙づ霸主 提交于 2019-12-11 09:28:41
问题 I have an image upload function that uploads form with image like this: iframe(url, { form: dom.byId("myform"), handleAs: "json", timeout: 5000, method: "POST" }).then(function () { console.log("Success"); }, function (Err) { console.log(Err); }); On server side I get the image, but on client side I get TypeError: Cannot read property 'value' of undefined↵ at I [as handleResponse] (http://ajax.googleapis.com/ajax/libs/dojo/1.9.2/dojo/request/iframe.js:9:114)↵ at r (http://ajax.googleapis.com

Multipart form data ajax request in dojo

回眸只為那壹抹淺笑 提交于 2019-12-11 09:06:47
问题 I googled a lot but could not find a way to do ajax post request for Multipart formdata enctype form .Can anybody help 回答1: Check out Example 1 in the dojo.xhr documentation: http://dojotoolkit.org/reference-guide/1.8/dojo/xhr.html A tweaked/shortened version: <form data-dojo-type="dijit/form/Form" id="myForm" data-dojo-id="myForm" encType="multipart/form-data" action="" method=""> <input data-dojo-type="dijit/form/ValidationTextBox" type="text" id="name" name="name" /> <div data-dojo-type=

updating/refreshing dojo datagrid with new store value on combobox value changes

[亡魂溺海] 提交于 2019-12-11 08:58:37
问题 I have a combo box and a datagrid in my page. when the user changes the combo box value i have to update the grid with children details of newly selected parent. How can I achieve this using Dojo combo box and datagrid. the following code snippet not working for me. when I use setStore method on the grid with new json data. <div dojoType="dojo.data.ItemFileReadStore" jsId="store" url="/child/index/"></div> // grid store <div dojoType="dojo.data.ItemFileReadStore" jsId="parentStore" url="