Started work on SiteDetails and Setup

This commit is contained in:
Deon George
2018-07-31 14:11:00 +10:00
parent 0ce640c283
commit 1cde2a888a
24 changed files with 1373 additions and 177 deletions

View File

@@ -0,0 +1,87 @@
@extends('adminlte::layouts.app')
@section('htmlheader_title')
Setup
@endsection
@section('contentheader_title')
{{ $so->site_name }}
@endsection
@section('contentheader_description')
Setup
@endsection
@section('main-content')
<div class="col-md-9">
<div class="box box-primary">
<div class="box-header with-border">
<h3 class="box-title">Setup Configuration</h3>
</div>
<form role="form" method="POST">
{{ csrf_field() }}
@if(session()->has('success'))
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div class="callout callout-success">
<p>{{ session()->get('success') }}</p>
</div>
</div>
</div>
@endif
@if($errors->any())
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div class="callout callout-danger">
<p>Some validation errors to look at.</p>
<ul>
@foreach ($errors->all() as $error)
<li>{{ $error }}</li>
@endforeach
</ul>
</div>
</div>
</div>
@endif
<div class="nav-tabs-custom">
<ul class="nav nav-tabs">
<li class="active"><a href="#tab-site" data-toggle="tab">Site Details</a></li>
<li><a href="#tab-other" data-toggle="tab">Other</a></li>
</ul>
<div class="box-body">
<div class="tab-content">
<div class="tab-pane active" id="tab-site">
@include('a.widgets.setup_site_details')
</div>
<div class="tab-pane" id="tab-other">
Other Details
</div>
</div>
</div>
<div class="box-footer">
<button type="submit" class="btn btn-info">Save</button>
</div>
</div>
</form>
</div>
</div>
@endsection
@section('page-scripts')
@js('/js/jqBootstrapValidation.js','jq-validation','jquery')
<script>
$(function () { $("input,select,textarea").not("[type=submit]").jqBootstrapValidation(); } );
</script>
<style>
span.help-block > ul {
color: #9d0000;
padding-left: 5px;
list-style-type: none;
}
</style>
@append

View File

