report fields
This commit is contained in:
15
resources/views/partials/reports/fields.blade.php
Normal file
15
resources/views/partials/reports/fields.blade.php
Normal file
@@ -0,0 +1,15 @@
|
||||
@foreach($fields as $field)
|
||||
@php $type = $field['type']; @endphp
|
||||
|
||||
@if (($type == 'textGroup') || ($type == 'emailGroup') || ($type == 'passwordGroup'))
|
||||
{{ Form::$type('settings[' . $field['name'] . ']', $field['title'], $field['icon'], $field['attributes']) }}
|
||||
@elseif ($type == 'textareaGroup')
|
||||
{{ Form::$type('settings[' . $field['name'] . ']', $field['title']) }}
|
||||
@elseif ($type == 'selectGroup')
|
||||
{{ Form::$type('settings[' . $field['name'] . ']', $field['title'], $field['icon'], $field['values'], $field['selected'], $field['attributes']) }}
|
||||
@elseif ($type == 'radioGroup')
|
||||
{{ Form::$type('settings[' . $field['name'] . ']', $field['title'], 1, $field['enable'], $field['disable'], $field['attributes']) }}
|
||||
@elseif ($type == 'checkboxGroup')
|
||||
{{ Form::$type('settings[' . $field['name'] . ']', $field['title'], $field['items'], $field['value'], $field['id'], $field['attributes']) }}
|
||||
@endif
|
||||
@endforeach
|
||||
@@ -1,6 +1,6 @@
|
||||
<div class="card-header">
|
||||
{!! Form::open([
|
||||
'url' => 'common/reports/' . $class->report->id,
|
||||
'url' => 'common/reports/' . $class->model->id,
|
||||
'role' => 'form',
|
||||
'method' => 'GET',
|
||||
]) !!}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@section('title', $class->report->name)
|
||||
@section('title', $class->model->name)
|
||||
|
||||
@section('new_button')
|
||||
<span>
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
@extends('layouts.print')
|
||||
|
||||
@section('title', $class->report->name)
|
||||
@section('title', $class->model->name)
|
||||
|
||||
@section('content')
|
||||
@if($class->report->chart)
|
||||
@if($class->model->settings->chart)
|
||||
@include($class->views['chart'])
|
||||
@endif
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<div class="card">
|
||||
@include($class->views['filter'])
|
||||
|
||||
@if($class->report->chart)
|
||||
@if(!empty($class->model->settings->chart))
|
||||
@include($class->views['chart'])
|
||||
@endif
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<thead class="thead-light">
|
||||
<tr>
|
||||
@if ($table == 'default')
|
||||
<th>{{ $class->groups[$class->report->group] }}</th>
|
||||
@if (($table == 'default') && !empty($class->groups))
|
||||
<th>{{ $class->groups[$class->model->settings->group] }}</th>
|
||||
@else
|
||||
<th>{{ $table }}</th>
|
||||
@endif
|
||||
|
||||
Reference in New Issue
Block a user