Skip to content

[WIP] Organization SMS Twilio Feature Updates Roadmap#4836

Closed
ShamiTomita wants to merge 76 commits into
rubyforgood:mainfrom
ShamiTomita:st/4815/AddSMStoOrganizationFeaturesSection
Closed

[WIP] Organization SMS Twilio Feature Updates Roadmap#4836
ShamiTomita wants to merge 76 commits into
rubyforgood:mainfrom
ShamiTomita:st/4815/AddSMStoOrganizationFeaturesSection

Conversation

@ShamiTomita
Copy link
Copy Markdown
Collaborator

@ShamiTomita ShamiTomita commented May 22, 2023

What github issue is this PR for, if any?

Resolves #4815

What changed, and why?

Changes to Twilio Functionality in frontend and backend.
On Edit Casa Organization, the Twilio Form Inputs have been nested in an accordion drop down within the Organization Features section. Currently, if the Twilio Enabled checkbox is checked (and if the rest of the form has valid inputs), the CASA org will validate its Twilio Credentials upon update. If the Twilio checkbox is disabled, any existing Twilio credentials are still stored but any SMS services should return a notice saying: "SMS notice was not sent. Error: Twilio Is Not Enabled."

The TwilioService now has its own custom error that handles checking to see if a casa_org has twilio enabled.

Changes include:

  • adding a twilio_enabled boolean column to the casa_org table
  • creating a casa_org.js file to handle Twilio form state (adding or removing "required" or "disabled" depending on Twilio Enabled Checkbox)
  • sms_reactivation_toggle.js to prevent SMS activity on the frontend if twilio is disabled

How will this affect user permissions?

  • Volunteer permissions: N/A
  • Supervisor permissions: N/A
  • Admin permissions: Changes to Twilio form in EDIT Casa Org

How is this tested? (please write tests!) 💖💪

Relevant tests added for all three user types, application controller, requests/users/password_spec.rb

Screenshots please :)

Screenshot 2023-05-22 at 10 19 58 AM
Screenshot 2023-05-22 at 10 20 25 AM
Screenshot 2023-05-31 at 4 15 08 PM
Screenshot 2023-05-31 at 4 15 18 PM

Feelings gif (optional)

What gif best describes your feeling working on this issue? https://giphy.com/
How to embed:
![alt text](https://media.giphy.com/media/1nP7ThJFes5pgXKUNf/giphy.gif)

Feedback please? (optional)

We are very interested in your feedback! Please give us some :) https://forms.gle/1D5ACNgTs2u9gSdh9

@github-actions github-actions Bot added erb Touches ERB templates javascript Touches JavaScript code ruby Touches Ruby code labels May 22, 2023
@github-actions github-actions Bot added the dependencies Touches dependency files label May 26, 2023
@littleforest littleforest changed the title WIP add sm sto organization features section [WIP] Add SMS to organization features section May 28, 2023
FireLemons and others added 3 commits May 31, 2023 19:10
author SHAMI_TOMITA <shamitomita@gmail.com> 1685494336 -0400
committer SHAMI_TOMITA <shamitomita@gmail.com> 1685574651 -0400

added back the return value

lint and app controller spec

TwilioService resource to current_user

remove unecessary code, refactor

lint

removing unnecessary complexity

rename for sms_reactivation js file

password spec

lint

twilio service spec move

lint

remove comment

remove comment

revert to old gem file

actual revert

lint

Update Gemfile.lock

revert to old gem file

actual revert

lint

Update Gemfile.lock
@github-actions github-actions Bot added the dependencies Touches dependency files label May 31, 2023
I'm so sorry
Last and final commit
@github-actions github-actions Bot removed the dependencies Touches dependency files label May 31, 2023
@ShamiTomita
Copy link
Copy Markdown
Collaborator Author

I'm sorry for all of the commits, I was trying to squash all the small ones but ended up adding more >.< . I think all of the files are fine now though.

@cnorm35
Copy link
Copy Markdown

cnorm35 commented May 31, 2023

Hi @cnorm35, if you have some time would you be able to give this a quick glance? Thank you!

Great job getting all of this together @ShamiTomita!

@ShamiTomita ShamiTomita changed the title [WIP] Add SMS to organization features section Add SMS to organization features section Jun 5, 2023
@ShamiTomita ShamiTomita changed the title Add SMS to organization features section [WIP] Add SMS to organization features section Jun 6, 2023
@ShamiTomita ShamiTomita changed the title [WIP] Add SMS to organization features section [WIP] Organization SMS Twilio Feature Updates Roadmap Jun 15, 2023
@ShamiTomita ShamiTomita marked this pull request as draft June 15, 2023 22:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

erb Touches ERB templates javascript Touches JavaScript code ruby Touches Ruby code 🧪 Tests Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add SMS to Organization Features Section

7 participants