Okay
  Public Ticket #3357544
autocomplete suggestions for consistency?
Closed

Comments

  • Alex started the conversation

    Hello, apparently an awesome product, seems it could very well be the choice for my database project, most likely there's no feature I'll need it doesn't have..! At least one question comes to mind though.

    You have the possibility for predefined values for editor. Very good, my question is also about ensuring consistency. My project is targeted for a hobby community, and I can see how volunteers inputting data could accidentally spell the same thing in a half a dozen wrong ways. Not good for consistency. But I don't think I either want a situation where only the administrators/moderators (even only thru the back end which would be even worse) can add those completely new values. To be fair, in my case at least the multi-value selectboxes would be with admin-predefined values though.

    So this is what I would need, I think it's quite simple really... I'd like to know is this possible in the current or maybe a future version of wpDataTables, and if yes already, could you provide some instructions how to accomplish this:

    When inputting a new value in a string type field (One-line edit), it should show autocomplete suggestions as you type, kind of like the search functionality in selectboxes, populating from values already in the database for the field in question. But you could also choose to ignore the suggestions and keep typing to add a completely new value. Which would then, after successfully saving the record, be shown also to other users in their autocomplete suggestions.

    I consider this essential functionality for my project, there would be a big positive impact on data consistency, especially on data fields like product name and type code and so on, because there usually are numerous ways to spell them but only just about one correct way. With this functionality people would instantly see if they're typing it differently than others.
    And no, the data could not be predefined by admins, there are numerous different products and types with their own correct spellings and we're starting with an empty database more or less, volunteers just add data as time goes along. Of course moderators would have to monitor things and even some bulk search-replace would have to be carried out occasionally in case of serious misspellings.

    Another approach, might do as a workaround, would be a single value select box (still populating from the live data though) with an "Add new" button for adding some new value not already selectable. Preferably using the selected value as a template to modify, then add. I'm not sure is wpDataTables capable yet of doing this either.

    And now after thinking of it a bit more, I think also some functionality similar to Cascade Filtering would be needed, to get for example type code suggestions for a specific brand only. The workflow in editing a new row would be to fill in the product brand field first, then with help of autocomplete, fill in the type code field. (And all this in the front-end, for registered users with appropriate privileges.)

    I briefly browsed through the related docs, but did not notice anything like this.

    Please advise, am I dreaming the impossible or can wpDataTables deliver :)

    Thanks in advance..!

  • Alex replied

    Hello again,

    I researched some more and found a 3rd party plugin "Gravity Forms Advanced Autocomplete Field".
    If (and that's IF) this would work with your Gravity Forms add-on, that might be the solution. I wonder if anyone has yet tested this.

    There seems to be some significant restrictions in your add-on for now though, especially the attachment problem when editing.
    For images, this probably could be handled somehow, by hotlinking the image from a separate image repository instead of adding it as an attachment.
    Also seems to leave out the foreign key relations, but I completely understand it's for technical reasons.

    I still really hope you could look into this in the near future, I mean just adding a setting to enable/disable autocomplete (populating straight from the database) for certain columns.
    Your product excels with the actual displaying of the table, but editing of the data could also be just about perfect with some small improvents :)

    Kind regards,
    Alex

  • Alex replied

    Now when thinking of it, I'm leaning towards going first with a single-value selectbox of predefined brands (I'll then ask people to inform me about brands missing), and try to instruct on spelling product numbers consistently.

    Let's see how that goes, when we get from planning stage to actual use. This adds a bit extra threshold though for the volunteers and trouble for me as admin, in beta phase there would be no other moderators.

    The very much preferred way would still be for the volunteers to be able to independently add any values missing from the selectboxes (or from one-line edit field autosuggestions), would it be straight within the input field itself or a separate modal or page, that doesn't matter that much.

    I've seen a neat implementation on one site, where a selectbox turns into a text input field when clicking "Add new brand" button next to it. Might be impossible to accomplish in wpDataTables though, so doesn't need to be anything that fancy.

    After reading your documentation quite a bit (yeah should have done it first), I now see I could make the brand selectbox pull the values from another table, using foreign keys. Excellent that you have this technique implemented, by the way..!
    And then probably provide a button or link (preferably right next to the selectbox but is this possible?) for people to add values to that another table when necessary. Maybe even giving that access only for the moderators later.

    This would be a very good solution already, but still I'd also like to see the possibility for enabling automatic suggestions for some of the one-line edit fields.

    If you have a place for feature requests (that you consider doable), where other users can also express their interest to them, I might want to add something like this there.

    Thanks

  •  1,708
    Miloš replied

    Hi, Alex.

    Firstly, I would like to sincerely apologize for the delayed response as we have been experiencing an unusually high number of tickets. I am sorry that it has taken longer than usual to respond to your concern and your patience is highly appreciated.

    -

    We will now cover multiple questions on same ticket, but for more effective support, in the future, please create separate tickets for each subject.

    -

    1. In regards to having auto-complete values for editing, i suggest, as you already found in our documentation, the best way with our plugin's current capabilities is with foreign-key relations.

    Just an important note, i notice you mentioned Gravity Forms.

    With Gravity Add-on tables, it is not possible to use foreign key relations as source data for columns.

    1727642925.png

    You can test all the Gravity Forms add-on features and options on this Sandbox Site - and check all the unavailable options in column and table settings.

    You can also check, if you already haven't , our Gravity Add-on Documentation here.



    2.  Provide a button or link (preferably right next to the selectbox but is this possible?) for people to add values to that another table when necessary. Maybe even giving that access only for the moderators later.

    -

    My apology, but i did not fully understand this use-case of adding the button or a link right next to the selectbox of foreign key values?

    Can you please elaborate on that - do you have any working example with screenshots or a Video?


    3. independently add any values missing from the selectboxes (or from one-line edit field autosuggestions), would it be straight within the input field itself or a separate modal or page

    - That will not be possible, if you set up a foreign key column, it is limited to a one value selectbox,

    to only see all the possible values pulled from the remote column of the foreign table;

    we are not able to add any new values for this use-case.

    4. Adding a future feature suggestion :

    Yes, we have a page where we closely follow what our users add as development suggestions, you can first check if anyone else already added it - in that case upvote it;

    or if it does not exist yet, you can add your own suggestion.

    -

    Please feel free to search on our suggestions page

     to see if someone may be already suggested this feature. If you can't see it, feel free to add your suggestion there,  and as more people vote, the feature will move higher on the priority list.

    You can certainly follow our changeLog page if you'd like ( it is also available in the plugin dashboard), where we state any changes/new features/bug fixes during updates;

    and our newsletter, so you're informed about new features, bug fixes, freebies, etc.

    -

    My sincere apology if i missed to cover any point, did my best to go through everything;

    please let me know if i missed anything.

    Thank you.

    And i just wanted to point out that you can try wpDataTables before purchasing

     on our sandbox Demo sites ( you can find links for the main plugin Demo,  

    as well as add-on Demos, in my signature),

    and there is a 15-day money-back guarantee period, 

    so if you purchase the plugin, you can safely fully test it out, and if it doesn't fit your needs you can request and receive a refund in that period. ( same goes for all plugins and add-ons)

    Let me know if you have any additional questions. 

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables

  • Alex replied

    Thank you for the reply, Miloš.


    I'm sorry for too long messages, that's a known problem of mine :)

    Yes, several things in one ticket should be avoided, in my opinion this was just about pondering different ways to tackle one problem however.
    Ok, it's essentially about having autocomplete AND a way to allow easily adding new values. And achieving both these things in the same column (which at first I thought would be good just being one-line edit type). This is now turning more like into having a feature to add new values when using selectbox. My bad, I try to remember next time :)

    We might be using different terms of the same things, or same terms of different things, so please forgive me for writing a few possibly obvious things next :)
    By autocomplete I mean, well, autocomplete, automatic suggestions as you type. These coming from all the existing values from the column.
    Automatically populating selectbox values from the database, instead of predefining them in the form, yes that's slightly another thing, and a must have (the "read from table on page load" setting).

    Luckily I found a perfect live example of what kind of functionality I'd like to have for users, please see the first dropdown, "Creatable Example":
    https://react-select.com/creatable

    So, you can select a value (just one and that's enough) from the list,
    type something to have autocomplete help you select,
    OR type something not yet existing and then create it. Even without any buttons in this implementation.

    This way users can add new values to certain columns if needed, during inputting new rows in the database.
    Next time someone wants to add that same value, it's now created and already there among the selectbox values.

    In an ideal world there should indeed be foreign keys involved here, provided there are no technical limitations preventing it. But if that's the case, then I would have to accept the possible performance hit and just leave out the foreign keys at least for the column in question, we're not talking about a massive database with any huge traffic anyway.
    Also I actually wouldn't want to bring Gravity Forms unnecessarily to the mix to complicate things, for just having one feature like autocomplete (which would even be a 3rd party add-on with no guarantee on working in this setup).

    Your suggestions page is great, I found it already in the meantime and checked out the suggestions, even reading through most of them and also upvoting and commenting some. Based on where this ticket leads us, I'm already prepared to add some new suggestions there.

    Thank you again,
    kind regards,
    Alex

  •  1,708
    Miloš replied

    Hi, Alex.

    You're welcome, i am happy to advise.smile.png

    No problem, i can completely relate about the messages being too long, i also have that problem very often.

    Working on making them more effective with less text but still to pass all the important points/details.

    -

    Thank you for providing the clear descriptions of what your goal is, i can understand what you mean.

    Unfortunately, with our current built-in functionalities, we do not have an ideal solution for your use-case,

    in terms of having a real "auto complete" , like when a user starts typing in a "one line Edit" or "multi-line Edit" during Editing.

    It is a really good idea for a future option, though, so you can make a development suggestion if any other user hasn't done that already.

    -

    Our auto-complete would only be offered, if this user has already visited the page before, and if they already used a certain word for editing before,

    then when they start typing again for some other row/ or same row - these words that the same user already used would become offered beneath the input.

    But i see what you mean - you would prefer having the actual database pull all the values and offer them,

    at this moment this is only possible with the foreign key option - but that one is limited to only single value selectbox, and to add new values,  we would have to go to the foreign Table and add values there;

    then they would appear as possible selectbox values in this "main table".

    Exactly, you have found the perfect example for the use-case, i see what you mean,

    like if a user starts typing one of the existing values, they show up

    9903278273.png

    or if they start typing something that still does not exist, it offers them to add this value :

    9899412962.png

    It is a great example and i like that idea very much, but at the moment it's not possible with our plugin,

    our developers would need to work on adding it in the future.

    If you can be so kind, please check if nobody already added this suggestion,

    and you can add it for voting - i will certainly upvote it and we will see how difficult it might be for the devs to add it , i hope as soon as possible.

    Thank you for this idea for improvement.

    Let us know if you have any further questions about this use-case,  and of course, if you have any unrelated question or suggestion/feedback,

    please don't hesitate to open new tickets.smile.png

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables

  • Alex replied

    Miloš,

    thank you very much for the comprehensive reply.

    Yes, in my nonprofit use case where volunteers would potentially add even large amounts of data, it would be crucial to have the experience very smooth and convenient for them for the project to succeed, at the same time trying to keep the consistency of the added data at a good level with minimal moderating effort.
    That's why advanced input features like this would be essential... suggestion added: https://features.wpdatatables.com/252 .

    I really hope this kind of functionality could be implemented in wpDataTables in the near future, along with a couple of other things you already seem to be working on, you soon could be light years ahead of the competition :D

    Ok, since there is no way to achieve the desired functionality yet, I'm thinking which way I should choose for the time being.
    Single value selectbox would be enough, so most likely I should go with the foreign key option, which usually is the right decision for this kind of data anyway.

    To add new values, if I decide the users should have that ability already in the beginning of the project, is there any workaround for the users to get to edit the foreign table as easily as possible, could a link/shortcode be placed somewhere very near the actual selectbox..? (I would of course prefer just a text input field with a button to "Add new", and the data would just go straight to the foreign table without users even noticing there's another table involved, but I understand this is also impossible at the moment.) But well, maybe I should go find about this myself :)

    Kind regards,
    Alex

  •  1,708
    Miloš replied

    Hi ,Alex.

    First of all, thank you for adding another great suggestion.

    A colleague from our QA Team just mentioned today that someone added very nice improvement ideas on our Suggestions Page, it took me a few minutes to realise they were your suggestions.smile.png

    It has my vote - just upvoted all your suggestions from my end.

    Yes, if our devs manage to add something like this soon, it might really set our plugin's features to the next level, but we will see how difficult it is and how much time it might take to implement it.

    -

    In regards to trying what might be the easiest/best way for end users to achieve the use-case as you described,

    you are correct - at this time, we don't have something like an "add new" or a "minimized" layout that might only show the editing of that specific column from the foreign table somewhere close to this "main table's selectbox" on screen/interface; ( even though i like this idea very much as well, that would be awesome if our devs add it soon);

    At the moment, If a user needs to edit the source table where the actual foreign key source values are coming from,

    you would have to either add that other table on the same page and 'somehow' indicate to the users "which table is which" to avoid confusion;

    or you could make a hyperlink close to this table that redirects/or opens a new tab to that other table's page, something like that,

     but we don't have a workaround that might make that easier/more seamless for the users.

    Thank you again for these great suggestions, this use-case is really something to think about and that might inspire our developers for the said improvements.

    Of course, please don't hesitate to open other/new tickets for anything else that we might advise about.smile.png


    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables