eli-video-interview 1.2.3-5.alpha.6 → 1.2.3-5.alpha.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (27) hide show
  1. package/esm/constants/ai-question.js +1 -1
  2. package/esm/modules/ai-ability-select/Root.js +8 -3
  3. package/esm/modules/ai-question/components/BootVideo/index.js +2 -2
  4. package/esm/modules/ai-question/components/QuestionModel/Item.js +3 -3
  5. package/esm/modules/ai-question/components/QuestionModel/List.js +1 -1
  6. package/esm/modules/ai-question/components/QuestionTemplate/index.js +4 -2
  7. package/esm/modules/ai-question/components/QuestionUpdate/Form.js +1 -1
  8. package/esm/modules/ai-question/components/QuestionUpdate/RandomQuestion.js +3 -5
  9. package/esm/modules/ai-question/components/QuestionUpdate/index.js +2 -2
  10. package/esm/store/ai-ability-select/question-ability-store.js +5 -1
  11. package/esm/store/ai-question/question-model-store.js +3 -3
  12. package/esm/store/enterprise/enterprise-store.d.ts +29 -0
  13. package/esm/store/enterprise/enterprise-store.js +13 -0
  14. package/lib/constants/ai-question.js +1 -1
  15. package/lib/modules/ai-ability-select/Root.js +8 -3
  16. package/lib/modules/ai-question/components/BootVideo/index.js +1 -1
  17. package/lib/modules/ai-question/components/QuestionModel/Item.js +2 -2
  18. package/lib/modules/ai-question/components/QuestionModel/List.js +1 -1
  19. package/lib/modules/ai-question/components/QuestionTemplate/index.js +4 -2
  20. package/lib/modules/ai-question/components/QuestionUpdate/Form.js +1 -1
  21. package/lib/modules/ai-question/components/QuestionUpdate/RandomQuestion.js +2 -4
  22. package/lib/modules/ai-question/components/QuestionUpdate/index.js +2 -2
  23. package/lib/store/ai-ability-select/question-ability-store.js +5 -1
  24. package/lib/store/ai-question/question-model-store.js +3 -3
  25. package/lib/store/enterprise/enterprise-store.d.ts +29 -0
  26. package/lib/store/enterprise/enterprise-store.js +16 -0
  27. package/package.json +1 -1
@@ -10,7 +10,7 @@ export var ADD_QUESTION_TYPE_LIST = [
10
10
  },
11
11
  {
12
12
  type: LANGUAGE,
13
- title: '语言能力题',
13
+ title: '朗读题',
14
14
  desc: '候选人根据所提供的文案进行朗读。',
15
15
  },
16
16
  ];
@@ -13,6 +13,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
13
13
  import AiAbilityList from './components/AiAbilityList';
14
14
  import { GetAiAbilityList } from "../../services/ai-ability";
15
15
  import { useAiAbilityListStore } from "../../store/ai-ability-select/question-ability-store";
16
+ import { useEnterpriseStore } from "../../store/enterprise/enterprise-store";
16
17
  import ScrollDialogContent from "../../components/ScrollDialogContent";
17
18
  import { useRequest } from 'ahooks';
18
19
  import { Box, Typography } from 'fbm-ui';
@@ -20,7 +21,8 @@ import { Stack } from 'fbm-ui/lib/mui';
20
21
  import { forwardRef, memo, useEffect } from 'react';
21
22
  var AiAbilitySelectRoot = forwardRef(function (_a, ref) {
22
23
  var jobToken = _a.jobToken, thirdToken = _a.thirdToken;
23
- var _b = useAiAbilityListStore(), aiAbilityList = _b.aiAbilityList, setAiAbilityList = _b.setAiAbilityList, selctedAbilitys = _b.selctedAbilitys;
24
+ var _b = useAiAbilityListStore(), aiAbilityList = _b.aiAbilityList, setAiAbilityList = _b.setAiAbilityList;
25
+ var setEnterprise = useEnterpriseStore().setEnterprise;
24
26
  var data = useRequest(function () { return GetAiAbilityList({ jobToken: jobToken, thirdToken: thirdToken }); }, {
25
27
  refreshDeps: [jobToken, thirdToken],
26
28
  }).data;
@@ -28,8 +30,11 @@ var AiAbilitySelectRoot = forwardRef(function (_a, ref) {
28
30
  setAiAbilityList((data === null || data === void 0 ? void 0 : data.data.list) || []);
29
31
  // eslint-disable-next-line react-hooks/exhaustive-deps
30
32
  }, [data]);
31
- console.log(selctedAbilitys);
32
- return (_jsx(ScrollDialogContent, __assign({ ref: ref }, { children: _jsxs(Box, __assign({ display: "flex", flexDirection: "column", width: 760 }, { children: [_jsxs(Stack, __assign({ spacing: 2, mb: 2 }, { children: [_jsx(Typography, __assign({ variant: "body1", fontWeight: 500 }, { children: "\u8BF7\u9009\u62E9\u8981\u4F18\u5148\u4F7F\u7528\u7684\u8003\u5BDF\u80FD\u529B\uFF0C\u4E5F\u53EF\u4EE5\u70B9\u51FB\u300C\u4E0B\u4E00\u6B65\u300D\u76F4\u63A5\u51FA\u9898" })), _jsxs(Stack, __assign({ direction: "row", spacing: 1, alignItems: "center" }, { children: [_jsx("img", { src: "//webcdn.fbmms.cn/assets/XXRf/bdUI9qZoTx-l2k_OHTotn", alt: "", width: 38, height: 16 }), _jsx(Typography, __assign({ variant: "caption", color: "textSecondary" }, { children: "AI\u6839\u636E\u5C97\u4F4D\u4FE1\u606F\u751F\u6210\u7684\u80FD\u529B\uFF0C\u521B\u5EFA\u5B8C\u6B65\u9AA4\u540E\uFF0C\u4F1A\u81EA\u52A8\u5C06\u9009\u62E9\u7684\u65B0\u589E\u80FD\u529B\u52A0\u5165\u5230\u8BBE\u7F6E\u9875\u7684\u8003\u5BDF\u80FD\u529B\u5217\u8868\u4E2D\u3002" }))] }))] })), _jsx(AiAbilityList, { items: aiAbilityList })] })) })));
33
+ useEffect(function () {
34
+ setEnterprise({ jobToken: jobToken, thirdToken: thirdToken });
35
+ // eslint-disable-next-line react-hooks/exhaustive-deps
36
+ }, [jobToken, thirdToken]);
37
+ return (_jsx(ScrollDialogContent, __assign({ ref: ref }, { children: _jsxs(Box, __assign({ display: "flex", flexDirection: "column", width: 760 }, { children: [_jsxs(Stack, __assign({ spacing: 2, mb: 2 }, { children: [_jsx(Typography, __assign({ variant: "body1", fontWeight: 500 }, { children: "\u8BF7\u9009\u62E9\u8981\u4F18\u5148\u4F7F\u7528\u7684\u8003\u5BDF\u80FD\u529B\uFF0C\u4E5F\u53EF\u4EE5\u70B9\u51FB\u300C\u4E0B\u4E00\u6B65\u300D\u76F4\u63A5\u51FA\u9898" })), (aiAbilityList === null || aiAbilityList === void 0 ? void 0 : aiAbilityList.some(function (v) { return v.isNew; })) && (_jsxs(Stack, __assign({ direction: "row", spacing: 1, alignItems: "center" }, { children: [_jsx("img", { src: "//webcdn.fbmms.cn/assets/XXRf/bdUI9qZoTx-l2k_OHTotn", alt: "", width: 38, height: 16 }), _jsx(Typography, __assign({ variant: "caption", color: "textSecondary" }, { children: "AI\u6839\u636E\u5C97\u4F4D\u4FE1\u606F\u751F\u6210\u7684\u80FD\u529B\uFF0C\u521B\u5EFA\u5B8C\u6B65\u9AA4\u540E\uFF0C\u4F1A\u81EA\u52A8\u5C06\u9009\u62E9\u7684\u65B0\u589E\u80FD\u529B\u52A0\u5165\u5230\u8BBE\u7F6E\u9875\u7684\u8003\u5BDF\u80FD\u529B\u5217\u8868\u4E2D\u3002" }))] })))] })), _jsx(AiAbilityList, { items: aiAbilityList })] })) })));
33
38
  });
34
39
  AiAbilitySelectRoot.displayName = 'AiAbilitySelectRoot';
35
40
  export default memo(AiAbilitySelectRoot);
@@ -27,7 +27,7 @@ import { PostCommonUpload } from "../../../../services/ai-question";
27
27
  import { useBootVideoStore } from "../../../../store/ai-question/boot-video-store";
28
28
  import { isExceedMaxVideoFileSize } from "../../../../utils/utils";
29
29
  import { useRequest, useSetState } from 'ahooks';
30
- import { AddIcon, Box, Button, Checkbox, Dialog, InfoIcon, Message, Radio, RadioGroup, Tooltip, Typography, Upload } from 'fbm-ui';
30
+ import { AddIcon, Box, Button, Checkbox, Dialog, Message, Radio, RadioGroup, Typography, Upload } from 'fbm-ui';
31
31
  import { Stack } from 'fbm-ui/lib/mui';
32
32
  import { useCallback, useEffect, useState } from 'react';
