Union pantalla principal y compra
This commit is contained in:
parent
8979e57240
commit
b40f77c819
|
@ -12,6 +12,17 @@
|
|||
android:supportsRtl="true"
|
||||
android:theme="@style/Theme.PantallaCompra"
|
||||
tools:targetApi="31" >
|
||||
<activity
|
||||
android:name=".ChairList"
|
||||
android:screenOrientation="portrait"
|
||||
android:exported="false" />
|
||||
<activity android:name=".PantallaCompra"
|
||||
android:screenOrientation="portrait"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".EventList"
|
||||
android:screenOrientation="portrait"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="true" >
|
||||
|
|
|
@ -1,11 +1,76 @@
|
|||
package com.example.pantallacompra
|
||||
|
||||
import android.content.Intent
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import android.os.Bundle
|
||||
import android.widget.Button
|
||||
import androidx.recyclerview.widget.GridLayoutManager
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
|
||||
class MainActivity : AppCompatActivity() {
|
||||
private lateinit var binding: ActivityMainBinding
|
||||
private lateinit var eventosReferences : DatabaseReference
|
||||
private lateinit var salasReference: DatabaseReference
|
||||
private lateinit var asientosReference: DatabaseReference
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
binding= ActivityMainBinding.inflate(layoutInflater)
|
||||
eventosReferences= FirebaseDatabase.getInstance().getReference("Eventos")
|
||||
salasReference= FirebaseDatabase.getInstance().getReference("Salas")
|
||||
asientosReference= FirebaseDatabase.getInstance().getReference("Asientos")
|
||||
|
||||
setContentView(R.layout.activity_main)
|
||||
|
||||
val boton = findViewById<Button>(R.id.nextBtn)
|
||||
|
||||
boton.setOnClickListener{
|
||||
val intent = Intent(this, EventList::class.java)
|
||||
startActivity(intent)
|
||||
}
|
||||
}
|
||||
|
||||
fun insertData(eventosReference: DatabaseReference, salasReference: DatabaseReference, asientosReference: DatabaseReference){
|
||||
cagarEventos(eventosReference)
|
||||
cargarSalas(salasReference)
|
||||
cargarAsientos(asientosReference)
|
||||
}
|
||||
|
||||
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")
|
||||
val event4= Event("Potros Furiosos","Pelicula",120,"Entretenimiento")
|
||||
val event5= Event("Trans Show","futbol",120,"Entretenimiento")
|
||||
val event6= Event("Michael Jackson","Musical",120,"Concierto")
|
||||
database.child(event1.nombre.toString()).setValue(event1)
|
||||
database.child(event2.nombre.toString()).setValue(event2)
|
||||
database.child(event3.nombre.toString()).setValue(event3)
|
||||
database.child(event4.nombre.toString()).setValue(event4)
|
||||
database.child(event5.nombre.toString()).setValue(event5)
|
||||
database.child(event6.nombre.toString()).setValue(event6)
|
||||
}
|
||||
|
||||
fun cargarSalas(database: DatabaseReference){
|
||||
//SE INSERTAN DATOS DE LAS SALAS EN LA BD
|
||||
val sala1=Sala(1,"los caligaris")
|
||||
val sala2=Sala(2,"Champions")
|
||||
val sala3=Sala(3,"Potros Furiosos")
|
||||
val sala4=Sala(4,"Trnas Show")
|
||||
|
||||
database.child(sala1.n0Sala.toString()).setValue(sala1)
|
||||
database.child(sala2.n0Sala.toString()).setValue(sala2)
|
||||
database.child(sala3.n0Sala.toString()).setValue(sala3)
|
||||
database.child(sala4.n0Sala.toString()).setValue(sala4)
|
||||
}
|
||||
fun cargarAsientos(database: DatabaseReference){
|
||||
val asientoA1=Asiento("A1",10,"Chafa","Libre",1)
|
||||
val asientoA2=Asiento("A2",10,"Chafa","Libre",1)
|
||||
val asientoA3=Asiento("A3",10,"Chafa","Libre",1)
|
||||
|
||||
database.child(asientoA1.noAsiento.toString()).setValue(asientoA1)
|
||||
database.child(asientoA2.noAsiento.toString()).setValue(asientoA2)
|
||||
database.child(asientoA3.noAsiento.toString()).setValue(asientoA3)
|
||||
}
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
package com.example.pantallacompra
|
||||
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import android.widget.TextView
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
|
||||
class adapter(private val item: ArrayList<String>) : RecyclerView.Adapter<adapter.ViewHolder>(){
|
||||
class ViewHolder(itemView : View) : RecyclerView.ViewHolder(itemView){
|
||||
val textView : TextView = itemView.findViewById(R.id.text)
|
||||
}
|
||||
|
||||
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ViewHolder {
|
||||
return ViewHolder(LayoutInflater.from(parent.context).inflate(R.layout.itemasiento,parent,false))
|
||||
}
|
||||
|
||||
override fun getItemCount(): Int {
|
||||
return item.size
|
||||
}
|
||||
|
||||
override fun onBindViewHolder(holder: ViewHolder, position: Int) {
|
||||
holder.textView.text = item[position]
|
||||
}
|
||||
}
|
Binary file not shown.
After Width: | Height: | Size: 109 KiB |
Binary file not shown.
After Width: | Height: | Size: 62 KiB |
Binary file not shown.
Binary file not shown.
|
@ -0,0 +1,69 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/eventTextTitle"
|
||||
android:layout_width="415dp"
|
||||
android:layout_height="87dp"
|
||||
android:background="#08404F"
|
||||
android:gravity="center"
|
||||
android:text="Playpal"
|
||||
android:textAlignment="gravity"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="34sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/logoCamion"
|
||||
android:layout_width="119dp"
|
||||
android:layout_height="82dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:background="#08404F"
|
||||
android:src="@drawable/logocamion"
|
||||
app:layout_constraintStart_toStartOf="@+id/eventTextTitle"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/chairRecycleView"
|
||||
android:layout_width="401dp"
|
||||
android:layout_height="582dp"
|
||||
android:layout_marginTop="60dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.0"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/eventTextTitle" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/noSalaText"
|
||||
android:layout_width="121dp"
|
||||
android:layout_height="63dp"
|
||||
android:text="N0. Sala"
|
||||
android:textAlignment="center"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/chairRecycleView"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.0"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="parent"
|
||||
app:layout_constraintVertical_bias="1.0" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/eventoText"
|
||||
android:layout_width="292dp"
|
||||
android:layout_height="59dp"
|
||||
android:text="Los Caligaris"
|
||||
android:textAlignment="center"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/chairRecycleView"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/noSalaText"
|
||||
app:layout_constraintTop_toBottomOf="@+id/eventTextTitle" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
@ -0,0 +1,61 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".EventList">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/eventTextTitle"
|
||||
android:layout_width="415dp"
|
||||
android:layout_height="87dp"
|
||||
android:background="#08404F"
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:gravity="center"
|
||||
android:text="Playpal"
|
||||
android:textAlignment="gravity"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="50sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/logoCamion"
|
||||
android:layout_width="120dp"
|
||||
android:layout_height="86dp"
|
||||
android:background="#08404F"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:srcCompat="@drawable/logocamion" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/eventRecycleView"
|
||||
android:layout_width="410dp"
|
||||
android:layout_height="585dp"
|
||||
android:background="#2b7f88"
|
||||
android:scrollbars="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/eventTitle"
|
||||
tools:listitem="@layout/event_item" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/eventTitle"
|
||||
android:layout_width="405dp"
|
||||
android:layout_height="70dp"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:layout_marginBottom="581dp"
|
||||
android:background="#297880"
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:text="Eventos"
|
||||
android:textAlignment="center"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/eventTextTitle" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
@ -4,172 +4,66 @@
|
|||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="#2B7F88"
|
||||
|
||||
android:background="#08404f"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textoApp"
|
||||
android:layout_width="410dp"
|
||||
android:layout_height="93dp"
|
||||
android:autoText="false"
|
||||
android:id="@+id/eventTextTitle"
|
||||
android:layout_width="309dp"
|
||||
android:layout_height="88dp"
|
||||
android:layout_marginTop="80dp"
|
||||
android:background="#08404F"
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:gravity="center"
|
||||
android:text="PlayPal"
|
||||
android:textAlignment="center"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="34sp"
|
||||
tools:layout_editor_absoluteX="0dp"
|
||||
tools:layout_editor_absoluteY="1dp" />
|
||||
android:text="Playpal"
|
||||
android:textAlignment="gravity"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="70sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/logoCamion" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/logo"
|
||||
android:layout_width="97dp"
|
||||
android:layout_height="93dp"
|
||||
app:srcCompat="@drawable/logo_empresa_log_stica_y_transporte_profesional_rojo_photoroom_png_photoroom"
|
||||
tools:layout_editor_absoluteX="0dp"
|
||||
tools:layout_editor_absoluteY="1dp" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imagenEvento"
|
||||
android:layout_width="380dp"
|
||||
android:layout_height="182dp"
|
||||
tools:layout_editor_absoluteX="9dp"
|
||||
tools:layout_editor_absoluteY="126dp"
|
||||
tools:srcCompat="@tools:sample/backgrounds/scenic" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="277dp"
|
||||
android:layout_height="170dp"
|
||||
android:id="@+id/logoCamion"
|
||||
android:layout_width="207dp"
|
||||
android:layout_height="195dp"
|
||||
android:layout_marginTop="64dp"
|
||||
android:background="#08404F"
|
||||
tools:layout_editor_absoluteX="62dp"
|
||||
tools:layout_editor_absoluteY="332dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textoDetalles"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="DETALLES DE LA VENTA"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="16sp"
|
||||
tools:layout_editor_absoluteX="50dp"
|
||||
tools:layout_editor_absoluteY="16dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textoFecha"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Fecha y hora:"
|
||||
android:textColor="#FFFFFF"
|
||||
tools:layout_editor_absoluteX="20dp"
|
||||
tools:layout_editor_absoluteY="48dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textoFecha"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Asientos seleccionados:"
|
||||
android:textColor="#FFFFFF"
|
||||
tools:layout_editor_absoluteX="20dp"
|
||||
tools:layout_editor_absoluteY="85dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textoFecha"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Monto total:"
|
||||
android:textColor="#FFFFFF"
|
||||
tools:layout_editor_absoluteX="20dp"
|
||||
tools:layout_editor_absoluteY="125dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/fechaHora"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="TextView"
|
||||
tools:layout_editor_absoluteX="114dp"
|
||||
tools:layout_editor_absoluteY="48dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/asientos"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="TextView"
|
||||
tools:layout_editor_absoluteX="183dp"
|
||||
tools:layout_editor_absoluteY="85dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/monto"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="TextView"
|
||||
tools:layout_editor_absoluteX="109dp"
|
||||
tools:layout_editor_absoluteY="125dp" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="278dp"
|
||||
android:layout_height="147dp"
|
||||
android:background="#08404F"
|
||||
tools:layout_editor_absoluteX="61dp"
|
||||
tools:layout_editor_absoluteY="519dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textoDetalles"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="COMPRADOR"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="16sp"
|
||||
tools:layout_editor_absoluteX="90dp"
|
||||
tools:layout_editor_absoluteY="16dp" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/editTextText3"
|
||||
android:layout_width="204dp"
|
||||
android:layout_height="24dp"
|
||||
android:background="#FFFFFF"
|
||||
android:ems="10"
|
||||
android:hint="Nombre"
|
||||
android:inputType="text"
|
||||
android:textColor="#808080"
|
||||
android:textSize="16sp"
|
||||
tools:layout_editor_absoluteX="46dp"
|
||||
tools:layout_editor_absoluteY="51dp" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/editTextPhone"
|
||||
android:layout_width="203dp"
|
||||
android:layout_height="23dp"
|
||||
android:background="#FFFFFF"
|
||||
android:ems="10"
|
||||
android:hint="Teléfono"
|
||||
android:inputType="phone"
|
||||
android:textColor="#808080"
|
||||
android:textSize="16sp"
|
||||
tools:layout_editor_absoluteX="46dp"
|
||||
tools:layout_editor_absoluteY="95dp" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:srcCompat="@drawable/logocamion" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/button2"
|
||||
android:id="@+id/nextBtn"
|
||||
android:layout_width="140dp"
|
||||
android:layout_height="81dp"
|
||||
android:background="@drawable/boton_redondo"
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:shadowColor="#61AAE4"
|
||||
android:text=" Eventos"
|
||||
android:textSize="20sp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.498"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/eventTextTitle"
|
||||
app:layout_constraintVertical_bias="0.354" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/sloganText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="#D9D9D9"
|
||||
android:text="Prueba"
|
||||
android:textColor="#000000"
|
||||
tools:layout_editor_absoluteX="97dp"
|
||||
tools:layout_editor_absoluteY="677dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/button"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="#D9D9D9"
|
||||
android:text="Cancelar"
|
||||
android:textColor="#000000"
|
||||
tools:layout_editor_absoluteX="218dp"
|
||||
tools:layout_editor_absoluteY="677dp" />
|
||||
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:text="Transformamos tu tiempo en un espectáculo"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="15sp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/nextBtn"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.492"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/eventTextTitle"
|
||||
app:layout_constraintVertical_bias="0.105" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
@ -0,0 +1,64 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.cardview.widget.CardView
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
|
||||
android:id="@+id/eventItem"
|
||||
android:layout_marginStart="12dp"
|
||||
android:background="@drawable/boton_redondo"
|
||||
android:layout_marginEnd="12dp"
|
||||
android:layout_marginHorizontal="10dp"
|
||||
android:layout_marginVertical="10dp"
|
||||
app:cardCornerRadius="20dp"
|
||||
app:cardElevation="8dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="110dp">
|
||||
|
||||
<RelativeLayout
|
||||
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/boton_redondo" />
|
||||
|
||||
<com.google.android.material.imageview.ShapeableImageView
|
||||
android:id="@+id/imageEvent"
|
||||
android:layout_width="90dp"
|
||||
android:layout_height="90dp"
|
||||
android:src="@drawable/descarga"
|
||||
android:layout_marginStart="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:scaleType="centerCrop" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/eventName"
|
||||
android:layout_width="250dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_marginStart="120dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:text="Titulo"
|
||||
android:textSize="15dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/eventType"
|
||||
android:layout_width="250dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_marginStart="120dp"
|
||||
android:layout_marginTop="40dp"
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:text="Tipo"
|
||||
android:textSize="15dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/eventDuration"
|
||||
android:layout_width="250dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_marginStart="120dp"
|
||||
android:layout_marginTop="70dp"
|
||||
android:fontFamily="@font/cinepolis"
|
||||
android:text="min"
|
||||
android:textSize="15dp" />
|
||||
|
||||
|
||||
</androidx.cardview.widget.CardView>
|
|
@ -0,0 +1,19 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#08404F"
|
||||
android:layout_margin="16dp"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:padding="6dp"
|
||||
></TextView>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
@ -0,0 +1,111 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="#2B7F88">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView"
|
||||
android:layout_width="415dp"
|
||||
android:layout_height="96dp"
|
||||
android:background="#08404F"
|
||||
android:gravity="center"
|
||||
android:text="PlayPal"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="34sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/logo"
|
||||
android:layout_width="97dp"
|
||||
android:layout_height="93dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:srcCompat="@drawable/logo_empresa_log_stica_y_transporte_profesional_rojo_photoroom_png_photoroom" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView2"
|
||||
android:layout_width="299dp"
|
||||
android:layout_height="41dp"
|
||||
android:gravity="center"
|
||||
android:text="Económicos"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:layout_editor_absoluteY="106dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView3"
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="43dp"
|
||||
android:gravity="center"
|
||||
android:text="Regulares"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:layout_editor_absoluteY="241dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView4"
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="38dp"
|
||||
android:gravity="center"
|
||||
android:text="VIP"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:layout_editor_absoluteY="369dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView5"
|
||||
android:layout_width="414dp"
|
||||
android:layout_height="99dp"
|
||||
android:background="#612020"
|
||||
android:gravity="center"
|
||||
android:text="Escenario"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="24sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:layout_editor_absoluteY="541dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView6"
|
||||
android:layout_width="79dp"
|
||||
android:layout_height="55dp"
|
||||
android:background="#612020"
|
||||
app:layout_constraintBottom_toTopOf="@+id/textView5"
|
||||
tools:layout_editor_absoluteX="166dp" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recycleCheap"
|
||||
android:layout_width="298dp"
|
||||
android:layout_height="57dp"
|
||||
android:layout_marginTop="16dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/textView2"
|
||||
tools:layout_editor_absoluteX="58dp" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recycleRegular"
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginTop="12dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/textView3"
|
||||
tools:layout_editor_absoluteX="56dp" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/recycleVip"
|
||||
android:layout_width="298dp"
|
||||
android:layout_height="35dp"
|
||||
android:layout_marginTop="24dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/textView4"
|
||||
tools:layout_editor_absoluteX="58dp" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
@ -0,0 +1,219 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="#2B7F88"
|
||||
android:textAlignment="center"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
<!-- Primer ConstraintLayout -->
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/top_layout"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="#08404F"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintWidth_default="percent"
|
||||
app:layout_constraintWidth_percent="0.9">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="PLAYPAL"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintVertical_bias="0.5" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<!-- Segundo ConstraintLayout -->
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/second_layout"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:background="#08404F"
|
||||
app:layout_constraintBottom_toTopOf="@+id/third_layout"
|
||||
app:layout_constraintEnd_toEndOf="@+id/top_layout"
|
||||
app:layout_constraintStart_toStartOf="@+id/top_layout"
|
||||
app:layout_constraintTop_toBottomOf="@+id/top_layout">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="345dp"
|
||||
android:layout_height="328dp"
|
||||
android:scaleType="centerCrop"
|
||||
android:src="@drawable/descarga"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<!-- Tercer ConstraintLayout -->
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/third_layout"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:background="#08404F"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="@+id/top_layout"
|
||||
app:layout_constraintHorizontal_bias="1.0"
|
||||
app:layout_constraintStart_toStartOf="@+id/top_layout"
|
||||
app:layout_constraintTop_toBottomOf="@+id/second_layout">
|
||||
|
||||
<!-- TextView para "DETALLES DE LA VENTA" -->
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView3"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:text="DETALLES DE LA VENTA"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="16sp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView4"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Fecha y hora: "
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@id/textView3"
|
||||
app:layout_constraintTop_toBottomOf="@id/textView3" />
|
||||
|
||||
<!-- TextView para "Asientos seleccionados" -->
|
||||
<TextView
|
||||
android:id="@+id/textView5"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Asientos seleccionados: "
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@id/textView3"
|
||||
app:layout_constraintTop_toBottomOf="@id/textView4" />
|
||||
|
||||
<!-- TextView para "Monto total" -->
|
||||
<TextView
|
||||
android:id="@+id/textView6"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Monto total: "
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@id/textView5"
|
||||
app:layout_constraintTop_toBottomOf="@id/textView5" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView7"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="DETALLES DEL COMPRADOR"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="16sp"
|
||||
app:layout_constraintStart_toStartOf="@id/textView6"
|
||||
app:layout_constraintTop_toBottomOf="@id/textView6" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView4Result"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="13 de Noviembre, 4:00 AM"
|
||||
android:textColor="#4CAF50"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toEndOf="@id/textView4"
|
||||
app:layout_constraintTop_toTopOf="@id/textView4" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView5Result"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="A1, B2 "
|
||||
android:textColor="#4CAF50"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toEndOf="@id/textView5"
|
||||
app:layout_constraintTop_toTopOf="@id/textView5" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView6Result"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="$2300.00"
|
||||
android:textColor="#4CAF50"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toEndOf="@id/textView6"
|
||||
app:layout_constraintTop_toTopOf="@id/textView6" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/editTextNombre"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:background="#FFFFFF"
|
||||
android:hint="Ingrese su nombre"
|
||||
android:padding="16dp"
|
||||
android:textColorHint="#808080"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintEnd_toEndOf="@id/textView7"
|
||||
app:layout_constraintStart_toStartOf="@id/textView7"
|
||||
app:layout_constraintTop_toBottomOf="@id/textView7" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/editTextTelefono"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:background="#FFFFFF"
|
||||
android:hint="Ingrese su número de teléfono"
|
||||
android:inputType="phone"
|
||||
android:padding="16dp"
|
||||
android:textColorHint="#808080"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintEnd_toEndOf="@id/textView7"
|
||||
app:layout_constraintStart_toStartOf="@id/textView7"
|
||||
app:layout_constraintTop_toBottomOf="@id/editTextNombre" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/buttonComprar"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:background="#d9d9d9"
|
||||
android:backgroundTint="#0D9D9D"
|
||||
android:text="Comprar"
|
||||
android:textColor="#000000"
|
||||
android:textSize="10sp"
|
||||
app:layout_constraintEnd_toStartOf="@id/buttonCancelar"
|
||||
app:layout_constraintStart_toStartOf="@id/editTextNombre"
|
||||
app:layout_constraintTop_toBottomOf="@id/editTextTelefono" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/buttonCancelar"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:background="#d9d9d9"
|
||||
android:text="Cancelar"
|
||||
android:textColor="#000000"
|
||||
android:textSize="10sp"
|
||||
app:layout_constraintEnd_toEndOf="@id/editTextTelefono"
|
||||
app:layout_constraintStart_toEndOf="@id/buttonComprar"
|
||||
app:layout_constraintTop_toBottomOf="@id/editTextTelefono" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
Loading…
Reference in New Issue