Skip to content

Commit ce5e81a

Browse files
committed
Initial push
0 parents  commit ce5e81a

File tree

200 files changed

+22120
-0
lines changed

Some content is hidden

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

200 files changed

+22120
-0
lines changed

.editorconfig

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

.env.example

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
APP_NAME="App Signal Team"
2+
APP_ENV=local
3+
APP_KEY=base64:4yQ1/35v17eOwTa64VW+TtO9oR3XXVIjjHdmYJbPU6Y=
4+
APP_DEBUG=true
5+
APP_URL=http://127.0.0.1:8000
6+
APP_SERVICE=app.signalteam.ro
7+
8+
LOG_CHANNEL=stack
9+
LOG_DEPRECATIONS_CHANNEL=null
10+
LOG_LEVEL=debug
11+
12+
13+
DB_CONNECTION=mysql
14+
DB_HOST=mysql.app.signalteam.ro
15+
DB_PORT=3306
16+
DB_DATABASE=laravel
17+
DB_USERNAME=sail
18+
DB_PASSWORD=password
19+
20+
21+
BROADCAST_DRIVER=log
22+
CACHE_DRIVER=file
23+
FILESYSTEM_DRIVER=local
24+
QUEUE_CONNECTION=sync
25+
SESSION_DRIVER=file
26+
SESSION_LIFETIME=120
27+
28+
MEMCACHED_HOST=127.0.0.1
29+
30+
REDIS_HOST=redis.app.signalteam.ro
31+
REDIS_PASSWORD=null
32+
REDIS_PORT=6379
33+
34+
MAIL_MAILER=smtp
35+
MAIL_HOST=mailhog
36+
MAIL_PORT=1025
37+
MAIL_USERNAME=null
38+
MAIL_PASSWORD=null
39+
MAIL_ENCRYPTION=null
40+
MAIL_FROM_ADDRESS=null
41+
MAIL_FROM_NAME="${APP_NAME}"
42+
43+
AWS_ACCESS_KEY_ID=
44+
AWS_SECRET_ACCESS_KEY=
45+
AWS_DEFAULT_REGION=us-east-1
46+
AWS_BUCKET=
47+
AWS_USE_PATH_STYLE_ENDPOINT=false
48+
49+
FLARE_KEY=
50+
51+
PUSHER_APP_ID=
52+
PUSHER_APP_KEY=
53+
PUSHER_APP_SECRET=
54+
PUSHER_APP_CLUSTER=mt1
55+
56+
VITE_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
57+
VITE_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
58+
59+
60+
WWWGROUP=1000
61+
WWWUSER=1000

.gitattributes

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
* text=auto
2+
*.css linguist-vendored
3+
*.scss linguist-vendored
4+
*.js linguist-vendored
5+
CHANGELOG.md export-ignore

.github/workflows/pint.yml

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Check & fix styling
2+
3+
on: [push]
4+
5+
jobs:
6+
pint:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: Checkout code
10+
uses: actions/checkout@v2
11+
with:
12+
ref: ${{ github.head_ref }}
13+
- name: Setup PHP
14+
uses: shivammathur/setup-php@v2
15+
with:
16+
php-version: '8.2'
17+
- name: Install dependencies
18+
run: composer install --no-interaction
19+
- name: Run Pint
20+
run: ./vendor/bin/pint
21+
- name: Commit changes
22+
uses: stefanzweifel/git-auto-commit-action@v4
23+
with:
24+
commit_message: Fix styling

