first commit
This commit is contained in:
commit
c9fb67e751
423 files changed
+53287
No files matched your search
@@ -0,0 +1,14 @@
|
||||
export interface AuthRequest {
|
||||
email: string;
|
||||
senha: string;
|
||||
}
|
||||
|
||||
export interface AuthResponse {
|
||||
token: string;
|
||||
user: {
|
||||
id: string;
|
||||
nome: string;
|
||||
email: string;
|
||||
perfil: string;
|
||||
};
|
||||
}
|
||||
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
declare module 'bcryptjs' {
|
||||
export function genSalt(rounds?: number): Promise<string>;
|
||||
export function hash(s: string, salt: string | number): Promise<string>;
|
||||
export function compare(s: string, hash: string): Promise<boolean>;
|
||||
export function hashSync(s: string, salt: string | number): string;
|
||||
export function compareSync(s: string, hash: string): boolean;
|
||||
export function genSaltSync(rounds?: number): string;
|
||||
export const getRounds: (hash: string) => number;
|
||||
}
|
||||
@@ -0,0 +1,85 @@
|
||||
export interface DatajudMovimento {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
dataHora: string;
|
||||
complementosTabelados?: {
|
||||
codigo: number;
|
||||
valor: number;
|
||||
nome: string;
|
||||
descricao: string;
|
||||
}[];
|
||||
}
|
||||
|
||||
export interface DatajudResponse {
|
||||
_source: {
|
||||
classe: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
};
|
||||
numeroProcesso: string;
|
||||
tribunal: string;
|
||||
dataAjuizamento: string;
|
||||
orgaoJulgador: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
};
|
||||
movimentos: DatajudMovimento[];
|
||||
assuntos: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
}[];
|
||||
};
|
||||
}
|
||||
|
||||
export interface DatajudSearchResponse {
|
||||
hits: {
|
||||
hits: {
|
||||
_source: DatajudResponse["_source"];
|
||||
}[];
|
||||
};
|
||||
}
|
||||
|
||||
export interface DatajudProcesso {
|
||||
id: string;
|
||||
tribunal: string;
|
||||
numeroProcesso: string;
|
||||
dataAjuizamento: string;
|
||||
grau: string;
|
||||
nivelSigilo: number;
|
||||
formato: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
};
|
||||
sistema: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
};
|
||||
classe: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
};
|
||||
assuntos: Array<{
|
||||
codigo: number;
|
||||
nome: string;
|
||||
}>;
|
||||
orgaoJulgador: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
codigoMunicipioIBGE: number;
|
||||
};
|
||||
movimentos: Array<{
|
||||
codigo: number;
|
||||
nome: string;
|
||||
dataHora: string;
|
||||
complementosTabelados?: Array<{
|
||||
codigo: number;
|
||||
descricao: string;
|
||||
valor: number;
|
||||
nome: string;
|
||||
}>;
|
||||
orgaoJulgador?: {
|
||||
codigoOrgao: number;
|
||||
nomeOrgao: string;
|
||||
};
|
||||
}>;
|
||||
}
|
||||
@@ -0,0 +1,149 @@
|
||||
export interface Usuario {
|
||||
id: string;
|
||||
nome: string;
|
||||
email: string;
|
||||
cargo: "advogado" | "assistente" | "admin";
|
||||
dataCriacao: Date;
|
||||
senha: string;
|
||||
}
|
||||
|
||||
export enum NaturezaProcesso {
|
||||
CIVEL = "CIVEL",
|
||||
CRIMINAL = "CRIMINAL",
|
||||
PREVIDENCIARIO = "PREVIDENCIARIO",
|
||||
TRABALHISTA = "TRABALHISTA",
|
||||
FAMILIA = "FAMILIA",
|
||||
TRIBUTARIO = "TRIBUTARIO",
|
||||
ADMINISTRATIVO = "ADMINISTRATIVO",
|
||||
}
|
||||
|
||||
export enum TipoParte {
|
||||
AUTOR = "AUTOR",
|
||||
REU = "REU",
|
||||
}
|
||||
|
||||
export enum StatusProcesso {
|
||||
INICIAL = "INICIAL",
|
||||
EM_ANDAMENTO = "EM_ANDAMENTO",
|
||||
SUSPENSO = "SUSPENSO",
|
||||
RECURSO = "RECURSO",
|
||||
CONCLUSO = "CONCLUSO",
|
||||
ARQUIVADO = "ARQUIVADO",
|
||||
}
|
||||
|
||||
export type ResultadoProcesso = 'NAO_JULGADO' | 'PROCEDENTE' | 'PARCIALMENTE_PROCEDENTE' | 'IMPROCEDENTE' | 'SEM_ANALISE_MERITO';
|
||||
|
||||
export interface Processo {
|
||||
id: string;
|
||||
numero: string;
|
||||
natureza: NaturezaProcesso;
|
||||
clienteId: string;
|
||||
tipoParteCliente: TipoParte;
|
||||
valorCausa?: number;
|
||||
orgaoJulgador: string;
|
||||
orgaoOrigem?: string;
|
||||
nomeContraparte: string;
|
||||
status: StatusProcesso;
|
||||
dataCriacao: Date;
|
||||
dataAtualizacao: Date;
|
||||
diligencias?: Diligencia[];
|
||||
audiencias?: Audiencia[];
|
||||
documentos?: Documento[];
|
||||
movimentacoes?: Movimentacao[];
|
||||
resultado: ResultadoProcesso;
|
||||
}
|
||||
|
||||
export interface Cliente {
|
||||
id: string;
|
||||
nome: string;
|
||||
cpfCnpj: string;
|
||||
email: string;
|
||||
telefone: string;
|
||||
endereco: string;
|
||||
processos?: Processo[];
|
||||
dataCriacao: Date;
|
||||
|
||||
// Informações Pessoais
|
||||
estadoCivil?:
|
||||
| "solteiro"
|
||||
| "casado"
|
||||
| "divorciado"
|
||||
| "uniao_estavel"
|
||||
| "viuvo";
|
||||
rg?: string;
|
||||
instagram?: string;
|
||||
profissao?: string;
|
||||
dataNascimento?: Date;
|
||||
|
||||
// Informações Financeiras
|
||||
vinculoEmpregaticio?: "mei" | "pj" | "clt" | "autonomo" | "servidor_publico";
|
||||
renda?: number;
|
||||
declaraIR?: boolean;
|
||||
tipoPrevidencia?: "RPPS" | "RGPS";
|
||||
contribuiPrevidencia?: boolean;
|
||||
|
||||
// Filiação
|
||||
nomePai?: string;
|
||||
nomeMae?: string;
|
||||
conjugeNome?: string;
|
||||
conjugeCpf?: string;
|
||||
filhos?: Filho[];
|
||||
}
|
||||
|
||||
export interface Filho {
|
||||
id: string;
|
||||
nome: string;
|
||||
dataNascimento: Date;
|
||||
clienteId: string;
|
||||
}
|
||||
|
||||
export interface Prazo {
|
||||
id: string;
|
||||
processoId: string;
|
||||
descricao: string;
|
||||
dataLimite: Date;
|
||||
status: "pendente" | "concluido" | "atrasado";
|
||||
responsavelId: string;
|
||||
}
|
||||
|
||||
export interface Documento {
|
||||
id: string;
|
||||
nome: string;
|
||||
tipo: string;
|
||||
processoId: string;
|
||||
url: string;
|
||||
dataCriacao: Date;
|
||||
}
|
||||
|
||||
export interface Tarefa {
|
||||
id: string;
|
||||
titulo: string;
|
||||
descricao: string;
|
||||
status: 'PENDENTE' | 'EM_ANDAMENTO' | 'CONCLUIDA' | 'CANCELADA';
|
||||
prioridade: 'BAIXA' | 'MEDIA' | 'ALTA' | 'URGENTE';
|
||||
dataInicio: Date;
|
||||
dataVencimento: Date;
|
||||
responsavelId: string;
|
||||
criadoPorId: string;
|
||||
processoId?: string;
|
||||
clienteId?: string;
|
||||
subtarefas: SubTarefa[];
|
||||
comentarios: Comentario[];
|
||||
etiquetas: string[];
|
||||
progresso: number;
|
||||
}
|
||||
|
||||
export interface SubTarefa {
|
||||
id: string;
|
||||
titulo: string;
|
||||
concluida: boolean;
|
||||
tarefaId: string;
|
||||
}
|
||||
|
||||
export interface Comentario {
|
||||
id: string;
|
||||
texto: string;
|
||||
criadoPorId: string;
|
||||
criadoEm: Date;
|
||||
tarefaId: string;
|
||||
}
|
||||
Vendored
+21
@@ -0,0 +1,21 @@
|
||||
/// <reference types="vite/client" />
|
||||
|
||||
declare namespace NodeJS {
|
||||
interface ProcessEnv {
|
||||
// ...existing env types...
|
||||
NEXTCLOUD_URL: string;
|
||||
NEXTCLOUD_USER: string;
|
||||
NEXTCLOUD_PASS: string;
|
||||
}
|
||||
}
|
||||
|
||||
interface ImportMetaEnv {
|
||||
// ...existing env types...
|
||||
readonly VITE_NEXTCLOUD_URL: string
|
||||
readonly VITE_NEXTCLOUD_USER: string
|
||||
readonly VITE_NEXTCLOUD_PASS: string
|
||||
}
|
||||
|
||||
interface ImportMeta {
|
||||
readonly env: ImportMetaEnv
|
||||
}
|
||||
Vendored
+13
@@ -0,0 +1,13 @@
|
||||
import { Request } from 'express';
|
||||
|
||||
declare global {
|
||||
namespace Express {
|
||||
interface Request {
|
||||
user?: {
|
||||
id: string;
|
||||
email: string;
|
||||
perfil: string;
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
import { FormaPagamento, StatusPagamento } from "@prisma/client";
|
||||
|
||||
export interface IHonorario {
|
||||
id?: string;
|
||||
processoId: string;
|
||||
formaPagamento: FormaPagamento;
|
||||
status: StatusPagamento;
|
||||
dataVencimento: Date;
|
||||
dataContrato?: Date;
|
||||
observacoes?: string | null;
|
||||
valorFixo?: number | null;
|
||||
percentualCausa?: number | null;
|
||||
percentualExito?: number | null;
|
||||
valorEntrada?: number | null;
|
||||
numeroParcelas: number;
|
||||
valorParcela?: number | null;
|
||||
diaVencimento: number;
|
||||
}
|
||||
|
||||
export interface IHonorarioCreate
|
||||
extends Omit<IHonorario, "id" | "dataContrato"> {}
|
||||
@@ -0,0 +1,55 @@
|
||||
export enum NaturezaProcesso {
|
||||
CIVEL = "CIVEL",
|
||||
CRIMINAL = "CRIMINAL",
|
||||
PREVIDENCIARIO = "PREVIDENCIARIO",
|
||||
TRABALHISTA = "TRABALHISTA",
|
||||
FAMILIA = "FAMILIA",
|
||||
TRIBUTARIO = "TRIBUTARIO",
|
||||
ADMINISTRATIVO = "ADMINISTRATIVO",
|
||||
}
|
||||
|
||||
export enum TipoParte {
|
||||
AUTOR = "AUTOR",
|
||||
REU = "REU",
|
||||
}
|
||||
|
||||
export interface Processo {
|
||||
id: string;
|
||||
numero: string;
|
||||
natureza: NaturezaProcesso;
|
||||
clienteId: string;
|
||||
tipoParteCliente: TipoParte;
|
||||
valorCausa?: number;
|
||||
orgaoJulgador: string;
|
||||
orgaoOrigem?: string;
|
||||
nomeContraparte: string;
|
||||
status: StatusProcesso;
|
||||
dataCriacao: Date;
|
||||
dataAtualizacao: Date;
|
||||
diligencias?: Diligencia[];
|
||||
audiencias?: Audiencia[];
|
||||
documentos?: Documento[];
|
||||
movimentacoes?: Movimentacao[];
|
||||
}
|
||||
|
||||
export interface ProcessoData {
|
||||
tribunalUF: string;
|
||||
tribunal: string;
|
||||
numeroOriginal?: string;
|
||||
dadosDatajud?: {
|
||||
classe: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
};
|
||||
dataAjuizamento: string;
|
||||
orgaoJulgador: {
|
||||
codigo: number;
|
||||
nome: string;
|
||||
};
|
||||
movimentos: Array<{
|
||||
codigo: number;
|
||||
nome: string;
|
||||
dataHora: string;
|
||||
}>;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
import { TipoParte } from './processo';
|
||||
|
||||
export enum StatusProcessoAdministrativo {
|
||||
INICIAL = 'INICIAL',
|
||||
EM_ANALISE = 'EM_ANALISE',
|
||||
EM_RECURSO = 'EM_RECURSO',
|
||||
FINALIZADO = 'FINALIZADO',
|
||||
ARQUIVADO = 'ARQUIVADO'
|
||||
}
|
||||
|
||||
export interface MovimentacaoAdministrativa {
|
||||
id: string;
|
||||
processoId: string;
|
||||
data: Date;
|
||||
descricao: string;
|
||||
tipoMovimentacao: string;
|
||||
numero?: string;
|
||||
documentos?: string[];
|
||||
observacoes?: string;
|
||||
}
|
||||
|
||||
export interface ProcessoAdministrativo {
|
||||
id: string;
|
||||
numero: string;
|
||||
descricao: string;
|
||||
orgao: string;
|
||||
clienteId: string;
|
||||
tipoParteCliente: TipoParte;
|
||||
valorPretensao?: number;
|
||||
status: StatusProcessoAdministrativo;
|
||||
dataCriacao: Date;
|
||||
dataAtualizacao: Date;
|
||||
resultado?: string;
|
||||
movimentacoes?: MovimentacaoAdministrativa[];
|
||||
documentos?: string[];
|
||||
observacoes?: string;
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
export enum PerfilUsuario {
|
||||
ADVOGADO_ADMIN = "ADVOGADO_ADMIN",
|
||||
ADVOGADO = "ADVOGADO",
|
||||
ASSISTENTE = "ASSISTENTE",
|
||||
ESTAGIARIO = "ESTAGIARIO",
|
||||
}
|
||||
|
||||
export interface Usuario {
|
||||
id: string;
|
||||
nome: string;
|
||||
email: string;
|
||||
perfil: PerfilUsuario;
|
||||
cpf?: string;
|
||||
rg?: string;
|
||||
oab?: string;
|
||||
oabUF?: string;
|
||||
telefone?: string;
|
||||
endereco?: string;
|
||||
numero?: string;
|
||||
complemento?: string;
|
||||
bairro?: string;
|
||||
cidade?: string;
|
||||
estado?: string;
|
||||
cep?: string;
|
||||
ativo: boolean;
|
||||
dataCriacao: Date;
|
||||
}
|
||||
Reference in new issue
Block a user