mail
mail copied to clipboard
Select and map a table to write mail properties to
Is your feature request related to a problem? Please describe.
I want to process my incoming messages in the Tables app, so I need to be able to choose the table and the data that should be mapped.
Describe the solution you'd like
The settings should be on a mailbox level.
Design input needed, but I would suggest adding it to the three- dot- menu for a mailbox (with the appropriate icon):
I used https://pictogrammers.com/library/mdi/icon/swap-horizontal/ but https://pictogrammers.com/library/mdi/icon/database-arrow-right-outline/ might work well too.
If we use the Account settings, it could look like this:
Which could open an additional modal:
If a table exists it should show an NcSelect for them.
cc @nimishavijay
In the next step:
- [ ] I can choose a table from the tables app that I want my messages to be written to.
- [ ] I want to be able to choose which data should get mapped, and to choose which table column the information should be written to
- [ ] Data that is available for writing
- Mailbox
- From
- To
- CC
- BCC
- Date received / sent
- Subject
- Body
- Attachment(s)
- Referenced email (replied)
- Thread root
- Flags
This would be nice to have in a modal that focuses on the mapping only, but again, design input needed.
When I'm done, all incoming messages in my INBOX should be written to the Tables app automatically.
Whenever there is a write to oc_mail_messages for my defined mailbox, there should be an additional write to the table of my choosing with the data that I defined.
Option 1
The messages are written to the tables app via background job.
This will need a new table in mail app:
mailbox ID
table ID
mappings
highest mapped UID
Option 2
The mappings could be saved in oc_preferences.
TBC
- [ ] Separate Table or oc_preferences
Describe alternatives you've considered
No response
Additional context
No response
Cool idea!
Some questions:
- [ ] How would adding to an existing table work? for example, if I want to link my inbox to the existing vacation request table
- [ ] How would you select the column to link message data? eg, I want to link the attachments to the "Vacation request form" column, would that be possible?
- [ ] Could you modify existing tables while setting this up? eg. can I add a "sender" column to the vacation request table while I'm setting up the mapping?
- [ ] Once a table is set up is it possible to modify it from the tables app?
- [ ] what happens if I delete the a column from the tables app?
- [ ] For creating a new table, how much control does the user have over the table details?
- [ ] can the user set the table and column names?
- [ ] what about constraints for the column (default values, etc)?
- [ ] possible to create columns that are not linked to message data?
Regarding the design itself:
- [ ] Since this is a rather niche feature, the entry point can be in the settings
- [ ] I would use the word "Connect" or "Link" instead of "Map", as it's easier to understand. MS has "Connect to Outlook" in Sharepoint, so I would go with that
- [ ] For icons, to maintain consistency with the Tables app icon, what do you think about tables-large-plus?
rough high level mockups with only very basic functionality, what do you think? is this even remotely close to the scope or did I completely misunderstand what's happening here:
When you click on "Connect to Tables":
Creating a new table:
Connecting an existing table:
What do you think? :) If this is in the right direction I can do more detailed mockups with more functionality, etc
Very nice! Agree with both your proposals @miaulalala @nimishavijay.
Only the icon I would change to table-arrow-right so itβs the small table icon and it denotes the one-way-ness of the connection: https://pictogrammers.com/library/mdi/icon/table-arrow-right/
That is so cool !! I think this could replace or enhance #44 There is one thing in the original proposal. I personally would map it to a folder instead of the full mailbox.
It's more likely a user place a mail into a folder and the mail triggers a new row into the Tables app. This would be very useful in ticketing systems. Like different folders would create different rows for different people. => Place it in marketing => Row for the marketing people => Place it to design => Row for the design people
Superseded by https://github.com/nextcloud/mail/issues/9691