<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to create a custom Attribute Inspector for mobile app using the ESRI JS API in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-create-a-custom-attribute-inspector-for/m-p/384581#M35585</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am making a mobile version of a JS web application I developed. I'm noticing though that the AttributeInspector widget by default uses standard dojo/form controls. This means that the form within the widget does not work correctly on a mobile browser.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there a way to change the AttributeInspector so that it uses the dojox/mobile controls? Right now, I am simply providing the LayerInfos object to constructor without specifying the FieldInfos object. I'd like to avoid that if I can because I'd like the app to be able to use different layers with different fields.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is how I create the AttributeInspector:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;var layerInfos = this.layers.map(function(layer) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; return {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureLayer : layer.layerObject,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; showAttachments : true,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; isEditable : layer.layerObject.isEditable()
&amp;nbsp;&amp;nbsp;&amp;nbsp; };
});

this.attInspector = new AttributeInspector({
&amp;nbsp;&amp;nbsp;&amp;nbsp; layerInfos : layerInfos
}, this.inspectorDiv);
this.attInspector.startup();&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is what it looks like on my Android phone:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]23255[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As you can see, the fields get cut off. Also, the dropdown lists do not appear as they should on a mobile device.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there anyway to do this without writing a lot of code to account for different field types and domains?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 05 Apr 2013 17:06:35 GMT</pubDate>
    <dc:creator>BrianBeck</dc:creator>
    <dc:date>2013-04-05T17:06:35Z</dc:date>
    <item>
      <title>How to create a custom Attribute Inspector for mobile app using the ESRI JS API</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-create-a-custom-attribute-inspector-for/m-p/384581#M35585</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am making a mobile version of a JS web application I developed. I'm noticing though that the AttributeInspector widget by default uses standard dojo/form controls. This means that the form within the widget does not work correctly on a mobile browser.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there a way to change the AttributeInspector so that it uses the dojox/mobile controls? Right now, I am simply providing the LayerInfos object to constructor without specifying the FieldInfos object. I'd like to avoid that if I can because I'd like the app to be able to use different layers with different fields.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is how I create the AttributeInspector:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;var layerInfos = this.layers.map(function(layer) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; return {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; featureLayer : layer.layerObject,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; showAttachments : true,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; isEditable : layer.layerObject.isEditable()
&amp;nbsp;&amp;nbsp;&amp;nbsp; };
});

this.attInspector = new AttributeInspector({
&amp;nbsp;&amp;nbsp;&amp;nbsp; layerInfos : layerInfos
}, this.inspectorDiv);
this.attInspector.startup();&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is what it looks like on my Android phone:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]23255[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As you can see, the fields get cut off. Also, the dropdown lists do not appear as they should on a mobile device.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there anyway to do this without writing a lot of code to account for different field types and domains?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Apr 2013 17:06:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/how-to-create-a-custom-attribute-inspector-for/m-p/384581#M35585</guid>
      <dc:creator>BrianBeck</dc:creator>
      <dc:date>2013-04-05T17:06:35Z</dc:date>
    </item>
  </channel>
</rss>

