Merge branch 'develop' into api-v2

This commit is contained in:
Kuba Szczodrzyński
2019-10-03 21:07:17 +02:00
268 changed files with 3573 additions and 2962 deletions

View File

@ -6,7 +6,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".messages.MessagesComposeActivity">
tools:context=".ui.modules.messages.MessagesComposeActivity">
<androidx.appcompat.widget.Toolbar
android:id="@+id/toolbar"
@ -67,4 +67,4 @@
</FrameLayout>
</LinearLayout>
</layout>
</layout>

View File

@ -7,7 +7,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".activities.FeedbackActivity">
tools:context=".ui.modules.feedback.FeedbackActivity">
<androidx.appcompat.widget.Toolbar
android:id="@+id/toolbar"
@ -147,4 +147,4 @@
</LinearLayout>
</LinearLayout>
</layout>
</layout>

View File

@ -17,147 +17,154 @@
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
app:popupTheme="@style/ThemeOverlay.AppCompat.Light" />
<LinearLayout
<ScrollView
android:id="@+id/webPushConfig"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<TextView
android:id="@+id/textView8"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:text="Przekazywanie powiadomień pozwala przesyłać wszystkie powiadomienia z tego urządzenia na wszystkie sparowane komputery, widoczne poniżej.\n\nPowiadomienia będą się wyświetlać w przeglądarce, w okienku pop-up, w prawym dolnym rogu ekranu.\n\nLista komputerów docelowych jest niezależna od wybranego profilu ucznia." />
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="@dimen/section_margin_top"
android:layout_marginEnd="8dp"
android:layout_marginRight="8dp"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/web_push_configured_browsers"
android:textAllCaps="true"
android:textColor="?attr/colorSection"
android:textStyle="bold" />
<View
android:layout_width="match_parent"
android:layout_height="@dimen/section_underline_height"
android:layout_marginTop="2dp"
android:background="?attr/colorSection" />
</LinearLayout>
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TableLayout
android:id="@+id/browserList"
android:id="@+id/textView8"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:shrinkColumns="0"
android:stretchColumns="0">
android:text="Przekazywanie powiadomień pozwala przesyłać wszystkie powiadomienia z tego urządzenia na wszystkie sparowane komputery, widoczne poniżej.\n\nPowiadomienia będą się wyświetlać w przeglądarce, w okienku pop-up, w prawym dolnym rogu ekranu.\n\nLista komputerów docelowych jest niezależna od wybranego profilu ucznia." />
<!--<TableRow
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="@dimen/section_margin_top"
android:layout_marginEnd="8dp"
android:layout_marginRight="8dp"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="end">
android:layout_height="wrap_content"
android:text="@string/web_push_configured_browsers"
android:textAllCaps="true"
android:textColor="?attr/colorSection"
android:textStyle="bold" />
<TextView
<View
android:layout_width="match_parent"
android:layout_height="@dimen/section_underline_height"
android:layout_marginTop="2dp"
android:background="?attr/colorSection" />
</LinearLayout>
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TableLayout
android:id="@+id/browserList"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:shrinkColumns="0"
android:stretchColumns="0">
<!--<TableRow
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginRight="8dp"
android:gravity="center_vertical"
android:text="Chrome 70.0.3538.102 @ Windows 7 64-bit" />
android:gravity="end">
<Button
android:id="@+id/button6"
style="@style/Widget.AppCompat.Button.Small"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:minHeight="0dp"
android:minWidth="0dp"
android:text="Usuń" />
<TextView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginRight="8dp"
android:gravity="center_vertical"
android:text="Chrome 70.0.3538.102 @ Windows 7 64-bit" />
</TableRow>-->
<Button
android:id="@+id/button6"
style="@style/Widget.AppCompat.Button.Small"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:minHeight="0dp"
android:minWidth="0dp"
android:text="Usuń" />
</TableLayout>
</TableRow>-->
<ProgressBar
android:id="@+id/browserListProgressBar"
style="?android:attr/progressBarStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:visibility="invisible" />
</TableLayout>
<TextView
android:id="@+id/browserListErrorText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:textSize="18sp"
android:textStyle="italic"
android:visibility="visible"
android:text="@string/web_push_no_browsers" />
<ProgressBar
android:id="@+id/browserListProgressBar"
style="?android:attr/progressBarStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:visibility="invisible" />
</FrameLayout>
<TextView
android:id="@+id/browserListErrorText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:textSize="18sp"
android:textStyle="italic"
android:visibility="visible"
android:text="@string/web_push_no_browsers" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="@dimen/section_margin_top"
android:layout_marginEnd="8dp"
android:layout_marginRight="8dp"
android:orientation="vertical">
</FrameLayout>
<TextView
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/web_push_pair_browser"
android:textAllCaps="true"
android:textColor="?attr/colorSection"
android:textStyle="bold" />
android:layout_marginStart="8dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="@dimen/section_margin_top"
android:layout_marginEnd="8dp"
android:layout_marginRight="8dp"
android:orientation="vertical">
<View
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/web_push_pair_browser"
android:textAllCaps="true"
android:textColor="?attr/colorSection"
android:textStyle="bold" />
<View
android:layout_width="match_parent"
android:layout_height="@dimen/section_underline_height"
android:layout_marginTop="2dp"
android:background="?attr/colorSection" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="@dimen/section_underline_height"
android:layout_marginTop="2dp"
android:background="?attr/colorSection" />
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="8dp"
android:orientation="horizontal">
<TextView
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:text="W przeglądarce na komputerze wejdź na stronę\n\nhttp://edziennik.szczodrzynski.pl/wp\n\nUdziel zgody na wysyłanie powiadomień, następnie zeskanuj wygenerowany kod QR.\n\nPod tym samym adresem możesz zarządzać listą sparowanych z przeglądarką urządzeń.\n\nJeśli sparujesz kilka urządzeń z tą samą przeglądarką, możesz otrzymywać te same powiadomienia kilkukrotnie." />
<Button
android:id="@+id/webPushScanNewButton"
style="@style/Widget.AppCompat.Button.Small"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Skanuj..." />
</LinearLayout>
android:layout_margin="8dp"
android:orientation="vertical">
</LinearLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:text="W przeglądarce na komputerze wejdź na stronę\n\nhttp://edziennik.szczodrzynski.pl/wp\n\nUdziel zgody na wysyłanie powiadomień, następnie zeskanuj wygenerowany kod QR.\n\nPod tym samym adresem możesz zarządzać listą sparowanych z przeglądarką urządzeń.\n\nJeśli sparujesz kilka urządzeń z tą samą przeglądarką, możesz otrzymywać te same powiadomienia kilkukrotnie." />
<Button
android:id="@+id/webPushScanNewButton"
style="@style/Widget.AppCompat.Button.Small"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:text="Skanuj..." />
</LinearLayout>
</LinearLayout>
</ScrollView>
<me.dm7.barcodescanner.zxing.ZXingScannerView
android:id="@+id/qrCodeScanner"
@ -168,4 +175,4 @@
</me.dm7.barcodescanner.zxing.ZXingScannerView>
</LinearLayout>
</layout>
</layout>

