fix the most recent contacts to show correctly on the gift details screen

This commit is contained in:
2026-01-21 19:36:33 -07:00
parent a0b99d5fca
commit 077f45f900
3 changed files with 8 additions and 17 deletions

View File

@@ -521,19 +521,10 @@ export default class EntityGrid extends Vue {
}
// Validate entities prop for people
if (this.entityType === "people" && !this.entities) {
logger.error(
"EntityGrid: entities prop is required when entityType is 'people'",
);
if (this.notify) {
this.notify(
{
group: "alert",
type: "danger",
title: "Error",
text: "Contacts data is required but not provided.",
},
TIMEOUTS.SHORT,
if (this.entityType === "people") {
if (!this.entities) {
logger.error(
"EntityGrid: entities prop or allContacts prop is required when entityType is 'people'",
);
}
}

View File

@@ -5,6 +5,8 @@ export type ContactMethod = {
};
export type Contact = {
// id is a property in most contacts, but besides sorting from DB we don't need it
//
// When adding a property:
// - Consider whether it should be added when exporting & sharing contacts, eg. DataExportSection

View File

@@ -428,10 +428,8 @@ export default class GiftedDetails extends Vue {
const activeIdentity = await (this as any).$getActiveIdentity();
this.activeDid = activeIdentity.activeDid || "";
const dbContacts = await this.$dbQuery("SELECT * FROM contacts");
this.allContacts = this.$mapQueryResultToValues(
dbContacts,
) as unknown as Contact[];
this.allContacts = await this.$contactsByDateAdded();
this.allMyDids = await retrieveAccountDids();
if (