|
|
@@ -105,7 +105,7 @@ class ContractController extends FrontController
|
|
|
->leftJoin('broadcasts as b', 'b.id', '=', 'cd.broadcast_id')
|
|
|
->where('to_m_id', $mId)
|
|
|
->whereIn('cd.status',[1,3])
|
|
|
- ->select(['cd.id', 'db_money', 'nbn_money', 'cd.created_at', 'cd.type', 'cd.status', 'b.hash'])->paginate(15);
|
|
|
+ ->select(['cd.id', 'db_money', 'nbn_money', 'cd.created_at', 'cd.type', 'cd.status', 'b.hash','cd.service_money'])->paginate(15);
|
|
|
return $this->apiResponseSuccess('', ['total' => $list->total(), 'items' => $list->items()]);
|
|
|
}
|
|
|
|
|
|
@@ -115,7 +115,10 @@ class ContractController extends FrontController
|
|
|
*/
|
|
|
function getContractList(){
|
|
|
$mId = MemberServer::creatServer()->getMemberId();
|
|
|
- $list=Contract::where('m_id',$mId)->select(['id','status','hash','money','created_at','is_out'])->paginate(15);
|
|
|
+ $list=Contract::where('m_id',$mId)->select(['id','status','hash','money','created_at','is_out'])->orderBy('id','desc')->paginate(15);
|
|
|
+ foreach ($list as $item){
|
|
|
+ $item->{'statusName'}=__('contract.status'.$item->{'status'});
|
|
|
+ }
|
|
|
return $this->apiResponseSuccess('', ['total' => $list->total(), 'items' => $list->items()]);
|
|
|
}
|
|
|
|