Menu

#3737 topic_nexus_extras submittable

Slash 2.5/3.0
open
5
2006-08-21
2006-07-27
shane
No

I think the mysql/updates file may be missing the following line:

alter table topic_nexus_extras add column submittable enum('yes','no')
default 'yes';

I couldn't find it, and I stumbled upon 2 older sites which were upgraded
a long time ago from 2.2.6 and are only a month or so behind from CVS-
HEAD and neither had the column on each site's table.

Discussion

  • Rob Malda

    Rob Malda - 2006-08-10
    • assigned_to: nobody --> pudge
     
  • Chris Nandor

    Chris Nandor - 2006-08-10

    Logged In: YES
    user_id=3660

    I don't have it on my site's table either. And it's not in the schema. I am
    confused! I don't think this column is supposed to exist on this table.

     
  • Chris Nandor

    Chris Nandor - 2006-08-18

    Logged In: YES
    user_id=3660

    tf23, did we resolve this?

     
  • shane

    shane - 2006-08-21

    Logged In: YES
    user_id=52587

    No, we didn't resolve it. I think this goes back (possibly an IRC discussion)
    about topic extras that can be either required, or marked as submittable such
    that they'll show on a submit.pl form. But I'm sorta confounded, because I
    don't see it in the schema anywhere in cvs-head. I looked at Slash::Submit

    and it does

    my $skins = $slashdb->getSkins();
    my $topic_values = $slashdb->getDescriptions('non_nexus_topics-
    submittable');
    my $skin_values = $slashdb->getDescriptions('skins-submittable');

    Slash::DB::MySQL has

    'non_nexus_topics-submittable'
    => sub { $_[0]->sqlSelectMany('topics.tid AS tid,textname', 'topics
    LEFT JOIN topic_nexus ON topic_
    nexus.tid=topics.tid', "topic_nexus.tid IS NULL AND submittable='yes'") },

    and submit.pl later has

    my $extracolumns = $slashdb->getNexusExtrasForChosen($chosen_hr)
    || [ ];

    however, when you look at getNexusExtrasForChosen it's calling

    getNexusExtras which is basically

    my $answer = $self->sqlSelectAll(
    'extras_textname, extras_keyword, type, content_type, required,
    ordering, extras_id',
    'topic_nexus_extras',
    "tid = $tid_q $content_type_clause ",
    "ORDER by ordering, extras_id"
    );

    and looking at createNexusExtra/update/delete, I don't see anything for a
    'submittable' column.

    so if I had to guess, this is something that was discussed, I modded our
    server to have the functionality, and it never went farther then that. then i
    stumbled on it later and thought it was a bug. for which, let me apologize.
    however, this *is* a handy thing to have, because it lets you define topic
    extras that someone would see via a submission and yet have topic extras
    that a non-admin user doesn't necessarily see when they submit something.
    i'll see if can't dig up the time to grab a fresh cvs c/o and mod that code so as
    to submit a patch to you all that would add the functionality to stock. (if I diff
    our tree right now you'd curse me), otherwise i'd submit the patch right now.

     
  • Chris Nandor

    Chris Nandor - 2006-08-21
    • assigned_to: pudge --> jamiemccarthy
     
  • shane

    shane - 2006-08-21

    Logged In: YES
    user_id=52587

    I'm uploading a patch that gives this functionality. It was applied against cvs-
    head from today. It also updates the schema, and mysqlupadates file too.

     
  • shane

    shane - 2006-08-21

    patch to give topic nexus extras submittable setting

     

Log in to post a comment.

Monday.com Logo