sqfentity_gen 1.2.0+7 copy "sqfentity_gen: ^1.2.0+7" to clipboard
sqfentity_gen: ^1.2.0+7 copied to clipboard

outdated

SqfnEntity Model Generator. SQLite ORM for Flutter lets you build and execute SQL commands easily and quickly with the help of fluent methods similar to .Net Entity Framework.

1.2.0+7 #

Added Form Generation Feature, and minValue, maxValue propery for datetime fields and fixed some bugs. Example:

@SqfEntityBuilderForm(tableCategory, formListTitleField: 'name', hasSubItems: true)
const tableCategory = SqfEntityTable(
    tableName: 'category',
    primaryKeyName: 'id',
    primaryKeyType: PrimaryKeyType.integer_auto_incremental,
    useSoftDeleting: true,
    // when useSoftDeleting is true, creates a field named 'isDeleted' on the table, and set to '1' this field when item deleted (does not hard delete)
    modelName:
        null, // SqfEntity will set it to TableName automatically when the modelName (class name) is null
    // declare fields
    fields: [
    SqfEntityField('name', DbType.text),
    SqfEntityField('isActive', DbType.bool, defaultValue: true),
    SqfEntityField('date1', DbType.datetime, defaultValue: 'DateTime.now()', minValue: '2019-01-01', maxValue: '2023-01-01'),
    SqfEntityField('date2', DbType.datetime,  minValue: '2020-01-01', maxValue: '2022-01-01')
    ]);

1.1.1+3 #

fixed the build error after defining multiple referance (RelationShip) to the same table

1.1.1+1 #

added saveResult property Note: You must re-generate your models after updating the package

Example:

final product = Product(
    name: 'Notebook 12"',
    description: '128 GB SSD i7',
    price: 6899,
    categoryId: 1);
await product.save();

print(product.saveResult.success); // bool (true/false)
print(product.saveResult.toString()); // String (message)

1.1.0+5 #

bugfix SequenceManager error on multi database

1.1.0+4 #

added unknown (text) dbType for unrecognized columns

1.1.0+3 #

added Date (Small Date) dbType

    SqfEntityField('birthDate', DbType.date),

1.1.0+2 #

added DateTime dbType

    SqfEntityField('birthDate', DbType.datetime),

1.1.0+1 #

modified sqlite dbType mapping

1.1.0 #

merged package with sqfentity_base

1.0.3+5 #

removed analyzer from dependencies

1.0.3+4 #

added FormBuilder

1.0.3+3 #

removed FormBuilder

1.0.3+2 #

added analyzer 0.38.2

1.0.3+1 #

sqfentity_base exported to sqfentity_base 1.0.1 package

1.0.2+4 #

Blob type mapped as Uint8List instead String

1.0.2 #

Added function to generate model from existing database

1.0.1 #

sqfentity_base moved into this package

1.0.0+7 #

some required changes applied

1.0.0+6 #

  • Initial publish This package required for sqfentity_gen ORM for Flutter code generator Includes SqfEntity base classes and Annotation Classes
19
likes
0
pub points
90%
popularity

Publisher

verified publisherhuseyintokpinar.com

SqfnEntity Model Generator. SQLite ORM for Flutter lets you build and execute SQL commands easily and quickly with the help of fluent methods similar to .Net Entity Framework.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

build, source_gen

More

Packages that depend on sqfentity_gen