AnsweredAssumed Answered

How to require fields to be updated when a text field is edited

Question asked by csoper@cityofberkeley.info_berkeley on Jun 9, 2020
Latest reply on Jun 11, 2020 by avezina-esristaff

I've created my first Web AppBuilder app! I’m trying to require one or more fields to be updated when a text field is edited. I think that the Smart Editor widget may be the solution. I'm sorry to ask such a long question.

 

Data in this app comes from a Survey123 form that I created. The survey has about 20 main questions and another 30 or so questions within a repeating group. My Feature Layer (hosted) from the survey has one layer and one related table. Example survey results (at least one item in the repeating group is required):

  • result 1 (item 1)
  • result 2 (item 1, item 2, item 3, item 4)
  • result 3 (item 1)
  • result 4 (item 1, item 2)

 

The Attributes pane in the Web AppBuilder app has two tabs:

  • A layer: each row represents the first 20 questions from the survey (one row per survey result).
  • A table: each row represents the next 30 questions from the survey (one or more rows per survey result).

 

After the survey results come in, an administrator needs to review text fields to remove personal info or correct an error. There are three text fields that need reviewing:

  • One text field in rows from layer (first tab in Attribute pane).
  • Two text fields in rows from table (second tab in Attribute pane).

 

I need a way to quickly review all of these text fields and update the status. At a minimum, I want to update the status with one record, like this:
ReviewStatus: 0=pendingReview, 1=changeIsNeeded, 2=deleted, 3=reviewComplete.

 

In general:

  1. Each record (survey result) will usually only have one row (item) in the related table.
  2. Each record needs to be reviewed and marked when the review is complete.
    1. Modifying text fields to remove personal info or correct errors should be infrequent.
  3. If possible, I need the ability to select 10 or 20 records, and mark them as reviewed. One by one would be tedious.

 

Ideally, I’d also like to indicate why the change was made:

PersonalInfo: 0=none, 1=removed.
Error: 0=none, 1=corrected.

And if an item or record was deleted (marked deleted, not actually deleted):

ItemDeleted: NUM1,NUM2 (comma separated list of items deleted).
RecordDeleted: 0=notDeleted, 1=enteredByAccident, etc.


Is there a way to accomplish everything I’m trying to do? When editing a text field, I want to require other field(s) to be updated. Is the Smart Editor widget the solution? I’ve read the documentation but, still haven’t been able to set it up. I’m new to building Web AppBuilder apps.

 

Thank you,
Chuck

Outcomes