View File

@ -9,8 +9,8 @@
<include
layout="@layout/row_dialog_lesson_change_item"
layout="@layout/row_lesson_change_item"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1" />
</com.github.tibolte.agendacalendarview.agenda.AgendaEventView>
</com.github.tibolte.agendacalendarview.agenda.AgendaEventView>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<com.github.tibolte.agendacalendarview.agenda.AgendaEventView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:orientation="horizontal">
<include
layout="@layout/row_teacher_absence_item"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1" />
</com.github.tibolte.agendacalendarview.agenda.AgendaEventView>

View File

@ -1,25 +1,38 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto">
<LinearLayout
android:id="@+id/detailsLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
android:layout_height="match_parent"
android:orientation="vertical">
<include
android:id="@+id/lesson_change_container"
layout="@layout/row_dialog_lesson_change_item"
android:id="@+id/lessonChangeContainer"
layout="@layout/row_lesson_change_item"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="5dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:layout_marginLeft="24dp"
android:layout_marginRight="24dp"
android:visibility="gone"
tools:visibility="visible" />
<include
android:id="@+id/teacherAbsenceContainer"
layout="@layout/row_teacher_absence_item"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:layout_marginLeft="24dp"
android:layout_marginRight="24dp"
android:visibility="gone"
tools:visibility="visible" />
@ -27,6 +40,8 @@
android:id="@+id/eventListLessonDetails"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="24dp"
android:layout_marginRight="24dp"
android:orientation="vertical">
<TextView
@ -57,34 +72,28 @@
tools:text="029 informatyczna -> 016 językowa" />
</LinearLayout>
<TextView
android:id="@+id/textNoEvents"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_margin="32dp"
android:text="@string/dialog_event_list_no_data"
android:textStyle="italic"
android:visibility="gone" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/eventListView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:clipToPadding="false"
android:paddingLeft="24dp"
android:paddingTop="8dp"
android:paddingRight="24dp"
android:paddingBottom="8dp"
tools:listitem="@layout/row_dialog_event_list_item" />
</LinearLayout>
<TextView
android:id="@+id/textNoEvents"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
android:text="@string/dialog_event_list_no_data"
android:textStyle="italic"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/detailsLayout" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/eventListView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/detailsLayout"
tools:listitem="@layout/row_dialog_event_list_item">
</androidx.recyclerview.widget.RecyclerView>
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.core.widget.NestedScrollView>