33
33
  var BootVideo = function (props) {
@@ -108,6 +108,6 @@ var BootVideo = function (props) {
108
108
  return (_jsx(Dialog, __assign({ open: open, title: "\u5B9A\u5236\u9762\u8BD5\u95F4", onClose: onClose, onOk: handleOk, width: 768 }, { children: _jsx(ScrollDialogContent, { children: _jsxs(Box, __assign({ sx: { display: 'flex', justifyContent: 'space-between' } }, { children: [_jsxs(Stack, { children: [_jsx(Typography, __assign({ variant: "body1", fontWeight: 500 }, { children: "\u9762\u8BD5\u95F4\u4E92\u52A8\u65B9\u5F0F" })), _jsx(RadioGroup, __assign({ defaultValue: "outlined", value: 1 }, { children: _jsx(Radio, { value: "1", label: "\u4F20\u7EDF\u8BFB\u9898\u6A21\u5F0F" }) })), _jsx(Typography, __assign({ variant: "body1", fontWeight: 500, mt: 3, mb: 2 }, { children: "\u5F15\u5BFC\u89C6\u9891" })), _jsx(CustomUploadedImgRoot, { children: mediaList.map(function (_a) {
109
109
  var videoUrl = _a.videoUrl, frameUrl = _a.frameUrl;
110
110
  return (_jsx("img", { src: frameUrl, style: { borderColor: (mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl) === videoUrl ? '#4CAF50' : 'transparent' }, height: 100, alt: "", onClick: function () { return handleSelectVideo(videoUrl, frameUrl); } }, videoUrl));
111
- }) }), _jsx(Typography, __assign({ variant: "caption", flexWrap: "wrap", width: 344, color: "text.disabled", mb: 2, mt: 1 }, { children: "\u5EFA\u8BAE\u4E0A\u4F20mp4\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8981\u8D85\u8FC7500M\uFF0C\u6700\u591A\u652F\u6301\u4E0A\u4F205\u4E2A\uFF0C\u652F\u6301\u89C6\u9891\u683C\u5F0F\uFF1Amp4\u3001mov\u3001m4v\u30013gp\u3001avi\u3001webm" })), _jsxs(Stack, __assign({ direction: "row", alignItems: "center" }, { children: [_jsxs(CustomUploadButtonRoot, { children: [_jsx(Upload, __assign({}, uploadProps, { children: _jsx(Button, __assign({ variant: "outlined", color: "inherit", icon: _jsx(AddIcon, {}) }, { children: "\u4E0A\u4F20\u89C6\u9891" })) })), _jsx(Tooltip, __assign({ title: "\u8BF7\u52FF\u4E0A\u4F20\u8272\u60C5\u53CA\u53CD\u52A8\u8FDD\u89C4\u89C6\u9891\uFF0C\u5EFA\u8BAE\u4F7F\u7528360\u6D4F\u89C8\u5668\u3002 \u5EFA\u8BAE\u4E0A\u4F20mp4\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8981\u8D85\u8FC7500M\uFF0C\u652F\u6301\u89C6\u9891\u683C\u5F0F\uFF1Amp4\u3001mov\u3001m4v\u30013gp\u3001avi\u3001webm\uFF0C\u652F\u6301\u7F16\u7801\u683C\u5F0F\uFF1AH.264\u3001HEV4\u3001 MPRG-4\u3001VP9" }, { children: _jsx("span", __assign({ style: { display: 'flex', alignItems: 'center', marginLeft: 8 } }, { children: _jsx(InfoIcon, { sx: { fontSize: 18, color: 'rgb(118, 118, 118)' } }) })) }))] }), _jsx(Box, __assign({ ml: 0.5 }, { children: _jsx(Checkbox, { checked: mediaState.appliedAllPosition, label: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u5E94\u7528\u5230\u6240\u6709AI\u89C6\u9891" })), onChange: function (e, checked) { return setMediaState({ appliedAllPosition: checked }); } }) }))] }))] }), _jsx(Box, __assign({ sx: { maxHeight: 'calc(100vh - 150px)', overflow: 'auto', flexGrow: 1 } }, { children: (mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl) || loading ? (_jsx(Box, __assign({ loading: loading, sx: { width: 160, height: 286, margin: 'auto', cursor: 'pointer' } }, { children: _jsx("video", { width: 160, height: 286, src: mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl, controls: true }) }))) : (_jsx(Upload, __assign({}, uploadProps, { children: _jsxs(CustomUploadCardRoot, { children: [_jsxs(CustomUploadCardTitle, { children: [_jsx(SvgIcon, { name: "video" }), _jsx(Typography, __assign({ variant: "subtitle1", color: "secondary" }, { children: "\u4E0A\u4F20\u89C6\u9891" }))] }), _jsx(Typography, __assign({ variant: "caption", color: "disabled", sx: { mt: 1 } }, { children: "\u62D6\u62FD\u89C6\u9891\u5230\u6B64\u5904\u4E5F\u53EF\u4E0A\u4F20" }))] }) }))) }))] })) }) })));
111
+ }) }), _jsx(Typography, __assign({ variant: "caption", flexWrap: "wrap", width: 344, color: "text.disabled", mb: 2, mt: 1 }, { children: "\u5EFA\u8BAE\u4E0A\u4F20mp4\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8981\u8D85\u8FC7500M\uFF0C\u6700\u591A\u652F\u6301\u4E0A\u4F205\u4E2A\uFF0C\u652F\u6301\u89C6\u9891\u683C\u5F0F\uFF1Amp4\u3001mov\u3001m4v\u30013gp\u3001avi\u3001webm" })), _jsxs(Stack, __assign({ direction: "row", alignItems: "center" }, { children: [_jsx(CustomUploadButtonRoot, { children: _jsx(Upload, __assign({}, uploadProps, { children: _jsx(Button, __assign({ variant: "outlined", color: "inherit", icon: _jsx(AddIcon, {}) }, { children: "\u4E0A\u4F20\u89C6\u9891" })) })) }), _jsx(Box, __assign({ ml: 2 }, { children: _jsx(Checkbox, { checked: mediaState.appliedAllPosition, label: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u5E94\u7528\u5230\u6240\u6709AI\u89C6\u9891" })), onChange: function (e, checked) { return setMediaState({ appliedAllPosition: checked }); } }) }))] }))] }), _jsx(Box, __assign({ sx: { maxHeight: 'calc(100vh - 150px)', overflow: 'auto', flexGrow: 1 } }, { children: (mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl) || loading ? (_jsx(Box, __assign({ loading: loading, sx: { width: 160, height: 286, margin: 'auto', cursor: 'pointer' } }, { children: _jsx("video", { width: 160, height: 286, src: mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl, controls: true }) }))) : (_jsx(Upload, __assign({}, uploadProps, { children: _jsxs(CustomUploadCardRoot, { children: [_jsxs(CustomUploadCardTitle, { children: [_jsx(SvgIcon, { name: "video" }), _jsx(Typography, __assign({ variant: "subtitle1", color: "secondary" }, { children: "\u4E0A\u4F20\u89C6\u9891" }))] }), _jsx(Typography, __assign({ variant: "caption", color: "disabled", sx: { mt: 1 } }, { children: "\u62D6\u62FD\u89C6\u9891\u5230\u6B64\u5904\u4E5F\u53EF\u4E0A\u4F20" }))] }) }))) }))] })) }) })));
112
112
  };
113
113
  export default BootVideo;
@@ -20,7 +20,7 @@ var __rest = (this && this.__rest) || function (s, e) {
20
20
  }
21
21
  return t;
22
22
  };
23
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
23
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
24
24
  import { DISABLED_REPEAT_TYPE, IS_AI_ANALYSIS, TEST_TYPE_READONLY } from "../../../../constants/ai-question";
25
25
  import { useQuestionModelStore } from "../../../../store/ai-question/question-model-store";
26
26
  import { useUpdateQuestionStore } from "../../../../store/ai-question/question-update-store";
@@ -72,8 +72,8 @@ var QuestionModelListItem = function (props) {
72
72
  }
73
73
  return questions.map(function (v) { return v.content; }).join('\n');
74
74
  }, [questions]);
75
- return (_jsxs(Paper, __assign({ variant: "outlined", sx: { display: 'block', mt: 2 } }, { children: [_jsxs(Box, __assign({ display: "flex", borderBottom: isAiAnalysis ? '1px solid rgba(0, 0, 0, 0.08)' : 'none' }, { children: [_jsx(Box, __assign({ width: 40, display: "flex", alignItems: "center", justifyContent: "center", sx: { cursor: 'move' } }, { children: _jsx(DragIndicatorIcon, { className: "dragHandle" }) })), _jsxs(Box, __assign({ flex: "1 0", padding: "16px 0" }, { children: [_jsxs(Box, __assign({ display: "flex", justifyContent: "space-between" }, { children: [_jsxs(Box, __assign({ flex: "1 0", display: "flex", alignItems: "center" }, { children: [_jsx(Typography, __assign({ variant: "subtitle1" }, { children: name })), category === null || category === void 0 ? void 0 : category.map(function (label) {
75
+ return (_jsxs(Paper, __assign({ variant: "outlined", sx: { display: 'block', mt: 2 } }, { children: [_jsxs(Box, __assign({ display: "flex", borderBottom: "1px solid rgba(0, 0, 0, 0.08)" }, { children: [_jsx(Box, __assign({ width: 40, display: "flex", alignItems: "center", justifyContent: "center", sx: { cursor: 'move' } }, { children: _jsx(DragIndicatorIcon, { className: "dragHandle" }) })), _jsxs(Box, __assign({ flex: "1 0", padding: "16px 0" }, { children: [_jsxs(Box, __assign({ display: "flex", justifyContent: "space-between" }, { children: [_jsxs(Box, __assign({ flex: "1 0", display: "flex", alignItems: "center" }, { children: [_jsx(Typography, __assign({ variant: "subtitle1" }, { children: name })), category === null || category === void 0 ? void 0 : category.map(function (label) {
76
76
  return label && (_jsx(Tooltip, __assign({ title: "".concat(label), placement: "bottom" }, { children: _jsx(Chip, { color: "default", label: label, size: "medium", sx: { ml: 1, maxWidth: '158px', overflow: 'hidden', whiteSpace: 'nowrap', textOverflow: 'ellipsis' } }, label) })));
77
- }), aiType === 2 && _jsx(Chip, { variant: "filled", color: "primary", label: "AI\u8BC4\u5206", size: "medium", sx: { ml: 1 } }), _jsx(Typography, __assign({ sx: { ml: 2 }, variant: "body2", color: "secondary" }, { children: getSecondToTime(Number(duration)) }))] })), _jsxs(Box, __assign({ width: 62, mr: 1, textAlign: "right" }, { children: [!TEST_TYPE_READONLY.includes(type) && (_jsx(IconButton, __assign({ size: "small", onClick: handleEdit }, { children: _jsx(EditIcon, {}) }))), _jsx(IconButton, __assign({ size: "small", onClick: handleRemove }, { children: _jsx(DeleteIcon, {}) }))] }))] })), _jsxs(Box, __assign({ mt: 1, pr: 2, display: "flex", alignItems: "center", justifyContent: "space-between" }, { children: [_jsx(Typography, __assign({ variant: "body2", color: "secondary" }, { children: formatQuestion })), _jsxs(Typography, __assign({ sx: { ml: 2, flexShrink: 0 }, variant: "caption", color: "secondary", alignSelf: "flex-end" }, { children: ["\u56DE\u7B54\u65F6\u957F:\u00A0", getSecondToTime(Number(duration))] }))] }))] }))] })), isAiAnalysis && (_jsxs(Stack, __assign({ direction: "row", justifyContent: "space-between", spacing: 1 }, { children: [_jsxs(Box, __assign({ display: "flex", alignItems: "center", padding: "3px 0 3px 40px" }, { children: [_jsx(Typography, __assign({ variant: "body2" }, { children: "\u6743\u91CD\u5360\u6BD4\uFF1A" })), _jsx(Input, { sx: { width: 82 }, size: "small", value: weight, endAdornment: "%", disabled: disabledWeight, onChange: handleWeightChange, onBlur: handleWeightBlur }), _jsx(Tooltip, __assign({ title: "AI\u6D4B\u8BC4\u9898\u53EF\u4EE5\u8BBE\u7F6E\u6743\u91CD\uFF0C\u7CFB\u7EDF\u5BF9\u5019\u9009\u4EBA\u89C6\u9891\u9762\u8BD5\u7ED3\u679C\u4F1A\u52A0\u5165\u6743\u91CD\u8FDB\u884C\u8BA1\u7B97\uFF0C\u5F97\u51FAAI\u89C6\u9891\u9762\u8BD5\u5F97\u5206\u3002\u8BBE\u7F6E\u540E5\u5206\u949F\u8D77\u6548" }, { children: _jsx("span", __assign({ style: { display: 'flex', alignItems: 'center', marginLeft: '8px' } }, { children: _jsx(InfoIcon, { sx: { fontSize: 14, color: 'rgba(0, 0, 0, 0.26)' } }) })) }))] })), !DISABLED_REPEAT_TYPE.includes(type) && (_jsx(Stack, __assign({ direction: "row" }, { children: _jsx(Switch, { sx: { flexShrink: 0, ml: 2, mr: 2 }, size: "small", checked: answerStatus === 1, label: _jsx(Typography, __assign({ fontSize: 12, lineHeight: 1.5, color: "rgba(0, 0, 0, 0.56)" }, { children: "\u5141\u8BB8\u91CD\u590D\u7B54\u9898" })), onChange: handleAnswerStatus }) })))] })))] })));
77
+ }), aiType === 2 && _jsx(Chip, { variant: "filled", color: "primary", label: "AI\u8BC4\u5206", size: "medium", sx: { ml: 1 } })] })), _jsxs(Box, __assign({ width: 62, mr: 1, textAlign: "right" }, { children: [!TEST_TYPE_READONLY.includes(type) && (_jsx(IconButton, __assign({ size: "small", onClick: handleEdit }, { children: _jsx(EditIcon, {}) }))), _jsx(IconButton, __assign({ size: "small", onClick: handleRemove }, { children: _jsx(DeleteIcon, {}) }))] }))] })), _jsxs(Box, __assign({ mt: 1, pr: 2, display: "flex", alignItems: "center", justifyContent: "space-between" }, { children: [_jsx(Typography, __assign({ variant: "body2", color: "secondary" }, { children: formatQuestion })), _jsxs(Typography, __assign({ sx: { ml: 2, flexShrink: 0 }, variant: "caption", color: "secondary", alignSelf: "flex-end" }, { children: ["\u56DE\u7B54\u65F6\u957F:\u00A0", getSecondToTime(Number(duration))] }))] }))] }))] })), _jsxs(Stack, __assign({ direction: "row", justifyContent: "space-between", spacing: 1, height: 42 }, { children: [_jsx(Box, __assign({ display: "flex", alignItems: "center", padding: "3px 0 3px 40px" }, { children: isAiAnalysis && (_jsxs(_Fragment, { children: [_jsx(Typography, __assign({ variant: "body2" }, { children: "\u6743\u91CD\u5360\u6BD4\uFF1A" })), _jsx(Input, { sx: { width: 82 }, size: "small", value: weight, endAdornment: "%", disabled: disabledWeight, onChange: handleWeightChange, onBlur: handleWeightBlur }), _jsx(Tooltip, __assign({ title: "AI\u6D4B\u8BC4\u9898\u53EF\u4EE5\u8BBE\u7F6E\u6743\u91CD\uFF0C\u7CFB\u7EDF\u5BF9\u5019\u9009\u4EBA\u89C6\u9891\u9762\u8BD5\u7ED3\u679C\u4F1A\u52A0\u5165\u6743\u91CD\u8FDB\u884C\u8BA1\u7B97\uFF0C\u5F97\u51FAAI\u89C6\u9891\u9762\u8BD5\u5F97\u5206\u3002\u8BBE\u7F6E\u540E5\u5206\u949F\u8D77\u6548" }, { children: _jsx("span", __assign({ style: { display: 'flex', alignItems: 'center', marginLeft: '8px' } }, { children: _jsx(InfoIcon, { sx: { fontSize: 14, color: 'rgba(0, 0, 0, 0.26)' } }) })) }))] })) })), !DISABLED_REPEAT_TYPE.includes(type) && (_jsx(Stack, __assign({ direction: "row" }, { children: _jsx(Switch, { sx: { flexShrink: 0, ml: 2, mr: 2 }, size: "small", checked: answerStatus === 1, label: _jsx(Typography, __assign({ fontSize: 12, lineHeight: 1.5, color: "rgba(0, 0, 0, 0.56)" }, { children: "\u5141\u8BB8\u91CD\u590D\u7B54\u9898" })), onChange: handleAnswerStatus }) })))] }))] })));
78
78
  };
79
79
  export default memo(QuestionModelListItem);
@@ -47,7 +47,7 @@ var QuestionModelList = function () {
47
47
  var combineTokens = selctedAbilitys.length > 0 ? selctedAbilitys : aiAbilityList.filter(function (v) { return v.isAI; }).map(function (item) { return item.token; });
48
48
  console.log(combineTokens);
49
49
  var random = aiEvaluationData[0].list.filter(function (item) { return combineTokens === null || combineTokens === void 0 ? void 0 : combineTokens.includes(item === null || item === void 0 ? void 0 : item.token); }).map(function (v) { return v.list; }) || [];
50
- handleUseQuestion(random.map(function (item) { return item[Math.floor(Math.random() * item.length)]; }));
50
+ handleUseQuestion(random.map(function (item) { return (__assign(__assign({}, item[Math.floor(Math.random() * item.length)]), { weight: (100 / combineTokens.length).toFixed(2) })); }));
51
51
  }, [aiAbilityList, aiEvaluationData, handleUseQuestion, selctedAbilitys]);
52
52
  useEffect(function () {
53
53
  if (steps) {
@@ -13,6 +13,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
13
13
  import AiEvaluation from './AiEvaluation';
14
14
  import Skeleton from './Skeleton';
15
15
  import { useAiAbilityListStore } from "../../../../store/ai-ability-select/question-ability-store";
16
+ import { useEnterpriseStore } from "../../../../store/enterprise/enterprise-store";
16
17
  import { PostAiModelQuestions } from "../../../../services/ai-question";
17
18
  import { useQuestionTemplateStore } from "../../../../store/ai-question/question-template-store";
18
19
  import { useRequest } from 'ahooks';
@@ -20,9 +21,10 @@ import { Box } from 'fbm-ui';
20
21
  var QuestionTemplate = function () {
21
22
  var updateAiEvaluationData = useQuestionTemplateStore().updateAiEvaluationData;
22
23
  var selctedAbilitys = useAiAbilityListStore().selctedAbilitys;
23
- var loading = useRequest(function () { return PostAiModelQuestions({ extraAbilityTokens: selctedAbilitys }); }, {
24
+ var enterprise = useEnterpriseStore().enterprise;
25
+ var loading = useRequest(function () { return PostAiModelQuestions(__assign({ extraAbilityTokens: selctedAbilitys }, enterprise)); }, {
24
26
  manual: false,
25
- refreshDeps: [selctedAbilitys],
27
+ refreshDeps: [selctedAbilitys, enterprise],
26
28
  onSuccess: function (_a) {
27
29
  var data = _a.data;
28
30
  return updateAiEvaluationData(data);
@@ -135,7 +135,7 @@ var QuestionForm = forwardRef(function (props, ref) {
135
135
  return (_a = form.values.questions) === null || _a === void 0 ? void 0 : _a.map(function (_, index) { return (_jsxs(Stack, __assign({ direction: "row", justifyContent: "space-between", spacing: 1 }, { children: [_jsx(FormItem, { required: true, name: "questions.".concat(index, ".content"), label: "\u9762\u8BD5\u5185\u5BB9", max: 300, placeholder: "\u9762\u8BD5\u5185\u5BB9\uFF08\u7CFB\u7EDF\u5C06\u6839\u636E\u6B64\u5185\u5BB9\u5411\u5019\u9009\u4EBA\u8FDB\u884C\u8BED\u97F3\u64AD\u62A5\uFF09", sx: { flexGrow: 1 } }, index), form.values.questions.length > 1 && (_jsx(Box, __assign({ height: 84, pt: 1 }, { children: _jsx(IconButton, __assign({ size: "small", onClick: function () {
136
136
  form.setValues(__assign(__assign({}, form.values), { questions: __spreadArray([], form.values.questions.filter(function (_, i) { return i !== index; }), true) }));
137
137
  } }, { children: _jsx(CloseIcon, {}) })) })))] }), index)); });
138
- } })) : (_jsx(VideoVoice, {})), !preview && aiShowType === ADD_QUESTION_TYPE.FREE && (_jsx(RandomQuestion, { category: form.values.category, broadcastType: form.values.broadcastType, onAddCustonQuestion: function () {
138
+ } })) : (_jsx(VideoVoice, {})), !preview && aiShowType === ADD_QUESTION_TYPE.FREE && (_jsx(RandomQuestion, { category: questionCollectionList === null || questionCollectionList === void 0 ? void 0 : questionCollectionList.find(function (v) { var _a; return v.name === ((_a = form.values.category) === null || _a === void 0 ? void 0 : _a.value); }), broadcastType: form.values.broadcastType, onAddCustonQuestion: function () {
139
139
  form.setValues(__assign(__assign({}, form.values), { questions: __spreadArray(__spreadArray([], form.values.questions, true), [{ content: '', videoUrl: '' }], false) }));
140
140
  }, onAddRandomQuestion: function (qs) {
141
141
  form.setValues(__assign(__assign({}, form.values), { questions: __spreadArray(__spreadArray([], form.values.questions, true), qs.map(function (v) { return ({ content: v, videoUrl: '' }); }), true) }));
@@ -9,7 +9,7 @@ var __assign = (this && this.__assign) || function () {
9
9
  };
10
10
  return __assign.apply(this, arguments);
11
11
  };
12
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
12
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
13
13
  import SelectQuestion from './SelectQuestion';
14
14
  import { useUpdateQuestionStore } from "../../../../store/ai-question/question-update-store";
15
15
  import { AddIcon, Box, Button, InfoIcon, Layout, Message, Popactions, Tooltip } from 'fbm-ui';
@@ -46,15 +46,13 @@ var RandomQuestion = function (_a) {
46
46
  },
47
47
  ];
48
48
  var isVideoBroadcast = broadcastType === 2;
49
- var desc = isVideoBroadcast
50
- ? "1. \u89C6\u9891\u5EFA\u8BAE\u7AD6\u7248\uFF0C\u6BD4\u4F8B9\uFF1A16\uFF0C\u683C\u5F0F.mp4\uFF1B\u5019\u9009\u4EBA\u53EF\u91CD\u590D\u542C\u9898\uFF0C\u4F46\u5355\u9898\n \u6700\u591A\u91CD\u590D3\u6B21\u3002\n 2. \u5F53\u9762\u8BD5\u95F4\u4EA4\u4E92\u65B9\u5F0F\u662FAI\u9762\u8BD5\u5B98\u5BF9\u8BDD\u6A21\u5F0F\u65F6\uFF0C\u5019\u9009\u4EBA\u9762\u8BD5\u65F6\u5C06\u81EA\u52A8\u628A\n \u9898\u76EE\u7684\u64AD\u62A5\u65B9\u5F0F\u53D8\u6362\u4E3AAI\u8BED\u97F3\u64AD\u62A5\u65B9\u5F0F\n 3.\u6BCF\u4F4D\u5019\u9009\u4EBA\u968F\u673A1\u9898\uFF0C\u6700\u591A5\u4E2A\u9009\u9879\u3002"
51
- : '每位候选人随机1题,最多5个选项。';
49
+ var desc = isVideoBroadcast ? (_jsxs(_Fragment, { children: ["1. \u89C6\u9891\u5EFA\u8BAE\u7AD6\u7248\uFF0C\u6BD4\u4F8B9\uFF1A16\uFF0C\u683C\u5F0F.mp4\uFF1B\u5019\u9009\u4EBA\u53EF\u91CD\u590D\u542C\u9898\uFF0C\u4F46\u5355\u9898 \u6700\u591A\u91CD\u590D3\u6B21\u3002", _jsx("br", {}), "2. \u5F53\u9762\u8BD5\u95F4\u4EA4\u4E92\u65B9\u5F0F\u662FAI\u9762\u8BD5\u5B98\u5BF9\u8BDD\u6A21\u5F0F\u65F6\uFF0C\u5019\u9009\u4EBA\u9762\u8BD5\u65F6\u5C06\u81EA\u52A8\u628A \u9898\u76EE\u7684\u64AD\u62A5\u65B9\u5F0F\u53D8\u6362\u4E3AAI\u8BED\u97F3\u64AD\u62A5\u65B9\u5F0F", _jsx("br", {}), "3.\u6BCF\u4F4D\u5019\u9009\u4EBA\u968F\u673A1\u9898\uFF0C\u6700\u591A5\u4E2A\u9009\u9879\u3002"] })) : ('每位候选人随机1题,最多5个选项。');
52
50
  var handleVideoBroadcastChange = function (key, checked) {
53
51
  var _a;
54
52
  updateQuestionState({
55
53
  item: __assign(__assign({}, item), { videoBroadcast: __assign(__assign({}, item === null || item === void 0 ? void 0 : item.videoBroadcast), (_a = {}, _a[key] = checked ? 1 : 2, _a)) }),
56
54
  });
57
55
  };
58
- return (_jsxs(Layout, { children: [_jsxs(Stack, __assign({ spacing: 2, mb: 1, direction: "row", alignItems: "center", justifyContent: "space-between" }, { children: [_jsxs(Stack, __assign({ spacing: 1, direction: "row", alignItems: "center" }, { children: [_jsx(Popactions, __assign({ actions: actions, trigger: "click", isClickAway: true }, { children: _jsx(Button, __assign({ variant: "outlined", color: "inherit", icon: _jsx(AddIcon, {}) }, { children: "\u968F\u673A\u9762\u8BD5\u5185\u5BB9" })) })), _jsx(Tooltip, __assign({ title: "".concat(desc), placement: "bottom-start" }, { children: _jsx(Box, __assign({ display: "flex", alignItems: "center", sx: { ml: 1, height: 48 } }, { children: _jsx(InfoIcon, { sx: { color: 'rgba(0, 0, 0, 0.26)', fontSize: 16 } }) })) }))] })), _jsx(Stack, __assign({ spacing: 1, direction: "row", alignItems: "center", mb: 2 }, { children: isVideoBroadcast && (_jsx(FormGroup, { children: _jsxs(Box, __assign({ display: "flex" }, { children: [_jsx(FormControlLabel, { control: _jsx(Checkbox, { checked: ((_b = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _b === void 0 ? void 0 : _b.videoRetry) === 1 }), label: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u91CD\u590D\u542C\u9898" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoRetry', checked); } }), _jsx(FormControlLabel, { control: _jsx(Checkbox, { checked: ((_c = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _c === void 0 ? void 0 : _c.videoSkip) === 1 }), label: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u8DF3\u8FC7" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoSkip', checked); } })] })) })) }))] })), _jsx(SelectQuestion, { token: category === null || category === void 0 ? void 0 : category.token, open: open, onClose: function () { return setOpen(false); }, onOk: onAddRandomQuestion })] }));
56
+ return (_jsxs(Layout, { children: [_jsxs(Stack, __assign({ spacing: 2, mb: 1, direction: "row", alignItems: "center", justifyContent: "space-between", mt: 0.375 }, { children: [_jsxs(Stack, __assign({ spacing: 1, direction: "row", alignItems: "center" }, { children: [_jsx(Popactions, __assign({ actions: actions, trigger: "click", isClickAway: true }, { children: _jsx(Button, __assign({ variant: "outlined", color: "inherit", icon: _jsx(AddIcon, {}) }, { children: "\u968F\u673A\u9762\u8BD5\u5185\u5BB9" })) })), _jsx(Tooltip, __assign({ title: desc, placement: "bottom-start" }, { children: _jsx(Box, __assign({ display: "flex", alignItems: "center", sx: { ml: 1, height: 48 } }, { children: _jsx(InfoIcon, { sx: { color: 'rgba(0, 0, 0, 0.26)', fontSize: 16 } }) })) }))] })), _jsx(Stack, __assign({ spacing: 1, direction: "row", alignItems: "center", mb: 2 }, { children: isVideoBroadcast && (_jsx(FormGroup, { children: _jsxs(Box, __assign({ display: "flex" }, { children: [_jsx(FormControlLabel, { control: _jsx(Checkbox, { checked: ((_b = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _b === void 0 ? void 0 : _b.videoRetry) === 1 }), label: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u91CD\u590D\u542C\u9898" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoRetry', checked); } }), _jsx(FormControlLabel, { control: _jsx(Checkbox, { checked: ((_c = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _c === void 0 ? void 0 : _c.videoSkip) === 1 }), label: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u8DF3\u8FC7" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoSkip', checked); } })] })) })) }))] })), _jsx(SelectQuestion, { token: category === null || category === void 0 ? void 0 : category.token, open: open, onClose: function () { return setOpen(false); }, onOk: onAddRandomQuestion })] }));
59
57
  };
60
58
  export default RandomQuestion;
@@ -103,8 +103,8 @@ var QuestionUpdate = function () {
103
103
  setSwitchTypeOpen(false);
104
104
  (_a = formRef === null || formRef === void 0 ? void 0 : formRef.current) === null || _a === void 0 ? void 0 : _a.setFormValues({ broadcastType: defaultQuestionParams.broadcastType });
105
105
  updateQuestionState({ aiShowType: ADD_QUESTION_TYPE.LANGUAGE });
106
- } }, { children: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u8DDF\u8BFB\u80FD\u529B" })) }))] }));
107
- return (_jsxs(Box, __assign({ display: "flex", alignItems: "center", height: 56 }, { children: [_jsx(Typography, __assign({ ml: 3, variant: "subtitle1" }, { children: aiShowType === ADD_QUESTION_TYPE.FREE ? '自由作答' : '跟读能力' })), _jsx(Popover, __assign({ open: switchTypeOpen, content: content, onClickAway: function () { return setSwitchTypeOpen(false); } }, { children: _jsx(Button, __assign({ variant: "text", size: "small", sx: { fontSize: 12, color: 'rgb(87, 107, 149)' }, onClick: function () { return setSwitchTypeOpen(true); } }, { children: "\u5207\u6362\u9898\u578B" })) }))] })));
106
+ } }, { children: _jsx(Typography, __assign({ variant: "body2" }, { children: "\u6717\u8BFB\u9898" })) }))] }));
107
+ return (_jsxs(Box, __assign({ display: "flex", alignItems: "center", height: 56 }, { children: [_jsx(Typography, __assign({ ml: 3, variant: "subtitle1" }, { children: aiShowType === ADD_QUESTION_TYPE.FREE ? '自由作答' : '朗读题' })), _jsx(Popover, __assign({ open: switchTypeOpen, content: content, onClickAway: function () { return setSwitchTypeOpen(false); } }, { children: _jsx(Button, __assign({ variant: "text", size: "small", sx: { fontSize: 12, color: 'rgb(87, 107, 149)' }, onClick: function () { return setSwitchTypeOpen(true); } }, { children: "\u5207\u6362\u9898\u578B" })) }))] })));
108
108
  };
109
109
  var getModelParams = useCallback(function (values, isSubmit) {
110
110
  return new Promise(function (resolve, reject) {
@@ -3,7 +3,11 @@ import { createGlobalStore } from 'hox';
3
3
  import { useState } from 'react';
4
4
  export var useAiAbilityListStore = (_a = createGlobalStore(function () {
5
5
  var _a = useState([]), aiAbilityList = _a[0], setAiAbilityList = _a[1];
6
- var _b = useState([]), selctedAbilitys = _b[0], setSelctedAbilitys = _b[1];
6
+ var _b = useState([
7
+ '5j7aylYmY1b2syzKbal3RS0P80',
8
+ 'V8aFzLMHHw3j3bNyAgiDRS0P80',
9
+ 'c3RANdCHEAP597Gzf0OWRS0P80',
10
+ ]), selctedAbilitys = _b[0], setSelctedAbilitys = _b[1];
7
11
  return {
8
12
  selctedAbilitys: selctedAbilitys,
9
13
  setSelctedAbilitys: setSelctedAbilitys,
@@ -10,11 +10,11 @@ var __assign = (this && this.__assign) || function () {
10
10
  return __assign.apply(this, arguments);
11
11
  };
12
12
  var _a;
13
- import { useCallback, useState } from 'react';
14
- import { createGlobalStore } from 'hox';
15
- import update from 'immutability-helper';
16
13
  import { IS_AI_ANALYSIS } from "../../constants/ai-question";
17
14
  import { computeDecimalValue, formatNumberDecimal, uniqueId } from "../../utils/utils";
15
+ import { createGlobalStore } from 'hox';
16
+ import update from 'immutability-helper';
17
+ import { useCallback, useState } from 'react';
18
18
  export var useQuestionModelStore = (_a = createGlobalStore(function () {
19
19
  var _a = useState(), questionModelData = _a[0], updateModel = _a[1];
20
20
  var _b = (questionModelData || {}).steps, steps = _b === void 0 ? [] : _b;
@@ -0,0 +1,29 @@
1
+ /// <reference types="react" />
2
+ export declare const useEnterpriseStore: (depsFn?: import("hox/es/types").DepsFn<{
3
+ enterprise: {
4
+ jobToken?: string | undefined;
5
+ thirdToken?: string | undefined;
6
+ };
7
+ setEnterprise: import("react").Dispatch<import("react").SetStateAction<{
8
+ jobToken?: string | undefined;
9
+ thirdToken?: string | undefined;
10
+ }>>;
11
+ }> | undefined) => {
12
+ enterprise: {
13
+ jobToken?: string | undefined;
14
+ thirdToken?: string | undefined;
15
+ };
16
+ setEnterprise: import("react").Dispatch<import("react").SetStateAction<{
17
+ jobToken?: string | undefined;
18
+ thirdToken?: string | undefined;
19
+ }>>;
20
+ }, getEnterpriseStore: () => {
21
+ enterprise: {
22
+ jobToken?: string | undefined;
23
+ thirdToken?: string | undefined;
24
+ };
25
+ setEnterprise: import("react").Dispatch<import("react").SetStateAction<{
26
+ jobToken?: string | undefined;
27
+ thirdToken?: string | undefined;
28
+ }>>;
29
+ } | undefined;
@@ -0,0 +1,13 @@
1
+ var _a;
2
+ import { createGlobalStore } from 'hox';
3
+ import { useState } from 'react';
4
+ export var useEnterpriseStore = (_a = createGlobalStore(function () {
5
+ var _a = useState({
6
+ jobToken: '',
7
+ thirdToken: '',
8
+ }), enterprise = _a[0], setEnterprise = _a[1];
9
+ return {
10
+ enterprise: enterprise,
11
+ setEnterprise: setEnterprise,
12
+ };
13
+ }), _a[0]), getEnterpriseStore = _a[1];
@@ -13,7 +13,7 @@ exports.ADD_QUESTION_TYPE_LIST = [
13
13
  },
14
14
  {
15
15
  type: LANGUAGE,
16
- title: '语言能力题',
16
+ title: '朗读题',
17
17
  desc: '候选人根据所提供的文案进行朗读。',
18
18
  },
19
19
  ];
@@ -18,6 +18,7 @@ var jsx_runtime_1 = require("react/jsx-runtime");
18
18
  var AiAbilityList_1 = __importDefault(require("./components/AiAbilityList"));
19
19
  var ai_ability_1 = require("../../services/ai-ability");
20
20
  var question_ability_store_1 = require("../../store/ai-ability-select/question-ability-store");
21
+ var enterprise_store_1 = require("../../store/enterprise/enterprise-store");
21
22
  var ScrollDialogContent_1 = __importDefault(require("../../components/ScrollDialogContent"));
22
23
  var ahooks_1 = require("ahooks");
23
24
  var fbm_ui_1 = require("fbm-ui");
@@ -25,7 +26,8 @@ var mui_1 = require("fbm-ui/lib/mui");
25
26
  var react_1 = require("react");
26
27
  var AiAbilitySelectRoot = (0, react_1.forwardRef)(function (_a, ref) {
27
28
  var jobToken = _a.jobToken, thirdToken = _a.thirdToken;
28
- var _b = (0, question_ability_store_1.useAiAbilityListStore)(), aiAbilityList = _b.aiAbilityList, setAiAbilityList = _b.setAiAbilityList, selctedAbilitys = _b.selctedAbilitys;
29
+ var _b = (0, question_ability_store_1.useAiAbilityListStore)(), aiAbilityList = _b.aiAbilityList, setAiAbilityList = _b.setAiAbilityList;
30
+ var setEnterprise = (0, enterprise_store_1.useEnterpriseStore)().setEnterprise;
29
31
  var data = (0, ahooks_1.useRequest)(function () { return (0, ai_ability_1.GetAiAbilityList)({ jobToken: jobToken, thirdToken: thirdToken }); }, {
30
32
  refreshDeps: [jobToken, thirdToken],
31
33
  }).data;
@@ -33,8 +35,11 @@ var AiAbilitySelectRoot = (0, react_1.forwardRef)(function (_a, ref) {
33
35
  setAiAbilityList((data === null || data === void 0 ? void 0 : data.data.list) || []);
34
36
  // eslint-disable-next-line react-hooks/exhaustive-deps
35
37
  }, [data]);
36
- console.log(selctedAbilitys);
37
- return ((0, jsx_runtime_1.jsx)(ScrollDialogContent_1.default, __assign({ ref: ref }, { children: (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", flexDirection: "column", width: 760 }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ spacing: 2, mb: 2 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body1", fontWeight: 500 }, { children: "\u8BF7\u9009\u62E9\u8981\u4F18\u5148\u4F7F\u7528\u7684\u8003\u5BDF\u80FD\u529B\uFF0C\u4E5F\u53EF\u4EE5\u70B9\u51FB\u300C\u4E0B\u4E00\u6B65\u300D\u76F4\u63A5\u51FA\u9898" })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", spacing: 1, alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)("img", { src: "//webcdn.fbmms.cn/assets/XXRf/bdUI9qZoTx-l2k_OHTotn", alt: "", width: 38, height: 16 }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "caption", color: "textSecondary" }, { children: "AI\u6839\u636E\u5C97\u4F4D\u4FE1\u606F\u751F\u6210\u7684\u80FD\u529B\uFF0C\u521B\u5EFA\u5B8C\u6B65\u9AA4\u540E\uFF0C\u4F1A\u81EA\u52A8\u5C06\u9009\u62E9\u7684\u65B0\u589E\u80FD\u529B\u52A0\u5165\u5230\u8BBE\u7F6E\u9875\u7684\u8003\u5BDF\u80FD\u529B\u5217\u8868\u4E2D\u3002" }))] }))] })), (0, jsx_runtime_1.jsx)(AiAbilityList_1.default, { items: aiAbilityList })] })) })));
38
+ (0, react_1.useEffect)(function () {
39
+ setEnterprise({ jobToken: jobToken, thirdToken: thirdToken });
40
+ // eslint-disable-next-line react-hooks/exhaustive-deps
41
+ }, [jobToken, thirdToken]);
42
+ return ((0, jsx_runtime_1.jsx)(ScrollDialogContent_1.default, __assign({ ref: ref }, { children: (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", flexDirection: "column", width: 760 }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ spacing: 2, mb: 2 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body1", fontWeight: 500 }, { children: "\u8BF7\u9009\u62E9\u8981\u4F18\u5148\u4F7F\u7528\u7684\u8003\u5BDF\u80FD\u529B\uFF0C\u4E5F\u53EF\u4EE5\u70B9\u51FB\u300C\u4E0B\u4E00\u6B65\u300D\u76F4\u63A5\u51FA\u9898" })), (aiAbilityList === null || aiAbilityList === void 0 ? void 0 : aiAbilityList.some(function (v) { return v.isNew; })) && ((0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", spacing: 1, alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)("img", { src: "//webcdn.fbmms.cn/assets/XXRf/bdUI9qZoTx-l2k_OHTotn", alt: "", width: 38, height: 16 }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "caption", color: "textSecondary" }, { children: "AI\u6839\u636E\u5C97\u4F4D\u4FE1\u606F\u751F\u6210\u7684\u80FD\u529B\uFF0C\u521B\u5EFA\u5B8C\u6B65\u9AA4\u540E\uFF0C\u4F1A\u81EA\u52A8\u5C06\u9009\u62E9\u7684\u65B0\u589E\u80FD\u529B\u52A0\u5165\u5230\u8BBE\u7F6E\u9875\u7684\u8003\u5BDF\u80FD\u529B\u5217\u8868\u4E2D\u3002" }))] })))] })), (0, jsx_runtime_1.jsx)(AiAbilityList_1.default, { items: aiAbilityList })] })) })));
38
43
  });
39
44
  AiAbilitySelectRoot.displayName = 'AiAbilitySelectRoot';
40
45
  exports.default = (0, react_1.memo)(AiAbilitySelectRoot);
@@ -113,6 +113,6 @@ var BootVideo = function (props) {
113
113
  return ((0, jsx_runtime_1.jsx)(fbm_ui_1.Dialog, __assign({ open: open, title: "\u5B9A\u5236\u9762\u8BD5\u95F4", onClose: onClose, onOk: handleOk, width: 768 }, { children: (0, jsx_runtime_1.jsx)(ScrollDialogContent_1.default, { children: (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ sx: { display: 'flex', justifyContent: 'space-between' } }, { children: [(0, jsx_runtime_1.jsxs)(mui_1.Stack, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body1", fontWeight: 500 }, { children: "\u9762\u8BD5\u95F4\u4E92\u52A8\u65B9\u5F0F" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.RadioGroup, __assign({ defaultValue: "outlined", value: 1 }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Radio, { value: "1", label: "\u4F20\u7EDF\u8BFB\u9898\u6A21\u5F0F" }) })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body1", fontWeight: 500, mt: 3, mb: 2 }, { children: "\u5F15\u5BFC\u89C6\u9891" })), (0, jsx_runtime_1.jsx)(styled_1.CustomUploadedImgRoot, { children: mediaList.map(function (_a) {
114
114
  var videoUrl = _a.videoUrl, frameUrl = _a.frameUrl;
115
115
  return ((0, jsx_runtime_1.jsx)("img", { src: frameUrl, style: { borderColor: (mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl) === videoUrl ? '#4CAF50' : 'transparent' }, height: 100, alt: "", onClick: function () { return handleSelectVideo(videoUrl, frameUrl); } }, videoUrl));
116
- }) }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "caption", flexWrap: "wrap", width: 344, color: "text.disabled", mb: 2, mt: 1 }, { children: "\u5EFA\u8BAE\u4E0A\u4F20mp4\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8981\u8D85\u8FC7500M\uFF0C\u6700\u591A\u652F\u6301\u4E0A\u4F205\u4E2A\uFF0C\u652F\u6301\u89C6\u9891\u683C\u5F0F\uFF1Amp4\u3001mov\u3001m4v\u30013gp\u3001avi\u3001webm" })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsxs)(styled_1.CustomUploadButtonRoot, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Upload, __assign({}, uploadProps, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", color: "inherit", icon: (0, jsx_runtime_1.jsx)(fbm_ui_1.AddIcon, {}) }, { children: "\u4E0A\u4F20\u89C6\u9891" })) })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: "\u8BF7\u52FF\u4E0A\u4F20\u8272\u60C5\u53CA\u53CD\u52A8\u8FDD\u89C4\u89C6\u9891\uFF0C\u5EFA\u8BAE\u4F7F\u7528360\u6D4F\u89C8\u5668\u3002 \u5EFA\u8BAE\u4E0A\u4F20mp4\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8981\u8D85\u8FC7500M\uFF0C\u652F\u6301\u89C6\u9891\u683C\u5F0F\uFF1Amp4\u3001mov\u3001m4v\u30013gp\u3001avi\u3001webm\uFF0C\u652F\u6301\u7F16\u7801\u683C\u5F0F\uFF1AH.264\u3001HEV4\u3001 MPRG-4\u3001VP9" }, { children: (0, jsx_runtime_1.jsx)("span", __assign({ style: { display: 'flex', alignItems: 'center', marginLeft: 8 } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoIcon, { sx: { fontSize: 18, color: 'rgb(118, 118, 118)' } }) })) }))] }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ ml: 0.5 }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Checkbox, { checked: mediaState.appliedAllPosition, label: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2" }, { children: "\u5E94\u7528\u5230\u6240\u6709AI\u89C6\u9891" })), onChange: function (e, checked) { return setMediaState({ appliedAllPosition: checked }); } }) }))] }))] }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ sx: { maxHeight: 'calc(100vh - 150px)', overflow: 'auto', flexGrow: 1 } }, { children: (mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl) || loading ? ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ loading: loading, sx: { width: 160, height: 286, margin: 'auto', cursor: 'pointer' } }, { children: (0, jsx_runtime_1.jsx)("video", { width: 160, height: 286, src: mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl, controls: true }) }))) : ((0, jsx_runtime_1.jsx)(fbm_ui_1.Upload, __assign({}, uploadProps, { children: (0, jsx_runtime_1.jsxs)(styled_1.CustomUploadCardRoot, { children: [(0, jsx_runtime_1.jsxs)(styled_1.CustomUploadCardTitle, { children: [(0, jsx_runtime_1.jsx)(SvgIcon_1.default, { name: "video" }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle1", color: "secondary" }, { children: "\u4E0A\u4F20\u89C6\u9891" }))] }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "caption", color: "disabled", sx: { mt: 1 } }, { children: "\u62D6\u62FD\u89C6\u9891\u5230\u6B64\u5904\u4E5F\u53EF\u4E0A\u4F20" }))] }) }))) }))] })) }) })));
116
+ }) }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "caption", flexWrap: "wrap", width: 344, color: "text.disabled", mb: 2, mt: 1 }, { children: "\u5EFA\u8BAE\u4E0A\u4F20mp4\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8981\u8D85\u8FC7500M\uFF0C\u6700\u591A\u652F\u6301\u4E0A\u4F205\u4E2A\uFF0C\u652F\u6301\u89C6\u9891\u683C\u5F0F\uFF1Amp4\u3001mov\u3001m4v\u30013gp\u3001avi\u3001webm" })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(styled_1.CustomUploadButtonRoot, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Upload, __assign({}, uploadProps, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", color: "inherit", icon: (0, jsx_runtime_1.jsx)(fbm_ui_1.AddIcon, {}) }, { children: "\u4E0A\u4F20\u89C6\u9891" })) })) }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ ml: 2 }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Checkbox, { checked: mediaState.appliedAllPosition, label: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2" }, { children: "\u5E94\u7528\u5230\u6240\u6709AI\u89C6\u9891" })), onChange: function (e, checked) { return setMediaState({ appliedAllPosition: checked }); } }) }))] }))] }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ sx: { maxHeight: 'calc(100vh - 150px)', overflow: 'auto', flexGrow: 1 } }, { children: (mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl) || loading ? ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ loading: loading, sx: { width: 160, height: 286, margin: 'auto', cursor: 'pointer' } }, { children: (0, jsx_runtime_1.jsx)("video", { width: 160, height: 286, src: mediaState === null || mediaState === void 0 ? void 0 : mediaState.mediaUrl, controls: true }) }))) : ((0, jsx_runtime_1.jsx)(fbm_ui_1.Upload, __assign({}, uploadProps, { children: (0, jsx_runtime_1.jsxs)(styled_1.CustomUploadCardRoot, { children: [(0, jsx_runtime_1.jsxs)(styled_1.CustomUploadCardTitle, { children: [(0, jsx_runtime_1.jsx)(SvgIcon_1.default, { name: "video" }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle1", color: "secondary" }, { children: "\u4E0A\u4F20\u89C6\u9891" }))] }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "caption", color: "disabled", sx: { mt: 1 } }, { children: "\u62D6\u62FD\u89C6\u9891\u5230\u6B64\u5904\u4E5F\u53EF\u4E0A\u4F20" }))] }) }))) }))] })) }) })));
117
117
  };
118
118
  exports.default = BootVideo;
@@ -74,8 +74,8 @@ var QuestionModelListItem = function (props) {
74
74
  }
75
75
  return questions.map(function (v) { return v.content; }).join('\n');
76
76
  }, [questions]);
77
- return ((0, jsx_runtime_1.jsxs)(mui_1.Paper, __assign({ variant: "outlined", sx: { display: 'block', mt: 2 } }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", borderBottom: isAiAnalysis ? '1px solid rgba(0, 0, 0, 0.08)' : 'none' }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ width: 40, display: "flex", alignItems: "center", justifyContent: "center", sx: { cursor: 'move' } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.DragIndicatorIcon, { className: "dragHandle" }) })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ flex: "1 0", padding: "16px 0" }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", justifyContent: "space-between" }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ flex: "1 0", display: "flex", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle1" }, { children: name })), category === null || category === void 0 ? void 0 : category.map(function (label) {
77
+ return ((0, jsx_runtime_1.jsxs)(mui_1.Paper, __assign({ variant: "outlined", sx: { display: 'block', mt: 2 } }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", borderBottom: "1px solid rgba(0, 0, 0, 0.08)" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ width: 40, display: "flex", alignItems: "center", justifyContent: "center", sx: { cursor: 'move' } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.DragIndicatorIcon, { className: "dragHandle" }) })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ flex: "1 0", padding: "16px 0" }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", justifyContent: "space-between" }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ flex: "1 0", display: "flex", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "subtitle1" }, { children: name })), category === null || category === void 0 ? void 0 : category.map(function (label) {
78
78
  return label && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: "".concat(label), placement: "bottom" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Chip, { color: "default", label: label, size: "medium", sx: { ml: 1, maxWidth: '158px', overflow: 'hidden', whiteSpace: 'nowrap', textOverflow: 'ellipsis' } }, label) })));
79
- }), aiType === 2 && (0, jsx_runtime_1.jsx)(fbm_ui_1.Chip, { variant: "filled", color: "primary", label: "AI\u8BC4\u5206", size: "medium", sx: { ml: 1 } }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ sx: { ml: 2 }, variant: "body2", color: "secondary" }, { children: (0, utils_1.getSecondToTime)(Number(duration)) }))] })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ width: 62, mr: 1, textAlign: "right" }, { children: [!ai_question_1.TEST_TYPE_READONLY.includes(type) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ size: "small", onClick: handleEdit }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.EditIcon, {}) }))), (0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ size: "small", onClick: handleRemove }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.DeleteIcon, {}) }))] }))] })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ mt: 1, pr: 2, display: "flex", alignItems: "center", justifyContent: "space-between" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", color: "secondary" }, { children: formatQuestion })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Typography, __assign({ sx: { ml: 2, flexShrink: 0 }, variant: "caption", color: "secondary", alignSelf: "flex-end" }, { children: ["\u56DE\u7B54\u65F6\u957F:\u00A0", (0, utils_1.getSecondToTime)(Number(duration))] }))] }))] }))] })), isAiAnalysis && ((0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", justifyContent: "space-between", spacing: 1 }, { children: [(0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", padding: "3px 0 3px 40px" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2" }, { children: "\u6743\u91CD\u5360\u6BD4\uFF1A" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Input, { sx: { width: 82 }, size: "small", value: weight, endAdornment: "%", disabled: disabledWeight, onChange: handleWeightChange, onBlur: handleWeightBlur }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: "AI\u6D4B\u8BC4\u9898\u53EF\u4EE5\u8BBE\u7F6E\u6743\u91CD\uFF0C\u7CFB\u7EDF\u5BF9\u5019\u9009\u4EBA\u89C6\u9891\u9762\u8BD5\u7ED3\u679C\u4F1A\u52A0\u5165\u6743\u91CD\u8FDB\u884C\u8BA1\u7B97\uFF0C\u5F97\u51FAAI\u89C6\u9891\u9762\u8BD5\u5F97\u5206\u3002\u8BBE\u7F6E\u540E5\u5206\u949F\u8D77\u6548" }, { children: (0, jsx_runtime_1.jsx)("span", __assign({ style: { display: 'flex', alignItems: 'center', marginLeft: '8px' } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoIcon, { sx: { fontSize: 14, color: 'rgba(0, 0, 0, 0.26)' } }) })) }))] })), !ai_question_1.DISABLED_REPEAT_TYPE.includes(type) && ((0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ direction: "row" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Switch, { sx: { flexShrink: 0, ml: 2, mr: 2 }, size: "small", checked: answerStatus === 1, label: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ fontSize: 12, lineHeight: 1.5, color: "rgba(0, 0, 0, 0.56)" }, { children: "\u5141\u8BB8\u91CD\u590D\u7B54\u9898" })), onChange: handleAnswerStatus }) })))] })))] })));
79
+ }), aiType === 2 && (0, jsx_runtime_1.jsx)(fbm_ui_1.Chip, { variant: "filled", color: "primary", label: "AI\u8BC4\u5206", size: "medium", sx: { ml: 1 } })] })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ width: 62, mr: 1, textAlign: "right" }, { children: [!ai_question_1.TEST_TYPE_READONLY.includes(type) && ((0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ size: "small", onClick: handleEdit }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.EditIcon, {}) }))), (0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ size: "small", onClick: handleRemove }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.DeleteIcon, {}) }))] }))] })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ mt: 1, pr: 2, display: "flex", alignItems: "center", justifyContent: "space-between" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2", color: "secondary" }, { children: formatQuestion })), (0, jsx_runtime_1.jsxs)(fbm_ui_1.Typography, __assign({ sx: { ml: 2, flexShrink: 0 }, variant: "caption", color: "secondary", alignSelf: "flex-end" }, { children: ["\u56DE\u7B54\u65F6\u957F:\u00A0", (0, utils_1.getSecondToTime)(Number(duration))] }))] }))] }))] })), (0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", justifyContent: "space-between", spacing: 1, height: 42 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", padding: "3px 0 3px 40px" }, { children: isAiAnalysis && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2" }, { children: "\u6743\u91CD\u5360\u6BD4\uFF1A" })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Input, { sx: { width: 82 }, size: "small", value: weight, endAdornment: "%", disabled: disabledWeight, onChange: handleWeightChange, onBlur: handleWeightBlur }), (0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: "AI\u6D4B\u8BC4\u9898\u53EF\u4EE5\u8BBE\u7F6E\u6743\u91CD\uFF0C\u7CFB\u7EDF\u5BF9\u5019\u9009\u4EBA\u89C6\u9891\u9762\u8BD5\u7ED3\u679C\u4F1A\u52A0\u5165\u6743\u91CD\u8FDB\u884C\u8BA1\u7B97\uFF0C\u5F97\u51FAAI\u89C6\u9891\u9762\u8BD5\u5F97\u5206\u3002\u8BBE\u7F6E\u540E5\u5206\u949F\u8D77\u6548" }, { children: (0, jsx_runtime_1.jsx)("span", __assign({ style: { display: 'flex', alignItems: 'center', marginLeft: '8px' } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoIcon, { sx: { fontSize: 14, color: 'rgba(0, 0, 0, 0.26)' } }) })) }))] })) })), !ai_question_1.DISABLED_REPEAT_TYPE.includes(type) && ((0, jsx_runtime_1.jsx)(mui_1.Stack, __assign({ direction: "row" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Switch, { sx: { flexShrink: 0, ml: 2, mr: 2 }, size: "small", checked: answerStatus === 1, label: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ fontSize: 12, lineHeight: 1.5, color: "rgba(0, 0, 0, 0.56)" }, { children: "\u5141\u8BB8\u91CD\u590D\u7B54\u9898" })), onChange: handleAnswerStatus }) })))] }))] })));
80
80
  };
