-
Notifications
You must be signed in to change notification settings - Fork 0
/
crud.h
134 lines (126 loc) · 4.28 KB
/
crud.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
#define PROJETO_SISTEMA_SAUDE_TRABALHO_FUNCS_H
#include "utilidades.h"
#include <stdio.h>
#include <stdlib.h>
#define MAX_PACIENTES 100
#define MAX_ATENDIMENTOS 100
// PROTOTYPES FOR REFERENCE
int adicionarPaciente
(
int codigosPacientes[],
char nomes[][50],
char generos[][10],
char RGs[][15],
char CPFs[][15],
char tiposSanguineos[][5],
char fatoresRH[],
char enderecos[][100],
char datasNascimento[][11],
int idades[],
int proximoCodigoPaciente,
int totalPacientes
);
int adicionarAtendimento
(
int codigosAtendimentos[],
int codigosPacientes[],
char tipos[][20],
char datasAtendimento[][11],
char status[][50],
float precos[],
int totalAtendimentos,
int totalPacientes
);
void exibirInformacoesPaciente
(
int codigosPacientes[], char nomes[][50],
char RGs[][15], char CPFs[][15],
char tiposSanguineos[][5], char fatoresRH[],
char enderecos[][100], char datasNascimento[][11],
int idades[], int totalPacientes
);
void exibirAtendimentos
(
int codigosAtendimentos[], int codigosPacientes[],
char tipos[][20], char datasAtendimento[][11],
char status[][50], float precos[],
int totalAtendimentos
);
int removerPaciente
(
int codigosPacientes[],char nomes[][50],
char RGs[][15],char CPFs[][15],
char tiposSanguineos[][5],char fatoresRH[],
char enderecos[][100],char datasNascimento[][11],
int idades[],int totalPacientes
);
int removerAtendimento
(
int codigosAtendimentos[],char status[][50],
int totalAtendimentos
);
void exibirAtendimentos
(
int codigosAtendimentos[], int codigosPacientes[],
char tipos[][20], char datasAtendimento[][11],
char status[][50], float precos[],
int totalAtendimentos
);
void listarPacientesComInformacoes
(
int codigosPacientes[],
char nomes[][50],
int idades[],
char generos[][10],
int totalPacientes
);
int calcularIdade
(
const char dataNascimento[]
);
void alterarDadosPaciente
(
int codigosPacientes[], char nomes[][50],
char generos[][10], char RGs[][15],
char CPFs[][15], char tiposSanguineos[][5],
char fatoresRH[], char enderecos[][100],
char datasNascimento[][11], int idades[],
int totalPacientes
);
void listarPacientesPorTipoSanguineo
(
int codigosPacientes[], char nomes[][50],
char tiposSanguineos[][5], char fatoresRH[],
char datasNascimento[][11], int totalPacientes
);
void listarConsultasPorData
(
int codigosPacientes[], char nomes[][50], char generos[][10], int idades[],
int codigosAtendimentos[], char tipos[][20], float precos[],
char datasAtendimento[][11], int totalPacientes, int totalAtendimentos
);
void mostrarPacientesOrdenados
(
int codigosPacientes[], char nomes[][50],
int idades[], int totalPacientes
);
void mostrarSomaConsultasPorPaciente
(
float precos[], int totalAtendimentos
);
void mostrarSomaConsultasPorData
(
float precos[], int totalAtendimentos,
char datasAtendimento[][11]
);
void mostrarSomaConsultasPorPeriodo
(
float precos[], char datasAtendimento[][11],
int totalAtendimentos
);
void editarAtendimento(
int codigosAtendimentos[], int totalAtendimentos,
int codigosPacientes[], char tipos[][20],
char datasAtendimento[][11], char status[][50],
float precos[]
);