diff --git a/404.html b/404.html index f0370935a..9e205e944 100644 --- a/404.html +++ b/404.html @@ -15,7 +15,7 @@ - + diff --git a/assets/js/29a082d0.20fd1cee.js b/assets/js/29a082d0.20fd1cee.js deleted file mode 100644 index 2d0eab66e..000000000 --- a/assets/js/29a082d0.20fd1cee.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunkadminforth=self.webpackChunkadminforth||[]).push([[4753],{8249:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>d,contentTitle:()=>a,default:()=>u,frontMatter:()=>s,metadata:()=>o,toc:()=>l});var r=t(4848),i=t(8453);const s={},a="Standard pages tuning",o={id:"tutorial/Customization/standardPagesTuning",title:"Standard pages tuning",description:"Fields Grouping",source:"@site/docs/tutorial/03-Customization/13-standardPagesTuning.md",sourceDirName:"tutorial/03-Customization",slug:"/tutorial/Customization/standardPagesTuning",permalink:"/docs/tutorial/Customization/standardPagesTuning",draft:!1,unlisted:!1,tags:[],version:"current",sidebarPosition:13,frontMatter:{},sidebar:"tutorialSidebar",previous:{title:"Security",permalink:"/docs/tutorial/Customization/security"},next:{title:"AdminForth Components Library",permalink:"/docs/tutorial/Customization/afcl"}},d={},l=[{value:"Fields Grouping",id:"fields-grouping",level:2},{value:"List",id:"list",level:2},{value:"Default Sorting",id:"default-sorting",level:3},{value:"Page size",id:"page-size",level:3},{value:"Custom row click action",id:"custom-row-click-action",level:3},{value:"Auto-refresh records",id:"auto-refresh-records",level:3},{value:"Creating",id:"creating",level:2},{value:"Fill with default values",id:"fill-with-default-values",level:3},{value:"Link to create form with preset values",id:"link-to-create-form-with-preset-values",level:3},{value:"Editing",id:"editing",level:2}];function c(e){const n={a:"a",blockquote:"blockquote",br:"br",code:"code",h1:"h1",h2:"h2",h3:"h3",img:"img",p:"p",pre:"pre",...(0,i.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h1,{id:"standard-pages-tuning",children:"Standard pages tuning"}),"\n",(0,r.jsx)(n.h2,{id:"fields-grouping",children:"Fields Grouping"}),"\n",(0,r.jsx)(n.p,{children:'In some cases, you may want to organize data fields into specific groups for better structure and clarity. For example, you could create a "Main Info" group to include columns like title, description, country, and apartment_image. Another group, "Characteristics," could hold attributes such as price, square_meter, number_of_rooms, property_type, and listed. Any values without a specified group will be categorized under "Other."'}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:" resources: [\n {\n ...\n options: {\n ...\n //diff-add\n createEditGroups: [\n //diff-add\n {\n //diff-add\n groupName: 'Main info',\n //diff-add\n columns: ['id','title', 'description', 'country', 'apartment_image']\n //diff-add\n },\n //diff-add\n {\n //diff-add\n groupName: 'Characteristics',\n //diff-add\n columns: ['price', 'square_meter', 'number_of_rooms', \"property_type\", \"listed\"]\n //diff-add\n }\n //diff-add\n ],\n }\n }\n ]\n"})}),"\n",(0,r.jsxs)(n.p,{children:["Here is how it looks:\n",(0,r.jsx)(n.img,{alt:"alt text",src:t(5276).A+"",width:"2281",height:"1129"})]}),"\n",(0,r.jsx)(n.h2,{id:"list",children:"List"}),"\n",(0,r.jsx)(n.h3,{id:"default-sorting",children:"Default Sorting"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:"import { AdminForthSortDirections } from 'adminforth';\n\n...\n resources: [\n {\n resourceId: 'aparts',\n options: {\n//diff-add\n defaultSort: {\n//diff-add\n columnName: 'created_at',\n//diff-add\n direction: AdminForthSortDirections.ASC, \n//diff-add\n }\n }\n }\n ]\n"})}),"\n",(0,r.jsx)(n.h3,{id:"page-size",children:"Page size"}),"\n",(0,r.jsxs)(n.p,{children:["use ",(0,r.jsx)(n.code,{children:"options.listPageSize"})," to define how many records will be shown on the page"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:" resources: [\n {\n resourceId: 'aparts',\n options: {\n ...\n//diff-add\n listPageSize: 10,\n }\n }\n ]\n"})}),"\n",(0,r.jsx)(n.h3,{id:"custom-row-click-action",children:"Custom row click action"}),"\n",(0,r.jsx)(n.p,{children:"By default, when you click on a record in the list view, the show view will be opened."}),"\n",(0,r.jsxs)(n.p,{children:["You can change this behavior by using ",(0,r.jsx)(n.code,{children:"options.listTableClickUrl"}),"."]}),"\n",(0,r.jsx)(n.p,{children:"To disable any action (don't open show) return null:"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:" resources: [\n {\n resourceId: 'aparts',\n options: {\n ...\n//diff-add\n listTableClickUrl: async (record, adminUser) => null,\n }\n }\n ]\n"})}),"\n",(0,r.jsx)(n.p,{children:"To open a custom page, return URL to the custom page (can start with https://, or relative adminforth path):"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:" options: {\n ...\n//diff-add\n listTableClickUrl: async (record, adminUser) => {\n return `https://google.com/search?q=${record.name}`;\n }\n }\n"})}),"\n",(0,r.jsxs)(n.p,{children:["If you wish to open the page in a new tab, add ",(0,r.jsx)(n.code,{children:"target=_blank"})," get param to the returned URL:"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:" options: {\n ...\n//diff-add\n listTableClickUrl: async (record, adminUser) => {\n return `https://google.com/search?q=${record.name}&target=_blank`;\n }\n }\n"})}),"\n",(0,r.jsx)(n.h3,{id:"auto-refresh-records",children:"Auto-refresh records"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"options.listRowsAutoRefreshSeconds"})," might be used to silently refresh records that are loaded (no new records will be fetched if\nthey appear)"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:" resources: [\n {\n resourceId: 'aparts',\n hooks: {\n//diff-add\n list: {\n//diff-add\n afterDatasourceResponse: async ({ response }: { response: any }) => { \n//diff-add\n response.forEach((r: any) => {\n//diff-add\n // substitute random country on any load\n//diff-add\n const countries = [ 'US', 'DE', 'FR', 'GB', 'NL', 'IT', 'ES', 'DK', 'PL', 'UA', \n//diff-add\n 'CA', 'AU', 'BR', 'JP', 'CN', 'IN', 'KR', 'TR', 'MX', 'ID']\n//diff-add\n r.country = countries[Math.floor(Math.random() * countries.length)];\n//diff-add\n })\n//diff-add\n return { ok: true, error: \"\" }\n//diff-add\n }\n//diff-add\n }\n },\n options: {\n ...\n//diff-add\n listRowsAutoRefreshSeconds: 1,\n }\n }\n ]\n"})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.img,{alt:"alt text",src:t(8481).A+"",width:"1999",height:"1499"})}),"\n",(0,r.jsx)(n.h2,{id:"creating",children:"Creating"}),"\n",(0,r.jsx)(n.h3,{id:"fill-with-default-values",children:"Fill with default values"}),"\n",(0,r.jsx)(n.p,{children:"Sometimes you want to generate some field value without asking user to fill it. For example createdAt oftenly store time of creation of the record. You can do this by using fillOnCreate:"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts" ',children:"\nnew AdminForth({\n ...\n resources: [\n {\n name: 'apartments',\n fields: [\n ...\n {\n name: 'created_at',\n type: AdminForthDataTypes.DATETIME,\n//diff-add\n fillOnCreate: ({ initialRecord, adminUser }) => (new Date()).toISOString(),\n },\n ],\n },\n ...\n ],\n"})}),"\n",(0,r.jsx)(n.p,{children:"Also you can assign adminUser ID by adminUser.dbUser.id in same hook:"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-typescript",metastring:'title="./resources/apartments.ts"',children:"new AdminForth({\n ...\n resources: [\n {\n name: 'apartments',\n fields: [\n ...\n {\n name: 'created_by',\n type: AdminForthDataTypes.STRING,\n//diff-add\n fillOnCreate: ({ initialRecord, adminUser }) => adminUser.dbUser.id,\n },\n ],\n },\n ...\n ],\n"})}),"\n",(0,r.jsxs)(n.blockquote,{children:["\n",(0,r.jsxs)(n.p,{children:["Same effect can be achieved by using ",(0,r.jsx)(n.a,{href:"/docs/tutorial/Customization/hooks/#modify-the-data-before-it-is-saved-to-the-database",children:"hooks"}),". But ",(0,r.jsx)(n.code,{children:"fillOnCreate"})," might be shorter and more readable."]}),"\n"]}),"\n",(0,r.jsx)(n.h3,{id:"link-to-create-form-with-preset-values",children:"Link to create form with preset values"}),"\n",(0,r.jsx)(n.p,{children:"Sometimes you might need to create a link that will open the create form with some fields pre-filled. For example, you might want to create a link that will open the create form with the realtor_id field pre-filled with the current user's ID."}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-html",metastring:'title="./resources/Dashboard.vue',children:"\n\n - + diff --git a/blog/archive/index.html b/blog/archive/index.html index bccf4f538..5a2725962 100644 --- a/blog/archive/index.html +++ b/blog/archive/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/chatgpt-plugin/index.html b/blog/chatgpt-plugin/index.html index f7f400fc3..5060866e7 100644 --- a/blog/chatgpt-plugin/index.html +++ b/blog/chatgpt-plugin/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/compose-ec2-deployment-github-actions/index.html b/blog/compose-ec2-deployment-github-actions/index.html index 843c6150d..f499a4e59 100644 --- a/blog/compose-ec2-deployment-github-actions/index.html +++ b/blog/compose-ec2-deployment-github-actions/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/compose-ec2-deployment/index.html b/blog/compose-ec2-deployment/index.html index 4ebfbfcb9..c7d265ecc 100644 --- a/blog/compose-ec2-deployment/index.html +++ b/blog/compose-ec2-deployment/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/index.html b/blog/index.html index 6eec82947..9066802b3 100644 --- a/blog/index.html +++ b/blog/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/tags/aws/index.html b/blog/tags/aws/index.html index 0f2a479ed..d4ad5a2ef 100644 --- a/blog/tags/aws/index.html +++ b/blog/tags/aws/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/tags/chatgpt/index.html b/blog/tags/chatgpt/index.html index 072e2e03d..b5179cec3 100644 --- a/blog/tags/chatgpt/index.html +++ b/blog/tags/chatgpt/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/tags/github-actions/index.html b/blog/tags/github-actions/index.html index f5323294b..cc40446bf 100644 --- a/blog/tags/github-actions/index.html +++ b/blog/tags/github-actions/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/tags/index.html b/blog/tags/index.html index 2dcf89ea4..cabde13d9 100644 --- a/blog/tags/index.html +++ b/blog/tags/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/tags/nuxt/index.html b/blog/tags/nuxt/index.html index 431884da3..993c199c8 100644 --- a/blog/tags/nuxt/index.html +++ b/blog/tags/nuxt/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/tags/plugin/index.html b/blog/tags/plugin/index.html index df9f91c8a..40f61bd11 100644 --- a/blog/tags/plugin/index.html +++ b/blog/tags/plugin/index.html @@ -15,7 +15,7 @@ - + diff --git a/blog/tags/terraform/index.html b/blog/tags/terraform/index.html index 605bae82d..7dada4e4b 100644 --- a/blog/tags/terraform/index.html +++ b/blog/tags/terraform/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/index.html b/docs/api/index.html index 427b12aae..94eba7801 100644 --- a/docs/api/index.html +++ b/docs/api/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/classes/Filters/index.html b/docs/api/types/Back/classes/Filters/index.html index 4245f3c1e..2ef514762 100644 --- a/docs/api/types/Back/classes/Filters/index.html +++ b/docs/api/types/Back/classes/Filters/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/classes/Sorts/index.html b/docs/api/types/Back/classes/Sorts/index.html index 938663260..7049e4753 100644 --- a/docs/api/types/Back/classes/Sorts/index.html +++ b/docs/api/types/Back/classes/Sorts/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/index.html b/docs/api/types/Back/index.html index 2f0786ea1..0aebaacdf 100644 --- a/docs/api/types/Back/index.html +++ b/docs/api/types/Back/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthBulkAction/index.html b/docs/api/types/Back/interfaces/AdminForthBulkAction/index.html index 8a5d54efb..6312e4b82 100644 --- a/docs/api/types/Back/interfaces/AdminForthBulkAction/index.html +++ b/docs/api/types/Back/interfaces/AdminForthBulkAction/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthConfig/index.html b/docs/api/types/Back/interfaces/AdminForthConfig/index.html index 6b18c7884..85fa97065 100644 --- a/docs/api/types/Back/interfaces/AdminForthConfig/index.html +++ b/docs/api/types/Back/interfaces/AdminForthConfig/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthConfigCustomization/index.html b/docs/api/types/Back/interfaces/AdminForthConfigCustomization/index.html index 181a5d570..ae2c80407 100644 --- a/docs/api/types/Back/interfaces/AdminForthConfigCustomization/index.html +++ b/docs/api/types/Back/interfaces/AdminForthConfigCustomization/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthForeignResource/index.html b/docs/api/types/Back/interfaces/AdminForthForeignResource/index.html index e9d158367..792c0fc7d 100644 --- a/docs/api/types/Back/interfaces/AdminForthForeignResource/index.html +++ b/docs/api/types/Back/interfaces/AdminForthForeignResource/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthInputConfig/index.html b/docs/api/types/Back/interfaces/AdminForthInputConfig/index.html index 8f9fcbcc4..8a73b5381 100644 --- a/docs/api/types/Back/interfaces/AdminForthInputConfig/index.html +++ b/docs/api/types/Back/interfaces/AdminForthInputConfig/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthResource/index.html b/docs/api/types/Back/interfaces/AdminForthResource/index.html index 9f086c067..14176b7f6 100644 --- a/docs/api/types/Back/interfaces/AdminForthResource/index.html +++ b/docs/api/types/Back/interfaces/AdminForthResource/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthResourceColumn/index.html b/docs/api/types/Back/interfaces/AdminForthResourceColumn/index.html index a4e8c23ab..9f572c572 100644 --- a/docs/api/types/Back/interfaces/AdminForthResourceColumn/index.html +++ b/docs/api/types/Back/interfaces/AdminForthResourceColumn/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/AdminForthResourceInput/index.html b/docs/api/types/Back/interfaces/AdminForthResourceInput/index.html index 45ef57de9..6bc693a0f 100644 --- a/docs/api/types/Back/interfaces/AdminForthResourceInput/index.html +++ b/docs/api/types/Back/interfaces/AdminForthResourceInput/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/HttpExtra/index.html b/docs/api/types/Back/interfaces/HttpExtra/index.html index 2e4594b80..97c77c6ae 100644 --- a/docs/api/types/Back/interfaces/HttpExtra/index.html +++ b/docs/api/types/Back/interfaces/HttpExtra/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForth/index.html b/docs/api/types/Back/interfaces/IAdminForth/index.html index a818a5042..e2cba0efc 100644 --- a/docs/api/types/Back/interfaces/IAdminForth/index.html +++ b/docs/api/types/Back/interfaces/IAdminForth/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthAuth/index.html b/docs/api/types/Back/interfaces/IAdminForthAuth/index.html index 811f471a6..6ce12a3f1 100644 --- a/docs/api/types/Back/interfaces/IAdminForthAuth/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthAuth/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthDataSourceConnector/index.html b/docs/api/types/Back/interfaces/IAdminForthDataSourceConnector/index.html index 6b8fa834f..c8208add8 100644 --- a/docs/api/types/Back/interfaces/IAdminForthDataSourceConnector/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthDataSourceConnector/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorBase/index.html b/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorBase/index.html index b69ecf0fb..3a9e4efe7 100644 --- a/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorBase/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorBase/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorConstructor/index.html b/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorConstructor/index.html index a27584091..a69b47964 100644 --- a/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorConstructor/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthDataSourceConnectorConstructor/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthFilter/index.html b/docs/api/types/Back/interfaces/IAdminForthFilter/index.html index 17ce27a2f..7e97c7a65 100644 --- a/docs/api/types/Back/interfaces/IAdminForthFilter/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthFilter/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthHttpResponse/index.html b/docs/api/types/Back/interfaces/IAdminForthHttpResponse/index.html index e90177372..d14ebdce6 100644 --- a/docs/api/types/Back/interfaces/IAdminForthHttpResponse/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthHttpResponse/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthPlugin/index.html b/docs/api/types/Back/interfaces/IAdminForthPlugin/index.html index ad56eb259..2430dd2ea 100644 --- a/docs/api/types/Back/interfaces/IAdminForthPlugin/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthPlugin/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthRestAPI/index.html b/docs/api/types/Back/interfaces/IAdminForthRestAPI/index.html index 44c155799..587850ac6 100644 --- a/docs/api/types/Back/interfaces/IAdminForthRestAPI/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthRestAPI/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IAdminForthSort/index.html b/docs/api/types/Back/interfaces/IAdminForthSort/index.html index c28f290a3..1da062c32 100644 --- a/docs/api/types/Back/interfaces/IAdminForthSort/index.html +++ b/docs/api/types/Back/interfaces/IAdminForthSort/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/ICodeInjector/index.html b/docs/api/types/Back/interfaces/ICodeInjector/index.html index f76ab7f1c..3cc76db63 100644 --- a/docs/api/types/Back/interfaces/ICodeInjector/index.html +++ b/docs/api/types/Back/interfaces/ICodeInjector/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IConfigValidator/index.html b/docs/api/types/Back/interfaces/IConfigValidator/index.html index 5aeca85da..5f975bc81 100644 --- a/docs/api/types/Back/interfaces/IConfigValidator/index.html +++ b/docs/api/types/Back/interfaces/IConfigValidator/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IExpressHttpServer/index.html b/docs/api/types/Back/interfaces/IExpressHttpServer/index.html index df3967534..d3c623be8 100644 --- a/docs/api/types/Back/interfaces/IExpressHttpServer/index.html +++ b/docs/api/types/Back/interfaces/IExpressHttpServer/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IHttpServer/index.html b/docs/api/types/Back/interfaces/IHttpServer/index.html index bfc996a08..06fe4965f 100644 --- a/docs/api/types/Back/interfaces/IHttpServer/index.html +++ b/docs/api/types/Back/interfaces/IHttpServer/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IOperationalResource/index.html b/docs/api/types/Back/interfaces/IOperationalResource/index.html index ff718f26b..c94fd2d6c 100644 --- a/docs/api/types/Back/interfaces/IOperationalResource/index.html +++ b/docs/api/types/Back/interfaces/IOperationalResource/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IWebSocketBroker/index.html b/docs/api/types/Back/interfaces/IWebSocketBroker/index.html index bb6c9df1d..cb04a2c37 100644 --- a/docs/api/types/Back/interfaces/IWebSocketBroker/index.html +++ b/docs/api/types/Back/interfaces/IWebSocketBroker/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/IWebSocketClient/index.html b/docs/api/types/Back/interfaces/IWebSocketClient/index.html index 5f136fb81..ad3a2c821 100644 --- a/docs/api/types/Back/interfaces/IWebSocketClient/index.html +++ b/docs/api/types/Back/interfaces/IWebSocketClient/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/ResourceOptions/index.html b/docs/api/types/Back/interfaces/ResourceOptions/index.html index ae3d450ff..1ed34002c 100644 --- a/docs/api/types/Back/interfaces/ResourceOptions/index.html +++ b/docs/api/types/Back/interfaces/ResourceOptions/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/interfaces/ResourceOptionsInput/index.html b/docs/api/types/Back/interfaces/ResourceOptionsInput/index.html index ffecf1fcc..ed0723912 100644 --- a/docs/api/types/Back/interfaces/ResourceOptionsInput/index.html +++ b/docs/api/types/Back/interfaces/ResourceOptionsInput/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/AdminForthDataSource/index.html b/docs/api/types/Back/type-aliases/AdminForthDataSource/index.html index e46de4fc5..0edd4399f 100644 --- a/docs/api/types/Back/type-aliases/AdminForthDataSource/index.html +++ b/docs/api/types/Back/type-aliases/AdminForthDataSource/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/AfterDataSourceResponseFunction/index.html b/docs/api/types/Back/type-aliases/AfterDataSourceResponseFunction/index.html index 54a149acc..131cac02a 100644 --- a/docs/api/types/Back/type-aliases/AfterDataSourceResponseFunction/index.html +++ b/docs/api/types/Back/type-aliases/AfterDataSourceResponseFunction/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/AfterSaveFunction/index.html b/docs/api/types/Back/type-aliases/AfterSaveFunction/index.html index c2b9edab5..cfd4d2a54 100644 --- a/docs/api/types/Back/type-aliases/AfterSaveFunction/index.html +++ b/docs/api/types/Back/type-aliases/AfterSaveFunction/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/AllowedActionValue/index.html b/docs/api/types/Back/type-aliases/AllowedActionValue/index.html index 8c9e1cfb4..9298b54c1 100644 --- a/docs/api/types/Back/type-aliases/AllowedActionValue/index.html +++ b/docs/api/types/Back/type-aliases/AllowedActionValue/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/AllowedActions/index.html b/docs/api/types/Back/type-aliases/AllowedActions/index.html index 0f66734fe..a4254e45b 100644 --- a/docs/api/types/Back/type-aliases/AllowedActions/index.html +++ b/docs/api/types/Back/type-aliases/AllowedActions/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/AllowedActionsInput/index.html b/docs/api/types/Back/type-aliases/AllowedActionsInput/index.html index d6e75cf5b..5d112cf14 100644 --- a/docs/api/types/Back/type-aliases/AllowedActionsInput/index.html +++ b/docs/api/types/Back/type-aliases/AllowedActionsInput/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/BeforeDataSourceRequestFunction/index.html b/docs/api/types/Back/type-aliases/BeforeDataSourceRequestFunction/index.html index e8fba85ad..b32999623 100644 --- a/docs/api/types/Back/type-aliases/BeforeDataSourceRequestFunction/index.html +++ b/docs/api/types/Back/type-aliases/BeforeDataSourceRequestFunction/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/BeforeLoginConfirmationFunction/index.html b/docs/api/types/Back/type-aliases/BeforeLoginConfirmationFunction/index.html index 7104353bb..ef321d897 100644 --- a/docs/api/types/Back/type-aliases/BeforeLoginConfirmationFunction/index.html +++ b/docs/api/types/Back/type-aliases/BeforeLoginConfirmationFunction/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/BeforeSaveFunction/index.html b/docs/api/types/Back/type-aliases/BeforeSaveFunction/index.html index e88e19d4d..9884a0f68 100644 --- a/docs/api/types/Back/type-aliases/BeforeSaveFunction/index.html +++ b/docs/api/types/Back/type-aliases/BeforeSaveFunction/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/FDataFilter/index.html b/docs/api/types/Back/type-aliases/FDataFilter/index.html index 0db6b9764..c63817a67 100644 --- a/docs/api/types/Back/type-aliases/FDataFilter/index.html +++ b/docs/api/types/Back/type-aliases/FDataFilter/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Back/type-aliases/FDataSort/index.html b/docs/api/types/Back/type-aliases/FDataSort/index.html index 632bd9f3f..c1f48660e 100644 --- a/docs/api/types/Back/type-aliases/FDataSort/index.html +++ b/docs/api/types/Back/type-aliases/FDataSort/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/enumerations/ActionCheckSource/index.html b/docs/api/types/Common/enumerations/ActionCheckSource/index.html index 64b6b70bd..189eb1b5b 100644 --- a/docs/api/types/Common/enumerations/ActionCheckSource/index.html +++ b/docs/api/types/Common/enumerations/ActionCheckSource/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/enumerations/AdminForthDataTypes/index.html b/docs/api/types/Common/enumerations/AdminForthDataTypes/index.html index 49e4517de..3ddb6cad2 100644 --- a/docs/api/types/Common/enumerations/AdminForthDataTypes/index.html +++ b/docs/api/types/Common/enumerations/AdminForthDataTypes/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/enumerations/AdminForthFilterOperators/index.html b/docs/api/types/Common/enumerations/AdminForthFilterOperators/index.html index 7786663f9..1931d28ab 100644 --- a/docs/api/types/Common/enumerations/AdminForthFilterOperators/index.html +++ b/docs/api/types/Common/enumerations/AdminForthFilterOperators/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/enumerations/AdminForthMenuTypes/index.html b/docs/api/types/Common/enumerations/AdminForthMenuTypes/index.html index da0143119..b93430be5 100644 --- a/docs/api/types/Common/enumerations/AdminForthMenuTypes/index.html +++ b/docs/api/types/Common/enumerations/AdminForthMenuTypes/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/enumerations/AdminForthResourcePages/index.html b/docs/api/types/Common/enumerations/AdminForthResourcePages/index.html index 1f14b784e..6ed60f2f6 100644 --- a/docs/api/types/Common/enumerations/AdminForthResourcePages/index.html +++ b/docs/api/types/Common/enumerations/AdminForthResourcePages/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/enumerations/AdminForthSortDirections/index.html b/docs/api/types/Common/enumerations/AdminForthSortDirections/index.html index 76eb100fa..ff4b4b8bd 100644 --- a/docs/api/types/Common/enumerations/AdminForthSortDirections/index.html +++ b/docs/api/types/Common/enumerations/AdminForthSortDirections/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/enumerations/AllowedActionsEnum/index.html b/docs/api/types/Common/enumerations/AllowedActionsEnum/index.html index 696909b8a..5a8eb7c03 100644 --- a/docs/api/types/Common/enumerations/AllowedActionsEnum/index.html +++ b/docs/api/types/Common/enumerations/AllowedActionsEnum/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/index.html b/docs/api/types/Common/index.html index 17a29de2e..ef9ccd610 100644 --- a/docs/api/types/Common/index.html +++ b/docs/api/types/Common/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthBulkActionCommon/index.html b/docs/api/types/Common/interfaces/AdminForthBulkActionCommon/index.html index 928e8b9df..61ce44473 100644 --- a/docs/api/types/Common/interfaces/AdminForthBulkActionCommon/index.html +++ b/docs/api/types/Common/interfaces/AdminForthBulkActionCommon/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthColumnEnumItem/index.html b/docs/api/types/Common/interfaces/AdminForthColumnEnumItem/index.html index b694b4036..0bbcf92a0 100644 --- a/docs/api/types/Common/interfaces/AdminForthColumnEnumItem/index.html +++ b/docs/api/types/Common/interfaces/AdminForthColumnEnumItem/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthComponentDeclarationFull/index.html b/docs/api/types/Common/interfaces/AdminForthComponentDeclarationFull/index.html index 3f476d5a4..eeaf3e4f1 100644 --- a/docs/api/types/Common/interfaces/AdminForthComponentDeclarationFull/index.html +++ b/docs/api/types/Common/interfaces/AdminForthComponentDeclarationFull/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthConfigForFrontend/index.html b/docs/api/types/Common/interfaces/AdminForthConfigForFrontend/index.html index 798a14ebb..39bb5371d 100644 --- a/docs/api/types/Common/interfaces/AdminForthConfigForFrontend/index.html +++ b/docs/api/types/Common/interfaces/AdminForthConfigForFrontend/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthConfigMenuItem/index.html b/docs/api/types/Common/interfaces/AdminForthConfigMenuItem/index.html index f58df87f3..02ce81110 100644 --- a/docs/api/types/Common/interfaces/AdminForthConfigMenuItem/index.html +++ b/docs/api/types/Common/interfaces/AdminForthConfigMenuItem/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthFieldComponents/index.html b/docs/api/types/Common/interfaces/AdminForthFieldComponents/index.html index 3cf4ef543..33adb2970 100644 --- a/docs/api/types/Common/interfaces/AdminForthFieldComponents/index.html +++ b/docs/api/types/Common/interfaces/AdminForthFieldComponents/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthForeignResourceCommon/index.html b/docs/api/types/Common/interfaces/AdminForthForeignResourceCommon/index.html index a1b461f0f..516cf945b 100644 --- a/docs/api/types/Common/interfaces/AdminForthForeignResourceCommon/index.html +++ b/docs/api/types/Common/interfaces/AdminForthForeignResourceCommon/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthResourceColumnCommon/index.html b/docs/api/types/Common/interfaces/AdminForthResourceColumnCommon/index.html index 87b1289e6..402d74e8f 100644 --- a/docs/api/types/Common/interfaces/AdminForthResourceColumnCommon/index.html +++ b/docs/api/types/Common/interfaces/AdminForthResourceColumnCommon/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthResourceColumnInputCommon/index.html b/docs/api/types/Common/interfaces/AdminForthResourceColumnInputCommon/index.html index de92dbbdd..d8fb9b1f1 100644 --- a/docs/api/types/Common/interfaces/AdminForthResourceColumnInputCommon/index.html +++ b/docs/api/types/Common/interfaces/AdminForthResourceColumnInputCommon/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthResourceCommon/index.html b/docs/api/types/Common/interfaces/AdminForthResourceCommon/index.html index fbb444172..19b9cb9fb 100644 --- a/docs/api/types/Common/interfaces/AdminForthResourceCommon/index.html +++ b/docs/api/types/Common/interfaces/AdminForthResourceCommon/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminForthResourceInputCommon/index.html b/docs/api/types/Common/interfaces/AdminForthResourceInputCommon/index.html index 1133ee6c9..b1010ecc4 100644 --- a/docs/api/types/Common/interfaces/AdminForthResourceInputCommon/index.html +++ b/docs/api/types/Common/interfaces/AdminForthResourceInputCommon/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/AdminUser/index.html b/docs/api/types/Common/interfaces/AdminUser/index.html index 74892864b..ac3c28a9e 100644 --- a/docs/api/types/Common/interfaces/AdminUser/index.html +++ b/docs/api/types/Common/interfaces/AdminUser/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/GetBaseConfigResponse/index.html b/docs/api/types/Common/interfaces/GetBaseConfigResponse/index.html index 3cdf82ce4..1d9a117b8 100644 --- a/docs/api/types/Common/interfaces/GetBaseConfigResponse/index.html +++ b/docs/api/types/Common/interfaces/GetBaseConfigResponse/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/ResourceVeryShort/index.html b/docs/api/types/Common/interfaces/ResourceVeryShort/index.html index 73dcc0d15..511f7a1d1 100644 --- a/docs/api/types/Common/interfaces/ResourceVeryShort/index.html +++ b/docs/api/types/Common/interfaces/ResourceVeryShort/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/interfaces/UserData/index.html b/docs/api/types/Common/interfaces/UserData/index.html index dce2482c3..ddb7bc2e9 100644 --- a/docs/api/types/Common/interfaces/UserData/index.html +++ b/docs/api/types/Common/interfaces/UserData/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/type-aliases/AdminForthComponentDeclaration/index.html b/docs/api/types/Common/type-aliases/AdminForthComponentDeclaration/index.html index 45bcded8d..9b383ea46 100644 --- a/docs/api/types/Common/type-aliases/AdminForthComponentDeclaration/index.html +++ b/docs/api/types/Common/type-aliases/AdminForthComponentDeclaration/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/type-aliases/AllowedActionsResolved/index.html b/docs/api/types/Common/type-aliases/AllowedActionsResolved/index.html index 1872d9fde..e51f83554 100644 --- a/docs/api/types/Common/type-aliases/AllowedActionsResolved/index.html +++ b/docs/api/types/Common/type-aliases/AllowedActionsResolved/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/type-aliases/AnnouncementBadgeResponse/index.html b/docs/api/types/Common/type-aliases/AnnouncementBadgeResponse/index.html index d19253012..f9dcb14de 100644 --- a/docs/api/types/Common/type-aliases/AnnouncementBadgeResponse/index.html +++ b/docs/api/types/Common/type-aliases/AnnouncementBadgeResponse/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/Common/type-aliases/ValidationObject/index.html b/docs/api/types/Common/type-aliases/ValidationObject/index.html index 3b550eca2..80c41f34d 100644 --- a/docs/api/types/Common/type-aliases/ValidationObject/index.html +++ b/docs/api/types/Common/type-aliases/ValidationObject/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/FrontendAPI/enumerations/AlertVariant/index.html b/docs/api/types/FrontendAPI/enumerations/AlertVariant/index.html index fd03d85ad..819f96ce6 100644 --- a/docs/api/types/FrontendAPI/enumerations/AlertVariant/index.html +++ b/docs/api/types/FrontendAPI/enumerations/AlertVariant/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/FrontendAPI/index.html b/docs/api/types/FrontendAPI/index.html index 94b0e9432..8bf448be5 100644 --- a/docs/api/types/FrontendAPI/index.html +++ b/docs/api/types/FrontendAPI/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/FrontendAPI/interfaces/FrontendAPIInterface/index.html b/docs/api/types/FrontendAPI/interfaces/FrontendAPIInterface/index.html index f1c6e78b3..722a6e547 100644 --- a/docs/api/types/FrontendAPI/interfaces/FrontendAPIInterface/index.html +++ b/docs/api/types/FrontendAPI/interfaces/FrontendAPIInterface/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/FrontendAPI/type-aliases/AlertParams/index.html b/docs/api/types/FrontendAPI/type-aliases/AlertParams/index.html index 643f71956..a20b19cfb 100644 --- a/docs/api/types/FrontendAPI/type-aliases/AlertParams/index.html +++ b/docs/api/types/FrontendAPI/type-aliases/AlertParams/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/api/types/FrontendAPI/type-aliases/ConfirmParams/index.html b/docs/api/types/FrontendAPI/type-aliases/ConfirmParams/index.html index 4d1eedd62..2d2ae921e 100644 --- a/docs/api/types/FrontendAPI/type-aliases/ConfirmParams/index.html +++ b/docs/api/types/FrontendAPI/type-aliases/ConfirmParams/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Advanced/plugin-development/index.html b/docs/tutorial/Advanced/plugin-development/index.html index 80c740d05..b2fcd6aa6 100644 --- a/docs/tutorial/Advanced/plugin-development/index.html +++ b/docs/tutorial/Advanced/plugin-development/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/afcl/index.html b/docs/tutorial/Customization/afcl/index.html index 5d27c4ba1..6b15ba758 100644 --- a/docs/tutorial/Customization/afcl/index.html +++ b/docs/tutorial/Customization/afcl/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/alert/index.html b/docs/tutorial/Customization/alert/index.html index 65d218391..5d2a6ad06 100644 --- a/docs/tutorial/Customization/alert/index.html +++ b/docs/tutorial/Customization/alert/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/branding/index.html b/docs/tutorial/Customization/branding/index.html index 4bca2cd48..2dcc3adef 100644 --- a/docs/tutorial/Customization/branding/index.html +++ b/docs/tutorial/Customization/branding/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/bulkActions/index.html b/docs/tutorial/Customization/bulkActions/index.html index 79ed39888..6618c4b22 100644 --- a/docs/tutorial/Customization/bulkActions/index.html +++ b/docs/tutorial/Customization/bulkActions/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/customFieldRendering/index.html b/docs/tutorial/Customization/customFieldRendering/index.html index 557caa38b..760f3401a 100644 --- a/docs/tutorial/Customization/customFieldRendering/index.html +++ b/docs/tutorial/Customization/customFieldRendering/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/customPages/index.html b/docs/tutorial/Customization/customPages/index.html index 6fea2a266..fa90ff1ea 100644 --- a/docs/tutorial/Customization/customPages/index.html +++ b/docs/tutorial/Customization/customPages/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/dataApi/index.html b/docs/tutorial/Customization/dataApi/index.html index 265cb7d8a..17b800671 100644 --- a/docs/tutorial/Customization/dataApi/index.html +++ b/docs/tutorial/Customization/dataApi/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/hooks/index.html b/docs/tutorial/Customization/hooks/index.html index 57fec9826..b0bb3ad16 100644 --- a/docs/tutorial/Customization/hooks/index.html +++ b/docs/tutorial/Customization/hooks/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/limitingAccess/index.html b/docs/tutorial/Customization/limitingAccess/index.html index 47116c086..f5ce7400d 100644 --- a/docs/tutorial/Customization/limitingAccess/index.html +++ b/docs/tutorial/Customization/limitingAccess/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/menuConfiguration/index.html b/docs/tutorial/Customization/menuConfiguration/index.html index 79e9901f0..418ef1f4c 100644 --- a/docs/tutorial/Customization/menuConfiguration/index.html +++ b/docs/tutorial/Customization/menuConfiguration/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/pageInjections/index.html b/docs/tutorial/Customization/pageInjections/index.html index 81d3f8071..fea7c0c35 100644 --- a/docs/tutorial/Customization/pageInjections/index.html +++ b/docs/tutorial/Customization/pageInjections/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/security/index.html b/docs/tutorial/Customization/security/index.html index dcd1e349d..7b0079df2 100644 --- a/docs/tutorial/Customization/security/index.html +++ b/docs/tutorial/Customization/security/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/standardPagesTuning/index.html b/docs/tutorial/Customization/standardPagesTuning/index.html index 00e297c86..f582b59e1 100644 --- a/docs/tutorial/Customization/standardPagesTuning/index.html +++ b/docs/tutorial/Customization/standardPagesTuning/index.html @@ -15,27 +15,27 @@ - +
Skip to main content

Standard pages tuning

Fields Grouping

In some cases, you may want to organize data fields into specific groups for better structure and clarity. For example, you could create a "Main Info" group to include columns like title, description, country, and apartment_image. Another group, "Characteristics," could hold attributes such as price, square_meter, number_of_rooms, property_type, and listed. Any values without a specified group will be categorized under "Other."

-
./resources/apartments.ts
 resources: [
{
...
options: {
...
createEditGroups: [
{
groupName: 'Main info',
columns: ['id','title', 'description', 'country', 'apartment_image']
},
{
groupName: 'Characteristics',
columns: ['price', 'square_meter', 'number_of_rooms', "property_type", "listed"]
}
],
}
}
]
+
./resources/apartments.ts
export default {
...
options: {
...
createEditGroups: [
{
groupName: 'Main info',
columns: ['id','title', 'description', 'country', 'apartment_image']
},
{
groupName: 'Characteristics',
columns: ['price', 'square_meter', 'number_of_rooms', "property_type", "listed"]
}
],
}
}

Here is how it looks: alt text

List

Default Sorting

-
./resources/apartments.ts
import { AdminForthSortDirections } from 'adminforth';

...
resources: [
{
resourceId: 'aparts',
options: {
defaultSort: {
columnName: 'created_at',
direction: AdminForthSortDirections.ASC,
}
}
}
]
+
./resources/apartments.ts
import { AdminForthSortDirections } from 'adminforth';

...
export default {
resourceId: 'aparts',
options: {
defaultSort: {
columnName: 'created_at',
direction: AdminForthSortDirections.asc,
}
}
}

Page size

use options.listPageSize to define how many records will be shown on the page

-
./resources/apartments.ts
  resources: [
{
resourceId: 'aparts',
options: {
...
listPageSize: 10,
}
}
]
+
./resources/apartments.ts
export default {
resourceId: 'aparts',
options: {
...
listPageSize: 10,
}
}
]

Custom row click action

By default, when you click on a record in the list view, the show view will be opened.

You can change this behavior by using options.listTableClickUrl.

To disable any action (don't open show) return null:

-
./resources/apartments.ts
  resources: [
{
resourceId: 'aparts',
options: {
...
listTableClickUrl: async (record, adminUser) => null,
}
}
]
+
./resources/apartments.ts
export default {
resourceId: 'aparts',
options: {
...
listTableClickUrl: async (record, adminUser) => null,
}
}
]

To open a custom page, return URL to the custom page (can start with https://, or relative adminforth path):

./resources/apartments.ts
      options: {
...
listTableClickUrl: async (record, adminUser) => {
return `https://google.com/search?q=${record.name}`;
}
}

If you wish to open the page in a new tab, add target=_blank get param to the returned URL:

@@ -43,14 +43,14 @@

Cust

Auto-refresh records

options.listRowsAutoRefreshSeconds might be used to silently refresh records that are loaded (no new records will be fetched if they appear)

-
./resources/apartments.ts
  resources: [
{
resourceId: 'aparts',
hooks: {
list: {
afterDatasourceResponse: async ({ response }: { response: any }) => {
response.forEach((r: any) => {
// substitute random country on any load
const countries = [ 'US', 'DE', 'FR', 'GB', 'NL', 'IT', 'ES', 'DK', 'PL', 'UA',
'CA', 'AU', 'BR', 'JP', 'CN', 'IN', 'KR', 'TR', 'MX', 'ID']
r.country = countries[Math.floor(Math.random() * countries.length)];
})
return { ok: true, error: "" }
}
}
},
options: {
...
listRowsAutoRefreshSeconds: 1,
}
}
]
+
./resources/apartments.ts
export default {
resourceId: 'aparts',
hooks: {
list: {
afterDatasourceResponse: async ({ response }: { response: any }) => {
response.forEach((r: any) => {
// substitute random country on any load
const countries = [ 'US', 'DE', 'FR', 'GB', 'NL', 'IT', 'ES', 'DK', 'PL', 'UA',
'CA', 'AU', 'BR', 'JP', 'CN', 'IN', 'KR', 'TR', 'MX', 'ID']
r.country = countries[Math.floor(Math.random() * countries.length)];
})
return { ok: true, error: "" }
}
}
},
options: {
...
listRowsAutoRefreshSeconds: 1,
}
}
]

alt text

Creating

Fill with default values

Sometimes you want to generate some field value without asking user to fill it. For example createdAt oftenly store time of creation of the record. You can do this by using fillOnCreate:

-
./resources/apartments.ts

new AdminForth({
...
resources: [
{
name: 'apartments',
fields: [
...
{
name: 'created_at',
type: AdminForthDataTypes.DATETIME,
fillOnCreate: ({ initialRecord, adminUser }) => (new Date()).toISOString(),
},
],
},
...
],
+
./resources/apartments.ts

export default {
name: 'apartments',
fields: [
...
{
name: 'created_at',
type: AdminForthDataTypes.DATETIME,
fillOnCreate: ({ initialRecord, adminUser }) => (new Date()).toISOString(),
},
],
},
...
],

Also you can assign adminUser ID by adminUser.dbUser.id in same hook:

-
./resources/apartments.ts
new AdminForth({
...
resources: [
{
name: 'apartments',
fields: [
...
{
name: 'created_by',
type: AdminForthDataTypes.STRING,
fillOnCreate: ({ initialRecord, adminUser }) => adminUser.dbUser.id,
},
],
},
...
],
+
./resources/apartments.ts
export default {
name: 'apartments',
fields: [
...
{
name: 'created_by',
type: AdminForthDataTypes.STRING,
fillOnCreate: ({ initialRecord, adminUser }) => adminUser.dbUser.id,
},
],
},
...
],

Same effect can be achieved by using hooks. But fillOnCreate might be shorter and more readable.

@@ -60,6 +60,6 @@

You can set a column editReadonly so it will be shown in the edit form but will be disabled.
This might be useful to better identify the record during editing or to show some additional information that should not be changed but can help to edit the record.

-
./resources/apartments.ts
new AdminForth({
...
resources: [
{
name: 'apartments',
fields: [
...
{
name: 'created_at',
type: AdminForthDataTypes.DATETIME,
editReadonly: true,
},
],
},
...
],
+
./resources/apartments.ts
export default {
name: 'apartments',
fields: [
...
{
name: 'created_at',
type: AdminForthDataTypes.DATETIME,
editReadonly: true,
},
],
},
...
],
\ No newline at end of file diff --git a/docs/tutorial/Customization/virtualColumns/index.html b/docs/tutorial/Customization/virtualColumns/index.html index daf1b9304..99242de22 100644 --- a/docs/tutorial/Customization/virtualColumns/index.html +++ b/docs/tutorial/Customization/virtualColumns/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Customization/websocket/index.html b/docs/tutorial/Customization/websocket/index.html index bd07c8cdd..c2b3e022f 100644 --- a/docs/tutorial/Customization/websocket/index.html +++ b/docs/tutorial/Customization/websocket/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Plugins/AuditLog/index.html b/docs/tutorial/Plugins/AuditLog/index.html index 676d586e0..e5c255211 100644 --- a/docs/tutorial/Plugins/AuditLog/index.html +++ b/docs/tutorial/Plugins/AuditLog/index.html @@ -15,7 +15,7 @@ - + @@ -40,7 +40,7 @@

./resources/auditLogs.ts
  export default {
dataSource: 'maindb',
table: 'audit_logs',
columns: [
{ name: 'id', primaryKey: true, required: false, fillOnCreate: ({initialRecord}: any) => uuid(), showIn: ['show'] },
{ name: 'created_at', required: false },
{ name: 'resource_id', required: false },
{ name: 'user_id', required: false,
foreignResource: {
resourceId: 'users',
} },
{ name: 'action', required: false },
{ name: 'diff', required: false, type: AdminForthDataTypes.JSON, showIn: ['show'] },
{ name: 'record_id', required: false },
],
options: {
allowedActions: {
edit: false,
delete: false,
create: false
}
},
plugins: [
new AuditLogPlugin({
// if you want to exclude some resources from logging
//excludeResourceIds: ['users'],
resourceColumns: {
resourceIdColumnName: 'resource_id',
resourceActionColumnName: 'action',
resourceDataColumnName: 'diff',
resourceUserIdColumnName: 'user_id',
resourceRecordIdColumnName: 'record_id',
resourceCreatedColumnName: 'created_at'
}
}),
],
}

Then you need to import ./resources/auditLogs:

-
./index.ts
import auditLogsResource from "./resources/auditLogs"


dataSources: [
...
resources: [
apartmentsResource,
usersResource,
auditLogsResource
],
...
]
+
./index.ts
import auditLogsResource from "./resources/auditLogs"


... new AdminForth({
dataSources: [...],
...
resources: [
apartmentsResource,
usersResource,
auditLogsResource
],
...
]

Also, we need to add it to menu:

menu: [
...
{
label: 'Audit Logs',
icon: 'flowbite:search-outline',
resourceId: 'audit_logs',
}
]

That's it! Now you can see the logs in the table

diff --git a/docs/tutorial/Plugins/ForeignInlineList/index.html b/docs/tutorial/Plugins/ForeignInlineList/index.html index f3706c122..723676471 100644 --- a/docs/tutorial/Plugins/ForeignInlineList/index.html +++ b/docs/tutorial/Plugins/ForeignInlineList/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Plugins/RichEditor/index.html b/docs/tutorial/Plugins/RichEditor/index.html index de00bfad5..778541aa1 100644 --- a/docs/tutorial/Plugins/RichEditor/index.html +++ b/docs/tutorial/Plugins/RichEditor/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Plugins/TwoFactorsAuth/index.html b/docs/tutorial/Plugins/TwoFactorsAuth/index.html index 2d9a3162f..bfe6ebe1c 100644 --- a/docs/tutorial/Plugins/TwoFactorsAuth/index.html +++ b/docs/tutorial/Plugins/TwoFactorsAuth/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Plugins/chat-gpt/index.html b/docs/tutorial/Plugins/chat-gpt/index.html index 2a5404ab3..5c512f57a 100644 --- a/docs/tutorial/Plugins/chat-gpt/index.html +++ b/docs/tutorial/Plugins/chat-gpt/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Plugins/email-password-reset/index.html b/docs/tutorial/Plugins/email-password-reset/index.html index e9ca43808..3cbb44f1d 100644 --- a/docs/tutorial/Plugins/email-password-reset/index.html +++ b/docs/tutorial/Plugins/email-password-reset/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Plugins/import-export/index.html b/docs/tutorial/Plugins/import-export/index.html index d56e05fb7..7fc060d05 100644 --- a/docs/tutorial/Plugins/import-export/index.html +++ b/docs/tutorial/Plugins/import-export/index.html @@ -15,7 +15,7 @@ - + @@ -33,6 +33,6 @@

Usage
import importExport from '@adminforth/import-export';

Add plugin instantiation to the plugins array of resource where you want to use it:

-

new AdminForth({
...
resources: [
{
resourceId: 'aparts',
plugins: [
...
new importExport({}),
],
},
],
});
+

export default {
resourceId: 'aparts',
plugins: [
...
new importExport({}),
],
...
}

\ No newline at end of file diff --git a/docs/tutorial/Plugins/open-signup/index.html b/docs/tutorial/Plugins/open-signup/index.html index 0dfaa4dc4..ec7808eb9 100644 --- a/docs/tutorial/Plugins/open-signup/index.html +++ b/docs/tutorial/Plugins/open-signup/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/Plugins/upload/index.html b/docs/tutorial/Plugins/upload/index.html index 567a9722f..272e7e41e 100644 --- a/docs/tutorial/Plugins/upload/index.html +++ b/docs/tutorial/Plugins/upload/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/deploy/index.html b/docs/tutorial/deploy/index.html index ba23e5d63..8bdd4493d 100644 --- a/docs/tutorial/deploy/index.html +++ b/docs/tutorial/deploy/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/gettingStarted/index.html b/docs/tutorial/gettingStarted/index.html index 6ecd64030..1eeb4af14 100644 --- a/docs/tutorial/gettingStarted/index.html +++ b/docs/tutorial/gettingStarted/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/glossary/index.html b/docs/tutorial/glossary/index.html index ef09ae4a7..bca230287 100644 --- a/docs/tutorial/glossary/index.html +++ b/docs/tutorial/glossary/index.html @@ -15,7 +15,7 @@ - + diff --git a/docs/tutorial/helloWorld/index.html b/docs/tutorial/helloWorld/index.html index 1291963be..7fe8bf8a5 100644 --- a/docs/tutorial/helloWorld/index.html +++ b/docs/tutorial/helloWorld/index.html @@ -15,7 +15,7 @@ - + diff --git a/index.html b/index.html index e97858b89..85804b5bb 100644 --- a/index.html +++ b/index.html @@ -15,7 +15,7 @@ - + diff --git a/search/index.html b/search/index.html index 4bbf3a5a8..4a429e3db 100644 --- a/search/index.html +++ b/search/index.html @@ -15,7 +15,7 @@ - +