81
81
  exports.default = (0, react_1.memo)(QuestionModelListItem);
@@ -52,7 +52,7 @@ var QuestionModelList = function () {
52
52
  var combineTokens = selctedAbilitys.length > 0 ? selctedAbilitys : aiAbilityList.filter(function (v) { return v.isAI; }).map(function (item) { return item.token; });
53
53
  console.log(combineTokens);
54
54
  var random = aiEvaluationData[0].list.filter(function (item) { return combineTokens === null || combineTokens === void 0 ? void 0 : combineTokens.includes(item === null || item === void 0 ? void 0 : item.token); }).map(function (v) { return v.list; }) || [];
55
- handleUseQuestion(random.map(function (item) { return item[Math.floor(Math.random() * item.length)]; }));
55
+ handleUseQuestion(random.map(function (item) { return (__assign(__assign({}, item[Math.floor(Math.random() * item.length)]), { weight: (100 / combineTokens.length).toFixed(2) })); }));
56
56
  }, [aiAbilityList, aiEvaluationData, handleUseQuestion, selctedAbilitys]);
57
57
  (0, react_1.useEffect)(function () {
58
58
  if (steps) {
@@ -18,6 +18,7 @@ var jsx_runtime_1 = require("react/jsx-runtime");
18
18
  var AiEvaluation_1 = __importDefault(require("./AiEvaluation"));
19
19
  var Skeleton_1 = __importDefault(require("./Skeleton"));
20
20
  var question_ability_store_1 = require("../../../../store/ai-ability-select/question-ability-store");
21
+ var enterprise_store_1 = require("../../../../store/enterprise/enterprise-store");
21
22
  var ai_question_1 = require("../../../../services/ai-question");
22
23
  var question_template_store_1 = require("../../../../store/ai-question/question-template-store");
23
24
  var ahooks_1 = require("ahooks");
@@ -25,9 +26,10 @@ var fbm_ui_1 = require("fbm-ui");
25
26
  var QuestionTemplate = function () {
26
27
  var updateAiEvaluationData = (0, question_template_store_1.useQuestionTemplateStore)().updateAiEvaluationData;
27
28
  var selctedAbilitys = (0, question_ability_store_1.useAiAbilityListStore)().selctedAbilitys;
28
- var loading = (0, ahooks_1.useRequest)(function () { return (0, ai_question_1.PostAiModelQuestions)({ extraAbilityTokens: selctedAbilitys }); }, {
29
+ var enterprise = (0, enterprise_store_1.useEnterpriseStore)().enterprise;
30
+ var loading = (0, ahooks_1.useRequest)(function () { return (0, ai_question_1.PostAiModelQuestions)(__assign({ extraAbilityTokens: selctedAbilitys }, enterprise)); }, {
29
31
  manual: false,
30
- refreshDeps: [selctedAbilitys],
32
+ refreshDeps: [selctedAbilitys, enterprise],
31
33
  onSuccess: function (_a) {
32
34
  var data = _a.data;
33
35
  return updateAiEvaluationData(data);
@@ -140,7 +140,7 @@ var QuestionForm = (0, react_1.forwardRef)(function (props, ref) {
140
140
  return (_a = form.values.questions) === null || _a === void 0 ? void 0 : _a.map(function (_, index) { return ((0, jsx_runtime_1.jsxs)(mui_1.Stack, __assign({ direction: "row", justifyContent: "space-between", spacing: 1 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.FormItem, { required: true, name: "questions.".concat(index, ".content"), label: "\u9762\u8BD5\u5185\u5BB9", max: 300, placeholder: "\u9762\u8BD5\u5185\u5BB9\uFF08\u7CFB\u7EDF\u5C06\u6839\u636E\u6B64\u5185\u5BB9\u5411\u5019\u9009\u4EBA\u8FDB\u884C\u8BED\u97F3\u64AD\u62A5\uFF09", sx: { flexGrow: 1 } }, index), form.values.questions.length > 1 && ((0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ height: 84, pt: 1 }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.IconButton, __assign({ size: "small", onClick: function () {
141
141
  form.setValues(__assign(__assign({}, form.values), { questions: __spreadArray([], form.values.questions.filter(function (_, i) { return i !== index; }), true) }));
142
142
  } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.CloseIcon, {}) })) })))] }), index)); });
143
- } })) : ((0, jsx_runtime_1.jsx)(VideoVoice_1.default, {})), !preview && aiShowType === ai_question_1.ADD_QUESTION_TYPE.FREE && ((0, jsx_runtime_1.jsx)(RandomQuestion_1.default, { category: form.values.category, broadcastType: form.values.broadcastType, onAddCustonQuestion: function () {
143
+ } })) : ((0, jsx_runtime_1.jsx)(VideoVoice_1.default, {})), !preview && aiShowType === ai_question_1.ADD_QUESTION_TYPE.FREE && ((0, jsx_runtime_1.jsx)(RandomQuestion_1.default, { category: questionCollectionList === null || questionCollectionList === void 0 ? void 0 : questionCollectionList.find(function (v) { var _a; return v.name === ((_a = form.values.category) === null || _a === void 0 ? void 0 : _a.value); }), broadcastType: form.values.broadcastType, onAddCustonQuestion: function () {
144
144
  form.setValues(__assign(__assign({}, form.values), { questions: __spreadArray(__spreadArray([], form.values.questions, true), [{ content: '', videoUrl: '' }], false) }));
145
145
  }, onAddRandomQuestion: function (qs) {
146
146
  form.setValues(__assign(__assign({}, form.values), { questions: __spreadArray(__spreadArray([], form.values.questions, true), qs.map(function (v) { return ({ content: v, videoUrl: '' }); }), true) }));
@@ -51,15 +51,13 @@ var RandomQuestion = function (_a) {
51
51
  },
52
52
  ];
53
53
  var isVideoBroadcast = broadcastType === 2;
54
- var desc = isVideoBroadcast
55
- ? "1. \u89C6\u9891\u5EFA\u8BAE\u7AD6\u7248\uFF0C\u6BD4\u4F8B9\uFF1A16\uFF0C\u683C\u5F0F.mp4\uFF1B\u5019\u9009\u4EBA\u53EF\u91CD\u590D\u542C\u9898\uFF0C\u4F46\u5355\u9898\n \u6700\u591A\u91CD\u590D3\u6B21\u3002\n 2. \u5F53\u9762\u8BD5\u95F4\u4EA4\u4E92\u65B9\u5F0F\u662FAI\u9762\u8BD5\u5B98\u5BF9\u8BDD\u6A21\u5F0F\u65F6\uFF0C\u5019\u9009\u4EBA\u9762\u8BD5\u65F6\u5C06\u81EA\u52A8\u628A\n \u9898\u76EE\u7684\u64AD\u62A5\u65B9\u5F0F\u53D8\u6362\u4E3AAI\u8BED\u97F3\u64AD\u62A5\u65B9\u5F0F\n 3.\u6BCF\u4F4D\u5019\u9009\u4EBA\u968F\u673A1\u9898\uFF0C\u6700\u591A5\u4E2A\u9009\u9879\u3002"
56
- : '每位候选人随机1题,最多5个选项。';
54
+ var desc = isVideoBroadcast ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: ["1. \u89C6\u9891\u5EFA\u8BAE\u7AD6\u7248\uFF0C\u6BD4\u4F8B9\uFF1A16\uFF0C\u683C\u5F0F.mp4\uFF1B\u5019\u9009\u4EBA\u53EF\u91CD\u590D\u542C\u9898\uFF0C\u4F46\u5355\u9898 \u6700\u591A\u91CD\u590D3\u6B21\u3002", (0, jsx_runtime_1.jsx)("br", {}), "2. \u5F53\u9762\u8BD5\u95F4\u4EA4\u4E92\u65B9\u5F0F\u662FAI\u9762\u8BD5\u5B98\u5BF9\u8BDD\u6A21\u5F0F\u65F6\uFF0C\u5019\u9009\u4EBA\u9762\u8BD5\u65F6\u5C06\u81EA\u52A8\u628A \u9898\u76EE\u7684\u64AD\u62A5\u65B9\u5F0F\u53D8\u6362\u4E3AAI\u8BED\u97F3\u64AD\u62A5\u65B9\u5F0F", (0, jsx_runtime_1.jsx)("br", {}), "3.\u6BCF\u4F4D\u5019\u9009\u4EBA\u968F\u673A1\u9898\uFF0C\u6700\u591A5\u4E2A\u9009\u9879\u3002"] })) : ('每位候选人随机1题,最多5个选项。');
57
55
  var handleVideoBroadcastChange = function (key, checked) {
58
56
  var _a;
59
57
  updateQuestionState({
60
58
  item: __assign(__assign({}, item), { videoBroadcast: __assign(__assign({}, item === null || item === void 0 ? void 0 : item.videoBroadcast), (_a = {}, _a[key] = checked ? 1 : 2, _a)) }),
61
59
  });
62
60
  };
