Files
rkm_educa_prof_app/lib/componentes/item_aluno_nota.dart

65 lines
2.1 KiB
Dart

import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:rkm_educa_prof_app/componentes/text_custom.dart';
import 'package:rkm_educa_prof_app/modelos/modelo_nota_aluno.dart';
import '../modelos/modelo_presenca_aluno.dart';
import '../utils/cores.dart';
import '../utils/dimensoes.dart';
class ItemAlunoNota extends StatelessWidget {
bool edit;
var onChanged;
ModeloNotaAluno aluno;
ItemAlunoNota({
required this.edit,
required this.onChanged,
required this.aluno
});
@override
Widget build(BuildContext context) {
return Column(
mainAxisSize: MainAxisSize.min,
children: [
Row(
children: [
Container(
width: 30,
child: TextCustom(text: aluno.NR_TURMA,size: 12.0, fontWeight: FontWeight.bold)),
TextCustom(text: aluno.NO_ALUNO,size: 12.0, fontWeight: FontWeight.bold),
Spacer(),
aluno.STATUS!='MATRICULADO'?
Container(
margin: EdgeInsets.symmetric(vertical: 5),
child: TextCustom(text: 'TRANSFERIDO', size: 12.0, fontWeight: FontWeight.bold,color: Colors.red,)):
Container(
margin: EdgeInsets.symmetric(vertical: 5),
color: PaletaCores.cinzaInput,
width: 50,
height: 25,
child: TextFormField(
enabled: edit,
inputFormatters: [
FilteringTextInputFormatter.digitsOnly,
],
controller: aluno.NOTA,
keyboardType: TextInputType.numberWithOptions(decimal: true),
decoration: InputDecoration(
border: OutlineInputBorder(
borderSide: BorderSide(width: 1, color: Colors.black12),
),
),
onChanged: onChanged,
),
)
],
),
aluno.AVISO==''?Container()
:TextCustom(text: aluno.AVISO,fontWeight: FontWeight.bold, color: Colors.red,textAlign: TextAlign.start,)
],
);
}
}