..
This commit is contained in:
@@ -39,12 +39,16 @@ public class EstablishmentDashboardActivity extends AppCompatActivity {
|
|||||||
? "Perfil criado. Configure horários, mesas e abra reservas."
|
? "Perfil criado. Configure horários, mesas e abra reservas."
|
||||||
: "Dashboard operacional. Acompanhe as reservas em tempo real.");
|
: "Dashboard operacional. Acompanhe as reservas em tempo real.");
|
||||||
|
|
||||||
Button btnOpenWalkIns = findViewById(R.id.btnAbrirEspera);
|
android.view.View btnOpenWalkIns = findViewById(R.id.btnAbrirEspera);
|
||||||
Button btnStaff = findViewById(R.id.btnGestaoStaff);
|
android.view.View btnStaff = findViewById(R.id.btnGestaoStaff);
|
||||||
Button btnGerirMesas = findViewById(R.id.btnGerirMesas);
|
android.view.View btnGerirMesas = findViewById(R.id.btnGerirMesas);
|
||||||
Button btnDetails = findViewById(R.id.btnDetalhesReservas);
|
android.view.View btnDetails = findViewById(R.id.btnDetalhesReservas);
|
||||||
Button btnSettings = findViewById(R.id.btnDefinicoes);
|
android.view.View btnSettings = findViewById(R.id.btnDefinicoes);
|
||||||
Button btnBack = findViewById(R.id.btnVoltar);
|
|
||||||
|
com.google.android.material.appbar.MaterialToolbar toolbar = findViewById(R.id.toolbar);
|
||||||
|
if (toolbar != null) {
|
||||||
|
toolbar.setNavigationOnClickListener(v -> finish());
|
||||||
|
}
|
||||||
|
|
||||||
String email = getIntent().getStringExtra(MainActivity.EXTRA_EMAIL);
|
String email = getIntent().getStringExtra(MainActivity.EXTRA_EMAIL);
|
||||||
if (email == null) {
|
if (email == null) {
|
||||||
@@ -56,45 +60,53 @@ public class EstablishmentDashboardActivity extends AppCompatActivity {
|
|||||||
}
|
}
|
||||||
final String finalEmail = email;
|
final String finalEmail = email;
|
||||||
|
|
||||||
btnOpenWalkIns.setOnClickListener(v -> {
|
if (btnOpenWalkIns != null) {
|
||||||
Intent intent = new Intent(this, ListaEsperaActivity.class);
|
btnOpenWalkIns.setOnClickListener(v -> {
|
||||||
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
Intent intent = new Intent(this, ListaEsperaActivity.class);
|
||||||
startActivity(intent);
|
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
||||||
});
|
startActivity(intent);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
btnStaff.setOnClickListener(v -> {
|
if (btnStaff != null) {
|
||||||
Intent intent = new Intent(this, GestaoStaffActivity.class);
|
btnStaff.setOnClickListener(v -> {
|
||||||
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
Intent intent = new Intent(this, GestaoStaffActivity.class);
|
||||||
startActivity(intent);
|
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
||||||
});
|
startActivity(intent);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
btnGerirMesas.setOnClickListener(v -> {
|
if (btnGerirMesas != null) {
|
||||||
Intent intent = new Intent(this, GerirMesasActivity.class);
|
btnGerirMesas.setOnClickListener(v -> {
|
||||||
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
Intent intent = new Intent(this, GerirMesasActivity.class);
|
||||||
startActivity(intent);
|
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
||||||
});
|
startActivity(intent);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
btnDetails.setOnClickListener(v -> {
|
if (btnDetails != null) {
|
||||||
Intent intent = new Intent(this, DetalhesReservasActivity.class);
|
btnDetails.setOnClickListener(v -> {
|
||||||
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
Intent intent = new Intent(this, DetalhesReservasActivity.class);
|
||||||
startActivity(intent);
|
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
||||||
});
|
startActivity(intent);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
btnSettings.setOnClickListener(v -> {
|
if (btnSettings != null) {
|
||||||
Intent intent = new Intent(this, DefinicoesAdminActivity.class);
|
btnSettings.setOnClickListener(v -> {
|
||||||
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
Intent intent = new Intent(this, DefinicoesAdminActivity.class);
|
||||||
startActivity(intent);
|
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
||||||
});
|
startActivity(intent);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
findViewById(R.id.cardReservasHoje).setOnClickListener(v -> {
|
android.view.View cardReservasHoje = findViewById(R.id.cardReservasHoje);
|
||||||
Intent intent = new Intent(this, DetalhesReservasActivity.class);
|
if (cardReservasHoje != null) {
|
||||||
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
cardReservasHoje.setOnClickListener(v -> {
|
||||||
startActivity(intent);
|
Intent intent = new Intent(this, DetalhesReservasActivity.class);
|
||||||
});
|
intent.putExtra(MainActivity.EXTRA_EMAIL, finalEmail);
|
||||||
|
startActivity(intent);
|
||||||
if (btnBack != null) {
|
});
|
||||||
|
|
||||||
btnBack.setOnClickListener(v -> finish());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
loadProximasReservas();
|
loadProximasReservas();
|
||||||
@@ -210,7 +222,8 @@ public class EstablishmentDashboardActivity extends AppCompatActivity {
|
|||||||
com.example.pap_teste.models.Reserva r = ds.getValue(com.example.pap_teste.models.Reserva.class);
|
com.example.pap_teste.models.Reserva r = ds.getValue(com.example.pap_teste.models.Reserva.class);
|
||||||
if (r != null && r.getRestauranteEmail() != null && r.getRestauranteEmail().trim().equalsIgnoreCase(finalEmail)) {
|
if (r != null && r.getRestauranteEmail() != null && r.getRestauranteEmail().trim().equalsIgnoreCase(finalEmail)) {
|
||||||
if (r.getEstado() != null) {
|
if (r.getEstado() != null) {
|
||||||
if ((r.getEstado().startsWith("Confirmada") || r.getEstado().equals("Concluída") || r.getEstado().equals("Arquivada")) && todayDate.equals(r.getData())) {
|
// Opção B: Conta TODAS as reservas confirmadas/concluídas/arquivadas
|
||||||
|
if (r.getEstado().startsWith("Confirmada") || r.getEstado().equals("Concluída") || r.getEstado().equals("Arquivada")) {
|
||||||
reservasHoje++;
|
reservasHoje++;
|
||||||
} else if ("Pendente".equals(r.getEstado())) {
|
} else if ("Pendente".equals(r.getEstado())) {
|
||||||
listaEspera++;
|
listaEspera++;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:id="@+id/establishmentRoot"
|
android:id="@+id/establishmentRoot"
|
||||||
@@ -8,186 +8,244 @@
|
|||||||
android:background="@color/colorBackground"
|
android:background="@color/colorBackground"
|
||||||
tools:context=".EstablishmentDashboardActivity">
|
tools:context=".EstablishmentDashboardActivity">
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
<com.google.android.material.appbar.AppBarLayout
|
||||||
android:id="@+id/btnVoltar"
|
android:layout_width="match_parent"
|
||||||
style="@style/Widget.Material3.Button.TextButton"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="16dp"
|
android:background="@color/colorBackground"
|
||||||
android:layout_marginTop="16dp"
|
app:elevation="0dp">
|
||||||
android:text="← Voltar"
|
|
||||||
android:textAllCaps="false"
|
|
||||||
android:textColor="@color/colorTextSecondary"
|
|
||||||
android:textSize="16sp"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
|
||||||
|
|
||||||
<ScrollView
|
<com.google.android.material.appbar.MaterialToolbar
|
||||||
android:layout_width="0dp"
|
android:id="@+id/toolbar"
|
||||||
android:layout_height="0dp"
|
android:layout_width="match_parent"
|
||||||
android:fillViewport="true"
|
android:layout_height="?attr/actionBarSize"
|
||||||
android:scrollbars="none"
|
app:title=""
|
||||||
app:layout_constraintTop_toBottomOf="@id/btnVoltar"
|
app:navigationIcon="@android:drawable/ic_menu_revert"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:navigationIconTint="@color/colorTextPrimary"/>
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent">
|
</com.google.android.material.appbar.AppBarLayout>
|
||||||
|
|
||||||
|
<androidx.core.widget.NestedScrollView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:clipToPadding="false"
|
||||||
|
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:padding="24dp">
|
android:padding="20dp">
|
||||||
|
|
||||||
|
<!-- HEADER TEXT -->
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/txtEstabTitle"
|
android:id="@+id/txtEstabTitle"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="Estabelecimento"
|
android:text="Bistro Manager"
|
||||||
android:textColor="@color/colorTextPrimary"
|
android:textColor="@color/colorTextPrimary"
|
||||||
android:textSize="28sp"
|
android:textSize="32sp"
|
||||||
android:fontFamily="sans-serif-medium" />
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/txtEstabSubtitle"
|
android:id="@+id/txtEstabSubtitle"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="8dp"
|
android:layout_marginTop="4dp"
|
||||||
android:text="Veja as reservas ao vivo e controle a ocupação."
|
android:text="Dashboard operacional. Acompanhe as reservas."
|
||||||
android:textColor="@color/colorTextSecondary"
|
android:textColor="@color/colorTextSecondary"
|
||||||
android:textSize="15sp"
|
android:textSize="14sp" />
|
||||||
android:lineSpacingExtra="2dp"/>
|
|
||||||
|
|
||||||
<TextView
|
<com.google.android.material.chip.Chip
|
||||||
android:id="@+id/txtEstabRole"
|
android:id="@+id/txtEstabRole"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="8dp"
|
android:layout_marginTop="8dp"
|
||||||
android:text="Função: ADMIN"
|
android:text="Função: ADMIN"
|
||||||
android:textColor="@color/colorSuccess"
|
android:textColor="@color/colorPrimary"
|
||||||
android:textSize="13sp"
|
app:chipBackgroundColor="#1A000000"
|
||||||
android:textStyle="bold" />
|
app:chipStrokeWidth="0dp"
|
||||||
|
android:clickable="false" />
|
||||||
|
|
||||||
|
<!-- ALERTS BANNER -->
|
||||||
|
<com.google.android.material.card.MaterialCardView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="24dp"
|
||||||
|
app:cardBackgroundColor="#FFF3E0"
|
||||||
|
app:cardCornerRadius="12dp"
|
||||||
|
app:strokeWidth="0dp"
|
||||||
|
app:cardElevation="0dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:padding="16dp">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_dialog_alert"
|
||||||
|
app:tint="#E65100" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="12dp"
|
||||||
|
android:text="Nenhum alerta crítico de momento."
|
||||||
|
android:textColor="#E65100"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
</LinearLayout>
|
||||||
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
<!-- STATS CARDS GRID -->
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="32dp"
|
android:layout_marginTop="24dp"
|
||||||
|
android:baselineAligned="false"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<!-- Reservas -->
|
||||||
<com.google.android.material.card.MaterialCardView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:id="@+id/cardReservasHoje"
|
android:id="@+id/cardReservasHoje"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="120dp"
|
||||||
android:layout_marginEnd="6dp"
|
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:foreground="?attr/selectableItemBackground"
|
android:layout_marginEnd="6dp"
|
||||||
app:cardBackgroundColor="@color/colorSurface"
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
app:cardCornerRadius="16dp"
|
app:cardCornerRadius="20dp"
|
||||||
app:cardElevation="2dp">
|
app:cardElevation="2dp"
|
||||||
|
android:clickable="true"
|
||||||
|
android:focusable="true">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:padding="16dp">
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_menu_my_calendar"
|
||||||
|
app:tint="@color/colorPrimary" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/txtReservasHojeDash"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="12dp"
|
||||||
|
android:text="0"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="28sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="Reservas"
|
android:text="Reservas"
|
||||||
android:textColor="@color/colorTextSecondary"
|
android:textColor="@color/colorTextSecondary"
|
||||||
android:textSize="13sp" />
|
android:textSize="12sp" />
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/txtReservasHojeDash"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="6dp"
|
|
||||||
android:text="00"
|
|
||||||
android:textColor="@color/colorPrimary"
|
|
||||||
android:textSize="30sp"
|
|
||||||
android:fontFamily="sans-serif-medium" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</com.google.android.material.card.MaterialCardView>
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
<!-- Mesas -->
|
||||||
<com.google.android.material.card.MaterialCardView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="120dp"
|
||||||
|
android:layout_weight="1"
|
||||||
android:layout_marginStart="6dp"
|
android:layout_marginStart="6dp"
|
||||||
android:layout_marginEnd="6dp"
|
android:layout_marginEnd="6dp"
|
||||||
android:layout_weight="1"
|
|
||||||
app:cardBackgroundColor="@color/colorSurface"
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
app:cardCornerRadius="16dp"
|
app:cardCornerRadius="20dp"
|
||||||
app:cardElevation="2dp">
|
app:cardElevation="2dp">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:padding="16dp">
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
<TextView
|
<ImageView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="24dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="24dp"
|
||||||
android:text="Mesas"
|
android:src="@android:drawable/ic_menu_sort_by_size"
|
||||||
android:textColor="@color/colorTextSecondary"
|
app:tint="#4CAF50" />
|
||||||
android:textSize="13sp" />
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/txtMesasLivresDash"
|
android:id="@+id/txtMesasLivresDash"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="6dp"
|
android:layout_marginTop="12dp"
|
||||||
android:text="00"
|
android:text="0"
|
||||||
android:textColor="@color/colorTextPrimary"
|
android:textColor="@color/colorTextPrimary"
|
||||||
android:textSize="30sp"
|
android:textSize="28sp"
|
||||||
android:fontFamily="sans-serif-medium" />
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="Mesas Livres"
|
||||||
|
android:textColor="@color/colorTextSecondary"
|
||||||
|
android:textSize="12sp" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</com.google.android.material.card.MaterialCardView>
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
<!-- Espera -->
|
||||||
<com.google.android.material.card.MaterialCardView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="120dp"
|
||||||
android:layout_marginStart="6dp"
|
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
|
android:layout_marginStart="6dp"
|
||||||
app:cardBackgroundColor="@color/colorSurface"
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
app:cardCornerRadius="16dp"
|
app:cardCornerRadius="20dp"
|
||||||
app:cardElevation="2dp">
|
app:cardElevation="2dp">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:gravity="center"
|
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
android:padding="16dp">
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_menu_recent_history"
|
||||||
|
app:tint="#F44336" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/txtListaEsperaDash"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="12dp"
|
||||||
|
android:text="0"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="28sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="Espera"
|
android:text="Espera"
|
||||||
android:textColor="@color/colorTextSecondary"
|
android:textColor="@color/colorTextSecondary"
|
||||||
android:textSize="13sp" />
|
android:textSize="12sp" />
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/txtListaEsperaDash"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="6dp"
|
|
||||||
android:text="00"
|
|
||||||
android:textColor="@color/colorWarning"
|
|
||||||
android:textSize="30sp"
|
|
||||||
android:fontFamily="sans-serif-medium" />
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</com.google.android.material.card.MaterialCardView>
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- PROXIMAS RESERVAS -->
|
||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="40dp"
|
android:layout_marginTop="32dp"
|
||||||
android:text="Próximas reservas"
|
android:text="Próximas Reservas"
|
||||||
android:textColor="@color/colorTextPrimary"
|
android:textColor="@color/colorTextPrimary"
|
||||||
android:textSize="20sp"
|
android:textSize="20sp"
|
||||||
android:fontFamily="sans-serif-medium" />
|
android:fontFamily="sans-serif-medium" />
|
||||||
@@ -198,107 +256,12 @@
|
|||||||
android:layout_marginTop="16dp"
|
android:layout_marginTop="16dp"
|
||||||
app:cardBackgroundColor="@color/colorSurface"
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
app:cardCornerRadius="20dp"
|
app:cardCornerRadius="20dp"
|
||||||
app:cardElevation="4dp">
|
app:cardElevation="1dp"
|
||||||
|
app:strokeWidth="1dp"
|
||||||
|
app:strokeColor="#1A000000">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/llProximasReservas"
|
android:id="@+id/llProximasReservas"
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:orientation="vertical"
|
|
||||||
android:padding="24dp">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:text="A procurar próximas reservas..."
|
|
||||||
android:textColor="@color/colorTextSecondary"
|
|
||||||
android:textSize="15sp" />
|
|
||||||
</LinearLayout>
|
|
||||||
</com.google.android.material.card.MaterialCardView>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="40dp"
|
|
||||||
android:text="Operações rápidas"
|
|
||||||
android:textColor="@color/colorTextPrimary"
|
|
||||||
android:textSize="20sp"
|
|
||||||
android:fontFamily="sans-serif-medium" />
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="16dp"
|
|
||||||
android:orientation="vertical">
|
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
|
||||||
android:id="@+id/btnAbrirEspera"
|
|
||||||
style="@style/Widget.Material3.Button.TonalButton"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="56dp"
|
|
||||||
android:layout_marginBottom="12dp"
|
|
||||||
app:cornerRadius="14dp"
|
|
||||||
android:text="Abrir lista de espera"
|
|
||||||
android:textAllCaps="false"
|
|
||||||
android:textSize="16sp" />
|
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
|
||||||
android:id="@+id/btnGerirMesas"
|
|
||||||
style="@style/Widget.Material3.Button.OutlinedButton"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="56dp"
|
|
||||||
android:layout_marginBottom="12dp"
|
|
||||||
app:cornerRadius="14dp"
|
|
||||||
android:text="Editar mesas"
|
|
||||||
android:textAllCaps="false"
|
|
||||||
android:textSize="16sp" />
|
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
|
||||||
android:id="@+id/btnDetalhesReservas"
|
|
||||||
style="@style/Widget.Material3.Button.OutlinedButton"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="56dp"
|
|
||||||
android:layout_marginBottom="12dp"
|
|
||||||
app:cornerRadius="14dp"
|
|
||||||
android:text="Detalhes das reservas"
|
|
||||||
android:textAllCaps="false"
|
|
||||||
android:textSize="16sp" />
|
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
|
||||||
android:id="@+id/btnGestaoStaff"
|
|
||||||
style="@style/Widget.Material3.Button.OutlinedButton"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="56dp"
|
|
||||||
android:layout_marginBottom="12dp"
|
|
||||||
app:cornerRadius="14dp"
|
|
||||||
android:text="Gestão de staff"
|
|
||||||
android:textAllCaps="false"
|
|
||||||
android:textSize="16sp" />
|
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
|
||||||
android:id="@+id/btnDefinicoes"
|
|
||||||
style="@style/Widget.Material3.Button.OutlinedButton"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="56dp"
|
|
||||||
android:layout_marginBottom="24dp"
|
|
||||||
app:cornerRadius="14dp"
|
|
||||||
android:text="Definições"
|
|
||||||
android:textAllCaps="false"
|
|
||||||
android:textSize="16sp" />
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
<com.google.android.material.card.MaterialCardView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginBottom="24dp"
|
|
||||||
app:cardBackgroundColor="@color/colorSurface"
|
|
||||||
app:cardCornerRadius="20dp"
|
|
||||||
app:strokeWidth="1dp"
|
|
||||||
app:strokeColor="@color/colorWarning"
|
|
||||||
app:cardElevation="2dp">
|
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical"
|
||||||
@@ -307,23 +270,208 @@
|
|||||||
<TextView
|
<TextView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="Alertas operacionais"
|
android:text="A procurar próximas reservas..."
|
||||||
android:textColor="@color/colorTextPrimary"
|
|
||||||
android:textSize="16sp"
|
|
||||||
android:fontFamily="sans-serif-medium" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="8dp"
|
|
||||||
android:text="• Mesa 07 aguarda confirmação há 10 min\n• 2 clientes aguardam resposta no chat"
|
|
||||||
android:textColor="@color/colorTextSecondary"
|
android:textColor="@color/colorTextSecondary"
|
||||||
android:lineSpacingExtra="4dp"
|
|
||||||
android:textSize="14sp" />
|
android:textSize="14sp" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
</com.google.android.material.card.MaterialCardView>
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
</LinearLayout>
|
<!-- ACCOES RAPIDAS -->
|
||||||
</ScrollView>
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="32dp"
|
||||||
|
android:text="Ações Rápidas"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="20sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
<!-- GRID OF ACTIONS -->
|
||||||
|
<GridLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="16dp"
|
||||||
|
android:layout_marginBottom="40dp"
|
||||||
|
android:columnCount="2"
|
||||||
|
android:useDefaultMargins="true">
|
||||||
|
|
||||||
|
<!-- ACTION 1 -->
|
||||||
|
<com.google.android.material.card.MaterialCardView
|
||||||
|
android:id="@+id/btnDetalhesReservas"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_columnWeight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:focusable="true"
|
||||||
|
android:layout_margin="6dp"
|
||||||
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
|
app:cardCornerRadius="16dp"
|
||||||
|
app:cardElevation="2dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_menu_agenda"
|
||||||
|
app:tint="@color/colorTextPrimary" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="12dp"
|
||||||
|
android:text="Todas as\nReservas"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
</LinearLayout>
|
||||||
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
<!-- ACTION 2 -->
|
||||||
|
<com.google.android.material.card.MaterialCardView
|
||||||
|
android:id="@+id/btnAbrirEspera"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_columnWeight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:focusable="true"
|
||||||
|
android:layout_margin="6dp"
|
||||||
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
|
app:cardCornerRadius="16dp"
|
||||||
|
app:cardElevation="2dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_menu_add"
|
||||||
|
app:tint="@color/colorTextPrimary" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="12dp"
|
||||||
|
android:text="Adicionar à\nEspera"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
</LinearLayout>
|
||||||
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
<!-- ACTION 3 -->
|
||||||
|
<com.google.android.material.card.MaterialCardView
|
||||||
|
android:id="@+id/btnGerirMesas"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_columnWeight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:focusable="true"
|
||||||
|
android:layout_margin="6dp"
|
||||||
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
|
app:cardCornerRadius="16dp"
|
||||||
|
app:cardElevation="2dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_menu_crop"
|
||||||
|
app:tint="@color/colorTextPrimary" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="12dp"
|
||||||
|
android:text="Gerir\nMesas"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
</LinearLayout>
|
||||||
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
<!-- ACTION 4 -->
|
||||||
|
<com.google.android.material.card.MaterialCardView
|
||||||
|
android:id="@+id/btnGestaoStaff"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_columnWeight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:focusable="true"
|
||||||
|
android:layout_margin="6dp"
|
||||||
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
|
app:cardCornerRadius="16dp"
|
||||||
|
app:cardElevation="2dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_menu_info_details"
|
||||||
|
app:tint="@color/colorTextPrimary" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="12dp"
|
||||||
|
android:text="Gestão\nde Staff"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
</LinearLayout>
|
||||||
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
<!-- ACTION 5 -->
|
||||||
|
<com.google.android.material.card.MaterialCardView
|
||||||
|
android:id="@+id/btnDefinicoes"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_columnWeight="1"
|
||||||
|
android:clickable="true"
|
||||||
|
android:focusable="true"
|
||||||
|
android:layout_margin="6dp"
|
||||||
|
app:cardBackgroundColor="@color/colorSurface"
|
||||||
|
app:cardCornerRadius="16dp"
|
||||||
|
app:cardElevation="2dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:padding="16dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:src="@android:drawable/ic_menu_preferences"
|
||||||
|
app:tint="@color/colorTextPrimary" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="12dp"
|
||||||
|
android:text="Definições\nda Conta"
|
||||||
|
android:textColor="@color/colorTextPrimary"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:fontFamily="sans-serif-medium" />
|
||||||
|
</LinearLayout>
|
||||||
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
|
</GridLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</androidx.core.widget.NestedScrollView>
|
||||||
|
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||||
|
|||||||
Reference in New Issue
Block a user