Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

osTicket v1.10 (stable) and Maintenance Release v1.9.15 are now available! Go get it now

A better ticket list!

124678

Comments

  • And there we go .... Osticket 1.8.1.2 haha
  • below the $qfrom var, I added this left join along with additions to the table html to get custom form values to show on the ticket page.

    ' LEFT JOIN (SELECT fe.object_id, v.value FROM ost_form_entry_values v
                            JOIN ost_form_field ff
                            ON ff.id = v.field_id

                              JOIN ost_form_entry fe
                                ON fe.id = v.entry_id
                            WHERE ff.name = "CUSTOM FIELD NAME HERE") as pos_value
            ON pos_value.object_id = ticket.ticket_id'.


    Add  .",pos_value.value as `pos_name`"
    for each field you want to use.
  • Hi.

    I wonder if I want to see a column in the list of open and closed tickets, which contains a list of different companies. 
    Would I serve all of the steps here are applying? 
    I do not want an additional column for the status of the ticket, what I want is one that tells me that the Ticket # X belongs to the company that previously selected when the user created the Ticket. 
    Currently, as I have defined my custom list with the name "companies" and also add it to my custom form for the details section, and variable name as "factory" 

    Someone could help me? 

    Thank you.
  • Hey there orochi12, 


    It's going to be very similar but you are going to want to modify the sql to pull the company from the database (using inner joins and such).  Then, instead of displaying the status variable you will just display your company variable.

    Let me know if you need help with this!

    Andy
  • Thanks rowlandan25,

    I really appreciate your help. 
    I'll try to review it as soon as possible and I'll tell you how it works.


  • @rowland25

    This will be great once I get to the bottom of some issues. I have been getting a couple of unexpected end of file errors on a few files. One I fixed but the other (I'm not fluent with php) is confusing me.

    Parse error: syntax error, unexpected end of file in \include\staff\statuscolor.mod.php on line 520

    I get the error after having to go add some closing </tr>'s that are missing.
  • Hey there tolje,

    Thanks for pointing out the missing </tr>'s.  I am going to go through my code and find them and get that fixed.  My assumption for the issue is that a } got moved out of place.  If you give me a couple mins, I will update the statuscolor.mod.php file and re-upload it to my site and you can either compare the two files or just copy the new one down.
  • edited April 2014
    Hello Rowlandan25,

    When I apply the mods and follow the instruction there: http://www.msrltech.com/support/dev/index.php/Ticket_Status_Mod_v1.2

    I obtain the following errors, see the attached txt file.

    Any ideas?

    my osTicket: V1.8.1.2
    error_tickets_status_mod.txt
    4K
  • I see the update, but still having issues with "unexpected end of file" with that file :(

    I also noticed an issue here:

    function updateColor(id){
        var f = document.getElementById('fg_'+id).value
        var b = document.getElementById('bg_'+id).value
        var d = document.getElementById('bd_'+id).value

    My editor flipped when I debugge the source and it claimed they should be closed with ";"

    I tried that but no luck still same error, so I'm still looking.
  • @alex_del: You need to run the two scripts in the admin panel (Admin Panel->Modules both Status Mod and Status Color).  Once you do that, you will be good to go.  You may be missing the module.php file that should be in the /scp folder, which you find here: http://www.msrltech.com/support/dev/index.php/File:Module.zip.

    @tolje: can you post the file so I can take a look at it real quick?
  • @rowlandan25

    in you addon is it posible to add Due date  between date and subjekt. 
    We dont use date for anything :-) Du date is more important :-)




    Due date.jpg
    2568 x 1026 - 395K
  • @ismannen Yes, it is very doable (and I even have instructions done already).  Take a look here: http://www.msrltech.com/support/dev/index.php/Modify_Ticket_Queue_View#Due_Date
  • @rowland25

    hmm i am ambaressed that i didnt see that.... i gonna check it out later today :-)
  • edited April 2014

    When I take the source from your mod pack zip I have a ton of issues with unexpected end of file. I'm hoping to get it working as having colors would be awesome!
    statuscolor.mod.txt
    23K
  • Found my issue. My server doesn't support short tags and I found exactly one short tag in the file.

        <tr>
          <td><?php echo $pname;?></td>
          <td><?php echo $val_def;?></td>
          <td><?php echo $val_cur;?></td>
          <td><input type='checkbox' id='upt_<?php echo $id;?>_<?php echo $pid;?>' name='upt_<?php echo $id;?>_<?php echo $pid;?>' /></td>
          <td><input type='text' onChange="check('upt_<?php echo $id;?>_<?php echo $pid;?>')" name='<?php echo $id;?>_<?php echo $pid;?>' value='<?php echo $val_cur;?>' /></td>
          <td><input type='checkbox' name='rmv_<?php echo $id;?>_<?php echo $pid;?>' /></td>
        </tr>
    <?
      }
    ?>
  • @tolje: I'm glad that it is working for you!  I apologize for the trouble but thank you for pointing it the problems so I can correct them!
  • edited April 2014
    @rowlandan25: No problem!

    I'm working on trying to get the sort working, I managed to get the layout to give me the proper formating with the sort options and I have it partially working, BUT it sorts by the value in alphabetical order instead of the order by the Identifier.. any idea on that?

    I'll paste up what I used instead of what you placed.

    In the thead I put the following after the ticketid header
    <?php /* THE SECTION INBETWEEN COMMENTS DISPLAYS THE TICKET STATUS HEADER. Feel free to move it to a different column. */ ?>
    <th width='100'>
    <a <?php echo $modstatus_sort; ?> href="tickets.php?sort=stat&order=<?php echo $negorder; ?><?php echo $qstr; ?>"
    title="Sort By Mod Status <?php echo $negorder; ?>">Status</a></th>
    <?php /* THE SECTION INBETWEEN COMMENTS DISPLAYS THE TICKET STATUS HEADER. */ ?>


    And in the tbody I did no major change but to move the column behind the ticketID
    ANY help in getting this to order by the identifier would be AWESOME!

    sortASC.JPG
    942 x 241 - 70K
    SortDESC.JPG
    937 x 242 - 71K
  • @rowlandan25

    • I copied this module.php (15:11, 2 April 2014) file in my SCP folfer
    • I added in /include/class.nav.php:
    image
    and

    image

    • I extracted everything and copied the folders/files in my osTicket directory.
    image

    I well have the module TAB:
    image
    When I select Ticket Status or Status Color I obtain the following error:

    image
    image

    And I also receive two error alerts of SQL error in my administrator mailbox:

    image

    image

    If you have any ideas of what can be wrong please could you help?
  • Hey there @alex_del,

    This issue was just what tolje and I discussed last night and I hadn't had time to update the files online.  The issue comes where each of those files (status.mod.php and statuscolor.mod.php) had a short tag (<? ?>) instead of the full php tag (<?php ?>).  The issue with this is that some servers don't allow short tags (such as your's I am assuming).  I have updated the site with the newest files that have corrected this issue.  The link is here: http://www.msrltech.com/support/dev/index.php/File:Status-v1.2.2.zip

    I would recommend copying over the other files and you should be good to go.  The database errors are because the sql is messed up until you run the quick setup choosing which list the status is in.  Until that is done, you will get the sql error as part of the statement says "where object_id= INNER JOIN".  Note that there is no number next to object_id.  That is fixed once the setup is run.

    Hope this helps!

    Andy
  • Hey @rowlandan25

    I was playing with the sort last night and got it to work perfectly based off the ID of the tags and not the names, but I somehow ended up displaying the ID's instead of the actual status names...At the end I reverted back to alphabetical sorting.

    This isn't a problem if you list your status's with a number in-front of each name... but to some this could be an issue. Any ideas from you or anyone else would be awesome! My guess is a custom sort of that column to only look at the id's but to display the entered values at the same time, but I'm not that familar with php coding to do this on my own yet. :(
  • Hey @tolje,

    I saw your post about the sort.  I just haven't had time to look at it.  To be honest, because I haven't ever looked at the sorting and how it works, I am completely lost to it.  However, I am hoping to have some time this weekend to look over what you did and look into the sorting.

    I'd be happy to let you know what I find!
  • Thank you rowlandan25, it is working now. I am also searching how to sort this column now.
  • Oh I forgot to mention that you have to add the line

    'stat'=>'modstatus' to the $sortOptions array or the sort won't even try to work.

    Let me know if you need any more info or files from me I'm glad to help.
  • Hello Guys,

    One question about the Status Mod.
    When we have to make an upgrade of osTicket, do we have systematically to redo the configuration of the status mod?
  • When a new version of osticket comes out, I will do everything I can to use what is already stored. However I cannot guarantee that as I have no control over how osticket develops future releases.
  • OK I understand. But if a new version comes out, do we have to remove the status mod from our current osTicket system to make the upgrade, or could we make the upgrade with it?
  • You can do the upgrade with it, but you'd have to wait for the new status mod files to get the ticket status back.
  • OK good news thanks :)
  • @rowlandan25: i'm not sure if the list view "Sort" question is solved:

    i added just the following on line 146 and now sorting works. (V1.8.02):

    $sortOptions=array('date'=>'effective_date','ID'=>'ticketID',
        'pri'=>'priority_id','name'=>'user.name','subj'=>'subject',
        'status'=>'ticket.status','assignee'=>'assigned','staff'=>'staff',
        'dept'=>'dept_name','duedate'=>'duedate', 'modstatus' => 'modstatus');

    Thanx for you great mod!
  • and of course: 
           
    <th width="120">
    <a <?php echo $modstatus_sort; ?> href="tickets.php?sort=modstatus&order=<?php echo $negorder; ?><?php echo $qstr; ?>" title="Status <?php echo $negorder; ?>">Ticket Status</a></th>
Sign In or Register to comment.