export interface Permission {
  _id: string;
  name: string;
  createdAt: string;
  updatedAt: string;
}

export interface GetPermissionsResponse {
  status: number;
  success: boolean;
  results: {
    permissions: Permission[];
  };
}

export type CreateAdminType = {
  fullName: string;
  userName: string;
  email: string;
  phoneNumber: string;
  permissions: string[];
  password: string;
};

export type UpdateAdminType = {
  fullName: string;
  userName: string;
  email: string;
  phoneNumber: string;
  permissions: string[];
};

export interface AdminRole {
  _id: string;
  name: string;
  createdAt: string;
  updatedAt: string;
}

export interface CreatedBy {
  _id: string;
  fullName: string;
  userName: string;
  email: string;
}

export interface Admin {
  _id: string;
  fullName: string;
  userName: string;
  email: string;
  phoneNumber: string;
  role: AdminRole;
  createdBy: CreatedBy;
  createdAt: string;
  updatedAt: string;
  permissions: string[];
}

export interface Pager {
  page: number;
  limit: number;
  totalItems: number;
  totalPages: number;
  prevPage: boolean;
  nextPage: string | null;
}

export interface GetAdminsResponse {
  status: number;
  success: boolean;
  results: {
    admins: Admin[];
    pager: Pager;
  };
}
