Merge branch 'master' of https://github.com/bagisto/bagisto into development

This commit is contained in:
Prashant Singh 2019-01-31 19:59:06 +05:30
commit f90df9ef01
31 changed files with 40 additions and 52 deletions

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
{
"/js/admin.js": "/js/admin.js?id=da5ebef9c25a064e7ed6",
"/css/admin.css": "/css/admin.css?id=0864a44c0f49929aff6a"
"/css/admin.css": "/css/admin.css?id=f9b723e338ec03ec5c50"
}

View File

@ -15,8 +15,6 @@ class AttributeDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 10; //overriding the default items per page
protected $index = 'id'; //the column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class AttributeFamilyDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id'; //the column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class CategoryDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'category_id'; //the column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class ChannelDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id'; //the column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class CurrencyDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id'; //the column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class CustomerDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'customer_id'; //the column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class CustomerGroupDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id'; //the column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class CustomerReviewDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'product_review_id'; //column that needs to be treated as index column
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class ExchangeRatesDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'currency_exch_id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class InventorySourcesDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class LocalesDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class NewsLetterDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class OrderDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class OrderInvoicesDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class OrderShipmentsDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'shipment_id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class ProductDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 10; //overriding the default items per page
protected $sortOrder = 'desc'; //asc or desc
protected $index = 'product_id';

View File

@ -15,8 +15,6 @@ class RolesDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class SliderDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'slider_id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class TaxCategoryDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class TaxRateDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -15,8 +15,6 @@ class UserDataGrid extends DataGrid
{
protected $paginate = true;
protected $itemsPerPage = 5; //overriding the default items per page
protected $index = 'user_id';
protected $sortOrder = 'desc'; //asc or desc

View File

@ -9,6 +9,7 @@ use Webkul\Admin\Facades\Configuration;
use Webkul\Core\Repositories\CoreConfigRepository as CoreConfig;
use Webkul\Core\Tree;
use Webkul\Admin\Http\Requests\ConfigurationForm;
use Illuminate\Support\Facades\Storage;
/**
* Configuration controller
@ -143,4 +144,18 @@ class ConfigurationController extends Controller
return redirect()->back();
}
/**
* download the file for the specified resource.
*
* @return \Illuminate\Http\Response
*/
public function download(Request $request)
{
$id = request()->route()->parameters()['id'];
$config = $this->coreConfig->findOneByField('id', $id);
return Storage::download($config['value']);
}
}

View File

@ -28,8 +28,7 @@ class ConfigurationForm extends FormRequest
'sales.*.*.title' => 'required',
'sales.*.*.active' => 'required',
'sales.*.*.order_status' => 'required',
// 'sales.*.*.Image' => 'image|mimes:jpg,png',
// 'sales.*.*.File' => 'mimes:doc,pdf,docx,zip',
'sales.*.*.file' => 'max:2048',
];
return $this->rules;
@ -46,8 +45,6 @@ class ConfigurationForm extends FormRequest
'sales.*.*.title.required' => 'The title field is required.',
'sales.*.*.active.required' => 'The status field is required.',
'sales.*.*.order_status.required' => 'Order Status field is required',
// 'sales.*.*.Image.image' => 'Image field must be an image',
// 'sales.*.*.Image.mimes' => 'Image must be a file of type: jpg, png',
];
}
}

View File

@ -69,7 +69,6 @@ Route::group(['middleware' => ['web']], function () {
Route::get('customers/delete/{id}', 'Webkul\Admin\Http\Controllers\Customer\CustomerController@destroy')->name('admin.customer.delete');
Route::get('reviews', 'Webkul\Product\Http\Controllers\ReviewController@index')->defaults('_config',[
'view' => 'admin::customers.reviews.index'
])->name('admin.customer.review.index');
@ -83,6 +82,10 @@ Route::group(['middleware' => ['web']], function () {
'redirect' => 'admin.configuration.index'
])->name('admin.configuration.index.store');
Route::get('configuration/{slug?}/{slug2?}/{path}', 'Webkul\Admin\Http\Controllers\ConfigurationController@download')->defaults('_config', [
'redirect' => 'admin.configuration.index'
])->name('admin.configuration.download');
// Reviews Routes
Route::get('reviews/edit/{id}', 'Webkul\Product\Http\Controllers\ReviewController@edit')->defaults('_config',[
'view' => 'admin::customers.reviews.edit'

View File

@ -558,6 +558,16 @@ body {
}
// customer oder css for admin end here
//configuration css
.configuration-image {
position: relative;
height: 33px;
width: 33px;
top: 15px;
border-radius: 3px;
margin-right: 5px;
}
// css for rtl start here

View File

@ -165,7 +165,7 @@
?>
@if ($result)
<img src="{{ $src }}" style="position: relative; top: 15px" />
<img src="{{ $src }}" class="configuration-image"/>
@endif
<input type="file" v-validate="'{{ $validations }}'" class="control" id="{{ $firstField }}[{{ $secondField }}][{{ $thirdField }}][{{ $field['name'] }}]" name="{{ $firstField }}[{{ $secondField }}][{{ $thirdField }}][{{ $field['name'] }}]" value="{{ old($name) ?: core()->getConfigData($name) }}" data-vv-as="&quot;{{ $field['name'] }}&quot;" style="padding-top: 5px;">
@ -185,6 +185,8 @@
<?php
$result = core()->getConfigData($name);
$src = explode("/", $result);
$path = end($src);
?>
<input type="file" v-validate="'{{ $validations }}'" class="control" id="{{ $firstField }}[{{ $secondField }}][{{ $thirdField }}][{{ $field['name'] }}]" name="{{ $firstField }}[{{ $secondField }}][{{ $thirdField }}][{{ $field['name'] }}]" value="{{ old($name) ?: core()->getConfigData($name) }}" data-vv-as="&quot;{{ $field['name'] }}&quot;" style="padding-top: 5px;">

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
{
"/js/ui.js": "/js/ui.js?id=8f9e12057b68b45d7046",
"/css/ui.css": "/css/ui.css?id=7a43bd666cebcd9daf43"
"/css/ui.css": "/css/ui.css?id=30da0e7b0c67d193950c"
}

View File

@ -970,4 +970,7 @@ modal {
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
.pull-right {
float:right;
}