Commit fbf3a432 authored by GayaniPKarunaratne's avatar GayaniPKarunaratne

Merge branch 'EAnalyzer_KarunaratneGP' of http://gitlab.sliit.lk/2021-035/2021-035-covidefender

parents 6a19c2e5 b9f32b97
import 'package:flutter/material.dart';
class EAnalyzerDash extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text("EAnalyzer DashBoard"),
),
body: Stack(
children: <Widget>[
Container(
decoration: BoxDecoration(
image: DecorationImage(
alignment: Alignment.topCenter,
image: AssetImage('lib/assets/images/green.jpg'),
))),
SafeArea(
child: Padding(
padding: EdgeInsets.all(16.0),
child: Column(
children: <Widget>[
Container(
height: 64,
margin: EdgeInsets.only(bottom: 20),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
CircleAvatar(
radius: 32,
backgroundColor: Colors.transparent,
backgroundImage: AssetImage('lib/assets/images/eana.png'),
),
SizedBox(
width: 16,
),
Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Text('EAnalyzer', style: TextStyle(fontSize: 35.0, color: Colors.white)),
],
)
],
),
),
Expanded(
child: GridView.count(
mainAxisSpacing: 10,
crossAxisSpacing: 10,
primary: false,
crossAxisCount: 2,
children: <Widget>[
Card(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8)),
elevation: 4,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
FlatButton(
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => EAnalyzerDash()),
);
},
child: Image.asset('lib/assets/images/event80.png'),
),
Text('Event Risk Analyzer', style: TextStyle(fontSize: 20.0))
],
)
),
Card(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8)),
elevation: 4,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
FlatButton(
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => EAnalyzerDash()),
);
},
child: Image.asset('lib/assets/images/event80.png'),
),
Text('Event Risk Analyzer', style: TextStyle(fontSize: 20.0))
],
)
),
Card(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8)),
elevation: 4,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
FlatButton(
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => EAnalyzerDash()),
);
},
child: Image.asset('lib/assets/images/event80.png'),
),
Text('Event Risk Analyzer', style: TextStyle(fontSize: 20.0))
],
)
),
Card(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8)),
elevation: 4,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
FlatButton(
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => EAnalyzerDash()),
);
},
child: Image.asset('lib/assets/images/event80.png'),
),
Text('Event Risk Analyzer', style: TextStyle(fontSize: 20.0))
],
)
),
],
),
)
],
),
),
)
],
),
);
}
}
\ No newline at end of file
import 'package:flutter/material.dart';
import 'EAnalyzerDash.dart';
class HomeScreen extends StatefulWidget {
_HomeScreenState createState() => _HomeScreenState();
......@@ -9,17 +10,20 @@ class _HomeScreenState extends State<HomeScreen> {
var size = MediaQuery.of(context).size;
return Scaffold(
appBar: AppBar(
leading: IconButton(icon: Icon(Icons.menu),onPressed: (){
leading: IconButton(icon: Icon(Icons.menu),
tooltip: 'Navigation menu',
onPressed: (){
}),
title: Text("CoviDefender Dashboard"),
actions: <Widget>[
IconButton(icon: Icon(Icons.search),onPressed: (){
IconButton(icon: Icon(Icons.search),
tooltip: 'Search',
onPressed: (){
}),
],
),
body: Stack(
children: <Widget>[
Container(
......@@ -158,14 +162,20 @@ class _HomeScreenState extends State<HomeScreen> {
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
Container(
height: size.height * .1,
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage(
'lib/assets/images/event80.png')),
)),
FlatButton(
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => EAnalyzerDash()),
);
},
child: Image.asset('lib/assets/images/event80.png'),
),
Text('Event Risk Analyzer', style: TextStyle(fontSize: 20.0))
// onPressed: (){
// Navigator.push(context,
// MaterialPageRoute(builder: (context)=>EAnalyzerDash()),
// );
],
)
),
......
......@@ -48,14 +48,14 @@ flutter:
assets:
- lib/assets/images/top_header.jpg
- lib/assets/images/mino.jpg
- lib/assets/images/boralu.jpg
- lib/assets/images/green.jpg
- lib/assets/images/map80.png
- lib/assets/images/man80.png
- lib/assets/images/bar80.png
- lib/assets/images/coach80.png
- lib/assets/images/time80.png
- lib/assets/images/event80.png
- lib/assets/images/eana.png
# To add assets to your application, add an assets section, like this:
# assets:
......
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