Skip to content

Commit 4a8e3fb

Browse files
committed
3.17 code
1 parent 881fb25 commit 4a8e3fb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+2673
-2595
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ The template can be configured using the following options:
4040
3. Change the sharing host, found in defaults.js inside the config folder for the application, to the sharing URL for ArcGIS Online or Portal. For ArcGIS Online users, keep the default value of www.arcgis.com or specify the name of your organization.
4141
- ArcGIS Online Example: `"sharinghost": location.protocol + "//" + “<your organization name>.maps.arcgis.com`
4242
- Portal Example where `arcgis` is the name of the Web Adaptor: `"sharinghost": location.protocol + "//" + "webadaptor.domain.com/arcgis"`
43-
4. If you are using Portal or a local install of the ArcGIS API for JavaScript, change all references to the ArcGIS API for JavaScript in index.html to refer to your local copy of the API. Search for the references containing `"//js.arcgis.com/3.16"` and replace this portion of the reference with the url to your local install.
43+
4. If you are using Portal or a local install of the ArcGIS API for JavaScript, change all references to the ArcGIS API for JavaScript in index.html to refer to your local copy of the API. Search for the references containing `"//js.arcgis.com/3.17"` and replace this portion of the reference with the url to your local install.
4444
- For example: `"//webadaptor.domain.com/arcgis/jsapi/jsapi"` where `arcgis` is the name of your Web Adaptor.
4545
5. Copy a map or group ID from Portal/ArcGIS Online and replace the default web map ID in the application’s index.html page. You can now run the application on your web server or customize the application further.
4646

