Giter Club home page Giter Club logo

Comments (4)

jkavalik avatar jkavalik commented on July 17, 2024 1

@MartkCz I tried that already, does not work for us either, because we have createElements as a separate function call after construct, so when whenAttached() is called in this case, there is nothing in the multiplier yet. It would have to be some event after createComponent but before handleSignal/fireEvents.. No idea what that could be.

On the other hand removing $this (presenter) from the constructor seems to work fine atm. And moving createElements to constructor before parent::__construct() would be probably acceptable too as we only use the multiplier in a couple of special components and can cover that with some comments to explain the difference to other code.

from forms-multiplier.

MartkCz avatar MartkCz commented on July 17, 2024

This is old nette syntax, the correct is:

public function createComponentAbcForm() : AbcForm {
        $form = new AbcForm();
        // ...
}

from forms-multiplier.

MartkCz avatar MartkCz commented on July 17, 2024

Probably fixed by e3a337b

from forms-multiplier.

slischka avatar slischka commented on July 17, 2024

Hi there. I have same problem. The attached method is called before I am able to add create and remove button. Its called in contributte/forms-multiplier/src/Multiplier.php:516 when the multiplier is assign to the form. I have one kinda solution, but its not super sexy. https://github.com/slischka/forms-multiplier/commit/461ea71a9efb92bd64bda5d45b6e5268919b4c8d

I was thinking about to add some logic to addCreateButton but its to complex. The result would be multiple calling getHttpData etc. nad that would not be good.

from forms-multiplier.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.