mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-28 05:13:53 +01:00
Added advanced query support in Nearby (#4714)
* Added feature for advanced query options in Nearby * Fix unit-tests coverage * wip-tests * Added log to identify if the nearby request is via an advanced query * Rolledback test-dependency updates * Fix tests * build fix * Added basic tests for relevant method in OkHttpJsonApiClient & NearbyController * Added NearbyParentFragmentPresenter Tests * Added AdvancedQueryFragment Unit Tests * Added more tests for NearbyParentFragmentPresenter * Reset ContributionsFragment with Upstream * Overload method loadNearbyPlaces for CustomQuery * Added more tests * Added more tests * Fixed tests for NearbyParentFragmentPresenter
This commit is contained in:
parent
bd00ce2071
commit
a0ff15cdc2
19 changed files with 823 additions and 47 deletions
54
app/src/main/res/layout/fragment_advance_query.xml
Normal file
54
app/src/main/res/layout/fragment_advance_query.xml
Normal file
|
|
@ -0,0 +1,54 @@
|
|||
<?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"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white"
|
||||
android:padding="10dp">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/tv_title"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/advanced_query_info_text"
|
||||
android:textColor="@color/secondaryTextColor"
|
||||
android:textStyle="bold"
|
||||
app:layout_constrainedHeight="true"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatEditText
|
||||
android:id="@+id/et_query"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/advanced_query_border"
|
||||
android:padding="5dp"
|
||||
android:textColor="@color/secondaryTextColor"
|
||||
app:layout_constrainedHeight="true"
|
||||
app:layout_constraintBottom_toTopOf="@id/btn_apply"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_title" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatButton
|
||||
android:id="@+id/btn_apply"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/apply"
|
||||
android:textColor="@color/white"
|
||||
app:layout_constrainedHeight="true"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatButton
|
||||
android:id="@+id/btn_reset"
|
||||
style="@style/Widget.AppCompat.Button.Borderless"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/reset"
|
||||
android:textColor="@color/mapbox_blue"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/btn_apply" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
|
@ -6,6 +6,9 @@
|
|||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
|
|
@ -129,6 +132,11 @@
|
|||
app:srcCompat="@drawable/ic_my_location_black_24dp"
|
||||
app:useCompatPadding="true" />
|
||||
|
||||
</RelativeLayout>
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_container_nearby_children"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
</RelativeLayout>
|
||||
|
||||
<include layout="@layout/bottom_sheet_nearby" />
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:elevation="@dimen/activity_margin_horizontal"
|
||||
android:background="@color/white">
|
||||
|
||||
|
|
@ -26,6 +26,15 @@
|
|||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginVertical="@dimen/dimen_10"
|
||||
android:paddingBottom="48dp"
|
||||
/>
|
||||
|
||||
<androidx.appcompat.widget.AppCompatButton
|
||||
android:id="@+id/btn_advanced_options"
|
||||
android:layout_width="match_parent"
|
||||
android:background="@color/status_bar_blue"
|
||||
android:text="@string/advanced_options"
|
||||
android:textColor="@color/white"
|
||||
android:layout_marginTop="-48dp"
|
||||
android:layout_height="48dp"/>
|
||||
</LinearLayout>
|
||||
Loading…
Add table
Add a link
Reference in a new issue