0

I'd like to reuse couple of fields I've created in ng-admin, except one specific field.

How can I manage to do that?

This is the code I'm using:

post.editionView()
        .title('Edit post "{{ entry.values.title }}"') // title() accepts a template string, which has access to the entry
        .actions(['list', 'show', 'delete']) // choose which buttons appear in the top action bar. Show is disabled by default
        .fields([
            post.creationView().fields(), //<--- I'd like to remove one field from here

Thank you,

Tommy
  • 126
  • 1
  • 6

1 Answers1

0

you can do it by passing fields to editionView also

currentInventoryItem.editionView()
            .title('Update Inventory Items')
            .fields(                
                nga.field('consume'),
                nga.field('add'),
                nga.field('price')
            )
  • right. but I'd like to find a way I won't to define all the fields over and over again... that's why I use "post.creationView().fields()", and want to specify only the fields I want to remove. – Tommy Sep 24 '16 at 09:58