63
- return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Layout, { children: [(0, jsx_runtime_1.jsxs)(mui_2.Stack, __assign({ spacing: 2, mb: 1, direction: "row", alignItems: "center", justifyContent: "space-between" }, { children: [(0, jsx_runtime_1.jsxs)(mui_2.Stack, __assign({ spacing: 1, direction: "row", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Popactions, __assign({ actions: actions, trigger: "click", isClickAway: true }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", color: "inherit", icon: (0, jsx_runtime_1.jsx)(fbm_ui_1.AddIcon, {}) }, { children: "\u968F\u673A\u9762\u8BD5\u5185\u5BB9" })) })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: "".concat(desc), placement: "bottom-start" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", sx: { ml: 1, height: 48 } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoIcon, { sx: { color: 'rgba(0, 0, 0, 0.26)', fontSize: 16 } }) })) }))] })), (0, jsx_runtime_1.jsx)(mui_2.Stack, __assign({ spacing: 1, direction: "row", alignItems: "center", mb: 2 }, { children: isVideoBroadcast && ((0, jsx_runtime_1.jsx)(mui_1.FormGroup, { children: (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex" }, { children: [(0, jsx_runtime_1.jsx)(mui_1.FormControlLabel, { control: (0, jsx_runtime_1.jsx)(mui_1.Checkbox, { checked: ((_b = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _b === void 0 ? void 0 : _b.videoRetry) === 1 }), label: (0, jsx_runtime_1.jsx)(mui_1.Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u91CD\u590D\u542C\u9898" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoRetry', checked); } }), (0, jsx_runtime_1.jsx)(mui_1.FormControlLabel, { control: (0, jsx_runtime_1.jsx)(mui_1.Checkbox, { checked: ((_c = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _c === void 0 ? void 0 : _c.videoSkip) === 1 }), label: (0, jsx_runtime_1.jsx)(mui_1.Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u8DF3\u8FC7" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoSkip', checked); } })] })) })) }))] })), (0, jsx_runtime_1.jsx)(SelectQuestion_1.default, { token: category === null || category === void 0 ? void 0 : category.token, open: open, onClose: function () { return setOpen(false); }, onOk: onAddRandomQuestion })] }));
61
+ return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Layout, { children: [(0, jsx_runtime_1.jsxs)(mui_2.Stack, __assign({ spacing: 2, mb: 1, direction: "row", alignItems: "center", justifyContent: "space-between", mt: 0.375 }, { children: [(0, jsx_runtime_1.jsxs)(mui_2.Stack, __assign({ spacing: 1, direction: "row", alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Popactions, __assign({ actions: actions, trigger: "click", isClickAway: true }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "outlined", color: "inherit", icon: (0, jsx_runtime_1.jsx)(fbm_ui_1.AddIcon, {}) }, { children: "\u968F\u673A\u9762\u8BD5\u5185\u5BB9" })) })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Tooltip, __assign({ title: desc, placement: "bottom-start" }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", sx: { ml: 1, height: 48 } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.InfoIcon, { sx: { color: 'rgba(0, 0, 0, 0.26)', fontSize: 16 } }) })) }))] })), (0, jsx_runtime_1.jsx)(mui_2.Stack, __assign({ spacing: 1, direction: "row", alignItems: "center", mb: 2 }, { children: isVideoBroadcast && ((0, jsx_runtime_1.jsx)(mui_1.FormGroup, { children: (0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex" }, { children: [(0, jsx_runtime_1.jsx)(mui_1.FormControlLabel, { control: (0, jsx_runtime_1.jsx)(mui_1.Checkbox, { checked: ((_b = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _b === void 0 ? void 0 : _b.videoRetry) === 1 }), label: (0, jsx_runtime_1.jsx)(mui_1.Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u91CD\u590D\u542C\u9898" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoRetry', checked); } }), (0, jsx_runtime_1.jsx)(mui_1.FormControlLabel, { control: (0, jsx_runtime_1.jsx)(mui_1.Checkbox, { checked: ((_c = item === null || item === void 0 ? void 0 : item.videoBroadcast) === null || _c === void 0 ? void 0 : _c.videoSkip) === 1 }), label: (0, jsx_runtime_1.jsx)(mui_1.Typography, __assign({ variant: "body2" }, { children: "\u5141\u8BB8\u8DF3\u8FC7" })), onChange: function (e, checked) { return handleVideoBroadcastChange('videoSkip', checked); } })] })) })) }))] })), (0, jsx_runtime_1.jsx)(SelectQuestion_1.default, { token: category === null || category === void 0 ? void 0 : category.token, open: open, onClose: function () { return setOpen(false); }, onOk: onAddRandomQuestion })] }));
64
62
  };
65
63
  exports.default = RandomQuestion;
@@ -108,8 +108,8 @@ var QuestionUpdate = function () {
108
108
  setSwitchTypeOpen(false);
109
109
  (_a = formRef === null || formRef === void 0 ? void 0 : formRef.current) === null || _a === void 0 ? void 0 : _a.setFormValues({ broadcastType: const_1.defaultQuestionParams.broadcastType });
110
110
  updateQuestionState({ aiShowType: ai_question_1.ADD_QUESTION_TYPE.LANGUAGE });
111
- } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2" }, { children: "\u8DDF\u8BFB\u80FD\u529B" })) }))] }));
112
- return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", height: 56 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ ml: 3, variant: "subtitle1" }, { children: aiShowType === ai_question_1.ADD_QUESTION_TYPE.FREE ? '自由作答' : '跟读能力' })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ open: switchTypeOpen, content: content, onClickAway: function () { return setSwitchTypeOpen(false); } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "text", size: "small", sx: { fontSize: 12, color: 'rgb(87, 107, 149)' }, onClick: function () { return setSwitchTypeOpen(true); } }, { children: "\u5207\u6362\u9898\u578B" })) }))] })));
111
+ } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ variant: "body2" }, { children: "\u6717\u8BFB\u9898" })) }))] }));
112
+ return ((0, jsx_runtime_1.jsxs)(fbm_ui_1.Box, __assign({ display: "flex", alignItems: "center", height: 56 }, { children: [(0, jsx_runtime_1.jsx)(fbm_ui_1.Typography, __assign({ ml: 3, variant: "subtitle1" }, { children: aiShowType === ai_question_1.ADD_QUESTION_TYPE.FREE ? '自由作答' : '朗读题' })), (0, jsx_runtime_1.jsx)(fbm_ui_1.Popover, __assign({ open: switchTypeOpen, content: content, onClickAway: function () { return setSwitchTypeOpen(false); } }, { children: (0, jsx_runtime_1.jsx)(fbm_ui_1.Button, __assign({ variant: "text", size: "small", sx: { fontSize: 12, color: 'rgb(87, 107, 149)' }, onClick: function () { return setSwitchTypeOpen(true); } }, { children: "\u5207\u6362\u9898\u578B" })) }))] })));
113
113
  };
