elioria-sst-x
    Preparing search index...

    Class SupabaseTechnicalResponsibleRepository

    Implements

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

    The db value.

    • Generated

      Executes create.

      Parameters

      • data: CreateTechnicalResponsibleData

        The data value.

      Returns Promise<TechnicalResponsible>

      The function result.

      Objective: In module packages/db/src/repositories/technical-responsible.repository.ts, run create.

      Behavior: Async; accepts data; returns a value; invokes Object.fromEntries.

    • 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/technical-responsible.repository.ts, run deactivate.

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

    • Generated

      Returns the result of findByCompany.

      Parameters

      • companyId: string

        The companyId value.

      • tenantId: string

        The tenantId value.

      Returns Promise<TechnicalResponsible[]>

      The function result.

      Objective: In module packages/db/src/repositories/technical-responsible.repository.ts, retrieve data through findByCompany.

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

    • Generated

      Returns the result of findById.

      Parameters

      • id: string

        The id value.

      • tenantId: string

        The tenantId value.

      Returns Promise<TechnicalResponsible | null>

      The function result.

      Objective: In module packages/db/src/repositories/technical-responsible.repository.ts, retrieve data through findById.

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

    • Generated

      Returns the result of findByTenant.

      Parameters

      • tenantId: string

        The tenantId value.

      Returns Promise<TechnicalResponsible[]>

      The function result.

      Objective: In module packages/db/src/repositories/technical-responsible.repository.ts, retrieve data through findByTenant.

      Behavior: Async; accepts tenantId; returns a value; invokes this.db .select() .from(technicalResponsibles) .where(eq(tec.

    • 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/technical-responsible.repository.ts, run reactivate.

      Behavior: Async; accepts id and tenantId; returns a value; invokes this.db .update(technicalResponsibles) .set({ active: true }.

    • Generated

      Executes update.

      Parameters

      • id: string

        The id value.

      • tenantId: string

        The tenantId value.

      • data: Partial<CreateTechnicalResponsibleData>

        The data value.

      Returns Promise<TechnicalResponsible>

      The function result.

      Objective: In module packages/db/src/repositories/technical-responsible.repository.ts, run update.

      Behavior: Async; accepts id and tenantId and data; returns a value; invokes this.db .update(technicalResponsibles) .set(updatePayload) ..