Commit b7ce82a7 authored by Inomjon's avatar Inomjon

App ga chat funcsiyasi qo'shlishi boshlandi

parent e197b2ff
...@@ -10,6 +10,7 @@ import '../../blocs/user_login_bloc/user_log_in_bloc.dart'; ...@@ -10,6 +10,7 @@ import '../../blocs/user_login_bloc/user_log_in_bloc.dart';
import '../../src/controllers/enter_number_cont.dart'; import '../../src/controllers/enter_number_cont.dart';
import '../../src/login_screen.dart'; import '../../src/login_screen.dart';
import '../../views/edit_profile_view/edit_profile_page.dart'; import '../../views/edit_profile_view/edit_profile_page.dart';
import '../../views/reset_password_view/reset_password_page.dart';
import '../../views/signin_view/signin_page.dart'; import '../../views/signin_view/signin_page.dart';
import '../../views/signup_view/signup_page.dart'; import '../../views/signup_view/signup_page.dart';
import '../../views/splash_view/splash_screen.dart'; import '../../views/splash_view/splash_screen.dart';
...@@ -46,6 +47,9 @@ class MainNavigator extends StatelessWidget { ...@@ -46,6 +47,9 @@ class MainNavigator extends StatelessWidget {
case MainRoutes.main_page: case MainRoutes.main_page:
builder = (BuildContext _) => MainPage(controller: controller); builder = (BuildContext _) => MainPage(controller: controller);
break; break;
case MainRoutes.reset_password_page:
builder = (BuildContext _) => ResetPasswordPage(controller: controller);
break;
case MainRoutes.user_signup_page: case MainRoutes.user_signup_page:
builder = (BuildContext _) => MultiBlocProvider( builder = (BuildContext _) => MultiBlocProvider(
providers: [ providers: [
......
...@@ -7,4 +7,5 @@ class MainRoutes { ...@@ -7,4 +7,5 @@ class MainRoutes {
static const String sign_in_page = "sign_in_page"; static const String sign_in_page = "sign_in_page";
static const String old_sign_in = "old_sign_in"; static const String old_sign_in = "old_sign_in";
static const String edit_profile_page = "edit_profile_page"; static const String edit_profile_page = "edit_profile_page";
static const String reset_password_page = "reset_password_page";
} }
\ No newline at end of file
...@@ -79,6 +79,7 @@ class _DrawerMenueState extends State<DrawerMenue> { ...@@ -79,6 +79,7 @@ class _DrawerMenueState extends State<DrawerMenue> {
size: 30, size: 30,
), ),
onTap: () async { onTap: () async {
Navigator.pushNamed(context, MainRoutes.reset_password_page);
}, },
), ),
const Spacer(), const Spacer(),
......
...@@ -158,11 +158,11 @@ class _HomePageState extends State<HomePage> { ...@@ -158,11 +158,11 @@ class _HomePageState extends State<HomePage> {
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
SmallText(text: appUsersModel.user?.fullName ?? "",fontWidget: FontWeight.bold,), SmallText(text: appUsersModel.user?.fullName ?? "",fontWidget: FontWeight.bold,),
SizedBox(height: context.h*0.005), SizedBox(height: context.h*0.001),
SmallText(text: appUsersModel.user?.email ?? "", size: context.h*0.017), SmallText(text: appUsersModel.user?.email ?? "", size: context.h*0.017),
SizedBox(height: context.h*0.005), SizedBox(height: context.h*0.001),
SmallText(text: appUsersModel.user?.phone ?? ""), SmallText(text: appUsersModel.user?.phone ?? ""),
SizedBox(height: context.h*0.005), SizedBox(height: context.h*0.001),
SmallText(text: appUsersModel.user?.id.toString() ?? ""), SmallText(text: appUsersModel.user?.id.toString() ?? ""),
], ],
), ),
......
import 'package:connectycube_sdk/connectycube_calls.dart';
import 'package:flutter/material.dart';
import 'package:vmeeting/src/extension/context_extensions.dart';
import 'package:vmeeting/src/widgets/big_text_widget.dart';
import '../../src/constants/colors_const.dart';
import '../../src/controllers/enter_number_cont.dart';
import '../../src/utils/app_utils.dart';
import '../../src/widgets/textfiled_widgets/auth_text_fild.dart';
class ResetPasswordPage extends StatefulWidget {
final NumberController controller;
const ResetPasswordPage({super.key, required this.controller});
@override
State<ResetPasswordPage> createState() => _ResetPasswordPageState();
}
class _ResetPasswordPageState extends State<ResetPasswordPage> {
final _emailControlle = TextEditingController(text: AppUtils.userModel.email);
final _emailFocusNode = FocusNode();
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: const BigText(text: "Chage Password"),
),
body: buildUI(),
);
}
Widget buildUI(){
return Container(
margin: EdgeInsets.symmetric(horizontal: context.w * 0.06),
child: Column(
children: [
SizedBox(height: context.h*0.2),
AuthTextFild(
lableName: "Email",
borderRadius: 10,
elevation: 1,
color: Colors.grey.withOpacity(0.2),
type: TextInputType.emailAddress,
focusNode: _emailFocusNode,
textEditingController: _emailControlle,
),
SizedBox(height: context.h*0.1),
buildButtons(),
],
),
);
}
Future<dynamic>resetPasswordUser(String emile) async {
return await resetPassword(emile)
.then((voidResult) {
print("Shu yerga keldi");
})
.catchError((error) {
print("Shu yerga keldi");
});
}
Widget buildButtons() {
return StreamBuilder(stream: widget.controller.outputElevatedButton,
builder: (BuildContext context, snapshot){
return Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
ElevatedButton(
style: ElevatedButton.styleFrom(
foregroundColor: Colors.white,
backgroundColor: ColorConst.appGreenColor,
disabledForegroundColor: Colors.grey.withOpacity(0.38),
disabledBackgroundColor: Colors.grey.withOpacity(0.12),
),
onPressed: () async {
if( _emailControlle.text.isNotEmpty){
widget.controller.inputElevatedButton.add(true);
final resetPasswordUse = await resetPasswordUser(_emailControlle.text);
widget.controller.inputElevatedButton.add(false);
print(resetPasswordUse);
}else{
AppUtils.showSnackBar(context, "PLEASE ENTER THE SAME VALUE AGAIN");
}
},
child: SizedBox(
height: context.h * 0.06,
child: Center(
child: snapshot.data ?? false
? AppUtils.buttonLoader
: BigText(
text: "Chage".toUpperCase(),
fontWidget: FontWeight.bold,
size: 16,
),
),
),
),
],
);
});
}
}
...@@ -61,10 +61,10 @@ packages: ...@@ -61,10 +61,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: collection name: collection
sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.17.2" version: "1.18.0"
connectycube_flutter_call_kit: connectycube_flutter_call_kit:
dependency: "direct main" dependency: "direct main"
description: description:
...@@ -476,10 +476,10 @@ packages: ...@@ -476,10 +476,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: meta name: meta
sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" sha256: a6e590c838b18133bb482a2745ad77c5bb7715fb0451209e1a7567d416678b8e
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.9.1" version: "1.10.0"
mime: mime:
dependency: transitive dependency: transitive
description: description:
...@@ -761,18 +761,18 @@ packages: ...@@ -761,18 +761,18 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: stack_trace name: stack_trace
sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.11.0" version: "1.11.1"
stream_channel: stream_channel:
dependency: transitive dependency: transitive
description: description:
name: stream_channel name: stream_channel
sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.1" version: "2.1.2"
string_scanner: string_scanner:
dependency: transitive dependency: transitive
description: description:
...@@ -801,10 +801,10 @@ packages: ...@@ -801,10 +801,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: test_api name: test_api
sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "0.6.0" version: "0.6.1"
tuple: tuple:
dependency: transitive dependency: transitive
description: description:
...@@ -945,10 +945,10 @@ packages: ...@@ -945,10 +945,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: web name: web
sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 sha256: afe077240a270dcfd2aafe77602b4113645af95d0ad31128cc02bce5ac5d5152
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "0.1.4-beta" version: "0.3.0"
web_browser_detect: web_browser_detect:
dependency: "direct main" dependency: "direct main"
description: description:
...@@ -1014,5 +1014,5 @@ packages: ...@@ -1014,5 +1014,5 @@ packages:
source: hosted source: hosted
version: "0.4.4-dev.4" version: "0.4.4-dev.4"
sdks: sdks:
dart: ">=3.1.3 <4.0.0" dart: ">=3.2.0-194.0.dev <4.0.0"
flutter: ">=3.13.0" flutter: ">=3.13.0"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment