Skip to content

Commit ce3dc24

Browse files
authored
Merge pull request #182 from icefoganalytics/main
Updates from Icefog
2 parents 6824730 + 88ad780 commit ce3dc24

File tree

682 files changed

+83013
-728
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

682 files changed

+83013
-728
lines changed

.dockerignore

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1-
src/*/node_modules
2-
src/*/dist
1+
api/node_modules
2+
api/dist
3+
web/node_modules
4+
web/dist
35
npm-debug.log

.eslintrc.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
env:
2+
browser: true
3+
es2021: true
4+
node: true
5+
extends:
6+
- prettier
7+
overrides: []
8+
parserOptions:
9+
ecmaVersion: latest
10+
sourceType: module
11+
rules: {}
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: ''
6+
assignees: ''
7+
8+
---
9+
10+
# Context
11+
12+
**Describe the bug**
13+
A clear and concise description of what the bug is.
14+
15+
**To Reproduce**
16+
Steps to reproduce the behavior:
17+
1. Go to '...'
18+
2. Click on '....'
19+
3. Scroll down to '....'
20+
4. See error
21+
22+
**Expected behavior**
23+
A clear and concise description of what you expected to happen.
24+
25+
**Screenshots**
26+
If applicable, add screenshots to help explain your problem.
27+
28+
**Desktop (please complete the following information):**
29+
- OS: [e.g. iOS]
30+
- Browser [e.g. chrome, safari]
31+
- Version [e.g. 22]
32+
33+
**Smartphone (please complete the following information):**
34+
- Device: [e.g. iPhone6]
35+
- OS: [e.g. iOS8.1]
36+
- Browser [e.g. stock browser, safari]
37+
- Version [e.g. 22]
38+
39+
**Additional context**
40+
Add any other context about the problem here.
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
title: ''
5+
labels: ''
6+
assignees: ''
7+
8+
---
9+
10+
Relates to:
11+
- TODO
12+
13+
# Context
14+
15+
**Is your feature request related to a problem? Please describe.**
16+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
17+
18+
**Describe the solution you'd like**
19+
A clear and concise description of what you want to happen.
20+
21+
**Describe alternatives you've considered**
22+
A clear and concise description of any alternative solutions or features you've considered.
23+
24+
**Additional context**
25+
Add any other context or screenshots about the feature request here.

.github/issue_template.md

Lines changed: 0 additions & 29 deletions
This file was deleted.

.github/pull_request_template.md

Lines changed: 12 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,24 @@
1-
Please replace the following example with your own content.
1+
Fixes TODO
22

3-
Fixes [#25](https://github.com/icefoganalytics/yhsi/issues/25)
3+
Relates to:
44

5-
# User Story
5+
- TODO
66

7-
See https://github.com/icefoganalytics/yhsi/issues/3
8-
As an edit level user I can edit the /sites Themes & Function form and it will create a site change request for admin approval.
7+
# Context
98

10-
# Details
9+
TODO
1110

12-
Now that I have a working example in the form of the Summary, Location, and Dates & Conditions sections, this task is simply a port of the existing patterns to include an additional sub-form.
11+
# Implementation
1312

14-
# Implementation Details
15-
16-
- Tweaked PlaceEdit saving and serialization to hopefully reduce developer errors.
17-
- Dockerize the test suite and update the README.
18-
- add a `dev ts-node` to get access to a local node repl that runs typescript.
13+
TODO
1914

2015
# Screenshots
2116

22-
![image](https://user-images.githubusercontent.com/23045206/163441939-d889fb77-1b78-40e6-b59d-c3a386cc3a5d.png)
17+
TODO
2318

2419
# Testing Instructions
2520

26-
1. Update your user roles to include `Site Admin` via the database console.
27-
2. Go to the /sites table and select a site.
28-
3. In the Themes & Function form, make an edit and press save.
29-
4. The site will refresh and your edits will be saved.
30-
5. Update your user roles so that they _do not include_ `Site Admin` or `Administrator` via the database console. Something like `Site Viewer` would probably be best.
31-
6. Go to the /sites table and select a site.
32-
7. In the summary form, make and edit (or two) and press save.
33-
8. The page will refresh and all Themes & Function fields will become readonly. The save button on the Themes & Function form will be disabled with an appropriate tooltip.
34-
9. Make yourself an `Site Admin` again and go to the /sites-change-requests table.
35-
10. The new change request will be at the top of the list. Click on it to review.
36-
11. Note the various features:
37-
38-
- "accept/reject" toggle buttons
39-
- accept/reject all
40-
- save button is locked until all changes are approved/rejected
41-
42-
12. Reject and accept some changes and press Save.
43-
13. Go back to the /sites table and check that you can now edit the site and that the changes have been applied or rejected correctly.
21+
1. Run the test suite via `dev test` (or `dev test_api`)
22+
2. Boot the app via `dev up`
23+
3. Log in to the app at http://localhost:8080
24+
4.

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,8 @@ typings/
7272

7373
# dotenv environment variables file
7474
.env
75-
src/api/.env
75+
.envrc
76+
api/.env
7677
.env.development
7778
.env.test
7879
.env.production
@@ -114,5 +115,4 @@ db/photo_data.sql
114115
db/place_data.sql
115116

116117
# Other
117-
package-lock.json
118118
.DS_Store

.prettierrc.yaml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# .prettierrc or .prettierrc.yaml
2-
embeddedLanguageFormatting: "auto"
2+
$schema: 'https://json.schemastore.org/prettierrc'
3+
embeddedLanguageFormatting: 'auto'
34
jsxSingleQuote: true
45
pugAttributeSeparator: 'as-needed'
56
pugSingleQuote: false
@@ -8,5 +9,11 @@ semi: true
89
singleAttributePerLine: true
910
singleQuote: true
1011
tabWidth: 2
11-
trailingComma: "es5"
12+
trailingComma: 'es5'
1213
useTabs: true
14+
printWidth: 100
15+
plugins:
16+
- prettier-plugin-embed
17+
- prettier-plugin-sql
18+
language: 'tsql'
19+
paramTypes: "{ named: [':'] }"

.tool-versions

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
nodejs 20.18.0
2+
ruby 3.3.5

Dockerfile

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,29 @@ ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true \
1414
RUN mkdir /home/node/app && chown -R node:node /home/node/app
1515
RUN mkdir /home/node/web && chown -R node:node /home/node/web
1616

17-
COPY --chown=node:node src/web/package*.json /home/node/web/
18-
COPY --chown=node:node src/api/package*.json /home/node/app/
17+
COPY --chown=node:node web/package*.json /home/node/web/
18+
COPY --chown=node:node api/package*.json /home/node/app/
1919

2020
RUN npm install -g npm@8.5.5
2121
USER node
2222

2323
WORKDIR /home/node/app
2424
RUN npm install && npm cache clean --force --loglevel=error
25-
COPY --chown=node:node src/api/.env* ./
25+
COPY --chown=node:node api/.env* ./
2626

2727
WORKDIR /home/node/web
2828

2929
RUN npm install && npm cache clean --force --loglevel=error
30-
COPY --chown=node:node src/api /home/node/app/
31-
COPY --chown=node:node src/web /home/node/web/
30+
COPY --chown=node:node api /home/node/app/
31+
COPY --chown=node:node web /home/node/web/
3232

3333
RUN npm run build:docker
3434

3535
EXPOSE 3000
3636

3737
WORKDIR /home/node/app
3838

39-
COPY src/api/templates /home/node/app/dist/templates
39+
COPY api/templates /home/node/app/dist/templates
4040

4141
ENV NODE_ENV=production
4242
#RUN npm install --platform=linux --arch=x64 sharp@0.29.1

0 commit comments

Comments
 (0)