New file:
* `background_task_queue.dart`: Queues for Background Tasks.
Impacted files:
* `background_task.dart`: now we add tasks to a specific queue
* `background_task_add_other_price.dart`: assigned to `BackgroundTaskQueue.fast`
* `background_task_add_price.dart`: assigned to `BackgroundTaskQueue.slow`
* `background_task_badge.dart`: minor refactoring
* `background_task_crop.dart`: assigned to `BackgroundTaskQueue.fast`
* `background_task_details.dart`: assigned to `BackgroundTaskQueue.fast`
* `background_task_download_products.dart`: assigned to `BackgroundTaskQueue.longHaul`
* `background_task_full_refresh.dart`: assigned to `BackgroundTaskQueue.longHaul`
* `background_task_hunger_games.dart`: assigned to `BackgroundTaskQueue.fast`
* `background_task_image.dart`: assigned to `BackgroundTaskQueue.slow`
* `background_task_language_refresh.dart`: assigned to `BackgroundTaskQueue.longHaul`
* `background_task_manager.dart`: now using new class `BackgroundTaskQueue` in order to use multiple queues
* `background_task_offline.dart`: assigned to `BackgroundTaskQueue.longHaul`
* `background_task_refresh_later.dart`: assigned to `BackgroundTaskQueue.fast`
* `background_task_top_barcodes.dart`: assigned to `BackgroundTaskQueue.longHaul`
* `background_task_unselect.dart`: assigned to `BackgroundTaskQueue.fast`
* `dao_string_list.dart`: added 2 queues
* `local_database.dart`: now running all queues
* `local_database_mock.dart`: minor refactoring
* `offline_tasks_page.dart`: now taking queues into account
* `up_to_date_mixin.dart`: now running all queues
* `user_preferences_page.dart`: now running all queues
* fix: 5693 - able to run tasks without minimum duration wait
Impacted files:
* `background_task_manager.dart`: made it possible to force an immediate run if possible
* `offline_tasks_page.dart`: force an immediate run if possible when clicking on the refresh button
* Added a call to BackgroundTaskManager.run related to prices
* Minor fix
* Wtf tests
* Ugly fix for mocking hive
Impacted files:
* `app_en.arb`: added a label for "location broader search"
* `app_fr.arb`: added a label for "location broader search"
* `dao_osm_location.dart`: added columns osmKey and osmValue
* `local_database.dart`: upgraded the version in order to add columns to location table
* `location_list_supplier.dart`: added optional parameters for optimized search; added fields osmKey and osmValue
* `location_query_model.dart`: now we use 2 suppliers - optimized and broader
* `location_query_page.dart`: now display optimized results first, then broader results after a button click
* `osm_location.dart`: added fields osmKey and osmValue
New files:
* `dao_osm_location.dart`: DAO about OSM locations.
* `loading_status.dart`: Common loading status.
* `location_list_supplier.dart`: Asynchronously loads locations.
* `location_map_page.dart`: Page that displays a map centered on a location.
* `location_query_model.dart`: Location query model.
* `location_query_page.dart`: Page that displays location results during and after download.
* `osm_location.dart`: Location as expected from OSM.
* `product_loading_status.dart`: Product loading status. Refactored from `product_list_item_simple.dart`
* `search_app_bar_title.dart`: Common search app bar title.
* `search_empty_screen.dart`: Common search empty screen.
* `search_helper.dart`: Common "text-field + history" search helper.
* `search_loading_screen.dart`: Common search loading screen.
* `search_location_helper.dart`: Search helper dedicated to location search.
* `search_location_model.dart`: Search location model.
* `search_location_preloaded_item.dart`: Location search preloaded list item, for locations historically selected.
* `search_preloaded_item.dart`: Common search preloaded item.
* `search_product_helper.dart`: Search helper dedicated to product search. Used to be in `search_page.dart`
Impacted files
* `app_en.arb`: added a "No location found" label
* `app_fr.arb`: added a "No location found" label
* `app_navigator.dart`: minor refactoring
* `dao_string_list.dart`: history key for new feature "previous location searches"
* `local_database.dart`: upgraded the version to take into account new class `DaoOsmLocation`
* `personalized_ranking_model.dart`: now using a common `LoadingStatus`
* `personalized_ranking_page.dart`: now using a common `LoadingStatus`
* `product_list_item_simple.dart`: now using a common `ProductLoadingStatus`
* `product_model.dart`: now using a common `ProductLoadingStatus`
* `product_price_item.dart`: added unrelated TODO comment
* `product_query_model.dart`: now using a common `LoadingStatus`
* `product_query_page.dart`: now using common `SearchLoadingScreen`, `SearchEmptyScreen` and `SearchAppBarTitle`
* `product_query_page_helper.dart`: removed useless `ProductQueryPageResult`; refactored `EditProductCallback` to `SearchQueryCallback` somewhere else
* `search_history_view.dart`: refactored with `SearchHelper` and preloaded items
* `search_page.dart`: refactored the actual search code to `SearchHelper`; added preloaded items; found a bug
* `smooth_product_carousel.dart`: minor refactoring
* `user_preferences_dev_mode.dart`: added a temporary access to location search; removed useless key
New file:
* `background_task_language_refresh.dart`: Background task about downloading products to translate.
Impacted files:
* `background_task_manager.dart`: minor refactoring
* `dao_product.dart`: new method `getTopProductsToTranslate`
* `local_database.dart`: minor refactoring
* `offline_tasks_page.dart`: minor refactoring
* `operation_type.dart`: new operation type `languageRefresh`
* `product_refresher.dart`: minor refactoring
* `up_to_date_mixin.dart`: minor refactoring
* `up_to_date_product_provider.dart`: minor refactoring
* `user_preferences_language_selector.dart`: now calling new task `BackgroundTaskLanguageRefresh` when changing language
New file:
* `dao_product_last_access.dart`: Table that stores the local last access timestamp for a product.
Impacted files:
* `local_database.dart`: new version of the database, because of the new "product last access" table
* `new_product_page.dart`: added a call to refresh the product "last access" timestamp
* `offline_data_page.dart`: added a call to delete the product "last access" timestamps
* `product_model.dart`: added a call to refresh the product "last access" timestamp
* `pubspec.lock`: wtf
Deleted files:
* `dao_hive_product.dart`: we don't store products in hive since 18 months ago
* `dao_unzipped_product.dart`: we don't store products as unzipped since 18 months ago
Impacted files:
* `background_task_hunger_games.dart`: impacted by off-dart new features
* `background_task_image.dart`: impacted by off-dart new features
* `crop_page.dart`: impacted by off-dart new features
* `local_database.dart`: removed hive and unzipped products
New files:
* `up_to_date_interest.dart`: Management of the interest for a key.
* `up_to_date_product_list_mixin.dart`: Provides the most up-to-date local product list data for a StatefulWidget.
* `up_to_date_product_list_provider.dart`: Provider that reflects the latest barcode lists on ProductLists.
Impacted files:
* `dao_product_list.dart`: made public method `getKey`; refreshes the provider
* `local_database.dart`: added a new `UpToDateProductListProvider`
* `product_list_page.dart`: now extends `UpToDateProductListMixin
* `up_to_date_product_provider.dart`: refactored using a `UpToDateInterest`
* `user_preferences_account.dart`: removed redundant access to product list page
* fix: 4066 - top n product download split in smaller robust parts
New files:
* `background_offline_barcodes.dart`: Background subtask about pre-downloading top n barcodes.
* `background_offline_products.dart`: Background subtask about downloading products.
* `dao_work_barcode.dart`: Work table that contains barcodes.
Impacted files:
* `background_task_offline.dart`: now we clean the new `DaoWorkBarcode` and we just call the new `BackgroundtaskOfflineBarcodes`
* `local_database.dart`: upgraded to version 3, with the new `DaoWorkBarcode`.
* `operation_type.dart: added the new 2 background tasks.
TODO
* `backgrount_task_manager.dart`: make it possible to actually chain tasks with immediate execution
* Penultimate step before un-drafting
New files:
* `background_task_paged.dart`: Abstract background task with paged actions.
* `background_task_progressing.dart`: Abstract background task with work in progress actions.
Impacted files:
* `background_task_crop.dart`: minor refactoring
* `background_task_details.dart`: minor refactoring
* `background_task_hunger_games.dart`: minor refactoring
* `background_task_image.dart`: minor refactoring
* `background_task_refresh_later.dart`: minor refactoring
* `background_task_unselect.dart`: minor refactoring
* `background_task_upload.dart`: minor refactoring
* `dao_work_barcode.dart`: minor refactoring
* `edit_product_page.dart`: minor refactoring
* `local_database.dart`: minor refactoring
* `new_product_page.dart`: minor refactoring
* `offline_tasks_page.dart`: minor refactoring; displays progress percentage
* `operation_type.dart`: moved file; minor refactoring for progress percentage
* `product_image_gallery_view.dart`: minor refactoring
* `up_to_date_changes.dart`: minor refactoring
Later:
* `background_task.dart`
* `background_task_download_products.dart`
* `background_task_full_refresh.dart`
* `background_task_manager.dart`
* `background_task_offline.dart`
* `background_task_top_barcodes.dart`
* `offline_data_page.dart`
* Final commit for main features.
Impacted files:
* `app_en.arb`: added a label for topN download with parameter
* `background_task.dart`: added a bool getter for immediate exec of the next task; minor refactoring
* `background_task_download_products.dart`: now as a _progressing_ background task, reused for top N, with KP and without KP
* `background_task_full_refresh.dart`: now as a _paged_ background task, that opens two progressing download tasks (one with KP, one without KP)
* `background_task_manager.dart`: now working as singleton; added a special case for immediate exec of the next task
* `background_task_offline.dart`: now as a _progressing_ background task
* `background_task_top_barcodes.dart`: now as a _progressing_ background task
* `dao_work_barcodes.dart`: fixed the bulk insert and delete for more than 1K products (actually, 1K SQL parameters)
* `offline_data_page.dart`: now using topN and pageSize parameters
* `offline_tasks_page.dart`: added a "work" label for the tasks
* `operation_type.dart`: now embeds the "work" in the task id
* Update packages/smooth_app/lib/background/background_task_download_products.dart
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* Update packages/smooth_app/lib/background/background_task_download_products.dart
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* Update packages/smooth_app/lib/background/background_task_progressing.dart
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* Update packages/smooth_app/lib/background/background_task_progressing.dart
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* fix: 4066 - localization
---------
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* feat: 3565 - badge on bottom bar about background tasks and access to list
Impacted files:
* `app_en.arb`: added 9 labels related to background tasks
* `background_task_manager.dart`: added an error/status for each task; removed the concept of "blocked" task manager
* `offline_tasks_page.dart`: localized and added error labels
* `page_manager.dart`: added a badge on bottom bar about pending background tasks
* `pubspec.lock`: wtf
* `pubspec.yaml`: added a dependency to `badges`
* `user_preferences_dev_mode.dart`: removed the access to the pending background task page
* `user_preferences_page.dart`: added a direct access to the pending background task page
* feat: 3565 - badge on bottom bar about background tasks and access to list
New file:
* `background_task_badge.dart`: Badge about pending background tasks.
Impacted files:
* `app_en.arb`: added 1 label about subtitle, edited the label about title
* `page_manager.dart`: now using new class `BackgroundTaskBadge`
* `user_preferences_page.dart`: added a subtitle and a badge for background tasks
* feat: 3565 - refreshed goldens test
* feat: 3565 - golden tests
Impacted files:
* `background_task_badge.dart`: refactored
* `background_task_manager.dart`: refactored
* `dao_string_list.dart`: added comments
* `local_database.dart`: added a method to be mocked
* `local_database_mock.dart`: overrode a method
* `offline_tasks_page.dart`: refactored
* `user_preferences_page-dark.png`: goldens
* `user_preferences_page-light.png`: goldens
* `user_preferences_page_test.dart`: added a reference to `LocalDatabase`
* feat: 3565 - golden tests
Impacted files:
* `background_task_badge.dart`: refactored
* `background_task_manager.dart`: refactored
* `dao_string_list.dart`: added comments
* `local_database.dart`: added a method to be mocked
* `local_database_mock.dart`: overrode a method
* `offline_tasks_page.dart`: refactored
* `user_preferences_page-dark.png`: goldens
* `user_preferences_page-light.png`: goldens
* `user_preferences_page_test.dart`: added a reference to `LocalDatabase`
* fix: 3533 - added a "stamp" to background tasks, to identify similar tasks
Impacted files:
* `abstract_background_task.dart`: added a stamp; minor refactoring
* `add_basic_details_page.dart`: implemented the background stamp
* `add_other_details_page.dart`: implemented the background stamp
* `background_task_details.dart`: new `enum BackgroundTaskDetailsStamp`; added the background stamp
* `background_task_image.dart`: added the background stamp
* `background_task_manager.dart`: refactored the run queue; stops when there's not internet connection
* `background_task_refresh_later.dart`: added the background stamp
* `edit_ingredients_page.dart`: added the background stamp
* `edit_new_packagings.dart`: implemented the background stamp
* `local_database.dart`: unrelated removal of deprecated comment
* `main.dart`: slightly related fix of #3522, because we used to run background tasks before the language was set
* `nutrition_page_loaded.dart`: implemented the background stamp
* `ocr_helper.dart`: added a background stamp
* `ocr_ingredients_helper.dart`: implemented the background stamp
* `ocr_packaging_helper.dart`: implemented the background stamp
* `simple_input_page.dart`: added the background stamp; now we split the updates in as many minimum parts as possible
* `simple_input_page_helpers.dart`: added and implemented background stamps; unrelated fix (when the widget is not displayed, the data should be considered as "not changed")
* fix: 3533 - added a 5 second delay between runs
Impacted files:
* `background_task_details.dart`: more verbose tags for stamps
* `background_task_image.dart`: added language to stamp
* `background_task_manager.dart`: added a 5 second minimum delay between runs; added temporary debug prints
* `edit_product_page.dart`: added a task refresh
* `product_image_gallery_view.dart`: added a task refresh
Deleted file:
* `background_task_helper.dart`
New files:
* `background_task_manager.dart`: Management of background tasks: single thread, block, restart, display.
* `dao_instant_string.dart`: Where we store strings that need INSTANT access (= not lazy, no await).
Impacted fles:
* `abstract_background_task.dart`: refactored
* `background_task_details.dart`: refactored around the changes in `AbstractBackgroundTask`
* `background_task_image.dart`: refactored around the changes in `AbstractBackgroundTask`
* `dao_string_list.dart`: refactoring around now managing several lists; removed unnecessary `await` for a non-lazy dao
* `local_database.dart`: added the new class `DaoInstantString`; relaunch the background task manager at every refresh
* `main.dart`: minor refactoring
* `new_crop_page.dart`: unrelated bug fix
* `offline_tasks_page.dart`: refactored around the new `BackgroundTaskManager`
* `operation_type.dart`: added helper methods
* `product_image_gallery_view.dart`: minor refactoring
* `product_image_viewer.dart`: unrelated bug fix - the product was not refreshed, and so wasn't the image even after a successful download
* `pubspec.lock`: wtf
* `pubspec.yaml`: removed `flutter_task_manager`
* `search_history_view.dart`: minor refactoring now that we have several lists in `DaoStringList`
* `search_page.dart`: minor refactoring now that we have several lists in `DaoStringList`
* `up_to_date_changes.dart`: minor refactoring
* `up_to_date_product_provider.dart`: minor refactoring
New file:
* `dao_transient_operation.dart`: Transient operation: a minimalist product with a key.
Impacted files:
* `barcode_product_query.dart`: minor refactoring
* `local_database.dart`: added reference to new class `DaoTransientOperation`
* `Podfile.lock`: wtf
* `product_refresher.dart`: minor refactoring
* `pubspec.lock`: wtf
New files:
* `dao_product_migration.dart`: Helpers around product data migration.
* `dao_unzipped_product.dart`: used to be `DaoProduct` - the old not zipped version; fixed `getAll` for big lists
Impacted files:
* `dao_hive_product.dart`: minor refactoring as `DaoProductMigrationSource`
* `dao_product.dart`: new table with zipped BLOB column as product and last update timestamp
* `local_database.dart`: now it's version 2 of sql database (new zipped product table); migration from old unzipped to new zipped product table; refactored around `DaoProductMigration`
New files:
* `abstract_sql_dao.dart`: DAO abstraction for SQL.
* `bulk_deletable.dart`: Interface for bulk database deletes.
* `bulk_insertable.dart`: Interface for bulk database inserts.
* `bulk_manager.dart`: Manager for bulk database inserts and deletes.
* `dao_hive_product.dart`: moved code from the previous `hive` version of `DaoProduct`, renamed here `DaoHiveProduct`
Impacted files:
* `dao_product.dart`: `sqflite` version of `DaoProduct`, that is from now on the only one to be used
* `local_database.dart`: added `sqflite` and its one table so far, also named `DaoProduct` in order to minimize the changes everywhere else (the old `DaoProduct` being renamed `DaoHiveProduct`); migrated the product data from `hive` to `sqflite`
* `Podfile.lock`: wtf
* `pubspec.lock`: wtf
* `data_importer/pubspec.yaml`: updated the `sqflite` dependency to the same as in `smooth_app`
* `smooth_app/pubspec.yaml`: added a dependency to `sqflite`
Deleted files:
* `sample_eco_knowledge_panels.json`: replaced by new file `sample_knowledge_panels.json`
* `sample_health_knowledge_panels.json`: replaced by new file `sample_knowledge_panels.json`
New files:
* `abstract_onboarding_data.dart`: Abstraction of data we download, store and reuse at onboarding.
* `dao_string.dart`: Where we store strings.
* `loading_dialog.dart`: Dialog with a stop button, while a future is running.
* `onboarding_data_knowledge_panels.dart`: Helper around knowledge panels we download, store and reuse at onboarding.
* `onboarding_data_product.dart`: Helper around a product we download, store and reuse at onboarding.
* `onboarding_loader.dart`: Helper around data we download, store and reuse at onboarding.
* `sample_knowledge_panels.json`: json data downloaded today for en_US, cf. onboarding_data_knowledge_panels.dart
* `tmp.dart`: Fixes to off-dart.
Impacted files:
* `knowledge_panel_page_template.dart`: added parameters to 1. use the database (and downloaded data) and 2. limit the display to a given panel
* `knowlegde_panel_builder.dart`: added a method to display only one panel
* `local_database.dart`: added new dao `DaoString`
* `new_product_page.dart`: refactored
* `next_button.dart`: added an optional call to async methods at "next" time - e.g. data download
* `nutrition_page_loaded.dart`: now uses the new `LoadingDialog`
* `onboarding_flow_navigator.dart`: now using the database to get more relevant (previoulsy downloaded) data
* `preferences_page.dart`: now using previously downloaded data instead of assets
* `product_dialog_helper.dart`: now uses the new `LoadingDialog`
* `question_card.dart`: unrelated minor refactoring
* `sample_eco_card_page.dart`: now using previously downloaded data instead of assets, and displaying only the environment card
* `sample_health_card_page.dart`: now using previously downloaded data instead of assets, and displaying only the health card
* `sample_product_json.dart`: json data downloaded today for en_US, cf. onboarding_data_product.dart
* `sign_up_page.dart`: now uses the new `LoadingDialog`
Deleted files:
* `bulk_deletable.dart`
* `bulk_insertable.dart`
* `bulk_manager.dart`
* `dao_product_extra.dart`
* `label_sneek_peak_view.dart`
* `list_page.dart`
* `multi_product_select_page.dart`
* `product_copy_helper.dart`
* `product_copy_view.dart`
* `product_extra.dart`
* `product_list_add_button.dart`
* `product_list_button.dart`
* `product_list_item.dart`
* `product_list_item_pantry.dart`
* `product_list_item_shopping.dart`
* `product_list_preview.dart`
* `product_list_preview_helper.dart`
Impacted files:
* `abstract_dao.dart`: added hive related init methods
* `barcode_product_query.dart`: minor refactoring
* `category_product_query.dart`: minor refactoring
* `continuous_scan_model.dart`: minor refactoring
* `dao_product.dart`: rewritten from scratch with hive instead of sqflite - much easier to understand!
* `dao_product_list.dart`: rewritten from scratch with hive instead of sqflite - much easier to understand!
* `dao_string_list.dart` (renamed from `search_history.dart`): rewritten from scratch with hive instead of sqflite
* `database_product_list_supplier.dart`: minor refactoring
* `group_product_query.dart`: minor refactoring
* `history_page.dart`: minor refactoring
* `keywords_product_query.dart`: minor refactoring
* `local_database.dart`: rewritten from scratch with hive instead of sqflite; simplified
* `main.dart`: minor refactoring
* `new_product_page.dart`: minor refactoring
* `personalized_ranking_page.dart`: removed old feature
* `product_list.dart`: preferred `enum` to `String` for types; removed tons of old features
* `product_list_dialog_helper.dart`: removed old feature
* `product_list_item_simple.dart`: removed old features
* `product_list_page.dart`: removed old features
* `product_page.dart`: removed old feature
* `product_query_page_helper.dart`: cleaner code with `enum`s
* `pubspec.yaml`: added hive, removed sqflite
* `query_product_list_supplier.dart`: minor refactoring
* `search_history_view.dart`: minor refactoring
* `search_page.dart`: minor refactoring
Database table `product_extra` replaces now dropped `product_list_item`.
New files:
* `bulk_deletable.dart`: Interface for bulk database deletes
* `bulk_insertable.dart`: Interface for bulk database inserts
* `bulk_manager.dart`: Manager for bulk database inserts and deletes
Impacted files:
* `abstract_dao.dart`: moved specific code to new classes `Bulk...`
* `dao_product.dart`: refactored
* `dao_product_extra.dart`: now manages the product list as "product extra"; now implements new interface `BulkDeletable`
* `dao_product_list.dart`: moved the data from table `product_list_item` to table `product_extra`; dropped table `product_list_item`; refactored
* `home_page.dart`: refresh after product list preview
* `list_page.dart`: refresh after product list preview
* `local_database.dart`: new database version
* `multi_select_product_page.dart`: refactored
* `product_copy_helper.dart`: refactored
* `product_list.dart`: added the list reordering feature; refactored
* `product_list_dialog_helper.dart`: refactored
* `product_list_page.dart`: some product lists are now reorderable and with dismissible items
* `product_list_preview.dart`: added the `andThen` parameter for a refresh afterwards
* `product_page.dart`: minor fix
* `query_product_list_supplier.dart`: refactored
* `smooth_it_model.dart`: refactored
New files:
* `abstract_dao.dart`: DAO abstraction
* `dao_product_extra.dart`: DAO for Product Extra data
Impacted files:
* `barcode_product_query.dart`: automatically storing the product in the database
* `continuous_scan_model.dart`: refactored
* `dao_product.dart`: now extends new class `AbstractDao`; moved code to new class `DaoProductExtra`; refactored; optimized bulk actions
* `dao_product_list.dart`: now extends new class `AbstractDao`; now using new class `DaoProductExtra`; removed a SQLite foreign key for performance reasons; not storing products anymore (it's done somewhere else)
* `database_product_list_supplier.dart`: refactored because of `ProductListSupplier`
* `local_database.dart`: new database version; added `DaoProductExtra`
* `main.dart`: more verbose database crash message
* `product_dialog_helper.dart`: minor refactoring
* `product_list_supplier.dart`: refactored
* `product_page.dart`: now we display the access, the scan and the refresh timestamps in the lousy temporary button
* `product_query_model.dart`: removed the code regarding storing products in the database as it's now done in the `QueryProductListSupplier`
* `product_query_page.dart`: minor refactoring
* `product_query_page_helper.dart`: refactored because of `ProductListSupplier`
* `query_product_list_supplier.dart`: automatically storing the products in the database; refactored because of `ProductListSupplier`
In table `product_extra` we added an `int` column:
* the primary keys are barcode and "extra key" (e.g. an id for each different list)
* there is an `int` value and a `String` value
* the `int` value is used for ordering data (timestamps or 1,2,3,...)
* the `String` value is used for storing more complex data as json (e.g. the list of timestamps for history)
The contents of table `product_extra` can be stored in flutter code with the new class `ProductExtra` (basically, `int` and `String`)
For the moment the history and scan timestamps of each product are available via a lousy button at the end of the page.
New file:
* `product_extra.dart`: Extra data attached to a Product when it belongs to a ProductList
Impacted files:
* `dao_product.dart`: added an `int` column to the product extra table; now we use new class `ProductExtra`; refactored
* `dao_product_list.dart`: now we use new class `ProductExtra`; refactored
* `local_database.dart`: upgraded the db version because of a new column; added helper method `timestampToDateTime`
* `product_list.dart`: now we use new class `ProductExtra`; refactored
* `product_list_page.dart`: now we use new class `ProductExtra`
* `product_page.dart`: added a sample button at the end of the page in order to display all history and scans related to the product
Now works only on the product name(s), too.
Impacted classes:
* `dao_product.dart`: added table `product_extra` for accented character management
* `local_database.dart`: incremented the database version from 3 to 4
* `pubspec.yaml`: added library `diacritic` for accented characters management
Impacted files:
* `dao_product_list.dart`: created the new `product_list_extra` table and accessed it
* `home_page.dart`: not 100% unrelated - now using new method `SmoothTheme.getForegroundColor`
* `list_page.dart`: added the background color to the product list card
* `local_database.dart`: upgraded to version 3, in order to create the new `product_list_extra` table
* `product_list.dart`: added extraTags field (for the moment, icon and color)
* `product_list_dialog_helper.dart`: added method `openChange`; minor refactoring
* `product_list_page.dart`: added the background color and the icon to the app bar, added the change icon menu item
* `smooth_theme.dart`: not 100% related - added methods `getForegroundColor` and `getBackgroundColor` in order to get unified shades
New files:
* `list_page.dart`: display the list of product lists
* `product_list_page.dart`: displays a product list
Impacted files:
* `dao_product_list.dart`: added methods `delete` and `getAll`; refactored
* `local_database.dart`: implemented the `notifyListeners` method
* `main.dart`: replaced the "track" option with "lists" on the bottom menu
* `personalized_ranking_page.dart`: simplified the "sliver" effects with standard flutter behavior
* `product_list.dart`: added the "history" list and the database read-only fields
* `product_page.dart`: added the product to "history" every time the page is displayed; added a standard back button
* `product_query_page.dart`: refactored
* `product_query_page_helper.dart`: added methods to the helper class
New file:
* `scan_page.dart`: helper class to be used on top of `AlternativeContinuousScanPage` and `ContinuousScanPage`
Impacted files:
* `alternative_continuous_scan_page.dart`: `ContinuousScanModel` is now initialized upstream by `ScanPage`
* `continuous_scan_model.dart`: now a `ChangeNotifier`, uses a `ProductList` and database cache
* `continuous_scan_page.dart`: `ContinuousScanModel` is now initialized upstream by `ScanPage`
* `contribution_page.dart`: uses the new `ScanPage` widget instead of the 2 scan pages
* `local_database.dart`: removed the dummy notify listener method
* `main.dart`: uses the new `ScanPage` widget instead of the 2 scan pages
* `personalized_ranking_page.dart`: now we use a `ProductList` as input
* `product_list.dart`: added a `getProduct` method and a "scan list" identifier
* `product_page.dart`: unrelated UI fixes
* `product_query_page.dart`: slight refactoring
* `smooth_it_model.dart`: now we use `ProductList`
* `smooth_product_carousel.dart`: added the new "CACHED" product possibility; fixed an init bug
... and automagically asking the end-user if they want to see the cache
New files:
* `dao_product.dart`
* `dao_product_list.dart`
* `database_product_list_supplier.dart`
* `product_list.dart`
* `product_list_supplier.dart`
* `product_query_page_helper.dart`
* `query_product_list_supplier.dart`
Impacted files:
* `choose_page.dart`: now uses `ProductQueryPageHelper` in order to get database or http results; refactored
* `continuous_scan_model.dart`: minor refactoring due to DAO
* `group_product_query.dart`: now implements new method `getProductList`
* `keywords_product_query.dart`: now implements new method `getProductList`
* `local_database.dart`: now it's version 2; refactored using the new DAO classes
* `product_query.dart`: new method `getProductList`
* `product_query_model.dart`: now we use a `ProductListSupplier` instead of a `ProductQuery`
* `product_query_page.dart`: now we use a `ProductListSupplier` instead of a `ProductQuery`
Impacted files:
* `alternative_continuous_scan_page.dart`: refactoring mainly due to changes in `ContinuousScanModel`
* `continuous_scan_model.dart`: now we don't deal with `Widget`s, only metadata, and we use a NotifyListeners method
* `continuous_scan_page.dart`: refactoring mainly due to changes in `ContinuousScanModel`
* `contribution_page.dart`: unrelated refactoring about the use of `UserPreferences`
* `local_database.dart`: added a temporary "dummy"`NotifyListeners` method, for the sake of demonstration - to be removed
* `smooth_product_carousel.dart`: now we build the `Widget`s from metadata, and we control here the carousel
New files:
* `barcode_product_query.dart`: API query / product by barcode (used to be in `full_products_database.dart`)
* `local_database.dart`: local SQLite database with one table (`product`)
Deleted files:
* `choose_page_model.dart`: moved the code to `StatefulWidget` `ChoosePage`
* `full_product_database.dart`: database code was deprecated; API fields is now in `ProductQuery`
Impacted files:
* `alternative_continuous_scan_page.dart`: now a `StatefulWidget`; refactored with `ContinuousScanPage`
* `build.gradle`: unrelated - lowered the Android `minSdkVersion` from `24` to `19`, in order to run the app on my old smartphone ;)
* `choose_page.dart`: refactoring as changed to `StatefulWidget`
* `continuous_scan_model.dart`: not a `ChangeNotifier` anymore - should be improved when we use product list
* `continuous_scan_page.dart`: now a `StatefulWidget`
* `group_product_query.dart`: minor refactoring due to the changes in `product_query.dart`
* `keywords_product_query.dart`: minor refactoring due to the changes in `product_query.dart`
* `main.dart`: added `LocalDatabase` to the providers; simplified the code; removed mentions to `SharedPreferences`
* `product_query.dart`: refactored a bit; moved here some fields from `full_product_database.dart`
* `product_query_model.dart`: now using `LocalDatabase`
* `product_query_page.dart`: now using `LocalDatabase`; refactoring
* `pubspec.yaml`: replaced `sembast with `sqflite`