Mensa Bild angepasst & links auf dem Dashboard hinzugefĆ¼gt
[DHBWCampusApp.git] / app / src / main / res / layout / fragment_dashboard.xml
index d6f19a59bdaf43c3ef2137bd65c3e21176bf0582..7947741f88bf28f9df8d2344464d08605bd710e2 100644 (file)
@@ -1,9 +1,189 @@
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:tools="http://schemas.android.com/tools"
+    xmlns:card_view="http://schemas.android.com/apk/res-auto"
     android:layout_width="match_parent"
     android:layout_height="match_parent"
-    tools:context=".fragments.Dashboard">
+    tools:context=".fragments.Dashboard"
+    android:orientation="vertical">
 
     <!-- TODO: Update blank fragment layout -->
+    <ScrollView
+        android:layout_width="wrap_content"
+        android:layout_height="match_parent"
+        android:id="@+id/scrollView5" >
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:orientation="vertical">
 
-</FrameLayout>
+            <android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
+                android:id="@+id/card_timetable"
+                android:layout_width="match_parent"
+                android:layout_height="180dp"
+                android:layout_margin="8dp"
+                card_view:cardCornerRadius="5dp">
+
+                <RelativeLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="match_parent">
+
+                    <ImageView
+                        android:layout_width="fill_parent"
+                        android:layout_height="70dp"
+                        android:id="@+id/timetable_image"
+                        android:layout_alignParentTop="true"
+                        android:layout_alignParentLeft="true"
+                        android:layout_alignParentStart="true"
+                        android:src="@drawable/header_kalender"
+                        android:scaleType="centerCrop" />
+
+                    <TextView
+                        android:id="@+id/title"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:maxLines="3"
+                        android:padding="8dp"
+                        android:text="@string/dashboard_calendar_title"
+                        android:textColor="#222"
+                        android:textStyle="bold"
+                        android:textSize="22dp" />
+
+                    <fragment
+                        android:layout_width="match_parent"
+                        android:layout_height="fill_parent"
+                        android:name="de.dhbwloe.campusapp.fragments.DashboardVorlesungsplan"
+                        android:layout_below="@+id/timetable_image"
+                        android:layout_alignParentLeft="true"
+                        android:layout_alignParentStart="true"
+                        android:id="@+id/fragment_timetable"
+                        tools:layout="@layout/fragment_dashboard_timetable" />
+
+                </RelativeLayout>
+            </android.support.v7.widget.CardView>
+
+            <android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
+                android:id="@+id/card_mensa"
+                android:layout_width="match_parent"
+                android:layout_height="220dp"
+                android:layout_margin="8dp"
+                card_view:cardCornerRadius="5dp">
+
+                <RelativeLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="match_parent">
+
+                    <ImageView
+                        android:layout_width="fill_parent"
+                        android:layout_height="80dp"
+                        android:id="@+id/mensa_image"
+                        android:layout_alignParentTop="true"
+                        android:layout_alignParentLeft="true"
+                        android:layout_alignParentStart="true"
+                        android:src="@drawable/dhbw_mensa"
+                        android:scaleType="centerCrop" />
+
+                    <TextView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:maxLines="3"
+                        android:padding="8dp"
+                        android:text="@string/dashboard_mensa_title"
+                        android:textColor="#222"
+                        android:textStyle="bold"
+                        android:textSize="22dp"
+                        android:id="@+id/textView15" />
+
+                    <fragment
+                        android:layout_width="match_parent"
+                        android:layout_height="fill_parent"
+                        android:name="de.dhbwloe.campusapp.fragments.DashboardMensa"
+                        android:id="@+id/fragment_mensa"
+                        android:layout_below="@+id/mensa_image"
+                        android:layout_alignParentLeft="true"
+                        android:layout_alignParentStart="true"
+                        tools:layout="@layout/fragment_dashboard_mensa_menu" />
+
+                </RelativeLayout>
+            </android.support.v7.widget.CardView>
+
+            <LinearLayout
+                android:orientation="horizontal"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content">
+
+                <android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
+                    android:id="@+id/card_view2"
+                    android:layout_width="wrap_content"
+                    android:layout_height="140dp"
+                    android:layout_margin="8dp"
+                    android:layout_weight="1"
+                    card_view:cardCornerRadius="5dp">
+
+                    <RelativeLayout
+                        android:layout_width="match_parent"
+                        android:layout_height="match_parent">
+
+                        <ImageView
+                            android:layout_width="wrap_content"
+                            android:layout_height="60dp"
+                            android:id="@+id/news_dhbw_image"
+                            android:layout_alignParentTop="true"
+                            android:layout_alignParentLeft="true"
+                            android:layout_alignParentStart="true"
+                            android:src="@drawable/header_dhbw"
+                            android:scaleType="fitCenter"
+                            android:background="#ffffff" />
+
+                        <fragment
+                            android:layout_width="match_parent"
+                            android:layout_height="fill_parent"
+                            android:name="de.dhbwloe.campusapp.fragments.DashboardNewsDhbw"
+                            android:id="@+id/fragment_dhbw"
+                            android:layout_below="@+id/news_dhbw_image"
+                            android:layout_alignParentLeft="true"
+                            android:layout_alignParentStart="true"
+                            tools:layout="@layout/fragment_dashboard_news_entry" />
+
+                    </RelativeLayout>
+                </android.support.v7.widget.CardView>
+
+                <android.support.v7.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
+                    android:id="@+id/card_view3"
+                    android:layout_width="wrap_content"
+                    android:layout_height="140dp"
+                    android:layout_margin="8dp"
+                    android:layout_weight="1"
+                    card_view:cardCornerRadius="5dp">
+
+                    <RelativeLayout
+                        android:layout_width="match_parent"
+                        android:layout_height="match_parent">
+
+                        <ImageView
+                            android:layout_width="wrap_content"
+                            android:layout_height="60dp"
+                            android:id="@+id/news_stuv_image"
+                            android:layout_alignParentTop="true"
+                            android:layout_alignParentLeft="true"
+                            android:layout_alignParentStart="true"
+                            android:src="@drawable/header_stuv"
+                            android:scaleType="fitCenter"
+                            android:background="#ffffff" />
+
+                        <fragment
+                            android:layout_width="match_parent"
+                            android:layout_height="fill_parent"
+                            android:name="de.dhbwloe.campusapp.fragments.DashboardNewsStuv"
+                            android:id="@+id/fragment_stuv"
+                            android:layout_below="@+id/news_stuv_image"
+                            android:layout_alignParentLeft="true"
+                            android:layout_alignParentStart="true"
+                            tools:layout="@layout/fragment_dashboard_news_none" />
+
+                    </RelativeLayout>
+                </android.support.v7.widget.CardView>
+
+            </LinearLayout>
+        </LinearLayout>
+    </ScrollView>
+</LinearLayout>