sonata-project / SonataAdminBundle

The missing Symfony Admin Generator
https://docs.sonata-project.org/projects/SonataAdminBundle
MIT License
2.11k stars 1.26k forks source link

Input text collection JavaScript issue #3533

Closed alzubaidi closed 8 years ago

alzubaidi commented 8 years ago

I am trying to add collection of input texts with add/delete buttons on admin block.

The problem is when I hit add button I get new 3 or 4 or even 5 new input fields instead of one!

The js function setup_collection_buttons called more than once hence attached more click events on HTML element .sonata-collection-add

Before click screenshot from 2016-01-13 13-26-25

After: screenshot from 2016-01-13 13-26-43

OskarStark commented 8 years ago

can you show the output of composer show -i ?

alzubaidi commented 8 years ago

behat/behat v2.5.5 Scenario-oriented BDD framework for PHP 5.3 behat/common-contexts v1.2.0 Commonly used contexts for Behat behat/gherkin v2.3.5 Gherkin DSL parser for PHP 5.3 behat/mink v1.7.0 Browser controller/emulator abstraction for PHP behat/mink-browserkit-driver v1.3.0 Symfony2 BrowserKit driver for Mink framework behat/mink-extension v1.3.3 Mink extension for Behat behat/mink-goutte-driver v1.2.0 Goutte driver for Mink framework behat/mink-selenium2-driver v1.3.0 Selenium2 (WebDriver) driver for Mink framework behat/transliterator v1.1.0 String transliterator cocur/slugify v1.4 Converts a string into a slug. dflydev/markdown v1.0.3 PHP Markdown & Extra doctrine/annotations v1.2.7 Docblock Annotations Parser doctrine/cache v1.6.0 Caching library offering an object-oriented API for many cache backends doctrine/collections v1.3.0 Collections Abstraction library doctrine/common v2.6.1 Common Library for Doctrine projects doctrine/data-fixtures dev-master b4213c2 Data Fixtures for all Doctrine Object Managers doctrine/dbal v2.5.3 Database Abstraction Layer doctrine/doctrine-bundle 1.6.1 Symfony DoctrineBundle doctrine/doctrine-cache-bundle 1.2.2 Symfony Bundle for Doctrine Cache doctrine/doctrine-fixtures-bundle 2.3.0 Symfony DoctrineFixturesBundle doctrine/doctrine-migrations-bundle 1.1.1 Symfony DoctrineMigrationsBundle doctrine/inflector v1.1.0 Common String Manipulations with regard to casing and singular/plural rules. doctrine/instantiator 1.0.5 A small, lightweight utility to instantiate objects in PHP without invoking their constructors doctrine/lexer v1.0.1 Base library for a lexer that can be used in Top-Down, Recursive Descent Parsers. doctrine/migrations 1.2.x-dev bffd726 Database Schema migrations using Doctrine DBAL doctrine/orm v2.4.8 Object-Relational-Mapper for PHP egeloen/ckeditor-bundle 2.5.2 Provides a CKEditor integration for your Symfony2 Project. egeloen/json-builder 1.0.3 JSON builder with escaping control for PHP 5.3+ fabpot/goutte v3.1.2 A simple PHP Web Scraper friendsofsymfony/comment-bundle dev-master c5eff3c This Bundle provides threaded comment functionality for Symfony2 applications friendsofsymfony/rest-bundle 1.5.3 This Bundle provides various tools to rapidly develop RESTful API's with Symfony2 friendsofsymfony/user-bundle v1.3.6 Symfony FOSUserBundle fzaninotto/faker v1.5.0 Faker is a PHP library that generates fake data for you. gedmo/doctrine-extensions v2.4.10 Doctrine2 behavioral extensions guzzle/guzzle v3.9.3 PHP HTTP client. This library is deprecated in favor of https://packagist.org/packages/guzzlehttp/guzzle guzzlehttp/guzzle 6.1.1 Guzzle is a PHP HTTP client library guzzlehttp/promises 1.0.3 Guzzle promises library guzzlehttp/psr7 1.2.1 PSR-7 message implementation imagine/imagine v0.6.3 Image processing for PHP 5.3 incenteev/composer-parameter-handler v2.1.2 Composer script handling your ignored parameter file instaclick/php-webdriver 1.4.3 PHP WebDriver for Selenium 2 jdorn/sql-formatter v1.2.17 a PHP SQL highlighting library jms/aop-bundle 1.2.0 Adds AOP capabilities to Symfony2 jms/cg 1.1.0 Toolset for generating PHP code jms/di-extra-bundle 1.6.0 Allows to configure dependency injection using annotations jms/metadata 1.5.1 Class/method/property metadata management in PHP jms/parser-lib 1.0.0 A library for easily creating recursive-descent parsers. jms/security-extra-bundle 1.5.2 Enhances the Symfony2 Security Component by adding several new features jms/serializer 0.16.0 Library for (de-)serializing data of any complexity; supports XML, JSON, and YAML. jms/serializer-bundle 0.13.0 Allows you to easily serialize, and deserialize data of any complexity knplabs/gaufrette v0.1.4 PHP5 library that provides a filesystem abstraction layer knplabs/knp-components 1.3.2 Knplabs component library knplabs/knp-markdown-bundle 1.2.0 Knplabs markdown bundle transforms markdown into html knplabs/knp-menu v2.1.0 An object oriented menu library knplabs/knp-menu-bundle v2.1.1 This bundle provides an integration of the KnpMenu library knplabs/knp-paginator-bundle 2.5.1 Paginator bundle for Symfony2 to automate pagination and simplify sorting and other features kriswallsmith/assetic v1.3.2 Asset Management for PHP kriswallsmith/buzz v0.15 Lightweight HTTP client michelf/php-markdown 1.6.0 PHP Markdown minttwist-dev/8na dev-master 33e244b 8NA site based on MTCF minttwist-dev/mtmenubundle dev-master 9594661 MTCF custom menu functionality for both admin and front-end areas minttwist-dev/mtthemebundle dev-master 1a73bf2 MT Custom theme monolog/monolog 1.17.2 Sends your logs to files, sockets, inboxes, databases and various web services mopa/bootstrap-bundle v3.0.0-beta3 Easy integration of twitters bootstrap into symfony2 mopa/composer-bridge v1.5.0 Symfony2 Composer Bridge nelmio/api-doc-bundle 2.11.1 Generates documentation for your REST API from annotations phpcollection/phpcollection 0.4.0 General-Purpose Collection Library for PHP phpdocumentor/reflection-docblock 2.0.4
phpoption/phpoption 1.5.0 Option Type for PHP phpspec/prophecy v1.5.0 Highly opinionated mocking framework for PHP 5.3+ phpunit/php-code-coverage 2.2.4 Library that provides collection, processing, and rendering functionality for PHP code coverage information. phpunit/php-file-iterator 1.4.1 FilterIterator implementation that filters files based on a list of suffixes. phpunit/php-text-template 1.2.1 Simple template engine. phpunit/php-timer 1.0.7 Utility class for timing phpunit/php-token-stream 1.4.8 Wrapper around PHP's tokenizer extension. phpunit/phpunit 4.8.21 The PHP Unit Testing framework. phpunit/phpunit-mock-objects 2.3.8 Mock Object library for PHPUnit psr/http-message 1.0 Common interface for HTTP messages psr/log 1.0.0 Common interface for logging libraries sebastian/comparator 1.2.0 Provides the functionality to compare PHP values for equality sebastian/diff 1.4.1 Diff implementation sebastian/environment 1.3.3 Provides functionality to handle HHVM/PHP environments sebastian/exporter 1.2.1 Provides the functionality to export PHP variables for visualization sebastian/global-state 1.1.1 Snapshotting of global state sebastian/recursion-context 1.0.2 Provides functionality to recursively process PHP variables sebastian/version 1.0.6 Library that helps with managing the version number of Git-hosted PHP projects sensio/distribution-bundle v2.3.22 The base bundle for the Symfony Distributions sensio/framework-extra-bundle v2.3.4 This bundle provides a way to configure your controllers with annotations sensio/generator-bundle v2.5.3 This bundle generates code for you simplethings/entity-audit-bundle v0.8 Audit for Doctrine Entities sonata-project/admin-bundle 2.3.7 Symfony SonataAdminBundle sonata-project/block-bundle 2.2.13 Symfony SonataBlockBundle sonata-project/cache 1.0.7 Cache library sonata-project/cache-bundle 2.2.5 This bundle provides caching services sonata-project/classification-bundle 2.2.2 Symfony SonataClassificationBundle sonata-project/comment-bundle dev-master 474a73d Symfony SonataCommentBundle sonata-project/core-bundle 2.3.10 Symfony SonataCoreBundle sonata-project/datagrid-bundle dev-master 0749e71 Symfony SonataDatagridBundle sonata-project/doctrine-extensions 1.0.2 Doctrine2 behavioral extensions sonata-project/doctrine-orm-admin-bundle 2.3.3 Symfony Sonata / Integrate Doctrine ORM into the SonataAdminBundle sonata-project/easy-extends-bundle 2.1.10 Symfony SonataEasyExtendsBundle sonata-project/exporter 1.4.1 Lightweight Exporter library sonata-project/formatter-bundle 2.3.3 Symfony SonataFormatterBundle sonata-project/google-authenticator 1.0.2 Library to integrate Google Authenticator into a PHP project sonata-project/intl-bundle 2.2.3 Symfony SonataIntlBundle sonata-project/media-bundle 2.3.3 Symfony SonataMediaBundle sonata-project/news-bundle 2.3.5 Symfony SonataNewsBundle sonata-project/notification-bundle 2.3.2 Symfony SonataNotificationBundle sonata-project/page-bundle 2.3.9 Symfony SonataPageBundle sonata-project/seo-bundle 1.1.10 Symfony SonataSeoBundle sonata-project/timeline-bundle 2.2.0 Symfony SonataTimelineBundle ~ integrate SpyTimelineBundle into Sonata sonata-project/user-bundle 2.2.4 Symfony SonataUserBundle stephpy/timeline dev-master 8b59d5b Standalone library to create timelines stephpy/timeline-bundle 2.2.0 Symfony2 bundle to make timeline stephpy/TimelineBundle dev-master e194ffb Symfony2 bundle to make timeline stof/doctrine-extensions-bundle v1.2.1 Integration of the gedmo/doctrine-extensions with Symfony2 swiftmailer/swiftmailer v5.4.1 Swiftmailer, free feature-rich PHP mailer symfony-cmf/routing 1.3.0 Extends the Symfony2 routing component for dynamic routes and chaining several routers symfony-cmf/routing-bundle 1.3.5 Symfony RoutingBundle symfony/assetic-bundle v2.7.1 Integrates Assetic into Symfony2 symfony/icu v1.2.2 Contains an excerpt of the ICU data and classes to load it. symfony/monolog-bundle v2.8.2 Symfony MonologBundle symfony/swiftmailer-bundle v2.3.9 Symfony SwiftmailerBundle symfony/symfony v2.5.0 The Symfony PHP framework twbs/bootstrap v3.0.0 Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development. twig/extensions v1.3.0 Common additional features for Twig that do not directly belong in core twig/twig v1.23.1 Twig, the flexible, fast, and secure template language for PHP willdurand/faker-bundle 1.3.0 Put the awesome Faker lib into the DIC and populate your database with fake data. willdurand/jsonp-callback-validator v1.1.0 JSONP callback validator. willdurand/negotiation 1.5.0 Content Negotiation tools for PHP provided as a standalone library.

greg0ire commented 8 years ago

Hi, sorry but as you may already know, Sonata 2 is no longer supported. Please ask us to reopen if you still experience this with Sonata 3.