1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Lack of Interest Add conditon argument to Thread Model

Discussion in 'Closed Suggestions' started by Cory Booth, Jan 20, 2011.

  1. Cory Booth

    Cory Booth Well-Known Member

    Can we have a couple more arguments to the Thread.php Model?
    Function prepareThreadConditions
    Current
    PHP:
            if (!empty($conditions['forum_id']))
      {
       
    $sqlConditions[] = 'thread.node_id = ' $db->quote($conditions['forum_id']);
      }
    Requested
    PHP:
            if (!empty($conditions['not_forum_id']))
      {
       
    $sqlConditions[] = 'thread.node_id <> ' $db->quote($conditions['not_forum_id']);
      }
    Current
    PHP:
            if (!empty($conditions['user_id']))
      {
       
    $sqlConditions[] = 'thread.user_id = ' $db->quote($conditions['user_id']);
      }
    Requested
    PHP:
            if (!empty($conditions['not_user_id']))
      {
       
    $sqlConditions[] = 'thread.user_id <> ' $db->quote($conditions['not_user_id']);
      }
     
  2. ragtek

    ragtek Guest

    You could always extend the model using the xf proxy class oder using a own model for your add-ons! (depends on what you want to do^^)
     
  3. Cory Booth

    Cory Booth Well-Known Member

    Extend? LOL Sorry ragtek, but I don't know how to do that yet... :)
    Actually what I was doing was trying to add a filter for Jaxel's RecentThreads module which seems to use this model to read threads.
    anks!
    I'll do some reading and see what I can figure out...
    Th
     

Share This Page