commit for release
parent
5b8a67131f
commit
c4fd2d9bd8
|
@ -31,9 +31,9 @@ class BasicInfo extends StatelessWidget {
|
||||||
child: ProgressHUD(
|
child: ProgressHUD(
|
||||||
child: BlocBuilder<UserBloc, UserState>(
|
child: BlocBuilder<UserBloc, UserState>(
|
||||||
builder: (context, state) {
|
builder: (context, state) {
|
||||||
|
|
||||||
if (state is UserLoggedIn) {
|
if (state is UserLoggedIn) {
|
||||||
String fileUrl = '${Url.instance.prefixHost()}://${Url.instance.host()}/media/${ state.userData!.employeeInfo!.profile!.photoPath!}';
|
String fileUrl =
|
||||||
|
'${Url.instance.prefixHost()}://${Url.instance.host()}/media/${state.userData?.employeeInfo?.profile?.photoPath}';
|
||||||
state.userData!.employeeInfo!.profile!.sex!.toUpperCase();
|
state.userData!.employeeInfo!.profile!.sex!.toUpperCase();
|
||||||
return SafeArea(
|
return SafeArea(
|
||||||
child: Scaffold(
|
child: Scaffold(
|
||||||
|
@ -51,21 +51,37 @@ class BasicInfo extends StatelessWidget {
|
||||||
child: Stack(
|
child: Stack(
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
children: [
|
children: [
|
||||||
|
|
||||||
CachedNetworkImage(
|
CachedNetworkImage(
|
||||||
imageUrl: fileUrl,
|
imageUrl: fileUrl,
|
||||||
imageBuilder: (context, imageProvider) => Container(
|
imageBuilder: (context, imageProvider) =>
|
||||||
|
Container(
|
||||||
width: 160,
|
width: 160,
|
||||||
height: 160,
|
height: 160,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
border: Border.all(color: third,width: 3),
|
border:
|
||||||
|
Border.all(color: Colors.black26, width: 3),
|
||||||
shape: BoxShape.circle,
|
shape: BoxShape.circle,
|
||||||
image: DecorationImage(
|
image: DecorationImage(
|
||||||
image: imageProvider, fit: BoxFit.cover),
|
image: imageProvider,
|
||||||
|
fit: BoxFit.cover),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
placeholder: (context, url) =>
|
||||||
|
const CircularProgressIndicator(),
|
||||||
|
errorWidget: (context, url, error) =>
|
||||||
|
Container(
|
||||||
|
width: 160,
|
||||||
|
height: 160,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
border:
|
||||||
|
Border.all(color: Colors.white, width: 3),
|
||||||
|
shape: BoxShape.circle,
|
||||||
|
|
||||||
|
),
|
||||||
|
child: SvgPicture.asset(
|
||||||
|
'assets/svgs/male.svg',
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
placeholder: (context, url) => const CircularProgressIndicator(),
|
|
||||||
errorWidget: (context, url, error) =>const Icon(Icons.error),
|
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|
Loading…
Reference in New Issue