// 项目中使用的类型定义

/**
 * 文章类型接口
 */
export interface Article {
  articleid: number
  title: string
  content: string
  attributeid: Number
  categoryName: string
  img?: string
  createdAt: string
  updatedAt: string
  viewCount?: number
  likes?: number
  commentCount?: number
  status?: number
  markdownscontent: string
}

/**
 * 文章DTO接口
 */
export interface ArticleDto {
  id?: number
  title: string
  content: string
  attributeid: number
  img?: string
  status?: number
  viewCount?: number
  likes?: number
  markdownscontent: string
}
/**
 * 文章分页接口
 */
export interface ArticlePagination {
  status?: number | undefined
  title?: string | undefined
  attributeid?: number | undefined
  categoryid?: number | undefined
  pagenum?: number | undefined
  pagesize?: number | undefined
}
/**
 * 留言类型接口
 */
export interface Message {
  messageid: number
  content: string
  nickname: string
  email: string
  articleid?: number
  parentid?: number
  createdAt: string
  replyid?: number
  likes?: number
  messageimg?: string
}

/**
 * 留言DTO接口
 */
export interface MessageDto {
  messageid?: number
  nickname?: string
  email?: string
  content?: string
  createdAt?: string
  parentid?: number
  replyid?: number
  articleid?: number
  messageimg?: string
}

/**
 * 分类类型接口
 */
export interface Category {
  Categoryid: number
  typename: string
  description?: string
  createdAt?: string
  updatedAt?: string
  articleCount?: number
}

/**
 * 分类DTO接口
 */
export interface CategoryDto {
  typename: string
  description?: string
}


/**
 * 分类属性接口
 */
export interface CategoryAttribute {
  map(arg0: (item: any) => any): unknown
  attributeid: number
  categoryid: number
  attributename: string
}

/**
 * 分类属性DTO接口
 */
export interface CategoryAttributeDto {
  categoryid: number
  attributename: string
}

/**
 * 用户信息接口
 */
export interface User {
  id?: number
  username?: string
  password?: string
  email?: string
  phone?: string
  role?: number
  createTime?: string
  avatar?: string
  token?: string
}

/**
 * 用户DTO接口
 */
export interface UserDto {
  username: string
  password: string
  email: string
  phone: string
  role?: number
}
/**
 * 疯言疯语类型接口
 */
export interface Nonsense {
  nonsenseid: number
  content: string
  status?: number
  time: string
}
/**
 * 疯言疯语DTO接口
 */
export interface NonsenseDto {
  content: string
  status?: number
  time?: string
}
/**
 * API响应接口
 */
export interface ApiResponse<T = any> {
  success: boolean
  code: number
  message?: string
  data?: T
  total?: number
}

/**
 * 分页参数接口
 */
export interface PaginationParams {
  pagenum?: number
  pagesize?: number
  status?: number
}