feat:特色菜收费
This commit is contained in:
1 parent
e5e24231e7
commit
3729e3b896
18 files changed
+93
-26
No files matched your search
@@ -104,7 +104,7 @@ class _$AppDatabase extends AppDatabase {
|
||||
Callback? callback,
|
||||
]) async {
|
||||
final databaseOptions = sqflite.OpenDatabaseOptions(
|
||||
version: 5,
|
||||
version: 7,
|
||||
onConfigure: (database) async {
|
||||
await database.execute('PRAGMA foreign_keys = ON');
|
||||
await callback?.onConfigure?.call(database);
|
||||
@@ -134,7 +134,7 @@ class _$AppDatabase extends AppDatabase {
|
||||
await database.execute(
|
||||
'CREATE TABLE IF NOT EXISTS `supermarket_code` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `serviceUniqueCode` TEXT NOT NULL, `spuId` TEXT NOT NULL, `unitId` TEXT NOT NULL, `barCode` TEXT NOT NULL)');
|
||||
await database.execute(
|
||||
'CREATE TABLE IF NOT EXISTS `shop_card` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `orderId` INTEGER NOT NULL, `productServiceUniqueCode` TEXT NOT NULL, `productName` TEXT NOT NULL, `productPic` TEXT NOT NULL, `productPrice` INTEGER NOT NULL, `nature` TEXT NOT NULL, `productNumber` INTEGER NOT NULL, `productWidget` REAL NOT NULL, `totalPrice` INTEGER NOT NULL)');
|
||||
'CREATE TABLE IF NOT EXISTS `shop_card` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `orderId` INTEGER NOT NULL, `productServiceUniqueCode` TEXT NOT NULL, `productName` TEXT NOT NULL, `productPic` TEXT NOT NULL, `productPrice` INTEGER NOT NULL, `nature` TEXT NOT NULL, `productNumber` INTEGER NOT NULL, `productWidget` REAL NOT NULL, `totalPrice` INTEGER NOT NULL, `isPriceIncreased` INTEGER NOT NULL)');
|
||||
await database.execute(
|
||||
'CREATE TABLE IF NOT EXISTS `classify` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `serviceUniqueCode` TEXT NOT NULL, `sysType` TEXT NOT NULL, `name` TEXT NOT NULL, `categoryType` TEXT NOT NULL, `sort` INTEGER NOT NULL, `createTime` TEXT NOT NULL, `updateTime` TEXT NOT NULL, `delFlag` INTEGER NOT NULL)');
|
||||
await database.execute(
|
||||
@@ -1164,7 +1164,9 @@ class _$ShopCardDao extends ShopCardDao {
|
||||
'nature': _supermarketNatureConverter.encode(item.nature),
|
||||
'productNumber': item.productNumber,
|
||||
'productWidget': item.productWidget,
|
||||
'totalPrice': item.totalPrice
|
||||
'totalPrice': item.totalPrice,
|
||||
'isPriceIncreased':
|
||||
_boolConverter.encode(item.isPriceIncreased)
|
||||
}),
|
||||
_shopCardEntityUpdateAdapter = UpdateAdapter(
|
||||
database,
|
||||
@@ -1180,7 +1182,9 @@ class _$ShopCardDao extends ShopCardDao {
|
||||
'nature': _supermarketNatureConverter.encode(item.nature),
|
||||
'productNumber': item.productNumber,
|
||||
'productWidget': item.productWidget,
|
||||
'totalPrice': item.totalPrice
|
||||
'totalPrice': item.totalPrice,
|
||||
'isPriceIncreased':
|
||||
_boolConverter.encode(item.isPriceIncreased)
|
||||
}),
|
||||
_shopCardEntityDeletionAdapter = DeletionAdapter(
|
||||
database,
|
||||
@@ -1196,7 +1200,9 @@ class _$ShopCardDao extends ShopCardDao {
|
||||
'nature': _supermarketNatureConverter.encode(item.nature),
|
||||
'productNumber': item.productNumber,
|
||||
'productWidget': item.productWidget,
|
||||
'totalPrice': item.totalPrice
|
||||
'totalPrice': item.totalPrice,
|
||||
'isPriceIncreased':
|
||||
_boolConverter.encode(item.isPriceIncreased)
|
||||
});
|
||||
|
||||
final sqflite.DatabaseExecutor database;
|
||||
@@ -1225,7 +1231,9 @@ class _$ShopCardDao extends ShopCardDao {
|
||||
nature: _supermarketNatureConverter.decode(row['nature'] as String),
|
||||
productNumber: row['productNumber'] as int,
|
||||
productWidget: row['productWidget'] as double,
|
||||
totalPrice: row['totalPrice'] as int),
|
||||
totalPrice: row['totalPrice'] as int,
|
||||
isPriceIncreased:
|
||||
_boolConverter.decode(row['isPriceIncreased'] as int)),
|
||||
arguments: [orderId]);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user