Laravel Nova. Save array in custom fieldCan Anyone Explain Laravel 5.2 Multi Auth with ExampleLaravel saving dynamic input data array in to databaseadmin-panel laravel array to string conversionsWhy does Laravel array cast sort the elements, and can it be avoided?Laravel nova overriding/setting custom value for the Fields or Has Through relationshipIntegration of bigbluebutton on Laravel nova admin dashboardLaravel Nova getting the relations in the custom Text fieldLaravel Nova: Dynamically bind fields to JSON attribute on modelLaravel Nova tool is not showing anythingDate field must cast to 'date' in Eloquent model

How to compactly explain secondary and tertiary characters without resorting to stereotypes?

Can someone clarify Hamming's notion of important problems in relation to modern academia?

Why do I get negative height?

Fair gambler's ruin problem intuition

Different meanings of こわい

Unlock My Phone! February 2018

how do we prove that a sum of two periods is still a period?

OP Amp not amplifying audio signal

What is required to make GPS signals available indoors?

What do you call someone who asks many questions?

What Exploit Are These User Agents Trying to Use?

How to show a landlord what we have in savings?

Does the Idaho Potato Commission associate potato skins with healthy eating?

Do creatures with a listed speed of "0 ft., fly 30 ft. (hover)" ever touch the ground?

Is it inappropriate for a student to attend their mentor's dissertation defense?

Venezuelan girlfriend wants to travel the USA to be with me. What is the process?

What are the G forces leaving Earth orbit?

Why is it a bad idea to hire a hitman to eliminate most corrupt politicians?

Can compressed videos be decoded back to their uncompresed original format?

Bullying boss launched a smear campaign and made me unemployable

Why were 5.25" floppy drives cheaper than 8"?

Rotate ASCII Art by 45 Degrees

How to remove border from elements in the last row?

How do I exit BASH while loop using modulus operator?



Laravel Nova. Save array in custom field


Can Anyone Explain Laravel 5.2 Multi Auth with ExampleLaravel saving dynamic input data array in to databaseadmin-panel laravel array to string conversionsWhy does Laravel array cast sort the elements, and can it be avoided?Laravel nova overriding/setting custom value for the Fields or Has Through relationshipIntegration of bigbluebutton on Laravel nova admin dashboardLaravel Nova getting the relations in the custom Text fieldLaravel Nova: Dynamically bind fields to JSON attribute on modelLaravel Nova tool is not showing anythingDate field must cast to 'date' in Eloquent model













0















I use nova.laravel.com. And I try create custom field for this admin panel for creation gallery, which save data as array ["image1.png","image2.png"].



If column in database as string (without $casts in model as array) and before - create json from array - all works good.



But I want do in model cast to native type as array:



protected $casts = [
'images' => 'array'
];


How can I save data as array, if Laravel Nova on frontend give me input, which cannot save objectarray. And save all as string.



Can I do this? Thank You.










share|improve this question



















  • 1





    Please try to reformulate your question. It's not clear what your problem is.

    – StefanG
    Mar 21 at 21:17















0















I use nova.laravel.com. And I try create custom field for this admin panel for creation gallery, which save data as array ["image1.png","image2.png"].



If column in database as string (without $casts in model as array) and before - create json from array - all works good.



But I want do in model cast to native type as array:



protected $casts = [
'images' => 'array'
];


How can I save data as array, if Laravel Nova on frontend give me input, which cannot save objectarray. And save all as string.



Can I do this? Thank You.










share|improve this question



















  • 1





    Please try to reformulate your question. It's not clear what your problem is.

    – StefanG
    Mar 21 at 21:17













0












0








0








I use nova.laravel.com. And I try create custom field for this admin panel for creation gallery, which save data as array ["image1.png","image2.png"].



If column in database as string (without $casts in model as array) and before - create json from array - all works good.



But I want do in model cast to native type as array:



protected $casts = [
'images' => 'array'
];


How can I save data as array, if Laravel Nova on frontend give me input, which cannot save objectarray. And save all as string.



Can I do this? Thank You.










share|improve this question
















