Ejemplo n.º 1
0
                ?>
</small></td>
                        <td style=" vertical-align: middle; "><small><center><time id="c" datetime="<?php 
                echo $row['date_create'];
                ?>
"></time></center></small></td>
                        <td style=" vertical-align: middle; "><small><center><time id="a" datetime="<?php 
                echo $t_ago;
                ?>
"></time></center></small></td>
                        <td style=" vertical-align: middle; "><small><?php 
                get_unit_name($row['unit_id']);
                ?>
</small>
                            <small><div  id="" class=" text-muted"><?php 
                name_of_user($row['user_to_id']);
                ?>
</div></small></td>
                        <td style=" vertical-align: middle; "><small><center><?php 
                echo $st;
                ?>
</center>
                            </small></td>
                        <td style=" vertical-align: middle; ">
                            <center>
                                <div class="btn-group btn-group-xs actions">
                                    <button data-toggle="tooltip" data-placement="bottom" title="<?php 
                echo lang('t_list_a_ok_no');
                ?>
" type="button" <?php 
                echo $dis_status;
Ejemplo n.º 2
0
</button>
                                        <button id="action_aprove_no" type="button" class="btn btn-danger btn-xs" value="<?php 
                    echo $row['id'];
                    ?>
"><?php 
                    echo lang('APPROVE_no');
                    ?>
</button>
                                    </div>
                                </center>

                            </td>
                        </tr>
                        <tr>
                            <td><small><em><?php 
                    echo name_of_user($row['user_from']);
                    ?>
</em> <?php 
                    echo lang('APPROVE_want');
                    ?>
</small></td>

                            <td><small><?php 
                    echo $row['fio'];
                    ?>
</small></td>
                            <td><small><?php 
                    echo $row['login'];
                    ?>
</small></td>
                            <td><small><?php 
Ejemplo n.º 3
0
                ?>

                <div class="alert alert-success"><i class="fa fa-check"></i> <?php 
                echo lang('TICKET_msg_lock');
                ?>
