Skip to content

Wins page

Saumil Dhankar edited this page Jun 27, 2022 · 25 revisions

Wins page

Current process for wins to appear on the wins page

  • User fills out share your wins form available through the Share your wins button on the Wins page
    • Form answers go onto the response tab of a spreadsheet automatically.

    • A Google Apps Script uses the access permissions of elizabethhonest bot account and creates an issue on the project board notifying us that the new submission needs to be reviewed

      Screenshot of an issue created by the elizabethhonest bot account

      image

      • An On form submit trigger runs a function which reformats a copy of the answer from the response tab onto the review tab in the spreadsheet for review
      • Submission is reviewed by product (in the spreadsheet)
      Screenshot of user response in review sheet

      image

      • If acceptable, PM marks true for show on website
      • If exceptional, PM marks true for showing on about page (this functionality might not be fully implemented yet)
      • If not acceptable, PM marks false for show on website
  • The Google Apps Script uses a time-based trigger to check the spreadsheet monthly and uses the access permissions of the elizabethhonest bot account to create a pull request for rows that should be added to the data in the json file.
  • When the pull request is merged, the data in _wins-data.json file gets updated and the wins.js file uses the json file to display the data on the Wins page. (Note: we are in the process of changing how the json files are generated, so this line item might need to be reviewed and updated again if required)
  • Once a month, new wins might appear on the Wins page on website if the user entry is approved by PM and the related PR has been merged.

Automations related to the process

  • As soon as a user submits the survey form, an On form submit trigger in the Google Apps Script adds the information from the response tab to the review tab in a spreadsheet in a specified format.
  • At the same time another On form summit trigger creates an issue to be added to our project board.
  • Next a time-based trigger which triggers monthly, in the same Google Apps Script, creates a Pull Request which if merged adds the new row (in the spreadsheet with a True value in the Display column) to the Wins page on the website.

Steps for developers working on issues related to wins page

  • Check if the issue requires you to gain access to the HfLA Website Admin Folder, if yes, reach out to the leads requesting appropriate access permissions.
    • If you need to work on the how the data from json file is used by wins.js to display on the wins page, you might not need access to the HfLA Website Admin Folder, but if you need to work on anything related to how the json file is generated, you will probably need access to the folder. If you are not sure, please check with the leads.
  • Go through the Wins form admin guide for detailed information on how the workflow (up until generation of the json file) is set up.
  • Make copies of all the files needed (from the HfLA Website Admin Folder) in your own drive and test out the code changes. No code change should be made to the production script.
  • Once approved the leads would add the code changes to the production script.

Resources

Note: Permissions to some of these resources might be restricted due to involvement of user data, please reach out to leads for access requests. Also, the list of resources is not comprehensive for security reasons, but the Wins form admin guide has detailed information on what resources you might need.

Clone this wiki locally