cnhis-design-vue 3.3.1-release.5 → 3.3.2-release.0
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/README.md +87 -87
- package/es/components/audio-sdk/index.d.ts +20 -0
- package/es/components/audio-sdk/src/Index.vue.d.ts +20 -0
- package/es/components/audio-sdk/src/Index.vue2.js +1 -1
- package/es/components/audio-sdk/src/audioSDK.d.ts +1 -0
- package/es/components/audio-sdk/src/audioSDK.js +11 -3
- package/es/components/audio-sdk/src/components/recording-modal.vue.d.ts +10 -0
- package/es/components/audio-sdk/src/components/recording.vue.d.ts +10 -0
- package/es/components/audio-sdk/src/components/recording.vue2.js +5 -0
- package/es/components/audio-sdk/src/constants/index.d.ts +1 -0
- package/es/components/audio-sdk/src/constants/index.js +3 -0
- package/es/components/audio-sdk/src/utils/recorder/fft.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/mp3-engine.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/mp3.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/recorder.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recorder/wave.d.ts +4 -0
- package/es/components/audio-sdk/src/utils/recordingModal.js +13 -2
- package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
- package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
- package/es/components/bpmn-workflow/types/ModelingModule.d.ts +1 -0
- package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
- package/es/components/callback/src/components/render/popupMaps.d.ts +17 -1
- package/es/components/card-render/index.d.ts +4 -4
- package/es/components/card-render/src/CardRender.vue.d.ts +4 -4
- package/es/components/card-render/src/components/index.d.ts +23 -23
- package/es/components/classification/src/components/table-modal/index.vue.d.ts +0 -3
- package/es/components/fabric-chart/src/hooks/useCumputedPoint.js +12 -6
- package/es/components/field-editor/index.d.ts +4 -0
- package/es/components/field-editor/src/FieldEditor.vue.d.ts +4 -0
- package/es/components/form-config/index.d.ts +80 -5
- package/es/components/form-config/src/FormConfig.vue.d.ts +80 -5
- package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +4 -0
- package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +57 -4
- package/es/components/form-config/src/components/FormConfigEventSetting.vue.d.ts +16 -1
- package/es/components/form-config/src/constants/index.d.ts +2 -1
- package/es/components/form-config/src/constants/index.js +1 -0
- package/es/components/form-config/src/hooks/useConfigurationField.js +19 -1
- package/es/components/form-config/src/hooks/useLocale.d.ts +1 -0
- package/es/components/form-config/src/hooks/useLocale.js +1 -0
- package/es/components/form-config/src/types/index.d.ts +1 -0
- package/es/components/form-render/index.d.ts +4 -0
- package/es/components/form-render/src/FormRender.vue.d.ts +4 -0
- package/es/components/form-render/src/FormRender.vue2.js +3 -2
- package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +4 -0
- package/es/components/form-render/src/components/renderer/combination/combination.js +1 -1
- package/es/components/form-render/src/components/renderer/date.d.ts +2 -2
- package/es/components/form-render/src/components/renderer/input.d.ts +16 -4
- package/es/components/form-render/src/components/renderer/input.js +39 -7
- package/es/components/form-render/src/components/renderer/levelSearchCascader/index.js +3 -0
- package/es/components/form-render/src/components/renderer/lineBar/FormCollapse.vue.d.ts +1 -0
- package/es/components/form-render/src/components/renderer/lineBar/index.d.ts +1 -0
- package/es/components/form-render/src/components/renderer/radio_checkbox.js +9 -8
- package/es/components/form-render/src/components/renderer/text.js +1 -1
- package/es/components/form-render/src/components/renderer/textarea.d.ts +16 -1
- package/es/components/form-render/src/components/renderer/textarea.js +36 -8
- package/es/components/form-render/src/hooks/useBusinessBinding.js +1 -0
- package/es/components/form-render/src/hooks/useComplexOptions.js +3 -2
- package/es/components/form-render/src/hooks/useFieldListAdaptor.d.ts +2 -2
- package/es/components/form-render/src/hooks/useFieldListAdaptor.js +4 -3
- package/es/components/form-render/src/hooks/useFieldNormalize.d.ts +2 -0
- package/es/components/form-render/src/hooks/useFormField.d.ts +2 -0
- package/es/components/form-render/src/hooks/useFormField.js +5 -1
- package/es/components/form-render/src/hooks/useFormValidator.js +1 -0
- package/es/components/form-render/src/hooks/usePresetScope.js +1 -0
- package/es/components/form-render/src/types/fieldItem.d.ts +11 -0
- package/es/components/form-render/src/types/index.d.ts +1 -0
- package/es/components/form-render/src/utils/index.js +1 -0
- package/es/components/form-render/src/utils/schema.js +60 -15
- package/es/components/guide/src/renderer.d.ts +2 -2
- package/es/components/iho-chat/src/components/PersonProfile.vue2.js +1 -1
- package/es/components/iho-table/index.d.ts +13 -1
- package/es/components/iho-table/src/IhoTable.vue.d.ts +13 -2
- package/es/components/iho-table/src/IhoTable.vue2.js +27 -20
- package/es/components/iho-table/src/plugins/filterRenderPlugin/filter.vue.d.ts +6 -0
- package/es/components/index.css +1 -1
- package/es/components/index.d.ts +1 -2
- package/es/components/index.js +0 -3
- package/es/components/info-header/index.d.ts +13 -0
- package/es/components/info-header/src/InfoHeader.vue.d.ts +13 -0
- package/es/components/info-header/src/components/infoDescription/DescriptionItem.vue.d.ts +1 -0
- package/es/components/info-header/src/components/infoDescription/DescriptionList.vue.d.ts +1 -0
- package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +5 -0
- package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +4 -0
- package/es/components/scale-view/index.d.ts +1 -1
- package/es/components/scale-view/src/ScaleView.vue.d.ts +1 -1
- package/es/components/scale-view/src/ScaleView.vue2.js +2 -2
- package/es/components/scale-view/src/hooks/scaleview-init.d.ts +1 -1
- package/es/components/scale-view/src/hooks/scaleview-init.js +2 -2
- package/es/components/select-person/src/SelectPerson.vue2.js +8 -5
- package/es/components/shortcut-setter/index.d.ts +16 -1
- package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +16 -1
- package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.js +11 -11
- package/es/env.d.ts +25 -25
- package/es/shared/assets/img/defaultCover/10review_successful.png.js +1 -1
- package/es/shared/assets/img/defaultCover/11review_fail.png.js +1 -1
- package/es/shared/assets/img/defaultCover/12no_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/13no_menu_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/14no_call_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/15no_use_tag.png.js +1 -1
- package/es/shared/assets/img/defaultCover/16no_table_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/1location.png.js +1 -1
- package/es/shared/assets/img/defaultCover/2notfound.png.js +1 -1
- package/es/shared/assets/img/defaultCover/3loading.png.js +1 -1
- package/es/shared/assets/img/defaultCover/4no_permission.png.js +1 -1
- package/es/shared/assets/img/defaultCover/5no_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/6no_network.png.js +1 -1
- package/es/shared/assets/img/defaultCover/7no_doctor.png.js +1 -1
- package/es/shared/assets/img/defaultCover/8system_error.png.js +1 -1
- package/es/shared/assets/img/defaultCover/9system_upgrade.png.js +1 -1
- package/es/shared/assets/img/failure.png.js +1 -1
- package/es/shared/assets/img/no-permission.png.js +1 -1
- package/es/shared/assets/img/nodata.png.js +1 -1
- package/es/shared/assets/img/notfound.png.js +1 -1
- package/es/shared/assets/img/qr.png.js +1 -1
- package/es/shared/assets/img/success.png.js +1 -1
- package/es/shared/assets/img/table_style_2.png.js +1 -1
- package/es/shared/assets/img/video.png.js +1 -1
- package/es/shared/assets/img/video_default_cover.png.js +1 -1
- package/es/shared/assets/img/xb_big.png.js +1 -1
- package/es/shared/assets/img/xb_small.png.js +1 -1
- package/es/shared/components/CancelRadio/CancelRadio.d.ts +7 -0
- package/es/shared/components/CancelRadio/CancelRadio.js +6 -6
- package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +86 -0
- package/es/shared/package.json.js +1 -1
- package/es/shared/utils/fabricjs/index.d.ts +6823 -0
- package/es/shared/utils/tapable/index.d.ts +139 -0
- package/package.json +76 -77
- package/es/components/ai-chat/index.d.ts +0 -680
- package/es/components/ai-chat/index.js +0 -10
- package/es/components/ai-chat/src/Index.vue.d.ts +0 -682
- package/es/components/ai-chat/src/Index.vue.js +0 -6
- package/es/components/ai-chat/src/Index.vue2.js +0 -175
- package/es/components/ai-chat/src/api/index.d.ts +0 -8
- package/es/components/ai-chat/src/api/index.js +0 -87
- package/es/components/ai-chat/src/components/ChatAudio.vue.d.ts +0 -38
- package/es/components/ai-chat/src/components/ChatAudio.vue.js +0 -6
- package/es/components/ai-chat/src/components/ChatAudio.vue2.js +0 -103
- package/es/components/ai-chat/src/components/ChatBI.vue.d.ts +0 -101
- package/es/components/ai-chat/src/components/ChatBI.vue.js +0 -6
- package/es/components/ai-chat/src/components/ChatBI.vue2.js +0 -73
- package/es/components/ai-chat/src/components/ChatCard.d.ts +0 -43
- package/es/components/ai-chat/src/components/ChatCard.js +0 -403
- package/es/components/ai-chat/src/components/ChatFooter.vue.d.ts +0 -203
- package/es/components/ai-chat/src/components/ChatFooter.vue.js +0 -6
- package/es/components/ai-chat/src/components/ChatFooter.vue2.js +0 -373
- package/es/components/ai-chat/src/components/ChatMain.d.ts +0 -2
- package/es/components/ai-chat/src/components/ChatMain.js +0 -350
- package/es/components/ai-chat/src/components/ChatMainDefault.d.ts +0 -2
- package/es/components/ai-chat/src/components/ChatMainDefault.js +0 -278
- package/es/components/ai-chat/src/components/ChatPatient.vue.d.ts +0 -59
- package/es/components/ai-chat/src/components/ChatPatient.vue.js +0 -6
- package/es/components/ai-chat/src/components/ChatPatient.vue2.js +0 -218
- package/es/components/ai-chat/src/components/ChatPrompt.vue.d.ts +0 -45
- package/es/components/ai-chat/src/components/ChatPrompt.vue.js +0 -6
- package/es/components/ai-chat/src/components/ChatPrompt.vue2.js +0 -143
- package/es/components/ai-chat/src/components/ChatRight.vue.d.ts +0 -57
- package/es/components/ai-chat/src/components/ChatRight.vue.js +0 -6
- package/es/components/ai-chat/src/components/ChatRight.vue2.js +0 -190
- package/es/components/ai-chat/src/components/card/JsonCard.d.ts +0 -25
- package/es/components/ai-chat/src/components/card/JsonCard.js +0 -574
- package/es/components/ai-chat/src/components/message-render/CardRender.d.ts +0 -16
- package/es/components/ai-chat/src/components/message-render/CardRender.js +0 -80
- package/es/components/ai-chat/src/components/message-render/FormRender.d.ts +0 -16
- package/es/components/ai-chat/src/components/message-render/FormRender.js +0 -173
- package/es/components/ai-chat/src/components/mobile/MobileChatAudio.vue.d.ts +0 -36
- package/es/components/ai-chat/src/components/mobile/MobileChatAudio.vue.js +0 -6
- package/es/components/ai-chat/src/components/mobile/MobileChatAudio.vue2.js +0 -96
- package/es/components/ai-chat/src/components/mobile/MobileChatFooter.vue.d.ts +0 -105
- package/es/components/ai-chat/src/components/mobile/MobileChatFooter.vue.js +0 -6
- package/es/components/ai-chat/src/components/mobile/MobileChatFooter.vue2.js +0 -260
- package/es/components/ai-chat/src/components/svgs/AddIcon.vue.js +0 -18
- package/es/components/ai-chat/src/components/svgs/AudioIcon.vue.js +0 -37
- package/es/components/ai-chat/src/components/svgs/KeyboardIcon.vue.js +0 -20
- package/es/components/ai-chat/src/components/svgs/MicroPhone.vue.js +0 -48
- package/es/components/ai-chat/src/hooks/index.d.ts +0 -2
- package/es/components/ai-chat/src/hooks/index.js +0 -2
- package/es/components/ai-chat/src/hooks/useChartAudioContext.d.ts +0 -18
- package/es/components/ai-chat/src/hooks/useChartAudioContext.js +0 -202
- package/es/components/ai-chat/src/hooks/useData.d.ts +0 -77
- package/es/components/ai-chat/src/hooks/useData.js +0 -289
- package/es/components/ai-chat/src/hooks/useFooterContext.d.ts +0 -38
- package/es/components/ai-chat/src/hooks/useFooterContext.js +0 -218
- package/es/components/ai-chat/src/hooks/useProgram.d.ts +0 -14
- package/es/components/ai-chat/src/hooks/useProgram.js +0 -306
- package/es/components/ai-chat/src/hooks/useSSE.d.ts +0 -9
- package/es/components/ai-chat/src/hooks/useSSE.js +0 -138
- package/es/components/ai-chat/src/hooks/useWebsocket.d.ts +0 -4
- package/es/components/ai-chat/src/hooks/useWebsocket.js +0 -66
- package/es/components/ai-chat/src/types/index.d.ts +0 -45
- package/es/components/ai-chat/src/types/index.js +0 -1
- package/es/components/ai-chat/src/utils/index.d.ts +0 -7
- package/es/components/ai-chat/src/utils/index.js +0 -41
- package/es/components/ai-chat/style/index.css +0 -1
- package/es/shared/assets/img/ai__avatar.png.js +0 -3
- package/es/shared/assets/img/file-emr.png.js +0 -3
- package/es/shared/assets/img/file.png.js +0 -3
- package/es/shared/assets/img/logo.png.js +0 -3
- package/es/shared/assets/img/use.png.js +0 -3
@@ -1,218 +0,0 @@
|
|
1
|
-
import { defineComponent, reactive, ref, openBlock, createBlock, unref, withCtx, createVNode, createTextVNode, toDisplayString } from 'vue';
|
2
|
-
import { NDrawer, NDrawerContent, NForm, NFormItem, NRadioGroup, NRadio, NSelect, NButton } from 'naive-ui';
|
3
|
-
import { isFunction, isArray } from 'lodash-es';
|
4
|
-
import { useData } from '../hooks/useData.js';
|
5
|
-
import '../utils/index.js';
|
6
|
-
|
7
|
-
var _sfc_main = /* @__PURE__ */ defineComponent({
|
8
|
-
__name: "ChatPatient",
|
9
|
-
props: {
|
10
|
-
show: {
|
11
|
-
type: Boolean
|
12
|
-
}
|
13
|
-
},
|
14
|
-
emits: ["update:show"],
|
15
|
-
setup(__props, {
|
16
|
-
emit
|
17
|
-
}) {
|
18
|
-
var _a;
|
19
|
-
const {
|
20
|
-
state,
|
21
|
-
patientInfo
|
22
|
-
} = useData();
|
23
|
-
const formValue = reactive({
|
24
|
-
businessType: "CLINICIAN",
|
25
|
-
vaa01: null,
|
26
|
-
bck03a: ""
|
27
|
-
});
|
28
|
-
const rules = {
|
29
|
-
businessType: {
|
30
|
-
required: true,
|
31
|
-
trigger: "change",
|
32
|
-
message: "\u8BF7\u9009\u62E9\u7C7B\u578B"
|
33
|
-
},
|
34
|
-
vaa01: {
|
35
|
-
required: true,
|
36
|
-
trigger: ["blur", "change"],
|
37
|
-
message: ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.201")) || "\u8BF7\u9009\u62E9\u60A3\u8005"
|
38
|
-
}
|
39
|
-
};
|
40
|
-
const options = ref([]);
|
41
|
-
const formRef = ref();
|
42
|
-
handleSearch("");
|
43
|
-
function renderLabel(option) {
|
44
|
-
var _a2, _b, _c, _d;
|
45
|
-
const {
|
46
|
-
bcq04b,
|
47
|
-
vae96
|
48
|
-
} = option;
|
49
|
-
const sex = vae96 == "1" ? ((_a2 = window.getLanguageByCode) == null ? void 0 : _a2.call(window, "10010.1.203")) || "\u7537" : vae96 == "2" ? ((_b = window.getLanguageByCode) == null ? void 0 : _b.call(window, "10010.1.204")) || "\u5973" : ((_c = window.getLanguageByCode) == null ? void 0 : _c.call(window, "10010.1.205")) || "\u672A\u77E5";
|
50
|
-
let str = "";
|
51
|
-
if (bcq04b) {
|
52
|
-
str += bcq04b + (((_d = window.getLanguageByCode) == null ? void 0 : _d.call(window, "10010.1.191")) || "\u5E8A");
|
53
|
-
}
|
54
|
-
const getPrefix = () => !str || str.endsWith("/") ? "" : "/";
|
55
|
-
const setValue = (key) => {
|
56
|
-
if (option[key]) {
|
57
|
-
str += getPrefix() + option[key];
|
58
|
-
}
|
59
|
-
};
|
60
|
-
setValue("vaa05");
|
61
|
-
str += "/" + sex;
|
62
|
-
setValue("vae87");
|
63
|
-
setValue("bck02a");
|
64
|
-
if (str.startsWith("/")) {
|
65
|
-
str = str.slice(1);
|
66
|
-
}
|
67
|
-
return str;
|
68
|
-
}
|
69
|
-
function handleUpdateValue(value, option) {
|
70
|
-
formValue.bck03a = option.bck03a;
|
71
|
-
}
|
72
|
-
async function handleSearch(keyword) {
|
73
|
-
var _a2;
|
74
|
-
if (!isFunction((_a2 = patientInfo.value) == null ? void 0 : _a2.queryPatient))
|
75
|
-
return;
|
76
|
-
try {
|
77
|
-
const data = await patientInfo.value.queryPatient({
|
78
|
-
keyword,
|
79
|
-
businessType: formValue.businessType
|
80
|
-
});
|
81
|
-
if (isArray(data)) {
|
82
|
-
options.value = data;
|
83
|
-
return;
|
84
|
-
}
|
85
|
-
options.value = [];
|
86
|
-
} catch (error) {
|
87
|
-
options.value = [];
|
88
|
-
}
|
89
|
-
}
|
90
|
-
function handleBusinessTypeUpdate() {
|
91
|
-
formValue.vaa01 = null;
|
92
|
-
formValue.bck03a = "";
|
93
|
-
handleSearch("");
|
94
|
-
}
|
95
|
-
function handleValidateClick(e) {
|
96
|
-
var _a2;
|
97
|
-
e.preventDefault();
|
98
|
-
(_a2 = formRef.value) == null ? void 0 : _a2.validate((errors) => {
|
99
|
-
if (!errors) {
|
100
|
-
const json = {
|
101
|
-
...formValue,
|
102
|
-
...options.value.find((option) => option.vaa01 === formValue.vaa01)
|
103
|
-
};
|
104
|
-
if (state.showPatient) {
|
105
|
-
state.selectedPatientLabel = renderLabel(json);
|
106
|
-
state.selectedPatientForm = json;
|
107
|
-
} else {
|
108
|
-
state.selectedPatient = json;
|
109
|
-
}
|
110
|
-
emit("update:show", false);
|
111
|
-
}
|
112
|
-
});
|
113
|
-
}
|
114
|
-
return (_ctx, _cache) => {
|
115
|
-
return openBlock(), createBlock(unref(NDrawer), {
|
116
|
-
placement: "bottom",
|
117
|
-
height: "300",
|
118
|
-
"trap-focus": false,
|
119
|
-
to: "#" + unref(state).id,
|
120
|
-
show: __props.show,
|
121
|
-
onMaskClick: _cache[2] || (_cache[2] = () => emit("update:show", false))
|
122
|
-
}, {
|
123
|
-
default: withCtx(() => [createVNode(unref(NDrawerContent), null, {
|
124
|
-
default: withCtx(() => [createVNode(unref(NForm), {
|
125
|
-
ref_key: "formRef",
|
126
|
-
ref: formRef,
|
127
|
-
"label-placement": "left",
|
128
|
-
"label-width": "auto",
|
129
|
-
size: "large",
|
130
|
-
model: formValue,
|
131
|
-
"require-mark-placement": "right-hanging",
|
132
|
-
rules
|
133
|
-
}, {
|
134
|
-
default: withCtx(() => {
|
135
|
-
var _a2, _b, _c;
|
136
|
-
return [createVNode(unref(NFormItem), {
|
137
|
-
label: ((_a2 = window.getLanguageByCode) == null ? void 0 : _a2.call(window, "10010.1.197")) || "\u4E1A\u52A1",
|
138
|
-
path: "businessType"
|
139
|
-
}, {
|
140
|
-
default: withCtx(() => {
|
141
|
-
var _a3;
|
142
|
-
return [createVNode(unref(NRadioGroup), {
|
143
|
-
value: formValue.businessType,
|
144
|
-
"onUpdate:value": [_cache[0] || (_cache[0] = ($event) => formValue.businessType = $event), handleBusinessTypeUpdate],
|
145
|
-
name: ((_a3 = window.getLanguageByCode) == null ? void 0 : _a3.call(window, "10010.1.197")) || "\u4E1A\u52A1"
|
146
|
-
}, {
|
147
|
-
default: withCtx(() => [createVNode(unref(NRadio), {
|
148
|
-
value: "CLINICIAN"
|
149
|
-
}, {
|
150
|
-
default: withCtx(() => {
|
151
|
-
var _a4;
|
152
|
-
return [createTextVNode(((_a4 = window.getLanguageByCode) == null ? void 0 : _a4.call(window, "10010.1.198")) || "\u95E8\u8BCA")];
|
153
|
-
}),
|
154
|
-
_: 1
|
155
|
-
}), createVNode(unref(NRadio), {
|
156
|
-
value: "HOSPITAL"
|
157
|
-
}, {
|
158
|
-
default: withCtx(() => {
|
159
|
-
var _a4;
|
160
|
-
return [createTextVNode(((_a4 = window.getLanguageByCode) == null ? void 0 : _a4.call(window, "10010.1.199")) || "\u4F4F\u9662")];
|
161
|
-
}),
|
162
|
-
_: 1
|
163
|
-
})]),
|
164
|
-
_: 1
|
165
|
-
}, 8, ["value"])];
|
166
|
-
}),
|
167
|
-
_: 1
|
168
|
-
}), createVNode(unref(NFormItem), {
|
169
|
-
label: ((_b = window.getLanguageByCode) == null ? void 0 : _b.call(window, "10010.1.200")) || "\u60A3\u8005",
|
170
|
-
path: "vaa01"
|
171
|
-
}, {
|
172
|
-
default: withCtx(() => {
|
173
|
-
var _a3;
|
174
|
-
return [createVNode(unref(NSelect), {
|
175
|
-
to: "body",
|
176
|
-
remote: "",
|
177
|
-
value: formValue.vaa01,
|
178
|
-
"onUpdate:value": [_cache[1] || (_cache[1] = ($event) => formValue.vaa01 = $event), handleUpdateValue],
|
179
|
-
placeholder: ((_a3 = window.getLanguageByCode) == null ? void 0 : _a3.call(window, "10010.1.201")) || "\u8BF7\u9009\u62E9\u60A3\u8005",
|
180
|
-
filterable: "",
|
181
|
-
options: options.value,
|
182
|
-
"render-label": renderLabel,
|
183
|
-
"value-field": "vaa01",
|
184
|
-
onSearch: handleSearch
|
185
|
-
}, null, 8, ["value", "options"])];
|
186
|
-
}),
|
187
|
-
_: 1
|
188
|
-
}), createVNode(unref(NFormItem), {
|
189
|
-
label: ((_c = window.getLanguageByCode) == null ? void 0 : _c.call(window, "10010.1.202")) || "\u79D1\u5BA4"
|
190
|
-
}, {
|
191
|
-
default: withCtx(() => [createTextVNode(toDisplayString(formValue.bck03a), 1)]),
|
192
|
-
_: 1
|
193
|
-
}), createVNode(unref(NFormItem), null, {
|
194
|
-
default: withCtx(() => [createVNode(unref(NButton), {
|
195
|
-
block: "",
|
196
|
-
type: "primary",
|
197
|
-
onClick: handleValidateClick
|
198
|
-
}, {
|
199
|
-
default: withCtx(() => {
|
200
|
-
var _a3;
|
201
|
-
return [createTextVNode(((_a3 = window.getLanguageByCode) == null ? void 0 : _a3.call(window, "10010.1.27")) || "\u786E\u5B9A")];
|
202
|
-
}),
|
203
|
-
_: 1
|
204
|
-
})]),
|
205
|
-
_: 1
|
206
|
-
})];
|
207
|
-
}),
|
208
|
-
_: 1
|
209
|
-
}, 8, ["model"])]),
|
210
|
-
_: 1
|
211
|
-
})]),
|
212
|
-
_: 1
|
213
|
-
}, 8, ["to", "show"]);
|
214
|
-
};
|
215
|
-
}
|
216
|
-
});
|
217
|
-
|
218
|
-
export { _sfc_main as default };
|
@@ -1,45 +0,0 @@
|
|
1
|
-
import { AnyObject } from '../../../../shared/types';
|
2
|
-
declare const _default: import("vue").DefineComponent<{
|
3
|
-
show: {
|
4
|
-
type: BooleanConstructor;
|
5
|
-
};
|
6
|
-
}, {
|
7
|
-
pageInfo: {
|
8
|
-
page: number;
|
9
|
-
hasMore: boolean;
|
10
|
-
};
|
11
|
-
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
12
|
-
show: {
|
13
|
-
type: BooleanConstructor;
|
14
|
-
};
|
15
|
-
}>> & {
|
16
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
17
|
-
}>>;
|
18
|
-
emit: (event: "update:show", ...args: any[]) => void;
|
19
|
-
state: AnyObject;
|
20
|
-
queryPrompt: import("vue").Ref<any>;
|
21
|
-
listRef: import("vue").Ref<any>;
|
22
|
-
keyword: import("vue").Ref<string>;
|
23
|
-
list: import("vue").Ref<AnyObject[]>;
|
24
|
-
showNoData: import("vue").ComputedRef<boolean>;
|
25
|
-
handleInput: () => void;
|
26
|
-
handleSearch: () => Promise<void>;
|
27
|
-
resetAndSearch: () => void;
|
28
|
-
select: (item: AnyObject) => void;
|
29
|
-
NDrawer: any;
|
30
|
-
NDrawerContent: any;
|
31
|
-
NIcon: any;
|
32
|
-
NInput: any;
|
33
|
-
NButton: any;
|
34
|
-
CloseOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
35
|
-
SearchOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
36
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:show"[], "update:show", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
37
|
-
show: {
|
38
|
-
type: BooleanConstructor;
|
39
|
-
};
|
40
|
-
}>> & {
|
41
|
-
"onUpdate:show"?: ((...args: any[]) => any) | undefined;
|
42
|
-
}, {
|
43
|
-
show: boolean;
|
44
|
-
}>;
|
45
|
-
export default _default;
|
@@ -1,143 +0,0 @@
|
|
1
|
-
import { createElementVNode, defineComponent, ref, computed, watch, openBlock, createBlock, unref, withCtx, createVNode, createElementBlock, Fragment, renderList, toDisplayString, withDirectives, vShow } from 'vue';
|
2
|
-
import { NDrawer, NDrawerContent, NButton, NIcon, NInput } from 'naive-ui';
|
3
|
-
import { CloseOutline, SearchOutline } from '@vicons/ionicons5';
|
4
|
-
import { isFunction } from 'lodash-es';
|
5
|
-
import '../../../../shared/utils/index.js';
|
6
|
-
import { useDebounceFn } from '@vueuse/core';
|
7
|
-
import 'date-fns';
|
8
|
-
import '@vue/shared';
|
9
|
-
import '@vueuse/shared';
|
10
|
-
import '../../../../shared/hooks/selectHooks/useSearchContent.js';
|
11
|
-
import { useScrollLoading } from '../../../../shared/hooks/useScrollLoading.js';
|
12
|
-
import { useData } from '../hooks/useData.js';
|
13
|
-
import '../utils/index.js';
|
14
|
-
|
15
|
-
var _a;
|
16
|
-
const _hoisted_1 = {
|
17
|
-
class: "title"
|
18
|
-
};
|
19
|
-
const _hoisted_2 = /* @__PURE__ */ createElementVNode("span", null, ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.206")) || "\u53D1\u73B0\u63D0\u793A\u8BCD", -1);
|
20
|
-
const _hoisted_3 = ["onClick"];
|
21
|
-
var _sfc_main = /* @__PURE__ */ defineComponent({
|
22
|
-
__name: "ChatPrompt",
|
23
|
-
props: {
|
24
|
-
show: {
|
25
|
-
type: Boolean
|
26
|
-
}
|
27
|
-
},
|
28
|
-
emits: ["update:show"],
|
29
|
-
setup(__props, {
|
30
|
-
emit
|
31
|
-
}) {
|
32
|
-
const props = __props;
|
33
|
-
const pageInfo = {
|
34
|
-
page: 0,
|
35
|
-
hasMore: true
|
36
|
-
};
|
37
|
-
const {
|
38
|
-
state,
|
39
|
-
queryPrompt
|
40
|
-
} = useData();
|
41
|
-
const listRef = ref();
|
42
|
-
const keyword = ref("");
|
43
|
-
const list = ref([]);
|
44
|
-
const showNoData = computed(() => !list.value.length && !!(keyword.value || "").replace(/^\s+|\s+$/g, ""));
|
45
|
-
const handleInput = useDebounceFn(resetAndSearch, 500);
|
46
|
-
useScrollLoading(listRef, () => {
|
47
|
-
handleSearch();
|
48
|
-
});
|
49
|
-
async function handleSearch() {
|
50
|
-
try {
|
51
|
-
if (!pageInfo.hasMore || !isFunction(queryPrompt.value))
|
52
|
-
return;
|
53
|
-
pageInfo.page++;
|
54
|
-
if (pageInfo.page == 1) {
|
55
|
-
list.value = [];
|
56
|
-
}
|
57
|
-
const data = await queryPrompt.value({
|
58
|
-
keyword: keyword.value,
|
59
|
-
page: pageInfo.page
|
60
|
-
});
|
61
|
-
if (list.value.length <= +data.records) {
|
62
|
-
list.value = pageInfo.page > 1 ? list.value.concat(data.rows) : data.rows;
|
63
|
-
if (list.value.length >= +data.records) {
|
64
|
-
pageInfo.hasMore = false;
|
65
|
-
}
|
66
|
-
}
|
67
|
-
} catch (error) {
|
68
|
-
} finally {
|
69
|
-
}
|
70
|
-
}
|
71
|
-
function resetAndSearch() {
|
72
|
-
Object.assign(pageInfo, {
|
73
|
-
page: 0,
|
74
|
-
hasMore: true
|
75
|
-
});
|
76
|
-
handleSearch();
|
77
|
-
}
|
78
|
-
function select(item) {
|
79
|
-
emit("update:show", false);
|
80
|
-
state.selectedPrompt = item;
|
81
|
-
state.sendContent = item.promptContent;
|
82
|
-
}
|
83
|
-
watch(() => props.show, (value) => {
|
84
|
-
if (value) {
|
85
|
-
keyword.value = "";
|
86
|
-
resetAndSearch();
|
87
|
-
}
|
88
|
-
});
|
89
|
-
return (_ctx, _cache) => {
|
90
|
-
return openBlock(), createBlock(unref(NDrawer), {
|
91
|
-
placement: "bottom",
|
92
|
-
height: "70%",
|
93
|
-
"trap-focus": false,
|
94
|
-
to: "#" + unref(state).id,
|
95
|
-
show: __props.show,
|
96
|
-
"content-class": "prompt-wrapper",
|
97
|
-
onMaskClick: _cache[2] || (_cache[2] = () => emit("update:show", false))
|
98
|
-
}, {
|
99
|
-
default: withCtx(() => [createVNode(unref(NDrawerContent), null, {
|
100
|
-
header: withCtx(() => [createElementVNode("div", _hoisted_1, [_hoisted_2, createVNode(unref(NButton), {
|
101
|
-
text: "",
|
102
|
-
onClick: _cache[0] || (_cache[0] = () => emit("update:show", false))
|
103
|
-
}, {
|
104
|
-
default: withCtx(() => [createVNode(unref(NIcon), {
|
105
|
-
size: "20",
|
106
|
-
component: unref(CloseOutline)
|
107
|
-
}, null, 8, ["component"])]),
|
108
|
-
_: 1
|
109
|
-
})]), createVNode(unref(NInput), {
|
110
|
-
ref: "inputRef",
|
111
|
-
clearable: "",
|
112
|
-
autofocus: "",
|
113
|
-
value: keyword.value,
|
114
|
-
"onUpdate:value": [_cache[1] || (_cache[1] = ($event) => keyword.value = $event), unref(handleInput)]
|
115
|
-
}, {
|
116
|
-
prefix: withCtx(() => [createVNode(unref(NIcon), {
|
117
|
-
component: unref(SearchOutline)
|
118
|
-
}, null, 8, ["component"])]),
|
119
|
-
_: 1
|
120
|
-
}, 8, ["value", "onUpdate:value"])]),
|
121
|
-
default: withCtx(() => {
|
122
|
-
var _a2;
|
123
|
-
return [createElementVNode("div", {
|
124
|
-
class: "list-wrapper",
|
125
|
-
ref_key: "listRef",
|
126
|
-
ref: listRef
|
127
|
-
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(list.value, (item) => {
|
128
|
-
return openBlock(), createElementBlock("div", {
|
129
|
-
class: "item",
|
130
|
-
key: item.promptId,
|
131
|
-
onClick: () => select(item)
|
132
|
-
}, [createElementVNode("p", null, toDisplayString(item.promptTitle), 1), createElementVNode("p", null, toDisplayString(item.promptContent), 1)], 8, _hoisted_3);
|
133
|
-
}), 128)), withDirectives(createElementVNode("div", null, ((_a2 = window.getLanguageByCode) == null ? void 0 : _a2.call(window, "10010.1.81")) || "\u627E\u4E0D\u5230\u76F8\u5173\u7684\u7ED3\u679C", 512), [[vShow, unref(showNoData)]])], 512)];
|
134
|
-
}),
|
135
|
-
_: 1
|
136
|
-
})]),
|
137
|
-
_: 1
|
138
|
-
}, 8, ["to", "show"]);
|
139
|
-
};
|
140
|
-
}
|
141
|
-
});
|
142
|
-
|
143
|
-
export { _sfc_main as default };
|
@@ -1,57 +0,0 @@
|
|
1
|
-
import { AnyObject } from '../../../../shared/types';
|
2
|
-
declare const _default: import("vue").DefineComponent<{}, {
|
3
|
-
medicalLabel: {
|
4
|
-
key: string;
|
5
|
-
title: string;
|
6
|
-
}[];
|
7
|
-
state: AnyObject;
|
8
|
-
configs: import("vue").Ref<any>;
|
9
|
-
sendMessage: (params?: AnyObject) => Promise<void>;
|
10
|
-
isStreamingOutput: import("vue").Ref<any>;
|
11
|
-
toolbarConfig: {
|
12
|
-
toolbarKeys: never[];
|
13
|
-
};
|
14
|
-
content: import("vue").Ref<string>;
|
15
|
-
saveDisabled: import("vue").ComputedRef<any>;
|
16
|
-
handleSave: () => Promise<void>;
|
17
|
-
handleDelete: () => Promise<void>;
|
18
|
-
createMedicalRecord: () => void;
|
19
|
-
extractContentByTitle: () => AnyObject;
|
20
|
-
NSpace: any;
|
21
|
-
NButton: any;
|
22
|
-
Editor: import("../../../../shared/types").SFCWithInstall<import("vue").DefineComponent<{
|
23
|
-
editorConfig: {
|
24
|
-
type: ObjectConstructor;
|
25
|
-
};
|
26
|
-
toolbarConfig: {
|
27
|
-
type: ObjectConstructor;
|
28
|
-
};
|
29
|
-
uploadImgUrl: {
|
30
|
-
type: StringConstructor;
|
31
|
-
};
|
32
|
-
isDisabled: {
|
33
|
-
type: BooleanConstructor;
|
34
|
-
default: boolean;
|
35
|
-
};
|
36
|
-
}, {
|
37
|
-
editorRef: import("vue").ShallowRef<any>;
|
38
|
-
renderVN: () => JSX.Element;
|
39
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, never[], never, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
40
|
-
editorConfig: {
|
41
|
-
type: ObjectConstructor;
|
42
|
-
};
|
43
|
-
toolbarConfig: {
|
44
|
-
type: ObjectConstructor;
|
45
|
-
};
|
46
|
-
uploadImgUrl: {
|
47
|
-
type: StringConstructor;
|
48
|
-
};
|
49
|
-
isDisabled: {
|
50
|
-
type: BooleanConstructor;
|
51
|
-
default: boolean;
|
52
|
-
};
|
53
|
-
}>> & {}, {
|
54
|
-
isDisabled: boolean;
|
55
|
-
}>>;
|
56
|
-
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
57
|
-
export default _default;
|
@@ -1,190 +0,0 @@
|
|
1
|
-
import { defineComponent, reactive, ref, computed, watch, withDirectives, openBlock, createElementBlock, createVNode, unref, withCtx, createTextVNode, createCommentVNode, vShow } from 'vue';
|
2
|
-
import { NSpace, NButton } from 'naive-ui';
|
3
|
-
import { $message } from '../utils/index.js';
|
4
|
-
import Editor from '../../../editor/index.js';
|
5
|
-
import { callbackApi } from '../api/index.js';
|
6
|
-
import { useData } from '../hooks/useData.js';
|
7
|
-
import 'lodash-es';
|
8
|
-
|
9
|
-
const _hoisted_1 = {
|
10
|
-
class: "ai-chat-right"
|
11
|
-
};
|
12
|
-
var _sfc_main = /* @__PURE__ */ defineComponent({
|
13
|
-
__name: "ChatRight",
|
14
|
-
setup(__props) {
|
15
|
-
const medicalLabel = [{
|
16
|
-
key: "zs_yy",
|
17
|
-
title: "\u4E3B\u8BC9"
|
18
|
-
}, {
|
19
|
-
key: "xbs_fuk",
|
20
|
-
title: "\u73B0\u75C5\u53F2"
|
21
|
-
}, {
|
22
|
-
key: "jws_vtk",
|
23
|
-
title: "\u65E2\u5F80\u53F2"
|
24
|
-
}, {
|
25
|
-
key: "patient_allergy_sync",
|
26
|
-
title: "\u8FC7\u654F\u53F2"
|
27
|
-
}, {
|
28
|
-
key: "tgjcms_wsssss",
|
29
|
-
title: "\u4F53\u683C\u68C0\u67E5\u63CF\u8FF0"
|
30
|
-
}, {
|
31
|
-
key: "marriage",
|
32
|
-
title: "\u5A5A\u59FB\u72B6\u51B5"
|
33
|
-
}, {
|
34
|
-
key: "nation",
|
35
|
-
title: "\u6C11\u65CF"
|
36
|
-
}, {
|
37
|
-
key: "profession",
|
38
|
-
title: "\u804C\u4E1A"
|
39
|
-
}, {
|
40
|
-
key: "jkzk_wyuu",
|
41
|
-
title: "\u4E00\u822C\u5065\u5EB7\u72B6\u51B5"
|
42
|
-
}, {
|
43
|
-
key: "ryljlz_tbyvrt",
|
44
|
-
title: "\u5916\u957F\u671F\u5C45\u4F4F\u53F2"
|
45
|
-
}, {
|
46
|
-
key: "yjbz_qisf1",
|
47
|
-
title: "\u996E\u9152\u6807\u5FD7"
|
48
|
-
}, {
|
49
|
-
key: "gydwufcjfsxwzjcs_aogt_oietyntrrqk",
|
50
|
-
title: "\u5DE5\u4E1A\u6BD2\u7269\u3001\u7C89\u5C18\u53CA\u653E\u5C04\u6027\u7269\u8D28\u63A5\u89E6\u53F2"
|
51
|
-
}, {
|
52
|
-
key: "yqtysjcs_ua_uirqk",
|
53
|
-
title: "\u75AB\u533A\u3001\u75AB\u6C34\u63A5\u89E6\u53F2"
|
54
|
-
}, {
|
55
|
-
key: "ryct_tbsw",
|
56
|
-
title: "\u5165\u9662\u67E5\u4F53"
|
57
|
-
}, {
|
58
|
-
key: "fzjclg_lessxj",
|
59
|
-
title: "\u8F85\u52A9\u68C0\u67E5\u7ED3\u679C"
|
60
|
-
}, {
|
61
|
-
key: "o_hn_iyjc_hr",
|
62
|
-
title: "\u4E92\u8BA4\u56DE\u586B"
|
63
|
-
}, {
|
64
|
-
key: "cbzd_phyo",
|
65
|
-
title: "\u521D\u6B65\u8BCA\u65AD"
|
66
|
-
}, {
|
67
|
-
key: "zljh_yuya",
|
68
|
-
title: "\u8BCA\u7597\u8BA1\u5212"
|
69
|
-
}, {
|
70
|
-
key: "wdcqjzs_qftanwk",
|
71
|
-
title: "\u5916\u5730\u957F\u671F\u5C45\u4F4F\u53F2"
|
72
|
-
}];
|
73
|
-
const {
|
74
|
-
state,
|
75
|
-
configs,
|
76
|
-
sendMessage,
|
77
|
-
isStreamingOutput
|
78
|
-
} = useData();
|
79
|
-
const toolbarConfig = reactive({
|
80
|
-
toolbarKeys: []
|
81
|
-
});
|
82
|
-
const content = ref("");
|
83
|
-
const saveDisabled = computed(() => {
|
84
|
-
var _a;
|
85
|
-
return state.loading || !((_a = state.consultationContent) == null ? void 0 : _a.id);
|
86
|
-
});
|
87
|
-
async function handleSave() {
|
88
|
-
try {
|
89
|
-
state.loading = true;
|
90
|
-
const json = extractContentByTitle();
|
91
|
-
state.consultationContent.contents[0].content.details.autoBackFillData = json;
|
92
|
-
await callbackApi(state.consultationContent);
|
93
|
-
$message.success("\u4FDD\u5B58\u6210\u529F");
|
94
|
-
} catch (error) {
|
95
|
-
console.log("error ==>", error);
|
96
|
-
} finally {
|
97
|
-
state.loading = false;
|
98
|
-
}
|
99
|
-
}
|
100
|
-
function createMedicalRecord() {
|
101
|
-
var _a;
|
102
|
-
const json = extractContentByTitle();
|
103
|
-
console.log("json ==>", json, state.consultationContent);
|
104
|
-
state.consultationContent.contents[0].content.details.autoBackFillData = json;
|
105
|
-
if (!isStreamingOutput.value) {
|
106
|
-
state.loadingText = "\u7CFB\u7EDF\u8FDB\u5165\u6DF1\u5EA6\u5206\u6790\u6A21\u5F0F\uFF0C\u6B63\u5728\u6574\u5408\u6570\u636E\uFF0C\u8C03\u53D6\u4E3B\u8BC9\uFF0C\u83B7\u53D6\u73B0\u75C5\u53F2\u3001\u65E2\u5F80\u75C5\u53F2\uFF0C\u8BFB\u53D6\u8FC7\u654F\u53F2\uFF0C\u7EFC\u5408\u591A\u7EF4\u5EA6\u4FE1\u606F\u751F\u6210\u8BCA\u65AD\u5EFA\u8BAE";
|
107
|
-
}
|
108
|
-
sendMessage({
|
109
|
-
opType: "create_medical",
|
110
|
-
...state.consultationContent,
|
111
|
-
contents: [{
|
112
|
-
role: "user",
|
113
|
-
content: "",
|
114
|
-
contentType: "text"
|
115
|
-
}],
|
116
|
-
medicalInfo: state.consultationContent,
|
117
|
-
firstSubmit: true,
|
118
|
-
parentMsgId: state.consultationContent.msgId,
|
119
|
-
flowResult: state.consultationContent.contents[0].content
|
120
|
-
});
|
121
|
-
state.inquiryStr = ((_a = state.consultationContent) == null ? void 0 : _a.__title) || "";
|
122
|
-
}
|
123
|
-
watch(() => state.showRight, (value) => {
|
124
|
-
var _a, _b, _c, _d;
|
125
|
-
if (!value) {
|
126
|
-
state.consultationContent = null;
|
127
|
-
} else {
|
128
|
-
state.showRightSlot = false;
|
129
|
-
const {
|
130
|
-
autoBackFillData
|
131
|
-
} = ((_d = (_c = (_b = (_a = state.consultationContent) == null ? void 0 : _a.contents) == null ? void 0 : _b[0]) == null ? void 0 : _c.content) == null ? void 0 : _d.details) || {};
|
132
|
-
content.value = "";
|
133
|
-
if (!autoBackFillData)
|
134
|
-
return;
|
135
|
-
medicalLabel.forEach((item, index) => {
|
136
|
-
content.value += `<p><span style="font-size: 16px;"><strong>${index + 1}\u3001${item.title}</strong></span></p><p><span>${autoBackFillData[item.key] || ""}</span></p>`;
|
137
|
-
});
|
138
|
-
const str = Object.keys(autoBackFillData).reduce((prev, cur) => {
|
139
|
-
var _a2;
|
140
|
-
const title = (_a2 = medicalLabel.find((i) => i.key === cur)) == null ? void 0 : _a2.title;
|
141
|
-
prev += title + ": " + autoBackFillData[cur] + "\n";
|
142
|
-
return prev;
|
143
|
-
}, "");
|
144
|
-
state.inquiryStr = str;
|
145
|
-
}
|
146
|
-
});
|
147
|
-
function extractContentByTitle() {
|
148
|
-
const result = {};
|
149
|
-
medicalLabel.forEach((item) => {
|
150
|
-
const regex = new RegExp(`<p><span.*?><strong>\\d+\u3001${item.title}<\\/strong><\\/span><\\/p><p>(.*?)<\\/p>`, "i");
|
151
|
-
const match = content.value.match(regex);
|
152
|
-
if (match && match[1]) {
|
153
|
-
const res = match[1].trim();
|
154
|
-
result[item.key] = res === "<br>" ? "" : res;
|
155
|
-
}
|
156
|
-
});
|
157
|
-
return result;
|
158
|
-
}
|
159
|
-
return (_ctx, _cache) => {
|
160
|
-
return withDirectives((openBlock(), createElementBlock("div", _hoisted_1, [createVNode(unref(Editor), {
|
161
|
-
"toolbar-config": toolbarConfig,
|
162
|
-
modelValue: content.value,
|
163
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => content.value = $event)
|
164
|
-
}, null, 8, ["toolbar-config", "modelValue"]), createVNode(unref(NSpace), {
|
165
|
-
class: "footer",
|
166
|
-
"wrap-item": false
|
167
|
-
}, {
|
168
|
-
default: withCtx(() => [createVNode(unref(NButton), {
|
169
|
-
round: "",
|
170
|
-
class: "gradient",
|
171
|
-
disabled: unref(state).loading,
|
172
|
-
onClick: createMedicalRecord
|
173
|
-
}, {
|
174
|
-
default: withCtx(() => [createTextVNode("\u5BA1\u6838\u5B8C\u6210")]),
|
175
|
-
_: 1
|
176
|
-
}, 8, ["disabled"]), createVNode(unref(NButton), {
|
177
|
-
round: "",
|
178
|
-
onClick: handleSave,
|
179
|
-
disabled: unref(saveDisabled)
|
180
|
-
}, {
|
181
|
-
default: withCtx(() => [createTextVNode("\u6682\u5B58")]),
|
182
|
-
_: 1
|
183
|
-
}, 8, ["disabled"]), createCommentVNode(' <n-button round @click="handleDelete" :disabled="state.loading" style="margin-left: auto">\u5220\u9664</n-button> ')]),
|
184
|
-
_: 1
|
185
|
-
})], 512)), [[vShow, unref(state).showRight]]);
|
186
|
-
};
|
187
|
-
}
|
188
|
-
});
|
189
|
-
|
190
|
-
export { _sfc_main as default };
|