105 lines
4.9 KiB
PHP
105 lines
4.9 KiB
PHP
<div class="modal-dialog modal-lg" role="document">
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
|
<h4 class="modal-title">
|
|
<i class="fas fa-phone"></i> {{ $phone->mobile_number }}
|
|
@if(!empty($phone->contact_name)) — {{ $phone->contact_name }} @endif
|
|
</h4>
|
|
</div>
|
|
<div class="modal-body">
|
|
<div class="row">
|
|
<div class="col-md-6">
|
|
<p><strong>@lang('sale.status'):</strong> {{ $statuses[$phone->status] ?? $phone->status }}</p>
|
|
<p><strong>@lang('crm::lang.follow_up_count'):</strong> {{ $phone->follow_up_count }}</p>
|
|
</div>
|
|
<div class="col-md-6">
|
|
<p><strong>@lang('crm::lang.assgined'):</strong> {{ $phone->assignedUser?->user_full_name ?? '-' }}</p>
|
|
@if(!empty($phone->last_follow_up_at))
|
|
<p><strong>@lang('crm::lang.last_follow_up'):</strong> @format_datetime($phone->last_follow_up_at)</p>
|
|
@endif
|
|
</div>
|
|
</div>
|
|
@if(!empty($phone->notes))
|
|
<p><strong>@lang('crm::lang.description'):</strong> {{ $phone->notes }}</p>
|
|
@endif
|
|
@if(!empty($phone->lead_id))
|
|
<p>
|
|
<a href="{{ action([\Modules\Crm\Http\Controllers\LeadController::class, 'show'], ['lead' => $phone->lead_id]) }}" class="btn btn-sm btn-success">
|
|
<i class="fas fa-user-tag"></i> @lang('crm::lang.view_lead')
|
|
</a>
|
|
</p>
|
|
@endif
|
|
|
|
<hr>
|
|
<h4>@lang('crm::lang.follow_up_history')</h4>
|
|
@if($phone->logs->count() > 0)
|
|
<table class="table table-bordered table-striped">
|
|
<thead>
|
|
<tr>
|
|
<th>@lang('lang_v1.date')</th>
|
|
<th>@lang('sale.status')</th>
|
|
<th>@lang('crm::lang.description')</th>
|
|
<th>@lang('business.created_by')</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach($phone->logs as $log)
|
|
<tr>
|
|
<td>@format_datetime($log->created_at)</td>
|
|
<td>{{ $statuses[$log->status] ?? $log->status }}
|
|
@if(!empty($log->is_auto))
|
|
<span class="label label-default">@lang('crm::lang.auto')</span>
|
|
@endif
|
|
</td>
|
|
<td>{{ $log->note }}</td>
|
|
<td>{{ $log->createdBy?->user_full_name }}</td>
|
|
</tr>
|
|
@endforeach
|
|
</tbody>
|
|
</table>
|
|
@else
|
|
<p class="text-muted">@lang('crm::lang.no_log_found')</p>
|
|
@endif
|
|
|
|
@if(config('constants.enable_crm_call_log'))
|
|
<hr>
|
|
<h4><i class="fas fa-phone-alt"></i> @lang('crm::lang.mobile_call_logs')</h4>
|
|
@if(isset($call_logs) && $call_logs->count() > 0)
|
|
<table class="table table-bordered table-striped">
|
|
<thead>
|
|
<tr>
|
|
<th>@lang('restaurant.start_time')</th>
|
|
<th>@lang('restaurant.end_time')</th>
|
|
<th>@lang('crm::lang.call_duration')</th>
|
|
<th>@lang('crm::lang.call_type')</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach($call_logs as $call_log)
|
|
<tr>
|
|
<td>@format_datetime($call_log->start_time)</td>
|
|
<td>@format_datetime($call_log->end_time)</td>
|
|
<td>
|
|
@if(!empty($call_log->duration))
|
|
{{ \Carbon\CarbonInterval::seconds($call_log->duration)->cascade()->forHumans() }}
|
|
@else
|
|
-
|
|
@endif
|
|
</td>
|
|
<td>{{ $call_log->call_type }}</td>
|
|
</tr>
|
|
@endforeach
|
|
</tbody>
|
|
</table>
|
|
@else
|
|
<p class="text-muted">@lang('crm::lang.no_mobile_call_logs')</p>
|
|
@endif
|
|
@endif
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-default" data-dismiss="modal">@lang('messages.close')</button>
|
|
</div>
|
|
</div>
|
|
</div>
|