.gitignore

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/node_modules
2+
/public/hot
3+
/public/build
4+
/public/storage
5+
/storage/*.key
6+
/vendor
7+
.env
8+
.env.backup
9+
.phpunit.result.cache
10+
docker-compose.override.yml
11+
Homestead.json
12+
Homestead.yaml
13+
npm-debug.log
14+
yarn-error.log
15+
/.idea
16+
/.vscode

.gitpod.yml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
tasks:
2+
- name: Setup environment and launch
3+
init: |
4+
cp .env.example .env
5+
sed -i "s#APP_URL=http://127.0.0.1:8000#APP_URL=$(gp url 8000)#g" .env
6+
composer install --ignore-platform-reqs
7+
php artisan key:generate
8+
php artisan storage:link
9+
touch database/database.sqlite
10+
php artisan migrate:fresh --seed
11+
php artisan serve
12+
13+
# Configure vscode
14+
vscode:
15+
extensions:
16+
- bmewburn.vscode-intelephense-client
17+
- ms-azuretools.vscode-docker
18+
- ecmel.vscode-html-css
19+
- MehediDracula.php-namespace-resolver
20+
- Equinusocio.vsc-community-material-theme
21+
- EditorConfig.EditorConfig
22+
- streetsidesoftware.code-spell-checker

.styleci.yml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
php:
2+
preset: laravel
3+
version: 8
4+
disabled:
5+
- no_unused_imports
6+
finder:
7+
not-name:
8+
- index.php
9+
- server.php
10+
js:
11+
finder:
12+
not-name:
13+
- webpack.mix.js
14+
css: true

.syncignore

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# CodeSync won't sync the files in the .syncignore. It follows same format as .gitignore.
2+
/node_modules
3+
/public/hot
4+
/public/build
5+
/public/storage
6+
/storage/*.key
7+
/vendor
8+
.env
9+
.env.backup
10+
.phpunit.result.cache
11+
docker-compose.override.yml
12+
Homestead.json
13+
Homestead.yaml
14+
npm-debug.log
15+
yarn-error.log
16+
/.idea
17+
/.vscode

LICENSE.md

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# MIT License
2+
3+
Copyright (c) Filament
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

+102
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
# Filament Demo App
2+
3+
A demo application to illustrate how Filament Admin works.
4+
5+
![Filament Demo](https://github.com/filamentphp/demo/assets/171715/899161a9-3c85-4dc9-9599-13928d3a4412)
6+
7+
[Open in Gitpod](https://gitpod.io/#https://github.com/filamentphp/demo) to edit it and preview your changes with no setup required.
8+
9+
## Installation
10+
11+
Clone the repo locally:
12+
13+
```sh
14+
git clone https://github.com/laravel-filament/demo.git filament-demo && cd filament-demo
15+
```
16+
17+
Install PHP dependencies:
18+
19+
```sh
20+
composer install
21+
```
22+
23+
Setup configuration:
24+
25+
```sh
26+
cp .env.example .env
27+
```
28+
29+
Generate application key:
30+
31+
```sh
32+
php artisan key:generate
33+
```
34+
35+
Create an SQLite database. You can also use another database (MySQL, Postgres), simply update your configuration accordingly.
36+
37+
```sh
38+
touch database/database.sqlite
39+
```
40+
41+
Run database migrations:
42+
43+
```sh
44+
php artisan migrate
45+
```
46+
47+
Run database seeder:
48+
49+
```sh
50+
php artisan db:seed
51+
```
52+
53+
> **Note**
54+
> If you get an "Invalid datetime format (1292)" error, this is probably related to the timezone setting of your database.
55+
> Please see https://dba.stackexchange.com/questions/234270/incorrect-datetime-value-mysql
56+
57+
58+
Create a symlink to the storage:
59+
60+
```sh
61+
php artisan storage:link
62+
```
63+
64+
Run the dev server (the output will give the address):
65+
66+
```sh
67+
php artisan serve
68+
```
69+
70+
You're ready to go! Visit the url in your browser, and login with:
71+
72+
- **Username:** admin@filamentphp.com
73+
- **Password:** password
74+
75+
## Features to explore
76+
77+
### Relations
78+
79+
#### BelongsTo
80+
- ProductResource
81+
- OrderResource
82+
- PostResource
83+
84+
#### BelongsToMany
85+
- CategoryResource\RelationManagers\ProductsRelationManager
86+
87+
#### HasMany
88+
- OrderResource\RelationManagers\PaymentsRelationManager
89+
90+
#### HasManyThrough
91+
- CustomerResource\RelationManagers\PaymentsRelationManager
92+
93+
#### MorphOne
94+
- OrderResource -> Address
95+
96+
#### MorphMany
97+
- ProductResource\RelationManagers\CommentsRelationManager
98+
- PostResource\RelationManagers\CommentsRelationManager
99+
100+
#### MorphToMany
101+
- BrandResource\RelationManagers\AddressRelationManager
102+
- CustomerResource\RelationManagers\AddressRelationManager

0 commit comments

Comments
 (0)