initial commit
This commit is contained in:
104
resources/views/partials/topbar.blade.php
Normal file
104
resources/views/partials/topbar.blade.php
Normal file
@@ -0,0 +1,104 @@
|
||||
|
||||
<style>
|
||||
.modal-style{
|
||||
padding-left: 10px;padding-right: 10px;font-size: 15px
|
||||
}
|
||||
.badge {
|
||||
position: relative;
|
||||
top: -15px;
|
||||
left: -25px;
|
||||
border: 1px solid red;
|
||||
border-radius: 50%;
|
||||
background-color: red;
|
||||
}
|
||||
</style>
|
||||
|
||||
@php
|
||||
$user_image_path = getSession('user_image');
|
||||
$profile_image = getSession('profile_image');
|
||||
$max_file_size= $file = config('constant.MAX_FILE_SIZE');
|
||||
@endphp
|
||||
|
||||
<!-- top navigation -->
|
||||
<div class="top_nav">
|
||||
<div class="nav_menu">
|
||||
<nav>
|
||||
<div class="nav toggle">
|
||||
<a id="menu_toggle"><i class="fa fa-bars"></i></a>
|
||||
</div>
|
||||
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li class="nav-item">
|
||||
<a href="javascript:;" class="user-profile dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
|
||||
@if(empty($profile_image))
|
||||
<img src="{{ asset('images/user.png') }}" alt="profile picture">
|
||||
@else
|
||||
<img src="{{getPublicFile($user_image_path)}}" alt="profile picture">
|
||||
@endif{{ Auth::user()->first_name }} {{ Auth::user()->last_name }}
|
||||
<span class=" fa fa-angle-down"></span>
|
||||
</a>
|
||||
<ul class="dropdown-menu dropdown-usermenu pull-right">
|
||||
|
||||
<li><a onclick="modalView('PROFILE_IMAGE_MODAL_VIEW','profile_pic_modal')" > Profile</a></li>
|
||||
<li><a onclick="modalView('SUPPORT_MODAL_VIEW','support_modal')" > Technical Support </a></li>
|
||||
<li><a href="{{config('constant.TECHNICAL_SUPPORT')}}" target="_blank"> Help Mailing Letter</a></li>
|
||||
|
||||
@if(Auth::user()->subscription_status == config('constant.SUBSCRIPTION_STATUS.SUBSCRIBED'))
|
||||
<li><a href="#" onclick="subscription()"> {{'Cancel Account'}}</a></li>
|
||||
@endif
|
||||
<li>
|
||||
<form method="post" action="{{ route('user.logout') }}">
|
||||
{{ csrf_field() }}
|
||||
<button type="submit" style="background-color: #fff; border: none;margin-top: 10px; margin-left:13px; color: #5A738E;" data-toggle="tooltip" data-placement="top" title="Logout">Log Out <i class="fa fa-sign-out pull-right" style="margin-right: 15px;"></i></button>
|
||||
</form>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
@include('partials.video_setting')
|
||||
@include('partials.supportsubmenu')
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
@include('partials.smart_credit_status')
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div id="modal_target"></div>
|
||||
<!-- /top navigation -->
|
||||
{{--@include('partials.payment_setting')--}}
|
||||
@push('script')
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
const modalView = (type,targetModal) => {
|
||||
common_helper.globalAjaxRequestAsync('{{route('show.modal')}}','POST',{ type: type,targetModal:targetModal },modalviewcallback);
|
||||
|
||||
}
|
||||
|
||||
const commonModalView = (type,targetModal,message) => {
|
||||
let data = { type: type,targetModal:targetModal,message: message};
|
||||
common_helper.globalAjaxRequestAsync('{{route('show.modal')}}','POST',data,modalviewcallback);
|
||||
|
||||
}
|
||||
|
||||
const submitSubscription = ()=>{
|
||||
common_helper.globalAjaxRequestAsync('{{route('process.ajax')}}','POST',{action:'SUBSCRIPTION_SMART_CREDIT',id:null, _token:"{{ csrf_token() }}"},subscriptioncallbackfunction);
|
||||
}
|
||||
|
||||
|
||||
const subscriptioncallbackfunction = (result)=>{
|
||||
if(result.status)
|
||||
{
|
||||
$('#confirmation_modal_subscription').modal('hide');
|
||||
Swal.fire({icon: result.type,title: result.message,width: 450,timer: 5000});
|
||||
window.location.href='{{route('manage.clients')}}';
|
||||
}else{
|
||||
$('#confirmation_modal_subscription').modal('hide');
|
||||
Swal.fire({icon: result.type,title: result.message,width: 450,timer: 5000});
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
<script src="{{asset('/')}}js/topbar/topbar.js"></script>
|
||||
@endpush
|
||||
Reference in New Issue
Block a user