POST
|
I've got the same problem. I've tried to add the FeatureTable to different dom nodes or layout widgets and I still get this problem. Now my workaround is to delete the "_trailingPaneNode" of this widget. var myFeatureTable = new FeatureTable({
featureLayer : featureLayer,
map : this.map,
syncSelection : true,
outFields: ["*"]
}).placeAt(this.domNode);
myFeatureTable._trailingPaneNode.destroy(); Somehow there is a problem with some style or something in this node. After I delete this node I can interact with the widget.
... View more
05-11-2017
05:55 AM
|
0
|
0
|
556
|
POST
|
Perhaps you find further informations in this link for real singletons (entry by "JonS"). We use it in our applications. http://stackoverflow.com/questions/4334437/dojo-singleton-or-at-least-static-method-variable Your second sample code can look like this. // returns Object
define([
'esri/core/Accessor',
'./Singleton',
'dojo/Evented'
], function (
Accessor,
Evented
) {
var Model = Singleton(Accessor.createSubclass([Evented], {
// stuff
}));
return Model.getInstance(); // or just return the singleton
});
... View more
03-20-2017
02:40 AM
|
1
|
1
|
572
|
POST
|
Unfortunately there are still no drawing tools (module "DrawToolbar") with 4.3.
... View more
03-07-2017
01:27 AM
|
0
|
0
|
1042
|
POST
|
Thanks again for your reply. The main problem is, that we just startet an implementation of a web app with about 40 or 50 widgets with 4.0 beta. At this beginning we used "esri/widgets/Widget"! But this base class had such big changes with 4.2 that we can't use it at this moment. Till 4.1 we could handle the new changes somehow. The migration will cost too much time. I think for this reason the module "esri/widgets/Widgette" was introduced for migration issues. I see that there is no option to merge these two base widget modules. So we have to migrate. odoe it would be nice that "esri/widgets/Widgette" can be kept in the next one or two releases. That will give us the time to migrate all widgets. Is it possible? Thanks in advance.
... View more
02-28-2017
12:50 AM
|
0
|
0
|
498
|
POST
|
As I heard on Developer Summit in Berlin last year, it will be available in 4.3. Can't wait for it, too. Perhaps we will see next month before the Developer Summit in Palm Springs would start.
... View more
02-28-2017
12:19 AM
|
1
|
1
|
1042
|
POST
|
Thank you for your reply. I tried your last option of creating the ContentPane, add it to StackContainer and use the automatically created domNode of ContentPane as the 'container' property. Unfortunately the result is just like the same as before. I get a string representation of a widget (currently inherited from "esri/widgets/Widgette") which are inside my custom widget. Am I missing something? Here is my code snippet. This is a module that handles adding and removing to and from the StackContainer. // some code before...
// 1. Create the Helper-ContentPane.
var content = new ContentPane();
// 2. Add it to StackContainer and select it (this.navigationStack is type StackContainer).
this.navigationStack.addChild(content);
this.navigationStack.selectChild(content);
// 3. Just check id and domNode property.
console.info("content.id", content.id);
console.info("content.domNode", content.domNode);
// 4. Set container property as domNode of ContentPane.
component.container = content.domNode;
// ...some code after The result is this. I debugged the widget handling and saw that this is the result of some core inheritance from dijit/_WidgetBase (toString function) which is used in esri/widgets/libs/maquette/maquette.js if there is no property 'vnodeSelector' while appending children in this custom widget. Here is the snippet of this part. let toTextVNode = (data: any): VNode => {
return {
vnodeSelector: '',
properties: undefined,
children: undefined,
text: data.toString(),
domNode: null
};
};
let appendChildren = function(parentSelector: string, insertions: any[], main: VNode[]) {
for (let i = 0, length = insertions.length; i < length; i++) {
let item = insertions[i];
if (Array.isArray(item)) {
appendChildren(parentSelector, item, main);
} else {
if (item !== null && item !== undefined) {
if (!item.hasOwnProperty('vnodeSelector')) {
item = toTextVNode(item);
}
main.push(item);
}
}
}
}; So we use a custom main Widget with "esri/widgets/Widget" which contains one or more widgets inherited from "esri/widgets/Widgette". I know, the mixture of Widget and Widgette is not a nice solution but for some issues till now we have to use this base module and want to migrate later to esri/widgets/Widget. Are there any other solutions or hints?
... View more
02-23-2017
01:09 AM
|
0
|
2
|
498
|
POST
|
Hey at all, hi Rene Rubalcava I need some help again at implementing custom widgets with TypeScript and base class "esri/widgets/Widget". I think I understand that working with TypeScript, JSX and Maquette. It seems to be that there is one important thing you have to keep in mind for developing. You have to hold a none virtual dom in your web app to render the virtual dom of your widget into it. Is that right? In a couple of days I tried to render a widget based on "esri/widgets/Widget" into a "dijit/layout/StackContainer". The main problem is, that there is no "domNode". I tried several things to prepare the domNode. Call the render() function Nothing happened. domNode ist still undefined Create a "dijit/layout/ContentPane", add it to StackContainer and than call widget._projector.merge(contentPane.domNode, widget.domNode); A string with some widget ids which contains the widget appears in the StackContainer Create a "dijit/layout/ContentPane", add it to StackContainer, assign widget.container=contentPane.id and than call widget.render(); A string with some widget ids which contains the widget appears in the StackContainer Wait for rendering with "dojo/aspect" function after. domNode ist still undefined Watching for changes of domNode and/or container Callback function doesn't call Is there a way to solve this problem? How can I render a widget without an existing container? There have to be a solution but I haven't any idea. Can you help me out please? Any help is appreciated! Thanks! Regards Martin
... View more
02-22-2017
08:37 AM
|
0
|
4
|
1060
|
POST
|
Ah, ok I see. Every time I call 'this.scheduleRender()' in my custom widget, the 'render' function executes. So I have to manage some attributes, variables and/or globals so that there will be a different result in the render function. Is that right? Does anybody have some further hints and tips?
... View more
02-15-2017
07:59 AM
|
0
|
0
|
399
|
POST
|
Hi at all! We write some custom widgets with the ArcGIS API 4.2 for JavaScript. Now we want to change the ui after an identify task gives us the result. Therefore I saw the 'scheduleRender' function. Unfortunately now well documented yet. So I look into the TypeScript widgets 'LayerList' and 'Print' to check how does it work. The render function returns an JSX Element but the functions called from 'scheduleRender' does not. So my questions is, how do I have to use this function? Is it just the attributes changing that triggers a new rendering ending in 'render' function? I appreciate any help. Thank you! Regards Martin
... View more
02-15-2017
07:45 AM
|
1
|
1
|
1066
|
POST
|
Great thank you! I will check your samples but I think I can take advantage of it. We are now to deep in this thing. So we will use it like you do ;). Our plan is (and I startet that meanwhile) to use ViewModels written in JavaScript and use them in widgets written in TypeScript. Can I contact you for some more questions or should I open new separate threads?
... View more
02-09-2017
09:01 AM
|
0
|
0
|
785
|
POST
|
odoe Ok, now here is my reply. Unfortunately there is no comfortable way to develop our widgets without TypeScript. So we have to start nearly from scratch. Doh! So I have two questions. 1. Do you have a nice documentaion where I can find some hints to start with Widget development including Accessors/ViewModels from scratch? I'm really new to that stuff and I need to develop some widgets really soon. I read the documentation from the Esri site here, here and here. I need some more information please. 2. How many main changes will be happen in the future releases of the API? For every update we need several of days and weeks to get our application runnable again. Thanks in advance. Regards Martin
... View more
02-09-2017
08:03 AM
|
0
|
2
|
785
|
POST
|
Hey Rene, thanks for your reply. I hoped, that you will be the one who answer my question! We have built our application since 4.0 was released. So we implement our widgets straight forward without TypeScript in the recommended way of ViewModels to the best of our knowledge and belief. I will check your hint/link if we can take some advantages for our widget development and will give a reply here.
... View more
02-07-2017
08:20 AM
|
0
|
3
|
785
|
POST
|
Hello again, could anybody share it with an Esri staff? I appreciate any help! This is really important for us and planning with the ArcGIS API 4.2 for JavaScript. Regards Martin
... View more
02-06-2017
05:08 AM
|
0
|
0
|
785
|
POST
|
Hello Community, perhaps an Esri staff could help me out. We develop a web application with the ArcGIS API 4.2 for JavaScript. There were many changes after the beta phase of 4.0 to the official release. We handled this issue with a couple of days development. After that there were a couple of changes in the update from 4.0 to 4.1. We handled that issue to. Now we updated to Version 4.2 and ran into some new problems. We have many custom widgets wich are created with the base class "esri/widgets/Widget" (function "createSubclass") in the typical "amd-define-style". With the use of "esri/widgets/Widget" and the new possibilty of writing custom widgets with TypeScript, it seems to be a problem. After we change all the custom modules and use the base class "esri/widgets/Widgette", no error occured and our application works fine again. So my important question is, is this base class "esri/widgets/Widgette" save for updates and can we use it in future? A questions beside. Is there a main plan to support only custom widgets developed with TypeScript? No "amd-define-style" anymore? Regards Martin
... View more
01-31-2017
01:35 AM
|
2
|
6
|
2689
|
POST
|
Indirectly, this is a Bug in the JSAPI as AJ Morris said. The problem is, that since ArcGIS for Server 10.2(.2) there is no spatial reference in the returning geometry of identify result. In ArcGIS for Server 10.1 the spatial reference still exists in identify result. So perhaps the JSAPI takes a default spatial reference for returning geometry which is 4326 (WGS84) and not the requested one. So I thing there is a bug in ArcGIS for Server 10.2. But the solution described above works for me too and is a good workaround. So thanks !
... View more
09-24-2014
01:56 AM
|
1
|
0
|
185
|
Title | Kudos | Posted |
---|---|---|
1 | 02-28-2017 12:19 AM | |
1 | 03-20-2017 02:40 AM | |
9 | 04-27-2012 07:01 AM | |
9 | 04-27-2012 07:01 AM | |
1 | 02-15-2017 07:45 AM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:24 AM
|