GithubHelp home page GithubHelp logo

Comments (6)

Bessamu avatar Bessamu commented on August 15, 2024

And here: Whitecube\NovaFlexibleContent\Flexible line 261

$value = "[{"layout":"wysiwyg","key":"355uifo1gx77j9h8umn7w7-wysiwyg","attributes":{"355uifo1gx77j9h8umn7w7-wysiwyg__title":"asda","355uifo1gx77j9h8umn7w7-wysiwyg__body":"1231231"}}]"

from nova-flexible-content.

toonvandenbos avatar toonvandenbos commented on August 15, 2024

Hi @Bessamu,

Could you provide some more contextual information?

  • Is your Flexible field defined on a regular Resource?
  • Is your Flexible field wrapped inside another field?
  • Which version of Laravel Nova are you using?

Thank you!

from nova-flexible-content.

Bessamu avatar Bessamu commented on August 15, 2024
  • Is your Flexible field defined on a regular Resource?
    • Yes
  • Is your Flexible field wrapped inside another field?
    • No
  • Which version of Laravel Nova are you using?
    • 1.2.1

My fields method:

    public function fields(Request $request)
    {
        return [
            ID::make()->sortable()->onlyOnIndex(),
            Date::make('Дата', 'date')->sortable()->creationRules('required'),
            TextWithSlug::make('Заголовок новости', 'header')->slug('Url')
                ->creationRules('required')
                ->sortable(),
            ElementSwitch::make('Активен', 'enabled')
                ->falseLabel('Нет')
                ->trueLabel('Да')
                ->sortable(),
            Slug::make('Url', 'url'),
            Text::make('Мета Заголовок', 'meta_title')->hideFromIndex(),
            Text::make('Мета ключевые слова', 'meta_keywords')->hideFromIndex(),
            Text::make('Мета описание', 'meta_description')->hideFromIndex(),
            NovaTrumbowyg::make('Краткое описание', 'annotation')->options([
                'svgPath' => config('nova.trumbowyg_icons_path')
            ])->hideFromIndex(),
            BelongsToMany::make('Товары', 'products', ProductResource::class)->searchable(),

            Flexible::make('Содержание новости', 'body_json')
                ->addLayout('Блок с текстом', 'wysiwyg', [
                    Text::make('Заголовок', 'title'),
                    NovaTrumbowyg::make('Содержание', 'body')
                ])
                ->addLayout('Youtube видео', 'video', [
                    Text::make('Заголовок', 'title'),
                    Image::make('Video Thumbnail', 'thumbnail'),
                    Text::make('ID видео (YouTube)', 'video'),
                    Text::make('Примечание к видео', 'desc')
                ])
                ->button('Добавить блок')
        ];
    }

Thanks for help!

from nova-flexible-content.

toonvandenbos avatar toonvandenbos commented on August 15, 2024

Could you update to Nova 2.0.10 and keep me posted? Thanks!

from nova-flexible-content.

Bessamu avatar Bessamu commented on August 15, 2024

Ok, hope it will be possible for my half-legacy app

from nova-flexible-content.

toonvandenbos avatar toonvandenbos commented on August 15, 2024

Alright. I'll close this issue as we're not able to reproduce the issue with Nova 2.0.10. However, feel free to open it again if the issue remains on an up-to-date setup.

from nova-flexible-content.

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.