08 2024
This commit is contained in:
parent
04d677d37a
commit
bfa3bb1df4
1191 changed files with 637397 additions and 10619 deletions
|
|
@ -9,6 +9,7 @@ use App\Models\UserCredit;
|
|||
use App\Models\UserPayCredit;
|
||||
use App\Models\UserCreditItem;
|
||||
use App\Http\Controllers\Controller;
|
||||
use Auth;
|
||||
|
||||
class PaymentController extends Controller
|
||||
{
|
||||
|
|
@ -48,7 +49,11 @@ class PaymentController extends Controller
|
|||
$ret = "";
|
||||
if(Credit::isCredit($UserCredit)){
|
||||
$ret .= '<a href="'.route('storage_file', [$UserCredit->id, 'credit', 'download']).'" class="btn btn-primary btn-xs"><i class="fa fa-download"></i></a> ';
|
||||
$ret .= '<a href="'.route('storage_file', [$UserCredit->id, 'credit', 'stream']).'" target="_blank" class="btn btn-warning btn-xs"><i class="fa fa-eye"></i></a>';
|
||||
$ret .= '<a href="'.route('storage_file', [$UserCredit->id, 'credit', 'stream']).'" target="_blank" class="btn btn-warning btn-xs"><i class="fa fa-eye"></i></a><br>';
|
||||
if(Auth::user()->isVIP()){
|
||||
$ret .= '<a href="'.route('storage_file', [$UserCredit->id, 'credit_detail', 'html']).'" target="_blank" class="btn btn-secondary btn-xs mt-2"><i class="fa fa-eye"></i></a> ';
|
||||
$ret .= '<a href="'.route('storage_file', [$UserCredit->id, 'credit_detail', 'pdf']).'" target="_blank" class="btn btn-secondary btn-xs mt-2"><i class="fa fa-file-pdf" style="min-width:13.5px"></i></a> ';
|
||||
}
|
||||
}else{
|
||||
$ret = "-";
|
||||
}
|
||||
|
|
@ -61,7 +66,7 @@ class PaymentController extends Controller
|
|||
$ret = "";
|
||||
if($UserCredit->user_credit_items){
|
||||
foreach($UserCredit->user_credit_items as $user_credit_item){
|
||||
$ret .= nl2br($user_credit_item->message)." / ".$user_credit_item->created_at->format('d.m.Y')."<br>";
|
||||
$ret .= nl2br($user_credit_item->getTransMessage())." / ".$user_credit_item->created_at->format('d.m.Y')."<br>";
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -85,7 +90,7 @@ class PaymentController extends Controller
|
|||
return \DataTables::eloquent($query)
|
||||
|
||||
->addColumn('message', function (UserCreditItem $user_credit_item) {
|
||||
return nl2br($user_credit_item->message);
|
||||
return nl2br($user_credit_item->getTransMessage());
|
||||
})
|
||||
->addColumn('credit', function (UserCreditItem $user_credit_item) {
|
||||
return formatNumber($user_credit_item->credit)." €";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue