Symfony

20

Solutions

34

Contributors

Symfony is a PHP web application framework for MVC applications. Symfony provides an architecture, components and tools for developers to build complex web applications faster. Symfony is aimed at building robust applications in an enterprise context by speeding up the creation and maintenance of web applications and replacing repetitive coding tasks. It has a low performance overhead used with a bytecode cache and gives developers full control over the configuration.

Share tech news, updates, or what's on your mind.

Sign up to Post

/usr/home/me/my_folder/symfony/app/cache/prod/doctrine/orm/Proxies

That Proxies folder keeps getting all it's files (they're all php entity files) deleted every time I trash cache in Symfony. This is sudden behavior, it has never done this before and I dont know what changed. Any tips?

Does this have something to do with the Doctrine ORM config file, wherever that is?

Basically we need to know why Symfony is not re-creating the populated cache folder : /usr/home/me/my_folder/symfony/app/cache/prod/doctrine/orm/Proxies
0
Become a Microsoft Certified Solutions Expert
LVL 19
Become a Microsoft Certified Solutions Expert

This course teaches how to install and configure Windows Server 2012 R2.  It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).

I installed Guzzle and  the Avalara tax client on my machine today and got the attached notices while doing so... is that "hard copies" notice something to be concerned about? It seems like its saying that it took a snapshot of those folders and if I ever change anything in the source folders from now on I need to reinstall, which obviously isn't good.
2019-06-14_13-03-46.jpg
0
I need the second to last item in the json response at the end of the code to include all the skus in each of the orders (so users can order all of that order's item's again all at once). What I have in there now only returns the sku in the last order. A preview of the current json response is embedded directly below. json
                // Organized Order Products into shipments //
                $shipments = array();
                foreach($order['order_details'] as $prod) {
            	   $grp = $dbAccessor->getShipmentGroup($prod['SKU']);
            	   if(!isset($shipments[$grp])) {
            	      $shipments[$grp] = array();  
            	   }

            	   $shipments[$grp][] = array('sku'             => $prod['SKU'],
                                              'name'            => $prod['Product'],
                                              'qty'             => $prod['qty'],
                                              'url'             => str_replace('http://www.mysite.com', '', $dbAccessor->getProductUrl($prod['SKU'])),
                                              'image_url'       => "/images/sku/small/".$dbAccessor->getSkuImage($prod['SKU']),
                                              'supplier_sku'    => $dbAccessor->getSupplierSku($prod['SKU']),
                                              'is_discontinued' => $dbAccessor->isDiscontinued($prod['SKU']),
                                              'supplier'       

Open in new window

0
I use FOS Rest Bundle with FOS user ton create registration form. The registration does not work so i tried to verify if there's an issue with my database.I've tried doctrine schema update and i receive a strange error .
[Doctrine\DBAL\Exception\DriverException]
  An exception occurred while executing 'CREATE TABLE `buyer` (id INT AUTO_INCREMENT NOT NULL, buyer_type_id INT DEFAULT NULL, country_id
   INT DEFAULT NULL, language_id INT DEFAULT NULL, first_market_region_id INT DEFAULT NULL, second_market_region_id INT DEFAULT NULL, thi
  rd_market_region_id INT DEFAULT NULL, creator_user_id INT DEFAULT NULL, modifier_user_id INT DEFAULT NULL, `name` VARCHAR(320) NOT NULL
  , `description` VARCHAR(1024) DEFAULT NULL, `main_products_services` VARCHAR(512) DEFAULT NULL, `reference_number` VARCHAR(100) DEFAULT
   NULL, `phone` VARCHAR(20) DEFAULT NULL, `fax` VARCHAR(20) DEFAULT NULL, `website` VARCHAR(100) DEFAULT NULL, `email` VARCHAR(255) DEFA
  ULT NULL, `first_name` VARCHAR(100) DEFAULT NULL, `last_name` VARCHAR(100) DEFAULT NULL, `job` VARCHAR(255) DEFAULT NULL, `picture` VAR
  CHAR(255) DEFAULT NULL, `address` VARCHAR(500) DEFAULT NULL, `zip_code` VARCHAR(10) DEFAULT NULL, `city` VARCHAR(10) DEFAULT NULL, `com
  pany_name` VARCHAR(320) DEFAULT NULL, `total_revenu` VARCHAR(100) DEFAULT NULL, `first_market_rate` INT DEFAULT NULL, `second_market_ra
  te` INT DEFAULT NULL, `third_market_rate` INT DEFAULT NULL, `is_public` TINYINT(1) NOT NULL, `views` INT DEFAULT NULL, …
0
In symfony 4 i have a form to manage user details.

There is a one-to-many relationship between User class and SecurityGroup class.

In my form i would like to have all SecurityGroup listed with checkboxes.
I've managed to do it, but if i check a checkbox the group is not added to the user after the handle request. (In the request dump i see my 2 checked groups)

Form Field:
->add('SecurityGroups', EntityType::class, [
                'class'     => 'App\Entity\SecurityGroup',
                'choice_label' => 'displayname',
                'query_builder' => function (SecurityGroupRepository $repo) {
                    return $repo->createQueryBuilder('f')
                        ->where('f.id > :id')
                        ->setParameter('id', 1);
                },
                'label'     => 'Member Of?',
                'expanded'  => true,
                'multiple'  => true,
            ])

Open in new window


Controller
public function edit(Request $request, $id)
    {

        $user = new User();

        if ($id == -1) {
            $module_title = 'Create a new User';
        }
        else
        {
            $module_title = 'Edit User';
            $user = $this->getDoctrine()->getRepository("App:User")->find($id);
        }

        $form = $this->createForm("App\Form\UserType", $user);


        $form->handleRequest($request);

        $current_user = $this->getUser();
        dump($request);
        dump($form);

        if ($form->isSubmitted() && $form->isValid())
        {

            $user = $form->getData();
            dump($user);
            
            $em = $this->getDoctrine()->getManager();
            $em->persist($user);
            $em->flush();
            $this->redirectToRoute('admin_user');
        }



        return $this->render('user/edit.html.twig', ['edit_form' => $form->createView(), 'module_title' => $module_title]);
    }

Open in new window


Dumps
Request {#86 ▼
  +attributes: ParameterBag {#70 ▶}
  +request: ParameterBag {#69 ▼
    #parameters: array:1 [▼
      "user" => array:8 [▼
        "username" => "admin"
        "email" => "email@email.email"
        "password" => ""
        "isActive" => "1"
        "DisplayName" => "admin"
        "SecurityGroups" => array:2 [▼
          0 => "2"
          1 => "4"
        ]
        "save" => ""
        "_token" => "YaqXjd73ZhrX8p1eOiFWZi1JWivaCLKMGZbulTsiRgE"
      ]
    ]
  }

Open in new window

0
Hello,

First of all sorry for my bad english! :)
I would like to make a keyword suggester with elasticsearch and symfony3.
My users want to publish a post. When they type the title of the post, it launch an ajax call at the 'focusout' of the title field.
This ajax call analyse the text and split the string at withespace. Then it launch a elastic query for each substring.
Its working but its a lot of request for nothing...
I would like to make a full text search and elastic gave me the keywords he found in the text.
For exemple:
Title: I would ike to drive a bike in the city to go see the boat.
Elastic give : 'bike', 'city', and 'boat'

Experts Exchange make this autossuggest keyword with the title.

If someone can help me :)

Thank a lot,
best regards.
Quentin,
0
We need a website for offering jobs and recruitment just like this one https://www.bayt.com
there are different ways to do that. we can develop our own frame work for it or we can use open source for the backend and maybe tamplates for the front end.
I want you to analyse this project requirements .
Please help me to find the requirements for this project.
0

Symfony

20

Solutions

34

Contributors

Symfony is a PHP web application framework for MVC applications. Symfony provides an architecture, components and tools for developers to build complex web applications faster. Symfony is aimed at building robust applications in an enterprise context by speeding up the creation and maintenance of web applications and replacing repetitive coding tasks. It has a low performance overhead used with a bytecode cache and gives developers full control over the configuration.

Top Experts In
Symfony
<
Monthly
>