Browse Source

bug responsive

Roberto Santini 3 years ago
parent
commit
7b1ef80e19
2 changed files with 44 additions and 21 deletions
  1. 3
    1
      app/DataTables/IssueDataTable.php
  2. 41
    20
      resources/views/layouts/navigation.blade.php

+ 3
- 1
app/DataTables/IssueDataTable.php View File

55
     ->setTableId($this->dataTableVariable)
55
     ->setTableId($this->dataTableVariable)
56
     ->columns($this->getColumns())
56
     ->columns($this->getColumns())
57
     // ->minifiedAjax()
57
     // ->minifiedAjax()
58
+    ->responsive()
58
     ->language(asset('plugins/datatables/Italian.json'))
59
     ->language(asset('plugins/datatables/Italian.json'))
59
     ->dom(count($buttons)==0?'rtip':'Brtip')
60
     ->dom(count($buttons)==0?'rtip':'Brtip')
60
     ->orderBy(0, 'desc')
61
     ->orderBy(0, 'desc')
70
     protected function getColumns()
71
     protected function getColumns()
71
     {
72
     {
72
       return [
73
       return [
73
-        Column::make('id')->title('#'),
74
+        Column::make('id')->title('#')->responsivePriority(1),
74
         Column::make('project.name')->title('Cliente'),
75
         Column::make('project.name')->title('Cliente'),
75
         Column::make('created_on')->title('Data')->data('created_on_label'),
76
         Column::make('created_on')->title('Data')->data('created_on_label'),
76
         Column::make('subject')->title('Oggetto'),
77
         Column::make('subject')->title('Oggetto'),
80
         ->printable(false)
81
         ->printable(false)
81
         ->width('10%')
82
         ->width('10%')
82
         ->title(' ')
83
         ->title(' ')
84
+        ->responsivePriority(2)
83
         ->addClass('text-right'),
85
         ->addClass('text-right'),
84
       ];
86
       ];
85
     }
87
     }

+ 41
- 20
resources/views/layouts/navigation.blade.php View File

51
             <x-dropdown-link :href="route('user.profilo')">
51
             <x-dropdown-link :href="route('user.profilo')">
52
               Profilo
52
               Profilo
53
             </x-dropdown-link>
53
             </x-dropdown-link>
54
-            
54
+
55
             <!-- Authentication -->
55
             <!-- Authentication -->
56
             <form method="POST" action="{{ route('logout') }}">
56
             <form method="POST" action="{{ route('logout') }}">
57
               @csrf
57
               @csrf
84
 
84
 
85
 <!-- Responsive Navigation Menu -->
85
 <!-- Responsive Navigation Menu -->
86
 <div :class="{'block': open, 'hidden': ! open}" class="hidden sm:hidden">
86
 <div :class="{'block': open, 'hidden': ! open}" class="hidden sm:hidden">
87
-  <div class="pt-2 pb-3 space-y-1">
88
-    <x-responsive-nav-link :href="route('login')" :active="request()->routeIs('dashboard')">
89
-      {{ __('Dashboard') }}
90
-    </x-responsive-nav-link>
91
-  </div>
87
+    <div class="pt-2 pb-3 space-y-1">
88
+        <x-responsive-nav-link :href="route('home')" :active="request()->routeIs('home')">
89
+            <i class="fas fa-home"></i> Home
90
+        </x-responsive-nav-link>
92
 
91
 
93
-  <!-- Responsive Settings Options -->
94
-  <div class="pt-4 pb-1 border-t border-gray-200">
95
-    <div class="flex items-center px-4">
96
-      <div class="flex-shrink-0">
97
-        <svg class="h-10 w-10 fill-current text-gray-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor">
98
-          <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z" />
99
-        </svg>
100
-      </div>
92
+        <x-responsive-nav-link :href="route('issue.index')" :active="request()->routeIs('issue.index')">
93
+            <i class="fas fa-ticket-alt"></i> Issues
94
+        </x-responsive-nav-link>
101
 
95
 
102
-      <div class="ml-3">
103
-        <div class="font-medium text-base text-gray-800">A</div>
104
-        <div class="font-medium text-sm text-gray-500">B</div>
105
-      </div>
96
+        <x-responsive-nav-link :href="route('azienda.index')" :active="request()->routeIs('azienda.index')">
97
+            <i class="fas fa-industry"></i> Aziende
98
+        </x-responsive-nav-link>
99
+
100
+        <x-responsive-nav-link :href="route('config.index')" :active="request()->routeIs('config.index')">
101
+            <i class="fas fa-cog"></i> Configurazione
102
+        </x-responsive-nav-link>
106
     </div>
103
     </div>
107
 
104
 
108
-    <div class="mt-3 space-y-1">
105
+    <!-- Responsive Settings Options -->
106
+    <div class="pt-4 pb-1 border-t border-gray-200">
107
+        <div class="flex items-center px-4">
108
+            <div class="flex-shrink-0">
109
+                <svg class="h-10 w-10 fill-current text-gray-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor">
110
+                    <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z" />
111
+                </svg>
112
+            </div>
113
+
114
+            <div class="ml-3">
115
+                <div class="font-medium text-base text-gray-800">{{ session('redmine_user')->firstname }} {{ session('redmine_user')->lastname }}</div>
116
+            </div>
117
+        </div>
118
+
119
+        <div class="mt-3 space-y-1">
120
+            <!-- Authentication -->
121
+            <form method="POST" action="{{ route('logout') }}">
122
+                @csrf
123
+
124
+                <x-responsive-nav-link :href="route('logout')"
125
+                        onclick="event.preventDefault();
126
+                                    this.closest('form').submit();">
127
+                    {{ __('Log out') }}
128
+                </x-responsive-nav-link>
129
+            </form>
130
+        </div>
109
     </div>
131
     </div>
110
-  </div>
111
 </div>
132
 </div>
112
 </nav>
133
 </nav>

Loading…
Cancel
Save