Skip to content
This repository has been archived by the owner on Jan 19, 2024. It is now read-only.

Commit

Permalink
Almost v0 - testing push to prod
Browse files Browse the repository at this point in the history
* Chart files

* Added mock_records

* AnalyticsWidgets BarChart and SurveyResponseFrequencyChart take in data as prop

* Started filtering

* Working on applying checkboxes for filtering

* Filtering re-renders the charts

* Filtering for age group and tourists

* dashboard aesthetics

* Merged in from backend

* Bolded headers for ManagedLocation tabs

* added develop environment

* amplify fix

* Visualization of average rating over time

* Statistics overview plus filter charts with checkboxes

* Adjusted time parsing correctly

* Added code to update overview section with real data

* Filtering for day and hours

* Added capacity questions, fixed some styling

* Initial settings commit

* Changed location boxes to reflect new design
Made stars accommodate fractional ratings

* Function to render checkboxes

* formatting

* Added titles to charts

* cardstyle outline

* upload pic fixed'
:

* amplify pull

* Time filtering for both sections of charts

* Only shows not enough data message when data has been retrieved and length is 0

* Reformatted filtering options

* Formatting

* Formatting for overview statistics

* Changed location boxes to reflect new design
Made stars accommodate fractional ratings

* front end edit location

* Formatting

* Formatting

* update location

* QR Code Filtering

* Formatting

* Formatting

* Slight style changes

* Bug fix for if age question isn't answered

* Analytics Dashboard excludes partially answered survey responses, 0 - 17 bucket changed to 13 - 17 (#48)

* Started throwing out incomplete surveys

* Exclude partially answered or unanswered surveys from analysis

* Changed occurences of 0-17 to 13-17

* Check if age is undefined in FilteredDataToAgeBarChart

* Change all occurrences of 0-17 to 13-17 in the data from the get request

* added TODO

* Minor change

* Github Workflow (#57)

* Displays a message if there is no data that fits the filtering criteria, changed QR code bottom axis to QR Code Name (#58)

* evan/qr-formatting (#50)

- deleted unnecessary console.log
- formatted QR management tab

* Survey data for 0-12 year olds is not collected.

* Functionality for deleting location from ManagedLocation page

* Jake/settings (#60)

* backend support

* amplify

* Basic create settings progress

* Initial settings page on sign up

* Create manager settings works after making an account

* Finished settings account creation and update in settings tab
Added bootstrap error message instead of alert

* Small star rating fix

* Fixed bug from merging

Co-authored-by: evansegaul <[email protected]>
Co-authored-by: jsladerman <[email protected]>

* Issue #62 - Populating flag for whether or not slider bar was touched (#63)

* Survey should now be including info on whether or not slider was touched

* Should be final version

* Including flag for whether or not slider was touched or rating is valid

Co-authored-by: Aviral Somani <[email protected]>

* Dropdown menu for analytics filtering (#64)

* Made filtering options collapsable

* Slight styling change

* Added instructions for filter widget

Co-authored-by: jsladerman <[email protected]>

* Billing page (#67)

* Add location button is a pencil icon

* Delete button in edit location modal

* Changed == to === and != to !== in analytics dashboard

* Fixed formatting so that everything is left-aligned in analytics dashboard when viewing from a wider screen

* Changing delete phrasing correcting style difference (#72)

* Jake/new loader (#70)

LOADING replaced with loader everywhere

* Evan/phone validation (#71)

* validation fields

* Fixing form completing notices

* change name of field

Co-authored-by: evansegaul <[email protected]>
Co-authored-by: Aviral Somani <[email protected]>

* Commenting out a line for Evan (#76)

Co-authored-by: Aviral Somani <[email protected]>

* Changed Tagline (#77)

Co-authored-by: jsladerman <[email protected]>

* Bug fix- NaN now displays a message (#78)

Co-authored by: CleanView Evan <[email protected]>
Co-authored-by: Gabi Gresenz <[email protected]>
Co-authored-by: evansegaul <[email protected]>
Co-authored-by: jsladerman <[email protected]>
Co-authored-by: cleanview-jake <[email protected]>
Co-authored-by: gabrielagresenz <[email protected]>
Co-authored-by: aviralsomani <[email protected]>
Co-authored-by: Aviral Somani <[email protected]>
  • Loading branch information
8 people authored Aug 2, 2020
1 parent bf65d11 commit 4102c04
Show file tree
Hide file tree
Showing 74 changed files with 6,089 additions and 821 deletions.

Large diffs are not rendered by default.

40 changes: 40 additions & 0 deletions amplify/backend/api/AccountSettingsApi/api-params.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"paths": [
{
"name": "/account",
"lambdaFunction": "AccountSettingsLambda",
"privacy": {
"private": true,
"auth": [
"/POST",
"/GET",
"/PUT",
"/PATCH"
]
}
}
],
"resourceName": "AccountSettingsApi",
"apiName": "AccountSettingsApi",
"functionArns": [
{
"lambdaFunction": "AccountSettingsLambda"
}
],
"privacy": {
"auth": 1,
"unauth": 0,
"authRoleName": "amplify-cleanviewweb-dev-143211-authRole",
"unAuthRoleName": "amplify-cleanviewweb-dev-143211-unauthRole"
},
"dependsOn": [
{
"category": "function",
"resourceName": "AccountSettingsLambda",
"attributes": [
"Name",
"Arn"
]
}
]
}
8 changes: 8 additions & 0 deletions amplify/backend/api/AccountSettingsApi/parameters.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"authRoleName": {
"Ref": "AuthRoleName"
},
"unauthRoleName": {
"Ref": "UnauthRoleName"
}
}
37 changes: 37 additions & 0 deletions amplify/backend/backend-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@
"LocationStorage": {
"service": "S3",
"providerPlugin": "awscloudformation"
},
"accounts": {
"service": "DynamoDB",
"providerPlugin": "awscloudformation"
}
},
"function": {
Expand Down Expand Up @@ -97,6 +101,25 @@
}
}
]
},
"AccountSettingsLambda": {
"build": true,
"providerPlugin": "awscloudformation",
"service": "Lambda",
"dependsOn": [
{
"category": "storage",
"resourceName": "accounts",
"attributes": [
"Name",
"Arn"
],
"attributeEnvMap": {
"Name": "TABLE_NAME",
"Arn": "TABLE_ARN"
}
}
]
}
},
"api": {
Expand Down Expand Up @@ -149,6 +172,20 @@
]
}
]
},
"AccountSettingsApi": {
"service": "API Gateway",
"providerPlugin": "awscloudformation",
"dependsOn": [
{
"category": "function",
"resourceName": "AccountSettingsLambda",
"attributes": [
"Name",
"Arn"
]
}
]
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,220 @@
{
"AWSTemplateFormatVersion": "2010-09-09",
"Description": "Lambda Function resource stack creation using Amplify CLI",
"Parameters": {
"CloudWatchRule": {
"Type": "String",
"Default": "NONE",
"Description": " Schedule Expression"
},
"env": {
"Type": "String"
},
"storageaccountsName": {
"Type": "String",
"Default": "storageaccountsName"
},
"storageaccountsArn": {
"Type": "String",
"Default": "storageaccountsArn"
}
},
"Conditions": {
"ShouldNotCreateEnvResources": {
"Fn::Equals": [
{
"Ref": "env"
},
"NONE"
]
}
},
"Resources": {
"LambdaFunction": {
"Type": "AWS::Lambda::Function",
"Metadata": {
"aws:asset:path": "./src",
"aws:asset:property": "Code"
},
"Properties": {
"Handler": "index.handler",
"FunctionName": {
"Fn::If": [
"ShouldNotCreateEnvResources",
"AccountSettingsLambda",
{
"Fn::Join": [
"",
[
"AccountSettingsLambda",
"-",
{
"Ref": "env"
}
]
]
}
]
},
"Environment": {
"Variables": {
"ENV": {
"Ref": "env"
},
"REGION": {
"Ref": "AWS::Region"
}
}
},
"Role": {
"Fn::GetAtt": [
"LambdaExecutionRole",
"Arn"
]
},
"Runtime": "nodejs12.x",
"Layers": [],
"Timeout": "25",
"Code": {
"S3Bucket": "amplify-cleanviewweb-develop-162445-deployment",
"S3Key": "amplify-builds/AccountSettingsLambda-4e6f34627a48316b3471-build.zip"
}
}
},
"LambdaExecutionRole": {
"Type": "AWS::IAM::Role",
"Properties": {
"RoleName": {
"Fn::If": [
"ShouldNotCreateEnvResources",
"cleanviewwebLambdaRole52683388",
{
"Fn::Join": [
"",
[
"cleanviewwebLambdaRole52683388",
"-",
{
"Ref": "env"
}
]
]
}
]
},
"AssumeRolePolicyDocument": {
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"Service": [
"lambda.amazonaws.com"
]
},
"Action": [
"sts:AssumeRole"
]
}
]
}
}
},
"lambdaexecutionpolicy": {
"DependsOn": [
"LambdaExecutionRole"
],
"Type": "AWS::IAM::Policy",
"Properties": {
"PolicyName": "lambda-execution-policy",
"Roles": [
{
"Ref": "LambdaExecutionRole"
}
],
"PolicyDocument": {
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"logs:CreateLogGroup",
"logs:CreateLogStream",
"logs:PutLogEvents"
],
"Resource": {
"Fn::Sub": [
"arn:aws:logs:${region}:${account}:log-group:/aws/lambda/${lambda}:log-stream:*",
{
"region": {
"Ref": "AWS::Region"
},
"account": {
"Ref": "AWS::AccountId"
},
"lambda": {
"Ref": "LambdaFunction"
}
}
]
}
},
{
"Effect": "Allow",
"Action": [
"dynamodb:DescribeTable",
"dynamodb:GetItem",
"dynamodb:Query",
"dynamodb:Scan",
"dynamodb:PutItem",
"dynamodb:UpdateItem",
"dynamodb:DeleteItem"
],
"Resource": [
{
"Ref": "storageaccountsArn"
},
{
"Fn::Join": [
"/",
[
{
"Ref": "storageaccountsArn"
},
"index/*"
]
]
}
]
}
]
}
}
}
},
"Outputs": {
"Name": {
"Value": {
"Ref": "LambdaFunction"
}
},
"Arn": {
"Value": {
"Fn::GetAtt": [
"LambdaFunction",
"Arn"
]
}
},
"Region": {
"Value": {
"Ref": "AWS::Region"
}
},
"LambdaExecutionRole": {
"Value": {
"Ref": "LambdaExecutionRole"
}
}
}
}
6 changes: 6 additions & 0 deletions amplify/backend/function/AccountSettingsLambda/amplify.state
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"pluginId": "amplify-nodejs-function-runtime-provider",
"functionRuntime": "nodejs",
"useLegacyBuild": true,
"defaultEditorFile": "src/app.js"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"lambdaLayers": []
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
Loading

0 comments on commit 4102c04

Please sign in to comment.