Skip to content
This repository has been archived by the owner on Dec 13, 2020. It is now read-only.

frontend: Letters feature #1196

Closed
teosarca opened this issue Sep 13, 2017 · 12 comments
Closed

frontend: Letters feature #1196

teosarca opened this issue Sep 13, 2017 · 12 comments

Comments

@teosarca
Copy link
Member

Type of issue

Feature request

Expected behavior

  1. open a document, e.g. a sales order - https://w101.metasfresh.com:8443/window/143/1000257

  2. click on Menu -> Letter (note: the Letter menu item shall be displayed if provided, see Render only provided document standard actions #1195 )
    image

  3. A letter modal is opening which is very similar with the Menu->Email modal, but much more simple:
    image
    i.e.

  • there is no "To" and "Topic" fields
  • there are no attachments
  • we still have the the templates dropdown (top right corner) which shall work like in the Email modal but instead of "/mail/" APIs, the "/letter/" APIs shall be used
  • on the left side of templates dropdown we have a print preview icon (button) which when pressed it shall call /letter/{letterId}/printPreview
  • on bottom we have the "Create" button. When pressed the /letter/{letterId}/complete API shall be called and if successful, the modal shall be closed
    image

Notes and observations

@teosarca
Copy link
Member Author

The backend task is metasfresh/metasfresh-webui-api-legacy#178

@pablosichert
Copy link
Contributor

Should there be a hotkey for this feature? If yes, which one?

@metas-mk
Copy link
Member

metas-mk commented Sep 19, 2017

Should there be a hotkey for this feature? If yes, which one?

@pablosichert No thanks. Not needed atm.

EDIT: Just saw that you added [ctrl]+r already. Ok, let's leave it like it is and see. ;)

@teosarca
Copy link
Member Author

btw, @pablosichert the Letter menu item shall be visible only if is provided in document's standardActions, i.e.

image

@pablosichert
Copy link
Contributor

@metas-mk Ok. I think the hotkeys could use some refactoring as well. For example I think mod + nwould be more intuitive for "New document" instead of mod + m. But that also depends how accustomed users are to the existing hotkeys.

@teosarca I put a comment on the PR regarding that. I think it would be easier to leave it hardcoded in this PR and then refactor it altogether in #1195.

metas-mk added a commit to metasfresh/metasfresh that referenced this issue Sep 19, 2017
Adding new Issue to the ReleaseNotes of next week's Release.
metasfresh/metasfresh-webui-frontend-legacy#1196
Frontend: Letters feature
teosarca added a commit to metasfresh/metasfresh that referenced this issue Sep 19, 2017
@teosarca
Copy link
Member Author

hi @pablosichert , thanks for the PR.

Did a quick test and found following issues.

  1. (cosmetics) until we find an icon for Letter menu item i would suggest to keep the space empty and have the menu item texts aligned:
    image

@teosarca
Copy link
Member Author

  1. The text templates dropdown is missing:
    image

It shall look and work exactly like in Email panel:
image

@pablosichert
Copy link
Contributor

Thanks for checking out the changes. I'll align the text accordingly.

The dropdown should be visible when the endpoint returns a set of templates.

image

Can you confirm that this is the right endpoint, but it doesn't return templates yet or is the URL wrong?

@teosarca
Copy link
Member Author

shit, right :)

I forgot to add that method. I just added now and it will be available on next build/rollout.

Btw, after selecting a template, i got following warning in console. Not sure if it's OK?!
image

@pablosichert
Copy link
Contributor

Np 😄 I'll look into it. Also fixing the margin between print preview button and dropdown at the top.

@teosarca
Copy link
Member Author

done, API available: http://w101.metasfresh.com:8081/swagger-ui.html#!/letter-rest-controller/getTemplatesUsingGET

@metas-rc
Copy link
Member

metas-rc commented Oct 3, 2017

Results of IT

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants