Skip to content

[NMA-1085] (Explore Dash) Show all locations for merchant grouping - #830

Merged
HashEngineering merged 32 commits into
feature-explore-dashfrom
feature-explore-grouping-details
Dec 9, 2021
Merged

HashEngineering merged 32 commits into
feature-explore-dashfrom
feature-explore-grouping-details

Conversation

@Syn-McJ

@Syn-McJ Syn-McJ commented Dec 8, 2021

Copy link
Copy Markdown
Member

When opening the closest location from the grouped list of merchants, we want to have an option to show all locations of this merchant.

Issue being fixed or feature implemented

  • Added additional screen for showing addresses of all merchant locations in radius.
  • Implemented two states for the details card.
  • Implemented focusing map on results/details/all locations.
  • Refactoring to support a more complicated transition tree.

Related PR's and Dependencies

Screenshots / Videos

How Has This Been Tested?

  • QA (Mobile Team)

Checklist:

  • I have performed a self-review of my own code and added comments where necessary
  • I have added or updated relevant unit/integration/functional/e2e tests

@Syn-McJ Syn-McJ self-assigned this Dec 8, 2021
@Query("DELETE FROM atm WHERE source LIKE :source")
override suspend fun deleteAll(source: String): Int

fun observePhysical(

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Accessor methods moved to a separate class to simplify testing

import org.dash.wallet.features.exploredash.data.model.*
import org.dash.wallet.features.exploredash.databinding.ItemDetailsViewBinding

class ItemDetails(context: Context, attrs: AttributeSet): LinearLayout(context, attrs) {

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code related to merchant/atm details is moved to a separate class to offload SearchFragment

binding.searchResults.removeItemDecorationAt(0)
}

binding.searchResults.adapter = ConcatAdapter(header, merchantLocationsAdapter)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because of BottomSheet behaviour issues, we have to use one RecyclerView for both search results and merchant locations.

app:layout_constraintTop_toBottomOf="@id/find_merchant_icon"
app:layout_constraintStart_toStartOf="@id/left_guideline"
app:srcCompat="@drawable/ic_explore_info_screen_gift_card_blue"
android:src="@drawable/ic_gift_card"

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed some duplicated resources

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since we are not supporting Android 4.4 anymore, then app:srcCompat is not necessary?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct, hence I'm not using it in the refactored code.

<dimen name="atm_details_height_ratio">0.55</dimen>
<dimen name="atm_manufacturer_vertical_margin">12dp</dimen>
<dimen name="atm_content_vertical_margin">72dp</dimen>
</resources> No newline at end of file

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added separate dimensions for smaller screens

@ClaudeHangui ClaudeHangui left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alright for me !

@HashEngineering
HashEngineering merged commit 70b22d0 into feature-explore-dash Dec 9, 2021
@Syn-McJ
Syn-McJ deleted the feature-explore-grouping-details branch December 10, 2021 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants