fixed rest of the bugs

This commit is contained in:
amirrezaghabeli
2025-09-30 12:37:54 +03:30
parent 87bdc13689
commit 92c759b6c6
6 changed files with 9 additions and 18 deletions
+1 -7
View File
@@ -94,13 +94,7 @@ class TendersViewModel with ChangeNotifier {
// Clear data when status changes
_clearAllData();
selectedSort = sort;
if (sort == TendersStrings.lessBudget) {
sortBy = 'estimated_value';
sortOrder = 'asc';
} else if (sort == TendersStrings.moreBudget) {
sortBy = 'estimated_value';
sortOrder = 'desc';
} else if (sort == TendersStrings.minimumTime) {
if (sort == TendersStrings.minimumTime) {
sortBy = 'submission_deadline';
sortOrder = 'asc';
} else if (sort == TendersStrings.mostOfTheTime) {
@@ -17,6 +17,7 @@ class TenderDetailsStrings {
static const String tenderNoExperience =
'No experience in e-platform development';
static const String tenderSubmitButton = 'Submit';
static const String tenderAcceptButton = 'Accept';
static const String tenderRejectButton = 'Reject';
static const String tenderClientExample =
'Procurement Notice Procurement Notice';
@@ -47,7 +47,7 @@ class TenderDetailActions extends StatelessWidget {
)
: BaseButton(
isEnabled: true,
text: TenderDetailsStrings.tenderSubmitButton,
text: TenderDetailsStrings.tenderAcceptButton,
backgroundColor: AppColors.primary30,
textColor: AppColors.mainBlue,
onPressed: () {
@@ -161,7 +161,7 @@ class TenderDetailActions extends StatelessWidget {
return viewModel.isSubmitApprovalLoading
? BaseButton(
isEnabled: true,
text: TenderDetailsStrings.tenderSubmitButton,
text: TenderDetailsStrings.tenderAcceptButton,
backgroundColor: AppColors.lightBlue,
textColor: AppColors.mainBlue,
onPressed: () {},
@@ -169,7 +169,7 @@ class TenderDetailActions extends StatelessWidget {
)
: BaseButton(
isEnabled: true,
text: TenderDetailsStrings.tenderSubmitButton,
text: TenderDetailsStrings.tenderAcceptButton,
backgroundColor: AppColors.lightBlue,
textColor: AppColors.mainBlue,
onPressed: () {
+4 -4
View File
@@ -75,7 +75,7 @@ class _DesktopTendersPageState extends State<DesktopTendersPage> {
if (tenders.isEmpty) {
return const Center(child: Text(CommonStrings.noData));
}
return Column(
children: [
Expanded(
@@ -210,7 +210,7 @@ class _ActionButtons extends StatelessWidget {
),
);
},
text: 'Filter',
text: TendersStrings.filter,
icon: AssetsManager.filter,
iconColor: AppColors.textBlue,
backgroundColor: AppColors.primary2,
@@ -221,7 +221,7 @@ class _ActionButtons extends StatelessWidget {
width: 178.0.w(),
isEnabled: true,
onPressed: () {
showDialog(
showDialog(
context: context,
builder:
(_) => Dialog(
@@ -236,7 +236,7 @@ class _ActionButtons extends StatelessWidget {
),
);
},
text: 'Sort',
text: TendersStrings.sort,
icon: AssetsManager.sort,
iconColor: AppColors.textBlue,
backgroundColor: AppColors.primary2,
@@ -25,6 +25,4 @@ class TendersStrings {
static const String sort = 'Sort';
static const String mostOfTheTime = 'Most of the time';
static const String minimumTime = 'Minimum time';
static const String lessBudget = 'Less budget';
static const String moreBudget = 'More budget';
}
@@ -55,8 +55,6 @@ class TendersSortDialog extends StatelessWidget {
...[
TendersStrings.minimumTime,
TendersStrings.mostOfTheTime,
TendersStrings.lessBudget,
TendersStrings.moreBudget,
].map((status) {
return RadioListTile(
value: status,