diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index d8edc91..ec0ef92 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -15,6 +15,9 @@
android:supportsRtl="true"
android:theme="@style/Theme.MedicalHealth"
tools:targetApi="31">
+
@@ -32,7 +35,7 @@
android:name=".RegistrarDActivity"
android:exported="false" />
, context: Context,val cellClickListener: CellClickListener) :
+class RecetaViewAdapter(private var notes : List, context: Context, val cellClickListener: CellClickListener) :
RecyclerView.Adapter() {
class NoteViewHolder(itemView: View) : RecyclerView.ViewHolder(itemView){
val tituloReceta : TextView = itemView.findViewById(R.id.tv_titulo_receta)
val fechaReceta : TextView = itemView.findViewById(R.id.tv_fecha_receta)
val nombreReceta : TextView = itemView.findViewById(R.id.tv_nombre_paciente)
- val btnDescargar : Button = itemView.findViewById(R.id.btn_descargar_receta)
- val btnEliminar: Button = itemView.findViewById(R.id.btn_eliminar_receta)
+ val btnDescargar : ImageView = itemView.findViewById(R.id.iv_descargar_receta)
+ val btnEliminar: ImageView = itemView.findViewById(R.id.iv_eliminar_receta)
+ val btnModificar : ImageView = itemView.findViewById(R.id.iv_modificar_receta)
val pesoReceta : TextView = itemView.findViewById(R.id.tv_peso_paciente)
val edadReceta : TextView = itemView.findViewById(R.id.tv_edad_paciente)
val dosisReceta : TextView=itemView.findViewById(R.id.tv_dosis_medicamento)
@@ -49,6 +51,9 @@ class RecetaViewAdapter(private var notes : List, context: Context,val c
holder.btnEliminar.setOnClickListener{
cellClickListener.onEliminarClickListener(position)
}
+ holder.btnModificar.setOnClickListener {
+ cellClickListener.onModifyClickListener(position)
+ }
}
fun refreshData( newNotes : List){
diff --git a/app/src/main/java/data/Doctor.kt b/app/src/main/java/com/terratenientes/medicalhealth/data/Doctor.kt
similarity index 73%
rename from app/src/main/java/data/Doctor.kt
rename to app/src/main/java/com/terratenientes/medicalhealth/data/Doctor.kt
index 72dafb6..d23ba62 100644
--- a/app/src/main/java/data/Doctor.kt
+++ b/app/src/main/java/com/terratenientes/medicalhealth/data/Doctor.kt
@@ -1,3 +1,3 @@
-package data
+package com.terratenientes.medicalhealth.data
data class Doctor(var Cedula : String ,var Nombre : String, var Apellido : String, var Telefono : String, var Consultorio : Int)
diff --git a/app/src/main/java/data/Paciente.kt b/app/src/main/java/com/terratenientes/medicalhealth/data/Paciente.kt
similarity index 84%
rename from app/src/main/java/data/Paciente.kt
rename to app/src/main/java/com/terratenientes/medicalhealth/data/Paciente.kt
index ca33451..8bd4a1c 100644
--- a/app/src/main/java/data/Paciente.kt
+++ b/app/src/main/java/com/terratenientes/medicalhealth/data/Paciente.kt
@@ -1,4 +1,4 @@
-package data
+package com.terratenientes.medicalhealth.data
data class Paciente(
var id: Int, // Este campo representa el ID autoincrementable en la base de datos
diff --git a/app/src/main/java/data/Receta.kt b/app/src/main/java/com/terratenientes/medicalhealth/data/Receta.kt
similarity index 80%
rename from app/src/main/java/data/Receta.kt
rename to app/src/main/java/com/terratenientes/medicalhealth/data/Receta.kt
index ace1073..b41277f 100644
--- a/app/src/main/java/data/Receta.kt
+++ b/app/src/main/java/com/terratenientes/medicalhealth/data/Receta.kt
@@ -1,3 +1,3 @@
-package data
+package com.terratenientes.medicalhealth.data
data class Receta(var NombrePaciente : String, var edadPaciente : Int, var pesoPaciente: Double, var nombreMedicamento : String, var fecha : String, var dosis : String, var duracion :String)
diff --git a/app/src/main/java/reports/ConsultarPacientesActivity.kt b/app/src/main/java/com/terratenientes/medicalhealth/reports/ConsultarPacientesActivity.kt
similarity index 95%
rename from app/src/main/java/reports/ConsultarPacientesActivity.kt
rename to app/src/main/java/com/terratenientes/medicalhealth/reports/ConsultarPacientesActivity.kt
index 54b6dc4..292a395 100644
--- a/app/src/main/java/reports/ConsultarPacientesActivity.kt
+++ b/app/src/main/java/com/terratenientes/medicalhealth/reports/ConsultarPacientesActivity.kt
@@ -1,4 +1,4 @@
-package reports
+package com.terratenientes.medicalhealth.reports
import android.Manifest
import android.annotation.SuppressLint
@@ -11,10 +11,10 @@ import android.os.Environment
import android.widget.Toast
import androidx.core.app.ActivityCompat
import androidx.core.content.ContextCompat
-import adapters.DoctorDataBaseHelper
+import com.terratenientes.medicalhealth.adapters.DoctorDataBaseHelper
import com.terratenientes.medicalhealth.ModificarActivity
-import data.Paciente
-import adapters.PacienteAdapter
+import com.terratenientes.medicalhealth.data.Paciente
+import com.terratenientes.medicalhealth.adapters.PacienteAdapter
import com.terratenientes.medicalhealth.R
import com.terratenientes.medicalhealth.databinding.ActivityConsultarPacientesBinding
import java.io.File
diff --git a/app/src/main/res/drawable/delete.xml b/app/src/main/res/drawable/delete.xml
new file mode 100644
index 0000000..3084d69
--- /dev/null
+++ b/app/src/main/res/drawable/delete.xml
@@ -0,0 +1,9 @@
+
+
+
diff --git a/app/src/main/res/drawable/download.xml b/app/src/main/res/drawable/download.xml
new file mode 100644
index 0000000..4ba6b80
--- /dev/null
+++ b/app/src/main/res/drawable/download.xml
@@ -0,0 +1,9 @@
+
+
+
diff --git a/app/src/main/res/drawable/update.xml b/app/src/main/res/drawable/update.xml
new file mode 100644
index 0000000..6849a5f
--- /dev/null
+++ b/app/src/main/res/drawable/update.xml
@@ -0,0 +1,9 @@
+
+
+
diff --git a/app/src/main/res/layout/activity_consultar_pacientes.xml b/app/src/main/res/layout/activity_consultar_pacientes.xml
index d861a2a..b2f591a 100644
--- a/app/src/main/res/layout/activity_consultar_pacientes.xml
+++ b/app/src/main/res/layout/activity_consultar_pacientes.xml
@@ -5,7 +5,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
- tools:context="reports.ConsultarPacientesActivity">
+ tools:context=".reports.ConsultarPacientesActivity">
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/src/main/res/layout/rc_receta_item.xml b/app/src/main/res/layout/rc_receta_item.xml
index 0cfa962..de36e79 100644
--- a/app/src/main/res/layout/rc_receta_item.xml
+++ b/app/src/main/res/layout/rc_receta_item.xml
@@ -63,33 +63,44 @@
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
-
+ app:layout_constraintVertical_bias="0.243" />
-
+
+ Peso del paciente KG
Agregar Receta
Ayuda
+ Modificar Receta
PrincipalActivity
Home
Dashboard