elioria-sst-x
    Preparing search index...

    Class SupabaseEpiIndividualCardRepository

    Implements

    Index
    db: PostgresJsDatabase<packages/db/src/schema> & {}

    The db value.

    • Generated

      Executes deactivate.

      Parameters

      • id: string

        The id value.

      • tenantId: string

        The tenantId value.

      Returns Promise<void>

      The function result.

      Objective: In module packages/db/src/repositories/epi-individual-card.repository.ts, run deactivate.

      Behavior: Async; accepts id and tenantId; returns a value; invokes this.db .update(epiIndividualCards) .set({ status: "inactive.

    • Generated

      Returns the result of findByCollaborator.

      Parameters

      • collaboratorId: string

        The collaboratorId value.

      • tenantId: string

        The tenantId value.

      Returns Promise<EpiIndividualCard | null>

      The function result.

      Objective: In module packages/db/src/repositories/epi-individual-card.repository.ts, retrieve data through findByCollaborator.

      Behavior: Async; accepts collaboratorId and tenantId; returns a value; invokes this.db .select() .from(epiIndividualCards) .where(and(eq(ep.

    • Generated

      Returns the result of findByCompany.

      Parameters

      • companyId: string

        The companyId value.

      • tenantId: string

        The tenantId value.

      Returns Promise<EpiIndividualCard[]>

      The function result.

      Objective: In module packages/db/src/repositories/epi-individual-card.repository.ts, retrieve data through findByCompany.

      Behavior: Async; accepts companyId and tenantId; returns a value; invokes this.db .select() .from(epiIndividualCards) .where(and(eq(ep.

    • Generated

      Returns the result of findOrCreate.

      Parameters

      • tenantId: string

        The tenantId value.

      • companyId: string

        The companyId value.

      • collaboratorId: string

        The collaboratorId value.

      Returns Promise<EpiIndividualCard>

      The function result.

      Objective: In module packages/db/src/repositories/epi-individual-card.repository.ts, retrieve data through findOrCreate.

      Behavior: Async; accepts tenantId and companyId and collaboratorId; returns a value; invokes this.db .select() .from(epiIndividualCards) .where( and( eq(.

    • Generated

      Executes reactivate.

      Parameters

      • id: string

        The id value.

      • tenantId: string

        The tenantId value.

      Returns Promise<void>

      The function result.

      Objective: In module packages/db/src/repositories/epi-individual-card.repository.ts, run reactivate.

      Behavior: Async; accepts id and tenantId; returns a value; invokes this.db .update(epiIndividualCards) .set({ status: "active" .

    • Generated

      Updates data through setStatusByCollaborator.

      Parameters

      • collaboratorId: string

        The collaboratorId value.

      • tenantId: string

        The tenantId value.

      • status: "active" | "inactive"

        The status value.

      Returns Promise<void>

      The function result.

      Objective: In module packages/db/src/repositories/epi-individual-card.repository.ts, change data through setStatusByCollaborator.

      Behavior: Async; accepts collaboratorId and tenantId and status; returns a value; invokes this.db .update(epiIndividualCards) .set({ status }) .where.