@@ -0,0 +1,61 @@
<div class="form-group col-sm-12 {{ $errors->has('site_name') ? 'has-error' : '' }}">
<label for="site_name">Site Name</label>
<input type="text" class="form-control" id="site_name" name="site_name" placeholder="Site Name" value="{{ old('site_name',$so->site_name) }}">
<span class="help-block">{{ $errors->first('site_name') }}</span>
</div>
<div class="form-group col-sm-12 {{ $errors->has('site_description') ? 'has-error' : '' }}">
<label for="site_description">Site Description</label>
<textarea class="form-control" id="site_description" name="site_description" placeholder="Site Description" rows="3">{{ old('site_description',$so->site_description) }}</textarea>
<span class="help-block">{{ $errors->first('site_description') }}</span>
</div>
<fieldset class="form-group col-sm-12">
<label>Site Address</label>
<div class="form-group col-sm-12 {{ $errors->has('site_address1') ? 'has-error' : '' }}">
<label for="site_address">Site Address Lines</label>
<input type="text" class="form-control" id="site_address1" name="site_address1" placeholder="Address1" value="{{ old('site_address1',$so->site_address1) }}">
<input type="text" class="form-control" id="site_address2" name="site_address2" placeholder="Address2" value="{{ old('site_address2',$so->site_address2) }}">
<span class="help-block">{{ $errors->first('site_address1') }} {{ $errors->first('site_address2') }}</span>
</div>
<div class="form-group col-sm-6 {{ $errors->has('site_city') ? 'has-error' : '' }}">
<label for="site_address">Site City</label>
<input type="text" class="form-control" id="site_city" name="site_city" placeholder="City" value="{{ old('site_city',$so->site_city) }}">
<span class="help-block">{{ $errors->first('site_city') }}</span>
</div>
<div class="form-group col-sm-3 {{ $errors->has('site_state') ? 'has-error' : '' }}">
<label for="site_address">Site State</label>
<input type="text" class="form-control col-sm-3" id="site_state" name="site_state" placeholder="State" value="{{ old('site_state',$so->site_state) }}">
<span class="help-block">{{ $errors->first('site_state') }}</span>
</div>
<div class="form-group col-sm-3 {{ $errors->has('site_postcode') ? 'has-error' : '' }}">
<label for="site_address">Site Post Code</label>
<input type="text" class="form-control col-sm-3" id="site_postcode" name="site_postcode" placeholder="Post Code" value="{{ old('site_postcode',$so->site_postcode) }}">
<span class="help-block">{{ $errors->first('site_postcode') }}</span>
</div>
</fieldset>
<div class="form-group col-sm-6 {{ $errors->has('site_phone') ? 'has-error' : '' }}">
<label for="site_phone">Site Phone</label>
<input class="form-control" id="site_phone" name="site_phone" placeholder="Site Phone" value="{{ old('site_phone',$so->site_phone) }}">
<span class="help-block">{{ $errors->first('site_phone') }}</span>
</div>
<div class="form-group col-sm-6 {{ $errors->has('site_fax') ? 'has-error' : '' }}">
<label for="site_fax">Site Fax</label>
<input class="form-control" id="site_fax" name="site_fax" placeholder="Site Fax" value="{{ old('site_fax',$so->site_fax) }}">
<span class="help-block">{{ $errors->first('site_fax') }}</span>
</div>
<div class="control-group form-group col-sm-6 {{ $errors->has('site_email') ? 'has-error' : '' }}">
<label for="site_email">Site Email</label>
<input type="email" class="form-control" id="site_email" name="site_email" placeholder="Site Email" value="{{ old('site_email',$so->site_email) }}">
<span class="help-block">{{ $errors->first('site_email') }}</span>
</div>
<div class="control-group form-group col-sm-6 {{ $errors->has('site_tax') ? 'has-error' : '' }}">
<label for="site_tax">Site Tax Number</label>
<div class="input-group">
<span class="input-group-addon">ABN</span>
<input type="number" class="form-control" id="site_tax" name="site_tax" minlength="10" maxlength="10" placeholder="Site Tax" value="{{ old('site_tax',$so->site_tax) }}">
</div>
<span class="help-block">{{ $errors->first('site_tax') }}</span>
</div>

View File

@@ -12,14 +12,10 @@
@endsection
@section('main-content')
<div class="content">
<div class="row">
<div class="col-xs-6">
@include('r.agents')
</div>
<div class="col-xs-6">
@include('r.accounts')
</div>
</div>
<div class="col-xs-6">
@include('r.agents')
</div>
<div class="col-xs-6">
@include('r.accounts')
</div>
@endsection

View File

@@ -49,4 +49,4 @@
</body>
<!-- BODY End-->
</html>
</html>

View File

@@ -24,12 +24,11 @@
<h2>Our Contacts</h2>
<address class="margin-bottom-40">
<table>
<tr><th style="vertical-align:top; padding-right: 5px;">Address</th><td>{!! join('<br>',[$so->address['address1'],$so->address['address2'],sprintf('%s, %s %s',$so->address['city'],$so->address['state'],$so->address['postcode'])]) !!}</td></tr>
<tr><th>Phone</th><td>{!! $so->phone !!}</tr>
@if($so->fax)
<tr><th>Fax</th><td>{!! $so->fax !!}</tr>
<tr><th style="vertical-align:top; padding-right: 5px;">Address</th><td>{!! $so->address('html') !!}</td></tr>
@if($so->site_fax)
<tr><th>Fax</th><td>{{ $so->site_fax }}</tr>
@endif
<tr><th>Email</th><td> <a href="mailto:{!! $so->email !!}">{!! $so->email !!}</a></tr>
<tr><th>Email</th><td> <a href="mailto:{{ $so->site_email }}">{{ $so->site_email }}</a></tr>
</table>
</address>
<!--

