maldicore / admin Goto Github PK
View Code? Open in Web Editor NEWCakePHP Plugin for automagic admin using Twitter Bootstrap for CakePHP 2.x
CakePHP Plugin for automagic admin using Twitter Bootstrap for CakePHP 2.x
Good work on the plugin! I downloaded and worked great on my app automagically as you said.
I made a change to it to enable users to view HTML source when using the wysihtml5.
Just wondering, Any reason why the defaultOptions.html = false?
This is most like a feature for the plugin, How can I make to change the user password ?
I have added the User model, but the password are plain-text, they are not encrypted with md5.
I am using cakephp 2.1 and call this plugins but after logout,we are able to go through internal page.
Hello,
I want that different Groups of users can view different menu.
How can I do that?
Thanks
Ale
navbar is returning empty forever. Know the reason?
I have defined a model like
class Product extends AppModel {
public $adminSettings = array( 'icon' => 'product');
public $belongsTo = array(
'Category' => array(
'className' => 'Category',
'conditions' => array('Category.active' => 1),
'order' => 'Category.name'
)
);
}
but unfortunatly the 'conditions' or 'order' is not considered when creating a new Product.
Hi,
I am new to CakePHP so I don't know if this is the correct place to ask this question but i have tried your plugin and it works great. But I am having an issues while creating forms.
I have created DB tables as products and categories. and the categories works great. But now when i see the add products form i want it such that it has a dropdownlist(select) of all the categories inserted. Right now all i get is a input text.
I have the foreign key for the categories in the products table as well.
So how can i acheive that i.e override the view to generate the select box.
//Wilson
there is a problem with uploading files, you have to change the way that you create the form in form.ctp from:
BSForm->create($modelClass); ?>to:
BSForm->create($modelClass, array('type' => 'file')); ?>to make i t work
I have a model, called User, with the following relation(s):
class User extends AppModel {
public $hasMany = array('Forum.Access');
}
Errors:
Missing Database Table
Error: Table accesses for model Access was not found in datasource default.
Notice: If you want to customize this error message, create studentskit\View\Errors\missing_table.ctp
Stack Trace
CORE\Cake\Model\Model.php line 3179 → Model->setSource(string)
CORE\Cake\Model\Model.php line 1301 → Model->getDataSource()
CORE\Cake\Model\Model.php line 1325 → Model->schema()
APP\Model\Behavior\TimeBehavior.php line 160 → Model->getColumnTypes()
APP\Model\Behavior\TimeBehavior.php line 19 → TimeBehavior->getAllFieldsOfType(AppModel, string)
CORE\Cake\Model\BehaviorCollection.php line 148 → TimeBehavior->setup(AppModel, array)
CORE\Cake\Model\BehaviorCollection.php line 68 → BehaviorCollection->load(string, array)
CORE\Cake\Model\Model.php line 733 → BehaviorCollection->init(string, array)
CORE\Cake\Utility\ClassRegistry.php line 174 → Model->__construct(array)
APP\Plugin\Admin\Controller\AdminAppController.php line 101 → ClassRegistry::init(string)
[internal function] → AdminAppController->beforeFilter(CakeEvent)
CORE\Cake\Event\CakeEventManager.php line 246 → call_user_func(array, CakeEvent)
CORE\Cake\Controller\Controller.php line 669 → CakeEventManager->dispatch(CakeEvent)
CORE\Cake\Routing\Dispatcher.php line 183 → Controller->startupProcess()
CORE\Cake\Routing\Dispatcher.php line 161 → Dispatcher->_invoke(UsersController, CakeRequest, CakeResponse)
APP\webroot\index.php line 92 → Dispatcher->dispatch(CakeRequest, CakeResponse)
To fix that
AdminAppController.php
$subModel = ClassRegistry::init($key);
$subModel = ClassRegistry::init($value['className']);
Done.
Thank you and Good Luck with your plugin!
I've just installed the plugin and on accessing /admin, I get the following error :
Error: Call to a member function check() on a non-object
File: [[....]]/app/Plugin/Admin/Controller/AdminAppController.php
Line: 45
Does this plugin have any dependencies on other plugins? Or on any user management/authentication code being in place?
Thanks!
After installing the plugin and going to /admin, I get the following error message:
Error: Table for model was not found in datasource default.
Stack Trace
CORE\Cake\Model\Model.php line 3231 → Model->setSource(string)
APP\Plugin\Admin\Config\bootstrap.php line 65 → Model->getDataSource()
CORE\Cake\Core\CakePlugin.php line 249 → include(string)
CORE\Cake\Core\CakePlugin.php line 169 → CakePlugin::_includeFile(string, boolean)
CORE\Cake\Core\CakePlugin.php line 101 → CakePlugin::bootstrap(string)
APP\Config\bootstrap.php line 74 → CakePlugin::load(string, array)
CORE\Cake\Core\Configure.php line 93 → include(string)
CORE\Cake\bootstrap.php line 164 → Configure::bootstrap(boolean)
APP\webroot\index.php line 91 → include(string)
What exactly am I doing wrong?
EDIT: I used the following line
CakePlugin::load('Admin' ,array('bootstrap' => true));
in bootstrap.php, like you told me. If I change it to this
CakePlugin::load('Admin');
it works.
After few hours of debug, I've found that your plugin is incompatible with debug_kit - which is one of the most common plugins for Cake.
To fix that issue:
public $helpers = array(
'BSForm' => array(
'className' => 'Admin.BootstrapForm'
),
'Html',
'Session' => array(
'className' => 'Admin.BootstrapSession'
),
'Paginator' => array(
'className' => 'Admin.BootstrapPaginator'
)
);
->Form->
into ->BSForm->
Good Luck with your plugin!
I have this model:
class Subject extends AppModel {
public $name = 'Subject';
public $useTable = 'subjects';
public $primaryKey = 'subject_id';
public $actsAs = array(
'Lock',
'LanguageFilter',
'Uploader.Attachment' => array(
'videoUpload'=>array(
'uploadDir' => 'vid/subjects/about_videos/',
'appendNameToUploadDir' => true,
'name' => 'formatFileName',
'dbColumn' => 'video_source'
)
);
}
I'm usig Miles' Uploader:
http://milesj.me/code/cakephp/uploader
Error I'm getting:
Class 'Uploader' not found
Dear sir,
Please solve the problem of upload PDF file in admin panel.
Hello,
First of all thanks by your admin is super!!!
I'm trying to create a combobox in the admin to let the user select one value and I have not idea how to create this in the model:
public $validate = array(
'language' => array(
'inList' => array(
'rule' => array('inList', array('es','cat','Home','null')),
'allowEmpty' => true,
)
)
);
this works but not shows the options in Combobox to the user, only validate the result,
Do someone know how to do it????
Thanks in advance,
Simple fix. Remove the old Bootstrap CSS in lieu of
//netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/css/bootstrap-combined.min.css
My cake php version is - 2.2.4
I cant configure the Model - Fpllowing errors are shown -
Undefined variable: navbar [ROOT\plugins\Admin\View\Admin\index.ctp, line 17]
Invalid argument supplied for foreach() [ROOT\plugins\Admin\View\Admin\index.ctp, line 17]
When I add new user and select group, group select is empty,
I installed the plugin but when I go to http://domain.com/admin I received this error
Error: AdminController could not be found.
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.