Skip to content
This repository was archived by the owner on Mar 3, 2021. It is now read-only.

Commit c9b4277

Browse files
committed
Adequação de exibição de boletim
1 parent ca1df30 commit c9b4277

17 files changed

+183
-149
lines changed

src/app/app-routing.module.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,12 @@ const routes: Routes = [
4040
loadChildren: './pages/mensagens-details/mensagens-details.module#MensagensDetailsPageModule'
4141
},
4242
{
43-
path: 'boletim',
44-
loadChildren: './pages/boletim/boletim.module#BoletimPageModule'
43+
path: 'boletim-trimestre',
44+
loadChildren: './pages/boletim-trimestre/boletim-trimestre.module#BoletimTrimestrePageModule'
4545
},
4646
{
47-
path: 'boletim-details',
48-
loadChildren: './pages/boletim-details/boletim-details.module#BoletimDetailsPageModule'
47+
path: 'boletim-trimestre-disciplina',
48+
loadChildren: './pages/boletim-trimestre-disciplina/boletim-trimestre-disciplina.module#BoletimTrimestreDisciplinaPageModule'
4949
},
5050
{
5151
path: 'ativ-aval-disc',

src/app/models/boletim.dto.ts

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
export interface BoletimDTO {
2+
qtdFaltas: number;
3+
tipoAvaliacao: string;
4+
resultado: string;
5+
descricao: string;
6+
nota: number;
7+
notaRec: number;
8+
periodo: number;
29
disciplina: string;
3-
notaTrim1: string;
4-
notaTrim2: string;
5-
notaTrim3: string;
6-
faltasTrim1: string;
7-
faltasTrim2: string;
8-
faltasTrim3: string;
9-
notaAnual: string;
10-
totalFaltas: string;
1110
}

src/app/pages/aluno/aluno.page.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ export class AlunoPage implements OnInit {
6868

6969
openBoletimPage(codTurmAlun) {
7070
this.data.storage = { codTurmAlun };
71-
this.router.navigate(["boletim"]);
71+
this.router.navigate(["boletim-trimestre"]);
7272
}
7373

7474
openFrequenciaPage(codTurmAlun) {

src/app/pages/boletim-details/boletim-details.page.html

Lines changed: 0 additions & 81 deletions
This file was deleted.

src/app/pages/boletim-details/boletim-details.page.scss

Whitespace-only changes.

src/app/pages/boletim-details/boletim-details.page.ts

Lines changed: 0 additions & 18 deletions
This file was deleted.

src/app/pages/boletim/boletim.module.ts renamed to src/app/pages/boletim-trimestre-disciplina/boletim-trimestre-disciplina.module.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { NgModule } from "@angular/core";
22
import { RouterModule } from "@angular/router";
33
import { IonicModule } from "@ionic/angular";
44

5-
import { BoletimPage } from "./boletim.page";
5+
import { BoletimTrimestreDisciplinaPage } from "./boletim-trimestre-disciplina.page";
66
import { CommonModule } from "@angular/common";
77
import { FormsModule } from "@angular/forms";
88

@@ -11,8 +11,8 @@ import { FormsModule } from "@angular/forms";
1111
CommonModule,
1212
FormsModule,
1313
IonicModule,
14-
RouterModule.forChild([{ path: "", component: BoletimPage }])
14+
RouterModule.forChild([{ path: "", component: BoletimTrimestreDisciplinaPage }])
1515
],
16-
declarations: [BoletimPage]
16+
declarations: [BoletimTrimestreDisciplinaPage]
1717
})
18-
export class BoletimPageModule {}
18+
export class BoletimTrimestreDisciplinaPageModule {}
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
<ion-header>
2+
<ion-toolbar color="primary">
3+
<ion-title>{{ trimestre }}º Trimestre</ion-title>
4+
<ion-buttons slot="start">
5+
<ion-back-button defaultHref="frequencia"> </ion-back-button>
6+
</ion-buttons>
7+
</ion-toolbar>
8+
</ion-header>
9+
10+
<ion-content padding>
11+
<ion-grid>
12+
<ion-row>
13+
<ion-col>
14+
<ion-card no-margin margin-bottom class="full-width">
15+
<ion-item class="border-bottom" text-wrap>
16+
<ion-label text-wrap>Ano Letivo: {{ anoLetivo }}</ion-label>
17+
</ion-item>
18+
</ion-card>
19+
</ion-col>
20+
</ion-row>
21+
<ion-row>
22+
<ion-col>
23+
<ion-list>
24+
<ion-item
25+
*ngFor="let item of boletim"
26+
class="item ios in-list ion-focusable item-label hydrated"
27+
>
28+
<ion-label
29+
class="sc-ion-label-ios-h sc-ion-label-ios-s ios hydrated"
30+
text-wrap
31+
>
32+
<h2>Disciplina: {{ item.disciplina }}</h2>
33+
<h3>
34+
Nota:
35+
{{
36+
item.notaRec && item.notaRec > item.nota
37+
? item.notaRec
38+
: item.nota
39+
}}
40+
</h3>
41+
<h3 style="color: red;">Faltas: {{ item.qtdFaltas }}</h3>
42+
<!-- <p style="text-align: justify">Conteúdo: {{ aula.conteudo }}</p> -->
43+
</ion-label>
44+
</ion-item>
45+
</ion-list>
46+
</ion-col>
47+
</ion-row>
48+
</ion-grid>
49+
</ion-content>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
ion-card {
2+
ion-item {
3+
--inner-border-width: 0;
4+
}
5+
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
import { BoletimDTO } from "../../models/boletim.dto";
2+
import { Component, OnInit } from "@angular/core";
3+
import { DataProvider } from "src/app/providers/data.provider";
4+
import { environment } from "src/environments/environment";
5+
6+
@Component({
7+
selector: "app-boletim-trimestre-disciplina",
8+
templateUrl: "boletim-trimestre-disciplina.page.html",
9+
styleUrls: ["./boletim-trimestre-disciplina.page.scss"]
10+
})
11+
export class BoletimTrimestreDisciplinaPage implements OnInit {
12+
boletim: BoletimDTO[];
13+
trimestre: number;
14+
anoLetivo = environment.ano;
15+
16+
constructor(private dataProvider: DataProvider) {
17+
this.boletim = this.dataProvider.storage.listNotas;
18+
this.trimestre = this.dataProvider.storage.trimestre;
19+
}
20+
21+
async ngOnInit() {}
22+
}

0 commit comments

Comments
 (0)