cache the user-profile lookup results in a list

This commit is contained in:
2026-02-21 15:14:00 -07:00
parent f3152fc414
commit 07ebd1c32f
5 changed files with 39 additions and 2 deletions

View File

@@ -34,6 +34,7 @@ import {
faCircleQuestion,
faCircleRight,
faCircleUser,
faCircleXmark,
faClock,
faCoins,
faComment,
@@ -135,6 +136,7 @@ library.add(
faCircleQuestion,
faCircleRight,
faCircleUser,
faCircleXmark,
faClock,
faCoins,
faComment,

View File

@@ -62,6 +62,11 @@ const routes: Array<RouteRecordRaw> = [
name: "contact-import",
component: () => import("../views/ContactImportView.vue"),
},
{
path: "/contact-profile-check",
name: "contact-profile-check",
component: () => import("../views/ContactProfileCheckView.vue"),
},
{
path: "/contact-qr",
name: "contact-qr",

View File

@@ -1734,7 +1734,7 @@ export const PlatformServiceMixin = {
/**
* Get data from temp table by ID
* Currently set by main.capacitor.ts storeSharedImageInTempDB()
*
*
* @param id Temporary storage ID
* @returns Promise<Temp | null> Temporary data or null if not found
*/
@@ -1749,7 +1749,7 @@ export const PlatformServiceMixin = {
/**
* Delete data from temp table by ID
*
*
* @param id Temporary storage ID
* @returns Promise<boolean> Success status
*/

View File

@@ -55,6 +55,9 @@
<!-- Contact Methods -->
<div class="mt-4">
<label class="block text-sm font-medium text-gray-700"
>Contact Methods</label
>
<div v-for="(method, index) in contactMethods" :key="index" class="mt-4">
<!-- Type and Value Row -->
<div class="flex gap-2">

View File

@@ -127,6 +127,20 @@
</div>
</div>
<!-- Check for Profile (admin/organizer feature) -->
<div
v-if="showGeneralAdvanced && contactsSelected.length > 0"
class="my-3 flex justify-center"
>
<button
class="text-sm uppercase bg-gradient-to-b from-green-400 to-green-700 shadow-[inset_0_-1px_0_0_rgba(0,0,0,0.5)] text-white px-4 py-2 rounded-md"
@click="checkSelectedProfiles"
>
<font-awesome icon="magnifying-glass" class="fa-fw mr-1" />
Check for Profile
</button>
</div>
<!-- Results List -->
<ul
v-if="contacts.length > 0"
@@ -334,6 +348,7 @@ export default class ContactsView extends Vue {
hideRegisterPromptOnNewContact = false;
isRegistered = false;
showDidCopy = false;
showGeneralAdvanced = false;
showPubKeyCopy = false;
showPubKeyHashCopy = false;
showGiveNumbers = false;
@@ -377,6 +392,7 @@ export default class ContactsView extends Vue {
await this.processContactJwt();
await this.processInviteJwt();
this.showGeneralAdvanced = !!settings.showGeneralAdvanced;
this.showGiveNumbers = !!settings.showContactGivesInline;
this.hideRegisterPromptOnNewContact =
!!settings.hideRegisterPromptOnNewContact;
@@ -598,6 +614,17 @@ export default class ContactsView extends Vue {
this.contactsFiltered = await this.filteredContacts();
}
/**
* Navigate to profile check view with selected contacts
*/
checkSelectedProfiles() {
sessionStorage.setItem("profileCheckFresh", "true");
this.$router.push({
name: "contact-profile-check",
query: { dids: JSON.stringify(this.contactsSelected) },
});
}
get copyButtonClass() {
return this.contactsSelected.length > 0
? "text-md bg-gradient-to-b from-blue-400 to-blue-700 " +