|
@@ -2258,6 +2258,47 @@
|
|
|
</span>
|
|
|
</template>
|
|
|
</el-dialog>
|
|
|
+
|
|
|
+ <!-- 肢体检测配置对话框 -->
|
|
|
+ <el-dialog
|
|
|
+ v-model="bodyDetectionConfigVisible"
|
|
|
+ title="肢体检测配置"
|
|
|
+ width="600px"
|
|
|
+ :close-on-click-modal="false"
|
|
|
+ >
|
|
|
+ <el-form :model="bodyDetectionConfig" label-width="120px">
|
|
|
+ <el-form-item label="检测时长">
|
|
|
+ <el-input-number
|
|
|
+ v-model="bodyDetectionConfig.duration"
|
|
|
+ :min="1"
|
|
|
+ :max="30"
|
|
|
+ :step="1"
|
|
|
+ controls-position="right"
|
|
|
+ /> 分钟
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="检测项目">
|
|
|
+ <el-checkbox-group v-model="bodyDetectionConfig.detectionItems">
|
|
|
+ <el-checkbox label="face">面部表情</el-checkbox>
|
|
|
+ <el-checkbox label="pose">肢体姿态</el-checkbox>
|
|
|
+ <el-checkbox label="gesture">手势动作</el-checkbox>
|
|
|
+ </el-checkbox-group>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="提示文本">
|
|
|
+ <el-input
|
|
|
+ v-model="bodyDetectionConfig.promptText"
|
|
|
+ type="textarea"
|
|
|
+ :rows="3"
|
|
|
+ placeholder="请输入提示文本"
|
|
|
+ />
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <template #footer>
|
|
|
+ <span class="dialog-footer">
|
|
|
+ <el-button @click="cancelBodyDetectionConfig" size="small">取消</el-button>
|
|
|
+ <el-button type="primary" @click="saveBodyDetectionConfig" size="small">确定</el-button>
|
|
|
+ </span>
|
|
|
+ </template>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -2375,7 +2416,7 @@ const recruitmentProcess = reactive([
|
|
|
{ id: 6, name: '简历收集', description: '简历收集', active: true, type: 'resume_collection',visible:true },
|
|
|
{ id: 5, name: '资料收集', description: '资料收集', active: true, type: 'data_collection',visible:true },
|
|
|
{ id: 2, name: 'AI考察', description: 'AI考察', active: true, type: 'ai_video',visible:true },
|
|
|
- { id: 8, name: '常识问题', description: '常识问题', active: true, type: 'common_sense',visible:true },
|
|
|
+ { id: 8, name: '综合素质考察', description: '综合素质考察', active: true, type: 'common_sense',visible:true },
|
|
|
{ id: 9, name: '心理问题', description: '心理问题', active: true, type: 'psychological_problem',visible:true },
|
|
|
{ id: 7, name: '候选人提问', description: '时长5分钟,最多3个问题', active: true, type: 'candidate_questions', visible:true,
|
|
|
config: {
|
|
@@ -2407,12 +2448,13 @@ const showProcessDialog = ref(false);
|
|
|
const processStepOptions = [
|
|
|
{ label: 'AI考察', value: 'ai_video' },
|
|
|
{ label: '视频宣讲', value: 'video_presentation' },
|
|
|
+ { label: '肢体检测', value: 'body_detection' }, // 新增肢体检测选项
|
|
|
/* { label: 'AI实时对话', value: 'ai_chat' },*/
|
|
|
{ label: '资料收集', value: 'data_collection' },
|
|
|
{ label: '简历收集', value: 'resume_collection' },
|
|
|
{ label: '候选人提问', value: 'candidate_questions' },
|
|
|
{ label: '心理问题', value: 'psychological_problem' },
|
|
|
- { label: '常识问题', value: 'common_sense' },
|
|
|
+ { label: '综合素质考察', value: 'common_sense' },
|
|
|
/* { label: '代码测试', value: 'code_test' },
|
|
|
{ label: '打字测试', value: 'typing_test' } */
|
|
|
];
|
|
@@ -3030,10 +3072,10 @@ const deleteProcessStep = (step: any,index: number) => {
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
- if(step.type=='psychological_problem'){ // 处理常识问题删除
|
|
|
+ if(step.type=='psychological_problem'){ // 处理综合素质考察删除
|
|
|
UpdateConfig({
|
|
|
id: getConfigId.value,
|
|
|
- enable_scoring_questions: false // 删除常识问题时,将enable_scoring_questions设置为false
|
|
|
+ enable_scoring_questions: false // 删除综合素质考察时,将enable_scoring_questions设置为false
|
|
|
}).then((res:any) => {
|
|
|
if(res.code == 2000) {
|
|
|
ElMessage.success('删除成功');
|
|
@@ -3042,10 +3084,10 @@ const deleteProcessStep = (step: any,index: number) => {
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
- if(step.type=='common_sense'){ // 处理常识问题删除
|
|
|
+ if(step.type=='common_sense'){ // 处理综合素质考察删除
|
|
|
UpdateConfig({
|
|
|
id: getConfigId.value,
|
|
|
- enable_single_choice: false, // 删除常识问题时,将enable_scoring_questions设置为false
|
|
|
+ enable_single_choice: false, // 删除综合素质考察时,将enable_scoring_questions设置为false
|
|
|
enable_multiple_choice: false,
|
|
|
enable_image_choice: false,
|
|
|
enable_fill_blank:false,
|
|
@@ -3160,7 +3202,7 @@ const addSelectedStepType = async (type: string, label: string) => {
|
|
|
})
|
|
|
}
|
|
|
|
|
|
- // 添加常识问题类型的处理
|
|
|
+ // 添加综合素质考察类型的处理
|
|
|
if (type === 'common_sense') {
|
|
|
UpdateConfig({
|
|
|
id: getConfigId.value,
|
|
@@ -4680,7 +4722,7 @@ const editAIVideo = async (step: AIVideoStep) => {
|
|
|
aiVideoOptions[key] = false;
|
|
|
});
|
|
|
}
|
|
|
- if(step.name === '常识问题'){
|
|
|
+ if(step.name === '综合素质考察'){
|
|
|
GetQuestionList({page:1,limit:20}).then((res:any)=>{
|
|
|
if(res.data){
|
|
|
questionList.value = res.data.items;
|
|
@@ -6314,6 +6356,53 @@ const addAIInterview = () => {
|
|
|
const showCommonSenseDialog = ref(false);
|
|
|
const showPsychologicalDialog = ref(false);
|
|
|
const showPostRenderDialog = ref(false);
|
|
|
+
|
|
|
+// 在setup中添加相关变量和方法
|
|
|
+const bodyDetectionConfigVisible = ref(false)
|
|
|
+const bodyDetectionConfig = ref({
|
|
|
+ duration: 5,
|
|
|
+ detectionItems: ['face', 'pose'],
|
|
|
+ promptText: '请按照提示完成相应的动作,系统将自动进行检测。'
|
|
|
+})
|
|
|
+
|
|
|
+// 打开肢体检测配置
|
|
|
+const openBodyDetectionConfig = () => {
|
|
|
+ bodyDetectionConfigVisible.value = true
|
|
|
+}
|
|
|
+
|
|
|
+// 取消肢体检测配置
|
|
|
+const cancelBodyDetectionConfig = () => {
|
|
|
+ bodyDetectionConfigVisible.value = false
|
|
|
+}
|
|
|
+
|
|
|
+// 保存肢体检测配置
|
|
|
+const saveBodyDetectionConfig = async () => {
|
|
|
+ try {
|
|
|
+ // TODO: 调用API保存配置
|
|
|
+ await saveProcessConfig({
|
|
|
+ position_id: route.params.id,
|
|
|
+ process_type: 'body_detection',
|
|
|
+ config: bodyDetectionConfig.value
|
|
|
+ })
|
|
|
+ ElMessage.success('配置保存成功')
|
|
|
+ bodyDetectionConfigVisible.value = false
|
|
|
+ } catch (error) {
|
|
|
+ console.error('保存肢体检测配置失败:', error)
|
|
|
+ ElMessage.error('配置保存失败')
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+// 在handleProcessConfig方法中添加肢体检测的处理
|
|
|
+const handleProcessConfig = (type: string) => {
|
|
|
+ switch (type) {
|
|
|
+ // ... existing code ...
|
|
|
+ case 'body_detection':
|
|
|
+ openBodyDetectionConfig()
|
|
|
+ break
|
|
|
+ // ... existing code ...
|
|
|
+ }
|
|
|
+}
|
|
|
+// ... existing code ...
|
|
|
</script>
|
|
|
|
|
|
<style scoped>
|