<?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 Re: Directions dijit and ArcServer 10.7 in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/directions-dijit-and-arcserver-10-7/m-p/739482#M68451</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you find a work around? I have exact same issue now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did find a solution.&lt;/P&gt;&lt;P&gt;By default the create Network Dataset widget in ArcMAP suggests that the traveltime parameter is called Minutes. This works in the directions widget using our route service shared on our old 10.4.0 portal but not with the same route service shared on our new 10.7.1 portal. The traveltime parameter must be renamed&amp;nbsp;from Minutes to TravelTime, then it works.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 05 Nov 2019 12:16:52 GMT</pubDate>
    <dc:creator>MortenHjelmsmark1</dc:creator>
    <dc:date>2019-11-05T12:16:52Z</dc:date>
    <item>
      <title>Directions dijit and ArcServer 10.7</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/directions-dijit-and-arcserver-10-7/m-p/739481#M68450</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm using JS 3.28 and&amp;nbsp;the Directions dijit and a custom route service.&amp;nbsp; All is well with 10.6.1 (and earlier!), but the same service fails when published to 10.7.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It is failing in Directions.js at &lt;SPAN&gt;_getCostAttribute()&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;_getCostAttribute: function(a) {&lt;BR /&gt; for (var b = this.serviceDescription &amp;amp;&amp;amp; this.serviceDescription.networkDataset.networkAttributes || [], c, d = 0; d &amp;lt; b.length; d++)&lt;BR /&gt; if (b&lt;D&gt;.name === a &amp;amp;&amp;amp; "esriNAUTCost" === b&lt;D&gt;.usageType) {&lt;BR /&gt; c = b&lt;D&gt;;&lt;BR /&gt; break&lt;BR /&gt; }&lt;BR /&gt; return c&lt;BR /&gt;},&lt;/D&gt;&lt;/D&gt;&lt;/D&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;b is a collection of networkattributes ('OneWay, Length, Time') and 'a' is the&amp;nbsp;impedanceAttributeName.&amp;nbsp; The impedance on the published service is "Time", but in the code 'a' is always "TravelTime", so in the loop above 'c=b&lt;D&gt;' is never hit and this function always returns null.&lt;/D&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This are also other places in Directions.js with lines like, which seems odd:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;|| this.serviceDescription &amp;amp;&amp;amp; &lt;STRONG&gt;10.6&lt;/STRONG&gt; &amp;lt;= this.serviceDescription.currentVersion;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Anyway, the route stops are plotted, but the route is never returned because it always fails with the error:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TypeError: Cannot read property 'units' of undefined&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is this broken for 10.7? or do I need to do something different?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Jun 2019 19:24:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/directions-dijit-and-arcserver-10-7/m-p/739481#M68450</guid>
      <dc:creator>EricO_Neal1</dc:creator>
      <dc:date>2019-06-10T19:24:21Z</dc:date>
    </item>
    <item>
      <title>Re: Directions dijit and ArcServer 10.7</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/directions-dijit-and-arcserver-10-7/m-p/739482#M68451</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you find a work around? I have exact same issue now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did find a solution.&lt;/P&gt;&lt;P&gt;By default the create Network Dataset widget in ArcMAP suggests that the traveltime parameter is called Minutes. This works in the directions widget using our route service shared on our old 10.4.0 portal but not with the same route service shared on our new 10.7.1 portal. The traveltime parameter must be renamed&amp;nbsp;from Minutes to TravelTime, then it works.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Nov 2019 12:16:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/directions-dijit-and-arcserver-10-7/m-p/739482#M68451</guid>
      <dc:creator>MortenHjelmsmark1</dc:creator>
      <dc:date>2019-11-05T12:16:52Z</dc:date>
    </item>
  </channel>
</rss>

