Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore/esmodules #20

Open
wants to merge 134 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
134 commits
Select commit Hold shift + click to select a range
f78ea6f
add like to string filter
wojtek-krysiak Dec 11, 2019
f68826e
fix tsc
wojtek-krysiak Dec 11, 2019
79282ef
add postinstall script
wojtek-krysiak Dec 11, 2019
02eaffd
Merge pull request #1 from SoftwareBrothers/dev
wojtek-krysiak Dec 12, 2019
d9cbbe6
add extra validation error in case of error
wojtek-krysiak Dec 12, 2019
0d75ce2
add position
wojtek-krysiak Dec 23, 2019
59900ec
Merge pull request #2 from SoftwareBrothers/dev
wojtek-krysiak Dec 23, 2019
f3f108f
chore: add find many method
wojtek-krysiak Jan 21, 2020
85e6c84
fix types issues
wojtek-krysiak Jan 21, 2020
546573a
fix automated tests
wojtek-krysiak Jan 21, 2020
107f0ea
chore: migrate to latest admin bro version
wojtek-krysiak Apr 3, 2020
d7b0f4f
refactor: :zap: rename package to @admin-bro/typeorm
wojtek-krysiak Jul 27, 2020
f03b957
style: add husky commitlint
wojtek-krysiak Jul 27, 2020
67f6edc
ci: add prostgress service
wojtek-krysiak Jul 27, 2020
ad6e616
ci: add migration
wojtek-krysiak Jul 27, 2020
867b41e
ci: fix remote repo
wojtek-krysiak Jul 27, 2020
8cc22fe
style: update style to be alligned with the template repo
wojtek-krysiak Aug 3, 2020
78fb6f3
fix: wrong publication setting
wojtek-krysiak Aug 3, 2020
46a99b3
style: fix linter issue
wojtek-krysiak Aug 3, 2020
cc75e05
chore(release): 1.0.1 [skip ci]
semantic-release-bot Aug 3, 2020
b30220b
ci: add slack integration
wojtek-krysiak Aug 3, 2020
46c3600
Merge branch 'master' of github.com:SoftwareBrothers/admin-bro-typeorm
wojtek-krysiak Aug 3, 2020
da5d8ad
fix: filtering by enums
wojtek-krysiak Aug 3, 2020
21f5be5
chore(release): 1.0.2 [skip ci]
semantic-release-bot Aug 3, 2020
d051783
fix: reference tables should not be sortable
wojtek-krysiak Aug 3, 2020
8ffe10e
Merge branch 'master' of github.com:SoftwareBrothers/admin-bro-typeorm
wojtek-krysiak Aug 3, 2020
44b97e3
chore(release): 1.0.3 [skip ci]
semantic-release-bot Aug 3, 2020
1021a45
feat: bring back admin-bro
wojtek-krysiak Aug 4, 2020
6da630a
Merge branch 'master' of github.com:SoftwareBrothers/admin-bro-typeorm
wojtek-krysiak Aug 4, 2020
dd4e79c
chore(release): 1.1.0 [skip ci]
semantic-release-bot Aug 4, 2020
ca2d40b
fix: error when filter reference columns
wojtek-krysiak Aug 6, 2020
9f20de8
Merge branch 'master' of github.com:SoftwareBrothers/admin-bro-typeorm
wojtek-krysiak Aug 6, 2020
2cb218a
docs: descirbe filter solution
wojtek-krysiak Aug 6, 2020
56cbab3
chore(release): 1.1.1 [skip ci]
semantic-release-bot Aug 6, 2020
580f5f9
Fixed the problem with non numbers primary columns
gelito Aug 22, 2020
8c904e3
chore: bump admin to the latest version
wojtek-krysiak Aug 22, 2020
7cd8a57
Merge branch 'master' of github.com:SoftwareBrothers/admin-bro-typeorm
wojtek-krysiak Aug 22, 2020
d773e3c
fix: upate admin-bro version
wojtek-krysiak Aug 22, 2020
afb3e91
chore(release): 1.1.2 [skip ci]
semantic-release-bot Aug 22, 2020
0ab423b
Fixed PR changes
gelito Aug 23, 2020
f75490f
Merge branch 'master' into master
gelito Aug 23, 2020
17a02fe
Merge pull request #3 from gelito/master
wojtek-krysiak Aug 23, 2020
461db93
ci: remove obsolete debug line
wojtek-krysiak Aug 23, 2020
1065379
ci: run workflow for PRs
wojtek-krysiak Aug 23, 2020
74897a7
Merge branch 'master' of github.com:SoftwareBrothers/admin-bro-typeorm
wojtek-krysiak Aug 23, 2020
2a6a8dc
ci: chnge type of pull_request_target to regular
wojtek-krysiak Aug 23, 2020
cfa7bce
Merge branch 'beta' of github.com:SoftwareBrothers/admin-bro-typeorm …
wojtek-krysiak Aug 23, 2020
375b747
style: fix linter issues
wojtek-krysiak Aug 23, 2020
833bd34
docs: add info about example app
wojtek-krysiak Aug 23, 2020
126ab7f
docs: note about need of running watch script
wojtek-krysiak Aug 24, 2020
5a9dcb3
test: add new entity to example app
wojtek-krysiak Aug 24, 2020
75baade
fix: support string type primary keys
wojtek-krysiak Aug 24, 2020
3e99cdc
chore(release): 1.1.3 [skip ci]
semantic-release-bot Aug 24, 2020
f60e61d
feat: allow to clear reference values
wojtek-krysiak Aug 27, 2020
957764b
chore(release): 1.2.0-beta.1 [skip ci]
semantic-release-bot Aug 27, 2020
715a7f4
chore: bump admin-bro version
wojtek-krysiak Aug 27, 2020
c27fa61
Merge branch 'beta' of github.com:SoftwareBrothers/admin-bro-typeorm …
wojtek-krysiak Aug 27, 2020
f596a47
chore: merge beta
wojtek-krysiak Aug 27, 2020
397d225
chore(release): 1.2.0 [skip ci]
semantic-release-bot Aug 27, 2020
11d3ffb
feat: boolean field
giuseppecutuli Sep 9, 2020
edb6b0a
Merge pull request #6 from giuseppecutuli/master
wojtek-krysiak Sep 9, 2020
b1e487d
chore(release): 1.3.0 [skip ci]
semantic-release-bot Sep 9, 2020
dfff5ac
chore: bump admin version and unify scripts
wojtek-krysiak Oct 8, 2020
438b617
feat: add support for mixed type
wojtek-krysiak Oct 8, 2020
3590925
ci: fix Ci for tests
wojtek-krysiak Oct 8, 2020
a191eb5
ci: bump admin versions
wojtek-krysiak Oct 8, 2020
6c279ec
fix: bump admin version
wojtek-krysiak Oct 8, 2020
9234faa
chore(release): 1.4.0-beta.1 [skip ci]
semantic-release-bot Oct 8, 2020
d33acdb
feat: bump admin-bro
wojtek-krysiak Nov 1, 2020
fb43c32
chore(release): 1.4.0-beta.2 [skip ci]
semantic-release-bot Nov 1, 2020
051b5b5
Merge pull request #8 from SoftwareBrothers/beta
wojtek-krysiak Nov 1, 2020
7ff7854
chore(release): 1.4.0 [skip ci]
semantic-release-bot Nov 1, 2020
8d3f892
fix: fix issue with references not working properly without setting R…
dziraf Nov 17, 2020
7d5a4b8
fix: fix tests, change relationships behavior
dziraf Nov 17, 2020
ea24e6e
chore: remove console.log
dziraf Nov 17, 2020
6b5f468
chore: trigger prerelease
dziraf Nov 17, 2020
ecd02ae
Merge branch 'master' of github.com:SoftwareBrothers/admin-bro-typeor…
dziraf Nov 17, 2020
08de41a
chore: remove releaserc changes
dziraf Nov 17, 2020
96a7d11
Merge pull request #10 from SoftwareBrothers/fix-relations
SimonB407 Jan 8, 2021
1d8c38c
chore(release): 1.4.1-beta.1 [skip ci]
semantic-release-bot Jan 8, 2021
f75decc
feat: Detect array of numbers
JonaszJestem Feb 17, 2021
62f67de
chore(release): 1.5.0-beta.1 [skip ci]
semantic-release-bot Feb 17, 2021
52330ea
feat: Allow embedded entities
JonaszJestem Feb 19, 2021
2d35c09
Merge pull request #14 from SoftwareBrothers/fix/embedded-models
JonaszJestem Feb 19, 2021
f6de206
chore(release): 1.5.0-beta.2 [skip ci]
semantic-release-bot Feb 19, 2021
c186fdd
feat: Allow passing custom filters to typeorm adapter
JonaszJestem May 5, 2021
95faf53
fix: Tests
JonaszJestem May 5, 2021
ca7d285
Merge pull request #21 from SoftwareBrothers/feat/allow-raw-filters
JonaszJestem May 6, 2021
f9b06bc
chore(release): 1.5.0-beta.3 [skip ci]
semantic-release-bot May 6, 2021
988381f
fix: check if string param is numeric before converting to Number
dziraf May 11, 2021
46dc226
Merge pull request #22 from SoftwareBrothers/fix/safe-parse-number
dziraf May 11, 2021
577debe
chore(release): 1.5.0-beta.4 [skip ci]
semantic-release-bot May 11, 2021
15b4a5f
chore: rebrand AdminBro to AdminJS
danklewicz-swb Jun 18, 2021
aad49b9
chore: update adminjs package
dziraf Jun 18, 2021
fe38042
Merge remote-tracking branch 'origin/feat/rebrand'
dziraf Jun 18, 2021
fea549c
chore: fix merging issues
dziraf Jun 18, 2021
b64336a
chore(release): 1.0.0 [skip ci]
semantic-release-bot Jun 18, 2021
1cca51c
fix: trigger new release
dziraf Jun 18, 2021
b597cf9
chore(release): 1.0.1 [skip ci]
semantic-release-bot Jun 18, 2021
f2977f1
fix: bump version to fix release
dziraf Jun 18, 2021
1b092f2
chore(release): 1.0.2 [skip ci]
semantic-release-bot Jun 18, 2021
e969efd
chore: trigger major version update
dziraf Jun 18, 2021
f4ed2eb
chore(release): 2.0.0 [skip ci]
semantic-release-bot Jun 18, 2021
83716ee
fix: move bigint to string data type (#31)(@davedefiq)
davedefiq Jan 21, 2022
89723bb
chore(release): 2.0.1 [skip ci]
semantic-release-bot Jan 21, 2022
22bb25e
chore: fit submodule to AdminJS dev workspace (#36)
ariansobczak-rst Feb 18, 2022
e07e5e4
test(resource): minimal tests for #find
geritol Mar 25, 2021
69b3a72
fix: handle UUID type in filters
dziraf Feb 24, 2022
d5c28b7
chore(release): 2.0.2 [skip ci]
semantic-release-bot Feb 24, 2022
96f4b3f
fix: fix uuid casting for filters
dziraf Apr 3, 2022
d2be458
chore(release): 2.0.3 [skip ci]
semantic-release-bot Apr 3, 2022
4cd3882
fix: replace ^ with ~ for typeorm version to avoid accidental bump
dziraf Apr 5, 2022
25cee7e
chore(release): 2.0.4 [skip ci]
semantic-release-bot Apr 5, 2022
e989388
feat: add in support for 0.3 typeorm (#43)(@asheliahut)
asheliahut Apr 26, 2022
7d5c284
chore(release): 3.0.0 [skip ci]
semantic-release-bot Apr 26, 2022
4b2b389
fix: unflatten params in "create" method
dziraf Jun 23, 2022
79adcca
chore(release): 3.0.1 [skip ci]
semantic-release-bot Jun 23, 2022
a2bcc4e
fix: cast to CHAR instead of TEXT when filtering uuid fields (#45)
dziraf Jun 24, 2022
30ca0c3
chore(release): 3.0.2 [skip ci]
semantic-release-bot Jun 24, 2022
5cda503
chore: update AdminJS to v6
dziraf Jul 13, 2022
b1c6076
chore(release): 4.0.0 [skip ci]
semantic-release-bot Jul 13, 2022
211254e
chore: update README.md
AdamFrydrychRST Jan 20, 2023
a927cb0
chore: change to ECMAScript modules
Mar 2, 2023
40e3e3a
wip
Mar 2, 2023
6ee6ada
chore: changed TS option
Mar 9, 2023
ee17d31
wip
Mar 14, 2023
301a9cf
chore: fix type assumptions when creating a new instance
dziraf Mar 14, 2023
54683c5
chore: update packages for ESM
dziraf Mar 20, 2023
300eaee
chore: temporarily use beta adminjs
dziraf Mar 20, 2023
7f930e6
chore: eslint fixes
dziraf Mar 20, 2023
c6a6f8d
chore: change typeorm migrate script
dziraf Mar 20, 2023
089d851
chore: temporarily disable tests
dziraf Mar 20, 2023
f5e0429
chore: add test
Mar 31, 2023
8a98aca
chore: update adminjs to version 7
dziraf Apr 18, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .env-example
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
POSTGRES_USER="adminjs"
POSTGRES_PASSWORD="adminjs"
POSTGRES_DATABASE="adminjs-typeorm-app"
POSTGRES_PORT=5432
POSTGRES_HOST="localhost"
44 changes: 44 additions & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
module.exports = {
env: {
browser: true,
es2020: true,
},
extends: [
'airbnb',
'plugin:react/recommended',
'plugin:@typescript-eslint/recommended',
],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 20,
sourceType: 'module',
},
plugins: ['react', '@typescript-eslint'],
rules: {
semi: ['error', 'never'],
'no-unused-vars': 'off',
'import/prefer-default-export': 'off',
// TODO remove following 2 lines
'guard-for-in': 'off',
'no-restricted-syntax': 'off',
'import/extensions': 'off',
'import/no-unresolved': 'off',
'react/jsx-filename-extension': 'off',
indent: ['error', 2],
'linebreak-style': ['error', 'unix'],
'object-curly-newline': 'off',
'@typescript-eslint/no-explicit-any': 'off',
},
overrides: [
{
files: ['*.tsx'],
rules: {
'react/prop-types': 'off',
'react/jsx-props-no-spreading': 'off',
},
},
],
}
97 changes: 97 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
name: CI/CD
on: [push, pull_request]
jobs:
setup:
name: setup
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup
uses: actions/setup-node@v2
with:
node-version: '18.x'
- uses: actions/cache@v2
id: yarn-cache
with:
path: node_modules
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node_modules-
- name: Install
if: steps.yarn-cache.outputs.cache-hit != 'true'
run: yarn install

test:
name: Test
runs-on: ubuntu-latest
needs: setup
env:
NODE_ENV: test
POSTGRES_PASSWORD: postgres
POSTGRES_DATABASE: postgres
POSTGRES_USER: postgres
services:
postgres:
image: postgres:10.8
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: postgres
ports:
- 5432:5432
# needed because the postgres container does not provide a healthcheck
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup
uses: actions/setup-node@v2
with:
node-version: '18.x'
- uses: actions/cache@v2
id: yarn-cache
with:
path: node_modules
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node_modules-
- name: Install
if: steps.yarn-cache.outputs.cache-hit != 'true'
run: yarn install
- name: Lint
run: yarn lint
- name: Migrate
run: yarn run migrate
- name: Test
run: yarn test

publish:
name: Publish
needs: test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup
uses: actions/setup-node@v2
with:
node-version: '18.x'
- uses: actions/cache@v2
id: yarn-cache
with:
path: node_modules
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node_modules-
- name: Install
if: steps.yarn-cache.outputs.cache-hit != 'true'
run: yarn install
- name: build
run: yarn build
- name: Release
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
run: yarn release
167 changes: 163 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,164 @@
\.idea/
# File created using '.gitignore Generator' for Visual Studio Code: https://bit.ly/vscode-gig

# Created by https://www.toptal.com/developers/gitignore/api/visualstudiocode,macos,node
# Edit at https://www.toptal.com/developers/gitignore?templates=visualstudiocode,macos,node

### macOS ###
# General
.DS_Store
.AppleDouble
.LSOverride

# Icon must end with two \r
Icon

# Thumbnails
._*

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk

### Node ###
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# nyc test coverage
.nyc_output

# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
lib/
package-lock\.json
*.db
jspm_packages/

# TypeScript v1 declaration files
typings/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env
.env.test

# parcel-bundler cache (https://parceljs.org/)
.cache

# Next.js build output
.next

# Nuxt.js build / generate output
.nuxt
dist

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and not Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

# vuepress build output
.vuepress/dist

# Serverless directories
.serverless/

# FuseBox cache
.fusebox/

# DynamoDB Local files
.dynamodb/

# TernJS port file
.tern-port

# Stores VSCode versions used for testing VSCode extensions
.vscode-test

### VisualStudioCode ###
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
*.code-workspace

### VisualStudioCode Patch ###
# Ignore all local history of files
.history

# End of https://www.toptal.com/developers/gitignore/api/visualstudiocode,macos,node

# Custom rules (everything added below won't be overriden by 'Generate .gitignore File' if you use 'Update' option)

types
build
lib
.adminjs

example-app/cypress/videos
2 changes: 2 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
\.idea/
node_modules/
spec/
example-app/
src/
package-lock\.json
*.db
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
access=public
26 changes: 26 additions & 0 deletions .releaserc
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"branches": [
"+([0-9])?(.{+([0-9]),x}).x",
"master",
"next",
"next-major",
{
"name": "beta",
"prerelease": true
}
],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/npm",
"@semantic-release/github",
"@semantic-release/git",
[
"semantic-release-slack-bot",
{
"notifyOnSuccess": true,
"notifyOnFail": true
}
]
]
}
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"typescript.tsdk": "node_modules/typescript/lib"
}
7 changes: 7 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Copyright 2018 SoftwareBrothers.co

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Loading