10 Commits

Author SHA1 Message Date
Jean-Sébastien Herbaux
a583d1b859
Fix/#3184/fix server crashs on database change (#5703)
* Don't set connection field on create/edit operation on content-types & components

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Make sure that every component has a valid connection attribute

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Remove connection check on components load

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Remove default connections from core & webhook stores but make sure it's defined in the application lifecycle

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Fix component's associations that can be undefined instead of empty in populateBareAssociations

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Remove "default" connection from plugins' models

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Remove connection attribute from generated models (cli)

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Mutate each component instead of reassign

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Build core_store and webhook model based on the current config

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Add connection to templates conditionally (based on args)

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Set default value for description to undefined instead of empty string

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Remove unnecessary complexity

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Update getStarted models

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Fix attributes parsing for generate:model

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Removed tpl option from generate:model/api

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>

* Remove tpl option from cli

Signed-off-by: Convly <jean-sebastien.herbaux@epitech.eu>
2020-04-07 16:31:44 +02:00
Pierre Noël
85e2dd5b53 fix generate:model --plugin path + little refacto of code
Signed-off-by: Pierre Noël <pierre.noel@strapi.io>
2020-03-19 18:35:08 +01:00
Pierre Noël
262d3e4364 Revert "fix generate:model --plugin path + little refacto of code"
This reverts commit d64af252bf251a4229e853833f390b79891e97bb.
2020-03-19 18:33:13 +01:00
Pierre Noël
d64af252bf fix generate:model --plugin path + little refacto of code
Signed-off-by: Pierre Noël <pierre.noel@strapi.io>
2020-03-19 18:29:30 +01:00
Alberto Maturano
154fc28a57 Normalize to standar file permissions
As a result of taking a look on PR #1967 I realized there is 819
executable files in this repository. It is obvious this is an error.
2018-09-24 12:33:09 -05:00
Pierre Burgy
17135196a5 Improve arguments handling for generators 2017-02-14 01:10:37 +01:00
Aurélien Georget
f2a233e1e0 Clean codebase and tests 2016-09-28 11:42:26 +02:00
Aurélien Georget
8c88e076a9 Handle template on CLI 2016-08-10 11:00:56 +02:00
Aurélien Georget
a550049a8b Add ability to generate multiple template by considering the ORM argument in the CLI 2016-08-09 12:38:05 +02:00
loicsaintroch
54287792ed Add default model generator 2016-04-21 14:59:00 +02:00