Merge branch 'master' into master

This commit is contained in:
Denis Duliçi
2018-12-24 10:17:40 +03:00
committed by GitHub
176 changed files with 890 additions and 621 deletions

View File

@@ -46,6 +46,9 @@
var text_no = '{{ trans('general.no') }}';
$(document).ready(function(){
$('#enabled_1').trigger('click');
$('#company_name').focus();
$("#default_currency").select2({
placeholder: "{{ trans('general.form.select.field', ['field' => trans_choice('general.currencies', 1)]) }}"
});

View File

@@ -98,10 +98,18 @@
$('#name').focus();
$("#tax_id").select2({
$('#tax_id').select2({
placeholder: {
id: '-1', // the value of the option
text: "{{ trans('general.form.select.field', ['field' => trans_choice('general.taxes', 1)]) }}"
},
escapeMarkup: function (markup) {
return markup;
},
language: {
noResults: function () {
return '<span id="tax-add-new plus"><i class="fa fa-plus"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});
@@ -116,6 +124,26 @@
});
});
$(document).on('click', '.select2-results__option.select2-results__message', function(e) {
tax_name = $('.select2-search__field').val();
$('body > .select2-container.select2-container--default.select2-container--open').remove();
$('#modal-create-tax').remove();
$.ajax({
url: '{{ url("modals/taxes/create") }}',
type: 'GET',
dataType: 'JSON',
data: {name: tax_name},
success: function(json) {
if (json['success']) {
$('body').append(json['html']);
}
}
});
});
$(document).on('click', '#button-category', function (e) {
$('#modal-create-category').remove();

View File

@@ -87,10 +87,18 @@
$("#sale_price").focusout();
$("#purchase_price").focusout();*/
$("#tax_id").select2({
$('#tax_id').select2({
placeholder: {
id: '-1', // the value of the option
text: "{{ trans('general.form.select.field', ['field' => trans_choice('general.taxes', 1)]) }}"
},
escapeMarkup: function (markup) {
return markup;
},
language: {
noResults: function () {
return '<span id="tax-add-new plus"><i class="fa fa-plus"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});
@@ -129,5 +137,25 @@
});
@endif
});
$(document).on('click', '.select2-results__option.select2-results__message', function(e) {
tax_name = $('.select2-search__field').val();
$('body > .select2-container.select2-container--default.select2-container--open').remove();
$('#modal-create-tax').remove();
$.ajax({
url: '{{ url("modals/taxes/create") }}',
type: 'GET',
dataType: 'JSON',
data: {name: tax_name},
success: function(json) {
if (json['success']) {
$('body').append(json['html']);
}
}
});
});
</script>
@endpush

View File

@@ -223,7 +223,7 @@
},
language: {
noResults: function () {
return '<span id="tax-add-new"><i class="fa fa-plus"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
return '<span id="tax-add-new"><i class="fa fa-plus-circle"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});

View File

@@ -204,7 +204,7 @@
},
language: {
noResults: function () {
return '<span id="tax-add-new"><i class="fa fa-plus"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
return '<span id="tax-add-new"><i class="fa fa-plus"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});
@@ -314,7 +314,7 @@
},
language: {
noResults: function () {
return '<span id="tax-add-new"><i class="fa fa-plus"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
return '<span id="tax-add-new"><i class="fa fa-plus-circle"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});

View File

@@ -18,7 +18,7 @@
@stack('quantity_td_start')
<td {{ $errors->has('item.' . $item_row . '.quantity') ? 'class="has-error"' : '' }}>
@stack('quantity_input_start')
<input value="{{ empty($item) ? '' : $item->quantity }}" class="form-control text-center" required="required" name="item[{{ $item_row }}][quantity]" type="text" id="item-quantity-{{ $item_row }}">
<input value="{{ empty($item) ? 1 : $item->quantity }}" class="form-control text-center" required="required" name="item[{{ $item_row }}][quantity]" type="text" id="item-quantity-{{ $item_row }}">
{!! $errors->first('item.' . $item_row . '.quantity', '<p class="help-block">:message</p>') !!}
@stack('quantity_input_end')
</td>

View File

@@ -29,7 +29,7 @@
<i class="fa fa-plus bg-blue"></i>
<div class="timeline-item">
<h3 class="timeline-header">{{ trans('general.title.create', ['type' => trans_choice('general.bills', 1)]) }}</h3>
<h3 class="timeline-header">{{ trans('bills.create_bill') }}</h3>
<div class="timeline-body">
{{ trans_choice('general.statuses', 1) . ': ' . trans('bills.messages.status.created', ['date' => Date::parse($bill->created_at)->format($date_format)]) }}
@@ -44,7 +44,7 @@
<i class="fa fa-envelope bg-orange"></i>
<div class="timeline-item">
<h3 class="timeline-header">{{ trans('general.title.send', ['type' => trans_choice('general.bills', 1)]) }}</h3>
<h3 class="timeline-header">{{ trans('bills.receive_bill') }}</h3>
<div class="timeline-body">
@if ($bill->status->code == 'draft')
@@ -63,7 +63,7 @@
<i class="fa fa-money bg-green"></i>
<div class="timeline-item">
<h3 class="timeline-header">{{ trans('general.title.get', ['type' => trans('general.paid')]) }}</h3>
<h3 class="timeline-header">{{ trans('bills.make_payment') }}</h3>
<div class="timeline-body">
@if($bill->status->code != 'paid' && empty($bill->payments()->count()))

View File

@@ -223,7 +223,7 @@
},
language: {
noResults: function () {
return '<span id="tax-add-new"><i class="fa fa-plus"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
return '<span id="tax-add-new plus"><i class="fa fa-plus-circle"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});
@@ -306,7 +306,7 @@
},
language: {
noResults: function () {
return '<span id="tax-add-new"><i class="fa fa-plus"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
return '<span id="tax-add-new"><i class="fa fa-plus"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});
@@ -403,6 +403,7 @@
$(document).on('click', '#cancel-discount', function(){
$('#discount').val('');
totalItem();
$('a[rel=popover]').trigger('click');

View File

@@ -204,7 +204,7 @@
},
language: {
noResults: function () {
return '<span id="tax-add-new"><i class="fa fa-plus"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
return '<span id="tax-add-new"><i class="fa fa-plus"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});
@@ -314,7 +314,7 @@
},
language: {
noResults: function () {
return '<span id="tax-add-new"><i class="fa fa-plus"> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
return '<span id="tax-add-new"><i class="fa fa-plus-circle"></i> {{ trans('general.title.new', ['type' => trans_choice('general.tax_rates', 1)]) }}</span>';
}
}
});

View File

@@ -18,7 +18,7 @@
@stack('quantity_td_start')
<td {{ $errors->has('item.' . $item_row . '.quantity') ? 'class="has-error"' : '' }}>
@stack('quantity_input_start')
<input value="{{ empty($item) ? '' : $item->quantity }}" class="form-control text-center" required="required" name="item[{{ $item_row }}][quantity]" type="text" id="item-quantity-{{ $item_row }}">
<input value="{{ empty($item) ? 1 : $item->quantity }}" class="form-control text-center" required="required" name="item[{{ $item_row }}][quantity]" type="text" id="item-quantity-{{ $item_row }}">
{!! $errors->first('item.' . $item_row . '.quantity', '<p class="help-block">:message</p>') !!}
@stack('quantity_input_end')
</td>

View File

@@ -29,7 +29,7 @@
<i class="fa fa-plus bg-blue"></i>
<div class="timeline-item">
<h3 class="timeline-header">{{ trans('general.title.create', ['type' => trans_choice('general.invoices', 1)]) }}</h3>
<h3 class="timeline-header">{{ trans('invoices.create_invoice') }}</h3>
<div class="timeline-body">
{{ trans_choice('general.statuses', 1) . ': ' . trans('invoices.messages.status.created', ['date' => Date::parse($invoice->created_at)->format($date_format)]) }}
@@ -44,7 +44,7 @@
<i class="fa fa-envelope bg-orange"></i>
<div class="timeline-item">
<h3 class="timeline-header">{{ trans('general.title.send', ['type' => trans_choice('general.invoices', 1)]) }}</h3>
<h3 class="timeline-header">{{ trans('invoices.send_invoice') }}</h3>
<div class="timeline-body">
@if ($invoice->status->code != 'sent' && $invoice->status->code != 'partial')
@@ -74,7 +74,7 @@
<i class="fa fa-money bg-green"></i>
<div class="timeline-item">
<h3 class="timeline-header">{{ trans('general.title.get', ['type' => trans('general.paid')]) }}</h3>
<h3 class="timeline-header">{{ trans('invoices.get_paid') }}</h3>
<div class="timeline-body">
@if($invoice->status->code != 'paid' && empty($invoice->payments()->count()))

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.admin.head')
<body class="hold-transition {{ setting('general.admin_theme', 'skin-green-light') }} sidebar-mini fixed">

View File

@@ -1,4 +1,4 @@
<html lang="{{ env('APP_LOCALE') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.auth.head')
<body class="hold-transition login-page">

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.bill.head')
<body onload="window.print();">

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.customer.head')
<body class="hold-transition skin-green-light sidebar-mini fixed">

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.invoice.head')
<body onload="window.print();">

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.link.head')
<body class="hold-transition skin-green-light sidebar-mini fixed link">

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.modules.head')
<body class="hold-transition {{ setting('general.admin_theme', 'skin-green-light') }} sidebar-mini fixed">

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.admin.head')
@push('css')

View File

@@ -1,4 +1,4 @@
<html lang="{{ setting('general.default_locale') }}">
<html lang="{{ app()->getLocale() }}">
@include('partials.wizard.head')
<body class="hold-transition {{ setting('general.admin_theme', 'skin-green-light') }} sidebar-mini fixed">

View File

@@ -11,6 +11,7 @@
@include('partials.modules.bar')
<div class="row">
@if ($paid)
<div class="col-md-12">
<div class="content-header no-padding-left">
<h3>{{ trans('modules.top_paid') }}</h3>
@@ -24,7 +25,9 @@
@include('partials.modules.no_apps')
@endif
</div>
@endif
@if ($new)
<div class="col-md-12">
<div class="content-header no-padding-left">
<h3>{{ trans('modules.new') }}</h3>
@@ -38,7 +41,9 @@
@include('partials.modules.no_apps')
@endif
</div>
@endif
@if ($free)
<div class="col-md-12">
<div class="content-header no-padding-left">
<h3>{{ trans('modules.top_free') }}</h3>
@@ -52,5 +57,6 @@
@include('partials.modules.no_apps')
@endif
</div>
@endif
</div>
@endsection

View File

@@ -146,12 +146,14 @@
@if ($module->price == '0.0000')
{{ trans('modules.free') }}
@else
{!! $module->price_prefix !!}
@if (isset($module->special_price))
<del>{{ $module->price }}</del>
{{ $module->special_price }}
@else
{{ $module->price }}
@endif
{!! $module->price_suffix !!}
@endif
</div>
</div>
@@ -205,7 +207,7 @@
<tbody>
@if ($module->vendor_name)
<tr>
<th>{{ trans_choice('general.vendors', 1) }}</th>
<th>{{ trans_choice('general.developers', 1) }}</th>
<td class="text-right"><a href="{{ url('apps/vendors/' . $module->vendor->slug) }}">{{ $module->vendor_name }}</a></td>
</tr>
@endif

View File

@@ -9,7 +9,7 @@
<div class="box-body">
<div class="col-md-12">
<div class="form-group required {{ $errors->has('api_token') ? 'has-error' : ''}}">
{!! Form::label('sale_price', trans('modules.api_token'), ['class' => 'control-label']) !!}
{!! Form::label('api_token', trans('modules.api_token'), ['class' => 'control-label']) !!}
<div class="input-group">
<span class="input-group-addon"><i class="fa fa-key"></i></span>
{!! Form::text('api_token', setting('general.api_token', null), ['class' => 'form-control', 'required' => 'required', 'placeholder' => trans('general.form.enter', ['field' => trans('modules.api_token')])]) !!}

View File

@@ -44,12 +44,14 @@
@if ($module->price == '0.0000')
{{ trans('modules.free') }}
@else
{!! $module->price_prefix !!}
@if (isset($module->special_price))
<del>{{ $module->price }}</del>
{{ $module->special_price }}
@else
{{ $module->price }}
@endif
{!! $module->price_suffix !!}
@endif
</div>
</div>

View File

@@ -1,60 +1,62 @@
<div id="review-items">
@foreach($reviews->data as $review)
<div class="post">
<div class="user-block">
<img class="img-circle img-bordered-sm" src="{{ $review->thumb }}" alt="{{ $review->author }}">
<span class="username">
{{ $review->author }}
<span class="pull-right">
@for($i = 1; $i <= $review->rating; $i++)
<i class="fa fa-star"></i>
@endfor
@for($i = $review->rating; $i < 5; $i++)
<i class="fa fa-star-o"></i>
@endfor
</span>
<div class="post">
<div class="user-block">
<img class="img-circle img-bordered-sm" src="{{ $review->thumb }}" alt="{{ $review->author }}">
<span class="username">
{{ $review->author }}
<span class="pull-right">
@for($i = 1; $i <= $review->rating; $i++)
<i class="fa fa-star"></i>
@endfor
@for($i = $review->rating; $i < 5; $i++)
<i class="fa fa-star-o"></i>
@endfor
</span>
<span class="description">{{ \Carbon\Carbon::parse($review->created_at)->format('F d, Y') }}</span>
</div>
<!-- /.user-block -->
<p>
{!! nl2br($review->text) !!}
</p>
</span>
<span class="description">{{ Date::parse($review->created_at)->format($date_format) }}</span>
</div>
<p>
{!! nl2br($review->text) !!}
</p>
</div>
@endforeach
@stack('pagination_start')
@php
$review_first_item = count($reviews->data) > 0 ? ($reviews->current_page - 1) * $reviews->per_page + 1 : null;
$review_last_item = count($reviews->data) > 0 ? $review_first_item + count($reviews->data) - 1 : null;
@endphp
@if ($review_first_item)
<div class="pull-left" style="margin-top: 7px;">
<small>{{ trans('pagination.showing', ['first' => $review_first_item, 'last' => $review_last_item, 'total' => $reviews->total, 'type' => strtolower(trans('modules.tab.reviews'))]) }}</small>
</div>
<div class="pull-right">
<ul class="pagination pagination-sm no-margin">
{{-- Previous Page Link --}}
@if ($reviews->current_page <= 1)
<li class="disabled"><span>&laquo;</span></li>
<li class="disabled"><span>&laquo;</span></li>
@else
<li><a href="{{ url(request()->path()) }}?page={{ $reviews->current_page - 1 }}" rel="prev">&laquo;</a></li>
<li><a href="{{ url(request()->path()) }}?page={{ $reviews->current_page - 1 }}" rel="prev">&laquo;</a></li>
@endif
{{-- Pagination Elements --}}
@for ($page = 1; $page <= $reviews->last_page; $page++)
@if ($page == $reviews->current_page)
<li class="active"><span>{{ $page }}</span></li>
<li class="active"><span>{{ $page }}</span></li>
@else
<li><a href="{{ url(request()->path()) }}?page={{ $page }}" data-page="{{ $page }}">{{ $page }}</a></li>
<li><a href="{{ url(request()->path()) }}?page={{ $page }}" data-page="{{ $page }}">{{ $page }}</a></li>
@endif
@endfor
{{-- Next Page Link --}}
@if ($reviews->current_page != 1)
<li><a href="{{ url(request()->path()) }}?page={{ $reviews->current_page + 1 }}" rel="next">&raquo;</a></li>
<li><a href="{{ url(request()->path()) }}?page={{ $reviews->current_page + 1 }}" rel="next">&raquo;</a></li>
@else
<li class="disabled"><span>&raquo;</span></li>
<li class="disabled"><span>&raquo;</span></li>
@endif
</ul>
</div>
@@ -65,4 +67,4 @@
@endif
@stack('pagination_end')
</div>
</div>

View File

@@ -4,6 +4,7 @@
</td>
<td>
{{ Form::textGroup('rate', trans('currencies.rate'), 'money', ['required' => 'required'], null, '') }}
{{ Form::hidden('type', 'normal') }}
</td>
<td class="hidden-xs">
{{ Form::radioGroup('enabled', trans('general.enabled'), trans('general.yes'), trans('general.no'), [], 'col-md-12 tax-enabled-radio-group') }}

View File

@@ -4,6 +4,7 @@
</td>
<td>
{{ Form::textGroup('rate', trans('currencies.rate'), 'money', ['required' => 'required'], $item->rate, '') }}
{{ Form::hidden('type', 'normal') }}
</td>
<td class="hidden-xs">
{{ Form::radioGroup('enabled', trans('general.enabled'), trans('general.yes'), trans('general.no'), [], 'col-md-12') }}