mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange.git
synced 2026-08-19 04:14:04 +00:00
fix some error in notification frontend
This commit is contained in:
@@ -20,7 +20,6 @@ use DateTime;
|
|||||||
|
|
||||||
class BookingController extends Controller
|
class BookingController extends Controller
|
||||||
{
|
{
|
||||||
|
|
||||||
public function index(){
|
public function index(){
|
||||||
$user = Auth::user();
|
$user = Auth::user();
|
||||||
$bookings = Booking::select('user_id', 'id', 'created_at', 'status', 'rate', 'term', 'amount', 'bia', 'verification_status')
|
$bookings = Booking::select('user_id', 'id', 'created_at', 'status', 'rate', 'term', 'amount', 'bia', 'verification_status')
|
||||||
|
|||||||
@@ -25,6 +25,6 @@ class UserController extends Controller
|
|||||||
public function notifications()
|
public function notifications()
|
||||||
{
|
{
|
||||||
$notifications = auth()->user()->unreadNotifications()->limit(5)->get();
|
$notifications = auth()->user()->unreadNotifications()->limit(5)->get();
|
||||||
return response()->json(['notifications'=>$notifications], 200);
|
return response()->json(['notifications'=> $notifications], 200);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,23 +13,24 @@
|
|||||||
<el-dropdown-menu slot="dropdown">
|
<el-dropdown-menu slot="dropdown">
|
||||||
<div id="notification">
|
<div id="notification">
|
||||||
<div v-if="notifications">
|
<div v-if="notifications">
|
||||||
<div v-for="(idx,item) in notifications" :key="idx">
|
<div v-for="(idx,item) in notifications" :key="idx.id">
|
||||||
<a v-on:click.prevent='navigateTo(item.data.link)'>
|
|
||||||
<el-dropdown-item>
|
<el-dropdown-item>
|
||||||
<!-- <b v-if="item.is_read == 0">
|
<a v-on:click.prevent='navigateTo(item.data.link)'>
|
||||||
{{item.detail}}
|
<!-- <b v-if="item.is_read == 0">
|
||||||
asd
|
{{item.detail}}
|
||||||
</b> -->
|
asd
|
||||||
<span >
|
</b> -->
|
||||||
{{item.data.details}}
|
<span >
|
||||||
|
{{item.data.details}}
|
||||||
</span>
|
|
||||||
<br/>
|
</span>
|
||||||
<span class="opacity80">
|
<br/>
|
||||||
<timeago :datetime="item.created_at"></timeago>
|
<span class="opacity80">
|
||||||
</span>
|
<timeago :datetime="item.created_at"></timeago>
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
</el-dropdown-item>
|
</el-dropdown-item>
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user