from muschinkina_maria

This commit is contained in:
mariamusinkina 2025-02-19 20:05:53 +05:00
parent a15f1fb00e
commit 8099193a1a
32 changed files with 924 additions and 824 deletions

View File

@ -1,121 +1,170 @@
<?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">
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/refresh"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
android:layout_marginHorizontal="20dp"
android:layout_marginTop="50dp"
app:layout_constraintTop_toTopOf="parent"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:gravity="center">
<ImageView
android:id="@+id/photo"
tools:src="@mipmap/ic_launcher"
android:layout_width="130dp"
android:layout_height="130dp"
android:layout_marginEnd="60dp"/>
<LinearLayout
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:gravity="center">
<TextView
android:textAlignment="center"
android:id="@+id/fullname"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:fontFamily="@font/manrope_bold"
android:textSize="24sp"
android:textStyle="bold"
android:maxWidth="280dp"
tools:text="Алексеев Виталий Александрович" />
<TextView
android:layout_marginTop="4dp"
android:textColor="@color/main_button_color"
android:id="@+id/position"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:text="Начальник" />
android:layout_height="match_parent">
<LinearLayout
android:layout_marginTop="4dp"
android:layout_width="280dp"
android:layout_height="wrap_content"
android:gravity="center_horizontal">
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginHorizontal="20dp"
android:layout_marginTop="50dp"
android:gravity="center"
android:orientation="vertical">
<TextView
android:layout_marginEnd="4dp"
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/last_visit" />
android:orientation="horizontal">
<TextView
android:fontFamily="@font/manrope_light"
android:id="@+id/lastEntry"
android:layout_width="wrap_content"
<ImageView
android:id="@+id/photo"
android:layout_width="130dp"
android:layout_height="130dp"
android:layout_marginEnd="60dp"
tools:src="@mipmap/ic_launcher" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical">
<TextView
android:id="@+id/fullname"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:fontFamily="@font/manrope_bold"
android:maxWidth="280dp"
android:textAlignment="center"
android:textSize="24sp"
android:textStyle="bold"
tools:text="Алексеев Виталий Александрович" />
<TextView
android:id="@+id/position"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:textColor="@color/main_button_color"
tools:text="Начальник" />
<LinearLayout
android:layout_width="280dp"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:gravity="center_horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="4dp"
android:text="@string/last_visit" />
<TextView
android:id="@+id/lastEntry"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:fontFamily="@font/manrope_light"
tools:text="19.09.24:10:00:01" />
</LinearLayout>
<TextView
android:id="@+id/error"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:textColor="@color/warn_button_color"
tools:text="Some error" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
tools:text="19.09.24:10:00:01" />
android:layout_marginHorizontal="20dp"
android:layout_marginTop="40dp"
android:orientation="vertical">
<Button
android:id="@+id/find_user"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:background="@drawable/main_button"
android:foreground="?attr/selectableItemBackground"
android:text="@string/find_employee_button_text"
android:textColor="@color/white"
android:visibility="gone"
tools:visibility="visible" />
<Button
android:id="@+id/scan"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:background="@drawable/main_button"
android:foreground="?attr/selectableItemBackground"
android:text="@string/scan_qr_text"
android:textColor="@color/white" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:orientation="horizontal">
<Button
android:id="@+id/block"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="@drawable/warn_button_outline"
android:foreground="?attr/selectableItemBackground"
android:text="@string/block_card_button_text"
android:textColor="@color/warn_button_color" />
<ImageButton
android:id="@+id/logout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:background="@drawable/warn_button"
android:padding="12dp"
android:src="@drawable/exit" />
</LinearLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="24dp"
android:layout_marginTop="32dp"
android:text="@string/card_using_header"
android:textFontWeight="600"
android:textSize="21sp" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/passes"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginHorizontal="20dp"
android:layout_marginTop="16dp"
tools:listitem="@layout/pass_item">
</androidx.recyclerview.widget.RecyclerView>
</LinearLayout>
</LinearLayout>
<TextView
android:layout_marginTop="8dp"
android:textColor="@color/warn_button_color"
android:id="@+id/error"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:text="Some error"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_marginBottom="10dp"
android:layout_marginHorizontal="20dp"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<Button
android:foreground="?attr/selectableItemBackground"
android:textColor="@color/warn_button_color"
android:id="@+id/logout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/logout_text"
android:background="@drawable/warn_button_outline"/>
<Button
android:foreground="?attr/selectableItemBackground"
android:textColor="@color/main_button_color"
android:layout_marginTop="10dp"
android:id="@+id/refresh"
android:text="@string/refresh_data"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/main_button_outline"/>
<Button
android:foreground="?attr/selectableItemBackground"
android:background="@drawable/main_button"
android:textColor="@color/white"
android:layout_marginTop="10dp"
android:id="@+id/scan"
android:text="@string/scan_qr_text"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
</androidx.constraintlayout.widget.ConstraintLayout>

View File

