diff --git a/src/formulas/formulas/contract/daoCore/dump.ts b/src/formulas/formulas/contract/daoCore/dump.ts index 5e20e3d..130337b 100644 --- a/src/formulas/formulas/contract/daoCore/dump.ts +++ b/src/formulas/formulas/contract/daoCore/dump.ts @@ -30,6 +30,7 @@ export type DumpState = { // Extra. votingModuleInfo?: ContractInfo createdAt?: string + createdAtEpoch?: number adminInfo?: { admin?: string | null config: Config @@ -171,6 +172,7 @@ export const dumpState: ContractFormula = { // Extra. votingModuleInfo, createdAt, + createdAtEpoch: createdAt ? new Date(createdAt).getTime() : undefined, adminInfo: adminConfig && { admin: adminAdmin, info: adminInfo, diff --git a/src/search/indexers/daos.ts b/src/search/indexers/daos.ts index 2019bb0..3105531 100644 --- a/src/search/indexers/daos.ts +++ b/src/search/indexers/daos.ts @@ -21,7 +21,7 @@ export const daos: MeilisearchIndexer = { 'value.proposalCount', 'value.hideFromSearch', ], - sortableAttributes: ['value.proposalCount'], + sortableAttributes: ['value.proposalCount', 'value.createdAtEpoch'], matches: async ({ event, state }) => { if (!(event instanceof WasmStateEvent)) { return