View File

@@ -1,6 +1,6 @@
<head>
<meta charset="UTF-8">
<title>{{ config('app.name') }} - {{ $so->name }}</title>
<title>{{ config('app.name') }} - {{ $so->site_name }}</title>
<meta content="width=device-width, initial-scale=1.0" name="viewport" />
<!-- CSRF Token -->
@@ -9,7 +9,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta property="og:site_name" content="{{ config('app.name') }}" />
<meta property="og:title" content="{{ $so->name }}" />
<meta property="og:title" content="{{ $so->site_name }}" />
<meta property="og:description" content="{{ $so->site_description }}" />
<meta property="og:type" content="website" />
<meta property="og:image" content="{{ $so->site_logo }}" />

View File

@@ -5,8 +5,8 @@
<!-- BEGIN TOP BAR LEFT PART -->
<div class="col-md-6 col-sm-6 additional-shop-info">
<ul class="list-unstyled list-inline">
<li><i class="fa fa-phone"></i><span>{!! $so->phone !!}</span></li>
<li><i class="fa fa-envelope-o"></i><span>{!! $so->email !!}</span></li>
<li><i class="fa fa-phone"></i><span>{!! $so->site_phone !!}</span></li>
<li><i class="fa fa-envelope-o"></i><span>{!! $so->site_email !!}</span></li>
</ul>
</div>
<!-- END TOP BAR LEFT PART -->
@@ -27,7 +27,7 @@
<!-- BEGIN HEADER -->
<div class="header">
<div class="container">
<a class="site-logo" href="{{ url('/') }}"><img src="{{ $so->logo_url() }}" alt="{{ config('app.name') }}" height="32"></a>
<a class="site-logo" href="{{ url('/') }}"><img src="{{ $so->logo_url() }}" alt="{{ $so->site_description }}" height="32"></a>
<a href="javascript:void(0);" class="mobi-toggler"><i class="fa fa-bars"></i></a>
<!-- BEGIN NAVIGATION -->

View File

@@ -1,3 +1,5 @@
{{-- This is not working unless site_slider is running. Might be a problem with the carousel --}}
<!-- BEGIN CLIENTS -->
<div class="row margin-bottom-40 our-clients">
<div class="col-md-3">
@@ -20,4 +22,17 @@
</div>
</div>
</div>
<!-- END CLIENTS -->
<!-- END CLIENTS -->
@section('scripts')
<!-- END SLIDER -->
@css('/site/js/jquery/plugins/owl.carousel/2.0.0/css/owl.carousel.css')
@css('/site/css/animate.css')
@js('/site/js/jquery/plugins/owl.carousel/2.0.0/js/owl.carousel.min.js','jq-owl-carousel','jquery')
<script type="text/javascript">
jQuery(document).ready(function() {
// Layout.initOWL();
});
</script>
@append

View File

@@ -67,16 +67,16 @@
</div>
</div>
<!-- END SLIDER -->
@css('/site/js/jquery/plugins/owl.carousel/2.0.0/css/owl.carousel.css')
@css('/site/css/animate.css')
@js('/site/js/jquery/plugins/owl.carousel/2.0.0/js/owl.carousel.min.js','jq-owl-carousel','jquery')<!-- slider for products -->
@js('/pages/js/bs-carousel.js','bs-carousel','jq-owl-carousel')
@section('scripts')
<!-- END SLIDER -->
@css('/site/js/jquery/plugins/owl.carousel/2.0.0/css/owl.carousel.css')
@css('/site/css/animate.css')
@js('/site/js/jquery/plugins/owl.carousel/2.0.0/js/owl.carousel.min.js','jq-owl-carousel','jquery')<!-- slider for products -->
@js('/pages/js/bs-carousel.js','bs-carousel','jq-owl-carousel')
<script type="text/javascript">
jQuery(document).ready(function() {
Layout.initOWL();
});
</script>
@append
@append