https://twill.io logo
Join Discord
Powered by
# ❓questions
  • j

    jefsev

    02/03/2023, 8:52 PM
    But 😮
  • j

    jefsev

    02/03/2023, 8:52 PM
    Call to undefined method A17\Twill\TwillRoutes::singleton()
  • j

    jefsev

    02/03/2023, 8:54 PM
    Maybe something went wrong with upgrading? because also with render blocks i do: whats in the upgrade.md The renderBlocks method now by default will NOT render the nested repeaters below the block. If you relied on this you now need to update to renderBlocks([], true) And i get: A17\Twill\Helpers\BlockRenderer::render(): Argument #2
  • j

    jefsev

    02/03/2023, 8:54 PM
    Or should it be rendeBlocks(true, []) ? Nope same error
  • i

    ifox

    02/03/2023, 8:57 PM
    You're still missing Facades in that namespace
  • i

    ifox

    02/03/2023, 8:57 PM
    regarding renderBlocks, what was your code before?
  • i

    ifox

    02/03/2023, 8:58 PM
    if it was
    renderBlocks(false)
    you can remove the false
  • j

    jefsev

    02/03/2023, 8:59 PM
    Ah oke
  • j

    jefsev

    02/03/2023, 9:00 PM
    use A17\Twill\Facades\TwillRoutes; // Register Twill routes here eg. TwillRoutes::singleton("menu"); this is the code. Facades is in the namespace but the error says: Call to undefined method A17\Twill\TwillRoutes::singleton() Like Facades is not there
  • i

    ifox

    02/03/2023, 9:02 PM
    hmm that's intereting
  • i

    ifox

    02/03/2023, 9:03 PM
    https://github.com/area17/twill/blob/3.x/src/TwillRoutes.php#L331
  • i

    ifox

    02/03/2023, 9:03 PM
    it's definitely there
  • i

    ifox

    02/03/2023, 9:03 PM
    the facade is only there to let you call it statically
  • j

    jefsev

    02/03/2023, 9:04 PM
    Im on 3.0.0-beta2 That's correct?
  • j

    jefsev

    02/03/2023, 9:07 PM
    Same problem with module and group. The error message returns A17\Twill\TwillRoutes::module() without Facades.
  • j

    jefsev

    02/03/2023, 9:17 PM
    composer dump: Call to undefined method A17\Twill\TwillRoutes::singleton() at vendor/laravel/framework/src/Illuminate/Support/Facades/Facade.php:338 334▕ if (! $instance) { 335▕ throw new RuntimeException('A facade root has not been set.'); 336▕ } 337▕ ➜ 338▕ return $instance->$method(...$args); 339▕ } 340▕ } 341▕
  • j

    jefsev

    02/03/2023, 9:17 PM
    strange
  • i

    ifox

    02/03/2023, 9:54 PM
    https://github.com/area17/twill/releases/tag/3.0.0-rc3 is the latest version @jefsev
  • i

    ifox

    02/03/2023, 9:56 PM
    indeed beta2 was before the Laravel update that released their own singleton
  • i

    ifox

    02/03/2023, 9:56 PM
    so that method is not in beta2
  • i

    ifox

    02/03/2023, 10:06 PM
    so if you are staying on beta2 you don't need to use TwillRoutes, you would use the standard Laravel Route facade:
    Route::singleton
    . but if you have updated Laravel to after they released their own ::singleton, that wouldn't work.
  • i

    ifox

    02/03/2023, 10:06 PM
    TLDR: please update to rc3 and you won't have this issue
  • b

    beardcoder

    02/04/2023, 11:27 AM
    I have an problem with the slugs after the update. any changes here?
  • b

    beardcoder

    02/04/2023, 11:28 AM
    No Slugs will be generated
  • b

    beardcoder

    02/04/2023, 11:30 AM
    Oh i found the problem. the slug is only gernated in the english version not in other languages
  • b

    beardcoder

    02/04/2023, 11:33 AM
    Hmmm 😦
  • i

    ifox

    02/04/2023, 11:41 AM
    @beardcoder is this a screenshot of a form submission payload? It shows that your title field isn't translated. It would need to be to generate a translated slug.
  • b

    beardcoder

    02/04/2023, 11:41 AM
    Ah okay. yes thats right i have only one language
  • b

    beardcoder

    02/04/2023, 11:45 AM
    If i change the default language to de nothing will be generated 😦
  • b

    beardcoder

    02/04/2023, 11:47 AM
    Okay, i build the bug by my self ^^
1...460461462...484Latest