KorzhCom / EasyData

Adaptive CRUD for ASP.NET Core. With EasyData you can get both API endpoints and client-side UI for all CRUD operations in a matter of minutes using just your DbContext and a few lines of code.
MIT License
594 stars 63 forks source link

Model class name and items per page #192

Open itoop2019 opened 2 months ago

itoop2019 commented 2 months ago

Hi! There are two questions.

  1. Is there a setting for the number of lines on the page (items per page)?

  2. The name of the model class (table in the database) becomes part of the address. Maybe the class has an alias so that the address can be substituted with an alias rather than the class name?

image

image

antifree commented 2 months ago

Hi @itoop2019!

  1. Yes, you can set up grid options:
    new EasyDataViewDispatcher({
    grid: {
       paging: {
        enabled: true // enable paging
        pageSize:  100 // default page size
        allowPageSizeChange: true, // add selector to change page size
        pageSizeItems: [20, 50, 100, 200] // page size options
    }
    }
    }).run()
  2. Unfortunately, there is no such possibility yet, but we can consider adding it.
itoop2019 commented 2 months ago

Many thanks, it works! I will be very grateful if you add an alias.