business details empty ui started

This commit is contained in:
vignesh 2022-05-25 14:21:11 +05:30
parent a0a6ba3860
commit c9fda10ec9
6 changed files with 1199 additions and 1053 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 322 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 314 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 201 KiB

View File

@ -285,7 +285,6 @@ class _businesshomeState extends State<businesshome> {
], ],
), ),
), ),
Spacer(),
Row( Row(
children: [ children: [
Padding( Padding(
@ -462,7 +461,6 @@ class _businesshomeState extends State<businesshome> {
), ),
), ),
), ),
Spacer(),
Padding( Padding(
padding: const EdgeInsets.only(left: 15), padding: const EdgeInsets.only(left: 15),
child: InkWell( child: InkWell(
@ -594,7 +592,6 @@ class _businesshomeState extends State<businesshome> {
), ),
), ),
), ),
Spacer(),
Padding( Padding(
padding: const EdgeInsets.only(left: 15), padding: const EdgeInsets.only(left: 15),
child: InkWell( child: InkWell(
@ -729,7 +726,6 @@ class _businesshomeState extends State<businesshome> {
], ],
), ),
), ),
Spacer(),
BottomNavigationBar( BottomNavigationBar(
iconSize: 20, iconSize: 20,
unselectedFontSize: 12, unselectedFontSize: 12,

View File

@ -0,0 +1,91 @@
import 'package:flutter/material.dart';
import 'package:flutter_switch/flutter_switch.dart';
class businessdetailsempty extends StatefulWidget {
const businessdetailsempty({Key? key}) : super(key: key);
@override
State<businessdetailsempty> createState() => _businessdetailsemptyState();
}
bool status = true;
class _businessdetailsemptyState extends State<businessdetailsempty> {
@override
Widget build(BuildContext context) {
return Scaffold(
body: SafeArea(
child: Column(
children: [
Container(
height: 400,
width: double.infinity,
alignment: Alignment.topCenter,
child: Stack(
children: [
Container(
height: 250,
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage('assets/images/bg.png'),
fit: BoxFit.cover),
borderRadius: BorderRadius.only(
bottomLeft: Radius.circular(20),
bottomRight: Radius.circular(20),
),
),
),
Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
FloatingActionButton(
child: Icon(
Icons.arrow_back,
size: 24,
color: Color(0xFF3D3D3D),
),
mini: true,
backgroundColor: Colors.white,
onPressed: () {
Navigator.pop(context);
},
),
Spacer(),
FlutterSwitch(
width: 107,
height: 50,
valueFontSize: 12,
toggleSize: 20,
value: status,
borderRadius: 30.0,
padding: 5,
showOnOff: true,
onToggle: (val) {
setState(() {
status = val;
});
},
activeText: "OPEN",
activeSwitchBorder:
Border.all(color: Colors.white, width: 10),
inactiveSwitchBorder:
Border.all(color: Colors.white, width: 10),
activeTextColor: Colors.white,
activeTextFontWeight: FontWeight.w600,
activeColor: Color(0xFF09CD99),
inactiveText: "CLOSED",
inactiveTextColor: Colors.white,
inactiveTextFontWeight: FontWeight.w600,
inactiveColor: Color(0xFFFF4B4C),
),
],
),
],
),
),
],
),
),
);
}
}

View File

