@@ -629,48 +629,48 @@ function web_TicketDialogue($ticketid) {
629629 //pushing some context
630630 if ($ moreContextFlag ) {
631631 if (!empty ($ userData )) {
632- $ currency = $ ubillingConfig ->getAlterParam ('TEMPLATE_CURRENCY ' , 'UAH ' );
633- $ userState = zb_UserIsAlive ($ userData );
634- $ stateLabel = __ ('Unknown ' );
635- switch ($ userState ) {
636- case 0 :
637- $ stateLabel = __ ('Inactive ' );
638- break ;
639- case 1 :
640- $ stateLabel = __ ('Active ' );
641- break ;
642- case -1 :
643- $ stateLabel = __ ('User passive ' );
644- break ;
645- }
646- $ userContext = '' ;
647- $ userContext .= __ ('Also take into account these data ' ) . ' ' . PHP_EOL ;
648- $ userContext .= __ ('Here is some information about user ' ) . ': ' . PHP_EOL ;
649- $ userContext .= __ ('Real Name ' ) . ': ' . $ userData ['realname ' ] . PHP_EOL ;
650- $ userContext .= __ ('Address ' ) . ': ' . $ userData ['fulladress ' ] . PHP_EOL ;
651- $ userContext .= __ ('Account balance ' ) . ': ' . $ userData ['Cash ' ] . ' ' . $ currency . PHP_EOL ;
652- if ($ userData ['Credit ' ]) {
653- $ userContext .= __ ('Credit limit ' ) . ': ' . $ userData ['Credit ' ] . ' ' . $ currency . PHP_EOL ;
654- $ stgUserData = zb_UserGetStargazerData ($ userLogin );
655- if ($ stgUserData ['CreditExpire ' ]) {
656- $ expireLabel = date ("Y-m-d " , $ stgUserData ['CreditExpire ' ]);
657- $ userContext .= __ ('Credit until date ' ) . ': ' . $ expireLabel . PHP_EOL ;
632+ $ currency = $ ubillingConfig ->getAlterParam ('TEMPLATE_CURRENCY ' , 'UAH ' );
633+ $ userState = zb_UserIsAlive ($ userData );
634+ $ stateLabel = __ ('Unknown ' );
635+ switch ($ userState ) {
636+ case 0 :
637+ $ stateLabel = __ ('Inactive ' );
638+ break ;
639+ case 1 :
640+ $ stateLabel = __ ('Active ' );
641+ break ;
642+ case -1 :
643+ $ stateLabel = __ ('User passive ' );
644+ break ;
645+ }
646+ $ userContext = '' ;
647+ $ userContext .= __ ('Also take into account these data ' ) . ' ' . PHP_EOL ;
648+ $ userContext .= __ ('Here is some information about user ' ) . ': ' . PHP_EOL ;
649+ $ userContext .= __ ('Real Name ' ) . ': ' . $ userData ['realname ' ] . PHP_EOL ;
650+ $ userContext .= __ ('Address ' ) . ': ' . $ userData ['fulladress ' ] . PHP_EOL ;
651+ $ userContext .= __ ('Account balance ' ) . ': ' . $ userData ['Cash ' ] . ' ' . $ currency . PHP_EOL ;
652+ if ($ userData ['Credit ' ]) {
653+ $ userContext .= __ ('Credit limit ' ) . ': ' . $ userData ['Credit ' ] . ' ' . $ currency . PHP_EOL ;
654+ $ stgUserData = zb_UserGetStargazerData ($ userLogin );
655+ if ($ stgUserData ['CreditExpire ' ]) {
656+ $ expireLabel = date ("Y-m-d " , $ stgUserData ['CreditExpire ' ]);
657+ $ userContext .= __ ('Credit until date ' ) . ': ' . $ expireLabel . PHP_EOL ;
658+ }
658659 }
659- }
660660
661- $ userContext .= __ ('Account status ' ) . ': ' . $ stateLabel . PHP_EOL ;
662- $ ispContextInfo = $ ubillingConfig ->getAlterParam ('HIVE_ISP_INFO ' , '' );
663- $ ispContextInfo = ubRouting::filters ($ ispContextInfo , 'safe ' );
664- if (!empty ($ ispContextInfo )) {
665- $ userContext .= __ ('Here some information about ISP ' ) . ': ' . $ ispContextInfo . PHP_EOL ;
666- }
661+ $ userContext .= __ ('Account status ' ) . ': ' . $ stateLabel . PHP_EOL ;
662+ $ ispContextInfo = $ ubillingConfig ->getAlterParam ('HIVE_ISP_INFO ' , '' );
663+ $ ispContextInfo = ubRouting::filters ($ ispContextInfo , 'safe ' );
664+ if (!empty ($ ispContextInfo )) {
665+ $ userContext .= __ ('Here some information about ISP ' ) . ': ' . $ ispContextInfo . PHP_EOL ;
666+ }
667667
668668
669- $ dialog [] = array (
670- 'role ' => 'system ' ,
671- 'content ' => $ userContext
672- );
673- }
669+ $ dialog [] = array (
670+ 'role ' => 'system ' ,
671+ 'content ' => $ userContext
672+ );
673+ }
674674 }
675675
676676 $ lastUserPrompt = $ tickettext ;
@@ -801,9 +801,9 @@ function getAiReply() {
801801 var seconds = 0;
802802 var timer = setInterval(function() {
803803 seconds++;
804- $("#hivemindstatus").html("<img src= \'skins/ajaxloader.gif \'> " + seconds + " '. __ ('sec. ' ). '");
804+ $("#hivemindstatus").html("<img src= \'skins/ajaxloader.gif \'> " + seconds + " ' . __ ('sec. ' ) . '");
805805 }, 1000);
806- $("#hivemindstatus").html("<img src= \'skins/ajaxloader.gif \'> 0 '. __ ('sec. ' ). '");
806+ $("#hivemindstatus").html("<img src= \'skins/ajaxloader.gif \'> 0 ' . __ ('sec. ' ) . '");
807807 $.ajax({
808808 type: "POST",
809809 url: "?module=ticketing&hivemind=true",
0 commit comments