View File

@ -5,11 +5,11 @@
<data>
<import type="android.view.View"/>
<import type="pl.szczodrzynski.edziennik.utils.Utils"/>
<import type="pl.szczodrzynski.edziennik.models.Date"/>
<import type="pl.szczodrzynski.edziennik.models.Time"/>
<import type="pl.szczodrzynski.edziennik.utils.models.Date"/>
<import type="pl.szczodrzynski.edziennik.utils.models.Time"/>
<variable
name="grade"
type="pl.szczodrzynski.edziennik.datamodels.GradeFull" />
type="pl.szczodrzynski.edziennik.data.db.modules.grades.GradeFull" />
<variable
name="historyVisible"
type="boolean" />

View File

@ -1,14 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/lessonChangeView"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:listitem="@layout/row_timetable_item" />
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/lessonChangeView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingTop="8dp"
android:paddingBottom="8dp"
android:paddingLeft="24dp"
android:paddingRight="24dp"
android:clipToPadding="false"
tools:listitem="@layout/row_timetable_item" />
</layout>

View File

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/teacherAbsenceView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingTop="8dp"
android:paddingBottom="8dp"
android:paddingLeft="24dp"
android:paddingRight="24dp"
android:clipToPadding="false"
tools:listitem="@layout/row_dialog_teacher_absence_item" />
</layout>

View File

@ -27,7 +27,7 @@
android:orientation="vertical">
<TextView
android:id="@+id/attendancesSummaryTitle"
android:id="@+id/attendanceSummaryTitle"
style="@style/Widget.AppCompat.Spinner"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -36,7 +36,7 @@
android:textSize="20sp" />
<TextView
android:id="@+id/attendancesSummarySubject"
android:id="@+id/attendanceSummarySubject"
style="@style/Widget.AppCompat.Spinner"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -168,7 +168,7 @@
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/attendancesView"
android:id="@+id/attendance_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="8dp"
@ -177,7 +177,7 @@
</androidx.recyclerview.widget.RecyclerView>
<LinearLayout
android:id="@+id/attendancesNoData"
android:id="@+id/attendance_no_data"
android:layout_width="match_parent"
android:orientation="vertical"
android:gravity="center"
@ -206,4 +206,4 @@
</FrameLayout>
</LinearLayout>
</pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator>
</layout>
</layout>

View File

@ -4,7 +4,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".fragments.DebugFragment">
tools:context=".ui.modules.base.DebugFragment">
<!-- TODO: Update blank fragment layout -->
<com.google.android.material.textfield.TextInputLayout

View File

@ -16,7 +16,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
tools:context=".fragments.HomeFragment">
tools:context=".ui.modules.home.HomeFragment">
<LinearLayout
android:id="@+id/cardInsertPoint"
@ -88,4 +88,4 @@
</LinearLayout>
</ScrollView>
</pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator>
</layout>
</layout>

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<layout 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">
<pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator
android:id="@+id/refreshLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<com.google.android.material.tabs.TabLayout
android:id="@+id/tabLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/colorSurface_6dp"
app:tabIndicatorColor="?colorPrimary"
app:tabMode="auto"
app:tabSelectedTextColor="?colorPrimary"
app:tabTextColor="?android:textColorPrimary" />
<androidx.viewpager.widget.ViewPager
android:id="@+id/viewPager"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
</LinearLayout>
</pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator>
</layout>

View File

@ -1,121 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto">
<pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator
android:id="@+id/refreshLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="8dp"
android:fontFamily="sans-serif-medium"
android:text="@string/homework_current_title"
android:textSize="20sp" />
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="8dp"
android:layout_weight="2">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/homeworksCurrentView"
android:layout_width="match_parent"
android:layout_height="match_parent">
</androidx.recyclerview.widget.RecyclerView>
<LinearLayout
android:id="@+id/homeworksCurrentNoData"
android:layout_width="match_parent"
android:orientation="vertical"
android:gravity="center"
android:layout_height="match_parent"
android:visibility="gone"
tools:visibility="visible">
<com.mikepenz.iconics.view.IconicsImageView
android:layout_width="match_parent"
android:layout_height="92dp"
app:iiv_color="?android:textColorPrimary"
app:iiv_icon="szf-file-document-edit"
app:iiv_size="92dp" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:fontFamily="sans-serif-medium"
android:gravity="center"
android:text="@string/homework_current_no_data"
android:textSize="18sp"
android:textStyle="italic" />
</LinearLayout>
</FrameLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="8dp"
android:fontFamily="sans-serif-medium"
android:text="@string/homework_past_title"
android:textSize="20sp" />
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="8dp"
android:layout_weight="3">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/homeworksPastView"
android:layout_width="match_parent"
android:layout_height="match_parent">
</androidx.recyclerview.widget.RecyclerView>
<LinearLayout
android:id="@+id/homeworksPastNoData"
android:layout_width="match_parent"
android:orientation="vertical"
android:gravity="center"
android:layout_height="match_parent"
android:visibility="gone"
tools:visibility="visible">
<com.mikepenz.iconics.view.IconicsImageView
android:layout_width="match_parent"
android:layout_height="92dp"
app:iiv_color="?android:textColorPrimary"
app:iiv_icon="szf-file-document-edit"
app:iiv_size="92dp" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:fontFamily="sans-serif-medium"
android:gravity="center"
android:text="@string/homework_past_no_data"
android:textSize="18sp"
android:textStyle="italic" />
</LinearLayout>
</FrameLayout>
</LinearLayout>
</pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator>
</layout>

View File

@ -0,0 +1,47 @@
<?xml version="1.0" encoding="utf-8"?>
<layout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/homeworkView"
android:layout_width="match_parent"
android:layout_height="match_parent">
</androidx.recyclerview.widget.RecyclerView>
<LinearLayout
android:id="@+id/homeworkNoData"
android:layout_width="match_parent"
android:orientation="vertical"
android:gravity="center"
android:layout_height="match_parent"
android:visibility="gone"
tools:visibility="visible">
<com.mikepenz.iconics.view.IconicsImageView
android:layout_width="match_parent"
android:layout_height="92dp"
app:iiv_color="?android:textColorPrimary"
app:iiv_icon="szf-file-document-edit"
app:iiv_size="92dp" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:fontFamily="sans-serif-medium"
android:gravity="center"
android:text="@string/homework_no_data"
android:textSize="18sp"
android:textStyle="italic" />
</LinearLayout>
</LinearLayout>
</layout>

View File