@ -1,5 +1,6 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_switch/flutter_switch.dart'; import 'package:flutter_switch/flutter_switch.dart';
import 'package:openclosenew/14_businessdetailsempty.dart';
import 'package:smooth_page_indicator/smooth_page_indicator.dart'; import 'package:smooth_page_indicator/smooth_page_indicator.dart';
class businessdetail extends StatefulWidget { class businessdetail extends StatefulWidget {
@ -11,32 +12,14 @@ class businessdetail extends StatefulWidget {
class _businessdetailState extends State<businessdetail> class _businessdetailState extends State<businessdetail>
with TickerProviderStateMixin { with TickerProviderStateMixin {
bool status = false; bool status = true;
int pageIndex = 0; int pageIndex = 0;
int _selectedIndex = 0;
void _onItemTapped(int index) {
setState(() {
_selectedIndex = index;
});
}
final _Controller = PageController(); final _Controller = PageController();
Color _textColor = Colors.black;
Color _appBarColor = Color.fromRGBO(36, 41, 46, 1);
Color _scaffoldBgcolor = Colors.white;
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
TabController _tabController = TabController(length: 4, vsync: this); TabController _tabController = TabController(length: 4, vsync: this);
return Theme( return Scaffold(
data: ThemeData(
textTheme: TextTheme(
bodyText1: TextStyle(color: _textColor),
bodyText2: TextStyle(color: _textColor),
),
),
child: Scaffold(
backgroundColor: Colors.white, backgroundColor: Colors.white,
body: SafeArea( body: SafeArea(
child: SingleChildScrollView( child: SingleChildScrollView(
@ -44,10 +27,6 @@ class _businessdetailState extends State<businessdetail>
children: [ children: [
Container( Container(
height: 400, height: 400,
foregroundDecoration: BoxDecoration(
color: status ? null : Colors.grey,
backgroundBlendMode: status ? null : BlendMode.saturation,
),
child: Stack( child: Stack(
children: [ children: [
Container( Container(
@ -62,14 +41,20 @@ class _businessdetailState extends State<businessdetail>
bottomRight: Radius.circular(20), bottomRight: Radius.circular(20),
), ),
), ),
foregroundDecoration: BoxDecoration(
color: status ? null : Colors.grey,
backgroundBlendMode:
status ? null : BlendMode.saturation,
), ),
child: Padding( if (status == false)
padding: const EdgeInsets.only( Container(
left: 10, right: 10, bottom: 120), height: 250,
decoration: BoxDecoration(
color: Colors.grey.withOpacity(0.5),
borderRadius: BorderRadius.only(
bottomLeft: Radius.circular(20),
bottomRight: Radius.circular(20),
),
),
),
Padding(
padding: EdgeInsets.only(bottom: 300),
child: Row( child: Row(
children: [ children: [
FloatingActionButton( FloatingActionButton(
@ -97,15 +82,6 @@ class _businessdetailState extends State<businessdetail>
onToggle: (val) { onToggle: (val) {
setState(() { setState(() {
status = val; status = val;
if (val) {
_textColor = Colors.black;
_scaffoldBgcolor = Colors.white;
} else {
_textColor = Colors.white;
_scaffoldBgcolor = Colors.grey;
}
}); });
}, },
activeText: "OPEN", activeText: "OPEN",
@ -124,13 +100,10 @@ class _businessdetailState extends State<businessdetail>
], ],
), ),
), ),
),
Spacer(),
Align( Align(
alignment: Alignment.center, alignment: Alignment.center,
child: Container( child: Container(
margin: margin: EdgeInsets.only(right: 20, left: 20, top: 150),
EdgeInsets.only(right: 20, left: 20, top: 150),
padding: EdgeInsets.all(12), padding: EdgeInsets.all(12),
height: 270, height: 270,
decoration: BoxDecoration( decoration: BoxDecoration(
@ -148,7 +121,7 @@ class _businessdetailState extends State<businessdetail>
], ],
), ),
foregroundDecoration: BoxDecoration( foregroundDecoration: BoxDecoration(
color: status ? null : Colors.grey, color: status ? null : Colors.white,
backgroundBlendMode: backgroundBlendMode:
status ? null : BlendMode.saturation, status ? null : BlendMode.saturation,
), ),
@ -215,19 +188,21 @@ class _businessdetailState extends State<businessdetail>
color: Colors.black, color: Colors.black,
), ),
onPressed: () { onPressed: () {
Navigator.pop(context); Navigator.push(
context,
MaterialPageRoute(
builder: (_) =>
businessdetailsempty()));
}, },
), ),
], ],
), ),
Spacer(),
Align( Align(
alignment: Alignment.topLeft, alignment: Alignment.topLeft,
child: Padding( child: Padding(
padding: const EdgeInsets.only(left: 10), padding: const EdgeInsets.only(left: 10),
child: Column( child: Column(
crossAxisAlignment: crossAxisAlignment: CrossAxisAlignment.start,
CrossAxisAlignment.start,
children: [ children: [
Row( Row(
children: [ children: [
@ -290,10 +265,8 @@ class _businessdetailState extends State<businessdetail>
" +91 98651 76796, +91 76786 85869", " +91 98651 76796, +91 76786 85869",
style: TextStyle( style: TextStyle(
fontFamily: 'Manrope', fontFamily: 'Manrope',
fontStyle: fontStyle: FontStyle.normal,
FontStyle.normal, fontWeight: FontWeight.w500,
fontWeight:
FontWeight.w500,
fontSize: 12, fontSize: 12,
color: Color(0xFF5C5C5C), color: Color(0xFF5C5C5C),
), ),
@ -397,10 +370,6 @@ class _businessdetailState extends State<businessdetail>
), ),
Container( Container(
height: 100, height: 100,
foregroundDecoration: BoxDecoration(
color: status ? null : Colors.grey,
backgroundBlendMode: status ? null : BlendMode.saturation,
),
child: ListView( child: ListView(
scrollDirection: Axis.horizontal, scrollDirection: Axis.horizontal,
children: [ children: [
@ -424,6 +393,11 @@ class _businessdetailState extends State<businessdetail>
Radius.circular(10), Radius.circular(10),
), ),
), ),
foregroundDecoration: BoxDecoration(
color: status ? null : Colors.white,
backgroundBlendMode:
status ? null : BlendMode.saturation,
),
child: Padding( child: Padding(
padding: const EdgeInsets.only(left: 80), padding: const EdgeInsets.only(left: 80),
child: Column( child: Column(
@ -456,7 +430,6 @@ class _businessdetailState extends State<businessdetail>
), ),
), ),
), ),
Spacer(),
Padding( Padding(
padding: padding:
const EdgeInsets.only(left: 22, right: 10, top: 20), const EdgeInsets.only(left: 22, right: 10, top: 20),
@ -477,6 +450,11 @@ class _businessdetailState extends State<businessdetail>
Radius.circular(10), Radius.circular(10),
), ),
), ),
foregroundDecoration: BoxDecoration(
color: status ? null : Colors.white,
backgroundBlendMode:
status ? null : BlendMode.saturation,
),
child: Padding( child: Padding(
padding: const EdgeInsets.only(left: 80), padding: const EdgeInsets.only(left: 80),
child: Column( child: Column(
@ -516,8 +494,8 @@ class _businessdetailState extends State<businessdetail>
controller: _Controller, // PageController controller: _Controller, // PageController
count: 3, count: 3,
effect: ExpandingDotsEffect( effect: ExpandingDotsEffect(
activeDotColor: Color(0xFF2AB17F), activeDotColor: status ? Color(0xFF2AB17F) : Colors.grey,
dotColor: Colors.greenAccent, dotColor: status ? Colors.greenAccent : Colors.grey,
dotWidth: 5, dotWidth: 5,
dotHeight: 5), dotHeight: 5),
// your preferred effect // your preferred effect
@ -558,7 +536,6 @@ class _businessdetailState extends State<businessdetail>
child: ListView( child: ListView(
scrollDirection: Axis.horizontal, scrollDirection: Axis.horizontal,
children: [ children: [
Spacer(),
Column( Column(
children: [ children: [
Padding( Padding(
@ -608,7 +585,6 @@ class _businessdetailState extends State<businessdetail>
), ),
], ],
), ),
Spacer(),
Column( Column(
children: [ children: [
Padding( Padding(
@ -655,7 +631,6 @@ class _businessdetailState extends State<businessdetail>
), ),
], ],
), ),
Spacer(),
Column( Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
@ -744,7 +719,6 @@ class _businessdetailState extends State<businessdetail>
child: ListView( child: ListView(
scrollDirection: Axis.horizontal, scrollDirection: Axis.horizontal,
children: [ children: [
Spacer(),
Column( Column(
children: [ children: [
Padding( Padding(
@ -766,7 +740,6 @@ class _businessdetailState extends State<businessdetail>
), ),
], ],
), ),
Spacer(),
Column( Column(
children: [ children: [
Padding( Padding(
@ -788,7 +761,6 @@ class _businessdetailState extends State<businessdetail>
), ),
], ],
), ),
Spacer(),
Column( Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
@ -839,21 +811,40 @@ class _businessdetailState extends State<businessdetail>
], ],
), ),
), ),
Align( Container(
alignment: Alignment.centerLeft, foregroundDecoration: BoxDecoration(
child: Padding( color: status ? null : Colors.grey,
padding: const EdgeInsets.only(left: 10, right: 10), backgroundBlendMode: status ? null : BlendMode.saturation,
child: TabBar(
controller: _tabController,
isScrollable: true,
labelPadding: EdgeInsets.symmetric(horizontal: 25),
indicator: BoxDecoration(
borderRadius: BorderRadius.circular(5),
color: Colors.black26,
), ),
tabs: [ height: 150,
Tab( child: ListView(
child: Text( scrollDirection: Axis.horizontal,
children: [
Column(
children: [
Padding(
padding: const EdgeInsets.only(left: 15, right: 15),
child: Container(
width: 130,
height: 100,
decoration: BoxDecoration(
image: const DecorationImage(
fit: BoxFit.cover,
image: AssetImage(
'assets/images/services_img1.png',
),
),
borderRadius:
BorderRadius.all(Radius.circular(5)),
),
),
),
Padding(
padding: const EdgeInsets.only(right: 16),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
"Buffet", "Buffet",
style: TextStyle( style: TextStyle(
fontFamily: 'Manrope', fontFamily: 'Manrope',
@ -863,9 +854,44 @@ class _businessdetailState extends State<businessdetail>
color: Color(0xFF3D3D3D), color: Color(0xFF3D3D3D),
), ),
), ),
Text(
"₹ 480.00 - 890.00",
style: TextStyle(
fontFamily: 'Manrope',
fontStyle: FontStyle.normal,
fontWeight: FontWeight.w600,
fontSize: 12,
color: Color(0xFF3D3D3D),
), ),
Tab( ),
child: Text( ],
),
),
],
),
Column(
children: [
Padding(
padding: const EdgeInsets.only(left: 15, right: 15),
child: Container(
width: 130,
height: 100,
decoration: BoxDecoration(
image: const DecorationImage(
fit: BoxFit.cover,
image: AssetImage(
'assets/images/services_img2.png',
),
),
borderRadius:
BorderRadius.all(Radius.circular(5)),
),
),
),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
"Bar", "Bar",
style: TextStyle( style: TextStyle(
fontFamily: 'Manrope', fontFamily: 'Manrope',
@ -875,33 +901,71 @@ class _businessdetailState extends State<businessdetail>
color: Color(0xFF3D3D3D), color: Color(0xFF3D3D3D),
), ),
), ),
), Text(
Tab( "₹ 200.00 (Starts from)",
child: Text(
"Car Parking",
style: TextStyle( style: TextStyle(
fontFamily: 'Manrope', fontFamily: 'Manrope',
fontStyle: FontStyle.normal, fontStyle: FontStyle.normal,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w600,
fontSize: 15, fontSize: 12,
color: Color(0xFF3D3D3D), color: Color(0xFF3D3D3D),
), ),
), ),
),
Tab(
child: Text(
"Family Room",
style: TextStyle(
fontFamily: 'Manrope',
fontStyle: FontStyle.normal,
fontWeight: FontWeight.w500,
fontSize: 15,
color: Color(0xFF3D3D3D),
),
),
),
], ],
), ),
],
),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: const EdgeInsets.only(left: 15, right: 15),
child: Container(
width: 130,
height: 100,
decoration: BoxDecoration(
image: const DecorationImage(
fit: BoxFit.cover,
image: AssetImage(
'assets/images/services_img3.png',
),
),
borderRadius:
BorderRadius.all(Radius.circular(5)),
),
),
),
Padding(
padding: const EdgeInsets.only(left: 20),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
"Cafe Club",
style: TextStyle(
fontFamily: 'Manrope',
fontStyle: FontStyle.normal,
fontWeight: FontWeight.w500,
fontSize: 15,
color: Color(0xFF3D3D3D),
),
),
Text(
"₹ 280.00",
style: TextStyle(
fontFamily: 'Manrope',
fontStyle: FontStyle.normal,
fontWeight: FontWeight.w600,
fontSize: 12,
color: Color(0xFF3D3D3D),
),
),
],
),
),
],
),
],
), ),
), ),
Padding( Padding(
@ -932,7 +996,7 @@ class _businessdetailState extends State<businessdetail>
), ),
Container( Container(
foregroundDecoration: BoxDecoration( foregroundDecoration: BoxDecoration(
color: status ? null : Colors.grey, color: status ? null : Colors.white,
backgroundBlendMode: status ? null : BlendMode.saturation, backgroundBlendMode: status ? null : BlendMode.saturation,
), ),
height: 100, height: 100,
@ -990,7 +1054,6 @@ class _businessdetailState extends State<businessdetail>
), ),
), ),
), ),
Spacer(),
Padding( Padding(
padding: const EdgeInsets.only(left: 22), padding: const EdgeInsets.only(left: 22),
child: InkWell( child: InkWell(
@ -1118,8 +1181,7 @@ class _businessdetailState extends State<businessdetail>
), ),
), ),
Padding( Padding(
padding: padding: const EdgeInsets.only(left: 15),
const EdgeInsets.only(left: 15),
child: Image.asset( child: Image.asset(
'assets/images/ticket1.png', 'assets/images/ticket1.png',
width: 25, width: 25,
@ -1144,7 +1206,6 @@ class _businessdetailState extends State<businessdetail>
), ),
), ),
), ),
Spacer(),
Padding( Padding(
padding: const EdgeInsets.only(left: 22, right: 10), padding: const EdgeInsets.only(left: 22, right: 10),
child: InkWell( child: InkWell(
@ -1183,8 +1244,7 @@ class _businessdetailState extends State<businessdetail>
), ),
), ),
Padding( Padding(
padding: padding: const EdgeInsets.only(left: 15),
const EdgeInsets.only(left: 15),
child: Image.asset( child: Image.asset(
'assets/images/ticket1.png', 'assets/images/ticket1.png',
width: 25, width: 25,
@ -1216,7 +1276,6 @@ class _businessdetailState extends State<businessdetail>
), ),
), ),
), ),
),
); );
} }
} }