diff --git a/app/src/main/java/com/example/pantallacompra/MainActivity.kt b/app/src/main/java/com/example/pantallacompra/MainActivity.kt
index a710eac..2f60229 100644
--- a/app/src/main/java/com/example/pantallacompra/MainActivity.kt
+++ b/app/src/main/java/com/example/pantallacompra/MainActivity.kt
@@ -41,7 +41,6 @@ class MainActivity : AppCompatActivity() {
fun cagarEventos(database: DatabaseReference){
//SE INSERTAN DATOS DE LOS EVENTOS EN LA BD
-
val event1 = Event("Los caligaris","Musical",120,"Concierto")
val event2= Event("Champions","futbol",100,"deportes")
val event3= Event("Rhiana Show","Musical",120,"Concierto")
@@ -69,46 +68,18 @@ class MainActivity : AppCompatActivity() {
database.child(sala4.n0Sala.toString()).setValue(sala4)
}
fun cargarAsientos(database: DatabaseReference){
- val asientoA1=Asiento("A1",25,"Chafa","Libre",1)
- val asientoA2=Asiento("A2",25,"Chafa","Libre",1)
- val asientoA3=Asiento("A3",25,"Chafa","Libre",1)
- val asientoA4=Asiento("A4",25,"Chafa","Libre",1)
- val asientoB1=Asiento("B1",40,"Regular","Libre",1)
- val asientoB2=Asiento("B2",40,"Regular","Libre",1)
- val asientoB3=Asiento("B3",40,"Regular","Libre",1)
- val asientoB4=Asiento("B4",40,"Regular","Libre",1)
- val asientoC1=Asiento("C1",40,"Regular","Libre",1)
- val asientoC2=Asiento("C2",40,"Regular","Libre",1)
- val asientoC3=Asiento("C3",40,"Regular","Libre",1)
- val asientoC4=Asiento("C4",40,"Regular","Libre",1)
- val asientoD1=Asiento("D1",40,"Regular","Libre",1)
- val asientoD2=Asiento("D2",40,"Regular","Libre",1)
- val asientoD3=Asiento("D3",40,"Regular","Libre",1)
- val asientoD4=Asiento("D4",40,"Regular","Libre",1)
- val asientoE1=Asiento("E1",70,"VIP","Libre",1)
- val asientoE2=Asiento("E2",70,"VIP","Libre",1)
- val asientoE3=Asiento("E3",70,"VIP","Libre",1)
- val asientoE4=Asiento("E4",70,"VIP","Libre",1)
+ val asientoA1=Asiento("A1",10,"Chafa","Libre",1)
+ val asientoA2=Asiento("A2",10,"Chafa","Libre",1)
+ val asientoA3=Asiento("A3",10,"Chafa","Libre",1)
+ val asientoB1=Asiento("B1",10,"Regular","Libre",1)
+ val asientoB2=Asiento("B2",10,"Regular","Libre",1)
+ val asientoB3=Asiento("B3",10,"Regular","Libre",1)
database.child(asientoA1.noAsiento.toString()).setValue(asientoA1)
database.child(asientoA2.noAsiento.toString()).setValue(asientoA2)
database.child(asientoA3.noAsiento.toString()).setValue(asientoA3)
- database.child(asientoA4.noAsiento.toString()).setValue(asientoA4)
database.child(asientoB1.noAsiento.toString()).setValue(asientoB1)
database.child(asientoB2.noAsiento.toString()).setValue(asientoB2)
database.child(asientoB3.noAsiento.toString()).setValue(asientoB3)
- database.child(asientoB4.noAsiento.toString()).setValue(asientoB4)
- database.child(asientoC1.noAsiento.toString()).setValue(asientoC1)
- database.child(asientoC2.noAsiento.toString()).setValue(asientoC2)
- database.child(asientoC3.noAsiento.toString()).setValue(asientoC3)
- database.child(asientoC4.noAsiento.toString()).setValue(asientoC4)
- database.child(asientoD1.noAsiento.toString()).setValue(asientoD1)
- database.child(asientoD2.noAsiento.toString()).setValue(asientoD2)
- database.child(asientoD3.noAsiento.toString()).setValue(asientoD3)
- database.child(asientoD4.noAsiento.toString()).setValue(asientoD4)
- database.child(asientoE1.noAsiento.toString()).setValue(asientoE1)
- database.child(asientoE2.noAsiento.toString()).setValue(asientoE2)
- database.child(asientoE3.noAsiento.toString()).setValue(asientoE3)
- database.child(asientoE4.noAsiento.toString()).setValue(asientoE4)
}
}
\ No newline at end of file
diff --git a/app/src/main/res/layout/pantalla_sala.xml b/app/src/main/res/layout/pantalla_sala.xml
index 9016d99..2908f59 100644
--- a/app/src/main/res/layout/pantalla_sala.xml
+++ b/app/src/main/res/layout/pantalla_sala.xml
@@ -19,6 +19,8 @@
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+