Initial commit: Tapalka monorepo (bot, front, strapi)
This commit is contained in:
7
CMyTapper/robucks-front/interfaces/global.d.ts
vendored
Normal file
7
CMyTapper/robucks-front/interfaces/global.d.ts
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
export {};
|
||||
|
||||
declare global {
|
||||
interface Window {
|
||||
Telegram: any;
|
||||
}
|
||||
}
|
||||
40
CMyTapper/robucks-front/interfaces/player.type.ts
Normal file
40
CMyTapper/robucks-front/interfaces/player.type.ts
Normal file
@@ -0,0 +1,40 @@
|
||||
import { StatusTask } from '@/interfaces/task.type';
|
||||
import { ITask } from '@/api/tasks.api';
|
||||
import { IArchiveRequest } from '@/api/archive-request.api';
|
||||
|
||||
export interface IPlayer {
|
||||
id: number;
|
||||
attributes: {
|
||||
telegram_nick: string;
|
||||
telegram_id: number;
|
||||
auth_id: string;
|
||||
balance: number;
|
||||
old_balance: number;
|
||||
referral_fee: number;
|
||||
my_referrals: { data: IPlayer[] | null };
|
||||
referral: { data: IPlayer | null };
|
||||
start_farm: Date | null;
|
||||
finished_tasks: { data: IFinishedTasks[] | null };
|
||||
archive_request: { data: IArchiveRequest | null };
|
||||
};
|
||||
}
|
||||
|
||||
export interface IFinishedTasks {
|
||||
id: number;
|
||||
attributes: {
|
||||
status: StatusTask;
|
||||
task: { data: ITask | null };
|
||||
};
|
||||
}
|
||||
|
||||
export interface ICreatePlayer {
|
||||
telegram_id: number;
|
||||
telegram_nick: string;
|
||||
balance: number;
|
||||
old_balance: number;
|
||||
}
|
||||
|
||||
export interface IUpdatePlayerTask {
|
||||
status: StatusTask;
|
||||
taskId: number;
|
||||
}
|
||||
4
CMyTapper/robucks-front/interfaces/task.type.ts
Normal file
4
CMyTapper/robucks-front/interfaces/task.type.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
export enum StatusTask {
|
||||
'pending_prize' = 'pending_prize',
|
||||
'claimed' = 'claimed',
|
||||
}
|
||||
Reference in New Issue
Block a user