@ -5,20 +5,14 @@
android:layout_width="match_parent"
android:layout_height="match_parent">
<pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator
android:id="@+id/refreshLayout"
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/emailList"
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/emailList"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clipChildren="false"
android:transitionGroup="false"
tools:listitem="@layout/messages_item"
tools:targetApi="lollipop" />
</pl.szczodrzynski.edziennik.utils.SwipeRefreshLayoutNoIndicator>
android:layout_height="match_parent"
android:clipChildren="false"
android:transitionGroup="false"
tools:listitem="@layout/messages_item"
tools:targetApi="lollipop" />
<ProgressBar
android:id="@+id/progressBar"
@ -26,4 +20,4 @@
android:layout_height="wrap_content"
android:layout_gravity="center"/>
</FrameLayout>
</layout>
</layout>

View File

@ -0,0 +1,41 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
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:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.google.android.material.card.MaterialCardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="4dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="4dp"
android:background="?selectableItemBackground"
app:cardCornerRadius="5dp"
app:cardElevation="4dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:padding="8dp">
<TextView
android:id="@+id/teacherAbsenceTime"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textAppearance="@style/NavView.TextView.Helper"
tools:text="2 września - 5 kwietnia"/>
<TextView
android:id="@+id/teacherAbsenceTeacher"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:text="Jan Kowalski"/>
</LinearLayout>
</com.google.android.material.card.MaterialCardView>
</LinearLayout>

View File

@ -7,7 +7,7 @@
android:orientation="vertical">
<com.google.android.material.card.MaterialCardView
android:id="@+id/homeworksItemCard"
android:id="@+id/homeworkItemCard"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
@ -31,7 +31,7 @@
android:orientation="horizontal">
<TextView
android:id="@+id/homeworksItemHomeworkDate"
android:id="@+id/homeworkItemHomeworkDate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="16dp"
@ -41,7 +41,7 @@
android:layout_marginEnd="16dp" />
<com.mikepenz.iconics.view.IconicsTextView
android:id="@+id/homeworksItemSharedBy"
android:id="@+id/homeworkItemSharedBy"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
@ -61,7 +61,7 @@
android:orientation="horizontal">
<TextView
android:id="@+id/homeworksItemTopic"
android:id="@+id/homeworkItemTopic"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
@ -72,7 +72,7 @@
tools:text="topic???" />
<com.google.android.material.button.MaterialButton
android:id="@+id/homeworksItemEdit"
android:id="@+id/homeworkItemEdit"
style="@style/Widget.MaterialComponents.Button.OutlinedButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@ -89,7 +89,7 @@
android:orientation="horizontal">
<TextView
android:id="@+id/homeworksItemSubjectTeacher"
android:id="@+id/homeworkItemSubjectTeacher"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginRight="8dp"
@ -100,7 +100,7 @@
tools:text="subjectName, teacherName" />
<TextView
android:id="@+id/homeworksItemTeamDate"
android:id="@+id/homeworkItemTeamDate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
@ -110,4 +110,4 @@
</com.google.android.material.card.MaterialCardView>
</LinearLayout>
</LinearLayout>

View File

@ -1,7 +1,7 @@
<androidx.cardview.widget.CardView android:id="@+id/lesson_change_card"
android:layout_width="match_parent"
android:layout_height="wrap_content"
tools:cardBackgroundColor="@color/blue_selected"
tools:cardBackgroundColor="#78909c"
app:cardCornerRadius="5dp"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
@ -23,7 +23,7 @@
android:text="@string/agenda_lesson_changes" />
<TextView
android:id="@+id/lesson_change_count"
android:id="@+id/lessonChangeCount"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:gravity="center"
@ -32,4 +32,4 @@
</LinearLayout>
</androidx.cardview.widget.CardView>
</androidx.cardview.widget.CardView>

View File

@ -0,0 +1,35 @@
<androidx.cardview.widget.CardView android:id="@+id/teacherAbsenceCard"
android:layout_width="match_parent"
android:layout_height="wrap_content"
tools:cardBackgroundColor="#ff1744"
app:cardCornerRadius="5dp"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="10dp">
<TextView
android:id="@+id/teacherAbsenceText"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center_vertical"
android:textAppearance="@style/NavView.TextView.Medium"
android:text="@string/agenda_teacher_absence" />
<TextView
android:id="@+id/teacherAbsenceCount"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:gravity="center"
android:textSize="20sp"
tools:text="3" />
</LinearLayout>
</androidx.cardview.widget.CardView>