123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174 |
- import { request } from '/@/utils/service';
- import { UserPageQuery, AddReq, DelReq, EditReq, InfoReq,PageQuery } from '@fast-crud/fast-crud';
- /* 获取胜任力标签 */
- export function GetCompetencyList(query: UserPageQuery) {
- return request({
- url: '/api/system/competency/list',
- method: 'get',
- params: {...query,tenant_id:1},
- });
- }
- /* 获取题库列表 */
- export function GetQuestionList(query: PageQuery) {
- return request({
- url: '/api/system/interview_question/list',
- method: 'get',
- params: {...query,tenant_id:1},/* :Session.get('tenant_id').tenant_id || ,tenant_id:'1' */
- });
- }
- /* 根据职位及胜任力标签生成题目 */
- export function GenerateQuestions(obj: AddReq) {
- return request({
- url: '/api/system/interview_question/ai_generated',
- method: 'post',
- data: {...obj,tenant_id:1},
- timeout: 0
- });
- }
- /* 获取生成题目的列表 */
- export function GetDraftList(obj: EditReq) {
- return request({
- url: `/api/system/interview_question/draft_list?tenant_id=${obj.tenant_id}&position_id=${obj.position_id}`,
- method: 'get',
- });
- }
- /* 暂存生成的题目 */
- export function SaveDraft(obj: EditReq) {
- return request({
- url: `/api/system/interview_question/confirm_draft`,
- method: 'post',
- data: {...obj,tenant_id:1},
- });
- }
- /* 获取数字人列表 */
- export function GetDigitalList(obj: EditReq) {
- return request({
- url: `/api/system/digital_human/`,
- method: 'get',
- params: {...obj,tenant_id:1},
- });
- }
- /* 创建配置 */
- export function CreateConfig(data:any) {
- return request({
- url:`/api/system/job_config/list`,
- method: 'post',
- data: {...data,tenant_id:1},
- });
- }
- /* 更新配置 */
- export function UpdateConfig(data:any) {
- return request({
- url:`/api/system/job_config/detail/${data.id}`,
- method: 'put',
- data: {...data,tenant_id:1},
- });
- }
- /* 获取当前配置 */
- export function GetConfig(id:any) {
- return request({
- url:`/api/system/job_config/position/detail/${id}`,
- method: 'get',
-
- });
- }
- /* 绑定职位问题 */
- export function AddDocument(obj: AddReq) {
- return request({
- url: 'api/system/job/add_question',
- method: 'post',
- data: {...obj,tenant_id:"1"},
- });
- }
- /* 生成开场白 */
- export function GetOpeningSpeech(obj: AddReq) {
- return request({
- url: '/api/system/digital_human/generate_opening_video',
- method: 'post',
- data: {...obj,tenant_id:"1"},
- timeout: 0
- });
- }
- /* 生成视频 */
- export function GetVideo(obj: AddReq) {
- return request({
- url: '/api/system/digital_human/generate_question_videos',
- method: 'post',
- data: {...obj,tenant_id:"1",force_regenerate: true},
- timeout: 0
- });
- }
- /* 批量绑定 */
- export function BatchBind(obj: AddReq) {
- return request({
- url: 'api/system/job/add_question',
- method: 'post',
- data: {...obj,tenant_id:"1"},
- });
- }
- /* 批量取消绑定 */
- export function BatchUnbind(obj: AddReq) {
- return request({
- url: '/api/system/job/batch_delete_questions',
- method: 'post',
- data: {...obj,tenant_id:"1"},
- });
- }
- /* export function GetPermission(query: UserPageQuery) {
- return request({
- url: '/api/system/competency/list',
- method: 'get',
- params: {...query,tenant_id:1},
- });
- }
- */
- /* 更新为红线题 */
- export function UpdateObj(obj: EditReq) {
- return request({
- url: "/api/system/interview_question/update",/* + obj.id+'/' */
- method: 'put',
- data: {...obj,tenant_id: '1'},
- });
- }
- /* 生成胜任力标签 */
- export function GenerateCompetency(obj: AddReq) {
- return request({
- url: '/competency/generate_from_position/',
- method: 'post',
- data: {...obj,tenant_id:"1"},
- timeout: 0
- });
- }
- /* 保存胜任力标签 */
- export function SaveCompetency(obj: AddReq) {
- return request({
- url: '/competency/save_position_tags/',
- method: 'post',
- data: {...obj,tenant_id:"1"},
- });
- }
- export function GetcategoryList(query: UserPageQuery) {
- return request({
- url: '/api/system/question_category/list',
- method: 'get',
- params: {...query,tenant_id:1},
- });
- }
- export function GetPositionList(query: UserPageQuery) {
- return request({
- url: '/api/system/job/list',
- method: 'get',
- params: {...query,tenant_id:1},
- });
- }
|