HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

Do the additional fields show on all discussion categories?

rbrahmsonrbrahmson "You may say I'm a dreamer / But I'm not the only one"NY ✭✭✭
edited July 2015 in Feedback

This plugin looks very interesting. I read the Readme file and it's unclear to me whether the mention of "Required on all discussions" may be set to be required (or optional) but limited it to specific categories.

What I'd like to do is to use this extension to add fields to a specific category without affecting the other categories. For example, if one category is about a product, to that category I'd like to add a field "Product Version".

Comments

  • Options
    hgtonighthgtonight ∞ · New Moderator

    Thanks for trying my addon!

    This plugin makes no distinction for categories.

    Search first

    Check out the Documentation! We are always looking for new content and pull requests.

    Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.

  • Options
    rbrahmsonrbrahmson "You may say I'm a dreamer / But I'm not the only one" NY ✭✭✭

    If the plugin changes the database structure which affects all categories, can you offer insights into making the additional fields visible for selected categories only? I am hoping for a simple effort,not sea parting;-)

  • Options
    peregrineperegrine MVP
    edited July 2015

    @rbrahmson

    I am hoping for a simple effort,not sea parting;-)

    the more you study the simpler the effort. Easier to cut down trees with a sharp axe. Sharpen your axe by learning how the simpler plugins work by learning events, sender objects and what info they contain, and simple php logic. r_j has written alot of tutorials and info on sender and objects and how-to's as well as numerous other people.

    simple effort -
    there are numerous other plugins that affect categories (generally they have the word "category" within the name of the plugin). look at how they determine what category they are in. then apply that to your customization. then based on category display field or don't by testing and not displaying it.

    sea parting -
    add field for category in settings. and test. Although I'm not a big fan of changing the discussion table period.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    rbrahmsonrbrahmson "You may say I'm a dreamer / But I'm not the only one" NY ✭✭✭

    Thanks, yes, I get it. Perhaps some perspective is due -- I convinced management to allow me to evaluate Vanilla. I don't have the budget and I have limited time - I am spending after hours/weekends to try to set up an internal demo that would get management excited. So my question was mostly to ensure that I am not going the wrong track by trying to go the "hide extra fields on other categories" route.
    What you describe is obviously the right way to learn and do things. But then there is the management clock. I acknowledging that you are correct and hoping that I am not wrong in pushing Vanilla against the constraints I am facing... I hope I have not become a burden on the great forum volunteers.

  • Options

    if you do get management excited about Vanilla, maybe the vanilla cloud would be the way to go, since you might not have enough time to do all the things you want yourself, due to time constraints.

    In any event the more you learn, the easier it will become good luck. sounds like you are in between a rock and a hard place i.e. - Convincing your employer to use something and Convincing Volunteers to provide tips and/or code to tweak the forum the way you need it. Maybe you just need to draw a line in the sand with what features you need for the demo and stop the mission creep. Or just draw up a complete feature list and then farm that out to someone or vanilla staff, and ask if it can be done.

    Perhaps just show the management team a series of mocked up powerpoint images. after you have asked whether the features you want are doable in vanilla.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    R_JR_J Ex-Fanboy Munich Admin

    You have to look at two aspects: UI and database. Your users should only see the additional field, if they are allowed to use it. Changing UI during run time means you need JavaScript: https://github.com/R-J/EventCalendar/blob/master/js/eventcalendar.js#L21-L33

    You also have to ensure that nobody messes around with your database and so you have to ensure the field is not saved/empty: https://github.com/R-J/EventCalendar/blob/master/class.eventcalendar.plugin.php#L210-L217

    Basically, that's all.

    You might want to have an admin screen where you can set which categories allow that field: https://github.com/R-J/EventCalendar/blob/master/class.eventcalendar.plugin.php#L95-L140

    By the way: adding a custom field to discussions is such easy, that you shouldn't use the discussion extender when you change the functionality so much.

  • Options
    rbrahmsonrbrahmson "You may say I'm a dreamer / But I'm not the only one" NY ✭✭✭

    I am encouraged by @R_J 's approach and will give it a try. Thanks everyone for supporting my inquiries, my travels through the Vanilla universe, and helping me learning a lot under less than ideal conditions (none are the fault of this great community).

Sign In or Register to comment.