Posts by LRMiloef

    Yes i allready returns the generated pdf as you descriped. that works fine.

    But what i'd like to do is to show an loading indicator to the user als long it takes to generate the pdf.

    Do you understand? So i thought i create a button, that triggers a js method that handles the download.

    So, my only problem is the js part..

    Hey,

    i need your help. Maybe someone has an idea:


    I have created an API-endpoint that renders and returns an pdf file. The pdf is generated by DomPDF.

    At the moment i just created static links with some GET-Parameters to download the Files. That is working fine so far.


    But if the files are a little bit bigger, it can take some time to generate the pdf. For that reason i'd like to call the API by vue js.

    When the user clicks the download-button, a loading indicator should appear. On receiving the response i'd like to trigger download.


    Do you have an idea how to do that with vue resource ?


    At the moment it only downloads corrupted pdf files.

    I think i found the issue... My mistake was, that i first installed the update, and $util->migrate() was not included.


    For the next try i just modified the composer.json on my server, so that i can install the update again...


    The problem is, that the number of the currently installed version seems to be stored on some other place additionaly. During the update, pagekit will use this other place to detect what version is installed. In my case that was still 1.0.1 although i changed it in composer.json. 


    I fixed it by installing version 1.0.0. When i update from that, the update-section will be called.


    So this is resolved for me now :-)

    Hey,


    yes actually i'm on version 1.0.0and want to update to 1.0.1.

    I also updated composer.json to version 1.0.1, and removed the echo stuff.


    I did not added $util->migrate() somewhere but now i have. Unfortunally it still would'nt mutatse my table... it seems that it would'nt run in the update-section of my scripts.php. For this reason it tried to echo out some stuff for debugging.

    Hey,


    i'd like to write an update for my extension. It's necessary to modify one of my tables. For that i added following snippet to my scripts.php



    My current version is 1.0.0. So if i'm right this should run my migration, right? It don't and i have really no idea why....

    Has someone any ideas?

    As i can see, App:abort() will only support these Codes:


    Code
    1. /**
    2. * @Deleting()
    3. */
    4. public static function deleting($event, Product $product)
    5. {
    6. Application::abort(500, 'My Message');
    7. }

    I figured out that this will stop deleting. :-)

    I can be so simple ;-)

    Ok.. then i think i'll prefere to hook in the Database Events.

    Maybey you can post here how to stop deleting in case of existing usages :-)

    Quote

    So if I understood correctly, you would like to avoid to delete a productCategory, while it's being used by another package, right?

    Yes, but i also like to avoid deleting when it's used in product too...
    That's only an example.. there are a lot of other tables where productCategoryis used.


    Do'nt you think it's better to use ForeignKeys to check relations?

    Hey,


    in one of my projekts i have a lot of tables.
    Some of them are related to each other.

    For example i have following entities:


    product, productCategory, package, package_productCategory


    An product can have one productCategory. An Package can contains multiple productCategories.


    Now it's important to avoid dropping a productCategory, that's used in product or/and productCategories.


    How would you do this? Should i use foreignKeys, or should i hook in the @deleting event from doctrine?

    Hey,

    when i use the v-validator i allways gets an [Vue warn]. Is there an way to avoid this warnings?


    Code
    1. <div id="app">
    2. <form v-validator="testform">
    3. <input name="text" v-model="text" v-validate:required>
    4. <p class="uk-form-help-block uk-text-danger" v-show="testform.text.invalid">INVALID</p>
    5. </form>
    6. </div>



    How would you realize this szenario?


    I need do create a website with two different themes. One theme, the "Main Theme" should be visible to all visitors of the Page. When a user with an specific role is logged in , an "Admin Template" has to be shown. It should have an own menu, an different styling, etc... Is that possible to realize?

    Hey,


    one new question:

    Is it possible to create an method in my site-controller that renders a view without the template frame arround?

    I need to generate an view without menu, footer, etc... is that possible with pagekit?