Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8023987
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T22:43:50+00:00 2026-06-04T22:43:50+00:00

I learn SonataAdminBundle with this tutorial: http://sftuts.com/doc/jobeet/en/the-admin-generator but instead of: I have empty values:

  • 0

I learn SonataAdminBundle with this tutorial:
http://sftuts.com/doc/jobeet/en/the-admin-generator

but instead of:

enter image description here

I have empty values:

enter image description here

Also in form, I have only submit button, but if I click this button then I have error:

PDOException: SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'type' cannot be null

Maybe is better tutorial for SonataAdminBundle?

EDIT:

<?php

//src/SfTuts/JobeetBundle/Admin/CategoryAdmin.php

namespace SfTuts\JobeetBundle\Admin;

use Sonata\AdminBundle\Admin\Admin;
use Sonata\AdminBundle\Form\FormMapper;
use Sonata\AdminBundle\Datagrid\DatagridMapper;
use Sonata\AdminBundle\Datagrid\ListMapper;

class CategoryAdmin extends Admin
{
    protected $list = array(
        'id' => array('identifier' => true),
        'name',
    );
    protected $form = array(
        'name',
    );
    protected $filter = array(
        'name',
    );
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T22:43:51+00:00Added an answer on June 4, 2026 at 10:43 pm

    You could read this piece of documentation. Your version of the tutorial could be outdated.
    http://sonata-project.org/bundles/admin/master/doc/index.html

    Try this code:

    use Sonata\AdminBundle\Admin;
    use Sonata\AdminBundle\Datagrid\ListMapper;
    use Sonata\AdminBundle\Datagrid\DatagridMapper;
    use Sonata\AdminBundle\Validator\ErrorElement;
    use Sonata\AdminBundle\Form\FormMapper;
    class CategoryAdmin extends Admin
    {
        /**
         * @param \Sonata\AdminBundle\Form\FormMapper $formMapper
         * @return void
         */
        protected function configureFormFields(FormMapper $formMapper)
        {
            $formMapper
                ->add('name')
                ;
        }
    
        /**
         * @param \Sonata\AdminBundle\Datagrid\DatagridMapper $datagridMapper
         * @return void
         */
        protected function configureDatagridFilters(DatagridMapper $datagridMapper)
        {
            $datagridMapper
                ->add('name');
        }
    
        /**
         * @param \Sonata\AdminBundle\Datagrid\ListMapper $listMapper
         * @return void
         */
        protected function configureListFields(ListMapper $listMapper)
        {
            $listMapper
                ->add('id')
                ->addIdentifier('name');
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I learn Symfony 2. I would like have example with SonataAdminBundle. I found: http://sonata-project.org/bundles/news/2-0/doc/reference/installation.html
i want to learn about the page flip effect like this one http://www.20thingsilearned.com/en-US Is
To learn spring MVC im using this tutorial - http://static.springsource.org/docs/Spring-MVC-step-by-step/index.html It refers to spring2.5
I am trying to learn cocos2d for iphone, following the following book http://www.apress.com/9781430233039 .
http://learn.iis.net/page.aspx/327/powershell-scripts/ CreateIISBindingOntoSite DAP1Site1 80 www.DAP1Site2.com http However I want to generate and usa a
I am trying to learn deserialization. I have written this code to deserialize *.hbm.xml
I am trying to learn to make calendar by this example . But, I
I am trying to learn about MYSQL Joins but am having trouble figuring this
I'm trying to learn more about WPF. I ran through an online tutorial that
I'm trying to learn about this feature of javascript I keep seeing in code,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.