Skip to content

Commit ba8bd47

Browse files
committed
cms
1 parent de3450b commit ba8bd47

37 files changed

+13927
-227
lines changed

content/.editorconfig

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 2
6+
end_of_line = lf
7+
charset = utf-8
8+
trim_trailing_whitespace = true
9+
insert_final_newline = true
10+
11+
[{package.json,*.yml}]
12+
indent_style = space
13+
indent_size = 2
14+
15+
[*.md]
16+
trim_trailing_whitespace = false

content/.env.example

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
HOST=0.0.0.0
2+
PORT=1337

content/.eslintignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
.cache
2+
build
3+
**/node_modules/**

content/.eslintrc

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{
2+
"parser": "babel-eslint",
3+
"extends": "eslint:recommended",
4+
"env": {
5+
"commonjs": true,
6+
"es6": true,
7+
"node": true,
8+
"browser": false
9+
},
10+
"parserOptions": {
11+
"ecmaFeatures": {
12+
"experimentalObjectRestSpread": true,
13+
"jsx": false
14+
},
15+
"sourceType": "module"
16+
},
17+
"globals": {
18+
"strapi": true
19+
},
20+
"rules": {
21+
"indent": ["error", 2, { "SwitchCase": 1 }],
22+
"linebreak-style": ["error", "unix"],
23+
"no-console": 0,
24+
"quotes": ["error", "single"],
25+
"semi": ["error", "always"]
26+
}
27+
}

content/.gitignore

+114
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
############################
2+
# OS X
3+
############################
4+
5+
.DS_Store
6+
.AppleDouble
7+
.LSOverride
8+
Icon
9+
.Spotlight-V100
10+
.Trashes
11+
._*
12+
13+
14+
############################
15+
# Linux
16+
############################
17+
18+
*~
19+
20+
21+
############################
22+
# Windows
23+
############################
24+
25+
Thumbs.db
26+
ehthumbs.db
27+
Desktop.ini
28+
$RECYCLE.BIN/
29+
*.cab
30+
*.msi
31+
*.msm
32+
*.msp
33+
34+
35+
############################
36+
# Packages
37+
############################
38+
39+
*.7z
40+
*.csv
41+
*.dat
42+
*.dmg
43+
*.gz
44+
*.iso
45+
*.jar
46+
*.rar
47+
*.tar
48+
*.zip
49+
*.com
50+
*.class
51+
*.dll
52+
*.exe
53+
*.o
54+
*.seed
55+
*.so
56+
*.swo
57+
*.swp
58+
*.swn
59+
*.swm
60+
*.out
61+
*.pid
62+
63+
64+
############################
65+
# Logs and databases
66+
############################
67+
68+
.tmp
69+
*.log
70+
*.sql
71+
*.sqlite
72+
*.sqlite3
73+
74+
75+
############################
76+
# Misc.
77+
############################
78+
79+
*#
80+
ssl
81+
.idea
82+
nbproject
83+
public/uploads/*
84+
!public/uploads/.gitkeep
85+
86+
############################
87+
# Node.js
88+
############################
89+
90+
lib-cov
91+
lcov.info
92+
pids
93+
logs
94+
results
95+
node_modules
96+
.node_history
97+
98+
99+
############################
100+
# Tests
101+
############################
102+
103+
testApp
104+
coverage
105+
106+
############################
107+
# Strapi
108+
############################
109+
110+
.env
111+
license.txt
112+
exports
113+
.cache
114+
build

content/.strapi-updater.json

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"latest": "3.3.3",
3+
"lastUpdateCheck": 1605650562334
4+
}

content/README.md

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Strapi application
2+
3+
A quick description of your strapi application

content/api/.gitkeep

Whitespace-only changes.

content/api/home/config/routes.json

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
"routes": [
3+
{
4+
"method": "GET",
5+
"path": "/home",
6+
"handler": "home.find",
7+
"config": {
8+
"policies": []
9+
}
10+
},
11+
{
12+
"method": "PUT",
13+
"path": "/home",
14+
"handler": "home.update",
15+
"config": {
16+
"policies": []
17+
}
18+
},
19+
{
20+
"method": "DELETE",
21+
"path": "/home",
22+
"handler": "home.delete",
23+
"config": {
24+
"policies": []
25+
}
26+
}
27+
]
28+
}

content/api/home/controllers/home.js

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
'use strict';
2+
3+
/**
4+
* Read the documentation (https://strapi.io/documentation/v3.x/concepts/controllers.html#core-controllers)
5+
* to customize this controller
6+
*/
7+
8+
module.exports = {};

