disabled side menu toggle for admin, created configuration for product types
This commit is contained in:
parent
43f7d7e9c1
commit
20247136a0
|
|
@ -28,6 +28,8 @@ to the ever demanding online world. Your business whether small or huge it suits
|
|||
|
||||
**We are also having a forum for any type of your concern, feature request discussions. Please visit: [Bagisto Forums](https://forums.bagisto.com/)**
|
||||
|
||||
# Visit our live [Demo](https://demo.bagisto.com)
|
||||
|
||||
It packs in lots of demanding features that allows your business to scale in no time:
|
||||
|
||||
* Multiple Channels, Locale, Currencies.
|
||||
|
|
|
|||
|
|
@ -0,0 +1,7 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
|
||||
];
|
||||
|
||||
?>
|
||||
|
|
@ -93,8 +93,42 @@ body {
|
|||
}
|
||||
}
|
||||
|
||||
.open-nav-aside {
|
||||
display: none;
|
||||
width: 100%;
|
||||
height: 8%;
|
||||
margin-top: 2%;
|
||||
padding: 5px;
|
||||
text-align: center;
|
||||
border: 1px solid $border-color;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.close-nav-aside {
|
||||
display: block;
|
||||
width: 100%;
|
||||
height: 8%;
|
||||
margin-top: 3%;
|
||||
padding: 10px;
|
||||
text-align: center;
|
||||
border: 1px solid $border-color;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.close-nav-aside:hover, .open-nav-aside:hover {
|
||||
background: $brand-color;
|
||||
}
|
||||
|
||||
.open-nav-aside, .close-nav-aside {
|
||||
.icon {
|
||||
height: 28px;
|
||||
width: 28px;
|
||||
}
|
||||
}
|
||||
|
||||
.navbar-left {
|
||||
position: absolute;
|
||||
display: block;
|
||||
position: fixed;
|
||||
top: 60px;
|
||||
bottom: 0;
|
||||
width: 90px;
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@
|
|||
<div class="page-title">
|
||||
<h1>
|
||||
<i class="icon angle-left-icon back-link" onclick="history.length > 1 ? history.go(-1) : window.location = '{{ url('/admin/dashboard') }}';"></i>
|
||||
|
||||
|
||||
{{ __('admin::app.catalog.products.add-title') }}
|
||||
</h1>
|
||||
</div>
|
||||
|
|
@ -44,7 +44,6 @@
|
|||
|
||||
<?php $familyId = app('request')->input('family') ?>
|
||||
<?php $sku = app('request')->input('sku') ?>
|
||||
|
||||
{!! view_render_event('bagisto.admin.catalog.product.create_form_accordian.general.before') !!}
|
||||
|
||||
<accordian :title="'{{ __('admin::app.catalog.products.general') }}'" :active="true">
|
||||
|
|
@ -55,8 +54,9 @@
|
|||
<div class="control-group" :class="[errors.has('type') ? 'has-error' : '']">
|
||||
<label for="type" class="required">{{ __('admin::app.catalog.products.product-type') }}</label>
|
||||
<select class="control" v-validate="'required'" id="type" name="type" {{ $familyId ? 'disabled' : '' }} data-vv-as=""{{ __('admin::app.catalog.products.product-type') }}"">
|
||||
<option value="simple">{{ __('admin::app.catalog.products.simple') }}</option>
|
||||
<option value="configurable" {{ $familyId ? 'selected' : '' }}>{{ __('admin::app.catalog.products.configurable') }}</option>
|
||||
@foreach($productTypes as $key => $productType)
|
||||
<option value="{{ $key }}">{{ $productType['name'] }}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
|
||||
@if ($familyId)
|
||||
|
|
|
|||
|
|
@ -1,8 +1,5 @@
|
|||
<div class="aside-nav">
|
||||
<ul>
|
||||
{{-- <li class="slider-aside">
|
||||
<span class="icon cross-icon" style="height: 64px; width: 64px; background: red;"></span>
|
||||
</li> --}}
|
||||
@if (request()->route()->getName() != 'admin.configuration.index')
|
||||
<?php $keys = explode('.', $menu->currentKey); ?>
|
||||
|
||||
|
|
@ -32,25 +29,25 @@
|
|||
@endif
|
||||
</ul>
|
||||
|
||||
<div class="aside-nav-toggle">
|
||||
<i class="angle-left-icon close-icon"></i>
|
||||
</div>
|
||||
{{-- <div class="close-nav-aside">
|
||||
<i class="icon angle-left-icon close-icon"></i>
|
||||
</div> --}}
|
||||
</div>
|
||||
|
||||
@push('scripts')
|
||||
{{-- @push('scripts')
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$(".close-icon").on('click', function(e){
|
||||
$(".close-nav-aside").on('click', function(e) {
|
||||
$('.content-wrapper').css("margin-left", "0px");
|
||||
$('.aside-nav').hide();
|
||||
$('.open').show();
|
||||
$('.aside-nav').css('display', 'none');
|
||||
$('.open-nav-aside').css('display', 'block');
|
||||
});
|
||||
|
||||
$(".open-icon").on('click', function(e){
|
||||
$(".open-nav-aside").on('click', function(e) {
|
||||
$('.content-wrapper').css("margin-left", "305px");
|
||||
$('.aside-nav').show();
|
||||
$('.open').hide();
|
||||
$('.aside-nav').css('display', '');
|
||||
$('.open-nav-aside').css('display', 'none');
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
@endpush --}}
|
||||
|
|
@ -11,7 +11,7 @@
|
|||
@endforeach
|
||||
</ul>
|
||||
|
||||
<div class="aside-nav-toggle open">
|
||||
<i class="angle-right-icon open-icon"></i>
|
||||
<div class="open-nav-aside">
|
||||
<i class="icon angle-right-icon open-icon"></i>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
[
|
||||
'key' => 'simple',
|
||||
'name' => 'Simple',
|
||||
'sort' => 1
|
||||
|
||||
], [
|
||||
'key' => 'configurable',
|
||||
'name' => 'Configurable',
|
||||
'sort' => 2
|
||||
]
|
||||
];
|
||||
|
|
@ -21,6 +21,8 @@ class ProductServiceProvider extends ServiceProvider
|
|||
$this->app->register(EventServiceProvider::class);
|
||||
|
||||
$this->app->register(ModuleServiceProvider::class);
|
||||
|
||||
$this->composeView();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -30,6 +32,28 @@ class ProductServiceProvider extends ServiceProvider
|
|||
*/
|
||||
public function register()
|
||||
{
|
||||
$this->registerConfig();
|
||||
}
|
||||
|
||||
public function registerConfig() {
|
||||
$this->mergeConfigFrom(
|
||||
dirname(__DIR__) . '/Config/product_types.php', 'product_types'
|
||||
);
|
||||
}
|
||||
|
||||
public function composeView() {
|
||||
view()->composer(['admin::catalog.products.create'], function ($view) {
|
||||
$items = array();
|
||||
|
||||
foreach (config('product_types') as $item) {
|
||||
$item['children'] = [];
|
||||
|
||||
array_push($items, $item);
|
||||
}
|
||||
|
||||
$types = core()->sortItems($items);
|
||||
|
||||
$view->with('productTypes', $types);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
@ -11,6 +11,7 @@ return [
|
|||
'edit' => 'Do you really want to edit this :resource?',
|
||||
],
|
||||
|
||||
'zero-index' => 'Index columns can have values greater than zero only',
|
||||
'no-records' => 'No Records Found',
|
||||
'filter-fields-missing' => 'Some of the required field is null, please check column, condition and value properly',
|
||||
'click_on_action' => 'Do you really want to perform this action?',
|
||||
|
|
|
|||
|
|
@ -338,7 +338,7 @@
|
|||
if (this.filterIndex == this.columnOrAlias && (this.numberValue == 0 || this.numberValue < 0)) {
|
||||
indexConditions = false;
|
||||
|
||||
alert('index columns can have values greater than zero only');
|
||||
alert('{{__('ui::app.datagrid.zero-index')}}');
|
||||
}
|
||||
|
||||
if(indexConditions)
|
||||
|
|
|
|||
Loading…
Reference in New Issue