ManageIQ / manageiq-ui-classic

Classic UI of ManageIQ
Apache License 2.0
50 stars 358 forks source link

Dots as a Long Description of Service Catalog Item #5853

Open hstastna opened 5 years ago

hstastna commented 5 years ago

When adding/editing Service Catalog Item, we can produce infinite number of dots instead of the text we have written for Long Description. Also Save button does not respond properly on changes while editing the Long Description.

Steps to reproduce:

  1. Services > Catalogs > Catalog Items
  2. Configuration > Add a new Catalog Item
  3. For Catalog Item Type, choose Generic
  4. Fill in the Name, choose some Dialog, check Display in Catalog checkbox => another tab Details appeared
  5. Go to Details tab and write something for Long Description
  6. Go back to the Basic Info tab and uncheck the Display in Catalog checkbox => Details tab disappears
  7. Check Display in Catalog checkbox again and check what's in Details tab => ... instead of nothing or what I've written here before (in step 5)!

More: Now (after step 7) if we enter some another text there and go back to Basic Info and uncheck the checkbox, after another checking the checkbox, there will be 6 dots ...... instead of three dots or the original text! Also if we save such a Catalog Item, the dots are saved, not the text we have written.

Questions: Obviously this does not work well but the question is how this should behave if we uncheck the checkbox and then decide to check it again. Should the previously written text still be there or should it be reset to default value (nil)? And what is the role of those three dots there? (I think that they shouldn't be there at all)

Update on questions: After discussion with Tereza (UX) we agreed that the previously written text should still be there, while checking and unchecking the Display in Catalog checkbox, and no dots. Or it would be better to get rid of the checkbox and the extra Details tab.

Notes: It works the same way also for editing and existing Catalog Item. If we skip steps 5 - 7, the issue does not appear and it is possible to save some text as a long description (not just dots).

This is how it looks like if we repeat steps 5 - 7 for three times: dots

Checking saved Long Description after adding new Catalog Item: long_desc

hstastna commented 5 years ago

@terezanovotna Maybe you could look at this as it is related to improving UX https://github.com/ManageIQ/manageiq-ui-classic/issues/5647 :)

hstastna commented 5 years ago

@martinpovolny

lpichler commented 5 years ago

k27w6t0MM9

terezanovotna commented 5 years ago

Discussed with @hstastna in person and we agreed on:

Screen Shot 2019-08-13 at 13 26 05

hstastna commented 5 years ago

@terezanovotna This is great, thank you very much. Anyway, after some more investigation, I've found that Long Description is mainly for some HTML code, so I think we should make the field much bigger, and maybe also to add some note that if user fills in some Long Description it will be displayed somewhere in Catalog (or I am not sure where exactly). Or maybe to find any other solution/design regarding Long Description.

@martinpovolny @himdel What do you think? How exactly is this working? How can we improve this? Thanks all in advance! :sparkle:

himdel commented 5 years ago

Yes, long description is a HTML description.

Unless we want to drop that feature, editing long description needs to happen in a codemirror editor as it is now, @terezanovotna ...

(It doesn't have to be on its own tab, but it needs to be a multiline editor.)


As for where this is displayed:

editing: Services > Catalogs > accordion Catalog Items > add/edit a catalog item

edit

detail in ui-classic: Services > Catalogs > accordion Service Catalogs > catalog item detail screen

view

detail in ui-service: Service Catalog > catalog item detail screen

viewsui

himdel commented 5 years ago

getting rid of "display in catalog" checkbox

@terezanovotna @hstastna What does getting rid of "display in catalog" mean?

Are you saying that every catalog item will get displayed in the catalog by default? (I'm not sure we can do that.)

hstastna commented 5 years ago

@himdel The screenshots are from SUI, right?

I meant that we would just get rid of the checkbox and set 'display in catalog' attribute/mark to true if user puts something there for the Long Description. And if user left it blank, it would be set to false. (we can see it for some Catalog Item for example like this: ServiceTemplate.first.display, at least I think so). Because in my opinion, it makes no sense to have the attribute set to true if user does not fill in the Long Description at all.

himdel commented 5 years ago

@hstastna No, only the last screenshot is from SUI. The first two are ui-classic.


And sorry but you can't do that.

Whether a catalog item has a long description or not is pretty much unrelated to whether the item gets displayed in a catalog. You can have a catalog full of catalog items, none of which will have any long description. And, similarly, items not in the catalog can still have long_description, we just won't show it anywhere outside catalogs.

If you really want to get rid of "display in catalog", make is so the user sees just the Catalog dropdown, and not chosing a catalog means not displayed.

himdel commented 5 years ago

Because in my opinion, it makes no sense to have the attribute set to true if user does not fill in the Long Description at all.

I think you're misunderstanding the attribute.

What it means is that the whole catalog item will be displayed in a catalog. (You get to choose which catalog in a dropdown.)

(So if you did what you propose, only catalog items with long description would be visible in the catalog and could be ordered)

(So .. display=false means it's not anywhere in the Service Catalogs accordion.)

hstastna commented 5 years ago

So Display in Catalog checkbox is not about displaying in Catalog (or wherever). I think it is misleading. I feel like I now totally don't understand it :smile:

And I can see different editing screens in our classic UI: edit_catitem This is because you looked at the editing of some Catalog Item of Ansible Playbook type. For all other types, it is different :( Maybe making all other screens the same as it is in your screenshot would be enough (regarding Name, Description and Long Description).

himdel commented 5 years ago

Display in Catalog is about whether the whole thing will be displayed in catalog or not. I think it's not misleading, it should just be on a separate line in the form :).

(So yeah, agreed, the form should be consistent in where it shows that attribute.)

hstastna commented 5 years ago

After some more discussion, we've found that we could allow user to fill in the Long description even without checking Display in Catalog checkbox, but in this case we should add note about that the Long description will not be displayed in Catalog. But it could be seen in the details screen of the created Catalog Item, at least. And I think that user could later change his mind and check the checkbox (or the switch), and then Long description would appear also in Catalog. We could have some another discussion with @terezanovotna about this. Or should we better leave it as it is now? Both approaches make some sense.

Fryguy commented 5 years ago

I think this is my favorite bug today :)

miq-bot commented 4 years ago

This issue has been automatically marked as stale because it has not been updated for at least 6 months.

If you can still reproduce this issue on the current release or on master, please reply with all of the information you have about it in order to keep the issue open.

Thank you for all your contributions!

hstastna commented 4 years ago

The issue is sthill present. @miq-bot remove_label stale