content/api/home/models/home.js

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
'use strict';
2+
3+
/**
4+
* Read the documentation (https://strapi.io/documentation/v3.x/concepts/models.html#lifecycle-hooks)
5+
* to customize this model
6+
*/
7+
8+
module.exports = {};
+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
"kind": "singleType",
3+
"collectionName": "homes",
4+
"info": {
5+
"name": "home"
6+
},
7+
"options": {
8+
"increments": true,
9+
"timestamps": true,
10+
"draftAndPublish": true
11+
},
12+
"attributes": {
13+
"title": {
14+
"type": "string",
15+
"required": true
16+
},
17+
"head_image": {
18+
"model": "file",
19+
"via": "related",
20+
"allowedTypes": [
21+
"images"
22+
],
23+
"plugin": "upload",
24+
"required": true
25+
},
26+
"hero_text": {
27+
"type": "text",
28+
"required": true
29+
}
30+
}
31+
}

content/api/home/services/home.js

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
'use strict';
2+
3+
/**
4+
* Read the documentation (https://strapi.io/documentation/v3.x/concepts/services.html#core-services)
5+
* to customize this service
6+
*/
7+
8+
module.exports = {};

content/config/database.js

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
module.exports = ({ env }) => ({
2+
defaultConnection: 'default',
3+
connections: {
4+
default: {
5+
connector: 'bookshelf',
6+
settings: {
7+
client: 'postgres',
8+
host: env('DATABASE_HOST', '127.0.0.1'),
9+
port: env.int('DATABASE_PORT', 5433),
10+
database: env('DATABASE_NAME', 'strapi_dev'),
11+
username: env('DATABASE_USERNAME', 'strapi'),
12+
password: env('DATABASE_PASSWORD', 'magical_password'),
13+
ssl: env.bool('DATABASE_SSL', false),
14+
},
15+
options: {}
16+
},
17+
},
18+
});

content/config/functions/bootstrap.js

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
'use strict';
2+
3+
/**
4+
* An asynchronous bootstrap function that runs before
5+
* your application gets started.
6+
*
7+
* This gives you an opportunity to set up your data model,
8+
* run jobs, or perform some special logic.
9+
*
10+
* See more details here: https://strapi.io/documentation/v3.x/concepts/configurations.html#bootstrap
11+
*/
12+
13+
module.exports = () => {};

content/config/functions/cron.js

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
'use strict';
2+
3+
/**
4+
* Cron config that gives you an opportunity
5+
* to run scheduled jobs.
6+
*
7+
* The cron format consists of:
8+
* [SECOND (optional)] [MINUTE] [HOUR] [DAY OF MONTH] [MONTH OF YEAR] [DAY OF WEEK]
9+
*
10+
* See more details here: https://strapi.io/documentation/v3.x/concepts/configurations.html#cron-tasks
11+
*/
12+
13+
module.exports = {
14+
/**
15+
* Simple example.
16+
* Every monday at 1am.
17+
*/
18+
// '0 1 * * 1': () => {
19+
//
20+
// }
21+
};
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
'use strict';
2+
3+
module.exports = async (/* ctx */) => {
4+
// return ctx.notFound('My custom message 404');
5+
};

content/config/server.js

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
module.exports = ({ env }) => ({
2+
host: env('HOST', '0.0.0.0'),
3+
port: env.int('PORT', 1337),
4+
admin: {
5+
auth: {
6+
secret: env('ADMIN_JWT_SECRET', 'f27af57a3cc534b48c1cb9e1eb408596'),
7+
},
8+
},
9+
});

content/extensions/.gitkeep

Whitespace-only changes.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
jwtSecret: process.env.JWT_SECRET || '08428094-614f-4a26-a2c9-29b8e3cf9d6f'
3+
};

content/favicon.ico

3.6 KB
Binary file not shown.

0 commit comments

Comments
 (0)