I use nova.laravel.com. And I try create custom field for this admin panel for creation gallery, which save data as array ["image1.png","image2.png"].



If column in database as string (without $casts in model as array) and before - create json from array - all works good.



But I want do in model cast to native type as array:



protected $casts = [
'images' => 'array'
];


How can I save data as array, if Laravel Nova on frontend give me input, which cannot save objectarray. And save all as string.



Can I do this? Thank You.







laravel laravel-nova






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 22 at 7:14







Pavel

















asked Mar 21 at 20:40









PavelPavel

111




111







  • 1





    Please try to reformulate your question. It's not clear what your problem is.

    – StefanG
    Mar 21 at 21:17












  • 1





    Please try to reformulate your question. It's not clear what your problem is.

    – StefanG
    Mar 21 at 21:17







1




1





Please try to reformulate your question. It's not clear what your problem is.

– StefanG
Mar 21 at 21:17





Please try to reformulate your question. It's not clear what your problem is.

– StefanG
Mar 21 at 21:17












1 Answer
1






active

oldest

votes


















0














Looks like there is a package already made for this.



https://novapackages.com/packages/halimtuhu/array-images



Example usage ArrayImages::make('Images', 'images')->disk('public'),






share|improve this answer























  • This library also use JSON.stringify(app.images) I want without JSON, save as array

    – Pavel
    Mar 22 at 6:38











Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55288916%2flaravel-nova-save-array-in-custom-field%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














Looks like there is a package already made for this.



https://novapackages.com/packages/halimtuhu/array-images



Example usage ArrayImages::make('Images', 'images')->disk('public'),






share|improve this answer























  • This library also use JSON.stringify(app.images) I want without JSON, save as array

    – Pavel
    Mar 22 at 6:38















0














Looks like there is a package already made for this.



https://novapackages.com/packages/halimtuhu/array-images



Example usage ArrayImages::make('Images', 'images')->disk('public'),






share|improve this answer























  • This library also use JSON.stringify(app.images) I want without JSON, save as array

    – Pavel
    Mar 22 at 6:38













0












0








0







Looks like there is a package already made for this.



https://novapackages.com/packages/halimtuhu/array-images



Example usage ArrayImages::make('Images', 'images')->disk('public'),






share|improve this answer













Looks like there is a package already made for this.



https://novapackages.com/packages/halimtuhu/array-images



Example usage ArrayImages::make('Images', 'images')->disk('public'),







share|improve this answer












share|improve this answer



share|improve this answer










answered Mar 22 at 0:10









Matt CMatt C

52134




52134












  • This library also use JSON.stringify(app.images) I want without JSON, save as array

    – Pavel
    Mar 22 at 6:38

















  • This library also use JSON.stringify(app.images) I want without JSON, save as array

    – Pavel
    Mar 22 at 6:38
















This library also use JSON.stringify(app.images) I want without JSON, save as array

– Pavel
Mar 22 at 6:38





This library also use JSON.stringify(app.images) I want without JSON, save as array

– Pavel
Mar 22 at 6:38



















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55288916%2flaravel-nova-save-array-in-custom-field%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

Swift 4 - func physicsWorld not invoked on collision? The Next CEO of Stack OverflowHow to call Objective-C code from Swift#ifdef replacement in the Swift language@selector() in Swift?#pragma mark in Swift?Swift for loop: for index, element in array?dispatch_after - GCD in Swift?Swift Beta performance: sorting arraysSplit a String into an array in Swift?The use of Swift 3 @objc inference in Swift 4 mode is deprecated?How to optimize UITableViewCell, because my UITableView lags

Access current req object everywhere in Node.js ExpressWhy are global variables considered bad practice? (node.js)Using req & res across functionsHow do I get the path to the current script with Node.js?What is Node.js' Connect, Express and “middleware”?Node.js w/ express error handling in callbackHow to access the GET parameters after “?” in Express?Modify Node.js req object parametersAccess “app” variable inside of ExpressJS/ConnectJS middleware?Node.js Express app - request objectAngular Http Module considered middleware?Session variables in ExpressJSAdd properties to the req object in expressjs with Typescript