Ui changes for view page

As i like to change view page like google map management concept given below…

how to wrote html section in tpl file ?

1 Like

Hi @polaiah102 - I love your ideas! (If I understand them correctly.) I remember discussing ideas for creating “one map to rule them all” in farmOS, which would always be show in a side-panel like this, and vary its content based on the context in which it was being displayed. Not sure if that’s what you have in mind… it would be great if you could describe your vision and use-cases in a bit more detail.

how to wrote html section in tpl file ?

That’s a very specific question for a very broad idea. :smile:

I think you’ll need to describe in more detail where this will be, how it will behave, what content will be included in both sides, etc, before we can provide more pointers on how to implement it. It will certainly be more than just a matter of writing HTML in a tpl file (also note: we are on Drupal 9 now which uses *.twig files, not *.tpl.php files).

Thought about something similar when I was thinking how the dashboard could be improved. Besides making it configurable per role and user, I also thought about changing its layout:

  • to remove the top navigation and move needed elements like account menu to the main vertical navigation (this is also an approach that is currently worked on as part of general drupal admin ui improvements https://www.drupal.org/project/navigation)
  • and to make the map always visible on the side
    • other dashboard content would be scrollable, but the map would be fixed to the side
    • by default the map could take half the available width but have an option to expand it to about 2/3 of the screen
    • this approach would also require some more thinking how it should behave on smaller screens/mobile devices
      • maybe on mobile the map could be by default hidden and have a toggle button that would open it to the full screen width on top of other dashboard content

Some quick mockups of how it could look:


Exactly i expected this only please give source code for that Ui or views

Don’t really have working code for this yet. The screenshots were just some quick hacking in the browser devtools I’ve done in the past to see how it could look.
Actual implementation of these changes would require some more consideration for:

  • how it could work on mobile devices / smaller screens?
  • the impact on other pages
    • removing the top bar to allow for full height map would require
      • to move navigation links to the main vertical navigation
        • having unified navigation in one place would be in my opinion nice improvement
      • to move breadcrumbs to some other place
        • maybe moving it right above page title could work? having it fixed to the top of the window while scrolling same as the page title is would also allow using breadcrumbs without scrolling back to the top
1 Like

I have used Google Earth to create farm maps with field boundaries, field areas (wet area, waterways), and crop planning information. This link should allow seeing an example of what I have been doing. It would be awesome if my FarmOS crop information automatically populated the pop up notes in my Google Earth maps, or clicking on a Google Earth map field area or marker brought up a FarmOS activity report of some sort. To enter a log entry into FarmOS, click a map field area then select the activity/action, the current state info for the field could auto populate the log entry for location, crop info (asset entries). Potential log entry time saver. Interactive Google Earth farm map

1 Like