13 lines
378 B
Dart
13 lines
378 B
Dart
part of '../unit.dart';
|
|||
|
|
|
||
|
|
abstract class IUnitRepository {
|
||
|
|
/// Ambil satuan dari server lalu simpan ke cache lokal.
|
||
|
|
/// Bila server tidak terjangkau, kembalikan isi cache supaya POS tetap bisa
|
||
|
|
/// mencetak `4,2 ons` saat offline.
|
||
|
|
Future<Either<UnitFailure, List<ProductUnit>>> getUnits({
|
||
|
|
bool forceRefresh = false,
|
||
|
|
});
|
||
|
|
|
||
|
|
Future<List<ProductUnit>> cachedUnits();
|
||
|
|
}
|