zizohassan / laraflat Goto Github PK
View Code? Open in Web Editor NEWAdvanced laravel system to build admin panel
Home Page: http://laraflat.com
License: MIT License
Advanced laravel system to build admin panel
Home Page: http://laraflat.com
License: MIT License
How to add language and how to access pages that have been created in 'admin/page'?
Dear AbdulAziz,
When i try to login i got this error
TokenMismatchException in VerifyCsrfToken.php line 68:
in VerifyCsrfToken.php line 68
at VerifyCsrfToken->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in ShareErrorsFromSession.php line 49
at ShareErrorsFromSession->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in StartSession.php line 64
at StartSession->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in AddQueuedCookiesToResponse.php line 37
at AddQueuedCookiesToResponse->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in EncryptCookies.php line 59
at EncryptCookies->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in Pipeline.php line 102
at Pipeline->then(object(Closure)) in Router.php line 561
at Router->runRouteWithinStack(object(Route), object(Request)) in Router.php line 520
at Router->dispatchToRoute(object(Request)) in Router.php line 498
at Router->dispatch(object(Request)) in Kernel.php line 174
at Kernel->Illuminate\Foundation\Http{closure}(object(Request)) in Pipeline.php line 30
at Pipeline->Illuminate\Routing{closure}(object(Request)) in HandleCors.php line 36
at HandleCors->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in TransformsRequest.php line 30
at TransformsRequest->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in TransformsRequest.php line 30
at TransformsRequest->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in ValidatePostSize.php line 27
at ValidatePostSize->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in CheckForMaintenanceMode.php line 46
at CheckForMaintenanceMode->handle(object(Request), object(Closure)) in Pipeline.php line 148
at Pipeline->Illuminate\Pipeline{closure}(object(Request)) in Pipeline.php line 53
at Pipeline->Illuminate\Routing{closure}(object(Request)) in Pipeline.php line 102
at Pipeline->then(object(Closure)) in Kernel.php line 149
at Kernel->sendRequestThroughRouter(object(Request)) in Kernel.php line 116
at Kernel->handle(object(Request)) in index.php line 54
at require_once('E:\laraflat\shop\public\index.php') in server.php line 21
Can you help me this issue.
Thanks in Advance Bro
DataTables warning: table id=dataTableBuilder - Ajax error. For more information about this error how to fix this
when i make migrate it show that error :
PHP Warning: require(C:\ionic\easysoft\bootstrap/../vendor/autoload.php): failed to open stream: No such file or directory in C:\ionic\easysoft\bootstrap\autoload.php on line 17
PHP Fatal error: require(): Failed opening required 'C:\ionic\easysoft\bootstrap/../vendor/autoload.php' (include_path='.;C:\php\pear') in C:\ionic\easysoft\bootstrap\autoload.php on line 17
i created a new module using laraflat called (Website)
i wanted to show only the data with id=1 in datatables like this
public function index(WebsitesDataTable $dataTable){
$this->model->where('id','1');
return $dataTable->render('admin.website.index');
}
but not working ... how can i deal with the datatables and send a query to it with EX please
HI
In the new version in generating new admin_model
when adding more than one item you get this error
Undefined offset: 0
in :…/app/Application/Controllers/Admin/CommandsController.php line 128
if ($request->colsName) {
$count = 0;
foreach ($request->colsName as $key => $cols) {
$count++;
$lang = $request->lang[$key] == 0 ? 'false' : 'true';
$validation = $this->handelValidation($request->validation[$key], $request->validationVal[$key]);
$colsOption .= $cols . ':' . $request->migration[$key] . ':' . $validation . ':' . $lang;
if ($count != count($request->colsName)) {
$colsOption .= ',';
}
}
}
DataTables warning: table id=dataTableBuilder - Ajax error....
I have download the zip from here
https://github.com/zizohassan/laraflat/releases/tag/1.0.1
then :
Z:\laraflat-1.0.1>composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
The "http://packagist.org/p/symfony/http-kernel%242cbb4a9acbd5961e1720c4b692b3f3a5208c73e2eb2d372a2117b3964be803ad.json" file could not be downloaded: failed to open stream: HTTP request failed!
http://packagist.org could not be fully loaded, package information was loaded from the local cache and may be out of date
Package operations: 101 installs, 0 updates, 0 removals
- Installing paragonie/random_compat (v2.0.11) Loading from cache
- Installing ramsey/uuid (dev-master 45cffe8) Loading from cache
- Installing mpociot/reflection-docblock (1.0.1) Loading from cache
...
..
.
.
.
.
@php artisan package:discover
In Connection.php line 664:
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'laraflat.pages' doesn't exist (SQL: select `title`, `slu
g` from `pages` where `slug` = about_us limit 1)
In Connection.php line 326:
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'laraflat.pages' doesn't exist
Script @php artisan package:discover handling the post-autoload-dump event returned with error code 1
Z:\laraflat-1.0.1>
I can't run any command in my terminal like
php artisan migrate
php artisan serve
php artisan cache:clear , etc ... .. .. .
great effort but I faced a little problem when project running on an online server and I logged as admin I can't access the admin page it redirected me to default homepage.
note it working on localhost correctly.
after I migrated and ran the seeders.still this line was problemtaic
return \App\Application\Model\Menu::where('name' , $name)->with(['item' => function($query){
return $query->orderBy('order' , 'asc');
}])->first()->item->groupBy('parent_id');
"Trying to get property of non-object (View: /tmp/laraflat/app/Application/views/layouts/menu.blade.php) (View: /tmp/laraflat/app/Application/views/layouts/menu. ▶"
i installed it with composer create-project --prefer-dist laraflat/laraflat
how can i update bootstrap and and change the theme.
when i login with admin ,it redirect me to 404 page
in database there is no record in permission table and permission roles
i hope you reply
thank
error: unable to create file public/admin/
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry the checkout with 'git checkout -f HEAD'
Salam;
it's possible te use laraflat with just one langue
thanks advance
DataTables warning: table id=dataTableBuilder - Ajax error. For more information about this error, please see http://datatables.net/tn/7
this error come when i open this page
i try to solve it with
$.fn.dataTable.ext.errMode = 'throw';
and solved
but the page take along time to get data and some time show end first process and reload it and
data come
i am sorry for my error
but i need to use laraflat thanks for u
NOT Schema::drop('permission_role'); in create_perission_groupe_table.php
if you are working on ubuntu server you most give permission to resource , config , app and database folders .
this is required when you use Laraflat Commands new model like post .
you may missed to add those thing to your documentation .
thank you for your amazing job
another thing , your project seems like slower than before , sometime it need really long time to go to another page , I got this problem today on real server ,I think the problem because you are tracking the visitors . is there is anyway to stop that ?
Canvas.resize | @ | jquery.flot.js:135
Canvas | @ | jquery.flot.js:114
setupCanvases | @ | jquery.flot.js:1313
Plot | @ | jquery.flot.js:707
$.plot | @ | jquery.flot.js:3146
(anonymous) | @ | dashboard.js:50
(anonymous) | @ | dashboard.js:176
I have used Laraflat Commands to create post section with
title ( required )
body( required )
image (required and as an image )
then from translate i finished all translation steps ,
now if i click on post then Datatable will alert an error and the error is what is showing in the image
"Illuminate\Database\QueryException"
file
:
"/var/www/xxxxxxxxxx/laraflat/vendor/laravel/framework/src/Illuminate/Database/Connection.php"
line
:
664
message
:
"SQLSTATE[42S02]: Base table or view not found: 1146 Table 'laraflat.post' doesn't exist (SQL: select count(*) as aggregate from (select '1' as `row_count` from `post`) count_row_table)"
in create_group_role_table
I Get this error when adding new page
"ErrorException (E_ERROR)
json_decode() expects parameter 1 to be string, array given (View: site\app\Application\views\admin\page\edit.blade.php)"
the error is from the function "function getLangValue($value, $key)" in app\Application\Helpers\lang.php
Arguments
array:2 [▶
"en" => "About us"
"ar" => "About us"
]
DataTables warning: table id=dataTableBuilder - Ajax error. For more information about this error, please see http://datatables.net/tn/7
i updated a 5.4 project i've been working on for a while to 5.5 i changed composer.json to the new version
the problem is when i type the command "php artisan make:admin_model" what happens is that a normal laravel model gets created inside of 'App' folder, not the expected laraflat model files
Hello
how to Use One Language on my project ... sometimes i just need to create my project Arabic or English only
[ErrorException]
ZipArchive::extractTo(H:\laragon\www/vendor/composer/d72f5056/zizohassan-laraflat-990725a\app\Application\views\vendor\apidoc
): failed to open stream: No such file or directory
ErrorException in arrays.php line 50:
array_combine(): Both parameters should have an equal number of elements
in arrays.php line 50
at HandleExceptions->handleError(2, 'array_combine(): Both parameters should have an equal number of elements', '/home/vagrant/Code/laraflat/app/Application/Helpers/arrays.php', 50, array('array' => array('name', 'created_at', 'updated_at'), 'replacement_keys' => array('UserName')))
--------------------------------------CODE-------------------------------------------------
@extends(layoutExtend())
@section('title')
{{ adminTrans('country' , 'country') }} {{ adminTrans('home' , 'view') }}
@endsection
@section('content')
@component(layoutForm() , ['title' => adminTrans('country' , 'country') , 'model' => 'country' , 'action' => adminTrans('home' , 'view') ])
<table class="table table-bordered table-responsive table-striped">
@php
$fields = rename_keys(
removeFromArray($data['fields'] , ['id']) ,
['UserName']
);
@endphp
@foreach($fields as $key => $field)
<tr>
<th>{{ $key }}</th>
@php $type = getFileType($field , $item[$field]) @endphp
@if($type == 'File')
<td> <a href="{{ url(env('UPLOAD_PATH').'/'.$item[$field]) }}">{{ $item[$field] }}</a></td>
@elseif($type == 'Image')
<td> <img src="{{ url(env('UPLOAD_PATH').'/'.$item[$field]) }}" /></td>
@else
<td>{!! nl2br($item[$field]) !!}</td>
@endif
</tr>
@endforeach
</table>
@include('admin.country.buttons.delete' , ['id' => $item->id])
@include('admin.country.buttons.edit' , ['id' => $item->id])
@endcomponent
@endsection
Data tables warning: table id=dataTableBuilder - Ajax error.For mor information about this error, please see http://datatable.net/tn/7
great effort but i faced a little problem how do you add a new field not edit the already existing name field and what if i want to delete the name field? and do i have to add .blade file for every new field?
Can I turn this admin panel into a package and post it at LaravelArab Community
C:\Users\ehab\blog\laraflat-master>php artisan serve
PHP Warning: require(C:\Users\ehab\blog\laraflat-master\bootstrap/../vendor/aut
oload.php): failed to open stream: No such file or directory in C:\Users\ehab\bl
og\laraflat-master\bootstrap\autoload.php on line 17
Warning: require(C:\Users\ehab\blog\laraflat-master\bootstrap/../vendor/autoload
.php): failed to open stream: No such file or directory in C:\Users\ehab\blog\la
raflat-master\bootstrap\autoload.php on line 17
PHP Fatal error: require(): Failed opening required 'C:\Users\ehab\blog\larafla
t-master\bootstrap/../vendor/autoload.php' (include_path='\xampp\php\PEAR') in C
:\Users\ehab\blog\laraflat-master\bootstrap\autoload.php on line 17
Fatal error: require(): Failed opening required 'C:\Users\ehab\blog\laraflat-mas
ter\bootstrap/../vendor/autoload.php' (include_path='\xampp\php\PEAR') in C:\Use
rs\ehab\blog\laraflat-master\bootstrap\autoload.php on line 17
فى الاول حاولت
Install Form Composer
windows 7 لكن فى مشكلة مع
حملت الملفات لكن بردو مش شغال
Hi,
First I congratulate you on this marvelous work.
If I want to add another function other than CRUD in the controller with admin view,
how do I fix the permission issue , the new view and function is not related to any model
say I want to add advance search page with filters,
I tried but all the time I get back to home page when I call the route to the new function and view.
Undefined variable: items (View: C:\xampp\htdocs\laraflat2\app\Application\views\vendor\pagination\default.blade.php)
when i put this code in the view
Hi I'm having issue running git clone and installation setup. Please assist.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.