forked from firka/student-legacy
finished final summary style and fixed thingies
This commit is contained in:
parent
9314c613bc
commit
4068abdb95
@ -120,51 +120,82 @@ class _AllSumBodyState extends State<AllSumBody> {
|
||||
});
|
||||
}
|
||||
|
||||
void getEverything() {
|
||||
getGrades();
|
||||
getHomework();
|
||||
getSubjects();
|
||||
getAbsences();
|
||||
getDelays();
|
||||
}
|
||||
|
||||
void generateTiles() {
|
||||
for (var i in things.values) {
|
||||
Widget w = Center(
|
||||
child: Column(
|
||||
Widget w = Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
Text(i.values.toList()[1]),
|
||||
Text(i.values.toList()[0]),
|
||||
],
|
||||
Text(
|
||||
i.values.toList()[1].toString(),
|
||||
style: const TextStyle(
|
||||
fontWeight: FontWeight.w800,
|
||||
fontSize: 36.0,
|
||||
color: Colors.white,
|
||||
),
|
||||
),
|
||||
Text(
|
||||
i.values.toList()[0],
|
||||
style: const TextStyle(
|
||||
fontSize: 18.0,
|
||||
color: Colors.white,
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
|
||||
if (i.values.toList()[0] == 'óra') {
|
||||
return; // amig nincs megoldva az osszes ora szamanak lekerese
|
||||
}
|
||||
// TODO: az orakat es a hazikat szarul keri le, de majd meg lesz csinalva
|
||||
if (firstSixTiles.length < 6) {
|
||||
firstSixTiles.add(w);
|
||||
} else {
|
||||
} else if (lastSixTiles.length < 6) {
|
||||
lastSixTiles.add(w);
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
getEverything();
|
||||
generateTiles();
|
||||
|
||||
return Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
GridView.count(
|
||||
const SizedBox(
|
||||
height: 45,
|
||||
),
|
||||
SizedBox(
|
||||
height: 250,
|
||||
child: GridView.count(
|
||||
crossAxisCount: 3,
|
||||
mainAxisSpacing: 10,
|
||||
crossAxisSpacing: 10,
|
||||
mainAxisSpacing: 0,
|
||||
crossAxisSpacing: 5,
|
||||
children: firstSixTiles,
|
||||
),
|
||||
const SizedBox(
|
||||
height: 40,
|
||||
),
|
||||
GridView.count(
|
||||
const SizedBox(
|
||||
height: 30,
|
||||
),
|
||||
SizedBox(
|
||||
height: 250,
|
||||
child: GridView.count(
|
||||
crossAxisCount: 3,
|
||||
mainAxisSpacing: 10,
|
||||
crossAxisSpacing: 10,
|
||||
mainAxisSpacing: 0,
|
||||
crossAxisSpacing: 5,
|
||||
children: lastSixTiles,
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
@ -105,6 +105,8 @@ class _SummaryScreenState extends State<SummaryScreen>
|
||||
Text(
|
||||
'Jó éved volt, $firstName!',
|
||||
textAlign: TextAlign.left,
|
||||
maxLines: 2,
|
||||
overflow: TextOverflow.fade,
|
||||
style: const TextStyle(
|
||||
fontWeight: FontWeight.w900,
|
||||
fontSize: 26.0,
|
||||
@ -118,7 +120,10 @@ class _SummaryScreenState extends State<SummaryScreen>
|
||||
? 'Nézzük a jegyeidet... 📖'
|
||||
: widget.currentPage == 'lessons'
|
||||
? 'A kedvenced órád 💓'
|
||||
: widget.currentPage == 'personality'
|
||||
? 'A te személyiséged...'
|
||||
: '',
|
||||
overflow: TextOverflow.fade,
|
||||
style: const TextStyle(
|
||||
fontWeight: FontWeight.bold,
|
||||
fontSize: 22.0,
|
||||
|
Loading…
x
Reference in New Issue
Block a user