Skip to content

Instantly share code, notes, and snippets.

@ybinstock
Last active May 30, 2023 19:30
Show Gist options
  • Save ybinstock/b5a4b05253c0ac1334c1 to your computer and use it in GitHub Desktop.
Save ybinstock/b5a4b05253c0ac1334c1 to your computer and use it in GitHub Desktop.
Parental Control for Goodnight Chrome
On the Parents page, have a login/signup/forgot password feature. If the user is logged in / after the user logins/signs up,
forward to settings page with additional feature of set parental control. Instead of the save settings button, it would say "Parental Control: Save Settings".
If logged in, instead of Parental Control, it should say welcome username
If the user wants to create an account, they go to the sign up page. The sign up page request their username(email), password, confirm password and stripe plug in.
So a user who has parental control once they press the button, would have a popup with a password field to confirm that it's the adult. If confirm, changes are saved. If not, changes aren't saved.
Check off/on button for kids version
On drop down from toolbar, change options to Unplug Settings...
Technologies Used: Stripe, Parse
Is there any way for a parent to email it to friends or share it on Facebook and get the first month free?
On Click for facebook share button, change stripe settings for 30 day free trial.
https://parse.com/docs/js_guide#objects
Turn Welcome back button off from being a link.
Turn Welcome back button to Account button.
Deliverables:
User signup/login/forgot password features - by EOD Monday.
credit card/Swipe (cancelling card, model with stripe token, exp. date, CV). By EOD Tuesday
Comments on every page - by EOD Wednesday
Questions:
"You should store the id property in your database along with the other customer info that you’ve collected, such as login credentials, for later reference."
On your site, you’d need to store each user’s login credentials (e.g., username and password, in an appropriately secure, encrypted format). You’d also need to store a value for how long the customer has paid for access.
When the customer logs in, you’d verify the login credentials and check the active_until timestamp to confirm that it’s still in the future, and therefore an active account. When the subscription is renewed (i.e., when Stripe bills the customer and they are charged again) your site will need to be notified of the additional payment so that you can update the customer’s active_until timestamp in your database.
Webhooks are a tool Stripe uses to notify your site of the events that occur related to your account. To use them, you’ll have to create an endpoint (e.g., a script) on your site that Stripe will send information to and register that endpoint with Stripe. https://stripe.com/docs/guides/subscriptions - https://stripe.com/docs/guides/subscriptions
If I hide the on /off switch for the kids view, is the default on?
If logged in, show the kids version of sleep time
Routes from Parse
https://parse.com/docs/js/symbols/Parse.Router.html
If parent is logged in, show time-sleep.html
On the sign up page, after they enter their username, email, password, route to stripe signup page, then become logged in,
Create popup on time-sleep.html page confirming password
https://github.com/ParsePlatform/Todo
Get user able to input credit card information and save token on parse - done
Fix cancel subscrption. node issue. talk to ellie
List of possible errors and give messaging
Update parse everytime user auto pays
Test possible credit cards
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment