Skip to content

Commit

Permalink
amplify update
Browse files Browse the repository at this point in the history
  • Loading branch information
chunyenHuang committed Mar 18, 2024
1 parent 4dec2e1 commit 9a67051
Show file tree
Hide file tree
Showing 33 changed files with 1,610 additions and 772 deletions.
5 changes: 3 additions & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"plugin:react/recommended"
],
"rules": {
"indent": ["error", 2],
"indent": ["error", 2, { "SwitchCase": 1 }],
"linebreak-style": ["error", "unix"],
"semi": ["error", "always"],
"max-len": ["error", { "code": 160 }],
Expand Down Expand Up @@ -46,6 +46,7 @@
"fetch": true,
"FormData": true,
"localStorage": true,
"FileReader": true
"FileReader": true,
"TPDirect": true
}
}
8 changes: 5 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -127,13 +127,16 @@ npm-debug.log*
yarn-debug.log*
yarn-error.log*


amplify/team-provider-info.json

#amplify-do-not-edit-begin
amplify/\#current-cloud-backend
amplify/.config/local-*
amplify/logs
amplify/mock-data
amplify/mock-api-resources
amplify/backend/amplify-meta.json
amplify/backend/awscloudformation
amplify/backend/.temp
build/
dist/
Expand All @@ -146,6 +149,5 @@ amplify-build-config.json
amplify-gradle-config.json
amplifytools.xcconfig
.secret-*
**.sample
#amplify-do-not-edit-end

amplify/team-provider-info.json
11 changes: 0 additions & 11 deletions .vscode/settings.json

This file was deleted.

7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,13 @@
## GetStarted

```bash
npm install -g @aws-amplify/cli

amplify configure
# regoin ap-northeast-1

amplify pull --appId dpw6pfmb7twme --envName {{ENV}}

# docs/React.md
npm i
npm start
Expand Down
20 changes: 20 additions & 0 deletions amplify/backend/api/aray/cli-inputs.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"version": 1,
"serviceConfiguration": {
"serviceName": "AppSync",
"defaultAuthType": {
"mode": "AMAZON_COGNITO_USER_POOLS",
"cognitoUserPoolId": "autharay6131feb9"
},
"additionalAuthTypes": [
{
"mode": "API_KEY",
"expirationTime": 365,
"apiKeyExpirationDate": "2025-03-18T19:48:46.300Z",
"keyDescription": "public"
}
],
"conflictResolution": {},
"apiName": "aray"
}
}
3 changes: 2 additions & 1 deletion amplify/backend/api/aray/parameters.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@
"autharay6131feb9",
"Outputs.UserPoolId"
]
}
},
"CreateAPIKey": 1
}
28 changes: 28 additions & 0 deletions amplify/backend/api/aray/schema/EventProject.graphql
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
type EventProject
@model
@key(name: "byEventIdByStatus",
fields: ["eventId","status"], queryField: "getEventProjectsByEventIdByStatus")
@auth(rules: [
{ allow: public, operations: [read] },
# update through custom resovler (need to update the event.attendanceCount)
{ allow: groups, groups: ["Users"], operations: [read] },
{ allow: groups, groups: ["Admins"] },
])
{
id: ID!
eventId: ID!
projectId: ID!
status: EventProjectStatus!
title: String
description: String

createdAt: AWSDateTime!
createdBy: String!
updatedAt: AWSDateTime!
updatedBy: String!
}

enum EventProjectStatus {
pending
confirmed
}
Loading

0 comments on commit 9a67051

Please sign in to comment.