Garbage Collection

Yes I saw your update. In my installation it behaves the same on the overview page or on a newly created layout.

Hi,
first let me say thank you for this great widget!

I encounter the same problem like @Nano .
When I put the widget on the overview page or a layout page it behaves like expected.
grafik

But on a fixed canvas layout page it looks like this.
grafik

I tested it with firefox and microsoft edge browser and with different devices.
It seems to me the list-item footer text is centered instead of being aligned left.
Therefore I insert this (which I found in the forum) to the widget code but without success.

Is there something else I can try?

Yes you are right. I never used it on anything else than a layout page. I cannot tell you how you can align it left, I would need to do some tests myself first. I donā€™t know when I will find the time to do so. If you find a solution in the meantime please post your solution here :pray:

I guess the way I insert the justify-content-left command, is not ok. It donā€™t refer to the footer.
But Iā€™m not a coder. I donā€™t know how to do it right.

Hm I donā€™t know if there is an easy solution for your problem. Actually since Iā€™m only using a standard OH component here this might require an ā€žofficialā€œ fix in the base implementation. There might be a workaround of course but I donā€™t see a straightforward solution. I tested it today and I can confirm that the positioning of the footer is indeed centered on a fixed canvas. I think that the widget should behave the same, no matter where you put it.

I updated the first post with a new version of the widget. It requires some adaptions on your end to switch from 0.2 to 0.3:

Breaking Changes:

  1. Collection items are no longer provided as a single string but via a group that needs to be parent of all collection date items

  2. Labels and color information now need to be setup as custom namespaces on the collection date items.

New features:

The list is now sorted by next pickup date

1 Like

Hi,
Iā€™m trying to download the widget via the marketplace, but that fails.
Installation of add-on marketplace:114871 failed
Iā€™m using OH 4.2 if that matters.
FWIW, Yours is not the only one.

Thank you for the report. Unfortunately I have no idea how to fix this :man_shrugging:

Hi,

Iā€™m getting the same error.
OH 4.2.1

Chris

@DrRSatzteil Thank you for taking this great widget to the next level!

Sorry, but I donā€™t understand how the items need to be setup. An example would be great. Could you please post your item definition?

@koenraad @Christian_Slamanig
As a workaround, you can create a new widget and copy and paste the code of the garbage widget into the new one, you created.

Hi anfaenger,

sure, let me show you my config. First of all you should create a group item like so:

Its members have to be of type DateTime and aggregation should be the earliest date as shown in the screenshot.

Then for every individual pickup date you create a DateTime item like this:

Then you add the corresponding metadata. In my case the namespaces are widgetText and widgetColor but the names are up to you. Just use these namespaces on all items and in the widget configuration and you are good:

Lastly donā€™t forget to add all of your DateTime items to your group that you created in the first step:

The DateTime items are then usually linked to an eventfilter thing of the iCalendar binding and thatā€™s it!

I hope this helps, let me know if you need any additional help to get things set up!

Thanks a lot! I made it. :+1:

The only thing Iā€™m missing:
Seems like the custom icon definition is not possible anymore, like it was possible in that old screenshot from version 0.2?
grafik

Now it looks like this:

Oh yes youā€™re right. I didnā€™t realise that is no longer possible to use different icons. I will add this option in the next version. Itā€™s just another metadata namespace for the icon and the default icon will be the trash can so that it stays backwards compatible.

2 Likes

I added a new property to the widget that allows you to change the icons for all or only selected collection dates. Please let me know if that works for you :blush::+1:

1 Like

Perfectly done! Thatā€™s exactly how I imagined it.
Thank you again. :clap: :+1:

grafik

1 Like

According to org.openhab.core.addon.marketplace.internal.community.CommunityMarketplaceAddonService.convertTopicToAddon(DiscourseTopicResponseDTO topic) openhab searches for links with trailing .jar, .kar, .json and .yaml in url https://community.openhab.org/t/114871.
In org.openhab.core.addon.marketplace.internal.community.CommunityUIWidgetAddonHandler.install(Addon) only the yaml mechanism ist working.

Someone could provide a working link with the widget code.