feat: start working on sell
This commit is contained in:
parent
f378c8c0be
commit
1803a2b119
8 changed files with 94 additions and 31 deletions
|
|
@ -45,6 +45,9 @@ class AddViewModel extends ChangeNotifier {
|
|||
notifyListeners();
|
||||
}
|
||||
|
||||
Owner? _sectionOwner;
|
||||
Owner? get sectionOwner => _sectionOwner;
|
||||
|
||||
List<Owner> _owners = [];
|
||||
List<Owner>? get owners => _owners;
|
||||
Future<Result<Owner>> addOwner(
|
||||
|
|
@ -176,9 +179,17 @@ class AddViewModel extends ChangeNotifier {
|
|||
),
|
||||
);
|
||||
case Error():
|
||||
break;
|
||||
return result;
|
||||
}
|
||||
|
||||
return result;
|
||||
final result2 = await _ownerRepository.sectionOwner;
|
||||
switch (result2) {
|
||||
case Ok():
|
||||
_sectionOwner = result2.value;
|
||||
break;
|
||||
default:
|
||||
}
|
||||
|
||||
return result2;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue