Skip to content

Commit c8eca6d

Browse files
committed
updated Report widget with working demo
1 parent a5c410c commit c8eca6d

File tree

6 files changed

+429
-123
lines changed

6 files changed

+429
-123
lines changed

config/report.js

+57-12
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,20 @@
1-
define([
2-
'esri/urlUtils'
3-
], function (urlUtils) {
4-
5-
urlUtils.addProxyRule({
6-
urlPrefix: 'http://server.domain',
7-
proxyUrl: '/proxy/proxy.ashx'
8-
});
1+
define([], function (ImageParameters) {
92

103
return {
11-
isDebug: true,
4+
isDebug: false,
125

6+
//default mapClick mode, mapClickMode lets widgets know what mode the map is in to avoid multipult map click actions from taking place (ie identify while drawing).
7+
defaultMapClickMode: 'identify',
138
mapOptions: {
149
basemap: 'hybrid',
1510
center: [-122.6314, 38.2658],
16-
// center: [-122.431297, 37.773972],
1711
zoom: 19,
1812
sliderStyle: 'small'
1913
},
2014

2115
titles: {
2216
header: 'CMV Report Widget',
23-
subHeader: 'This is an example of the Report Widget',
17+
subHeader: 'Identify a parcel by clicking the map',
2418
pageTitle: 'CMV Report Widget'
2519
},
2620

@@ -32,7 +26,17 @@ define([
3226
},
3327
collapseButtonsPane: 'center', //center or outer
3428

35-
operationalLayers: [],
29+
operationalLayers: [
30+
{
31+
type: 'dynamic',
32+
url: 'http://gis-webpub.sonoma-county.org/arcgis/rest/services/BaseMap/Parcels/MapServer',
33+
title: 'Parcels',
34+
options: {
35+
id: 'parcels',
36+
opacity: 1
37+
}
38+
}
39+
],
3640

3741
widgets: {
3842
growler: {
@@ -43,12 +47,53 @@ define([
4347
srcNodeRef: 'growlerDijit',
4448
options: {}
4549
},
50+
identify: {
51+
include: true,
52+
id: 'identify',
53+
type: 'invisible',
54+
path: 'gis/dijit/Identify',
55+
options: {
56+
map: true,
57+
mapClickMode: true,
58+
mapRightClickMenu: true,
59+
identifyLayerInfos: true,
60+
identifyTolerance: 5,
61+
identifies: {
62+
parcels: {
63+
0: {
64+
fieldInfos: [
65+
{
66+
fieldName: 'APN',
67+
visible: true
68+
},
69+
{
70+
fieldName: 'Reports',
71+
visible: true,
72+
formatter: function () {
73+
return '<a id="parcel-report" title="Run Parcel Report" style="cursor:pointer">Parcel Report</a>';
74+
}
75+
}
76+
]
77+
}
78+
}
79+
}
80+
}
81+
},
4682
report: {
4783
include: true,
4884
id: 'report',
4985
type: 'invisible',
5086
path: 'widgets/Report',
5187
options: 'config/reportWidget'
88+
},
89+
reportReactor: {
90+
include: true,
91+
id: 'reportReactor',
92+
type: 'invisible',
93+
path: 'widgets/ReportReactor',
94+
options: {
95+
map: true
96+
}
5297
}
5398
}
5499
};

0 commit comments

Comments
 (0)