Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jakob Lithner 61 posts 264 karma points
    Mar 01, 2019 @ 21:13
    Jakob Lithner
    0

    Tags on Media items not working

    I have used TagManager for ContentTypes and it works like a charm.

    Now I have added two tag properties to some of my media items. It works fine to set the tags and they are saved on media items.

    But when I go to TagManager to see my tags it gets a bit strange. The TagGroups are found and even the tag names, but all tag names are empty. There is no connection to the media items where they are used.

    I tried to uninstall TagManager and then install it again, but that made no difference.

    What can I do?

  • Nigel Wilson 944 posts 2076 karma points
    Mar 02, 2019 @ 00:52
    Nigel Wilson
    0

    Hi Jakob

    Thanks for your post - I can look into this to try and work out the issue.

    Are you able to please confirm the version of Umbraco your site is currently using ?

    Thanks

    Nigel

  • Jakob Lithner 61 posts 264 karma points
    Mar 02, 2019 @ 12:41
    Jakob Lithner
    0

    There definitely is a problem somewhere, but I am not sure whether it is related to the TagManager or to the Tags.

    • When I now edit tags in Backend UI the existing tags don't show up so I get no intellisense.
    • When I in my frontend code load existing tags to be used for searching, then only one of them show up!

    I know this has worked before. What can I have done? I no I have experimented a bit in the TagManager with renaming and deleted tags. Can that be a reason? Or is there some magic secret in how to add tag properties on DocumentTypes/MediaTypes? I use specificly named TagGroups everywhere. Currently only one of them works.

    The cmsTags table looks great. I find all tag names to be present and related to correcy group names. But the cmsTagRelationship table looks suspiciously empty! Only 12 out of ~100 tags are present.

    The tags seems to be saved to the Documents/MediaItems but my impression is that I can't trust that tag names are also saved to the cmsTagRelationship table. This would explain all the problems: the missing references in TagManager, the missing intellisense and the missing readout of existing tags.

    But the crucial question still remains: why is it unstable????

  • Jakob Lithner 61 posts 264 karma points
    Mar 02, 2019 @ 07:13
    Jakob Lithner
    0

    I am using Umbraco version 7.10.4

    I appreciate the quick answer!

  • Jakob Lithner 61 posts 264 karma points
    Mar 02, 2019 @ 12:51
    Jakob Lithner
    0

    My impression is that tags are fragile things. I have had a lot of problems before as well.

    • Is there a workaround?
    • Is it possible to restart and kick them alive again?
    • Is there a best practice with some dangerous steps that are to be avoided to keep them alive?
  • Nigel Wilson 944 posts 2076 karma points
    Mar 03, 2019 @ 18:56
    Nigel Wilson
    0

    Hi Jakob

    Firstly, I confirm I have replicated the issue by installing a fresh copy of Umbraco with the default starter kit (this comes with tags preinstalled across 2 tag groups). I have added a tag property to the Image media object, added a tag and then viewed in the Tag Manager section. The media item does not appear. The tag is showing but no link to the media item.

    I have no idea how long this issue has been present as tags are not that commonly used on media (at least that is my impression).

    In terms of all your other queries:

    Sorry but I am not sure what you are referring in in the comment When I now edit tags in Backend UI the existing tags don't show up so I get no intellisense.

    I have checked my SQL database and confirm the cmsTagRelationship table has entries in it for all tags, including the new one I just created.

    Sorry but I don't know of any workarounds, and in terms of your question to restart - I am guessing this would require you to delete the properties on your document / media types, check your dB tables to ensure they are empty, re-add the properties and then re-add the tags. Quite a nasty job unless your site is very small.

    I have also created a new Tag Data Type with a new group, added this to the Image media object, and added tags. Everything works as expected, except for the media item not being listed in the Tag manager section.

    I will work on fixing the Tag Manager issue in the coming days and get an update released.

    In terms of your issue re the cmsTagRelationship table - I do not believe it is due to the Tag Manager code. There was also this recent issue (https://our.umbraco.com/packages/backoffice-extensions/tag-manager/tag-manager/95009-bug-on-merge-tags-corrupted-property-data) which points to an issue in core, so potentially your cmsTagRelationship data issue is also related to a tag issue in core.

    Cheers

    Nigel

  • Jakob Lithner 61 posts 264 karma points
    Mar 03, 2019 @ 20:42
    Jakob Lithner
    0

    Hi Nigel,

    Thanks for your concern and efforts!!

    I appreciate the idea of modifying TagManager to work with Media Items!

    I created a method that manually loops through all my media items, reads all tags, creates tag records where needed and creates tagrelation records where missing. I did this with direct calls to database as I don't trust core :) This works at the moment as a workaround to make my tags visible. But it does not address the real issue as new tags will not be saved correctly :(

    "When I now edit tags in Backend UI the existing tags don't show up so I get no intellisense". This was referring to editing the tag property of Documents in Umbraco Backend. Usually I get a list of alternatives with defined tags, but this was now lacking thus increasing the risk of creating similar tags. I don't think this is related to TagManager but another sign of a fragile Umbraco tag handling.

  • Nigel Wilson 944 posts 2076 karma points
    Mar 03, 2019 @ 22:47
    Nigel Wilson
    0

    Hi Jakob

    By intellisense, I am assuming you are meaning auto-suggest as per the image below.

    enter image description here

    This appears to be working as expected for me (and as per the helper text you need to press enter to "save" the tag).

    If you are not seeing the auto-suggest, I wonder - have you upgraded your Umbraco site and/or would it be worth copy/pasting the umbraco & umbraco_client directories to see if that resolves that issue.

    Media items being linked in Tag Manager is still an outstanding issue :-)

    Cheers Nigel

  • Jakob Lithner 61 posts 264 karma points
    Mar 03, 2019 @ 22:50
    Jakob Lithner
    0

    Yes, "autosuggest" is what I mean!

    I have not updated my site. It is not even deployed, but will hopefully be in a week.

  • Nigel Wilson 944 posts 2076 karma points
    Mar 03, 2019 @ 23:28
    Nigel Wilson
    0

    Hi Jakob

    Maybe it is worth downloading the same build as your site and copying the umbraco & umbraco_client directories into your site, just to ensure you've not had any install issues, etc.

    Also have you tried different browsers to see if the auto-suggest is consistently not working ? If not, then this points to something weird in your install.

    Cheers Nigel

  • Jakob Lithner 61 posts 264 karma points
    Mar 07, 2019 @ 22:34
    Jakob Lithner
    0

    I have tried in different browsers and I agree there must be something bad with my installation. I suspect data inconsistency in some way.

    Currently I dare not to upgrade since I read your links that indicated similar issues in later versions of Umbraco ....

    Maybe I should a full empty install and copy folders but I push that a bot forward as I am quite busy now.

  • Nigel Wilson 944 posts 2076 karma points
    Mar 05, 2019 @ 06:11
    Nigel Wilson
    100

    Hi Jakob

    Just confirming I have released an update to the package to fix the bug for listing media items.

    Be great if you are able to install and check it is working OK for you.

    Cheers

    Nigel

  • Jakob Lithner 61 posts 264 karma points
    Mar 07, 2019 @ 22:36
    Jakob Lithner
    0

    Sorry, I did not answer until now.

    Tonight I have tried and can confirm that your updated version 5.1 works excellent with Tagged Media.

    Thanks for the quick fix. I really appreciate it!!

  • Nigel Wilson 944 posts 2076 karma points
    Mar 07, 2019 @ 22:57
    Nigel Wilson
    1

    All good Jakob and I likewise appreciate you finding the bug, thankfully one that was very easy to resolve. :-)

    Are you able to please mark this thread as resolved - just nice to close it off

Please Sign in or register to post replies

Write your reply to:

Draft