This commit is contained in:
che
2026-07-23 12:06:08 +05:00
parent 4cfc5d6ae6
commit dddf6516d3
47 changed files with 2253 additions and 94 deletions
+205 -3
View File
@@ -1,25 +1,194 @@
import type { ListParams } from "./api_client";
export interface Contract {
id: number;
name: string;
number: string;
absolute_url: string;
contract_type: string;
category: string;
amount_total_display: string;
amount_by_ds: string;
comment: string;
date: string;
status_name: string;
status: string;
nds: string;
name_of_product: string;
counterparty_name: string;
amount: number;
month_pay: number | null;
avans_pay: string;
amount_total: number;
estimate_nds_cost: number;
estimate_nds_cert: number;
bill_cost_sum: number | null;
bill_paid_sum: number | null;
income_total: number;
arrears: number;
counterparty_id: number | null;
project_id: number | null;
frc_id: number | null;
employee_id: number | null;
counterparty: Counterparty | null;
project: Project | null;
frc: Frc | null;
employee: Employee | null;
}
export interface ContractCreate {
name: string;
number: string;
absolute_url: string;
contract_type: string;
category: string;
amount_total_display: string;
amount_by_ds: string;
comment: string;
date: string;
status_name: string;
status: string;
nds: string;
name_of_product: string;
counterparty_name: string;
amount: number;
month_pay?: number | null;
avans_pay: string;
amount_total: number;
estimate_nds_cost: number;
estimate_nds_cert: number;
bill_cost_sum?: number | null;
bill_paid_sum?: number | null;
income_total: number;
arrears: number;
counterparty_id?: number | null;
project_id?: number | null;
frc_id?: number | null;
employee_id?: number | null;
}
export interface ContractUpdate {
name?: string;
number?: string;
absolute_url?: string;
contract_type?: string;
category?: string;
amount_total_display?: string;
amount_by_ds?: string;
comment?: string;
date?: string;
status_name?: string;
status?: string;
nds?: string;
name_of_product?: string;
counterparty_name?: string;
amount?: number;
month_pay?: number | null;
avans_pay?: string;
amount_total?: number;
estimate_nds_cost?: number;
estimate_nds_cert?: number;
bill_cost_sum?: number | null;
bill_paid_sum?: number | null;
income_total?: number;
arrears?: number;
counterparty_id?: number | null;
project_id?: number | null;
frc_id?: number | null;
employee_id?: number | null;
}
export interface ContractListParams extends ListParams {
id?: number;
name?: string;
name__contains?: string;
number?: string;
number__contains?: string;
date?: string;
status?: string;
status_name?: string;
status_name__contains?: string;
contract_type?: string;
contract_type__contains?: string;
category?: string;
category__contains?: string;
counterparty_name__contains?: string;
name_of_product__contains?: string;
counterparty_id?: number | null;
project_id?: number | null;
frc_id?: number | null;
employee_id?: number | null;
}
export interface Counterparty {
id: number;
name: string;
}
export interface CounterpartyCreate {
name: string;
}
export interface CounterpartyUpdate {
name?: string;
}
export interface CounterpartyListParams extends ListParams {
id?: number;
name?: string;
name__contains?: string;
}
export interface Employee {
id: number;
name: string;
avatar: string;
short_name: string;
avatar_small: string | null;
}
export interface EmployeeCreate {
name: string;
avatar: string;
short_name: string;
avatar_small?: string | null;
}
export interface EmployeeUpdate {
name?: string;
avatar?: string;
short_name?: string;
avatar_small?: string | null;
}
export interface EmployeeListParams extends ListParams {
id?: number;
name?: string;
name__contains?: string;
short_name?: string;
short_name__contains?: string;
}
export interface Frc {
id: number;
name: string;
icon: string;
balance: number;
}
export interface FrcCreate {
name: string;
icon: string;
balance: number;
}
export interface FrcUpdate {
name?: string;
icon?: string;
balance?: number;
}
export interface FrcListParams extends ListParams {
id?: number;
name?: string;
name__contains?: string;
}
export interface Message {
@@ -47,6 +216,39 @@ export interface MessageListParams extends ListParams {
employee_id?: number;
}
export interface Project {
id: number;
name: string;
full_name: string;
short_name: string;
locality_id: number | null;
locality_name: string | null;
}
export interface ProjectCreate {
name: string;
full_name: string;
short_name: string;
locality_id?: number | null;
locality_name?: string | null;
}
export interface ProjectUpdate {
name?: string;
full_name?: string;
short_name?: string;
locality_id?: number | null;
locality_name?: string | null;
}
export interface ProjectListParams extends ListParams {
id?: number;
name?: string;
name__contains?: string;
short_name?: string;
short_name__contains?: string;
}
export interface Task {
id: number;
name: string;