作者 anyv
1 个管道 的构建 通过 耗费 0 秒

54

@@ -120,6 +120,7 @@ class PayController extends HomeBaseController @@ -120,6 +120,7 @@ class PayController extends HomeBaseController
120 $data_money_income_salesman['book_thumbnail'] = $val['thumbnail']; 120 $data_money_income_salesman['book_thumbnail'] = $val['thumbnail'];
121 $data_money_income_salesman['book_num'] = $val['number']; 121 $data_money_income_salesman['book_num'] = $val['number'];
122 $data_money_income_salesman['uid'] = $salesman['uid']; 122 $data_money_income_salesman['uid'] = $salesman['uid'];
  123 + $data_money_income_salesman['indent_id'] = $order['id'];
123 Db::name('money_income') -> insert($data_money_income_salesman); 124 Db::name('money_income') -> insert($data_money_income_salesman);
124 } 125 }
125 Db::name('my_user') -> where('uid',$salesman['uid']) -> setInc('balance',$money_salesman); 126 Db::name('my_user') -> where('uid',$salesman['uid']) -> setInc('balance',$money_salesman);
@@ -134,6 +135,7 @@ class PayController extends HomeBaseController @@ -134,6 +135,7 @@ class PayController extends HomeBaseController
134 $data_money_income_teacher['book_thumbnail'] = $val['thumbnail']; 135 $data_money_income_teacher['book_thumbnail'] = $val['thumbnail'];
135 $data_money_income_teacher['book_num'] = $val['number']; 136 $data_money_income_teacher['book_num'] = $val['number'];
136 $data_money_income_teacher['uid'] = $teacher['uid']; 137 $data_money_income_teacher['uid'] = $teacher['uid'];
  138 + $data_money_income_teacher['indent_id'] = $order['id'];
137 Db::name('money_income') -> insert($data_money_income_teacher); 139 Db::name('money_income') -> insert($data_money_income_teacher);
138 } 140 }
139 Db::name('my_user') -> where('uid',$teacher['uid']) -> setInc('balance',$money_teacher); 141 Db::name('my_user') -> where('uid',$teacher['uid']) -> setInc('balance',$money_teacher);
@@ -158,6 +160,7 @@ class PayController extends HomeBaseController @@ -158,6 +160,7 @@ class PayController extends HomeBaseController
158 $data_money_income_salesman['book_thumbnail'] = $val['thumbnail']; 160 $data_money_income_salesman['book_thumbnail'] = $val['thumbnail'];
159 $data_money_income_salesman['book_num'] = $val['number']; 161 $data_money_income_salesman['book_num'] = $val['number'];
160 $data_money_income_salesman['uid'] = $salesman['uid']; 162 $data_money_income_salesman['uid'] = $salesman['uid'];
  163 + $data_money_income_salesman['indent_id'] = $order['id'];
161 Db::name('money_income') -> insert($data_money_income_salesman); 164 Db::name('money_income') -> insert($data_money_income_salesman);
162 } 165 }
163 Db::name('my_user') -> where('uid',$salesman['uid']) -> setInc('balance',$money_salesman); 166 Db::name('my_user') -> where('uid',$salesman['uid']) -> setInc('balance',$money_salesman);
@@ -171,6 +174,7 @@ class PayController extends HomeBaseController @@ -171,6 +174,7 @@ class PayController extends HomeBaseController
171 $data_money_income_teacher['book_thumbnail'] = $val['thumbnail']; 174 $data_money_income_teacher['book_thumbnail'] = $val['thumbnail'];
172 $data_money_income_teacher['book_num'] = $val['number']; 175 $data_money_income_teacher['book_num'] = $val['number'];
173 $data_money_income_teacher['uid'] = $data_user['uid']; 176 $data_money_income_teacher['uid'] = $data_user['uid'];
  177 + $data_money_income_teacher['indent_id'] = $order['id'];
174 Db::name('money_income') -> insert($data_money_income_teacher); 178 Db::name('money_income') -> insert($data_money_income_teacher);
175 } 179 }
176 Db::name('my_user') -> where('uid',$data_user['uid']) -> setInc('balance',$money_teacher); 180 Db::name('my_user') -> where('uid',$data_user['uid']) -> setInc('balance',$money_teacher);
@@ -198,6 +202,7 @@ class PayController extends HomeBaseController @@ -198,6 +202,7 @@ class PayController extends HomeBaseController
198 $money_income_teacher['book_thumbnail'] = $val['thumbnail']; 202 $money_income_teacher['book_thumbnail'] = $val['thumbnail'];
199 $money_income_teacher['book_num'] = $val['number']; 203 $money_income_teacher['book_num'] = $val['number'];
200 $money_income_teacher['uid'] = $teacher['uid']; 204 $money_income_teacher['uid'] = $teacher['uid'];
  205 + $money_income_teacher['indent_id'] = $order['id'];
201 Db::name('money_income') -> insert($money_income_teacher); 206 Db::name('money_income') -> insert($money_income_teacher);
202 } 207 }
203 //增加老师余额 208 //增加老师余额
@@ -228,6 +233,7 @@ class PayController extends HomeBaseController @@ -228,6 +233,7 @@ class PayController extends HomeBaseController
228 $money_income_teacher['book_thumbnail'] = $val['thumbnail']; 233 $money_income_teacher['book_thumbnail'] = $val['thumbnail'];
229 $money_income_teacher['book_num'] = $val['number']; 234 $money_income_teacher['book_num'] = $val['number'];
230 $money_income_teacher['uid'] = $teacher; 235 $money_income_teacher['uid'] = $teacher;
  236 + $money_income_teacher['indent_id'] = $order['id'];
231 Db::name('money_income') -> insert($money_income_teacher); 237 Db::name('money_income') -> insert($money_income_teacher);
232 } 238 }
233 //增加老师余额 239 //增加老师余额
@@ -413,8 +413,11 @@ class PersonalcenterController extends WeChatBaseController{ @@ -413,8 +413,11 @@ class PersonalcenterController extends WeChatBaseController{
413 $student_user = Db::name('my_user') -> where('pid',$my_user['id']) -> select(); 413 $student_user = Db::name('my_user') -> where('pid',$my_user['id']) -> select();
414 foreach ($student_user as $key => $val){ 414 foreach ($student_user as $key => $val){
415 $indent[] = Db::name('indent') -> where('uid',$val['uid']) -> select(); 415 $indent[] = Db::name('indent') -> where('uid',$val['uid']) -> select();
  416 + foreach ($indent as $key => $val){
  417 + /*$indent[$key]['indent_goods'] = Db::name() -> where() -> */
  418 + }
416 } 419 }
417 - dump($indent);die; 420 +
418 421
419 }elseif ($my_user['status'] == 2){ 422 }elseif ($my_user['status'] == 2){
420 423