index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
<meta property="og:site_name" content="esri" />
2525
<!-- End Facebook -->
2626
<!--Use protocol relative urls that way if the browser is viewing the page via HTTPS the js/css file will be requested using the HTTPS protocol-->
27-
<link rel="stylesheet" type="text/css" href="//js.arcgis.com/3.16/esri/css/esri.css" />
27+
<link rel="stylesheet" type="text/css" href="//js.arcgis.com/3.17/esri/css/esri.css" />
2828
<link rel="stylesheet" type="text/css" href="//fonts.googleapis.com/css?family=Lato:300,400,700" />
2929
<!--Load any application specific styles-->
3030
<link rel="stylesheet" type="text/css" href="css/dijit.css" />
@@ -115,7 +115,7 @@
115115
dojoConfig.locale = RegExp.$1;
116116
}
117117
</script>
118-
<script type="text/javascript" src="//js.arcgis.com/3.16"></script>
118+
<script type="text/javascript" src="//js.arcgis.com/3.17"></script>
119119
<script type="text/javascript">
120120
require([
121121
"config/templateConfig",

js/SearchSources.js

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ define(["dojo/_base/declare", "dojo/_base/lang", "dojo/_base/array", "dojo/_base
1212
//When true we restrict world locator to the map extent
1313
geocoders: [],
1414
esriSource: null,
15+
enableSearchingAll: true,
1516
//Geocoders defined in helper services
1617
itemData: null,
1718
//web map item info includes operational layers and info about searches configured on web map
@@ -27,6 +28,7 @@ define(["dojo/_base/declare", "dojo/_base/lang", "dojo/_base/array", "dojo/_base
2728
return {
2829
map: this.map,
2930
sources: this._createSources(),
31+
enableSearchingAll: this.enableSearchingAll,
3032
activeSourceIndex: this._getActiveSource()
3133
};
3234
},
@@ -55,15 +57,20 @@ define(["dojo/_base/declare", "dojo/_base/lang", "dojo/_base/array", "dojo/_base
5557

5658
_getActiveSource: function () {
5759
var activeIndex = 0;
58-
if (this.sources && this.sources.length > 1) {
59-
activeIndex = "all";
60+
if (this.hasOwnProperty("activeSourceIndex")) {
61+
activeIndex = this.activeSourceIndex;
6062
}
61-
array.some(this.sources, function (s, index) {
62-
if (!s.hasEsri && s.featureLayer) {
63-
activeIndex = index;
64-
return true;
63+
else{
64+
if (this.sources && this.enableSearchingAll && this.sources.length > 1) {
65+
activeIndex = "all";
6566
}
66-
});
67+
array.some(this.sources, function (s, index) {
68+
if (!s.hasEsri && s.featureLayer) {
69+
activeIndex = index;
70+
return true;
71+
}
72+
});
73+
}
6774
return activeIndex;
6875
},
6976
_createHelperServiceSources: function () {

js/main.js

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
define([
22
"dojo/_base/declare",
3+
"dojo/_base/kernel",
34
"dojo/_base/lang",
45
"esri/arcgis/utils",
56
"dojo/json",
@@ -29,6 +30,7 @@ define([
2930
],
3031
function (
3132
declare,
33+
kernel,
3234
lang,
3335
arcgisUtils,
3436
JSON,
@@ -88,6 +90,9 @@ define([
8890
this._showDrawerSize = 850;
8991
},
9092
startup: function (config) {
93+
94+
document.documentElement.lang = kernel.locale;
95+
9196
// config will contain application and user defined info for the template such as i18n strings, the web map id
9297
// and application id
9398
// any url parameters and any application specific configuration information.
@@ -161,6 +166,11 @@ define([
161166
layers: tocLayers
162167
}, tocNode);
163168
toc.startup();
169+
if(this._mapLegend) {
170+
on(toc, "toggle", lang.hitch(this, function () {
171+
this._mapLegend.refresh();
172+
}));
173+
}
164174
}
165175
// if we have social layers
166176
if (this.socialLayers && this.socialLayers.length) {
@@ -186,6 +196,11 @@ define([
186196
layers: socialTocLayers
187197
}, socialTocNode);
188198
socialToc.startup();
199+
if(this._mapLegend) {
200+
on(socialToc, "toggle", lang.hitch(this, function () {
201+
this._mapLegend.refresh();
202+
}));
203+
}
189204
this._socialToc = socialToc;
190205
}
191206
}
@@ -548,6 +563,8 @@ define([
548563
itemData: this.config.itemInfo.itemData
549564
};
550565
if (this.config.searchConfig) {
566+
searchOptions.enableSearchingAll = this.config.searchConfig.enableSearchingAll;
567+
searchOptions.activeSourceIndex = this.config.searchConfig.activeSourceIndex;
551568
searchOptions.applicationConfiguredSources = this.config.searchConfig.sources || [];
552569
} else {
553570
var configuredSearchLayers = (this.config.searchLayers instanceof Array) ? this.config.searchLayers : JSON.parse(this.config.searchLayers);

js/nls/ShareDialog.js

Lines changed: 28 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -15,33 +15,35 @@ define({
1515
}
1616
}
1717
}),
18-
"ar": 1,
19-
"cs": 1,
20-
"da": 1,
21-
"de": 1,
18+
"ar": 1,
19+
"cs": 1,
20+
"da": 1,
21+
"de": 1,
2222
"el": 1,
23-
"es": 1,
24-
"et": 1,
25-
"fi": 1,
26-
"fr": 1,
27-
"he": 1,
28-
"it": 1,
29-
"ja": 1,
30-
"ko": 1,
31-
"lt": 1,
32-
"lv": 1,
33-
"nl": 1,
34-
"nb": 1,
23+
"es": 1,
24+
"et": 1,
25+
"fi": 1,
26+
"fr": 1,
27+
"he": 1,
28+
"hr": 1,
29+
"it": 1,
30+
"ja": 1,
31+
"ko": 1,
32+
"lt": 1,
33+
"lv": 1,
34+
"nl": 1,
35+
"nb": 1,
3536
"pl": 1,
36-
"pt-br": 1,
37-
"pt-pt": 1,
38-
"ro": 1,
39-
"ru": 1,
40-
"sv": 1,
41-
"th": 1,
42-
"tr": 1,
43-
"vi": 1,
44-
"zh-cn": 1,
45-
"zh-hk": 1,
37+
"pt-br": 1,
38+
"pt-pt": 1,
39+
"ro": 1,
40+
"ru": 1,
41+
"sr": 1,
42+
"sv": 1,
43+
"th": 1,
44+
"tr": 1,
45+
"vi": 1,
46+
"zh-cn": 1,
47+
"zh-hk": 1,
4648
"zh-tw": 1
4749
});

js/nls/ar/ShareDialog.js

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
1-
define(
2-
({
3-
"widgets": {
4-
"ShareDialog": {
5-
"title": "مشاركة",
6-
"heading": "مشاركة هذه الخريطة",
7-
"url": "رابط الخريطة",
8-
"embed": "تضمين الخريطة",
9-
"extent": "مشاركة نطاق الخريطة الحالي",
10-
"size": "الحجم (الاتساع/الارتفاع):",
11-
"facebookTooltip": "Facebook",
12-
"twitterTooltip": "Twitter",
13-
"gplusTooltip": "Google Plus",
14-
"emailTooltip": "البريد الإلكتروني"
15-
}
16-
}
17-
})
18-
);
1+
define({
2+
"widgets": {
3+
"ShareDialog": {
4+
"title": "مشاركة",
5+
"heading": "مشاركة هذه الخريطة",
6+
"url": "رابط الخريطة",
7+
"embed": "تضمين الخريطة",
8+
"extent": "مشاركة نطاق الخريطة الحالي",
9+
"size": "الحجم (الاتساع/الارتفاع):",
10+
"facebookTooltip": "Facebook",
11+
"twitterTooltip": "Twitter",
12+
"gplusTooltip": "Google Plus",
13+
"emailTooltip": "البريد الإلكتروني"
14+
}
15+
}
16+
});

js/nls/ar/resources.js

Lines changed: 67 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -1,69 +1,67 @@
1-
define(
2-
({
3-
map: {
4-
error: "يتعذر إنشاء الخريطة",
5-
views: "مناطق عرض."
6-
},
7-
report: {
8-
flag: "العلامة غَيْرُ مُوَافِقة",
9-
error: "خطأ",
10-
success: "مُعلَّم",
11-
loading: "تحميل&hellip"
12-
},
13-
mapNotes:{
14-
notesUnavailable: "الوصف غير متاح",
15-
bookmarks: "إشارات مرجعية",
16-
zoomTo: "تكبير الموقع وإيجاد المزيد من المعلومات.",
17-
untitledNote: "بدون عنوان"
18-
},
19-
social: {
20-
flickr: "Flickr",
21-
mediaLayers: "طبقات الوسائط",
22-
mediaLayersDescription: "إظهار المساهمات من الجمهور على الخريطة.",
23-
flickrSettings: "إعدادات Flicker",
24-
twitter: "Twitter",
25-
twitterSettings: "إعدادات Twitter",
26-
twitterUser: "حساب Twitter",
27-
twitterSignIn: "تسجيل الدخول إلى Twitter",
28-
webcams: "Webcams.travel",
29-
instagram: "Instagram",
30-
instagramSettings: "إعدادات Instagram",
31-
igTime: "التحميل داخل عدد الايام السابقة",
32-
youtube: "YouTube",
33-
youtubeSettings: "إعدادات YouTube",
34-
ytSettingsInfo: "يتضمن عرض مقاطع الفيديو الشبكة والمحتويات الاحترافية.",
35-
ytTime: "تم التحميل فيما مضى",
36-
today: "يوم",
37-
this_week: "اسبوع",
38-
this_month: "شهر",
39-
all_time: "طول الوقت",
40-
moreInfo: "المزيد من المعلومات",
41-
searchTerms: "مصطلحات البحث",
42-
search: "بحث",
43-
flSettingsInfo: "إرجاع النتائج المتطابقة مع عنوان الصورة أو الوصف أو العلامات.",
44-
twSettingsInfo: "رؤية ما يحدث€™الآن.",
45-
igSettingsInfo: "يعتبر Instagram سريع وطريقة سهلة ومُضحكة لمشاركة الحياة مع الأصدقاء والعائلة.",
46-
advancedOperators: "تلميح:استخدم<a target=\"_blank\" href=\"https://support.twitter.com/articles/71577-using-advanced-search\">عوامل التشغيل</a>لإنشاء عمليات البحث المتقدمة.",
47-
tweetsFilteredBy: "يتم تنقية التغريدات بواسطة:",
48-
photosFilteredBy: "يتم تنقية الصور بواسطة:",
49-
videosFilteredBy: "تتم تصفية مقاطع الفيديو بواسطة:",
50-
twitterAccountStatus: "قم بتمكين طبقة Twitter لرؤية حالتك."
51-
},
52-
general: {
53-
map: "خريطة",
54-
mapInfo: "معلومات الخريطة",
55-
legend: "مفتاح الخريطة",
56-
featured: "المواقع المتميزة",
57-
layers: "طبقات",
58-
share: "مشاركة",
59-
about: "نبذة عن",
60-
find: "كود Zip والمدينة، وغير ذلك.",
61-
moreInfo: "مزيد من المعلومات",
62-
dateModified: "آخر تعديل",
63-
noSearchResult: "يتعذر إيجاد النتائج",
64-
switchAccount: "حساب التبديل",
65-
signIn: "تسجيل الدخول",
66-
settings: "الإعدادات"
67-
}
68-
})
69-
);
1+
define({
2+
"map": {
3+
"error": "يتعذر إنشاء الخريطة",
4+
"views": "مناطق عرض."
5+
},
6+
"report": {
7+
"flag": "العلامة غَيْرُ مُوَافِقة",
8+
"error": "خطأ",
9+
"success": "مُعلَّم",
10+
"loading": "تحميل&hellip"
11+
},
12+
"mapNotes": {
13+
"notesUnavailable": "الوصف غير متاح",
14+
"bookmarks": "إشارات مرجعية",
15+
"zoomTo": "تكبير الموقع وإيجاد المزيد من المعلومات.",
16+
"untitledNote": "بدون عنوان"
17+
},
18+
"social": {
19+
"flickr": "Flickr",
20+
"mediaLayers": "طبقات الوسائط",
21+
"mediaLayersDescription": "إظهار المساهمات من الجمهور على الخريطة.",
22+
"flickrSettings": "إعدادات Flicker",
23+
"twitter": "Twitter",
24+
"twitterSettings": "إعدادات Twitter",
25+
"twitterUser": "حساب Twitter",
26+
"twitterSignIn": "تسجيل الدخول إلى Twitter",
27+
"webcams": "Webcams.travel",
28+
"instagram": "Instagram",
29+
"instagramSettings": "إعدادات Instagram",
30+
"igTime": "التحميل داخل عدد الايام السابقة",
31+
"youtube": "YouTube",
32+
"youtubeSettings": "إعدادات YouTube",
33+
"ytSettingsInfo": "يتضمن عرض مقاطع الفيديو الشبكة والمحتويات الاحترافية.",
34+
"ytTime": "تم التحميل فيما مضى",
35+
"today": "يوم",
36+
"this_week": "اسبوع",
37+
"this_month": "شهر",
38+
"all_time": "طول الوقت",
39+
"moreInfo": "المزيد من المعلومات",
40+
"searchTerms": "مصطلحات البحث",
41+
"search": "بحث",
42+
"flSettingsInfo": "إرجاع النتائج المتطابقة مع عنوان الصورة أو الوصف أو العلامات.",
43+
"twSettingsInfo": "رؤية ما يحدث€™الآن.",
44+
"igSettingsInfo": "يعتبر Instagram سريع وطريقة سهلة ومُضحكة لمشاركة الحياة مع الأصدقاء والعائلة.",
45+
"advancedOperators": "تلميح:استخدم<a target=\"_blank\" href=\"https://support.twitter.com/articles/71577-using-advanced-search\">عوامل التشغيل</a>لإنشاء عمليات البحث المتقدمة.",
46+
"tweetsFilteredBy": "يتم تنقية التغريدات بواسطة:",
47+
"photosFilteredBy": "يتم تنقية الصور بواسطة:",
48+
"videosFilteredBy": "تتم تصفية مقاطع الفيديو بواسطة:",
49+
"twitterAccountStatus": "قم بتمكين طبقة Twitter لرؤية حالتك."
50+
},
51+
"general": {
52+
"map": "خريطة",
53+
"mapInfo": "معلومات الخريطة",
54+
"legend": "مفتاح الخريطة",
55+
"featured": "المواقع المتميزة",
56+
"layers": "طبقات",
57+
"share": "مشاركة",
58+
"about": "نبذة عن",
59+
"find": "كود Zip والمدينة، وغير ذلك.",
60+
"moreInfo": "مزيد من المعلومات",
61+
"dateModified": "آخر تعديل",
62+
"noSearchResult": "يتعذر إيجاد النتائج",
63+
"switchAccount": "حساب التبديل",
64+
"signIn": "تسجيل الدخول",
65+
"settings": "الإعدادات"
66+
}
67+
});

0 commit comments

Comments
 (0)