Skip to content

Commit

Permalink
Merge pull request #2282 from MoveOnOrg/add-campaign-button
Browse files Browse the repository at this point in the history
Adds campaign button functionality and updates method name to ensure that there is clarity in methods.
  • Loading branch information
Arique1104 authored Jul 25, 2023
2 parents 1e39468 + 4decbf7 commit 0740e62
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 19 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ARG BUILDER_IMAGE=node:12.22
ARG RUNTIME_IMAGE=node:12.22-alpine
ARG BUILDER_IMAGE=node:16.18
ARG RUNTIME_IMAGE=node:16.18-alpine
ARG PHONE_NUMBER_COUNTRY=US

FROM ${BUILDER_IMAGE} as builder
Expand Down
9 changes: 7 additions & 2 deletions app.json
Original file line number Diff line number Diff line change
Expand Up @@ -181,12 +181,17 @@
"TWILIO_VALIDATION": {
"description": "Validate twilio message report links as well",
"value": "1"
},

"TWILIO_MESSAGE_SERVICE_SID": {
"description": "A twilio service message account SID",
"required": false
}
},
"addons": [
"heroku-postgresql:hobby-dev",
"heroku-postgresql:mini",
{
"plan": "heroku-redis:hobby-dev",
"plan": "heroku-redis:mini",
"options": {
"maxmemory-policy": "volatile-lru"
}
Expand Down
5 changes: 0 additions & 5 deletions docs/HOWTO_AZURE_DEPLOY.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,6 @@ YARN VERSION IS:
- Usually there is an IP White List for the different access for things
- It’s probably doing something wrong with the environment variables.


## Heroku Deployment
- Documentation update coming soon.


## AZURE AUTOMATED CONFIGURATION FILE
- Coming Soonish!
- Spotcheck
Expand Down
3 changes: 2 additions & 1 deletion docs/HOWTO_HEROKU_DEPLOY.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
- Do not start any of the processes/dynos besides `web` (see below for non-Twilio uses)
- The default setup is a free tier for processing and the database. See below for scaling and production requirements

## Important Note for First Time Deployers:
## Important Notes for First Time Deployers:

- Due to the deprecation on this vendor's hobby/free resources, we wanted to inform folks that these instructions will guide you towards having successfully deploying through Heroku, but the monthly fee will be about ~$19 a month.
- There is a variable named `SUPPRESS_SELF_INVITE` in your configuration variables in Heroku. When this is set to nothing, anyone can visit your app and create an organization. When it is set to `true`, this changes login/signup behavior - when a person signs up and visits your app, they will not create an organization. On first deployment, it should be set to nothing to ensure that you have the ability to create an organization and view the full functionality of the application.

## Instructions for Auth0 configuration variable setup
Expand Down
20 changes: 11 additions & 9 deletions src/containers/AdminCampaignList.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { StyleSheet, css } from "aphrodite";
import { withRouter } from "react-router";
import gql from "graphql-tag";

import Button from "@material-ui/core/Button"
import Fab from "@material-ui/core/Fab";
import AddIcon from "@material-ui/icons/Add";
import ArchiveIcon from "@material-ui/icons/Archive";
Expand Down Expand Up @@ -64,7 +65,7 @@ export class AdminCampaignList extends React.Component {
archiveMultipleMenu: false
};

handleClickNewButton = async () => {
createNewCampaignButton = async () => {
const { organizationId } = this.props.params;
this.setState({ isLoading: true });
const newCampaign = await this.props.mutations.createCampaign({
Expand Down Expand Up @@ -342,14 +343,15 @@ export class AdminCampaignList extends React.Component {
}
// add campaign button
return (
<Fab
color="primary"
{...dataTest("addCampaign")}
style={theme.components.floatingButton}
onClick={this.handleClickNewButton}
>
<AddIcon />
</Fab>
<Button
style={theme.components.floatingButton}
color="primary"
variant="contained"
{...dataTest("addCampaign")}
onClick={this.createNewCampaignButton}
>Create New Campaign
</Button>

);
}

Expand Down

0 comments on commit 0740e62

Please sign in to comment.