first change
This commit is contained in:
0
Modules/Meeting/resources/assets/.gitkeep
Normal file
0
Modules/Meeting/resources/assets/.gitkeep
Normal file
0
Modules/Meeting/resources/assets/js/app.js
Normal file
0
Modules/Meeting/resources/assets/js/app.js
Normal file
0
Modules/Meeting/resources/assets/sass/app.scss
Normal file
0
Modules/Meeting/resources/assets/sass/app.scss
Normal file
0
Modules/Meeting/resources/views/.gitkeep
Normal file
0
Modules/Meeting/resources/views/.gitkeep
Normal file
16
Modules/Meeting/resources/views/events/create.blade.php
Normal file
16
Modules/Meeting/resources/views/events/create.blade.php
Normal file
@@ -0,0 +1,16 @@
|
||||
@extends('layouts.app')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
|
||||
{{ html()->form('POST')->route('event.store')->class(['needs-validation'])->attributes(['novalidate'])->open() }}
|
||||
|
||||
@include('meeting::events.partials.action')
|
||||
|
||||
{{ html()->form()->close() }}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
@@ -0,0 +1,12 @@
|
||||
<div class="hstack flex-wrap gap-3">
|
||||
@can('event.show')
|
||||
<a href="{{ route('event.show', $id) }}" class="link-secondary fs-15"><i class="ri-eye-fill"></i></a>
|
||||
@endcan
|
||||
@can('event.edit')
|
||||
<a href="{{ route('event.edit', $id) }}" class="link-primary fs-15 edit-item-btn"><i class="ri-edit-2-fill"></i></a>
|
||||
@endcan
|
||||
@can('event.destroy')
|
||||
<a href="javascript:void(0);" data-link="{{ route('event.destroy', $id) }}" data-id="{{ $id }}"
|
||||
class="link-danger fs-15 remove-item-btn"><i class="ri-delete-bin-fill"></i></a>
|
||||
@endcan
|
||||
</div>
|
11
Modules/Meeting/resources/views/events/edit.blade.php
Normal file
11
Modules/Meeting/resources/views/events/edit.blade.php
Normal file
@@ -0,0 +1,11 @@
|
||||
@extends('layouts.app')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
{{ html()->modelForm($event, 'PUT')->route('event.update', $event->id)->class(['needs-validation'])->attributes(['novalidate'])->open() }}
|
||||
@include('meeting::events.partials.action')
|
||||
{{ html()->form()->close() }}
|
||||
|
||||
</div>
|
||||
@endsection
|
40
Modules/Meeting/resources/views/events/index.blade.php
Normal file
40
Modules/Meeting/resources/views/events/index.blade.php
Normal file
@@ -0,0 +1,40 @@
|
||||
@extends('layouts.app')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
|
||||
<div class="mb-1 text-end">
|
||||
@can('event.create')
|
||||
<a href="{{ route('event.create') }}" class="btn btn-primary btn-sm waves-effect waves-light"><i
|
||||
class="ri-add-fill me-1 align-bottom"></i> Create</a>
|
||||
@endcan
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
@php
|
||||
$columns = [
|
||||
[
|
||||
'title' => 'SN',
|
||||
'data' => 'DT_RowIndex',
|
||||
'name' => 'DT_RowIndex',
|
||||
'orderable' => false,
|
||||
'searchable' => false,
|
||||
],
|
||||
['title' => 'Title', 'data' => 'title', 'name' => 'title'],
|
||||
['title' => 'Type', 'data' => 'type', 'name' => 'type'],
|
||||
['title' => 'Date', 'data' => 'date', 'name' => 'date'],
|
||||
['title' => 'Location', 'data' => 'location', 'name' => 'location'],
|
||||
['title' => 'Status', 'data' => 'status', 'name' => 'status'],
|
||||
['title' => 'Action', 'data' => 'action', 'orderable' => false, 'searchable' => false],
|
||||
];
|
||||
@endphp
|
||||
|
||||
<x-data-table-script :route="route('event.index')" :columns="$columns" />
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
@@ -0,0 +1,98 @@
|
||||
<div class="row">
|
||||
<div class="col-lg-9">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="row gy-3">
|
||||
<div class="col-md-12">
|
||||
{{ html()->label('Title')->class('form-label') }}
|
||||
{{ html()->text('title')->class('form-control')->placeholder('Event Title')->required() }}
|
||||
{{ html()->div('Please Enter Event Title')->class('invalid-feedback') }}
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
{{ html()->label('Event Type')->class('form-label') }}
|
||||
{{ html()->select('type', config('constants.event_type_options'))->class('form-select select2')->placeholder('Event Type')->required() }}
|
||||
{{ html()->div('Please Choose Type')->class('invalid-feedback') }}
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
{{ html()->label('Location')->class('form-label') }}
|
||||
{{ html()->text('location')->class('form-control')->placeholder('Event Location') }}
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
{{ html()->label('Start Date')->class('form-label') }}
|
||||
<div class="input-group">
|
||||
{{ html()->text('start_date')->class('form-control')->id('event-start-date')->placeholder('Event Start Date')->attributes([
|
||||
'data-provider' => 'flatpickr',
|
||||
'data-date-format' => 'Y-m-d',
|
||||
'data-enable-time' => '',
|
||||
])->required() }}
|
||||
<span class="input-group-text"><i class="ri-calendar-event-line"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
{{ html()->label('End Date')->class('form-label') }}
|
||||
<div class="input-group">
|
||||
{{ html()->text('end_date')->class('form-control')->id('event-end-date')->placeholder('Event End Date')->attributes([
|
||||
'data-provider' => 'flatpickr',
|
||||
'data-date-format' => 'Y-m-d',
|
||||
'data-enable-time' => '',
|
||||
]) }}
|
||||
<span class="input-group-text"><i class="ri-calendar-event-line"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- <div class="col-lg-3 col-md-6">
|
||||
{{ html()->label('Start Time')->class('form-label') }}
|
||||
<div class="input-group">
|
||||
{{ html()->text('start_time')->class('form-control')->placeholder('Event Start Time')->attributes(['data-provider' => 'timepickr', 'data-time-basic' => 'true']) }}
|
||||
<span class="input-group-text"><i class="ri-time-line"></i></span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-6">
|
||||
{{ html()->label('End Time')->class('form-label') }}
|
||||
<div class="input-group">
|
||||
{{ html()->text('end_time')->class('form-control')->placeholder('Event End Time')->attributes(['data-provider' => 'timepickr', 'data-time-basic' => 'true']) }}
|
||||
<span class="input-group-text"><i class="ri-time-line"></i></span>
|
||||
</div>
|
||||
</div> --}}
|
||||
|
||||
<div class="col-lg-12 col-md-12">
|
||||
{{ html()->label('Description')->class('form-label') }}
|
||||
{{ html()->textarea('description')->class('form-control ckeditor-classic') }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-lg-3">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title mb-0">Publish</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="row gy-3">
|
||||
<div class="col-md-12">
|
||||
{{ html()->label('Status')->class('form-label') }}
|
||||
{{ html()->select('status', $status)->class('form-control select2') }}
|
||||
</div>
|
||||
<div class="col-12">
|
||||
<x-form-buttons :editable='$editable' label='Add' href="{{ route('event.index') }}" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end card body -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@push('js')
|
||||
<script src="{{ asset('assets/js/pages/form-validation.init.js') }}"></script>
|
||||
@endpush
|
52
Modules/Meeting/resources/views/events/show.blade.php
Normal file
52
Modules/Meeting/resources/views/events/show.blade.php
Normal file
@@ -0,0 +1,52 @@
|
||||
@extends('layouts.app')
|
||||
@inject('employeeRepository', 'Modules\Employee\Repositories\EmployeeRepository')
|
||||
@use('Carbon\Carbon')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="card card-body p-4">
|
||||
<div>
|
||||
<div class="table-responsive">
|
||||
<table class="table-borderless mb-0 table">
|
||||
<tbody>
|
||||
<tr>
|
||||
<th><span class="fw-medium">Event Title</span></th>
|
||||
<td>{{ $item->title }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<tr>
|
||||
<th><span class="fw-medium">Start Time</span></th>
|
||||
<td>{{ Carbon::parse($item->start_time)->format('h:i A') }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><span class="fw-medium">End Time</span></th>
|
||||
<td>{{ Carbon::parse($item->end_time)->format('h:i A') }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><span class="fw-medium">Location</span></th>
|
||||
<td>{{ $item->location }}</td>
|
||||
</tr>
|
||||
<th><span class="fw-medium">Description</span></th>
|
||||
<td>{!! $item->description !!}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mb-3 text-end">
|
||||
<a href="{{ route('event.index') }}" class="btn btn-secondary w-sm">Back</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('js')
|
||||
<script src="{{ asset('assets/js/pages/form-validation.init.js') }}"></script>
|
||||
@endpush
|
29
Modules/Meeting/resources/views/layouts/master.blade.php
Normal file
29
Modules/Meeting/resources/views/layouts/master.blade.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
|
||||
<title>Meeting Module - {{ config('app.name', 'Laravel') }}</title>
|
||||
|
||||
<meta name="description" content="{{ $description ?? '' }}">
|
||||
<meta name="keywords" content="{{ $keywords ?? '' }}">
|
||||
<meta name="author" content="{{ $author ?? '' }}">
|
||||
|
||||
<!-- Fonts -->
|
||||
<link rel="preconnect" href="https://fonts.bunny.net">
|
||||
<link href="https://fonts.bunny.net/css?family=figtree:400,500,600&display=swap" rel="stylesheet" />
|
||||
|
||||
{{-- Vite CSS --}}
|
||||
{{-- {{ module_vite('build-meeting', 'resources/assets/sass/app.scss') }} --}}
|
||||
</head>
|
||||
|
||||
<body>
|
||||
@yield('content')
|
||||
|
||||
{{-- Vite JS --}}
|
||||
{{-- {{ module_vite('build-meeting', 'resources/assets/js/app.js') }} --}}
|
||||
</body>
|
16
Modules/Meeting/resources/views/meeting/create.blade.php
Normal file
16
Modules/Meeting/resources/views/meeting/create.blade.php
Normal file
@@ -0,0 +1,16 @@
|
||||
@extends('layouts.app')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
|
||||
{{ html()->form('POST')->route('meeting.store')->class(['needs-validation'])->attributes(['novalidate'])->open() }}
|
||||
|
||||
@include('meeting::meeting.partials.action')
|
||||
|
||||
{{ html()->form()->close() }}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
12
Modules/Meeting/resources/views/meeting/edit.blade.php
Normal file
12
Modules/Meeting/resources/views/meeting/edit.blade.php
Normal file
@@ -0,0 +1,12 @@
|
||||
@extends('layouts.app')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
{{ html()->modelForm($meeting, 'PUT')->route('meeting.update', $meeting->id)->class(['needs-validation'])->attributes(['novalidate'])->open() }}
|
||||
@include('meeting::meeting.partials.action')
|
||||
{{ html()->closeModelForm() }}
|
||||
|
||||
</div>
|
||||
|
||||
@endsection
|
95
Modules/Meeting/resources/views/meeting/index.blade.php
Normal file
95
Modules/Meeting/resources/views/meeting/index.blade.php
Normal file
@@ -0,0 +1,95 @@
|
||||
@extends('layouts.app')
|
||||
@inject('employeeRepository', 'Modules\Employee\Repositories\EmployeeRepository')
|
||||
|
||||
@use('Carbon\Carbon')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
|
||||
<div class="mb-1 text-end">
|
||||
@can('meeting.create')
|
||||
<a href="{{ route('meeting.create') }}" class="btn btn-primary waves-effect waves-light"><i
|
||||
class="ri-add-fill me-1 align-bottom"></i> Create</a>
|
||||
@endcan
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body table-layoutt">
|
||||
<table id="datatable" class="display table-sm table-bordered table">
|
||||
<thead class="table-dark">
|
||||
<tr>
|
||||
<th class="tb-col"><span class="overline-title">S.N</span></th>
|
||||
<th class="tb-col"><span class="overline-title">Title</span></th>
|
||||
<th class="tb-col"><span class="overline-title">Date</span></th>
|
||||
<th class="tb-col"><span class="overline-title">Meeting with</span></th>
|
||||
<th class="tb-col"><span class="overline-title"> Team Member</span></th>
|
||||
<th class="tb-col"><span class="overline-title">Location</span></th>
|
||||
<th class="tb-col" data-sortable="false"><span class="overline-title">Action</span>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
@foreach ($meetingLists as $index => $item)
|
||||
<tr>
|
||||
<td class="tb-col">{{ $index + 1 }}</td>
|
||||
<td class="tb-col">{{ $item->title }}</td>
|
||||
<td class="tb-col">{{ $item->date?->format('Y-m-d') }}
|
||||
<br>
|
||||
<span class="text-success fs-12">[{{ Carbon::parse($item->start_time)->format('h:i A') }}</span> -
|
||||
<span class="text-danger fs-12">
|
||||
{{ Carbon::parse($item->end_time)->format('h:i A') }} ]</span>
|
||||
|
||||
</td>
|
||||
<td class="tb-col">{{ $item->meeting_with }}
|
||||
<br>
|
||||
{{ $item->meeting_with == 'client' ? $item->client?->name : '-' }}
|
||||
</td>
|
||||
<td class="tb-col">
|
||||
<div class="avatar-group flex-nowrap">
|
||||
@isset($item->assignedUser)
|
||||
@foreach ($item->assignedUser as $assignedId)
|
||||
<div class="avatar-group-item">
|
||||
<a href="javascript: void(0);" class="d-inline-block" data-bs-toggle="tooltip"
|
||||
data-bs-trigger="hover" data-bs-placement="top" title="{{ $assignedId->full_name }}">
|
||||
<img src="{{ asset($assignedId->profile_pic) }}" alt=""
|
||||
class="rounded-circle avatar-xxs">
|
||||
</a>
|
||||
</div>
|
||||
@endforeach
|
||||
@endisset
|
||||
|
||||
</div>
|
||||
|
||||
{{-- @endif --}}
|
||||
</td>
|
||||
{{-- <td class="tb-col">-</td> --}}
|
||||
<td class="tb-col">{{ $item->location }}</td>
|
||||
<td class="tb-col">
|
||||
<div class="hstack flex-wrap gap-3">
|
||||
@can('meeting.show')
|
||||
<a href="{{ route('meeting.show', $item->id) }}" class="link-secondary fs-15 view-item-btn">
|
||||
<i class="ri-eye-fill"></i>
|
||||
</a>
|
||||
@endcan
|
||||
@can('meeting.edit')
|
||||
<a href="{{ route('meeting.edit', $item->id) }}" class="link-primary fs-15 edit-item-btn"><i
|
||||
class="ri-edit-2-fill"></i></a>
|
||||
@endcan
|
||||
@can('meeting.destroy')
|
||||
<a href="javascript:void(0);" data-link="{{ route('meeting.destroy', $item->id) }}"
|
||||
data-id="{{ $item->id }}" class="link-danger fs-15 remove-item-btn"><i
|
||||
class="ri-delete-bin-fill"></i></a>
|
||||
@endcan
|
||||
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
@@ -0,0 +1,140 @@
|
||||
<div class="row">
|
||||
<div class="col-lg-9">
|
||||
|
||||
<div class="card">
|
||||
|
||||
<div class="card-body">
|
||||
|
||||
<div class="row gy-3">
|
||||
<div class="col-lg-6 col-md-6">
|
||||
{{ html()->label('Title')->class('form-label') }}
|
||||
{{ html()->text('title')->class('form-control')->placeholder('Meeting Title')->required() }}
|
||||
{{ html()->div('Please mention meeting title')->class('invalid-feedback') }}
|
||||
</div>
|
||||
|
||||
<div class="col-lg-6 col-md-6">
|
||||
{{ html()->label('Location')->class('form-label') }}
|
||||
{{ html()->text('location')->class('form-control')->placeholder('Meeting Location')->required() }}
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3 col-md-3">
|
||||
{{ html()->label('Meeting with:')->class('form-label') }}
|
||||
<div class="form-check form-radio-success">
|
||||
{{ html()->radio('meeting_with', false, 'client')->class('form-check-input meeting-with')->checked($editable && $meeting->meeting_with == 'client') }}
|
||||
{{ html()->label('Client')->class('form-check-label me-1')->for('meeting_with_client') }}
|
||||
</div>
|
||||
|
||||
<div class="form-check form-radio-success">
|
||||
{{ html()->radio('meeting_with', false, 'team')->class('form-check-input meeting-with')->checked($editable && $meeting->meeting_with == 'team') }}
|
||||
{{ html()->label('Office Team')->class('form-check-label me-1')->for('meeting_with_team') }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-9 col-md-9 client-dropdown d-none">
|
||||
{{ html()->label('Client')->class('form-label') }}
|
||||
{{ html()->select('client_id', $clientList)->class('form-select select2')->placeholder('Select client')->value($editable ? $meeting->client?->id : null) }}
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-lg-9 col-md-9 team-dropdown d-none">
|
||||
{{ html()->label('Team Member')->class('form-label') }}
|
||||
{{ html()->multiselect('members[ids][]', $employeeList)->class('form-control select2')->value($meeting->members['ids'] ?? null)->attributes(['multiple', 'id' => 'teams']) }}
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-lg-12 col-md-12">
|
||||
{{ html()->label('Description')->class('form-label') }}
|
||||
{{ html()->textarea('description')->class('form-control ckeditor-classic') }}
|
||||
</div>
|
||||
|
||||
<x-form-buttons :editable='$editable' label='Add' href="{{ route('meeting.index') }}" />
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-3">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title mb-0">Publish</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
{{ html()->label('Status')->class('form-label') }}
|
||||
{{ html()->select('status', $status)->class('form-select select2') }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end card body -->
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="card-title mb-0">Date</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="row gy-2">
|
||||
<div class="col-12">
|
||||
<div class="input-group">
|
||||
{{ html()->text('date')->class('form-control flatpickr-date')->value(date('Y-m-d'))->required() }}
|
||||
<span class="input-group-text"><i class="ri-calendar-line"></i></span>
|
||||
{{ html()->div('Event Date is required')->class('invalid-feedback') }}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-12">
|
||||
{{ html()->label('Start Time')->class('form-label') }}
|
||||
<div class="input-group">
|
||||
{{ html()->time('start_time')->value(date('h:i'))->class('form-control') }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-12">
|
||||
{{ html()->label('End Time')->class('form-label') }}
|
||||
<div class="input-group">
|
||||
{{ html()->time('end_time')->class('form-control') }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end card body -->
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@push('js')
|
||||
<script src="{{ asset('assets/js/pages/form-validation.init.js') }}"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
// Trigger the change event on page load to set initial visibility
|
||||
$('.meeting-with').trigger('change');
|
||||
|
||||
// Check the initial state and show/hide dropdowns accordingly
|
||||
const selectedValue = $('.meeting-with:checked').val();
|
||||
if (selectedValue === 'team') {
|
||||
$('.team-dropdown').removeClass('d-none');
|
||||
$('.client-dropdown').addClass('d-none');
|
||||
} else if (selectedValue === 'client') {
|
||||
$('.client-dropdown').removeClass('d-none');
|
||||
$('.team-dropdown').addClass('d-none');
|
||||
}
|
||||
|
||||
// Change event for radio buttons
|
||||
$('.meeting-with').change(function() {
|
||||
let value = $(this).val();
|
||||
if (value === 'team') {
|
||||
$('.team-dropdown').removeClass('d-none');
|
||||
$('.client-dropdown').addClass('d-none');
|
||||
} else if (value === 'client') {
|
||||
$('.client-dropdown').removeClass('d-none');
|
||||
$('.team-dropdown').addClass('d-none');
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@endpush
|
246
Modules/Meeting/resources/views/meeting/show.blade.php
Normal file
246
Modules/Meeting/resources/views/meeting/show.blade.php
Normal file
@@ -0,0 +1,246 @@
|
||||
@extends('layouts.app')
|
||||
@inject('employeeRepository', 'Modules\Employee\Repositories\EmployeeRepository')
|
||||
@use('Carbon\Carbon')
|
||||
@section('content')
|
||||
<div class="container-fluid">
|
||||
<x-dashboard.breadcumb :title="$title" />
|
||||
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="card card-body">
|
||||
<div class="col-md">
|
||||
<h4 class="fw-bold">{{ $item->title }}</h4>
|
||||
<div class="hstack flex-wrap gap-3">
|
||||
<div><i class="ri-building-line me-1 align-bottom"></i> {{ $item->location }}</div>
|
||||
<div class="vr"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="border-top border-top-dashed mt-4 pt-3">
|
||||
<div class="row gy-2">
|
||||
<div class="col-lg-2 col-sm-4">
|
||||
<div>
|
||||
<p class="text-uppercase fw-medium mb-2">Date :</p>
|
||||
<h5 class="fs-15 mb-0">
|
||||
{{ $item->date }}
|
||||
</h5>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-2 col-sm-4">
|
||||
<div>
|
||||
<p class="text-uppercase fw-medium mb-2">Start Time :</p>
|
||||
<h5 class="fs-15 mb-0">{{ Carbon::parse($item->start_time)->format('h:i A') }}</h5>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-2 col-sm-4">
|
||||
<div>
|
||||
<p class="text-uppercase fw-medium mb-2">End Time:</p>
|
||||
<h5 class="fs-15 mb-0">{{ Carbon::parse($item->end_time)->format('h:i A') }}</h5>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-2 col-sm-4">
|
||||
<div>
|
||||
<p class="text-uppercase fw-medium mb-2">Type:</p>
|
||||
<span class="fs-15 badge bg-primary mb-0">{{ $item->meeting_with }}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-2 col-sm-4">
|
||||
<div>
|
||||
<p class="text-uppercase fw-medium mb-2">Client:</p>
|
||||
<h5 class="fs-15 mb-0">{{ @$item->client?->client_name }}</h5>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-9">
|
||||
<div class="card card-body">
|
||||
<div class="text-muted">
|
||||
<h6 class="fw-semibold text-uppercase mb-3">Description</h6>
|
||||
{!! Str::limit($item->description, 666) !!}
|
||||
@if (strlen($item->description) > 666)
|
||||
<div id="description-full" style="display: none;">
|
||||
{!! $item->description !!}
|
||||
</div>
|
||||
<a href="javascript:void(0);" id="see-more-btn" class="text-primary">See More</a>
|
||||
<a href="javascript:void(0);" id="see-less-btn" class="text-primary"
|
||||
style="display: none;">See
|
||||
Less</a>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">Meeting Minute List</h5>
|
||||
@foreach ($minutes as $minute)
|
||||
<div class="simplebar-scrollable-y py-3" data-simplebar style="max-height: 400px;">
|
||||
<div class="acitivity-timeline">
|
||||
<div class="acitivity-item d-flex py-2">
|
||||
<div class="avatar-xs acitivity-avatar flex-shrink-0">
|
||||
<div class="avatar-title bg-primary-subtle text-primary rounded-circle">
|
||||
{{ substr($minute->agenda, 0, 1) }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex-grow-1 ms-3">
|
||||
<h6 class="mb-1">{{ $minute->agenda }}</h6>
|
||||
<p class="text-muted mb-0">{!! $minute->description !!}</p>
|
||||
</div>
|
||||
<div class="d-flex flex-column ms-3 flex-shrink-0">
|
||||
<div class="avatar-group flex-nowrap">
|
||||
@isset($minute->assignedUser)
|
||||
@foreach ($minute->assignedUser as $assignedId)
|
||||
<div class="avatar-group-item">
|
||||
<a href="javascript: void(0);" class="d-inline-block"
|
||||
data-bs-toggle="tooltip" data-bs-trigger="hover"
|
||||
data-bs-placement="top" title="{{ $assignedId->full_name }}">
|
||||
<img src="{{ asset($assignedId->profile_pic) }}" alt=""
|
||||
class="rounded-circle avatar-xxs">
|
||||
</a>
|
||||
</div>
|
||||
@endforeach
|
||||
@endisset
|
||||
</div>
|
||||
<small class="text-primary mb-2">{{ $minute->created_at?->format('d M, Y') }}</small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
<!--end card-body-->
|
||||
</div>
|
||||
|
||||
<div class="card card-body">
|
||||
<h6 class="fw-semibold text-uppercase mb-3">Meeting Minute</h6>
|
||||
|
||||
{{ html()->form('POST')->route('meeting.storeSubTask')->class(['needs-validation'])->attributes(['novalidate', 'enctype' => 'multipart/form-data'])->open() }}
|
||||
{{ html()->hidden('meeting_id', $item->id) }}
|
||||
<div class="row gy-1">
|
||||
<div class="col-md-12">
|
||||
{{ html()->label('Agenda')->class('form-label') }}
|
||||
{{ html()->textarea('agenda')->class('form-control')->placeholder('Enter Agenda')->required() }}
|
||||
{{ html()->div('Please enter agenda')->class('invalid-feedback') }}
|
||||
</div>
|
||||
|
||||
<div class="col-md-12">
|
||||
{{ html()->label('Attendees')->class('form-label') }}
|
||||
{{ html()->multiselect('attendees[ids][]', $employeeList)->class('form-control select2')->value($item->members['ids'] ?? null)->attributes(['multiple', 'id' => 'teams']) }}
|
||||
{{ html()->div('Please enter attendees')->class('invalid-feedback') }}
|
||||
</div>
|
||||
|
||||
<div class="col-md-12">
|
||||
{{ html()->label('Description')->class('form-label') }}
|
||||
{{ html()->textarea('description')->class('form-control ckeditor-classic')->placeholder('..') }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="mt-3 text-end">
|
||||
<button type="submit" class="btn btn-success w-sm">Save</button>
|
||||
|
||||
</div>
|
||||
{{ html()->form()->close() }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<div class="list-group mb-2">
|
||||
<li class="list-group-item active">Action</li>
|
||||
|
||||
<a href="{{ route('meeting.sendmail', $item->id) }}" class="list-group-item list-group-item-action"
|
||||
data-bs-toggle="modal" data-bs-target="#emailModal"><i
|
||||
class="ri-mail-fill text-danger me-2 align-middle"></i>Send Email</a>
|
||||
<a href="{{ route('meeting.edit', $item->id) }}" class="list-group-item list-group-item-action"><i
|
||||
class="ri-pencil-fill text-primary me-2 align-middle"></i>Edit</a>
|
||||
<a href="{{ route('meeting.index') }}" class="list-group-item list-group-item-action"><i
|
||||
class="ri-user-add-fill text-secondary me-2 align-middle"></i>Back</a>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<div class="d-flex mb-3">
|
||||
<h6 class="card-title flex-grow-1 mb-0">Team Members</h6>
|
||||
</div>
|
||||
<ul class="list-unstyled vstack mb-0 gap-3">
|
||||
@foreach ($item->assignedUser as $assignedUser)
|
||||
<li>
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="flex-shrink-0">
|
||||
<img src="{{ $assignedUser->profile_pic }}" alt=""
|
||||
class="avatar-xs rounded-circle material-shadow">
|
||||
</div>
|
||||
<div class="flex-grow-1 ms-2">
|
||||
<h6 class="mb-1"><a href="#">{{ $assignedUser->full_name }}</a>
|
||||
</h6>
|
||||
<p class="text-muted mb-0">{{ $assignedUser->email }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
@endforeach
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('js')
|
||||
<script src="{{ asset('assets/js/pages/form-validation.init.js') }}"></script>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
|
||||
$('#see-less-btn').hide();
|
||||
|
||||
$('#see-more-btn').on('click', function() {
|
||||
$('#description-preview').hide();
|
||||
$('#description-full').show();
|
||||
$(this).hide();
|
||||
$('#see-less-btn').show();
|
||||
});
|
||||
|
||||
$('#see-less-btn').on('click', function() {
|
||||
$('#description-full').hide();
|
||||
$('#description-preview').show();
|
||||
$(this).hide();
|
||||
$('#see-more-btn').show();
|
||||
});
|
||||
|
||||
$('#send-email-btn').on('click', function(e) {
|
||||
e.preventDefault();
|
||||
const $btn = $(this);
|
||||
const url = $btn.attr('href');
|
||||
|
||||
$btn.prop('disabled', true).text('Sending mail...');
|
||||
|
||||
$.ajax({
|
||||
url: url,
|
||||
method: 'GET',
|
||||
success: function(response) {
|
||||
alert(response.message || 'Email sent successfully!');
|
||||
},
|
||||
error: function(xhr, status, error) {
|
||||
const errorMsg = xhr.responseJSON?.error ||
|
||||
'Failed to send email. Please try again.';
|
||||
alert(errorMsg);
|
||||
},
|
||||
complete: function() {
|
||||
$btn.prop('disabled', false).text('Send Email');
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
</script>
|
||||
@endpush
|
Reference in New Issue
Block a user