Commit Graph

62 Commits

Author SHA1 Message Date
silverqx fc477bf1e5 added qmake/cmake option to disable ORM
Added TINYORM_DISABLE_ORM macro controlled by ORM for CMake and
disable_orm for qmake. When TINYORM_DISABLE_ORM macro is defined then
only the query builder without ORM is compiled.
Also excludes ORM-related unit tests.
2021-12-31 11:40:12 +01:00
silverqx 714fd88688 sync docs, DISABLE_THREAD_LOCAL macro 2021-12-30 17:32:55 +01:00
silverqx 62d37a65f5 sync docs, fixed links 2021-12-28 11:54:42 +01:00
silverqx 35cf938440 sync docs, added Building and Hello world docs
RootFolderInput component allows to input the root folder and
application folder and these two folders are used across whole
documentation, they are persisted in the local storage.

Also pretty huge enhancements:

 - Docusaurus upgraded to 2.0.0-beta.14
 - APITable component
 - RootFolderInput / RootFolder components
 - enhanced docusaurus.config.js
 - new qmake syntax highlighter
 - fixed bash syntax highlighter
 - fixed robots.txt, moved to static/ folder
 - enabled sass for css modules and for global customCss
2021-12-27 16:53:01 +01:00
silverqx dd2ca5c754 docs Windows >=10 2021-12-21 17:30:52 +01:00
silverqx 42e1acfb78 docs enhanced dependencies page
- added Install dependencies section
 - added links
 - typos
2021-12-21 17:30:10 +01:00
silverqx 5db3ec9875 docs changed extension to sqlite3 2021-12-21 17:28:39 +01:00
silverqx 284ce50c52 docs dependencies minor update 2021-12-11 14:30:28 +01:00
silverqx 9de5f5e26a docs added supported compilers 2021-12-11 13:35:36 +01:00
silverqx cf838f6c39 docs _H to _HPP 2021-12-09 17:40:00 +01:00
silverqx 516968c7d1 bugfix docs many-to-many custom pivot example 2021-12-09 14:53:21 +01:00
silverqx e56a28c1bf docs added Pivot include to doc examples 2021-11-13 14:09:38 +01:00
silverqx 88c90f5574 bugfix in docs, section at wrong position 2021-08-03 11:34:03 +02:00
silverqx 7ca8910cc4 added querying relationship existence/absence
- support for querying nested relations existence/absence
 - added tests for all possible overloads 😲, 28 unit tests and 14
   functional tests
 - added has() related proxies to the Model and Relation
 - added documentation
 - gcc and clang specific fixes

others:

 - used clazy exclude comments instead of suppressing warnings in IDE
2021-08-03 09:31:31 +02:00
silverqx 2741447cff added docs for select and orderBy subqueries 2021-07-18 22:03:08 +02:00
silverqx 1a3daa1249 updated dependencies docs 2021-07-18 10:11:36 +02:00
silverqx b211a4db46 missing unprepared() and updated docs
Added missing unprepared() and affectingStatement() proxies.

 - also updated docs
2021-07-17 17:06:36 +02:00
silverqx 4ba7c804c9 updated docs 2021-07-17 15:15:57 +02:00
silverqx 559fa2b4c5 sync docs, bugfix headings 2021-07-15 18:28:26 +02:00
silverqx f457fbc936 added docs for subqueries in where() 2021-07-15 18:02:03 +02:00
silverqx a4fe443541 added pluck()
Two overloads, simple pluck(column) to get values from the given column
and pluck<T>(column, key) which returns std::map<T, QVariant> values
of the given column keyed by the given key.

 - added docs
 - added tests
 - manually tested all proxies
2021-07-13 14:28:41 +02:00
silverqx c2c410e20d sync docs 2021-07-13 09:43:36 +02:00
silverqx 45f59f2bac modified docs for Docusaurus 2
- added logo and favicon
2021-07-11 15:48:55 +02:00
silverqx 867a5f6587 added missing raw methods
or/whereRaw(), groupByRaw(), or/havingRaw(), orderByRaw().

 - added docs
 - tested manually in Playground
2021-07-06 18:28:58 +02:00
silverqx c65379d80f added docs for Subquery Joins 2021-07-06 11:04:40 +02:00
silverqx d8e54d1b62 docs for Aggregates and Raw methods 2021-07-06 09:34:05 +02:00
silverqx 4dbc564704 small docs update 2021-07-05 11:26:16 +02:00
silverqx 23e0564313 updated docs 2021-06-02 21:42:05 +02:00
silverqx 890cc1a6f8 updated docs
Clarified the Relation name in belongsTo/belongsToMany relations.
2021-05-27 10:14:01 +02:00
silverqx 8e90efca99 minor docs update 2021-05-25 12:07:47 +02:00
silverqx bd1c1e917f updated docs, Constraining Eager Loads and withOnly 2021-05-25 10:46:53 +02:00
silverqx e17f64a1ac added isolation_level to docs 2021-05-24 12:01:37 +02:00
silverqx ef4db51c4b updated docs, relations related changes
After the following changes:

 - get rid of Model::relationVisitor() in models
 - changed Model::u_with type to QVector<QString>
2021-05-24 11:49:34 +02:00
silverqx c7e53bc1bc updated docs after non-affecting statements
After the following change:

 - return values for non-affecting statements.
2021-05-24 10:37:51 +02:00
silverqx a313196feb updated README.md 2021-05-24 08:11:24 +02:00
silverqx 2a2f072ccf added BelongsToMany::save/saveMany/create/createMany
- added tests
 - updated documentation
 - added missing std::move in HasOneOrMany::save()
2021-04-30 22:13:33 +02:00
silverqx 02ebf6fce5 simplified many-to-many relation definition
- dynamic_cast() is not needed anymore, this is the result of following
   change:
   - relation factory methods return actual creating type instead
     of the general base Relation type"
 - also docs updated
2021-04-16 17:54:40 +02:00
silverqx 9ade54a539 added Default Models for HasOne and BelongsTo
The HasOne and BelongsTo can now return default model instead
of the nullptr.

 - also added tests
 - added documentation
 - updated test db structure, null foreign key in previewable files
 - to the test db into the previewable files added row without parent
 - relation factory methods return actual creating type instead of
   the general base Relation type
2021-04-16 13:29:42 +02:00
silverqx c15eaab7bb renamed model.hpp include in documentation 2021-04-12 13:14:09 +02:00
silverqx efb45346c3 renamed Model and Derived in documentation
- from BaseModel to Model
 - template parameter from Model to Derived

Result is Model<Derived, AllRelations...>.
2021-04-12 12:38:52 +02:00
silverqx da749b0c88 added Pessimistic Locking
- QueryBuilder::lock/sharedLock/lockForUpdate
 - also added tests
 - added documentation
2021-04-11 12:26:52 +02:00
silverqx 36ed085381 updated markdown documentation
- added missing documentation for 'Inserting & Updating Related Models'
   in TinyORM: Relationships
 - added missing documentation for 'Deleting Models'
   in TinyORM: Getting Started
 - re-compared all documentation against latest Eloquent version
2021-04-10 16:24:03 +02:00
silverqx 20c03828ff added Mass Assignment feature
- added u_fillable on models used in tests that need it
 - added documentation for mass assignment
 - added tests for mass assignment feature
 - added new Torrent models for tests, which have set up u_fillable and
   u_guarded differently
 - added schema grammar, query post-processor, and schema builder, they
   was needed for database column listing during a mass assignment
   guarded attributes check, used to check if the given attribute is
   a valid guardable column
2021-04-09 10:19:19 +02:00
silverqx 4c77f3d9b3 used using alias declarations in doc examples 2021-04-06 11:03:54 +02:00
silverqx d5d25d73b2 added docs for SQLite connetions 2021-04-06 10:32:56 +02:00
silverqx 782c95c134 added documentation for default attribute values 2021-04-06 09:31:53 +02:00
silverqx 68446e3530 added SQLite database support 🔥🚀
- all tests are ran against SQLite test database too 🎉🔥
 - removed default models connection for tests, because I'm testing
   models for all database connections and the connection is controlled
   by global test data, so every test is ran against all the
   supported databases
 - added test code controlled by TINYORM_TESTS_CODE preprocessor macro,
   which enables connection override in the BaseModel
 - build tests only when the "CONFIG += build_tests" was added to the
   qmake command

added php script to create databases

 - script creates MySQL and SQLite databases
 - script populate this databases with test data
 - connection credentials are provided through the DB_ env. variables

other changes

 - added api to enable statement counters for the given connections
 - added BaseModel::truncate test
2021-03-26 18:49:50 +01:00
silverqx d5e8a7f0be added models used in many-to-many docs 2021-03-26 18:48:38 +01:00
silverqx 74579ce909 added documentation for many-to-many relations 2021-03-26 18:48:38 +01:00
silverqx 2fe171b4b3 changed position of friend and using BaseModel
Changed in all models and the documentation was updated too.
2021-03-26 18:44:04 +01:00