114
114
  var getModelParams = (0, react_1.useCallback)(function (values, isSubmit) {
115
115
  return new Promise(function (resolve, reject) {
@@ -6,7 +6,11 @@ var hox_1 = require("hox");
6
6
  var react_1 = require("react");
7
7
  exports.useAiAbilityListStore = (_a = (0, hox_1.createGlobalStore)(function () {
8
8
  var _a = (0, react_1.useState)([]), aiAbilityList = _a[0], setAiAbilityList = _a[1];
9
- var _b = (0, react_1.useState)([]), selctedAbilitys = _b[0], setSelctedAbilitys = _b[1];
9
+ var _b = (0, react_1.useState)([
10
+ '5j7aylYmY1b2syzKbal3RS0P80',
11
+ 'V8aFzLMHHw3j3bNyAgiDRS0P80',
12
+ 'c3RANdCHEAP597Gzf0OWRS0P80',
13
+ ]), selctedAbilitys = _b[0], setSelctedAbilitys = _b[1];
10
14
  return {
11
15
  selctedAbilitys: selctedAbilitys,
12
16
  setSelctedAbilitys: setSelctedAbilitys,
@@ -16,11 +16,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
16
16
  var _a;
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
18
  exports.getQuestionModelStore = exports.useQuestionModelStore = void 0;
19
- var react_1 = require("react");
20
- var hox_1 = require("hox");
21
- var immutability_helper_1 = __importDefault(require("immutability-helper"));
22
19
  var ai_question_1 = require("../../constants/ai-question");
23
20
  var utils_1 = require("../../utils/utils");
21
+ var hox_1 = require("hox");
22
+ var immutability_helper_1 = __importDefault(require("immutability-helper"));
23
+ var react_1 = require("react");
24
24
  exports.useQuestionModelStore = (_a = (0, hox_1.createGlobalStore)(function () {
25
25
  var _a = (0, react_1.useState)(), questionModelData = _a[0], updateModel = _a[1];
26
26
  var _b = (questionModelData || {}).steps, steps = _b === void 0 ? [] : _b;
@@ -0,0 +1,29 @@
1
+ /// <reference types="react" />
2
+ export declare const useEnterpriseStore: (depsFn?: import("hox/es/types").DepsFn<{
3
+ enterprise: {
4
+ jobToken?: string | undefined;
5
+ thirdToken?: string | undefined;
6
+ };
7
+ setEnterprise: import("react").Dispatch<import("react").SetStateAction<{
8
+ jobToken?: string | undefined;
9
+ thirdToken?: string | undefined;
10
+ }>>;
11
+ }> | undefined) => {
12
+ enterprise: {
13
+ jobToken?: string | undefined;
14
+ thirdToken?: string | undefined;
15
+ };
16
+ setEnterprise: import("react").Dispatch<import("react").SetStateAction<{
17
+ jobToken?: string | undefined;
18
+ thirdToken?: string | undefined;
19
+ }>>;
20
+ }, getEnterpriseStore: () => {
21
+ enterprise: {
22
+ jobToken?: string | undefined;
23
+ thirdToken?: string | undefined;
24
+ };
25
+ setEnterprise: import("react").Dispatch<import("react").SetStateAction<{
26
+ jobToken?: string | undefined;
27
+ thirdToken?: string | undefined;
28
+ }>>;
29
+ } | undefined;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ var _a;
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.getEnterpriseStore = exports.useEnterpriseStore = void 0;
5
+ var hox_1 = require("hox");
6
+ var react_1 = require("react");
7
+ exports.useEnterpriseStore = (_a = (0, hox_1.createGlobalStore)(function () {
8
+ var _a = (0, react_1.useState)({
9
+ jobToken: '',
10
+ thirdToken: '',
11
+ }), enterprise = _a[0], setEnterprise = _a[1];
12
+ return {
13
+ enterprise: enterprise,
14
+ setEnterprise: setEnterprise,
15
+ };
16
+ }), _a[0]), exports.getEnterpriseStore = _a[1];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eli-video-interview",
3
- "version": "1.2.35.alpha.6",
3
+ "version": "1.2.35.alpha.8",
4
4
  "description": "鳄梨科技 AI视频面试 React SDK",
5
5
  "author": "鳄梨科技",
6
6
  "license": "MIT",