* finish task #7313.

This commit is contained in:
wangyidong
2019-02-13 17:27:58 +08:00
parent 7481bb097c
commit 10418ad027
2 changed files with 13 additions and 1 deletions
+12
View File
@@ -622,6 +622,18 @@ class productModel extends model
$roadmap = array();
$total = 0;
$parents = array();
foreach($plans as $planID => $plan)
{
if($plan->parent == '-1')
{
$parents[$planID] = $plan->title;
unset($plans[$planID]);
}
if($plan->parent > 0 and isset($parents[$plan->parent])) $plan->title = $parents[$plan->parent] . ' / ' . $plan->title;
}
foreach($plans as $plan)
{
if(($plan->end != '0000-00-00' and strtotime($plan->end) - time() <= 0) or $plan->end == '2030-01-01') continue;
+1 -1
View File
@@ -68,7 +68,7 @@
<?php echo html::submitButton();?>
<?php echo html::backButton();?>
<?php echo html::hidden('product', $product->id);?>
<?php echo html::hidden('branch', $parent ? $parentPlan->branch : $branch);?>
<?php if($parent) echo html::hidden('branch', $parentPlan->branch);?>
<?php echo html::hidden('parent', $parent);?>
</td>
</tr>