/** * Namespace Api * * All backend api type */ declare namespace Api { namespace Question { /** common params of paginating */ interface PaginatingCommonParams { /** pageIndex page number */ pageIndex: number /** page size */ pageSizes: number /** total count */ total: number } /** common params of paginating query list data */ interface PaginatingQueryRecord extends PaginatingCommonParams { data: T[] } /** get question library list all params */ interface GetQuestionLibraryListAllParams { /** question id */ questionId: number /** pageIndex page number */ pageIndex: number /** page size */ pageSizes: number /** search keyword */ keyWords?: string } /** add params */ interface AddParams { /** question id */ id: number /** question name */ name: string /** question content */ questionContent: string /** question type */ questionType: QuestionType } /** add question library params */ interface AddQuestionLibraryParams { /** question library id */ id: number /** question library name */ name: string /** question library content */ answer: string /** question id */ questionId: number /** question library image url */ imageUrl: string /** question library type */ type: QuestionScoreType /** is priority 0: no 1: yes */ IsGood: number } /** common search params of table */ type CommonSearchParams = Pick /** * enable status * * - "1": enabled * - "2": disabled */ type EnableStatus = '1' | '2' /** question score type */ type QuestionScoreType = '1' | '2' /** 固定分数 | 答题个数 */ /** competition round type */ type CompetitionRoundType = '1' | '2' /** 题包环节 | 加时环节 */ /** common record */ type CommonRecord = { /** record id */ id: number /** record creator */ createBy: string /** record create time */ createTime: string /** record updater */ updateBy: string /** record update time */ updateTime: string /** record status */ status: EnableStatus | null } & T } }