@ -35,7 +35,7 @@
<EditText
android:inputType="textPassword"
android:layout_marginTop="24dp"
android:layout_marginTop="8dp"
android:paddingHorizontal="20dp"
android:fontFamily="@font/manrope_light"
android:id="@+id/password"

View File

@ -6,106 +6,151 @@
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/refresh"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginHorizontal="20dp"
android:layout_marginTop="130dp">
android:layout_marginTop="60dp"
android:orientation="vertical">
<LinearLayout
android:id="@+id/content"
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
android:layout_height="match_parent">
<LinearLayout
android:id="@+id/content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_horizontal"
android:layout_height="match_parent"
android:orientation="vertical">
<ImageView
android:id="@+id/photo"
android:layout_width="130dp"
android:layout_height="130dp"
tools:src="@mipmap/ic_launcher" />
<TextView
android:id="@+id/fullname"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:fontFamily="@font/manrope_bold"
android:maxWidth="280dp"
android:textAlignment="center"
android:textSize="24sp"
android:textStyle="bold"
tools:text="Алексеев Виталий Александрович" />
<TextView
android:id="@+id/position"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:textColor="@color/main_button_color"
tools:text="Начальник" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:gravity="center_horizontal">
android:gravity="center_horizontal"
android:orientation="vertical">
<ImageView
android:id="@+id/photo"
android:layout_width="130dp"
android:layout_height="130dp"
tools:src="@mipmap/ic_launcher" />
<TextView
android:id="@+id/fullname"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="4dp"
android:text="@string/last_visit" />
android:layout_marginTop="8dp"
android:fontFamily="@font/manrope_bold"
android:maxWidth="280dp"
android:textAlignment="center"
android:textSize="24sp"
android:textStyle="bold"
tools:text="Алексеев Виталий Александрович" />
<TextView
android:id="@+id/lastEntry"
android:id="@+id/position"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:fontFamily="@font/manrope_light"
tools:text="19.09.24:10:00:01" />
android:layout_marginTop="4dp"
android:textColor="@color/main_button_color"
tools:text="Начальник" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:gravity="center_horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginEnd="4dp"
android:text="@string/last_visit" />
<TextView
android:id="@+id/lastEntry"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:fontFamily="@font/manrope_light"
tools:text="19.09.24:10:00:01" />
</LinearLayout>
<Button
android:id="@+id/find_user"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="24dp"
android:background="@drawable/main_button"
android:foreground="?attr/selectableItemBackground"
android:text="@string/find_employee_button_text"
android:textColor="@color/white"
android:visibility="gone"
tools:visibility="visible" />
<Button
android:id="@+id/scan"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:background="@drawable/main_button"
android:foreground="?attr/selectableItemBackground"
android:text="@string/scan_qr_text"
android:textColor="@color/white" />
<TextView
android:id="@+id/error"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:textColor="@color/warn_button_color"
android:visibility="gone"
tools:text="Some error" />
</LinearLayout>
<Button
android:id="@+id/scan"
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="24dp"
android:background="@drawable/main_button"
android:foreground="?attr/selectableItemBackground"
android:text="@string/scan_qr_text"
android:textColor="@color/white" />
android:layout_marginTop="10dp"
android:orientation="horizontal">
<Button
android:id="@+id/block"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="@drawable/warn_button_outline"
android:foreground="?attr/selectableItemBackground"
android:text="@string/block_card_button_text"
android:textColor="@color/warn_button_color" />
<ImageButton
android:id="@+id/logout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:background="@drawable/warn_button"
android:padding="12dp"
android:src="@drawable/exit" />
</LinearLayout>
<TextView
android:id="@+id/error"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:textColor="@color/warn_button_color"
tools:text="Some error" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginHorizontal="20dp"
android:layout_marginTop="60dp"
android:orientation="vertical">
<Button
android:id="@+id/logout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@drawable/warn_button_outline"
android:foreground="?attr/selectableItemBackground"
android:text="@string/logout_text"
android:textColor="@color/warn_button_color" />
android:layout_marginStart="24dp"
android:layout_marginTop="32dp"
android:text="@string/card_using_header"
android:textFontWeight="600"
android:textSize="21sp" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/passes"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginHorizontal="20dp"
android:layout_marginTop="16dp"
tools:listitem="@layout/pass_item">
</androidx.recyclerview.widget.RecyclerView>
</LinearLayout>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
</androidx.constraintlayout.widget.ConstraintLayout>

View File

@ -11,4 +11,5 @@
<color name="warn_button_color">#D71A1E</color>
<color name="gray">#F8F8FA</color>
<color name="ripple">#FFFFFF</color>
<color name="dark_gray">#5B5B5B</color>
</resources>

View File

@ -13,4 +13,9 @@
<string name="last_visit">Последний вход: </string>
<string name="password_input_hint">Введите пароль</string>
<string name="register_process_button_text">Зарегестрироваться</string>
<string name="block_card_button_text">Заблокировать карту</string>
<string name="card_using_header">Использование пропуска</string>
<string name="find_employee_button_text">Поиск сотрудника</string>
<string name="find_button_text">Найти</string>
<string name="find_employee_header">Поиск сотрудника</string>
</resources>