Updated the pipeline

This commit is contained in:
Abdullah Alassaf
2024-09-04 17:05:13 +03:00
parent 5f4aa93e01
commit fd497d5797
4 changed files with 15 additions and 20 deletions

View File

@ -31,7 +31,7 @@ jobs:
run: flutter pub get
- name: Build Flutter Web App
run: flutter build web
run: flutter build web --release --dart-define=FLAVOR=production
- name: Build And Deploy
id: builddeploy

View File

@ -1,5 +1,4 @@
import 'dart:convert';
import 'package:flutter/cupertino.dart';
import 'package:syncrow_web/pages/access_management/model/password_model.dart';
import 'package:syncrow_web/pages/visitor_password/model/device_model.dart';
import 'package:syncrow_web/pages/visitor_password/model/schedule_model.dart';

View File

@ -1,5 +1,4 @@
import 'package:dio/dio.dart';
import 'package:flutter/foundation.dart';
import 'package:syncrow_web/pages/auth/model/region_model.dart';
import 'package:syncrow_web/pages/auth/model/token.dart';
import 'package:syncrow_web/services/api/http_service.dart';
@ -25,8 +24,7 @@ class AuthenticationAPI {
path: ApiEndpoints.forgetPassword,
body: {"email": email, "password": password},
showServerMessage: true,
expectedResponseModel: (json) {
});
expectedResponseModel: (json) {});
return response;
}
@ -64,19 +62,18 @@ class AuthenticationAPI {
}
static Future verifyOtp({required String email, required String otpCode}) async {
final response = await HTTPService().post(
path: ApiEndpoints.verifyOtp,
body: {"email": email, "type": "PASSWORD", "otpCode": otpCode},
showServerMessage: true,
expectedResponseModel: (json) {
if (json['message'] == 'Otp Verified Successfully') {
return true;
} else {
return false;
}
});
return response;
final response = await HTTPService().post(
path: ApiEndpoints.verifyOtp,
body: {"email": email, "type": "PASSWORD", "otpCode": otpCode},
showServerMessage: true,
expectedResponseModel: (json) {
if (json['message'] == 'Otp Verified Successfully') {
return true;
} else {
return false;
}
});
return response;
}
static Future<List<RegionModel>> fetchRegion() async {

View File

@ -1,8 +1,7 @@
import 'package:flutter_dotenv/flutter_dotenv.dart';
abstract class ApiEndpoints {
// static String baseUrl = dotenv.env['BASE_URL'] ?? '';
static String baseUrl = 'https://syncrow-staging.azurewebsites.net';
static String baseUrl = dotenv.env['BASE_URL'] ?? '';
static const String signUp = '/authentication/user/signup';
static const String login = '/authentication/user/login';
static const String forgetPassword = '/authentication/user/forget-password';