BASE: Update Icons & Name Of The App.
This commit is contained in:
@@ -2,7 +2,7 @@ import 'package:customer/constant/constant.dart';
|
||||
import 'package:customer/models/product_model.dart';
|
||||
import 'package:customer/models/vendor_model.dart';
|
||||
import '../service/fire_store_utils.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:get/get.dart' hide Trans;
|
||||
|
||||
class SearchScreenController extends GetxController {
|
||||
@override
|
||||
@@ -28,13 +28,20 @@ class SearchScreenController extends GetxController {
|
||||
isLoading.value = false;
|
||||
|
||||
for (var element in vendorList) {
|
||||
await FireStoreUtils.getProductByVendorId(element.id.toString()).then((value) {
|
||||
if ((Constant.isSubscriptionModelApplied == true || element.adminCommission?.isEnabled == true) && element.subscriptionPlan != null) {
|
||||
await FireStoreUtils.getProductByVendorId(element.id.toString()).then((
|
||||
value,
|
||||
) {
|
||||
if ((Constant.isSubscriptionModelApplied == true ||
|
||||
element.adminCommission?.isEnabled == true) &&
|
||||
element.subscriptionPlan != null) {
|
||||
if (element.subscriptionPlan?.itemLimit == '-1') {
|
||||
productList.addAll(value);
|
||||
} else {
|
||||
int selectedProduct =
|
||||
value.length < int.parse(element.subscriptionPlan?.itemLimit ?? '0') ? (value.isEmpty ? 0 : (value.length)) : int.parse(element.subscriptionPlan?.itemLimit ?? '0');
|
||||
value.length <
|
||||
int.parse(element.subscriptionPlan?.itemLimit ?? '0')
|
||||
? (value.isEmpty ? 0 : (value.length))
|
||||
: int.parse(element.subscriptionPlan?.itemLimit ?? '0');
|
||||
productList.addAll(value.sublist(0, selectedProduct));
|
||||
}
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user