|
@@ -0,0 +1,189 @@
|
|
|
+import 'package:flutter/material.dart';
|
|
|
+import 'dart:math' as math;
|
|
|
+import 'package:luojigou_thinking_core/src/view/student_info_list_view.dart';
|
|
|
+import 'package:luojigou_thinking_core/src/data/data_management.dart';
|
|
|
+
|
|
|
+// 综合评估报告&单次评估报告
|
|
|
+class ComprehensiveEvaluationReportPage extends StatelessWidget {
|
|
|
+ @override
|
|
|
+ Widget build(BuildContext context) {
|
|
|
+ return Scaffold(
|
|
|
+ body: MediaQuery.removePadding(
|
|
|
+ context: context,
|
|
|
+ removeTop: true,
|
|
|
+ child: Container(
|
|
|
+ decoration: BoxDecoration(
|
|
|
+ gradient: LinearGradient(
|
|
|
+ colors: [Color(0xFFBFD6FF), Color(0xFFFEFEFE)],
|
|
|
+ begin: Alignment.topLeft,
|
|
|
+ end: Alignment.bottomRight,
|
|
|
+ stops: [0, 0.5],
|
|
|
+ )),
|
|
|
+ child: Column(
|
|
|
+ children: [
|
|
|
+ AppNavBar(context),
|
|
|
+ SizedBox(height: 17),
|
|
|
+ HeaderView(context),
|
|
|
+ Expanded(
|
|
|
+ child: ContentList(),
|
|
|
+ ),
|
|
|
+ SizedBox(height: 58)
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Container ContentList() {
|
|
|
+ return Container(
|
|
|
+ margin: EdgeInsets.symmetric(horizontal: 18),
|
|
|
+ padding: EdgeInsets.symmetric(horizontal: 15),
|
|
|
+ decoration: BoxDecoration(color: Color(0xFFFFFFFF), borderRadius: BorderRadius.circular(15), boxShadow: [BoxShadow(color: Color(0xB3BFD8FF), offset: Offset(0, 2), blurRadius: 20, spreadRadius: 0)]),
|
|
|
+ child: Column(
|
|
|
+ children: [
|
|
|
+ SizedBox(height: 18),
|
|
|
+ Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ children: [
|
|
|
+ Row(
|
|
|
+ children: [
|
|
|
+ Image.asset("assets/thinking_core/class_icon.png", width: 18, height: 18),
|
|
|
+ SizedBox(width: 9.5),
|
|
|
+ Text("逻辑狗中1班", style: TextStyle(fontSize: 18, height: 22 / 18, fontWeight: FontWeight.w600)),
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ Text("已评估(13人)", style: TextStyle(color: Color(0xFF666666), fontSize: 16, height: 22.5 / 18, fontWeight: FontWeight.w400))
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ SizedBox(height: 10),
|
|
|
+ SendToParentsWidget(),
|
|
|
+ Expanded(child: StudentInfoListView(accessoryViewType: AssessAccessoryViewType.Send)),
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Container HeaderView(BuildContext context) {
|
|
|
+ return Container(
|
|
|
+ margin: EdgeInsets.symmetric(horizontal: 18),
|
|
|
+ width: MediaQuery.of(context).size.width,
|
|
|
+ height: (MediaQuery.of(context).size.width - 36) * 179 / 339,
|
|
|
+ child: Stack(
|
|
|
+ fit: StackFit.expand,
|
|
|
+ children: [
|
|
|
+ Image.asset(
|
|
|
+ "assets/thinking_core/comprehensive_evaluat_on_record.png",
|
|
|
+ ),
|
|
|
+ Column(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
+ children: [
|
|
|
+ Column(
|
|
|
+ crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
+ children: [
|
|
|
+ SizedBox(height: 22 * (MediaQuery.of(context).size.width - 36) * 179 / 339 / 179),
|
|
|
+ Padding(padding: EdgeInsets.only(left: 19), child: Text("思维芯游戏", style: TextStyle(color: Colors.white, fontSize: 21, height: 29.5 / 21, fontWeight: FontWeight.w600))),
|
|
|
+ SizedBox(height: 7 * (MediaQuery.of(context).size.width - 36) * 179 / 339 / 179),
|
|
|
+ Padding(padding: EdgeInsets.only(left: 19), child: Text("学期综合发展评估", style: TextStyle(color: Colors.white, fontSize: 21, height: 29.5 / 21, fontWeight: FontWeight.w600))),
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ Padding(padding: EdgeInsets.only(left: 19, bottom: 49 * (MediaQuery.of(context).size.width - 36) * 179 / 339 / 179), child: Text("生成时间:2021.2.3", style: TextStyle(color: Colors.white, fontSize: 11, height: 15 / 11, fontWeight: FontWeight.w500))),
|
|
|
+ ],
|
|
|
+ )
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Container AppNavBar(BuildContext context) {
|
|
|
+ return Container(
|
|
|
+ width: MediaQuery.of(context).size.width,
|
|
|
+ height: MediaQuery.of(context).padding.top + 44,
|
|
|
+ alignment: Alignment.bottomLeft,
|
|
|
+ child: Row(
|
|
|
+ children: [
|
|
|
+ Container(
|
|
|
+ color: Colors.transparent,
|
|
|
+ padding: EdgeInsets.symmetric(horizontal: 18, vertical: 15),
|
|
|
+ child: Image.asset(
|
|
|
+ "assets/thinking_core/back.png",
|
|
|
+ width: 10.5,
|
|
|
+ height: 19,
|
|
|
+ )),
|
|
|
+ Expanded(
|
|
|
+ child: Text(
|
|
|
+ "综合评估记录",
|
|
|
+ textAlign: TextAlign.center,
|
|
|
+ style: TextStyle(color: Colors.black, fontSize: 18, height: 25 / 18, fontWeight: FontWeight.w600),
|
|
|
+ )),
|
|
|
+ Padding(
|
|
|
+ padding: EdgeInsets.symmetric(horizontal: 18, vertical: 15),
|
|
|
+ child: SizedBox(width: 10.5),
|
|
|
+ )
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+// 发送给家长
|
|
|
+class SendToParentsWidget extends StatelessWidget {
|
|
|
+ @override
|
|
|
+ Widget build(BuildContext context) {
|
|
|
+ return Container(
|
|
|
+ width: double.infinity,
|
|
|
+ height: 42,
|
|
|
+ padding: EdgeInsets.only(left: 10, right: 15),
|
|
|
+ decoration: BoxDecoration(
|
|
|
+ gradient: LinearGradient(colors: [Color(0xFFEBF1FF), Color(0xFFDCE6FF)]),
|
|
|
+ borderRadius: BorderRadius.circular(6),
|
|
|
+ ),
|
|
|
+ child: CustomPaint(
|
|
|
+ size: Size(36, 42),
|
|
|
+ painter: SendToParentsPainter(),
|
|
|
+ child: Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ children: [
|
|
|
+ Text("有12份家园共育策略未发送给家长", style: TextStyle(color: Color(0xFF666666), fontSize: 12, height: 16.5 / 12, fontWeight: FontWeight.w400)),
|
|
|
+ GestureDetector(
|
|
|
+ child: Container(
|
|
|
+ width: 84,
|
|
|
+ height: 25,
|
|
|
+ alignment: Alignment.center,
|
|
|
+ decoration: BoxDecoration(
|
|
|
+ color: Color(0xFF5F87F0),
|
|
|
+ borderRadius: BorderRadius.circular(12.5),
|
|
|
+ ),
|
|
|
+ child: Text("发给家长", style: TextStyle(color: Color(0xFFFFFFFF), fontSize: 12, height: 16.5 / 12, fontWeight: FontWeight.w400)),
|
|
|
+ ),
|
|
|
+ )
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class SendToParentsPainter extends CustomPainter {
|
|
|
+ @override
|
|
|
+ void paint(Canvas canvas, Size size) {
|
|
|
+ final paint = Paint()
|
|
|
+ ..color = Colors.transparent
|
|
|
+ ..style = PaintingStyle.fill;
|
|
|
+ canvas.drawRRect(RRect.fromLTRBR(0, 0, size.width, size.height, Radius.circular(5)), paint);
|
|
|
+ final path = Path();
|
|
|
+ path.addRRect(RRect.fromRectAndRadius(Rect.fromLTWH(0, 0, 12, 12), Radius.circular(3)));
|
|
|
+ canvas.save();
|
|
|
+ canvas.translate(42, -8);
|
|
|
+ canvas.rotate(math.pi / 4);
|
|
|
+ canvas.drawPath(path, paint..color = Color(0xFFEBF1FF));
|
|
|
+ canvas.restore();
|
|
|
+ }
|
|
|
+
|
|
|
+ @override
|
|
|
+ bool shouldRepaint(covariant CustomPainter oldDelegate) {
|
|
|
+ // TODO: implement shouldRepaint
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+}
|