Numéro d’ID de bogue |
BUG-000116897 |
Envoi | September 19, 2018 |
Dernière modification | August 9, 2025 |
S’applique à | ArcGIS Online |
Version trouvée | N/A |
Système d’exploitation | Windows OS |
Version du système d’exploitation | 10.0 64 Bit |
Version de correction | 6.4 (December 2018) |
Statut | Fixed
Le bogue a été corrigé. Pour plus d’informations, reportez-vous aux sections Version de correction et Informations supplémentaires, le cas échéant.
|
Solution de contournement
- Inside of an existing dataset that has a text field that is causing the issue, create a new field and set the data type to short integer.
- Right-click the feature class in the Catalog tab and click Properties.
- In the properties, click the Subtypes tab and enter the following information:
- Subtype Field: the name of the short integer field.
- Default Subtype is No Response.
- Subtypes codes (the format is code, description):
- 0, No Response
- 1, No
- 2, Yes
- Click OK to apply the subtypes.
- Open the attribute table for the feature class, right-click the short integer field, and select Field Calculator.
- There might be a warning that pops up that says calculations will be made outside of an edit session. Click Yes to proceed.
- Change the parser to Python.
- Check the checkbox next to Show Codeblock.
- Put the following lines of code into the codeblock (code will also be provided in a Python file): def calc(x): if x == 'yes': a = 2 elif x == 'Yes': a = 2 elif x == 'no': a = 1 elif x == 'No': a = 1 else: a = 0 return a
- Call the function at the bottom where the values are assigned and place in the text field as the parameter for the function (ex. Test = calc(!textfield!). See the attached picture for an example.
- Click OK to run the calculation.
- The records for the field is now updated and reflect their values from the text field..
- Publish the service to ArcGIS Online and enable the Create, Delete, and Update capabilities.
- Add the feature service to a web map with full editing control.
- Change the style of the layer by clicking Change Style and selecting the short integer field for the attribute to show. Select Type (Unique Values) for the drawing style.
- Change the labels to reflect their text values.
- Save the map and share as a Web AppBuilder for ArcGIS app.
- Choose the dashboard theme.
- While editing the app, click the Widget pane and there will be five spaces that can have widgets.
- Select one of those, choose the Info Summary widget to add, and click OK.
- This brings up a configuration window for the widget. Please put in the following parameters:
- Click the Add Layer button to add the feature service to the widget.
- Click the checkboxes next to Display Feature Counts and Expand List on Startup.
- Under Display Options, hover the mouse to the left of the symbol and a pencil symbol should appear. Click it to open a new window.
- Go to the Panel tab, click the checkbox next to Group Features, and click the radio button displaying 'by renderer'.
- Click OK to exit the Display Options window and click OK once more to exit the configuration window.
- The widget is now appear with the counts and symbols of the features currently in the map view.
- The labels now appear correctly.
Étapes pour reproduire
ID de bogue: BUG-000116897
Logiciel: