|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
<!-- saved from url=(0109)http://localhost/freenetis/cs/work_reports/show_all/100/your_votes/ASC/page/1?path_qsurl=members%2Fshow%2F166 -->
|
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
|
|
|
|
|
|
|
<title>Kohana_Database_Exception</title>
|
|
|
|
<style type="text/css">
|
|
/* <![CDATA[ */
|
|
* {padding:0;margin:0;border:0;}
|
|
body {background:#eee;font-family:sans-serif;font-size:85%;}
|
|
h1,h2,h3,h4 {margin-bottom:0.5em;padding:0.2em 0;border-bottom:solid 1px #ccc;color:#911;}
|
|
h1 {font-size:2em;}
|
|
h2 {font-size:1.5em;}
|
|
p,pre {margin-bottom:0.5em;}
|
|
strong {color:#700;}
|
|
#wrap {width:600px;margin:2em auto;padding:0.5em 1em;background:#fff;border:solid 1px #ddd;border-bottom:solid 2px #aaa;}
|
|
#stats {margin:0;padding-top: 0.5em;border-top:solid 1px #ccc;font-size:0.8em;text-align:center;color:#555;}
|
|
.message {margin:1em;padding:0.5em;background:#dfdfdf;border:solid 1px #999;}
|
|
.detail {text-align:center;}
|
|
.backtrace {margin:0 2em 1em;}
|
|
.backtrace pre {background:#eee;}
|
|
.error {font-size: 10px; color: red}
|
|
/* ]]> */
|
|
</style>
|
|
<link rel="stylesheet" type="text/css" href="./chyba_files/forms.css" media="screen">
|
|
<!--[if IE]>
|
|
<link rel="stylesheet" type="text/css" href="http://localhost/freenetis/media/css/forms.css" media="screen" />
|
|
<![endif]-->
|
|
<!--
|
|
This is a little <script> does two things:
|
|
1. Prevents a strange bug that can happen in IE when using the <style> tag
|
|
2. Accounts for PHP's relative anchors in errors
|
|
-->
|
|
<script type="text/javascript">document.write('<base href="http://php.net/" />')</script><!--<base href="http://php.net/">--><base href=".">
|
|
<script type="text/javascript" src="./chyba_files/jquery.min.js"></script>
|
|
<script type="text/javascript" src="./chyba_files/jquery.validate.min.js"></script>
|
|
<script type="text/javascript"><!--
|
|
|
|
$(document).ready(function ()
|
|
{
|
|
// toogle trace path
|
|
$('#link_stack_trace').click(function ()
|
|
{
|
|
$(this).hide();
|
|
$('#stack_trace_message').show();
|
|
return false;
|
|
});
|
|
|
|
// on click on tetx area remove text and delete this trigger
|
|
$('textarea').focus(function ()
|
|
{
|
|
$(this).text('');
|
|
$(this).focus(function () {});
|
|
return false;
|
|
});
|
|
|
|
// form
|
|
$('form').validate();
|
|
});
|
|
|
|
--></script>
|
|
</head>
|
|
<body>
|
|
<div id="wrap">
|
|
<h1>Chyba serveru</h1>
|
|
<p>Nahlašte prosím tuto chybu jako bug tímto formulářem:</p>
|
|
<form action="http://localhost/freenetis/cs/email/send_email_to_developers" class="form" method="post" style="margin-bottom: 20px" novalidate="novalidate">
|
|
<table cellspacing="4" class="form" style="background: #F1F1F1">
|
|
<tbody><tr>
|
|
<td><label for="uname">Vaše jméno:</label></td>
|
|
<td><input type="text" name="uname" class="required"></td>
|
|
</tr>
|
|
<tr>
|
|
<td><label for="uemail">Váš email:</label></td>
|
|
<td><input type="text" name="uemail" class="required email"></td>
|
|
</tr>
|
|
<tr>
|
|
<td><label for="ename">Název chyby:</label></td>
|
|
<td><input type="text" name="ename" class="required"></td>
|
|
</tr>
|
|
<tr>
|
|
<td><label for="udescription">Popis:</label></td>
|
|
<td><textarea cols="80" rows="20" name="udescription" class="required" style="width: 380px; height: 100px;">Popište jakou akci jste prováděl(a), když se objevila tato chyba...</textarea></td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td><input type="submit" value="Zaslat chybové hlášení"></td>
|
|
</tr>
|
|
<input type="hidden" name="line" value="374">
|
|
<input type="hidden" name="file" value="374">
|
|
<input type="hidden" name="url" value="work_reports/show_all/100/your_votes/ASC/page/1">
|
|
<input type="hidden" name="error" value="Kohana_Database_Exception">
|
|
<input type="hidden" name="description" value="">
|
|
<input type="hidden" name="detail" value="Chyba se vyskytla na <strong>řádku 374</strong> souboru <strong>system/libraries/drivers/Database/Mysql.php</strong>.">
|
|
<input type="hidden" name="trace" value="<ul class="backtrace"><li><strong>system/libraries/drivers/Database/Mysql.php [99]:</strong><pre>Mysql_Result->__construct( )</pre></li>
|
|
<li><strong>system/libraries/Database.php [187]:</strong><pre>Database_Mysql_Driver->query(
|
|
SELECT * FROM
|
|
(
|
|
SELECT r.id, r.user_id, CONCAT(u.name, ' ', u.surname) as uname,
|
|
r.description, ROUND(SUM(j.suggest_amount), 2) AS suggest_amount,
|
|
MIN(j.date) AS date_from, MAX(j.date) AS date_to, r.type,
|
|
ROUND(SUM(j.hours), 2) AS hours, SUM(j.km) AS km, r.payment_type,
|
|
IF(MIN(state) <= 1, MIN(state), MAX(state)) AS state,
|
|
IFNULL(t.amount, IF(r.payment_type = 1, 'Platba hotově', 0)) AS rating,
|
|
r.transfer_id, (agree_count - disagree_count) AS approval_state,
|
|
IFNULL(v.agree_count, 0) AS agree_count,
|
|
IFNULL(v.abstain_count, 0) AS abstain_count,
|
|
IFNULL(v.disagree_count, 0) AS disagree_count,
|
|
v.comment AS vote_comments
|
|
FROM job_reports r
|
|
LEFT JOIN transfers t ON t.id = r.transfer_id
|
|
JOIN users u ON u.id = r.user_id
|
|
JOIN jobs j ON r.id = j.job_report_id
|
|
LEFT JOIN
|
|
(
|
|
SELECT
|
|
job_id,
|
|
SUM(agree) AS agree_count,
|
|
SUM(abstain) AS abstain_count,
|
|
SUM(disagree) AS disagree_count,
|
|
GROUP_CONCAT(
|
|
CONCAT(
|
|
u.name,' ',u.surname,' (',v.time,'):
|
|
',
|
|
IF(vote = 1, 'Souhlas', IF(vote = -1, 'Nesouhlas', 'Zdržet se'))
|
|
)
|
|
ORDER BY time
|
|
SEPARATOR ',
|
|
|
|
'
|
|
) AS comment
|
|
FROM
|
|
(
|
|
SELECT
|
|
v.*, j.id AS job_id,
|
|
IF(vote = 1, 1, 0) AS agree,
|
|
IF(vote = 0, 1, 0) AS abstain,
|
|
IF(vote = -1, 1, 0) AS disagree
|
|
FROM votes v
|
|
JOIN jobs j ON v.type = 1 AND fk_id = j.id
|
|
AND j.job_report_id IS NOT NULL
|
|
GROUP BY j.job_report_id, v.user_id
|
|
) v
|
|
JOIN users u ON v.user_id = u.id
|
|
GROUP BY job_id
|
|
) v ON v.job_id = j.id
|
|
WHERE r.concept = 0
|
|
GROUP BY r.id
|
|
) wr
|
|
ORDER BY `your_votes` asc
|
|
LIMIT 0, 100
|
|
)</pre></li>
|
|
<li><strong>application/models/job_report.php [402]:</strong><pre>Database->query(
|
|
SELECT * FROM
|
|
(
|
|
SELECT r.id, r.user_id, CONCAT(u.name, ' ', u.surname) as uname,
|
|
r.description, ROUND(SUM(j.suggest_amount), 2) AS suggest_amount,
|
|
MIN(j.date) AS date_from, MAX(j.date) AS date_to, r.type,
|
|
ROUND(SUM(j.hours), 2) AS hours, SUM(j.km) AS km, r.payment_type,
|
|
IF(MIN(state) <= 1, MIN(state), MAX(state)) AS state,
|
|
IFNULL(t.amount, IF(r.payment_type = 1, ?, 0)) AS rating,
|
|
r.transfer_id, (agree_count - disagree_count) AS approval_state,
|
|
IFNULL(v.agree_count, 0) AS agree_count,
|
|
IFNULL(v.abstain_count, 0) AS abstain_count,
|
|
IFNULL(v.disagree_count, 0) AS disagree_count,
|
|
v.comment AS vote_comments
|
|
FROM job_reports r
|
|
LEFT JOIN transfers t ON t.id = r.transfer_id
|
|
JOIN users u ON u.id = r.user_id
|
|
JOIN jobs j ON r.id = j.job_report_id
|
|
LEFT JOIN
|
|
(
|
|
SELECT
|
|
job_id,
|
|
SUM(agree) AS agree_count,
|
|
SUM(abstain) AS abstain_count,
|
|
SUM(disagree) AS disagree_count,
|
|
GROUP_CONCAT(
|
|
CONCAT(
|
|
u.name,' ',u.surname,' (',v.time,'):
|
|
',
|
|
IF(vote = ?, ?, IF(vote = ?, ?, ?))
|
|
)
|
|
ORDER BY time
|
|
SEPARATOR ',
|
|
|
|
'
|
|
) AS comment
|
|
FROM
|
|
(
|
|
SELECT
|
|
v.*, j.id AS job_id,
|
|
IF(vote = ?, 1, 0) AS agree,
|
|
IF(vote = ?, 1, 0) AS abstain,
|
|
IF(vote = ?, 1, 0) AS disagree
|
|
FROM votes v
|
|
JOIN jobs j ON v.type = 1 AND fk_id = j.id
|
|
AND j.job_report_id IS NOT NULL
|
|
GROUP BY j.job_report_id, v.user_id
|
|
) v
|
|
JOIN users u ON v.user_id = u.id
|
|
GROUP BY job_id
|
|
) v ON v.job_id = j.id
|
|
WHERE r.concept = 0
|
|
GROUP BY r.id
|
|
) wr
|
|
ORDER BY `your_votes` asc
|
|
LIMIT 0, 100
|
|
, Array
|
|
(
|
|
[0] => Platba hotově
|
|
[1] => 1
|
|
[2] => Souhlas
|
|
[3] => -1
|
|
[4] => Nesouhlas
|
|
[5] => Zdržet se
|
|
[6] => 1
|
|
[7] => 0
|
|
[8] => -1
|
|
)
|
|
)</pre></li>
|
|
<li><strong>application/controllers/work_reports.php [125]:</strong><pre>Job_report_Model->get_all_work_reports( )</pre></li>
|
|
<li><pre>Work_reports_Controller->show_all( 100, your_votes, ASC, page, 1 )</pre></li>
|
|
<li><strong>system/core/Kohana.php [363]:</strong><pre>call_user_func_array( Array
|
|
(
|
|
[0] => Work_reports_Controller Object
|
|
(
|
|
[arr] =>
|
|
[settings] => Settings Object
|
|
(
|
|
)
|
|
|
|
[popup] => 0
|
|
[dialog] => 0
|
|
[noredirect] =>
|
|
[user_has_voip] =>
|
|
[ip_address_span] => 127.0.0.1
|
|
[unread_user_mails] => 14
|
|
[count_of_unclosed_logged_errors] => 0
|
|
[devices_down_count] => 0
|
|
[user_favourites_pages] => Mysql_Result Object
|
|
(
|
|
[fetch_type:protected] => mysql_fetch_object
|
|
[return_type:protected] => stdClass
|
|
[result:protected] => Resource id #59
|
|
[insert_id:protected] =>
|
|
[sql:protected] =>
|
|
SELECT * FROM user_favourite_pages
|
|
WHERE user_id = '166'
|
|
ORDER BY `title` asc
|
|
LIMIT 0, 50
|
|
|
|
[current_row:protected] => 0
|
|
[total_rows:protected] => 0
|
|
)
|
|
|
|
[member_id:protected] => 166
|
|
[user_id:protected] => 166
|
|
[member_account_id:protected] => 176
|
|
[session:protected] => Session Object
|
|
(
|
|
[input:protected] => Input Object
|
|
(
|
|
[use_xss_clean:protected] =>
|
|
[ip_address] =>
|
|
[user_agent] =>
|
|
)
|
|
|
|
)
|
|
|
|
[groups_aro_map:Controller:private] => Groups_aro_map_Model Object
|
|
(
|
|
[table_names_plural:protected] =>
|
|
[has_one:protected] => Array
|
|
(
|
|
)
|
|
|
|
[belongs_to:protected] => Array
|
|
(
|
|
)
|
|
|
|
[has_many:protected] => Array
|
|
(
|
|
)
|
|
|
|
[has_and_belongs_to_many:protected] => Array
|
|
(
|
|
)
|
|
|
|
[load_with:protected] => Array
|
|
(
|
|
)
|
|
|
|
[object:protected] => Array
|
|
(
|
|
[group_id] => 0
|
|
[aro_id] => 0
|
|
)
|
|
|
|
[changed:protected] => Array
|
|
(
|
|
)
|
|
|
|
[related:protected] => Array
|
|
(
|
|
)
|
|
|
|
[loaded:protected] =>
|
|
[saved:protected] =>
|
|
[sorting:protected] => Array
|
|
(
|
|
[id] => asc
|
|
)
|
|
|
|
[object_relations:protected] => Array
|
|
(
|
|
)
|
|
|
|
[changed_relations:protected] => Array
|
|
(
|
|
)
|
|
|
|
[object_name:protected] => groups_aro_map
|
|
[object_plural:protected] => groups_aro_maps
|
|
[table_name:protected] => groups_aro_map
|
|
[table_columns:protected] => Array
|
|
(
|
|
[group_id] => Array
|
|
(
|
|
[type] => int
|
|
[max] => 2147483647
|
|
[unsigned] =>
|
|
)
|
|
|
|
[aro_id] => Array
|
|
(
|
|
[type] => int
|
|
[max] => 2147483647
|
|
[unsigned] =>
|
|
)
|
|
|
|
)
|
|
|
|
[ignored_columns:protected] =>
|
|
[primary_key:protected] => id
|
|
[primary_val:protected] => name
|
|
[foreign_key:protected] => Array
|
|
(
|
|
)
|
|
|
|
[reload_on_wakeup:protected] => 1
|
|
[db:protected] => Database Object
|
|
(
|
|
[config:protected] => Array
|
|
(
|
|
[benchmark] =>
|
|
[persistent] =>
|
|
[connection] => Array
|
|
(
|
|
[type] => mysql
|
|
[user] => root
|
|
[pass] =>
|
|
[host] => localhost
|
|
[port] =>
|
|
[socket] =>
|
|
[database] => freenetis_video_olga
|
|
)
|
|
|
|
[character_set] => utf8
|
|
[table_prefix] =>
|
|
[object] => 1
|
|
[cache] =>
|
|
[escape] => 1
|
|
)
|
|
|
|
[driver:protected] => Database_Mysql_Driver Object
|
|
(
|
|
[link:protected] => Resource id #31
|
|
[db_config:protected] => Array
|
|
(
|
|
[benchmark] =>
|
|
[persistent] =>
|
|
[connection] => Array
|
|
(
|
|
[type] => mysql
|
|
[user] => root
|
|
[pass] =>
|
|
[host] => localhost
|
|
[port] =>
|
|
[socket] =>
|
|
[database] => freenetis_video_olga
|
|
)
|
|
|
|
[character_set] => utf8
|
|
[table_prefix] =>
|
|
[object] => 1
|
|
[cache] =>
|
|
[escape] => 1
|
|
)
|
|
|
|
[query_cache:protected] =>
|
|
)
|
|
|
|
[link:protected] => Resource id #31
|
|
[select:protected] => Array
|
|
(
|
|
)
|
|
|
|
[set:protected] => Array
|
|
(
|
|
)
|
|
|
|
[from:protected] => Array
|
|
(
|
|
)
|
|
|
|
[join:protected] => Array
|
|
(
|
|
)
|
|
|
|
[where:protected] => Array
|
|
(
|
|
)
|
|
|
|
[orderby:protected] => Array
|
|
(
|
|
)
|
|
|
|
[order:protected] => Array
|
|
(
|
|
)
|
|
|
|
[groupby:protected] => Array
|
|
(
|
|
)
|
|
|
|
[having:protected] => Array
|
|
(
|
|
)
|
|
|
|
[distinct:protected] =>
|
|
[limit:protected] =>
|
|
[offset:protected] =>
|
|
[last_query:protected] =>
|
|
SELECT * FROM
|
|
(
|
|
SELECT r.id, r.user_id, CONCAT(u.name, ' ', u.surname) as uname,
|
|
r.description, ROUND(SUM(j.suggest_amount), 2) AS suggest_amount,
|
|
MIN(j.date) AS date_from, MAX(j.date) AS date_to, r.type,
|
|
ROUND(SUM(j.hours), 2) AS hours, SUM(j.km) AS km, r.payment_type,
|
|
IF(MIN(state) <= 1, MIN(state), MAX(state)) AS state,
|
|
IFNULL(t.amount, IF(r.payment_type = 1, 'Platba hotově', 0)) AS rating,
|
|
r.transfer_id, (agree_count - disagree_count) AS approval_state,
|
|
IFNULL(v.agree_count, 0) AS agree_count,
|
|
IFNULL(v.abstain_count, 0) AS abstain_count,
|
|
IFNULL(v.disagree_count, 0) AS disagree_count,
|
|
v.comment AS vote_comments
|
|
FROM job_reports r
|
|
LEFT JOIN transfers t ON t.id = r.transfer_id
|
|
JOIN users u ON u.id = r.user_id
|
|
JOIN jobs j ON r.id = j.job_report_id
|
|
LEFT JOIN
|
|
(
|
|
SELECT
|
|
job_id,
|
|
SUM(agree) AS agree_count,
|
|
SUM(abstain) AS abstain_count,
|
|
SUM(disagree) AS disagree_count,
|
|
GROUP_CONCAT(
|
|
CONCAT(
|
|
u.name,' ',u.surname,' (',v.time,'):
|
|
',
|
|
IF(vote = 1, 'Souhlas', IF(vote = -1, 'Nesouhlas', 'Zdržet se'))
|
|
)
|
|
ORDER BY time
|
|
SEPARATOR ',
|
|
|
|
'
|
|
) AS comment
|
|
FROM
|
|
(
|
|
SELECT
|
|
v.*, j.id AS job_id,
|
|
IF(vote = 1, 1, 0) AS agree,
|
|
IF(vote = 0, 1, 0) AS abstain,
|
|
IF(vote = -1, 1, 0) AS disagree
|
|
FROM votes v
|
|
JOIN jobs j ON v.type = 1 AND fk_id = j.id
|
|
AND j.job_report_id IS NOT NULL
|
|
GROUP BY j.job_report_id, v.user_id
|
|
) v
|
|
JOIN users u ON v.user_id = u.id
|
|
GROUP BY job_id
|
|
) v ON v.job_id = j.id
|
|
WHERE r.concept = 0
|
|
GROUP BY r.id
|
|
) wr
|
|
ORDER BY `your_votes` asc
|
|
LIMIT 0, 100
|
|
|
|
[query_history:protected] => Array
|
|
(
|
|
)
|
|
|
|
)
|
|
|
|
[db_applied:protected] => Array
|
|
(
|
|
[where] => where
|
|
[select] => select
|
|
[orderby] => orderby
|
|
)
|
|
|
|
[with_applied:protected] => Array
|
|
(
|
|
)
|
|
|
|
[is_in_transaction:protected] =>
|
|
[is_logger_on:protected] => Array
|
|
(
|
|
[add] => 1
|
|
[update] => 1
|
|
[delete] => 1
|
|
)
|
|
|
|
)
|
|
|
|
[load] => Loader Object
|
|
(
|
|
)
|
|
|
|
[uri] => URI Object
|
|
(
|
|
)
|
|
|
|
[input] => Input Object
|
|
(
|
|
[use_xss_clean:protected] =>
|
|
[ip_address] =>
|
|
[user_agent] =>
|
|
)
|
|
|
|
[is_favourite] =>
|
|
)
|
|
|
|
[1] => show_all
|
|
)
|
|
, Array
|
|
(
|
|
[0] => 100
|
|
[1] => your_votes
|
|
[2] => ASC
|
|
[3] => page
|
|
[4] => 1
|
|
)
|
|
)</pre></li>
|
|
<li><pre>Kohana::instance( )</pre></li>
|
|
<li><strong>system/core/Event.php [217]:</strong><pre>call_user_func( Array
|
|
(
|
|
[0] => Kohana
|
|
[1] => instance
|
|
)
|
|
)</pre></li>
|
|
<li><strong>system/core/Bootstrap.php [55]:</strong><pre>Event::run( system.execute )</pre></li>
|
|
<li><strong>index.php [109]:</strong><pre>require( system/core/Bootstrap.php )</pre></li></ul>">
|
|
<input type="hidden" name="message" value="Chyba v SQL dotazu - Unknown column 'your_votes' in 'order clause'">
|
|
</tbody></table>
|
|
</form>
|
|
<h2>Kohana_Database_Exception</h2>
|
|
<p></p>
|
|
<p class="message">Chyba v SQL dotazu - Unknown column 'your_votes' in 'order clause'</p>
|
|
<p class="detail">Chyba se vyskytla na <strong>řádku 374</strong> souboru <strong>system/libraries/drivers/Database/Mysql.php</strong>.</p>
|
|
<h3>Trasování zásobníku</h3>
|
|
<ul class="backtrace"><li><strong>system/libraries/drivers/Database/Mysql.php [99]:</strong><pre>Mysql_Result->__construct( )</pre></li>
|
|
<li><strong>system/libraries/Database.php [187]:</strong><pre>Database_Mysql_Driver->query(
|
|
SELECT * FROM
|
|
(
|
|
SELECT r.id, r.user_id, CONCAT(u.name, ' ', u.surname) as uname,
|
|
r.description, ROUND(SUM(j.suggest_amount), 2) AS suggest_amount,
|
|
MIN(j.date) AS date_from, MAX(j.date) AS date_to, r.type,
|
|
ROUND(SUM(j.hours), 2) AS hours, SUM(j.km) AS km, r.payment_type,
|
|
IF(MIN(state) <= 1, MIN(state), MAX(state)) AS state,
|
|
IFNULL(t.amount, IF(r.payment_type = 1, 'Platba hotově', 0)) AS rating,
|
|
r.transfer_id, (agree_count - disagree_count) AS approval_state,
|
|
IFNULL(v.agree_count, 0) AS agree_count,
|
|
IFNULL(v.abstain_count, 0) AS abstain_count,
|
|
IFNULL(v.disagree_count, 0) AS disagree_count,
|
|
v.comment AS vote_comments
|
|
FROM job_reports r
|
|
LEFT JOIN transfers t ON t.id = r.transfer_id
|
|
JOIN users u ON u.id = r.user_id
|
|
JOIN jobs j ON r.id = j.job_report_id
|
|
LEFT JOIN
|
|
(
|
|
SELECT
|
|
job_id,
|
|
SUM(agree) AS agree_count,
|
|
SUM(abstain) AS abstain_count,
|
|
SUM(disagree) AS disagree_count,
|
|
GROUP_CONCAT(
|
|
CONCAT(
|
|
u.name,' ',u.surname,' (',v.time,'):
|
|
',
|
|
IF(vote = 1, 'Souhlas', IF(vote = -1, 'Nesouhlas', 'Zdržet se'))
|
|
)
|
|
ORDER BY time
|
|
SEPARATOR ',
|
|
|
|
'
|
|
) AS comment
|
|
FROM
|
|
(
|
|
SELECT
|
|
v.*, j.id AS job_id,
|
|
IF(vote = 1, 1, 0) AS agree,
|
|
IF(vote = 0, 1, 0) AS abstain,
|
|
IF(vote = -1, 1, 0) AS disagree
|
|
FROM votes v
|
|
JOIN jobs j ON v.type = 1 AND fk_id = j.id
|
|
AND j.job_report_id IS NOT NULL
|
|
GROUP BY j.job_report_id, v.user_id
|
|
) v
|
|
JOIN users u ON v.user_id = u.id
|
|
GROUP BY job_id
|
|
) v ON v.job_id = j.id
|
|
WHERE r.concept = 0
|
|
GROUP BY r.id
|
|
) wr
|
|
ORDER BY `your_votes` asc
|
|
LIMIT 0, 100
|
|
)</pre></li>
|
|
<li><strong>application/models/job_report.php [402]:</strong><pre>Database->query(
|
|
SELECT * FROM
|
|
(
|
|
SELECT r.id, r.user_id, CONCAT(u.name, ' ', u.surname) as uname,
|
|
r.description, ROUND(SUM(j.suggest_amount), 2) AS suggest_amount,
|
|
MIN(j.date) AS date_from, MAX(j.date) AS date_to, r.type,
|
|
ROUND(SUM(j.hours), 2) AS hours, SUM(j.km) AS km, r.payment_type,
|
|
IF(MIN(state) <= 1, MIN(state), MAX(state)) AS state,
|
|
IFNULL(t.amount, IF(r.payment_type = 1, ?, 0)) AS rating,
|
|
r.transfer_id, (agree_count - disagree_count) AS approval_state,
|
|
IFNULL(v.agree_count, 0) AS agree_count,
|
|
IFNULL(v.abstain_count, 0) AS abstain_count,
|
|
IFNULL(v.disagree_count, 0) AS disagree_count,
|
|
v.comment AS vote_comments
|
|
FROM job_reports r
|
|
LEFT JOIN transfers t ON t.id = r.transfer_id
|
|
JOIN users u ON u.id = r.user_id
|
|
JOIN jobs j ON r.id = j.job_report_id
|
|
LEFT JOIN
|
|
(
|
|
SELECT
|
|
job_id,
|
|
SUM(agree) AS agree_count,
|
|
SUM(abstain) AS abstain_count,
|
|
SUM(disagree) AS disagree_count,
|
|
GROUP_CONCAT(
|
|
CONCAT(
|
|
u.name,' ',u.surname,' (',v.time,'):
|
|
',
|
|
IF(vote = ?, ?, IF(vote = ?, ?, ?))
|
|
)
|
|
ORDER BY time
|
|
SEPARATOR ',
|
|
|
|
'
|
|
) AS comment
|
|
FROM
|
|
(
|
|
SELECT
|
|
v.*, j.id AS job_id,
|
|
IF(vote = ?, 1, 0) AS agree,
|
|
IF(vote = ?, 1, 0) AS abstain,
|
|
IF(vote = ?, 1, 0) AS disagree
|
|
FROM votes v
|
|
JOIN jobs j ON v.type = 1 AND fk_id = j.id
|
|
AND j.job_report_id IS NOT NULL
|
|
GROUP BY j.job_report_id, v.user_id
|
|
) v
|
|
JOIN users u ON v.user_id = u.id
|
|
GROUP BY job_id
|
|
) v ON v.job_id = j.id
|
|
WHERE r.concept = 0
|
|
GROUP BY r.id
|
|
) wr
|
|
ORDER BY `your_votes` asc
|
|
LIMIT 0, 100
|
|
, Array
|
|
(
|
|
[0] => Platba hotově
|
|
[1] => 1
|
|
[2] => Souhlas
|
|
[3] => -1
|
|
[4] => Nesouhlas
|
|
[5] => Zdržet se
|
|
[6] => 1
|
|
[7] => 0
|
|
[8] => -1
|
|
)
|
|
)</pre></li>
|
|
<li><strong>application/controllers/work_reports.php [125]:</strong><pre>Job_report_Model->get_all_work_reports( )</pre></li>
|
|
<li><pre>Work_reports_Controller->show_all( 100, your_votes, ASC, page, 1 )</pre></li>
|
|
<li><strong>system/core/Kohana.php [363]:</strong><pre>call_user_func_array( Array
|
|
(
|
|
[0] => Work_reports_Controller Object
|
|
(
|
|
[arr] =>
|
|
[settings] => Settings Object
|
|
(
|
|
)
|
|
|
|
[popup] => 0
|
|
[dialog] => 0
|
|
[noredirect] =>
|
|
[user_has_voip] =>
|
|
[ip_address_span] => 127.0.0.1
|
|
[unread_user_mails] => 14
|
|
[count_of_unclosed_logged_errors] => 0
|
|
[devices_down_count] => 0
|
|
[user_favourites_pages] => Mysql_Result Object
|
|
(
|
|
[fetch_type:protected] => mysql_fetch_object
|
|
[return_type:protected] => stdClass
|
|
[result:protected] => Resource id #59
|
|
[insert_id:protected] =>
|
|
[sql:protected] =>
|
|
SELECT * FROM user_favourite_pages
|
|
WHERE user_id = '166'
|
|
ORDER BY `title` asc
|
|
LIMIT 0, 50
|
|
|
|
[current_row:protected] => 0
|
|
[total_rows:protected] => 0
|
|
)
|
|
|
|
[member_id:protected] => 166
|
|
[user_id:protected] => 166
|
|
[member_account_id:protected] => 176
|
|
[session:protected] => Session Object
|
|
(
|
|
[input:protected] => Input Object
|
|
(
|
|
[use_xss_clean:protected] =>
|
|
[ip_address] =>
|
|
[user_agent] =>
|
|
)
|
|
|
|
)
|
|
|
|
[groups_aro_map:Controller:private] => Groups_aro_map_Model Object
|
|
(
|
|
[table_names_plural:protected] =>
|
|
[has_one:protected] => Array
|
|
(
|
|
)
|
|
|
|
[belongs_to:protected] => Array
|
|
(
|
|
)
|
|
|
|
[has_many:protected] => Array
|
|
(
|
|
)
|
|
|
|
[has_and_belongs_to_many:protected] => Array
|
|
(
|
|
)
|
|
|
|
[load_with:protected] => Array
|
|
(
|
|
)
|
|
|
|
[object:protected] => Array
|
|
(
|
|
[group_id] => 0
|
|
[aro_id] => 0
|
|
)
|
|
|
|
[changed:protected] => Array
|
|
(
|
|
)
|
|
|
|
[related:protected] => Array
|
|
(
|
|
)
|
|
|
|
[loaded:protected] =>
|
|
[saved:protected] =>
|
|
[sorting:protected] => Array
|
|
(
|
|
[id] => asc
|
|
)
|
|
|
|
[object_relations:protected] => Array
|
|
(
|
|
)
|
|
|
|
[changed_relations:protected] => Array
|
|
(
|
|
)
|
|
|
|
[object_name:protected] => groups_aro_map
|
|
[object_plural:protected] => groups_aro_maps
|
|
[table_name:protected] => groups_aro_map
|
|
[table_columns:protected] => Array
|
|
(
|
|
[group_id] => Array
|
|
(
|
|
[type] => int
|
|
[max] => 2147483647
|
|
[unsigned] =>
|
|
)
|
|
|
|
[aro_id] => Array
|
|
(
|
|
[type] => int
|
|
[max] => 2147483647
|
|
[unsigned] =>
|
|
)
|
|
|
|
)
|
|
|
|
[ignored_columns:protected] =>
|
|
[primary_key:protected] => id
|
|
[primary_val:protected] => name
|
|
[foreign_key:protected] => Array
|
|
(
|
|
)
|
|
|
|
[reload_on_wakeup:protected] => 1
|
|
[db:protected] => Database Object
|
|
(
|
|
[config:protected] => Array
|
|
(
|
|
[benchmark] =>
|
|
[persistent] =>
|
|
[connection] => Array
|
|
(
|
|
[type] => mysql
|
|
[user] => root
|
|
[pass] =>
|
|
[host] => localhost
|
|
[port] =>
|
|
[socket] =>
|
|
[database] => freenetis_video_olga
|
|
)
|
|
|
|
[character_set] => utf8
|
|
[table_prefix] =>
|
|
[object] => 1
|
|
[cache] =>
|
|
[escape] => 1
|
|
)
|
|
|
|
[driver:protected] => Database_Mysql_Driver Object
|
|
(
|
|
[link:protected] => Resource id #31
|
|
[db_config:protected] => Array
|
|
(
|
|
[benchmark] =>
|
|
[persistent] =>
|
|
[connection] => Array
|
|
(
|
|
[type] => mysql
|
|
[user] => root
|
|
[pass] =>
|
|
[host] => localhost
|
|
[port] =>
|
|
[socket] =>
|
|
[database] => freenetis_video_olga
|
|
)
|
|
|
|
[character_set] => utf8
|
|
[table_prefix] =>
|
|
[object] => 1
|
|
[cache] =>
|
|
[escape] => 1
|
|
)
|
|
|
|
[query_cache:protected] =>
|
|
)
|
|
|
|
[link:protected] => Resource id #31
|
|
[select:protected] => Array
|
|
(
|
|
)
|
|
|
|
[set:protected] => Array
|
|
(
|
|
)
|
|
|
|
[from:protected] => Array
|
|
(
|
|
)
|
|
|
|
[join:protected] => Array
|
|
(
|
|
)
|
|
|
|
[where:protected] => Array
|
|
(
|
|
)
|
|
|
|
[orderby:protected] => Array
|
|
(
|
|
)
|
|
|
|
[order:protected] => Array
|
|
(
|
|
)
|
|
|
|
[groupby:protected] => Array
|
|
(
|
|
)
|
|
|
|
[having:protected] => Array
|
|
(
|
|
)
|
|
|
|
[distinct:protected] =>
|
|
[limit:protected] =>
|
|
[offset:protected] =>
|
|
[last_query:protected] =>
|
|
SELECT * FROM
|
|
(
|
|
SELECT r.id, r.user_id, CONCAT(u.name, ' ', u.surname) as uname,
|
|
r.description, ROUND(SUM(j.suggest_amount), 2) AS suggest_amount,
|
|
MIN(j.date) AS date_from, MAX(j.date) AS date_to, r.type,
|
|
ROUND(SUM(j.hours), 2) AS hours, SUM(j.km) AS km, r.payment_type,
|
|
IF(MIN(state) <= 1, MIN(state), MAX(state)) AS state,
|
|
IFNULL(t.amount, IF(r.payment_type = 1, 'Platba hotově', 0)) AS rating,
|
|
r.transfer_id, (agree_count - disagree_count) AS approval_state,
|
|
IFNULL(v.agree_count, 0) AS agree_count,
|
|
IFNULL(v.abstain_count, 0) AS abstain_count,
|
|
IFNULL(v.disagree_count, 0) AS disagree_count,
|
|
v.comment AS vote_comments
|
|
FROM job_reports r
|
|
LEFT JOIN transfers t ON t.id = r.transfer_id
|
|
JOIN users u ON u.id = r.user_id
|
|
JOIN jobs j ON r.id = j.job_report_id
|
|
LEFT JOIN
|
|
(
|
|
SELECT
|
|
job_id,
|
|
SUM(agree) AS agree_count,
|
|
SUM(abstain) AS abstain_count,
|
|
SUM(disagree) AS disagree_count,
|
|
GROUP_CONCAT(
|
|
CONCAT(
|
|
u.name,' ',u.surname,' (',v.time,'):
|
|
',
|
|
IF(vote = 1, 'Souhlas', IF(vote = -1, 'Nesouhlas', 'Zdržet se'))
|
|
)
|
|
ORDER BY time
|
|
SEPARATOR ',
|
|
|
|
'
|
|
) AS comment
|
|
FROM
|
|
(
|
|
SELECT
|
|
v.*, j.id AS job_id,
|
|
IF(vote = 1, 1, 0) AS agree,
|
|
IF(vote = 0, 1, 0) AS abstain,
|
|
IF(vote = -1, 1, 0) AS disagree
|
|
FROM votes v
|
|
JOIN jobs j ON v.type = 1 AND fk_id = j.id
|
|
AND j.job_report_id IS NOT NULL
|
|
GROUP BY j.job_report_id, v.user_id
|
|
) v
|
|
JOIN users u ON v.user_id = u.id
|
|
GROUP BY job_id
|
|
) v ON v.job_id = j.id
|
|
WHERE r.concept = 0
|
|
GROUP BY r.id
|
|
) wr
|
|
ORDER BY `your_votes` asc
|
|
LIMIT 0, 100
|
|
|
|
[query_history:protected] => Array
|
|
(
|
|
)
|
|
|
|
)
|
|
|
|
[db_applied:protected] => Array
|
|
(
|
|
[where] => where
|
|
[select] => select
|
|
[orderby] => orderby
|
|
)
|
|
|
|
[with_applied:protected] => Array
|
|
(
|
|
)
|
|
|
|
[is_in_transaction:protected] =>
|
|
[is_logger_on:protected] => Array
|
|
(
|
|
[add] => 1
|
|
[update] => 1
|
|
[delete] => 1
|
|
)
|
|
|
|
)
|
|
|
|
[load] => Loader Object
|
|
(
|
|
)
|
|
|
|
[uri] => URI Object
|
|
(
|
|
)
|
|
|
|
[input] => Input Object
|
|
(
|
|
[use_xss_clean:protected] =>
|
|
[ip_address] =>
|
|
[user_agent] =>
|
|
)
|
|
|
|
[is_favourite] =>
|
|
)
|
|
|
|
[1] => show_all
|
|
)
|
|
, Array
|
|
(
|
|
[0] => 100
|
|
[1] => your_votes
|
|
[2] => ASC
|
|
[3] => page
|
|
[4] => 1
|
|
)
|
|
)</pre></li>
|
|
<li><pre>Kohana::instance( )</pre></li>
|
|
<li><strong>system/core/Event.php [217]:</strong><pre>call_user_func( Array
|
|
(
|
|
[0] => Kohana
|
|
[1] => instance
|
|
)
|
|
)</pre></li>
|
|
<li><strong>system/core/Bootstrap.php [55]:</strong><pre>Event::run( system.execute )</pre></li>
|
|
<li><strong>index.php [109]:</strong><pre>require( system/core/Bootstrap.php )</pre></li></ul> <p id="stats">Načteno za 0.2130 sekund, použito 4.02MB paměti.</p>
|
|
</div>
|
|
|
|
</body></html>
|