update database
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
library;
|
||||
|
||||
import 'package:hive_ce/hive.dart';
|
||||
import 'package:worker/core/constants/storage_constants.dart';
|
||||
import 'package:worker/features/home/domain/entities/member_card.dart';
|
||||
|
||||
part 'member_card_model.g.dart';
|
||||
@@ -20,8 +21,8 @@ part 'member_card_model.g.dart';
|
||||
/// - Hive local database storage
|
||||
/// - Converting to/from domain entity
|
||||
///
|
||||
/// Hive Type ID: 10 (ensure this doesn't conflict with other models)
|
||||
@HiveType(typeId: 10)
|
||||
/// Hive Type ID: 25 (from HiveTypeIds.memberCardModel)
|
||||
@HiveType(typeId: HiveTypeIds.memberCardModel)
|
||||
class MemberCardModel extends HiveObject {
|
||||
/// Member ID
|
||||
@HiveField(0)
|
||||
|
||||
@@ -8,7 +8,7 @@ part of 'member_card_model.dart';
|
||||
|
||||
class MemberCardModelAdapter extends TypeAdapter<MemberCardModel> {
|
||||
@override
|
||||
final typeId = 10;
|
||||
final typeId = 25;
|
||||
|
||||
@override
|
||||
MemberCardModel read(BinaryReader reader) {
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
library;
|
||||
|
||||
import 'package:hive_ce/hive.dart';
|
||||
import 'package:worker/core/constants/storage_constants.dart';
|
||||
import 'package:worker/features/home/domain/entities/promotion.dart';
|
||||
|
||||
part 'promotion_model.g.dart';
|
||||
@@ -20,8 +21,8 @@ part 'promotion_model.g.dart';
|
||||
/// - Hive local database storage
|
||||
/// - Converting to/from domain entity
|
||||
///
|
||||
/// Hive Type ID: 11 (ensure this doesn't conflict with other models)
|
||||
@HiveType(typeId: 11)
|
||||
/// Hive Type ID: 26 (from HiveTypeIds.promotionModel)
|
||||
@HiveType(typeId: HiveTypeIds.promotionModel)
|
||||
class PromotionModel extends HiveObject {
|
||||
/// Promotion ID
|
||||
@HiveField(0)
|
||||
|
||||
@@ -8,7 +8,7 @@ part of 'promotion_model.dart';
|
||||
|
||||
class PromotionModelAdapter extends TypeAdapter<PromotionModel> {
|
||||
@override
|
||||
final typeId = 11;
|
||||
final typeId = 26;
|
||||
|
||||
@override
|
||||
PromotionModel read(BinaryReader reader) {
|
||||
|
||||
@@ -147,7 +147,7 @@ class HomePage extends ConsumerWidget {
|
||||
QuickAction(
|
||||
icon: Icons.grid_view,
|
||||
label: l10n.products,
|
||||
onTap: () => context.go(RouteNames.products),
|
||||
onTap: () => context.pushNamed(RouteNames.products),
|
||||
),
|
||||
QuickAction(
|
||||
icon: Icons.shopping_cart,
|
||||
|
||||
Reference in New Issue
Block a user