Merge branch 'feature/platfrom_aggregate_finance' of wmtx/platform into release

优化合同期限查询
master
廖金灵 5 years ago committed by Gogs
commit 5d809ae9b8

@ -44,10 +44,10 @@ class PartnerController extends ThinkController
if (isset($_REQUEST['timestart']) && isset($_REQUEST['timeend'])) {
$time_start = strtotime($_REQUEST['timestart']);
$time_end = strtotime($_REQUEST['timeend'])+ 86399;
$map["_string"] = "(contract_start_time BETWEEN {$time_start} AND {$time_end}) OR (contract_end_time BETWEEN {$time_start} AND {$time_end})";
$map["_string"] = "(contract_start_time BETWEEN {$time_start} AND {$time_end}) OR (contract_end_time BETWEEN {$time_start} AND {$time_end}) OR (contract_start_time <= {$time_end} AND contract_end_time >= {$time_end}) OR (contract_start_time >0 AND contract_end_time = 0)";
} elseif (isset($_REQUEST['timestart'])) {
$time_start = strtotime($_REQUEST['timestart']);
$map["_string"] = "(contract_start_time >= {$time_start} ) OR (contract_end_time >= {$time_start})";
$map["_string"] = "(contract_start_time >= {$time_start} ) OR (contract_end_time >= {$time_start}) OR ( contract_start_time >0 AND contract_end_time = 0)";
} elseif (isset($_REQUEST['timeend'])) {
$time_end = strtotime($_REQUEST['timeend'])+ 86399;
$map["_string"] = "(contract_start_time <= {$time_end} ) OR (contract_end_time <= {$time_end})";

@ -302,14 +302,14 @@
</tr>
<if condition="$game['row'] gt 1">
<foreach name="game['turnover_ratio']" item="game_ratio" key="gamekey">
<if condition="$gamekey gt 0">
<foreach name="game['turnover_ratio']" item="game_ratio2" key="gamekey2">
<if condition="$gamekey2 gt 0">
<tr>
<td>{$game['name']|default="--"}</td>
<td>{$game['ratio']|showPercent}</td>
<td>{$game_ratio2['name']|default="--"}</td>
<td>{$game_ratio2['ratio']|showPercent}</td>
<td>{$game['cp_ratio'][$gamekey]['name']|default="--"}</td>
<td>{$game['cp_ratio'][$gamekey]['ratio']|showPercent}</td>
<td>{$game['cp_ratio'][$gamekey2]['name']|default="--"}</td>
<td>{$game['cp_ratio'][$gamekey2]['ratio']|showPercent}</td>
</tr>
</if>
</foreach>

@ -334,11 +334,11 @@
</tr>
<if condition="$game['row'] gt 1">
<foreach name="game['turnover_ratio']" item="game_ratio" key="gamekey">
<if condition="$gamekey gt 0">
<foreach name="game['turnover_ratio']" item="game_ratio2" key="gamekey2">
<if condition="$gamekey2 gt 0">
<tr>
<td>{$game['name']|default="--"}</td>
<td>{$game['ratio']|showPercent}</td>
<td>{$game_ratio2['name']|default="--"}</td>
<td>{$game_ratio2['ratio']|showPercent}</td>
</tr>
</if>
</foreach>

Loading…
Cancel
Save