pcm-agents 1.0.0 → 1.0.1
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.
- package/dist/cjs/components-chat-message_33.cjs.entry.js +6 -6
- package/dist/cjs/components-chat-message_33.cjs.entry.js.map +1 -1
- package/dist/cjs/{conversation-utils-BfkOMf_-.js → conversation-utils-BSbqTS91.js} +4 -4
- package/dist/cjs/{conversation-utils-BfkOMf_-.js.map → conversation-utils-BSbqTS91.js.map} +1 -1
- package/dist/cjs/{index-BnRvF-cO.js → index-CU_o8ASa.js} +3 -3
- package/dist/cjs/{index-BnRvF-cO.js.map → index-CU_o8ASa.js.map} +1 -1
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/oem-htws-modal.cjs.entry.js +1 -1
- package/dist/cjs/oem-jd-modal.cjs.entry.js +2 -2
- package/dist/cjs/oem-jlpp-modal.cjs.entry.js +1 -1
- package/dist/cjs/oem-jlzz-modal.cjs.entry.js +1 -1
- package/dist/cjs/oem-mnct-modal.cjs.entry.js +1 -1
- package/dist/cjs/oem-mnms-modal.cjs.entry.js +1 -1
- package/dist/cjs/oem-qgqjl-modal.cjs.entry.js +3 -3
- package/dist/cjs/pcm-hr-chat-modal.cjs.entry.js +2 -2
- package/dist/cjs/pcm-jlsx-modal.cjs.entry.js +174 -6
- package/dist/cjs/pcm-jlsx-modal.cjs.entry.js.map +1 -1
- package/dist/cjs/pcm-jlsx-modal.entry.cjs.js.map +1 -1
- package/dist/cjs/{sentry-reporter-CAeLEFLc.js → sentry-reporter-DmBt7dYt.js} +3 -3
- package/dist/cjs/{sentry-reporter-CAeLEFLc.js.map → sentry-reporter-DmBt7dYt.js.map} +1 -1
- package/dist/collection/components/pcm-app-chat-modal/pcm-app-chat-modal.css +1 -1
- package/dist/collection/components/pcm-jlsx-modal/pcm-jlsx-modal.css +14 -0
- package/dist/collection/components/pcm-jlsx-modal/pcm-jlsx-modal.js +173 -5
- package/dist/collection/components/pcm-jlsx-modal/pcm-jlsx-modal.js.map +1 -1
- package/dist/collection/components/pcm-virtual-chat-modal/pcm-virtual-chat-modal.css +1 -1
- package/dist/collection/components/pcm-zsk-chat-modal/pcm-zsk-chat-modal.css +1 -1
- package/dist/components/components-chat-message.js +1 -1
- package/dist/components/components-digital-human.js +1 -1
- package/dist/components/components-export-records-modal.js +1 -1
- package/dist/components/components-mobile-input-btn.js +1 -1
- package/dist/components/components-mobile-upload-btn.js +1 -1
- package/dist/components/components-position-selector.js +1 -1
- package/dist/components/components-thousand-resume-wrapper.js +1 -1
- package/dist/components/components-upload.js +1 -1
- package/dist/components/components-voice-input-btn.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/oem-htws-modal.js +5 -5
- package/dist/components/oem-jd-modal.js +5 -5
- package/dist/components/oem-jlpp-modal.js +7 -7
- package/dist/components/oem-jlsx-modal.js +5 -5
- package/dist/components/oem-jlzz-modal.js +5 -5
- package/dist/components/oem-mnct-modal.js +7 -7
- package/dist/components/oem-mnms-modal.js +8 -8
- package/dist/components/oem-qgqjl-modal.js +9 -9
- package/dist/components/oem-zygh-modal.js +5 -5
- package/dist/components/{p-DkJ7RM7j.js → p-3Q_UlCBS.js} +3 -3
- package/dist/components/{p-DkJ7RM7j.js.map → p-3Q_UlCBS.js.map} +1 -1
- package/dist/components/{p-CR7hzwAG.js → p-BmcWjR4N.js} +6 -6
- package/dist/components/p-BmcWjR4N.js.map +1 -0
- package/dist/components/{p-Cy_hQiQs.js → p-BzkaZYPy.js} +3 -3
- package/dist/components/{p-Cy_hQiQs.js.map → p-BzkaZYPy.js.map} +1 -1
- package/dist/components/{p-Bn48g_o5.js → p-CLbRlbBQ.js} +3 -3
- package/dist/components/{p-Bn48g_o5.js.map → p-CLbRlbBQ.js.map} +1 -1
- package/dist/components/{p-CCTgkbh7.js → p-CXEN9wni.js} +3 -3
- package/dist/components/{p-CCTgkbh7.js.map → p-CXEN9wni.js.map} +1 -1
- package/dist/components/{p-BH3zMcBy.js → p-Ctv3wyw7.js} +4 -4
- package/dist/components/{p-BH3zMcBy.js.map → p-Ctv3wyw7.js.map} +1 -1
- package/dist/components/{p-DNPkGKCS.js → p-DVLwCSEJ.js} +3 -3
- package/dist/components/{p-DNPkGKCS.js.map → p-DVLwCSEJ.js.map} +1 -1
- package/dist/components/{p-DrIjQbpV.js → p-DXRKSQ8c.js} +3 -3
- package/dist/components/{p-DrIjQbpV.js.map → p-DXRKSQ8c.js.map} +1 -1
- package/dist/components/{p-BBxWf8DW.js → p-D_aQ1w9v.js} +3 -3
- package/dist/components/{p-BBxWf8DW.js.map → p-D_aQ1w9v.js.map} +1 -1
- package/dist/components/{p-CUpl5cwz.js → p-DmWFUjNG.js} +3 -3
- package/dist/components/{p-CUpl5cwz.js.map → p-DmWFUjNG.js.map} +1 -1
- package/dist/components/{p-Bab9bYff.js → p-DtLvVebv.js} +4 -4
- package/dist/components/{p-Bab9bYff.js.map → p-DtLvVebv.js.map} +1 -1
- package/dist/components/{p-Cp6_0jsj.js → p-jItKLiWg.js} +3 -3
- package/dist/components/{p-Cp6_0jsj.js.map → p-jItKLiWg.js.map} +1 -1
- package/dist/components/{p-DuRuN7gY.js → p-kxAOEOKi.js} +3 -3
- package/dist/components/{p-DuRuN7gY.js.map → p-kxAOEOKi.js.map} +1 -1
- package/dist/components/pcm-1zhanshi-mnms-modal.js +5 -5
- package/dist/components/pcm-app-chat-modal.js +1 -1
- package/dist/components/pcm-ats-mnms-modal.js +5 -5
- package/dist/components/pcm-card.js +1 -1
- package/dist/components/pcm-hr-chat-modal.js +2 -2
- package/dist/components/pcm-htws-modal.js +8 -8
- package/dist/components/pcm-hyzj-modal.js +5 -5
- package/dist/components/pcm-jd-modal.js +6 -6
- package/dist/components/pcm-jlpp-modal.js +8 -8
- package/dist/components/pcm-jlsx-modal.js +177 -9
- package/dist/components/pcm-jlsx-modal.js.map +1 -1
- package/dist/components/pcm-jlzz-modal.js +6 -6
- package/dist/components/pcm-mnct-modal.js +7 -7
- package/dist/components/pcm-mnms-modal.js +8 -8
- package/dist/components/pcm-mnms-zp-modal.js +8 -8
- package/dist/components/pcm-msbg-modal.js +5 -5
- package/dist/components/pcm-qgqjl-modal.js +9 -9
- package/dist/components/pcm-virtual-chat-modal.js +1 -1
- package/dist/components/pcm-zsk-chat-modal.js +3 -3
- package/dist/components/pcm-zsk-chat-modal.js.map +1 -1
- package/dist/components/pcm-zygh-modal.js +7 -7
- package/dist/components/pcm-zygh-v2-modal.js +7 -7
- package/dist/esm/components-chat-message_33.entry.js +6 -6
- package/dist/esm/components-chat-message_33.entry.js.map +1 -1
- package/dist/esm/{conversation-utils-Ck8snHlu.js → conversation-utils-DbEUsn3n.js} +4 -4
- package/dist/esm/{conversation-utils-Ck8snHlu.js.map → conversation-utils-DbEUsn3n.js.map} +1 -1
- package/dist/esm/{index-BR_BEmyI.js → index-Bo13CEzs.js} +4 -4
- package/dist/esm/{index-BR_BEmyI.js.map → index-Bo13CEzs.js.map} +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/oem-htws-modal.entry.js +1 -1
- package/dist/esm/oem-jd-modal.entry.js +2 -2
- package/dist/esm/oem-jlpp-modal.entry.js +1 -1
- package/dist/esm/oem-jlzz-modal.entry.js +1 -1
- package/dist/esm/oem-mnct-modal.entry.js +1 -1
- package/dist/esm/oem-mnms-modal.entry.js +1 -1
- package/dist/esm/oem-qgqjl-modal.entry.js +3 -3
- package/dist/esm/pcm-hr-chat-modal.entry.js +2 -2
- package/dist/esm/pcm-jlsx-modal.entry.js +174 -6
- package/dist/esm/pcm-jlsx-modal.entry.js.map +1 -1
- package/dist/esm/{sentry-reporter-BZPRD4nE.js → sentry-reporter-K4l0BEc5.js} +3 -3
- package/dist/esm/{sentry-reporter-BZPRD4nE.js.map → sentry-reporter-K4l0BEc5.js.map} +1 -1
- package/dist/pcm-agents/index.esm.js +1 -1
- package/dist/pcm-agents/{p-0abb8e18.entry.js → p-54101b75.entry.js} +2 -2
- package/dist/pcm-agents/{p-4427d0b4.entry.js → p-576d7f0c.entry.js} +2 -2
- package/dist/pcm-agents/{p-8b6019b7.entry.js → p-68cce17d.entry.js} +2 -2
- package/dist/pcm-agents/{p-7000140e.entry.js → p-9683136b.entry.js} +2 -2
- package/dist/pcm-agents/{p-CDLRm6tb.js → p-Ce7kriVb.js} +2 -2
- package/dist/pcm-agents/{p-CDLRm6tb.js.map → p-Ce7kriVb.js.map} +1 -1
- package/dist/pcm-agents/{p-CC_AWE7Q.js → p-DSL40nYe.js} +2 -2
- package/dist/pcm-agents/{p-CC_AWE7Q.js.map → p-DSL40nYe.js.map} +1 -1
- package/dist/pcm-agents/{p-C5UfA3VN.js → p-DxyGiF-E.js} +2 -2
- package/dist/pcm-agents/{p-C5UfA3VN.js.map → p-DxyGiF-E.js.map} +1 -1
- package/dist/pcm-agents/{p-6419b0bb.entry.js → p-ac0a2540.entry.js} +2 -2
- package/dist/pcm-agents/p-b252dbbe.entry.js +8 -0
- package/dist/pcm-agents/p-b252dbbe.entry.js.map +1 -0
- package/dist/pcm-agents/{p-66459556.entry.js → p-c02bf16e.entry.js} +2 -2
- package/dist/pcm-agents/{p-4f35fe24.entry.js → p-c2409f51.entry.js} +2 -2
- package/dist/pcm-agents/p-d55ba137.entry.js +2 -0
- package/dist/pcm-agents/p-d55ba137.entry.js.map +1 -0
- package/dist/pcm-agents/{p-174577d5.entry.js → p-dc3da9bc.entry.js} +2 -2
- package/dist/pcm-agents/pcm-agents.esm.js +1 -1
- package/dist/pcm-agents/pcm-jlsx-modal.entry.esm.js.map +1 -1
- package/dist/types/components/pcm-jlsx-modal/pcm-jlsx-modal.d.ts +7 -2
- package/dist/types/components.d.ts +2 -2
- package/package.json +1 -1
- package/dist/components/p-CR7hzwAG.js.map +0 -1
- package/dist/pcm-agents/p-4a767489.entry.js +0 -8
- package/dist/pcm-agents/p-4a767489.entry.js.map +0 -1
- package/dist/pcm-agents/p-99bf652c.entry.js +0 -2
- package/dist/pcm-agents/p-99bf652c.entry.js.map +0 -1
- /package/dist/pcm-agents/{p-0abb8e18.entry.js.map → p-54101b75.entry.js.map} +0 -0
- /package/dist/pcm-agents/{p-4427d0b4.entry.js.map → p-576d7f0c.entry.js.map} +0 -0
- /package/dist/pcm-agents/{p-8b6019b7.entry.js.map → p-68cce17d.entry.js.map} +0 -0
- /package/dist/pcm-agents/{p-7000140e.entry.js.map → p-9683136b.entry.js.map} +0 -0
- /package/dist/pcm-agents/{p-6419b0bb.entry.js.map → p-ac0a2540.entry.js.map} +0 -0
- /package/dist/pcm-agents/{p-66459556.entry.js.map → p-c02bf16e.entry.js.map} +0 -0
- /package/dist/pcm-agents/{p-4f35fe24.entry.js.map → p-c2409f51.entry.js.map} +0 -0
- /package/dist/pcm-agents/{p-174577d5.entry.js.map → p-dc3da9bc.entry.js.map} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
import { verifyApiKey, sendHttpRequest, sendSSERequest, getCosPreviewUrl, PCM_DOMAIN } from "../../utils/utils";
|
|
2
|
+
import { verifyApiKey, sendHttpRequest, sendSSERequest, getCosPreviewUrl, PCM_DOMAIN, uploadFileByUrl } from "../../utils/utils";
|
|
3
3
|
import { showMessage } from "../../utils/message-utils";
|
|
4
4
|
import { ErrorEventBus } from "../../utils/error-event";
|
|
5
5
|
import { authStore } from "../../../store/auth.store";
|
|
@@ -45,8 +45,9 @@ export class JlsxModal {
|
|
|
45
45
|
*/
|
|
46
46
|
fullscreen = false;
|
|
47
47
|
/**
|
|
48
|
-
*
|
|
49
|
-
*
|
|
48
|
+
* 自定义输入参数<br>
|
|
49
|
+
* - job_info: 填充 JD 输入区域
|
|
50
|
+
* - file_urls: 简历文件 URL,多个以逗号分隔;创建任务后自动进入简历列表并开始筛选
|
|
50
51
|
*/
|
|
51
52
|
customInputs = {};
|
|
52
53
|
/**
|
|
@@ -324,6 +325,9 @@ export class JlsxModal {
|
|
|
324
325
|
evaluation_criteria: this.evaluationCriteria,
|
|
325
326
|
create_time: new Date().toISOString()
|
|
326
327
|
});
|
|
328
|
+
if (this.customInputs?.file_urls) {
|
|
329
|
+
await this.startAnalysisWithCustomFileUrls();
|
|
330
|
+
}
|
|
327
331
|
}
|
|
328
332
|
else {
|
|
329
333
|
throw new Error(response.message || '创建任务失败');
|
|
@@ -534,7 +538,13 @@ export class JlsxModal {
|
|
|
534
538
|
} })), h("textarea", { id: "job-description", class: "job-description-textarea", placeholder: "\u8BF7\u8F93\u5165\u804C\u4F4D\u63CF\u8FF0\uFF0C\u5305\u62EC\u804C\u8D23\u3001\u8981\u6C42\u7B49\u4FE1\u606F...", rows: 6, value: this.jobDescription, onInput: this.handleJobDescriptionChange })), h("div", { class: "criteria-input-section" }, h("div", { class: "criteria-header" }, h("label", { htmlFor: "evaluation-criteria" }, "\u8BC4\u5206\u6807\u51C6"), h("div", { class: "criteria-actions" }, h("span", { class: `total-weight ${this.getTotalWeight() !== 100 ? 'invalid' : ''}` }, "\u603B\u6743\u91CD: ", this.getTotalWeight(), "%"), h("span", null))), h("div", { class: "criteria-table-container" }, h("table", { class: "criteria-table" }, h("thead", null, h("tr", null, h("th", { style: { width: '25%' } }, "\u6807\u51C6\u540D\u79F0"), h("th", { style: { width: '15%' } }, "\u6743\u91CD(%)"), h("th", { style: { width: '50%' } }, "\u63CF\u8FF0"), h("th", { style: { width: '10%' } }, "\u64CD\u4F5C"))), h("tbody", null, this.evaluationCriteria.map((criteria, index) => (h("tr", { key: index }, h("td", null, h("input", { type: "text", class: "criteria-name-input", placeholder: "\u8BF7\u8F93\u5165\u6807\u51C6\u540D\u79F0", value: criteria.name, onInput: (e) => this.handleEvaluationCriteriaNameChange(index, e.target.value) })), h("td", null, h("input", { type: "number", class: "criteria-value-input", placeholder: "0", min: "0", max: "100", value: criteria.value, onInput: (e) => this.handleEvaluationCriteriaValueChange(index, e.target.value) })), h("td", null, h("textarea", { class: "criteria-description-input", placeholder: "\u8BF7\u8F93\u5165\u8BC4\u5206\u6807\u51C6\u63CF\u8FF0", rows: 2, value: criteria.description, onInput: (e) => this.handleEvaluationCriteriaDescriptionChange(index, e.target.value) })), h("td", null, h("button", { type: "button", class: "remove-criteria-btn", disabled: this.evaluationCriteria.length <= 1, onClick: () => this.removeEvaluationCriteria(index), title: this.evaluationCriteria.length <= 1 ? '至少需要保留一个评分标准' : '删除此标准' }, "\u00D7")))))))), h("div", { class: "add-criteria-btn-wrapper" }, h("button", { type: "button", class: "add-criteria-btn", onClick: this.addEvaluationCriteria }, "+ \u6DFB\u52A0\u6807\u51C6")), this.getTotalWeight() !== 100 && (h("p", { class: "criteria-warning" }, "\u26A0\uFE0F \u6743\u91CD\u603B\u548C\u5E94\u4E3A100%\uFF0C\u5F53\u524D\u4E3A", this.getTotalWeight(), "%"))), h("div", { class: "criteria-input-section" }, h("div", { class: "criteria-header" }, h("label", { htmlFor: "evaluation-criteria" }, "\u91CD\u8981\u6761\u4EF6\uFF08\u9009\u586B\uFF09"), h("div", null)), h("textarea", { id: "job-description", class: "job-description-textarea", placeholder: "\u5728\u6B64\u680F\u586B\u5199\u7684\u6761\u4EF6\u4E3A\u786C\u6027\u8981\u6C42\uFF0C\u4E0D\u7B26\u5408\u6761\u4EF6\u7684\u7B80\u5386\uFF0C\u5176\u6700\u7EC8\u5339\u914D\u5EA6\u5C06\u76F4\u63A5\u5224\u5B9A\u4E3A0\u5206\u3002", rows: 6, value: this.importantConditions, onInput: this.handleImportantConditionsChange })), h("button", { class: "submit-button", disabled: !this.jobDescription.trim() || this.evaluationCriteria.length === 0 || this.getTotalWeight() !== 100 || this.isSubmitting, onClick: this.handleCreateTask }, this.isSubmitting ? '创建中...' : '创建任务'), h("div", { class: "ai-disclaimer" }, h("p", null, "\u6240\u6709\u5185\u5BB9\u5747\u7531AI\u751F\u6210\u4EC5\u4F9B\u53C2\u8003"), h("p", { class: "beian-info" }, h("span", null, "\u4E2D\u592E\u7F51\u4FE1\u529E\u751F\u6210\u5F0F\u4EBA\u5DE5\u667A\u80FD\u670D\u52A1\u5907\u6848\u53F7"), "\uFF1A", h("a", { href: "https://www.pincaimao.com", target: "_blank", rel: "noopener noreferrer" }, "Hunan-PinCaiMao-202412310003")))));
|
|
535
539
|
}
|
|
536
540
|
renderTaskStep() {
|
|
537
|
-
return (h("div", { class: "task-container" }, h("div", { class: "task-info-section" }, h("div", { class: "info-cards" }, h("div", { class: "info-card" }, h("div", { class: "card-header", onClick: this.toggleJdDetail }, h("span", { class: "card-title" }, "\u804C\u4F4D\u63CF\u8FF0"), h("button", { class: "toggle-btn" }, "\u67E5\u770B")), h("div", { class: "card-preview" }, h("p", { class: "preview-text" }, this.jobDescription))), h("div", { class: "info-card" }, h("div", { class: "card-header", onClick: this.toggleCriteriaDetail }, h("span", { class: "card-title" }, "\u8BC4\u5206\u6807\u51C6\u3001\u91CD\u8981\u6761\u4EF6"), h("button", { class: "toggle-btn" }, "\u67E5\u770B")), h("div", { class: "card-preview" }, h("p", { class: "preview-text" }, this.getEvaluationCriteriaText()))))), h("div", { class: "upload-section" }, h("div", { class: "section-header" }, h("h4", null, "\u4E0A\u4F20\u7B80\u5386")), h("
|
|
541
|
+
return (h("div", { class: "task-container" }, h("div", { class: "task-info-section" }, h("div", { class: "info-cards" }, h("div", { class: "info-card" }, h("div", { class: "card-header", onClick: this.toggleJdDetail }, h("span", { class: "card-title" }, "\u804C\u4F4D\u63CF\u8FF0"), h("button", { class: "toggle-btn" }, "\u67E5\u770B")), h("div", { class: "card-preview" }, h("p", { class: "preview-text" }, this.jobDescription))), h("div", { class: "info-card" }, h("div", { class: "card-header", onClick: this.toggleCriteriaDetail }, h("span", { class: "card-title" }, "\u8BC4\u5206\u6807\u51C6\u3001\u91CD\u8981\u6761\u4EF6"), h("button", { class: "toggle-btn" }, "\u67E5\u770B")), h("div", { class: "card-preview" }, h("p", { class: "preview-text" }, this.getEvaluationCriteriaText()))))), h("div", { class: "upload-section" }, h("div", { class: "section-header" }, h("h4", null, "\u4E0A\u4F20\u7B80\u5386")), h("div", { class: this.customInputs?.file_urls ? 'upload-disabled-wrapper' : '', onClick: (event) => {
|
|
542
|
+
if (this.customInputs?.file_urls) {
|
|
543
|
+
event.stopPropagation();
|
|
544
|
+
event.preventDefault();
|
|
545
|
+
showMessage('不允许上传简历,请联系管理员', 'warning');
|
|
546
|
+
}
|
|
547
|
+
} }, h("components-upload", { ref: (el) => this.pcmUploadRef = el, multiple: true, maxFileSize: 15 * 1024 * 1024, acceptFileSuffixList: ['.pdf', '.doc', '.docx', '.txt', '.md', '.ppt', '.pptx', '.jpg', '.jpeg', '.png'], mobileUploadAble: this.mobileUploadAble, disabled: Boolean(this.customInputs?.file_urls), uploadParams: { tags: ['resume'] }, onUploadChange: this.handleUploadChange })), h("div", { class: "upload-actions" }, this.uploadedResumeRecords.some(record => record.evaluate_status !== 1 && record.evaluate_status !== 0) && (h("button", { class: "analyze-btn", onClick: this.handleStartAnalysis }, `开始分析 (${this.uploadedResumeRecords.filter(record => record.evaluate_status !== 1 && record.evaluate_status !== 0).length} 个待分析)`)))), h("div", { class: "resume-table-section" }, h("div", { class: "section-header" }, h("h4", null, "\u7B80\u5386\u5217\u8868"), h("div", { class: "section-header-side" }, this.showBatchExport && !!this.resumeRecords?.find(item => item.evaluate_status == 1) && h("div", { class: "export-actions" }, h("div", { class: "export-btn", onClick: this.exportAllPDF }, h("span", null, "\u6279\u91CF\u5BFC\u51FA\u62A5\u544A")), h("div", { class: "export-divide" }), h("div", { class: "export-btn", onClick: this.handleExportRecordsClick }, "\u5BFC\u51FA\u8BB0\u5F55")), h("button", { class: "refresh-btn", onClick: this.handleRefreshTable, disabled: this.isLoadingResumeList, title: "\u5237\u65B0\u8868\u683C" }, h("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "currentColor", class: this.isLoadingResumeList ? 'rotating' : '' }, h("path", { d: "M17.65 6.35C16.2 4.9 14.21 4 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08c-.82 2.33-3.04 4-5.65 4-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z" }))), h("span", { class: "record-count" }, "\u5DF2\u7B5B\u9009 ", this.totalRecords, " \u6761\u8BB0\u5F55"))), h("div", { class: "table-container" }, h("table", { class: "resume-table" }, h("thead", null, h("tr", null, h("th", null, "\u7B80\u5386\u6587\u4EF6\u540D"), h("th", null, "\u4EBA\u624D\u4FE1\u606F"), h("th", { class: `sortable-header ${this.sortOrder !== 'none' ? 'active' : ''}`, onClick: this.handleSortByScore }, h("span", { class: "header-content" }, "\u8BC4\u4F30\u5206\u6570", h("span", { class: "sort-icons" }, h("svg", { class: `sort-icon ${this.sortOrder === 'asc' ? 'active' : ''}`, width: "12", height: "12", viewBox: "0 0 12 12" }, h("path", { d: "M6 3l4 4H2z", fill: "currentColor" })), h("svg", { class: `sort-icon ${this.sortOrder === 'desc' ? 'active' : ''}`, width: "12", height: "12", viewBox: "0 0 12 12" }, h("path", { d: "M6 9L2 5h8z", fill: "currentColor" }))))), h("th", null, "\u8BC4\u4F30\u8BE6\u60C5"), h("th", null, "\u72B6\u6001"), h("th", null, "\u64CD\u4F5C"))), h("tbody", null, this.isLoadingResumeList ? (h("tr", null, h("td", { colSpan: 6, class: "empty-row" }, h("div", { class: "empty-state" }, h("div", { class: "loading-spinner-small" }), h("p", null, "\u6B63\u5728\u52A0\u8F7D\u7B80\u5386\u6570\u636E..."))))) : this.resumeRecords.length === 0 ? (h("tr", null, h("td", { colSpan: 6, class: "empty-row" }, h("div", { class: "empty-state" }, h("p", null, "\u6682\u65E0\u7B80\u5386\u6570\u636E"), h("p", { class: "empty-hint" }, "\u8BF7\u4E0A\u4F20\u7B80\u5386\u5F00\u59CB\u7B5B\u9009"))))) : (this.resumeRecords.map(record => (h("tr", { key: record.id }, h("td", { class: "filename-cell" }, h("span", { class: "file-icon" }, "\uD83D\uDCDD"), h("span", { title: record.fileName }, record.fileName)), h("td", { class: "talent-info-cell", title: record.talentInfo }, record.talentInfo), h("td", { class: "score-cell" }, h("div", { class: `score-badge ${this.getScoreClass(record.score)}` }, typeof record.score === 'number' ? record.score : '--'), record.out_important_conditions === 1 && h("div", { class: "out-important-conditions" }, "\u4E0D\u6EE1\u8DB3\u91CD\u8981\u6761\u4EF6")), h("td", { class: "detail-cell", title: record.scoreDetail }, h("span", { class: "detail-content", onClick: () => this.handleViewEvaluate(record) }, record.scoreDetail)), h("td", { class: "status-cell" }, h("span", { class: `status-badge status-${this.getEvaluateStatusClass(record.evaluate_status)}` }, this.getEvaluateStatusText(record.evaluate_status))), h("td", { class: "action-cell" }, h("div", { class: "action-dropdown" }, h("button", { class: "action-btn dropdown-trigger", onClick: (e) => {
|
|
538
548
|
e.stopPropagation();
|
|
539
549
|
this.toggleDropdown(record.id);
|
|
540
550
|
} }, "\u64CD\u4F5C", h("svg", { width: "12", height: "12", viewBox: "0 0 24 24", fill: "currentColor" }, h("path", { d: "M7 10l5 5 5-5z" }))), this.activeDropdownId === record.id && (h("div", { class: "dropdown-menu" }, h("div", { class: "dropdown-item", onClick: (e) => {
|
|
@@ -684,6 +694,164 @@ export class JlsxModal {
|
|
|
684
694
|
this.isLoadingResumeList = false;
|
|
685
695
|
}
|
|
686
696
|
}
|
|
697
|
+
/**
|
|
698
|
+
* 使用 customInputs 中的 file_urls 开始分析简历。
|
|
699
|
+
*/
|
|
700
|
+
async startAnalysisWithCustomFileUrls() {
|
|
701
|
+
if (!this.currentTask) {
|
|
702
|
+
showMessage('任务信息不存在', 'error');
|
|
703
|
+
return;
|
|
704
|
+
}
|
|
705
|
+
const fileUrls = this.customInputs?.file_urls;
|
|
706
|
+
if (!fileUrls) {
|
|
707
|
+
return;
|
|
708
|
+
}
|
|
709
|
+
const originalFileUrls = fileUrls.split(',').map(url => url.trim()).filter(Boolean);
|
|
710
|
+
if (originalFileUrls.length === 0) {
|
|
711
|
+
showMessage('没有有效的简历文件URL', 'warning');
|
|
712
|
+
return;
|
|
713
|
+
}
|
|
714
|
+
this.isAnalyzing = true;
|
|
715
|
+
this.isLoadingResumeList = true;
|
|
716
|
+
try {
|
|
717
|
+
const resumeFileUrls = [];
|
|
718
|
+
for (const url of originalFileUrls) {
|
|
719
|
+
if (url.startsWith('http://') || url.startsWith('https://')) {
|
|
720
|
+
try {
|
|
721
|
+
const fileName = url.split('/').pop() || 'resume.pdf';
|
|
722
|
+
const uploadResponse = await uploadFileByUrl({
|
|
723
|
+
url,
|
|
724
|
+
file_name: fileName
|
|
725
|
+
});
|
|
726
|
+
if (uploadResponse.success && uploadResponse.data?.cos_key) {
|
|
727
|
+
resumeFileUrls.push(uploadResponse.data.cos_key);
|
|
728
|
+
}
|
|
729
|
+
else {
|
|
730
|
+
console.error(`上传文件失败: ${url}`, uploadResponse.message);
|
|
731
|
+
showMessage(`上传文件 ${fileName} 失败: ${uploadResponse.message || '未知错误'}`, 'error');
|
|
732
|
+
}
|
|
733
|
+
}
|
|
734
|
+
catch (error) {
|
|
735
|
+
console.error(`上传文件出错: ${url}`, error);
|
|
736
|
+
showMessage(`上传文件出错: ${error instanceof Error ? error.message : '未知错误'}`, 'error');
|
|
737
|
+
}
|
|
738
|
+
}
|
|
739
|
+
else {
|
|
740
|
+
resumeFileUrls.push(url);
|
|
741
|
+
}
|
|
742
|
+
}
|
|
743
|
+
if (resumeFileUrls.length === 0) {
|
|
744
|
+
showMessage('没有有效的简历文件可以分析', 'error');
|
|
745
|
+
return;
|
|
746
|
+
}
|
|
747
|
+
if (resumeFileUrls.length < originalFileUrls.length) {
|
|
748
|
+
showMessage(`部分文件上传失败,将继续分析 ${resumeFileUrls.length}/${originalFileUrls.length} 个文件`, 'warning');
|
|
749
|
+
}
|
|
750
|
+
const clearResponse = await sendHttpRequest({
|
|
751
|
+
url: '/sdk/v1/agent/app_filter_resume/clear_repeated_resumes',
|
|
752
|
+
method: 'POST',
|
|
753
|
+
data: {
|
|
754
|
+
task_id: this.currentTask.id,
|
|
755
|
+
resume_file_urls: resumeFileUrls
|
|
756
|
+
}
|
|
757
|
+
});
|
|
758
|
+
if (!clearResponse.success) {
|
|
759
|
+
throw new Error(clearResponse.message || '简历校验失败');
|
|
760
|
+
}
|
|
761
|
+
const filteredFileUrls = clearResponse.data || [];
|
|
762
|
+
if (filteredFileUrls.length === 0) {
|
|
763
|
+
showMessage('已清除重复上传的简历,没有新的简历需要分析', 'info');
|
|
764
|
+
return;
|
|
765
|
+
}
|
|
766
|
+
const ruleString = this.evaluationCriteria
|
|
767
|
+
.map(criteria => `- ${criteria.name}(占比${criteria.value}%):${criteria.description}`)
|
|
768
|
+
.join(' \n');
|
|
769
|
+
this.resumeAnalysisStart.emit({
|
|
770
|
+
task_id: this.currentTask.id,
|
|
771
|
+
resume_count: filteredFileUrls.length,
|
|
772
|
+
resume_files: filteredFileUrls.map(url => ({
|
|
773
|
+
file_name: url.split('/').pop() || '未知文件',
|
|
774
|
+
file_url: url
|
|
775
|
+
}))
|
|
776
|
+
});
|
|
777
|
+
let analysisFailed = false;
|
|
778
|
+
await sendSSERequest({
|
|
779
|
+
url: '/sdk/v1/chat/chat-messages',
|
|
780
|
+
method: 'POST',
|
|
781
|
+
data: {
|
|
782
|
+
bot_id: this.botId,
|
|
783
|
+
response_mode: 'blocking',
|
|
784
|
+
query: '简历筛选',
|
|
785
|
+
inputs: {
|
|
786
|
+
job_info: this.jobDescription,
|
|
787
|
+
jd_id: this.currentTask.jd_id,
|
|
788
|
+
task_id: this.currentTask.id,
|
|
789
|
+
file_urls: filteredFileUrls.join(','),
|
|
790
|
+
rule: ruleString
|
|
791
|
+
}
|
|
792
|
+
},
|
|
793
|
+
onMessage: (data) => {
|
|
794
|
+
if (data.event === 'error') {
|
|
795
|
+
analysisFailed = true;
|
|
796
|
+
this.someErrorEvent.emit({
|
|
797
|
+
error: data.data,
|
|
798
|
+
message: data.data?.message || data.message || '分析失败'
|
|
799
|
+
});
|
|
800
|
+
this.internalConversationId = null;
|
|
801
|
+
return;
|
|
802
|
+
}
|
|
803
|
+
if (data && !this.internalConversationId && (data.message_id || data.conversation_id || data.id)) {
|
|
804
|
+
this.internalConversationId = data.conversation_id;
|
|
805
|
+
this.conversationStart.emit({
|
|
806
|
+
conversation_id: data.conversation_id,
|
|
807
|
+
event: data.event || 'message',
|
|
808
|
+
message_id: data.message_id,
|
|
809
|
+
id: String(this.currentTask.id)
|
|
810
|
+
});
|
|
811
|
+
}
|
|
812
|
+
},
|
|
813
|
+
onComplete: async () => {
|
|
814
|
+
if (analysisFailed) {
|
|
815
|
+
this.internalConversationId = null;
|
|
816
|
+
return;
|
|
817
|
+
}
|
|
818
|
+
await this.loadResumeList();
|
|
819
|
+
this.emitAnalysisCompleteEvent();
|
|
820
|
+
this.internalConversationId = null;
|
|
821
|
+
},
|
|
822
|
+
onError: (error) => {
|
|
823
|
+
analysisFailed = true;
|
|
824
|
+
console.error('简历分析失败:', error);
|
|
825
|
+
SentryReporter.captureError(error, {
|
|
826
|
+
action: 'startAnalysisWithCustomFileUrls',
|
|
827
|
+
component: 'pcm-jlsx-modal',
|
|
828
|
+
title: '简历分析失败'
|
|
829
|
+
});
|
|
830
|
+
this.someErrorEvent.emit({
|
|
831
|
+
error,
|
|
832
|
+
message: '简历分析失败,请重试'
|
|
833
|
+
});
|
|
834
|
+
this.internalConversationId = null;
|
|
835
|
+
}
|
|
836
|
+
});
|
|
837
|
+
}
|
|
838
|
+
catch (error) {
|
|
839
|
+
console.error('开始分析失败:', error);
|
|
840
|
+
SentryReporter.captureError(error, {
|
|
841
|
+
action: 'startAnalysisWithCustomFileUrls',
|
|
842
|
+
component: 'pcm-jlsx-modal',
|
|
843
|
+
title: '开始分析失败'
|
|
844
|
+
});
|
|
845
|
+
this.someErrorEvent.emit({
|
|
846
|
+
error,
|
|
847
|
+
message: '开始分析失败,请重试'
|
|
848
|
+
});
|
|
849
|
+
}
|
|
850
|
+
finally {
|
|
851
|
+
this.isAnalyzing = false;
|
|
852
|
+
this.isLoadingResumeList = false;
|
|
853
|
+
}
|
|
854
|
+
}
|
|
687
855
|
/**
|
|
688
856
|
* 开始分析简历
|
|
689
857
|
*/
|
|
@@ -1362,7 +1530,7 @@ export class JlsxModal {
|
|
|
1362
1530
|
"optional": false,
|
|
1363
1531
|
"docs": {
|
|
1364
1532
|
"tags": [],
|
|
1365
|
-
"text": "\u81EA\u5B9A\u4E49\u8F93\u5165\u53C2\u6570\
|
|
1533
|
+
"text": "\u81EA\u5B9A\u4E49\u8F93\u5165\u53C2\u6570<br>\r\n- job_info: \u586B\u5145 JD \u8F93\u5165\u533A\u57DF\r\n- file_urls: \u7B80\u5386\u6587\u4EF6 URL\uFF0C\u591A\u4E2A\u4EE5\u9017\u53F7\u5206\u9694\uFF1B\u521B\u5EFA\u4EFB\u52A1\u540E\u81EA\u52A8\u8FDB\u5165\u7B80\u5386\u5217\u8868\u5E76\u5F00\u59CB\u7B5B\u9009"
|
|
1366
1534
|
},
|
|
1367
1535
|
"getter": false,
|
|
1368
1536
|
"setter": false,
|