vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   HelpDesk v1.63 (https://vborg.vbsupport.ru/showthread.php?t=77155)

red_baron2000 03-15-2005 12:24 PM

i made a litle mod that will allow given department mods to recieve pms about new tickets that submitted to their dep.

note
this mod will add a few queries .



run this query to add option to the CP:
Code:

INSERT INTO setting (varname, grouptitle, value, defaultvalue, optioncode, displayorder, advanced, volatile) VALUES ('helpdesk_pm_notify', 'helpdesk', '1', '0', '<select name=\\\"setting[$setting[varname]]\\\" tabindex=\\\"1\\\" class=\\\"bginput\\\">
<option value=\\\"0\\\" \" . iif($setting[\'value\']==0,\'selected=\"selected\"\') . \">$vbphrase[none]</option>
<option value=\\\"1\\\" \" . iif($setting[\'value\']==1,\'selected=\"selected\"\') . \">$vbphrase[private_message]</option>
<option value=\\\"2\\\" \" . iif($setting[\'value\']==2,\'selected=\"selected\"\') . \">$vbphrase[email]</option>
</select>'
,'51', '0', '0')

open helpdesk.php
find
Code:

        // lets send an email instead
$vboptions['helpdesk_auto_repsonse'] = 2;
}
}

add below it
Code:

if ($vboptions['helpdesk_pm_notify'] == 1)
{                // send PM to department group
        if ($bbuserinfo['permissions']['pmquota'] != 0)
{
$toemail = $bbuserinfo['email'];
                eval(fetch_email_phrases('helpdesk_auto_pm', iif(isset($newpost_lang["$toemail"]),                $newpost_lang["$toemail"], 0)));
        sendprivatemessage_group($vboptions['helpdesk_department_access'], $message, $subject);
}
}

find
Code:

$DB_site->shutdown_query("UPDATE ".TABLE_PREFIX."user SET pmtotal = pmtotal + 1, pmunread = pmunread + 1, pmpopup = " . $userinfo['pmpopup'] . " WHERE userid = '" . $userinfo['userid'] . "'");
}

add below it
Code:

function sendprivatemessage_group ($group_ids, $message, $subject)
{
global $DB_site;
$groups_ids = split(',', $group_ids);
foreach($groups_ids as $group_id)
        {
        $users_ret= $DB_site->query("SELECT username,userid,pmpopup FROM " . TABLE_PREFIX . "user where usergroupid='$group_id'");
while($users_arr=mysql_fetch_array($users_ret))
        sendprivatemessage ($users_arr, $message, $subject); //send pm to each user in the give group_id
        }
}

find
Code:

function sendprivatemessage_group ($group_ids, $message, $subject)
{
global $DB_site;
$groups_ids = split(',', $group_ids);
foreach($groups_ids as $group_id)
        {
        $users_ret= $DB_site->query("SELECT username,userid,pmpopup FROM " . TABLE_PREFIX . "user where usergroupid='$group_id'");
while($users_arr=mysql_fetch_array($users_ret))
        sendprivatemessage ($users_arr, $message, $subject); //send pm to each user in the give group_id
        }
}

add below it
Code:

        $bbuserinfo[m_subj]=addslashes(htmlspecialchars_uni($_REQUEST['title']));
        $bbuserinfo[messa]=addslashes($message);
        $bbuserinfo[tick_id]=$ticketid;

also create attached phrases .

enjoy

WhSox21 03-15-2005 06:34 PM

Live Demo has been updated.

red_baron2000 - I'll install this and see how she works. If it works good and if there is no way for me to optimize the code (which there might be) I'll release an update tomorrow.

Bloodlust 03-15-2005 09:17 PM

Wow that looks really good. Great work. Could be useful for me in the future.

HC. 03-16-2005 11:55 PM

ok,
coming in late on this hack
could some one tell me which one to install and what to edit
step by step please
thanks
hc

WhSox21 03-16-2005 11:58 PM

Obviously you're goign to want to download the latest version. I'll remove the old one. I left it up there for people before. Like stated in the first post there are no file edits! The installation can be found in the zip file.

mfowler70 03-17-2005 02:14 PM

I need to upgrade, but want to wait until the moderator notification from the last page is incorporated into the mod. Any idea when (if) that will be ready? Also, are there any other additions planned for the next rollout?

Awesome, awesome work.

TopeeGuy 03-17-2005 05:37 PM

Is it possible for the person who submitted the original ticket to receive an email when his or ticket receives a reply from a mod/admin?

Reef 03-22-2005 12:59 PM

Very nice addon WhSox21 but, I have a permissions problem I can't get sorted out... All members can see the Administer Block and view tickets other than their own.. Also Tickets that I have claimed ownership of are never listed in "My Tickets"

example:
My Registered Users Group permissions are set to only;

Can Create Tickets = Yes
Can Resolve Tickets = Yes
All others = No

Registered users can still view every ticket... Any Ideas??

Blackbeard 03-22-2005 04:09 PM

Quote:

Originally Posted by Blackbeard
Is it possible to set it so registered users can reply to anyones helpdesk post but dont have access to the settings section.

In the add depatments area i have put there usergroup in , they can post but not reply to other members post, just we have alot of helpful members and we want to use this as a general helpdesk aswell as a bug reporting center.


Quote:

Originally Posted by WhSox21
It would take a little bit of editing of the actual code to accomplish this. If you really wanted to do that you could modify the helpdesk.php file and remove the part of the queries where it checks for the userid. Depending on how tomorrow goes I'll see if I can help you out and post a file for you to use. I'll try to release this as a release too.

I really need to start a list of feature requests. I'll try to get something organized here shortly. This week is pretty hectic for me so once I do get something I'll let everyone know.
Quote:

Originally Posted by Blackbeard
I know you not had much sleep but have you had any time to look into this m8 - Sorry for pushing my luck, but its such a great idea and hack want to use it to its full potential on my forum.
Quote:

Originally Posted by WhSox21
I'll be able to help after tomorrow...

On another note... We made HotM for March!

I'd really appreciate the votes! That is if you absolutely love this hack!

Vote Here!
Have you had any luck on this topic m8, sorry to keep asking, bet u wish i would go away.

cheers for all the hard work

WhSox21 03-23-2005 04:26 AM

Quote:

Originally Posted by Reef
Very nice addon WhSox21 but, I have a permissions problem I can't get sorted out... All members can see the Administer Block and view tickets other than their own.. Also Tickets that I have claimed ownership of are never listed in "My Tickets"

example:
My Registered Users Group permissions are set to only;

Can Create Tickets = Yes
Can Resolve Tickets = Yes
All others = No

Registered users can still view every ticket... Any Ideas??

Are you using the latest version?

In your AdminCP then to vBulletin Options then HelpDesk...
Usergroups With Department Access - make sure this list (seperated by commas) only gives the usergroups you want to have access to those areas.


All times are GMT. The time now is 12:40 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01484 seconds
  • Memory Usage 1,756KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (7)bbcode_code_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete