|
@@ -541,7 +541,7 @@ class Order
|
|
|
),
|
|
|
);
|
|
|
|
|
|
- $button = $this->show_button($process, $info, $role);
|
|
|
+ $button = $this->show_button($process, $info, $role, $parent_member);
|
|
|
|
|
|
if (($info['status'] == 3 || $info['status'] == 4) && $info['agent_cash'] > 0) {
|
|
|
|
|
@@ -572,7 +572,7 @@ class Order
|
|
|
return $html;
|
|
|
}
|
|
|
|
|
|
- private function show_button($process, $info, $role)
|
|
|
+ private function show_button($process, $info, $role, $parent_member)
|
|
|
{
|
|
|
$button = array();
|
|
|
$cstatus = ',cstatus,soft_price';
|
|
@@ -638,12 +638,33 @@ class Order
|
|
|
if (isset($process[1]) && $process[1]) {
|
|
|
$purl .= '&where_id=' . $process[1]['id'];
|
|
|
}
|
|
|
- $button[] = array
|
|
|
- (
|
|
|
- 'type' => 'edit',
|
|
|
- 'link' => $purl,
|
|
|
- 'name' => '业务初审',
|
|
|
- );
|
|
|
+
|
|
|
+ if ($parent_member) {
|
|
|
+ if ($parent_member['status'] == 2) {
|
|
|
+ $button[] = array
|
|
|
+ (
|
|
|
+ 'type' => 'edit',
|
|
|
+ 'link' => $purl,
|
|
|
+ 'name' => '业务初审',
|
|
|
+ );
|
|
|
+ } else {
|
|
|
+ $button[] = array
|
|
|
+ (
|
|
|
+ 'type' => 'click',
|
|
|
+ 'content' => 'showCs()',
|
|
|
+ 'name' => '业务初审<script>function showCs(){layer.msg("直属上级未认证,无法进行初审")}</script>'
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ } else {
|
|
|
+ $button[] = array
|
|
|
+ (
|
|
|
+ 'type' => 'edit',
|
|
|
+ 'link' => $purl,
|
|
|
+ 'name' => '业务初审',
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
} elseif ($info['status'] == 2) {
|
|
|
|
|
|
$purl = Dever::url('project/database/update?project=agent&table=order_process&order_id='.$info['id'].'&status=2&col=order_id,status,audit,desc', 'manage');
|