</div>

            <?php 
            }
            if ($lb != "0") {
                ?>
                <div class="alert alert-danger"><?php 
                echo lang('TICKET_msg_lock_error');
                ?>
 <?php 
                echo name_of_user($lb);
                ?>
</div>
            <?php 
            }
        }
        if ($mode == "unlock") {
            $tid = $_POST['tid'];
            $stmt = $dbConnection->prepare('update tickets set lock_by=:n, last_update=now() where id=:tid');
            $stmt->execute(array(':tid' => $tid, ':n' => '0'));
            $unow = $_SESSION['helpdesk_user_id'];
            $stmt = $dbConnection->prepare('INSERT INTO ticket_log (msg, date_op, init_user_id, ticket_id)
values (:unlock, now(), :unow, :tid)');
            $stmt->execute(array(':tid' => $tid, ':unow' => $unow, ':unlock' => 'unlock'));
            ?>
Ejemplo n.º 4
0
function view_log($tid)
{
    global $dbConnection;
    $stmt = $dbConnection->prepare('SELECT msg,
							date_op, init_user_id, to_user_id, to_unit_id from ticket_log where
							ticket_id=:tid order by date_op DESC');
    $stmt->execute(array(':tid' => $tid));
    $re = $stmt->fetchAll();
    if (!empty($re)) {
        ?>

							<div class="col-md-12" style=" padding-left: 0px; padding-right: 0px; ">


								<div class="panel panel-default">
									<div class="panel-body" style="max-height: 400px; scroll-behavior: initial; overflow-y: scroll;">

										<table class="table table-hover">
											<thead>
											<tr>
												<th><center><small><?php 
        echo lang('TICKET_t_date');
        ?>
</small></center>	</th>
												<th><center><small><?php 
        echo lang('TICKET_t_init');
        ?>
	</small></center></th>
												<th><center><small><?php 
        echo lang('TICKET_t_action');
        ?>
 	</small></center></th>
												<th><center><small><?php 
        echo lang('TICKET_t_desc');
        ?>
	</small></center></th>


											</tr>
											</thead>

											<tbody>
											<?php 
        foreach ($re as $row) {
            $t_action = $row['msg'];
            if ($t_action == 'refer') {
                $icon_action = "fa fa-long-arrow-right";
                $text_action = "" . lang('TICKET_t_a_refer') . " <br>" . view_array(get_unit_name_return($row['to_unit_id'])) . "<br>" . name_of_user_ret($row['to_user_id']);
            }
            if ($t_action == 'arch') {
                $icon_action = "fa fa-archive";
                $text_action = lang('TICKET_t_a_arch');
            }
            if ($t_action == 'ok') {
                $icon_action = "fa fa-check-circle-o";
                $text_action = lang('TICKET_t_a_ok');
            }
            if ($t_action == 'no_ok') {
                $icon_action = "fa fa-circle-o";
                $text_action = lang('TICKET_t_a_nook');
            }
            if ($t_action == 'lock') {
                $icon_action = "fa fa-lock";
                $text_action = lang('TICKET_t_a_lock');
            }
            if ($t_action == 'unlock') {
                $icon_action = "fa fa-unlock";
                $text_action = lang('TICKET_t_a_unlock');
            }
            if ($t_action == 'create') {
                $icon_action = "fa fa-star-o";
                $text_action = lang('TICKET_t_a_create');
            }
            if ($t_action == 'edit_prio') {
                $icon_action = "fa fa-pencil-square";
                $text_action = lang('TICKET_t_a_e_prio');
            }
            if ($t_action == 'edit_msg') {
                $icon_action = "fa fa-pencil-square";
                $text_action = lang('TICKET_t_a_e_text');
            }
            if ($t_action == 'edit_subj') {
                $icon_action = "fa fa-pencil-square";
                $text_action = lang('TICKET_t_a_e_subj');
            }
            if ($t_action == 'comment') {
                $icon_action = "fa fa-comment";
                $text_action = lang('TICKET_t_a_com');
            }
            ?>
												<tr>
													<td style="width: 100px; vertical-align: inherit;"><small><center>
													
													<time id="c" datetime="<?php 
            echo $row['date_op'];
            ?>
"></time>
													
													</center></small></td>
													<td style=" width: 200px; vertical-align: inherit;"><small><center><?php 
            echo name_of_user($row['init_user_id']);
            ?>
</center></small></td>
													<td style=" width: 50px; vertical-align: inherit;"><small><center><i class="<?php 
            echo $icon_action;
            ?>
"></i>  </center></small></td>
													<td style=" width: 200px; vertical-align: inherit;"><small><?php 
            echo $text_action;
            ?>
</small></td>


												</tr>
											<?php 
        }
        ?>
											</tbody>
										</table>
									</div>
								</div>





							</div>



						<?php 
    }
}
Ejemplo n.º 5
0
</div>
                    </div>


                <?php 
                }
                if ($status_ok == 0) {
                    if ($lock_by != 0) {
                        if ($status_lock == "you") {
                            ?>
                            <div class="col-md-12" style="padding-top:20px;">
                                <div class="alert alert-warning"><?php 
                            echo lang('TICKET_t_lock');
                            ?>
 <strong><?php 
                            echo name_of_user($lock_by);
                            ?>
</strong>. <br><?php 
                            echo lang('TICKET_t_lock_1');
                            ?>
</div>
                            </div>
                        <?php 
                        }
                        if ($status_lock == "me") {
                            ?>
                            <div class="col-md-12" style="padding-top:20px;" id="msg_e">
                                <div class="alert alert-warning"><?php 
                            echo lang('TICKET_t_lock_i');
                            ?>
</div>
Ejemplo n.º 6
0
                echo lang('TICKET_name');
                ?>
 <strong>#<?php 
                echo $row['id'];
                ?>
</strong></a></div>
  <div class="panel-body">
	    <table class="table table-bordered">
                <tbody>
                <tr>
                    <td style="width:50px;"><small><strong><?php 
                echo lang('TICKET_t_from');
                ?>
 </strong></small></td>
                    <td><small><?php 
                echo name_of_user($row['user_init_id']);
                ?>
 </small></td>
                    <td style="width:150px;"><small><strong> <?php 
                echo lang('TICKET_t_was_create');
                ?>
</strong></small></td>
                    <td style="width:150px;"><small><time id="c" datetime="<?php 
                echo $row['date_create'];
                ?>
"></time> </small></td>
                </tr>
                <tr>
                    <td style="width:50px;"><small><strong><?php 
                echo lang('TICKET_t_to');
                ?>