cnhis-design-vue 3.2.15-beta.9 → 3.2.16-beta.13

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 (148) hide show
  1. package/es/components/ai-chat/index.d.ts +9 -0
  2. package/es/components/ai-chat/src/Index.vue.d.ts +9 -0
  3. package/es/components/ai-chat/src/Index.vue2.js +1 -1
  4. package/es/components/ai-chat/src/components/ChatCard.js +1 -1
  5. package/es/components/ai-chat/style/index.css +1 -1
  6. package/es/components/branch-notice/index.d.ts +32 -3
  7. package/es/components/branch-notice/src/BranchNotice.vue.d.ts +9 -3
  8. package/es/components/branch-notice/src/BranchNotice.vue2.js +1 -1
  9. package/es/components/branch-notice/src/canstants.js +1 -1
  10. package/es/components/button-print/index.d.ts +6 -13
  11. package/es/components/button-print/src/ButtonPrint.vue.d.ts +6 -13
  12. package/es/components/button-print/src/components/NewPrintComponent.vue.d.ts +6 -13
  13. package/es/components/button-print/src/components/NewPrintComponent.vue2.js +1 -1
  14. package/es/components/button-print/src/components/OldPrintComponent.vue2.js +1 -1
  15. package/es/components/button-print/style/index.css +1 -1
  16. package/es/components/callback/src/components/render/popupMaps.d.ts +10 -0
  17. package/es/components/card-reader-sdk/src/cardReaderSDK.js +1 -1
  18. package/es/components/classification/index.d.ts +30 -0
  19. package/es/components/classification/src/components/search-filter/index.vue.d.ts +30 -0
  20. package/es/components/classification/src/components/set-classification/index.vue.d.ts +30 -0
  21. package/es/components/classification/src/components/table-modal/index.vue.d.ts +0 -3
  22. package/es/components/classification/src/index.vue.d.ts +30 -0
  23. package/es/components/date-picker/index.d.ts +10 -0
  24. package/es/components/date-picker/src/DatePicker.vue.d.ts +10 -0
  25. package/es/components/date-picker/src/DatePicker.vue2.js +1 -1
  26. package/es/components/expand-field/index.d.ts +27 -1
  27. package/es/components/expand-field/src/components/FormItemPerson.vue.d.ts +27 -1
  28. package/es/components/expand-field/src/components/PersonModal.vue.d.ts +27 -1
  29. package/es/components/expand-field/src/components/form.vue.d.ts +27 -1
  30. package/es/components/expand-field/src/index.vue.d.ts +27 -1
  31. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useCenter.js +1 -1
  32. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useOther.d.ts +1 -0
  33. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useOther.js +1 -1
  34. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useSurgicalAnesthesiaChart.js +1 -1
  35. package/es/components/fabric-chart/src/hooks/temperature/useCenter.js +1 -1
  36. package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.js +1 -1
  37. package/es/components/fabric-chart/src/hooks/useCommon.d.ts +1 -2
  38. package/es/components/fabric-chart/src/hooks/useDraw.js +1 -1
  39. package/es/components/fabric-chart/src/interface.d.ts +1 -0
  40. package/es/components/field-set/src/FieldColor.vue.d.ts +24 -4
  41. package/es/components/field-set/src/FieldFilter.vue.d.ts +6 -5
  42. package/es/components/field-set/src/FieldFilter.vue2.js +1 -1
  43. package/es/components/field-set/src/FieldSet.vue.d.ts +5 -5
  44. package/es/components/field-set/src/components/condition.vue.d.ts +10 -0
  45. package/es/components/field-set/src/components/edit-dialog.vue.d.ts +20 -0
  46. package/es/components/field-set/src/components/edit-filter.vue.d.ts +10 -0
  47. package/es/components/field-set/src/components/table-row.vue.d.ts +4 -4
  48. package/es/components/field-set/src/components/table-row.vue2.js +1 -1
  49. package/es/components/field-set/src/utils/index.js +1 -1
  50. package/es/components/form-config/index.d.ts +1051 -1
  51. package/es/components/form-config/src/FormConfig.vue.d.ts +1051 -1
  52. package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +10 -0
  53. package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +10 -1
  54. package/es/components/form-config/src/components/FormConfigEdit.vue2.js +1 -1
  55. package/es/components/form-config/src/components/FormConfigEventSetting.vue.d.ts +1029 -0
  56. package/es/components/form-config/src/components/FormConfigEventSetting.vue2.js +1 -1
  57. package/es/components/form-config/src/constants/index.js +1 -1
  58. package/es/components/form-config/style/index.css +1 -1
  59. package/es/components/form-render/index.d.ts +10 -0
  60. package/es/components/form-render/src/FormRender.vue.d.ts +10 -0
  61. package/es/components/form-render/src/FormRender.vue2.js +1 -1
  62. package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +10 -0
  63. package/es/components/form-render/src/components/renderer/input.d.ts +9 -1
  64. package/es/components/form-render/src/components/renderer/input.js +1 -1
  65. package/es/components/form-render/src/components/renderer/select.d.ts +6 -0
  66. package/es/components/form-render/src/components/renderer/select.js +1 -1
  67. package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -1
  68. package/es/components/form-render/src/hooks/useLowCodeReactions.js +1 -1
  69. package/es/components/iho-chat/index.d.ts +477 -102
  70. package/es/components/iho-chat/src/Index.vue.d.ts +477 -102
  71. package/es/components/iho-chat/src/Index.vue2.js +1 -1
  72. package/es/components/iho-chat/src/components/ChatAdd.vue.d.ts +33 -9
  73. package/es/components/iho-chat/src/components/ChatAdd.vue2.js +1 -1
  74. package/es/components/iho-chat/src/components/ChatFile.vue.d.ts +33 -10
  75. package/es/components/iho-chat/src/components/ChatFile.vue2.js +1 -1
  76. package/es/components/iho-chat/src/components/ChatFooter.vue.d.ts +33 -10
  77. package/es/components/iho-chat/src/components/ChatFooter.vue2.js +1 -1
  78. package/es/components/iho-chat/src/components/ChatHeader.vue.d.ts +133 -45
  79. package/es/components/iho-chat/src/components/ChatMain.vue.d.ts +183 -18
  80. package/es/components/iho-chat/src/components/ChatMain.vue2.js +1 -1
  81. package/es/components/iho-chat/src/components/ChatRecord.vue.d.ts +10 -1
  82. package/es/components/iho-chat/src/components/ChatSearch.vue.d.ts +0 -1
  83. package/es/components/iho-chat/src/components/ChatSet.vue.d.ts +45 -17
  84. package/es/components/iho-chat/src/components/MessageEvent.vue.d.ts +137 -0
  85. package/es/components/iho-chat/src/components/MessageEvent.vue.js +1 -0
  86. package/es/components/iho-chat/src/components/MessageEvent.vue2.js +1 -0
  87. package/es/components/iho-chat/src/components/MultipleVideo.vue.d.ts +40 -13
  88. package/es/components/iho-chat/src/components/MultipleVideo.vue2.js +1 -1
  89. package/es/components/iho-chat/src/components/PersonProfile.vue.d.ts +13 -7
  90. package/es/components/iho-chat/src/components/PersonProfile.vue2.js +1 -1
  91. package/es/components/iho-chat/src/components/SiderList.vue.d.ts +11 -1
  92. package/es/components/iho-chat/src/components/SiderList.vue2.js +1 -1
  93. package/es/components/iho-chat/src/components/Video.vue.d.ts +2 -2
  94. package/es/components/iho-chat/src/components/Video.vue2.js +1 -1
  95. package/es/components/iho-chat/src/constants/index.d.ts +2 -1
  96. package/es/components/iho-chat/src/constants/index.js +1 -1
  97. package/es/components/iho-chat/src/hooks/useData.d.ts +4 -2
  98. package/es/components/iho-chat/src/hooks/useData.js +1 -1
  99. package/es/components/iho-chat/src/hooks/useVideo.d.ts +3 -3
  100. package/es/components/iho-chat/src/hooks/useVideo.js +1 -1
  101. package/es/components/iho-chat/src/types/index.d.ts +13 -2
  102. package/es/components/iho-chat/src/utils/asyncQueue.d.ts +10 -0
  103. package/es/components/iho-chat/src/utils/asyncQueue.js +1 -0
  104. package/es/components/iho-chat/style/iconfont.ttf +0 -0
  105. package/es/components/iho-chat/style/index.css +1 -1
  106. package/es/components/iho-table/src/plugins/filterDaterangeRenderPlugin/filter.vue.d.ts +10 -0
  107. package/es/components/iho-table/src/plugins/filterRenderPlugin/filter.vue2.js +1 -1
  108. package/es/components/iho-table/src/plugins/filterRenderPlugin/index.js +1 -1
  109. package/es/components/iho-table/src/plugins/filterTextPlugin/filter.vue.d.ts +1 -0
  110. package/es/components/iho-table/src/plugins/filterTextPlugin/filter.vue2.js +1 -1
  111. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.d.ts +10 -0
  112. package/es/components/iho-table/src/types/index.d.ts +17 -0
  113. package/es/components/iho-table/src/utils/index.js +1 -1
  114. package/es/components/iho-table/style/index.css +1 -1
  115. package/es/components/index.css +1 -1
  116. package/es/components/info-header/index.d.ts +20 -0
  117. package/es/components/info-header/src/InfoHeader.vue.d.ts +20 -0
  118. package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +10 -0
  119. package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +10 -0
  120. package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
  121. package/es/components/select-person/index.d.ts +27 -1
  122. package/es/components/select-person/src/SelectPerson.vue.d.ts +15 -1
  123. package/es/components/select-person/src/SelectPerson.vue2.js +1 -1
  124. package/es/components/select-person/src/index.vue.d.ts +27 -1
  125. package/es/components/select-person/src/index.vue2.js +1 -1
  126. package/es/components/shortcut-setter/index.d.ts +10 -0
  127. package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +10 -0
  128. package/es/components/table-filter/src/components/bi-filter/ValueCfg.vue.d.ts +10 -0
  129. package/es/components/table-filter/src/components/bi-filter/components/Date.vue.d.ts +10 -0
  130. package/es/components/table-filter/src/components/bi-filter/components/index.d.ts +10 -0
  131. package/es/components/table-filter/src/components/bi-filter/index.vue.d.ts +10 -0
  132. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.d.ts +20 -0
  133. package/es/components/table-filter/src/components/classify-filter/components/Date.vue.d.ts +10 -0
  134. package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue.d.ts +10 -0
  135. package/es/components/table-filter/src/components/classify-filter/components/index.d.ts +20 -0
  136. package/es/components/table-filter/src/components/classify-filter/index.vue.d.ts +20 -0
  137. package/es/components/table-filter/src/components/render-widget/components/DateInner.vue.d.ts +10 -0
  138. package/es/components/table-filter/src/components/render-widget/components/DateOut.vue.d.ts +10 -0
  139. package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue.d.ts +10 -0
  140. package/es/components/table-filter/src/components/render-widget/components/DateRangeOut.vue.d.ts +10 -0
  141. package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue2.js +1 -1
  142. package/es/components/table-filter/src/components/render-widget/components/index.d.ts +40 -0
  143. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +40 -0
  144. package/es/env.d.ts +25 -25
  145. package/es/shared/hooks/useDateTime.js +1 -1
  146. package/es/shared/package.json.js +1 -1
  147. package/es/shared/types/business.d.ts +4 -0
  148. package/package.json +2 -2
@@ -0,0 +1,137 @@
1
+ import { PropType } from 'vue';
2
+ import { AnyObject } from '../../../../shared/types';
3
+ declare const _default: import("vue").DefineComponent<{
4
+ data: {
5
+ type: PropType<AnyObject>;
6
+ required: true;
7
+ };
8
+ }, {
9
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
10
+ data: {
11
+ type: PropType<AnyObject>;
12
+ required: true;
13
+ };
14
+ }>> & {}>>;
15
+ state: {
16
+ orgId: string | number;
17
+ currentSessionItem: AnyObject;
18
+ id: string;
19
+ userInfo: AnyObject;
20
+ msgList: AnyObject[];
21
+ currentMsg: AnyObject;
22
+ isAppendMsg: boolean;
23
+ sessionList: AnyObject[];
24
+ isChangeSession: boolean;
25
+ updateSessionItem: AnyObject;
26
+ isUpdateSession: boolean;
27
+ currentReferenceMsg: AnyObject | null;
28
+ currentReEditMsg: AnyObject | null;
29
+ showVideo: boolean;
30
+ currentAVMsg: AnyObject;
31
+ currentGroupUser: AnyObject[];
32
+ showMultipleVideo: boolean;
33
+ };
34
+ inviter: import("vue").Ref<any>;
35
+ invitee: import("vue").Ref<any[]>;
36
+ isValidJSON: (str: string) => boolean;
37
+ getTask: (_id: number | string, arrRes: AnyObject[]) => () => Promise<unknown>;
38
+ getEventContent: (data: AnyObject) => Promise<void>;
39
+ NButton: any;
40
+ PersonProfile: import("vue").DefineComponent<{
41
+ userId: {
42
+ type: (NumberConstructor | StringConstructor)[];
43
+ };
44
+ disabled: {
45
+ type: BooleanConstructor;
46
+ default: boolean;
47
+ };
48
+ userInfo: {
49
+ type: PropType<AnyObject>;
50
+ };
51
+ }, {
52
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
53
+ userId: {
54
+ type: (NumberConstructor | StringConstructor)[];
55
+ };
56
+ disabled: {
57
+ type: BooleanConstructor;
58
+ default: boolean;
59
+ };
60
+ userInfo: {
61
+ type: PropType<AnyObject>;
62
+ };
63
+ }>> & {
64
+ onClose?: ((...args: any[]) => any) | undefined;
65
+ }>>;
66
+ emit: (event: "close", ...args: any[]) => void;
67
+ state: {
68
+ orgId: string | number;
69
+ currentSessionItem: AnyObject;
70
+ id: string;
71
+ userInfo: AnyObject;
72
+ msgList: AnyObject[];
73
+ currentMsg: AnyObject;
74
+ isAppendMsg: boolean;
75
+ sessionList: AnyObject[];
76
+ isChangeSession: boolean;
77
+ updateSessionItem: AnyObject;
78
+ isUpdateSession: boolean;
79
+ currentReferenceMsg: AnyObject | null;
80
+ currentReEditMsg: AnyObject | null;
81
+ showVideo: boolean;
82
+ currentAVMsg: AnyObject;
83
+ currentGroupUser: AnyObject[];
84
+ showMultipleVideo: boolean;
85
+ };
86
+ openSession: (session: string | AnyObject) => Promise<void>;
87
+ showUserDetail: import("vue").Ref<boolean>;
88
+ showLargeAvatar: import("vue").Ref<boolean>;
89
+ showPhone: import("vue").Ref<boolean>;
90
+ userDetail: AnyObject;
91
+ info: {
92
+ label: string;
93
+ value: string;
94
+ key: string;
95
+ }[];
96
+ personInfo: import("vue").ComputedRef<{
97
+ label: string;
98
+ value: string;
99
+ key: string;
100
+ }[]>;
101
+ toOpenSession: () => Promise<void>;
102
+ updateShow: (value: boolean) => Promise<void>;
103
+ getContent: (info: AnyObject) => any;
104
+ onChange: (options: {
105
+ file: import("naive-ui").UploadFileInfo;
106
+ }) => Promise<void>;
107
+ NAvatar: any;
108
+ NPopover: any;
109
+ NButton: any;
110
+ NIcon: any;
111
+ ChatbubbleEllipses: 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<{}>>, {}>;
112
+ Close: 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<{}>>, {}>;
113
+ EyeOutline: 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<{}>>, {}>;
114
+ EyeOffOutline: 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<{}>>, {}>;
115
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "close"[], "close", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
116
+ userId: {
117
+ type: (NumberConstructor | StringConstructor)[];
118
+ };
119
+ disabled: {
120
+ type: BooleanConstructor;
121
+ default: boolean;
122
+ };
123
+ userInfo: {
124
+ type: PropType<AnyObject>;
125
+ };
126
+ }>> & {
127
+ onClose?: ((...args: any[]) => any) | undefined;
128
+ }, {
129
+ disabled: boolean;
130
+ }>;
131
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
132
+ data: {
133
+ type: PropType<AnyObject>;
134
+ required: true;
135
+ };
136
+ }>>, {}>;
137
+ export default _default;
@@ -0,0 +1 @@
1
+ import e from"./MessageEvent.vue2.js";import r from"../../../../_virtual/_plugin-vue_export-helper.js";var t=r(e,[["__file","MessageEvent.vue"]]);export{t as default};
@@ -0,0 +1 @@
1
+ import{defineComponent as e,ref as t,openBlock as r,createElementBlock as n,unref as o,createBlock as i,withCtx as s,createVNode as a,createTextVNode as u,toDisplayString as l,Fragment as c,renderList as p,createCommentVNode as d,createElementVNode as m}from"vue";import{NButton as f}from"naive-ui";import v from"./PersonProfile.vue.js";import{useData as g}from"../hooks/useData.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{getUserDetailApi as y}from"../api/index.js";import"../utils/index.js";import{toString as h}from"lodash-es";import"trtc-sdk-v5";import{AsyncScheduler as w}from"../utils/asyncQueue.js";const k={key:0,class:"tip-text"},j={key:0},x=m("span",{style:{"margin-right":"5px"}},"邀请",-1),I={key:0},_={key:2},b=m("span",null,"加入群聊",-1);var O=e({__name:"MessageEvent",props:{data:{type:Object,required:!0}},setup(e){const m=e,{state:O}=g(),P=t(),z=t([]);function B(e,t){return()=>new Promise(((r,n)=>{y({userId:h(e)}).then((e=>{t.push(e),r(e)})).catch((e=>n(e)))}))}return async function(e){var t;const r=null==(t=null==e?void 0:e.content)?void 0:t.msg;if(!function(e){try{return JSON.parse(e),!0}catch(e){return!1}}(r))return;const{inviter:n,invitee:o=[]}=JSON.parse(r);if(!n||!o)return;try{if(n==O.userInfo.id)P.value=O.userInfo;else{const e=await y({userId:h(n)});(null==e?void 0:e.id)&&(P.value=e)}const e=new w,t=[];for(const r of o)r==O.userInfo.id?t.push(O.userInfo):e.add(B(r,t));e.waitForAll().then((()=>{z.value=t}))}catch(e){console.log("error ==>",e)}}(m.data),(e,t)=>{var m;return P.value&&z.value.length>0?(r(),n("p",k,[P.value.id==o(O).userInfo.id?(r(),n("span",j,(null==(m=window.getLanguageByCode)?void 0:m.call(window,"10010.1.67"))||"你")):(r(),i(v,{key:1,placement:"buttom","user-info":P.value},{trigger:s((()=>[a(o(f),{size:"tiny",text:"",style:{color:"var(--c-primary-color)","margin-right":"5px"}},{default:s((()=>[u(l(P.value.name),1)])),_:1})])),_:1},8,["user-info"])),x,(r(!0),n(c,null,p(z.value,((e,t)=>{var p;return r(),n(c,{key:e.id},[e.id==o(O).userInfo.id?(r(),n("span",I,(null==(p=window.getLanguageByCode)?void 0:p.call(window,"10010.1.67"))||"你")):(r(),i(v,{key:1,placement:"buttom","user-info":e},{trigger:s((()=>[a(o(f),{size:"tiny",text:"",style:{color:"var(--c-primary-color)","margin-right":"5px"}},{default:s((()=>[u(l(e.name),1)])),_:2},1024)])),_:2},1032,["user-info"])),t<=z.value.length-2?(r(),n("span",_,"、")):d("v-if",!0)],64)})),128)),b])):d("v-if",!0)}}});export{O as default};
@@ -7,7 +7,6 @@ declare const _default: import("vue").DefineComponent<{}, {
7
7
  name: string;
8
8
  }[]>;
9
9
  state: {
10
- filterable: boolean;
11
10
  orgId: string | number;
12
11
  currentSessionItem: AnyObject;
13
12
  id: string;
@@ -32,7 +31,8 @@ declare const _default: import("vue").DefineComponent<{}, {
32
31
  receiver?: string | undefined;
33
32
  }) => Promise<void>;
34
33
  trtc: TRTC;
35
- voiceOpen: import("vue").Ref<boolean>;
34
+ trtcProxy: import("vue").Ref<any>;
35
+ voiceClose: import("vue").Ref<boolean>;
36
36
  isAudio: import("vue").ComputedRef<boolean>;
37
37
  isCall: import("vue").ComputedRef<boolean>;
38
38
  startTimer: () => void;
@@ -41,7 +41,7 @@ declare const _default: import("vue").DefineComponent<{}, {
41
41
  messageTypeText: import("vue").ComputedRef<"语音" | "视频">;
42
42
  timing: import("vue").Ref<string>;
43
43
  toggleVideo: () => Promise<void>;
44
- videocamOpen: import("vue").Ref<boolean>;
44
+ videocamClose: import("vue").Ref<boolean>;
45
45
  installEventHandlers: ({ handleError, handleRemoteUserEnter, handleRemoteAudioAvailable, handleRemoteUserExit, handleRemoteVideoAvailable }: {
46
46
  handleError: import("../../../../shared/types").AnyFn;
47
47
  handleRemoteUserEnter: import("../../../../shared/types").AnyFn;
@@ -59,7 +59,10 @@ declare const _default: import("vue").DefineComponent<{}, {
59
59
  isConnect: import("vue").Ref<boolean>;
60
60
  callUser: import("vue").ComputedRef<any>;
61
61
  title: import("vue").ComputedRef<string>;
62
- handleAddPerson: (checkedIds: string[]) => void;
62
+ handleAddPerson: ({ checkedIds, checkedOptions }: {
63
+ checkedIds: string[];
64
+ checkedOptions: AnyObject[];
65
+ }) => void;
63
66
  handleCall: () => void;
64
67
  handleEnter: () => Promise<void>;
65
68
  handleExit: () => Promise<void>;
@@ -96,6 +99,11 @@ declare const _default: import("vue").DefineComponent<{}, {
96
99
  default: boolean;
97
100
  };
98
101
  }, {
102
+ initialOptions: AnyObject[];
103
+ tabList: {
104
+ key: string;
105
+ label: string;
106
+ }[];
99
107
  props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
100
108
  title: {
101
109
  type: StringConstructor;
@@ -125,7 +133,6 @@ declare const _default: import("vue").DefineComponent<{}, {
125
133
  }>>;
126
134
  emit: (event: "comfirm", ...args: any[]) => void;
127
135
  state: {
128
- filterable: boolean;
129
136
  orgId: string | number;
130
137
  currentSessionItem: AnyObject;
131
138
  id: string;
@@ -149,27 +156,41 @@ declare const _default: import("vue").DefineComponent<{}, {
149
156
  keyword: import("vue").Ref<string>;
150
157
  showModal: import("vue").Ref<boolean>;
151
158
  checkedOptions: import("vue").Ref<AnyObject[]>;
152
- options: import("vue").Ref<AnyObject[]>;
153
159
  groupName: import("vue").Ref<string>;
154
- checkedSourceIds: import("vue").Ref<(string | number)[]>;
155
160
  remark: import("vue").Ref<string>;
161
+ currentTab: import("vue").Ref<AnyObject[]>;
162
+ breadcrumbList: import("vue").Ref<AnyObject[]>;
156
163
  userList: import("vue").Ref<AnyObject[]>;
157
164
  handleInput: () => void;
158
165
  _disabledIds: import("vue").ComputedRef<any[]>;
159
- defaultOptions: import("vue").ComputedRef<{
166
+ sessionList: import("vue").ComputedRef<{
167
+ id: any;
168
+ name: any;
169
+ avatar: any;
170
+ chatType: any;
171
+ }[]>;
172
+ friends: import("vue").ComputedRef<{
173
+ id: any;
174
+ name: any;
175
+ avatar: any;
176
+ chatType: any;
177
+ }[]>;
178
+ groups: import("vue").ComputedRef<{
160
179
  id: any;
161
180
  name: any;
162
181
  avatar: any;
182
+ chatType: any;
163
183
  }[]>;
164
184
  checkedIds: import("vue").ComputedRef<any[]>;
165
185
  btnDisabled: import("vue").ComputedRef<boolean>;
166
186
  allChecked: import("vue").WritableComputedRef<boolean>;
187
+ checkedSourceIds: import("vue").WritableComputedRef<any[]>;
188
+ currentTabKey: import("vue").ComputedRef<any>;
189
+ getDisabled: (id: string | number) => boolean;
190
+ handleClickCheckbox: (option: AnyObject) => Promise<void>;
191
+ toggleTab: (item: AnyObject) => void;
192
+ handleTabBack: () => void;
167
193
  handlePositiveClick: () => Promise<void>;
168
- updateCheckedSourceIds: () => void;
169
- handleSourceIdsUpdate: (value: (string | number)[], meta: {
170
- actionType: "check" | "uncheck";
171
- value: string | number;
172
- }) => void;
173
194
  closeTag: (id: string) => void;
174
195
  NModal: any;
175
196
  NButton: any;
@@ -181,8 +202,14 @@ declare const _default: import("vue").DefineComponent<{}, {
181
202
  NCheckbox: any;
182
203
  NCheckboxGroup: any;
183
204
  NTooltip: any;
205
+ NBreadcrumb: any;
206
+ NBreadcrumbItem: any;
184
207
  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<{}>>, {}>;
185
208
  AddOutline: 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<{}>>, {}>;
209
+ PersonOutline: 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<{}>>, {}>;
210
+ PeopleOutline: 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<{}>>, {}>;
211
+ ChevronBackOutline: 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<{}>>, {}>;
212
+ last: <T>(array: import("lodash").List<T> | null | undefined) => T | undefined;
186
213
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "comfirm"[], "comfirm", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
187
214
  title: {
188
215
  type: StringConstructor;
@@ -1 +1 @@
1
- import{createElementVNode as e,defineComponent as o,ref as t,computed as n,onBeforeUnmount as l,openBlock as i,createElementBlock as a,withDirectives as s,toDisplayString as r,unref as d,vShow as c,createVNode as u,withCtx as m,Fragment as p,renderList as v,createCommentVNode as g,createTextVNode as w,nextTick as f}from"vue";import{NButton as h,NIcon as y}from"naive-ui";import k from"./ChatAdd.vue.js";import{Close as I,Mic as b,MicOff as A,Videocam as C,VideocamOff as V,Call as M,PersonAdd as _}from"@vicons/ionicons5";import{getUserDetailApi as L}from"../api/index.js";import"@vueuse/core";import{$message as x}from"../utils/index.js";import{xorBy as R}from"lodash-es";import{CHAT_TYPE as E,SUBSCRIBE_MESSAGE_TYPE as T}from"../constants/index.js";import"../../../../shared/utils/index.js";import"date-fns";import"@vue/shared";import"@vueuse/shared";import"../../../../shared/hooks/selectHooks/useSearchContent.js";import"../../../../shared/hooks/useScrollLoading.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{useVideo as B}from"../hooks/useVideo.js";import j from"trtc-sdk-v5";var S,$,H,U,z,N;const D={class:"video-wrapper video-wrapper--multiple"},O={class:"video-header"},P={key:0,class:"video-main"},Y={class:"video-main__left"},q=["data-name"],G={class:"video-bottom"},F={class:"btn-group"},J={class:"btn"},K=e("span",{class:"text"},(null==(S=window.getLanguageByCode)?void 0:S.call(window,"10010.1.104"))||"静音",-1),Q={class:"btn"},W=e("span",{class:"text"},(null==($=window.getLanguageByCode)?void 0:$.call(window,"10010.1.105"))||"摄像头",-1),X=e("span",{class:"text"},(null==(H=window.getLanguageByCode)?void 0:H.call(window,"10010.1.106"))||"结束会诊",-1),Z={class:"btn"},ee=e("span",{class:"text"},(null==(U=window.getLanguageByCode)?void 0:U.call(window,"10010.1.107"))||"添加参会人",-1),oe={class:"video-main__right"},te=["id","data-name"],ne={class:"user"},le={class:"name"},ie={key:0,class:"tip"},ae={key:0,class:"calling-box"},se={key:1,class:"opt-btn"},re={class:"btn"},de=e("span",null,(null==(z=window.getLanguageByCode)?void 0:z.call(window,"10010.1.113"))||"拒接",-1),ce={class:"btn"},ue=e("span",null,(null==(N=window.getLanguageByCode)?void 0:N.call(window,"10010.1.114"))||"接听",-1);var me=o({__name:"MultipleVideo",setup(o){const S=t(),$=t([]),{state:H,sendMessage:U,trtc:z,voiceOpen:N,isAudio:me,isCall:pe,startTimer:ve,resetTimer:ge,toggleAudio:we,messageTypeText:fe,timing:he,toggleVideo:ye,videocamOpen:ke,installEventHandlers:Ie,uninstallEventHandlers:be}=B(),Ae=t(!1),Ce=n((()=>pe.value?H.userInfo.name:H.currentAVMsg.sendName)),Ve=n((()=>{if(!Ae.value)return"";const e=pe.value?`(${$.value.length+1}/${H.currentAVMsg.checkedIds.length+1})`:"";return`${Ce.value}发起的${fe.value}会诊${e} ${he.value}`}));function Me(e){console.log("checkedIds :>> ",e),H.currentAVMsg.checkedIds.push(...e),_e()}function _e(){var e;(null==(e=H.currentAVMsg.checkedIds)?void 0:e.length)&&H.currentAVMsg.checkedIds.forEach((e=>{U({chatType:E.SINGLE,content:{msg:H.currentAVMsg.chatMessageType+","+H.currentAVMsg.strRoomId,chatMessageType:T.AV_STATUS},receiver:e})})),Ae.value||Le()}async function Le(){const e=await j.isSupported();if(!e.result||!e.detail.isH264EncodeSupported||!e.detail.isH264DecodeSupported)return console.log("checkResult :>> ",e),void(H.showMultipleVideo=!1);try{if(await z.enterRoom({strRoomId:H.currentAVMsg.strRoomId,sdkAppId:parseInt(H.userInfo.sdkAppID),userId:H.userInfo.id,userSig:H.userInfo.userSig}),Ae.value=!0,ve(),Ie({handleError:Se,handleRemoteUserEnter:Te,handleRemoteAudioAvailable:Ee,handleRemoteUserExit:je,handleRemoteVideoAvailable:Re}),await z.startLocalAudio(),me.value)return;await z.startLocalVideo({view:S.value})}catch(e){console.log("error :>> ",e),x.error(e),H.showMultipleVideo=!1}}async function xe(){try{if(H.showMultipleVideo=!1,be({handleError:Se,handleRemoteUserEnter:Te,handleRemoteAudioAvailable:Ee,handleRemoteUserExit:je,handleRemoteVideoAvailable:Re}),await z.exitRoom(),await z.stopLocalAudio(),me.value)return;await z.stopLocalVideo()}catch(e){console.log("error :>> ",e)}}async function Re(e){const{userId:o,streamType:t}=e;try{t===j.TYPE.STREAM_TYPE_MAIN&&(await f(),await z.startRemoteVideo({userId:o,streamType:t,view:o}))}catch(e){console.log("error :>> ",e)}}async function Ee(e){var o;const{userId:t}=e;if(t&&!(null==(o=$.value.map((e=>e.id)))?void 0:o.includes(t))){const e=await Be(t);$.value.push({id:t,name:e})}}async function Te(e){const{userId:o}=e,t=await Be(o);$.value.push({id:o,name:t}),ve()}async function Be(e){const o=await L({userId:e});return(null==o?void 0:o.name)||""}function je(e){console.log("event :>> 退房",e);const{userId:o}=e;$.value=R($.value,[{id:o,name:""}],"id")}function Se(e){console.log("error :>> ",e),H.showMultipleVideo=!1}return l((()=>{xe()})),(o,t)=>{var n,l,f,L,x,R;return i(),a("div",D,[e("div",O,[s(e("span",{class:"title"},r(d(Ve)),513),[[c,Ae.value]]),u(d(h),{quaternary:"",circle:"",color:"#ffffffcc",onClick:xe},{icon:m((()=>[u(d(y),{component:d(I)},null,8,["component"])])),_:1})]),Ae.value?(i(),a("div",P,[e("div",Y,[e("div",{ref_key:"selfVideoRef",ref:S,class:"video-view","data-name":d(H).userInfo.name},null,8,q),e("div",G,[e("div",F,[e("div",J,[u(d(h),{text:"",color:d(N)?"#fff":"#000",onClick:d(we)},{icon:m((()=>[u(d(y),{component:d(N)?d(b):d(A)},null,8,["component"])])),_:1},8,["color","onClick"]),K]),e("div",Q,[u(d(h),{text:"",color:d(ke)?"#fff":"#000",disabled:d(me),onClick:d(ye)},{icon:m((()=>[u(d(y),{component:d(ke)?d(C):d(V)},null,8,["component"])])),_:1},8,["color","disabled","onClick"]),W]),e("div",{class:"btn",onClick:xe},[u(d(h),{circle:"",color:"#f17568",class:"btn--rotate"},{icon:m((()=>[u(d(y),{component:d(M)},null,8,["component"])])),_:1}),X]),u(k,{onComfirm:Me},{trigger:m((()=>[e("div",Z,[u(d(h),{text:"",color:"#fff"},{icon:m((()=>[u(d(y),{component:d(_)},null,8,["component"])])),_:1}),ee])])),_:1})])])]),e("div",oe,[(i(!0),a(p,null,v($.value,(e=>(i(),a("div",{key:e.id,id:e.id,class:"video-view","data-name":e.name},null,8,te)))),128))])])):(i(),a(p,{key:1},[e("div",ne,[e("span",le,r(d(Ce))+((null==(n=window.getLanguageByCode)?void 0:n.call(window,"10010.1.108"))||"发起的")+r(d(fe))+((null==(l=window.getLanguageByCode)?void 0:l.call(window,"10010.1.109"))||"会议"),1),d(pe)?g("v-if",!0):(i(),a("span",ie,((null==(f=window.getLanguageByCode)?void 0:f.call(window,"10010.1.110"))||"邀请你加入")+r(d(fe))+((null==(L=window.getLanguageByCode)?void 0:L.call(window,"10010.1.109"))||"会议"),1))]),d(pe)?(i(),a("div",ae,[u(k,{onComfirm:Me,disabledIds:d(H).currentAVMsg.checkedIds},{trigger:m((()=>[u(d(h),{size:"large",circle:"",color:"#000"},{icon:m((()=>[u(d(y),{component:d(_)},null,8,["component"])])),_:1})])),_:1},8,["disabledIds"]),e("p",null,((null==(x=window.getLanguageByCode)?void 0:x.call(window,"10010.1.111"))||"已邀请共")+r(d(H).currentAVMsg.checkedIds.length)+((null==(R=window.getLanguageByCode)?void 0:R.call(window,"10010.1.40"))||"人"),1),u(d(h),{size:"large",strong:"",round:"",type:"primary",onClick:_e},{default:m((()=>{var e;return[w((null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.112"))||"开始会诊")]})),_:1}),g(' <div class="btn-box">\r\n\t\t\t\t\t\t<n-button color="#000" round>\r\n\t\t\t\t\t\t\t<template #icon>\r\n\t\t\t\t\t\t\t\t<n-icon :component="Mic" />\r\n\t\t\t\t\t\t\t</template>\r\n\t\t\t\t\t\t</n-button>\r\n\t\t\t\t\t\t<n-button color="#000" round>\r\n\t\t\t\t\t\t\t<template #icon>\r\n\t\t\t\t\t\t\t\t<n-icon :component="Videocam" />\r\n\t\t\t\t\t\t\t</template>\r\n\t\t\t\t\t\t</n-button>\r\n\t\t\t\t\t</div> ')])):(i(),a("div",se,[e("div",re,[u(d(h),{circle:"",color:"#f17568",class:"btn--rotate",onClick:t[0]||(t[0]=()=>d(H).showMultipleVideo=!1)},{icon:m((()=>[u(d(y),{size:"30",component:d(M)},null,8,["component"])])),_:1}),de]),e("div",ce,[u(d(h),{circle:"",color:"#2ac98b",onClick:Le},{icon:m((()=>[u(d(y),{size:"30",component:d(M)},null,8,["component"])])),_:1}),ue])]))],64))])}}});export{me as default};
1
+ import{createElementVNode as e,defineComponent as o,ref as n,computed as l,onBeforeUnmount as i,openBlock as a,createElementBlock as t,withDirectives as s,toDisplayString as d,unref as c,vShow as r,createVNode as u,withCtx as m,Fragment as v,renderList as p,createCommentVNode as g,createTextVNode as w,nextTick as f}from"vue";import{NButton as h,NIcon as y}from"naive-ui";import k from"./ChatAdd.vue.js";import{Close as I,Mic as C,MicOff as A,Videocam as b,VideocamOff as V,Call as _,PersonAdd as M}from"@vicons/ionicons5";import{getUserDetailApi as x}from"../api/index.js";import"@vueuse/core";import{$message as L}from"../utils/index.js";import{xorBy as R}from"lodash-es";import{CHAT_TYPE as E,SUBSCRIBE_MESSAGE_TYPE as T}from"../constants/index.js";import"../../../../shared/utils/index.js";import"date-fns";import"@vue/shared";import"@vueuse/shared";import"../../../../shared/hooks/selectHooks/useSearchContent.js";import"../../../../shared/hooks/useScrollLoading.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{useVideo as B}from"../hooks/useVideo.js";import j from"trtc-sdk-v5";var S,$,H,U,z,N;const P={class:"video-wrapper video-wrapper--multiple"},D={class:"video-header"},Y={key:0,class:"video-main"},q={class:"video-main__left"},G=["data-name"],O={class:"video-bottom"},F={class:"btn-group"},J={class:"btn"},K=e("span",{class:"text"},(null==(S=window.getLanguageByCode)?void 0:S.call(window,"10010.1.104"))||"静音",-1),Q={class:"btn"},W=e("span",{class:"text"},(null==($=window.getLanguageByCode)?void 0:$.call(window,"10010.1.105"))||"摄像头",-1),X=e("span",{class:"text"},(null==(H=window.getLanguageByCode)?void 0:H.call(window,"10010.1.106"))||"结束会诊",-1),Z={class:"btn"},ee=e("span",{class:"text"},(null==(U=window.getLanguageByCode)?void 0:U.call(window,"10010.1.107"))||"添加参会人",-1),oe={class:"video-main__right"},ne=["id","data-name"],le={class:"user"},ie={class:"name"},ae={key:0,class:"tip"},te={key:0,class:"calling-box"},se={class:"btn-box"},de={key:1,class:"opt-btn"},ce={class:"btn"},re=e("span",null,(null==(z=window.getLanguageByCode)?void 0:z.call(window,"10010.1.113"))||"拒接",-1),ue={class:"btn"},me=e("span",null,(null==(N=window.getLanguageByCode)?void 0:N.call(window,"10010.1.114"))||"接听",-1);var ve=o({__name:"MultipleVideo",setup(o){const S=n(),$=n([]),{state:H,sendMessage:U,trtc:z,trtcProxy:N,voiceClose:ve,isAudio:pe,isCall:ge,startTimer:we,resetTimer:fe,toggleAudio:he,messageTypeText:ye,timing:ke,toggleVideo:Ie,videocamClose:Ce,installEventHandlers:Ae,uninstallEventHandlers:be}=B(),Ve=n(!1),_e=l((()=>ge.value?H.userInfo.name:H.currentAVMsg.sendName)),Me=l((()=>{if(!Ve.value)return"";const e=ge.value?`(${$.value.length+1}/${H.currentAVMsg.checkedIds.length+1})`:"";return`${_e.value}发起的${ye.value}会诊${e} ${ke.value}`}));function xe({checkedIds:e,checkedOptions:o}){console.log("checkedIds :>> ",e,o),H.currentAVMsg.checkedIds.push(...e),Le()}function Le(){var e;(null==(e=H.currentAVMsg.checkedIds)?void 0:e.length)&&H.currentAVMsg.checkedIds.forEach((e=>{U({chatType:E.SINGLE,content:{msg:H.currentAVMsg.chatMessageType+","+H.currentAVMsg.strRoomId,chatMessageType:T.AV_STATUS},receiver:e})})),Ve.value||Re()}async function Re(){const e=await j.isSupported();if(!e.result||!e.detail.isH264EncodeSupported||!e.detail.isH264DecodeSupported)return console.log("checkResult :>> ",e),void(H.showMultipleVideo=!1);try{if(await z.enterRoom({strRoomId:H.currentAVMsg.strRoomId,sdkAppId:parseInt(H.userInfo.sdkAppID),userId:H.userInfo.id,userSig:H.userInfo.userSig,proxy:N.value}),Ve.value=!0,we(),Ae({handleError:He,handleRemoteUserEnter:je,handleRemoteAudioAvailable:Be,handleRemoteUserExit:$e,handleRemoteVideoAvailable:Te}),await z.startLocalAudio({mute:ve.value}),pe.value)return;await z.startLocalVideo({view:S.value,mute:Ce.value})}catch(e){console.log("error :>> ",e),L.error(e),H.showMultipleVideo=!1}}async function Ee(){try{if(H.showMultipleVideo=!1,be({handleError:He,handleRemoteUserEnter:je,handleRemoteAudioAvailable:Be,handleRemoteUserExit:$e,handleRemoteVideoAvailable:Te}),await z.exitRoom(),await z.stopLocalAudio(),pe.value)return;await z.stopLocalVideo()}catch(e){console.log("error :>> ",e)}}async function Te(e){const{userId:o,streamType:n}=e;try{n===j.TYPE.STREAM_TYPE_MAIN&&(await f(),await z.startRemoteVideo({userId:o,streamType:n,view:o}))}catch(e){console.log("error :>> ",e)}}async function Be(e){var o;const{userId:n}=e;if(n&&!(null==(o=$.value.map((e=>e.id)))?void 0:o.includes(n))){const e=await Se(n);$.value.push({id:n,name:e})}}async function je(e){const{userId:o}=e,n=await Se(o);$.value.push({id:o,name:n}),we()}async function Se(e){const o=await x({userId:e});return(null==o?void 0:o.name)||""}function $e(e){console.log("event :>> 退房",e);const{userId:o}=e;$.value=R($.value,[{id:o,name:""}],"id")}function He(e){console.log("error :>> ",e),H.showMultipleVideo=!1}return i((()=>{Ee()})),(o,n)=>{var l,i,f,x,L,R;return a(),t("div",P,[e("div",D,[s(e("span",{class:"title"},d(c(Me)),513),[[r,Ve.value]]),u(c(h),{quaternary:"",circle:"",color:"#ffffffcc",onClick:Ee},{icon:m((()=>[u(c(y),{component:c(I)},null,8,["component"])])),_:1})]),Ve.value?(a(),t("div",Y,[e("div",q,[e("div",{ref_key:"selfVideoRef",ref:S,class:"video-view","data-name":c(H).userInfo.name},null,8,G),e("div",O,[e("div",F,[e("div",J,[u(c(h),{text:"",color:c(ve)?"#000":"#fff",onClick:c(he)},{icon:m((()=>[u(c(y),{component:c(ve)?c(A):c(C)},null,8,["component"])])),_:1},8,["color","onClick"]),K]),e("div",Q,[u(c(h),{text:"",color:c(Ce)?"#000":"#fff",disabled:c(pe),onClick:c(Ie)},{icon:m((()=>[u(c(y),{component:c(Ce)?c(V):c(b)},null,8,["component"])])),_:1},8,["color","disabled","onClick"]),W]),e("div",{class:"btn",onClick:Ee},[u(c(h),{circle:"",color:"#f17568",class:"btn--rotate"},{icon:m((()=>[u(c(y),{component:c(_)},null,8,["component"])])),_:1}),X]),u(k,{onComfirm:xe,disabledIds:c(H).currentAVMsg.checkedIds},{trigger:m((()=>[e("div",Z,[u(c(h),{text:"",color:"#fff"},{icon:m((()=>[u(c(y),{component:c(M)},null,8,["component"])])),_:1}),ee])])),_:1},8,["disabledIds"])])])]),e("div",oe,[(a(!0),t(v,null,p($.value,(e=>(a(),t("div",{key:e.id,id:e.id,class:"video-view","data-name":e.name},null,8,ne)))),128))])])):(a(),t(v,{key:1},[e("div",le,[e("span",ie,d(c(_e))+((null==(l=window.getLanguageByCode)?void 0:l.call(window,"10010.1.108"))||"发起的")+d(c(ye))+((null==(i=window.getLanguageByCode)?void 0:i.call(window,"10010.1.109"))||"会议"),1),c(ge)?g("v-if",!0):(a(),t("span",ae,((null==(f=window.getLanguageByCode)?void 0:f.call(window,"10010.1.110"))||"邀请你加入")+d(c(ye))+((null==(x=window.getLanguageByCode)?void 0:x.call(window,"10010.1.109"))||"会议"),1))]),c(ge)?(a(),t("div",te,[u(k,{onComfirm:xe,disabledIds:c(H).currentAVMsg.checkedIds},{trigger:m((()=>[u(c(h),{size:"large",circle:"",color:"#000"},{icon:m((()=>[u(c(y),{component:c(M)},null,8,["component"])])),_:1})])),_:1},8,["disabledIds"]),e("p",null,((null==(L=window.getLanguageByCode)?void 0:L.call(window,"10010.1.111"))||"已邀请共")+d(c(H).currentAVMsg.checkedIds.length)+((null==(R=window.getLanguageByCode)?void 0:R.call(window,"10010.1.40"))||"人"),1),u(c(h),{size:"large",strong:"",round:"",type:"primary",onClick:Le},{default:m((()=>{var e;return[w((null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.112"))||"开始会诊")]})),_:1}),e("div",se,[u(c(h),{color:"#000",round:"",onClick:n[0]||(n[0]=e=>ve.value=!c(ve))},{icon:m((()=>[u(c(y),{component:c(ve)?c(A):c(C)},null,8,["component"])])),_:1}),u(c(h),{color:"#000",round:"",onClick:n[1]||(n[1]=e=>Ce.value=!c(Ce)),disabled:c(pe)},{icon:m((()=>[u(c(y),{component:c(Ce)?c(V):c(b)},null,8,["component"])])),_:1},8,["disabled"])])])):(a(),t("div",de,[e("div",ce,[u(c(h),{circle:"",color:"#f17568",class:"btn--rotate",onClick:n[2]||(n[2]=()=>c(H).showMultipleVideo=!1)},{icon:m((()=>[u(c(y),{size:"30",component:c(_)},null,8,["component"])])),_:1}),re]),e("div",ue,[u(c(h),{circle:"",color:"#2ac98b",onClick:Re},{icon:m((()=>[u(c(y),{size:"30",component:c(_)},null,8,["component"])])),_:1}),me])]))],64))])}}});export{ve as default};
@@ -1,30 +1,34 @@
1
+ import { PropType } from 'vue';
1
2
  import { UploadFileInfo } from 'naive-ui';
2
3
  import { AnyObject } from '../../../../shared/types';
3
4
  declare const _default: import("vue").DefineComponent<{
4
5
  userId: {
5
- type: StringConstructor;
6
- required: true;
6
+ type: (NumberConstructor | StringConstructor)[];
7
7
  };
8
8
  disabled: {
9
9
  type: BooleanConstructor;
10
10
  default: boolean;
11
11
  };
12
+ userInfo: {
13
+ type: PropType<AnyObject>;
14
+ };
12
15
  }, {
13
16
  props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
14
17
  userId: {
15
- type: StringConstructor;
16
- required: true;
18
+ type: (NumberConstructor | StringConstructor)[];
17
19
  };
18
20
  disabled: {
19
21
  type: BooleanConstructor;
20
22
  default: boolean;
21
23
  };
24
+ userInfo: {
25
+ type: PropType<AnyObject>;
26
+ };
22
27
  }>> & {
23
28
  onClose?: ((...args: any[]) => any) | undefined;
24
29
  }>>;
25
30
  emit: (event: "close", ...args: any[]) => void;
26
31
  state: {
27
- filterable: boolean;
28
32
  orgId: string | number;
29
33
  currentSessionItem: AnyObject;
30
34
  id: string;
@@ -74,13 +78,15 @@ declare const _default: import("vue").DefineComponent<{
74
78
  EyeOffOutline: 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<{}>>, {}>;
75
79
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "close"[], "close", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
76
80
  userId: {
77
- type: StringConstructor;
78
- required: true;
81
+ type: (NumberConstructor | StringConstructor)[];
79
82
  };
80
83
  disabled: {
81
84
  type: BooleanConstructor;
82
85
  default: boolean;
83
86
  };
87
+ userInfo: {
88
+ type: PropType<AnyObject>;
89
+ };
84
90
  }>> & {
85
91
  onClose?: ((...args: any[]) => any) | undefined;
86
92
  }, {
@@ -1 +1 @@
1
- import{defineComponent as t,ref as e,reactive as l,computed as n,openBlock as o,createBlock as a,unref as i,withCtx as r,renderSlot as s,createElementBlock as d,Fragment as c,withDirectives as u,createElementVNode as p,createVNode as v,createCommentVNode as g,toDisplayString as m,createTextVNode as w,renderList as y,vShow as f}from"vue";import{NPopover as k,NAvatar as h,NButton as b,NIcon as C}from"naive-ui";import{ChatbubbleEllipses as j,EyeOffOutline as L,EyeOutline as B,Close as I}from"@vicons/ionicons5";import{useData as _}from"../hooks/useData.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{CHAT_TYPE as x}from"../constants/index.js";import{openSessionApi as z,getUserDetailApi as N}from"../api/index.js";import"../utils/index.js";import"lodash-es";import"trtc-sdk-v5";const D={class:"person-profile-main"},S={class:"left"},$={class:"profile"},E={class:"profile__text"},P={class:"right"},q={class:"right__content"},G={class:"label"},O={class:"content"};var T=t({__name:"PersonProfile",props:{userId:{type:String,required:!0},disabled:{type:Boolean,default:!1}},emits:["close"],setup(t,{emit:T}){var U,A,F,H,J,K,M,Q;const R=t,{state:V,openSession:W}=_(),X=e(!1),Y=e(!1),Z=e(!1),tt=l({}),et=[{label:(null==(U=window.getLanguageByCode)?void 0:U.call(window,"10010.1.115"))||"机构",value:"",key:"orgName"},{label:(null==(A=window.getLanguageByCode)?void 0:A.call(window,"10010.1.116"))||"姓名",value:"",key:"name"},{label:(null==(F=window.getLanguageByCode)?void 0:F.call(window,"10010.1.117"))||"归属科室",value:"",key:"deptName"},{label:(null==(H=window.getLanguageByCode)?void 0:H.call(window,"10010.1.118"))||"业务科室",value:"",key:"businessDeptNames"},{label:(null==(J=window.getLanguageByCode)?void 0:J.call(window,"10010.1.119"))||"手机号",value:"",key:"phone"},{label:(null==(K=window.getLanguageByCode)?void 0:K.call(window,"10010.1.120"))||"岗位",value:"",key:"post"},{label:(null==(M=window.getLanguageByCode)?void 0:M.call(window,"10010.1.121"))||"工号",value:"",key:"jobId"},{label:(null==(Q=window.getLanguageByCode)?void 0:Q.call(window,"10010.1.122"))||"性别",value:"",key:"orgName"}],lt=n((()=>(tt.id&&et.forEach((t=>{const{key:e}=t;t.value=tt[e]})),et)));async function nt(){X.value=!1;let t=V.sessionList.find((t=>t.receiver===R.userId));if(!t)try{t=await z({chatType:x.SINGLE,receiver:R.userId,sender:V.userInfo.id})}catch(t){console.log("error :>> ",t)}t&&W(t),T("close")}async function ot(t){if(!t)return;const e=await N({userId:R.userId});(null==e?void 0:e.id)?Object.assign(tt,e):tt.id=""}function at(t){const{key:e,value:l}=t;return"phone"!==e||Z.value?l:(l||"").replace(/(\d{3})\d{4}(\d{4})/,"$1****$2")}return(e,l)=>(o(),a(i(k),{raw:"",class:"person-profile-wrapper",show:X.value,"onUpdate:show":[l[3]||(l[3]=t=>X.value=t),ot],trigger:t.disabled?"manual":"click","show-arrow":!1,to:"body",shift:""},{trigger:r((()=>[s(e.$slots,"trigger")])),default:r((()=>[tt.id?(o(),d(c,{key:0},[u(p("div",D,[p("div",S,[p("div",$,[v(i(h),{src:tt.avatar,bordered:"",round:"",size:100,onClickCapture:l[0]||(l[0]=t=>Y.value=!0)},null,8,["src"]),g(' <n-upload abstract accept="image/*" @change="onChange">\r\n\t\t\t\t\t\t\t<n-upload-trigger #="{ handleClick }" abstract>\r\n\t\t\t\t\t\t\t\t<n-button\r\n\t\t\t\t\t\t\t\t\tcircle\r\n\t\t\t\t\t\t\t\t\tsecondary\r\n\t\t\t\t\t\t\t\t\tclass="edit-avatar"\r\n\t\t\t\t\t\t\t\t\tv-show="userDetail.id === state.userInfo.id"\r\n\t\t\t\t\t\t\t\t\t@click="handleClick"\r\n\t\t\t\t\t\t\t\t>\r\n\t\t\t\t\t\t\t\t\t<template #icon>\r\n\t\t\t\t\t\t\t\t\t\t<n-icon size="16" color="#666666" :component="Camera" />\r\n\t\t\t\t\t\t\t\t\t</template>\r\n\t\t\t\t\t\t\t\t</n-button>\r\n\t\t\t\t\t\t\t</n-upload-trigger>\r\n\t\t\t\t\t\t</n-upload> '),p("div",E,[p("h4",null,m(tt.name),1),p("p",null,m(tt.orgName),1)]),v(i(b),{strong:"",secondary:"",onClick:nt},{default:r((()=>[v(i(C),{size:"13",color:"#666666",component:i(j),style:{"margin-right":"6px"}},null,8,["component"]),w(" 发消息 ")])),_:1})])]),p("div",P,[p("div",q,[(o(!0),d(c,null,y(i(lt),((t,e)=>(o(),d("div",{class:"info-item",key:e},[p("span",G,m(t.label),1),p("div",O,[p("span",null,m(at(t)),1),"phone"===t.key&&at(t)?(o(),a(i(C),{key:0,size:"16",color:"#666666",component:Z.value?i(L):i(B),style:{"margin-left":"10px"},onClick:l[1]||(l[1]=t=>Z.value=!Z.value)},null,8,["component"])):g("v-if",!0)])])))),128))])])],512),[[f,!Y.value]]),u(p("div",{class:"large-avatar",onClick:l[2]||(l[2]=t=>Y.value=!1)},[v(i(b),{circle:"",size:"small",secondary:""},{icon:r((()=>[v(i(C),{size:24,component:i(I),color:"#fff"},null,8,["component"])])),_:1}),v(i(h),{size:310,round:"",src:tt.avatar},null,8,["src"])],512),[[f,Y.value]])],64)):g("v-if",!0)])),_:3},8,["show","trigger"]))}});export{T as default};
1
+ import{defineComponent as t,ref as e,reactive as n,computed as l,openBlock as o,createBlock as a,unref as i,withCtx as s,renderSlot as r,createElementBlock as d,Fragment as u,withDirectives as c,createElementVNode as p,createVNode as v,createCommentVNode as g,toDisplayString as m,createTextVNode as w,renderList as f,vShow as y}from"vue";import{NPopover as k,NAvatar as b,NButton as h,NIcon as C}from"naive-ui";import{ChatbubbleEllipses as I,EyeOffOutline as j,EyeOutline as L,Close as B}from"@vicons/ionicons5";import{useData as _}from"../hooks/useData.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{CHAT_TYPE as x}from"../constants/index.js";import{openSessionApi as z,getUserDetailApi as N}from"../api/index.js";import"../utils/index.js";import"lodash-es";import"trtc-sdk-v5";const D={class:"person-profile-main"},S={class:"left"},$={class:"profile"},E={class:"profile__text"},O={class:"right"},P={class:"right__content"},G={class:"label"},T={class:"content"};var U=t({__name:"PersonProfile",props:{userId:{type:[String,Number]},disabled:{type:Boolean,default:!1},userInfo:{type:Object}},emits:["close"],setup(t,{emit:U}){var q,A,F,H,J,K,M,Q;const R=t,{state:V,openSession:W}=_(),X=e(!1),Y=e(!1),Z=e(!1),tt=n({}),et=[{label:(null==(q=window.getLanguageByCode)?void 0:q.call(window,"10010.1.115"))||"机构",value:"",key:"orgName"},{label:(null==(A=window.getLanguageByCode)?void 0:A.call(window,"10010.1.116"))||"姓名",value:"",key:"name"},{label:(null==(F=window.getLanguageByCode)?void 0:F.call(window,"10010.1.117"))||"归属科室",value:"",key:"deptName"},{label:(null==(H=window.getLanguageByCode)?void 0:H.call(window,"10010.1.118"))||"业务科室",value:"",key:"businessDeptNames"},{label:(null==(J=window.getLanguageByCode)?void 0:J.call(window,"10010.1.119"))||"手机号",value:"",key:"phone"},{label:(null==(K=window.getLanguageByCode)?void 0:K.call(window,"10010.1.120"))||"岗位",value:"",key:"post"},{label:(null==(M=window.getLanguageByCode)?void 0:M.call(window,"10010.1.121"))||"工号",value:"",key:"jobId"},{label:(null==(Q=window.getLanguageByCode)?void 0:Q.call(window,"10010.1.122"))||"性别",value:"",key:"orgName"}],nt=l((()=>(tt.id&&et.forEach((t=>{const{key:e}=t;t.value=tt[e]})),et)));async function lt(){var t;X.value=!1;let e=V.sessionList.find((t=>t.receiver===R.userId));if(!e)try{e=await z({chatType:x.SINGLE,receiver:R.userId||(null==(t=R.userInfo)?void 0:t.id),sender:V.userInfo.id})}catch(t){console.log("error :>> ",t)}e&&W(e),U("close")}async function ot(t){if(!t)return;if(!R.userId&&!R.userInfo)return;let e={};R.userId?e=await N({userId:R.userId}):R.userInfo&&(e=R.userInfo),(null==e?void 0:e.id)?Object.assign(tt,e):tt.id=""}function at(t){const{key:e,value:n}=t;return"phone"!==e||Z.value?n:(n||"").replace(/(\d{3})\d{4}(\d{4})/,"$1****$2")}return(e,n)=>(o(),a(i(k),{raw:"",class:"person-profile-wrapper",show:X.value,"onUpdate:show":[n[3]||(n[3]=t=>X.value=t),ot],trigger:t.disabled?"manual":"click","show-arrow":!1,to:"body",shift:""},{trigger:s((()=>[r(e.$slots,"trigger")])),default:s((()=>[tt.id?(o(),d(u,{key:0},[c(p("div",D,[p("div",S,[p("div",$,[v(i(b),{src:tt.avatar,bordered:"",round:"",size:100,onClickCapture:n[0]||(n[0]=t=>Y.value=!0)},null,8,["src"]),g(' <n-upload abstract accept="image/*" @change="onChange">\n\t\t\t\t\t\t\t<n-upload-trigger #="{ handleClick }" abstract>\n\t\t\t\t\t\t\t\t<n-button\n\t\t\t\t\t\t\t\t\tcircle\n\t\t\t\t\t\t\t\t\tsecondary\n\t\t\t\t\t\t\t\t\tclass="edit-avatar"\n\t\t\t\t\t\t\t\t\tv-show="userDetail.id === state.userInfo.id"\n\t\t\t\t\t\t\t\t\t@click="handleClick"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<template #icon>\n\t\t\t\t\t\t\t\t\t\t<n-icon size="16" color="#666666" :component="Camera" />\n\t\t\t\t\t\t\t\t\t</template>\n\t\t\t\t\t\t\t\t</n-button>\n\t\t\t\t\t\t\t</n-upload-trigger>\n\t\t\t\t\t\t</n-upload> '),p("div",E,[p("h4",null,m(tt.name),1),p("p",null,m(tt.orgName),1)]),v(i(h),{strong:"",secondary:"",onClick:lt},{default:s((()=>[v(i(C),{size:"13",color:"#666666",component:i(I),style:{"margin-right":"6px"}},null,8,["component"]),w(" 发消息 ")])),_:1})])]),p("div",O,[p("div",P,[(o(!0),d(u,null,f(i(nt),((t,e)=>(o(),d("div",{class:"info-item",key:e},[p("span",G,m(t.label),1),p("div",T,[p("span",null,m(at(t)),1),"phone"===t.key&&at(t)?(o(),a(i(C),{key:0,size:"16",color:"#666666",component:Z.value?i(j):i(L),style:{"margin-left":"10px"},onClick:n[1]||(n[1]=t=>Z.value=!Z.value)},null,8,["component"])):g("v-if",!0)])])))),128))])])],512),[[y,!Y.value]]),c(p("div",{class:"large-avatar",onClick:n[2]||(n[2]=t=>Y.value=!1)},[v(i(h),{circle:"",size:"small",secondary:""},{icon:s((()=>[v(i(C),{size:24,component:i(B),color:"#fff"},null,8,["component"])])),_:1}),v(i(b),{size:310,round:"",src:tt.avatar},null,8,["src"])],512),[[y,Y.value]])],64)):g("v-if",!0)])),_:3},8,["show","trigger"]))}});export{U as default};
@@ -28,7 +28,6 @@ declare const _default: import("vue").DefineComponent<{}, {
28
28
  filterList: import("vue").Ref<AnyObject[]>;
29
29
  handleInput: () => void;
30
30
  state: {
31
- filterable: boolean;
32
31
  orgId: string | number;
33
32
  currentSessionItem: AnyObject;
34
33
  id: string;
@@ -48,6 +47,7 @@ declare const _default: import("vue").DefineComponent<{}, {
48
47
  showMultipleVideo: boolean;
49
48
  };
50
49
  unreadTotal: import("vue").ComputedRef<number>;
50
+ filterable: import("vue").Ref<any>;
51
51
  openSession: (session: string | AnyObject) => Promise<void>;
52
52
  setUpdateSessionItem: (item: AnyObject) => void;
53
53
  setCurrentSessionItem: (item: AnyObject) => void;
@@ -140,6 +140,9 @@ declare const _default: import("vue").DefineComponent<{}, {
140
140
  type: StringConstructor;
141
141
  default: string;
142
142
  };
143
+ isDateDisabled: {
144
+ type: import("vue").PropType<(current: number, ...arg: any[]) => boolean>;
145
+ };
143
146
  }, {
144
147
  attrs: {
145
148
  [x: string]: unknown;
@@ -172,6 +175,9 @@ declare const _default: import("vue").DefineComponent<{}, {
172
175
  type: StringConstructor;
173
176
  default: string;
174
177
  };
178
+ isDateDisabled: {
179
+ type: import("vue").PropType<(current: number, ...arg: any[]) => boolean>;
180
+ };
175
181
  }>> & {
176
182
  "onUpdate:formatted-value"?: ((...args: any[]) => any) | undefined;
177
183
  }>>;
@@ -184,6 +190,7 @@ declare const _default: import("vue").DefineComponent<{}, {
184
190
  isDateTime: import("vue").ComputedRef<boolean>;
185
191
  formatRef: import("vue").ComputedRef<string>;
186
192
  panelFormatRef: import("vue").ComputedRef<string | [string, string]>;
193
+ _isDateDisabled: import("vue").ComputedRef<(current: number, ...arg: any[]) => boolean>;
187
194
  focus: () => any;
188
195
  blur: () => any;
189
196
  handleConfirm: (target: HTMLInputElement) => void;
@@ -223,6 +230,9 @@ declare const _default: import("vue").DefineComponent<{}, {
223
230
  type: StringConstructor;
224
231
  default: string;
225
232
  };
233
+ isDateDisabled: {
234
+ type: import("vue").PropType<(current: number, ...arg: any[]) => boolean>;
235
+ };
226
236
  }>> & {
227
237
  "onUpdate:formatted-value"?: ((...args: any[]) => any) | undefined;
228
238
  }, {
@@ -1 +1 @@
1
- import{defineComponent as e,ref as t,computed as l,withDirectives as n,openBlock as i,createElementBlock as a,normalizeStyle as o,unref as s,createVNode as u,withCtx as r,createElementVNode as d,Fragment as v,renderList as c,createBlock as p,vShow as m,createCommentVNode as f,createTextVNode as g,toDisplayString as w,withModifiers as y,normalizeClass as k,nextTick as h}from"vue";import{NPopover as _,NInput as x,NIcon as C,NTag as M,NAvatar as R,NBadge as b}from"naive-ui";import j from"./ContextMenu.js";import{useData as D}from"../hooks/useData.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{STATUS as E}from"../constants/index.js";import{toppingSessionApi as L,updateStatusApi as B}from"../api/index.js";import{listSort as I,formatTime as T}from"../utils/index.js";import"lodash-es";import"trtc-sdk-v5";import{vFlexibleResize as N}from"../../../../shared/directive/flexibleResize.js";import S from"../../../date-picker/index.js";import{SearchOutline as V}from"@vicons/ionicons5";import $ from"./userItemRender.js";import O from"../../../default-page/index.js";import{useDebounceFn as U}from"@vueuse/core";import{isBefore as H,isAfter as z}from"date-fns";const K={key:0,class:"sider-list__filter"},P={class:"user-list-wrapper"},W={class:"sider-list__tags box-shadow"},A=["onClick","onContextmenu"],X={class:"avatar-right"},Y={class:"name"},q={class:"msg-tip"},F={class:"msg-tip__content"},G={key:0},J=["innerHTML"];var Q=e({__name:"SiderList",setup(e){var Q,Z,ee;const te="all",le="unread",ne="ended";let ie=[];const ae=t(300),oe=t(),se=t([{label:(null==(Q=window.getLanguageByCode)?void 0:Q.call(window,"10010.1.123"))||"全部",key:te},{label:(null==(Z=window.getLanguageByCode)?void 0:Z.call(window,"10010.1.124"))||"未读",key:le},{label:(null==(ee=window.getLanguageByCode)?void 0:ee.call(window,"10010.1.77"))||"结束",key:ne}]),ue=t(),re=t(!1),de=t({left:0,top:0}),ve=t(),ce=t("all"),pe=t(),me=t(),fe=t(),ge=t(""),we=t(!1),ye=t([]),ke=U(Te,500),{state:he,unreadTotal:_e,openSession:xe,setUpdateSessionItem:Ce,setCurrentSessionItem:Me}=D(),Re=l((()=>Math.min(Math.max(ae.value,240),360))),be=l((()=>I(he.sessionList)));function je({distance:e}){ae.value=ae.value+e}function De(e,t=s(ce)){var l;return t===te||(t===le?ie.includes(e.sessionKey)||(null!=(l=e.unreadNum)?l:0)>0:t===ne?e.status===E.ENDED:void 0)}async function Ee(e,t){try{if("topping"===e)return await L({id:t.id,topping:!(null==t?void 0:t.topping)}),void(he.id===t.id?Me({topping:!(null==t?void 0:t.topping)}):Ce({...t,topping:!(null==t?void 0:t.topping)}));"remove"===e&&(await B({id:t.id,status:E.REMOVED}),he.id===t.id?Me({status:E.REMOVED}):Ce({...t,status:E.REMOVED}))}catch(e){}}function Le(e){we.value=e,e||(ge.value="",fe.value=null,ye.value=[])}function Be(e){var t,l,n,i,a;const o=null==(n=null==(l=null==(t=pe.value)?void 0:t.$datePicker)?void 0:l.panelInstRef)?void 0:n.$el;Le(!(!e.target||!(o&&o.contains(e.target)||(null==(i=me.value)?void 0:i.$el)&&(null==(a=me.value)?void 0:a.$el.contains(e.target)))))}function Ie(e){fe.value=e,Te()}function Te(){ge.value||fe.value?ye.value=be.value.filter((e=>{const t=e.name.includes(ge.value);if(!fe.value)return t;const[l,n]=fe.value,i=new Date(e.createdTime);return t&&H(i,new Date(n+" 23:59:59"))&&z(i,new Date(l+" 00:00:00"))})):ye.value=[]}return(e,t)=>n((i(),a("section",{class:"sider-list",style:o({width:s(Re)+"px"})},[s(he).filterable?(i(),a("div",K,[u(s(_),{raw:"","content-class":"search-content__sider",class:"search-wrapper",show:we.value,placement:"bottom-start","display-directive":"show","show-arrow":!1,onClickoutside:Be},{trigger:r((()=>[u(s(x),{ref_key:"inputRef",ref:me,placeholder:"请输入名称模糊搜索",value:ge.value,"onUpdate:value":t[0]||(t[0]=e=>ge.value=e),onInput:s(ke),onClick:t[1]||(t[1]=()=>Le(!0))},{prefix:r((()=>[u(s(C),{component:s(V)},null,8,["component"])])),_:1},8,["value","onInput"])])),default:r((()=>{var e;return[u(s(S),{ref_key:"datePickerRef",ref:pe,"formatted-value":fe.value,type:"daterange",clearable:"","onUpdate:formattedValue":Ie},null,8,["formatted-value"]),d("div",P,[(i(!0),a(v,null,c(ye.value,(e=>(i(),p(s($),{key:e.id,item:e,onItemClick:t[2]||(t[2]=()=>Le(!1))},null,8,["item"])))),128)),n(u(s(O),{config:{title:" ",content:(null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.81"))||"找不到相关的结果"},type:"5"},null,512),[[m,ye.value.length<1]])])]})),_:1},8,["show"])])):f("v-if",!0),d("div",W,[(i(!0),a(v,null,c(se.value,(e=>(i(),p(s(M),{type:ce.value===e.key?"primary":"default",round:"",bordered:!1,key:e.key,onClick:()=>{return t=e.key,ce.value=t,void(t===le&&(ie=(be.value.filter((e=>{var t;return(null!=(t=e.unreadNum)?t:0)>0}))||[]).map((e=>e.sessionKey))));var t}},{default:r((()=>{return[g(w(e.label)+"("+w((t=e,t.key===ne?be.value.filter((e=>e.status===E.ENDED)).length:_e.value))+") ",1)];var t})),_:2},1032,["type","onClick"])))),128))]),d("div",{class:"sider-list__box",ref_key:"listBoxRef",ref:oe},[(i(!0),a(v,null,c(s(be),(e=>{var t;return i(),a(v,{key:e.id},[e.status!==s(E).REMOVED?n((i(),a("div",{key:0,onClick:()=>s(xe)(e),onContextmenu:y((t=>async function(e,t){var l,n,i,a,o;ve.value=t,re.value=!0,await h();const{clientX:s,clientY:u}=e,{width:r=0,height:d=0,left:v=0,top:c=0}=(null==(l=oe.value)?void 0:l.getBoundingClientRect())||{},{width:p=100,height:m=80}=(null==(i=null==(n=ue.value)?void 0:n.$el)?void 0:i.getBoundingClientRect())||{},f=null!=(o=null==(a=oe.value)?void 0:a.scrollTop)?o:0,g={};s<v+r-(p+2)-5?g.left=s-v+5+"px":g.right=v+r-s+5+"px",c+d-u<=m+5?g.bottom=5-f+"px":g.top=u-c+f+5+"px",de.value=g}(t,e.id)),["prevent"]),class:k(["sider-list__box__item",{active:e.id===s(he).id},e.topping?"sider-list__box__item--top":""])},[u(s(R),{round:"",size:"large",src:e.avatar},null,8,["src"]),d("div",X,[d("div",Y,[d("h4",null,w(e.name),1),d("span",null,w(e.lastMessage?s(T)(e.lastMessageSendTime).siderMsgTime:""),1)]),d("div",q,[d("div",F,["WITHDRAWN"===e.lastMessageStatus?(i(),a("div",G,(null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.68"))||"撤回了一条消息")):(i(),a("div",{key:1,innerHTML:e.lastMessageContent},null,8,J))]),u(s(b),{value:e.unreadNum>99?"99+":e.unreadNum},null,8,["value"])])])],42,A)),[[m,De(e)]]):f("v-if",!0)],64)})),128)),u(s(j),{ref_key:"contextmenuRef",ref:ue,show:re.value,"onUpdate:show":t[3]||(t[3]=e=>re.value=e),type:"session",position:de.value,id:ve.value,onSelect:Ee},null,8,["show","position","id"])],512)],4)),[[s(N),{mode:"VR",onMove:je}]])}});export{Q as default};
1
+ import{defineComponent as e,ref as t,computed as l,withDirectives as n,openBlock as i,createElementBlock as a,normalizeStyle as o,unref as s,createVNode as u,withCtx as r,createElementVNode as d,Fragment as v,renderList as c,createBlock as p,vShow as m,createCommentVNode as f,createTextVNode as g,toDisplayString as w,withModifiers as y,normalizeClass as k,nextTick as h}from"vue";import{NPopover as _,NInput as x,NIcon as C,NTag as M,NAvatar as R,NBadge as b}from"naive-ui";import j from"./ContextMenu.js";import{useData as D}from"../hooks/useData.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{STATUS as E}from"../constants/index.js";import{toppingSessionApi as L,updateStatusApi as B}from"../api/index.js";import{listSort as I,formatTime as T}from"../utils/index.js";import"lodash-es";import"trtc-sdk-v5";import{vFlexibleResize as N}from"../../../../shared/directive/flexibleResize.js";import S from"../../../date-picker/index.js";import{SearchOutline as V}from"@vicons/ionicons5";import $ from"./userItemRender.js";import O from"../../../default-page/index.js";import{useDebounceFn as U}from"@vueuse/core";import{isBefore as H,isAfter as z}from"date-fns";const K={key:0,class:"sider-list__filter"},P={class:"user-list-wrapper"},W={class:"sider-list__tags box-shadow"},A=["onClick","onContextmenu"],X={class:"avatar-right"},Y={class:"name"},q={class:"msg-tip"},F={class:"msg-tip__content"},G={key:0},J=["innerHTML"];var Q=e({__name:"SiderList",setup(e){var Q,Z,ee;const te="all",le="unread",ne="ended";let ie=[];const ae=t(300),oe=t(),se=t([{label:(null==(Q=window.getLanguageByCode)?void 0:Q.call(window,"10010.1.123"))||"全部",key:te},{label:(null==(Z=window.getLanguageByCode)?void 0:Z.call(window,"10010.1.124"))||"未读",key:le},{label:(null==(ee=window.getLanguageByCode)?void 0:ee.call(window,"10010.1.77"))||"结束",key:ne}]),ue=t(),re=t(!1),de=t({left:0,top:0}),ve=t(),ce=t("all"),pe=t(),me=t(),fe=t(),ge=t(""),we=t(!1),ye=t([]),ke=U(Ne,500),{state:he,unreadTotal:_e,filterable:xe,openSession:Ce,setUpdateSessionItem:Me,setCurrentSessionItem:Re}=D(),be=l((()=>Math.min(Math.max(ae.value,240),360))),je=l((()=>I(he.sessionList)));function De({distance:e}){ae.value=ae.value+e}function Ee(e,t=s(ce)){var l;return t===te||(t===le?ie.includes(e.sessionKey)||(null!=(l=e.unreadNum)?l:0)>0:t===ne?e.status===E.ENDED:void 0)}async function Le(e,t){try{if("topping"===e)return await L({id:t.id,topping:!(null==t?void 0:t.topping)}),void(he.id===t.id?Re({topping:!(null==t?void 0:t.topping)}):Me({...t,topping:!(null==t?void 0:t.topping)}));"remove"===e&&(await B({id:t.id,status:E.REMOVED}),he.id===t.id?Re({status:E.REMOVED}):Me({...t,status:E.REMOVED}))}catch(e){}}function Be(e){we.value=e,e||(ge.value="",fe.value=null,ye.value=[])}function Ie(e){var t,l,n,i,a;const o=null==(n=null==(l=null==(t=pe.value)?void 0:t.$datePicker)?void 0:l.panelInstRef)?void 0:n.$el;Be(!(!e.target||!(o&&o.contains(e.target)||(null==(i=me.value)?void 0:i.$el)&&(null==(a=me.value)?void 0:a.$el.contains(e.target)))))}function Te(e){fe.value=e,Ne()}function Ne(){ge.value||fe.value?ye.value=je.value.filter((e=>{const t=e.name.includes(ge.value);if(!fe.value)return t;const[l,n]=fe.value,i=new Date(e.createdTime);return t&&H(i,new Date(n+" 23:59:59"))&&z(i,new Date(l+" 00:00:00"))})):ye.value=[]}return(e,t)=>n((i(),a("section",{class:"sider-list",style:o({width:s(be)+"px"})},[s(xe)?(i(),a("div",K,[u(s(_),{raw:"","content-class":"search-content__sider",class:"search-wrapper",show:we.value,placement:"bottom-start","display-directive":"show","show-arrow":!1,onClickoutside:Ie},{trigger:r((()=>[u(s(x),{ref_key:"inputRef",ref:me,placeholder:"请输入名称模糊搜索",value:ge.value,"onUpdate:value":t[0]||(t[0]=e=>ge.value=e),onInput:s(ke),onClick:t[1]||(t[1]=()=>Be(!0))},{prefix:r((()=>[u(s(C),{component:s(V)},null,8,["component"])])),_:1},8,["value","onInput"])])),default:r((()=>{var e;return[u(s(S),{ref_key:"datePickerRef",ref:pe,"formatted-value":fe.value,type:"daterange",clearable:"","onUpdate:formattedValue":Te},null,8,["formatted-value"]),d("div",P,[(i(!0),a(v,null,c(ye.value,(e=>(i(),p(s($),{key:e.id,item:e,onItemClick:t[2]||(t[2]=()=>Be(!1))},null,8,["item"])))),128)),n(u(s(O),{config:{title:" ",content:(null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.81"))||"找不到相关的结果"},type:"5"},null,512),[[m,ye.value.length<1]])])]})),_:1},8,["show"])])):f("v-if",!0),d("div",W,[(i(!0),a(v,null,c(se.value,(e=>(i(),p(s(M),{type:ce.value===e.key?"primary":"default",round:"",bordered:!1,key:e.key,onClick:()=>{return t=e.key,ce.value=t,void(t===le&&(ie=(je.value.filter((e=>{var t;return(null!=(t=e.unreadNum)?t:0)>0}))||[]).map((e=>e.sessionKey))));var t}},{default:r((()=>{return[g(w(e.label)+"("+w((t=e,t.key===ne?je.value.filter((e=>e.status===E.ENDED)).length:_e.value))+") ",1)];var t})),_:2},1032,["type","onClick"])))),128))]),d("div",{class:"sider-list__box",ref_key:"listBoxRef",ref:oe},[(i(!0),a(v,null,c(s(je),(e=>{var t;return i(),a(v,{key:e.id},[e.status!==s(E).REMOVED?n((i(),a("div",{key:0,onClick:()=>s(Ce)(e),onContextmenu:y((t=>async function(e,t){var l,n,i,a,o;ve.value=t,re.value=!0,await h();const{clientX:s,clientY:u}=e,{width:r=0,height:d=0,left:v=0,top:c=0}=(null==(l=oe.value)?void 0:l.getBoundingClientRect())||{},{width:p=100,height:m=80}=(null==(i=null==(n=ue.value)?void 0:n.$el)?void 0:i.getBoundingClientRect())||{},f=null!=(o=null==(a=oe.value)?void 0:a.scrollTop)?o:0,g={};s<v+r-(p+2)-5?g.left=s-v+5+"px":g.right=v+r-s+5+"px",c+d-u<=m+5?g.bottom=5-f+"px":g.top=u-c+f+5+"px",de.value=g}(t,e.id)),["prevent"]),class:k(["sider-list__box__item",{active:e.id===s(he).id},e.topping?"sider-list__box__item--top":""])},[u(s(R),{round:"",size:"large",src:e.avatar},null,8,["src"]),d("div",X,[d("div",Y,[d("h4",null,w(e.name),1),d("span",null,w(e.lastMessage?s(T)(e.lastMessageSendTime).siderMsgTime:""),1)]),d("div",q,[d("div",F,["WITHDRAWN"===e.lastMessageStatus?(i(),a("div",G,(null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.68"))||"撤回了一条消息")):(i(),a("div",{key:1,innerHTML:e.lastMessageContent},null,8,J))]),u(s(b),{value:e.unreadNum>99?"99+":e.unreadNum},null,8,["value"])])])],42,A)),[[m,Ee(e)]]):f("v-if",!0)],64)})),128)),u(s(j),{ref_key:"contextmenuRef",ref:ue,show:re.value,"onUpdate:show":t[3]||(t[3]=e=>re.value=e),type:"session",position:de.value,id:ve.value,onSelect:Le},null,8,["show","position","id"])],512)],4)),[[s(N),{mode:"VR",onMove:De}]])}});export{Q as default};
@@ -7,7 +7,6 @@ declare const _default: import("vue").DefineComponent<{}, {
7
7
  receiver?: string | undefined;
8
8
  }) => Promise<void>;
9
9
  state: {
10
- filterable: boolean;
11
10
  orgId: string | number;
12
11
  currentSessionItem: import("../../../../shared/types").AnyObject;
13
12
  id: string;
@@ -26,9 +25,10 @@ declare const _default: import("vue").DefineComponent<{}, {
26
25
  currentGroupUser: import("../../../../shared/types").AnyObject[];
27
26
  showMultipleVideo: boolean;
28
27
  };
28
+ trtcProxy: import("vue").Ref<any>;
29
29
  trtc: TRTC;
30
30
  timing: import("vue").Ref<string>;
31
- voiceOpen: import("vue").Ref<boolean>;
31
+ voiceClose: import("vue").Ref<boolean>;
32
32
  isAudio: import("vue").ComputedRef<boolean>;
33
33
  isCall: import("vue").ComputedRef<boolean>;
34
34
  startTimer: () => void;
@@ -1 +1 @@
1
- import{createElementVNode as e,defineComponent as o,ref as n,computed as s,watch as t,onBeforeUnmount as r,openBlock as a,createElementBlock as l,withDirectives as i,vShow as c,createVNode as u,unref as d,toDisplayString as v,Fragment as m,normalizeClass as p,withCtx as g}from"vue";import{NAvatar as f,NButton as w,NIcon as h}from"naive-ui";import{Mic as I,MicOffCircle as y,Call as A}from"@vicons/ionicons5";import{avFinishApi as k}from"../api/index.js";import"@vueuse/core";import{$message as E}from"../utils/index.js";import"lodash-es";import{AV_STATUS as V,CHAT_TYPE as R}from"../constants/index.js";import"../../../../shared/utils/index.js";import"date-fns";import"@vue/shared";import"@vueuse/shared";import"../../../../shared/hooks/selectHooks/useSearchContent.js";import"../../../../shared/hooks/useScrollLoading.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{useVideo as S}from"../hooks/useVideo.js";import C from"trtc-sdk-v5";var M,b,L,T;const j={class:"video-wrapper"},x={class:"user"},_={class:"name"},N={class:"tip"},H={class:"opt-btn"},D={class:"btn"},z=e("span",null,(null==(M=window.getLanguageByCode)?void 0:M.call(window,"10010.1.104"))||"静音",-1),B=e("span",null,(null==(b=window.getLanguageByCode)?void 0:b.call(window,"10010.1.113"))||"拒接",-1),U={class:"btn"},F=e("span",null,(null==(L=window.getLanguageByCode)?void 0:L.call(window,"10010.1.125"))||"挂断",-1),O=e("span",null,(null==(T=window.getLanguageByCode)?void 0:T.call(window,"10010.1.114"))||"接听",-1);var G=o({__name:"Video",setup(o){const{sendMessage:M,state:b,trtc:L,timing:T,voiceOpen:G,isAudio:J,isCall:P,startTimer:$,resetTimer:q,toggleAudio:K,messageTypeText:Q,time:W,installEventHandlers:X,uninstallEventHandlers:Y}=S(),Z=n(),ee=n(),oe=n(!1);let ne=null;const se=s((()=>{var e,o,n;return P.value?{avatar:b.currentSessionItem.avatar,name:b.currentSessionItem.name,userId:b.currentSessionItem.receiver}:{avatar:null==(e=b.currentAVMsg.currentMsg)?void 0:e.senderAvatar,name:null==(o=b.currentAVMsg.currentMsg)?void 0:o.senderName,userId:null==(n=b.currentAVMsg.currentMsg)?void 0:n.sender}})),te=s((()=>oe.value?J.value?T.value:"":P.value?"正在呼叫...":`邀请你${Q.value}问诊...`)),re=s((()=>{var e,o;return null==(o=null==(e=b.currentAVMsg.currentMsg)?void 0:e.content)?void 0:o.avStatus}));async function ae(e=V.FINISHED){M({chatType:R.SINGLE,content:{msg:e===V.FINISHED?""+W.seconds:"s",chatMessageType:b.currentAVMsg.chatMessageType,avStatus:e},receiver:se.value.userId}),await k({recordId:b.currentAVMsg.currentMsg.id,status:e,duration:e===V.FINISHED?W.seconds:0})}async function le(){const e=await C.isSupported();if(!e.result||!e.detail.isH264EncodeSupported||!e.detail.isH264DecodeSupported)return console.log("checkResult :>> ",e),void(b.showVideo=!1);try{if(await L.enterRoom({strRoomId:b.currentAVMsg.strRoomId,sdkAppId:parseInt(b.userInfo.sdkAppID),userId:b.userInfo.id,userSig:b.userInfo.userSig}),P.value||(oe.value=!0,$()),X({handleError:pe,handleRemoteUserEnter:ve,handleRemoteAudioAvailable:de,handleRemoteUserExit:me,handleRemoteVideoAvailable:ue}),await L.startLocalAudio(),J.value)return;await L.startLocalVideo({view:ee.value})}catch(e){console.log("error :>> ",e),E.error(e),b.showVideo=!1}}function ie(){P.value&&!oe.value?ae(V.CANCELED):ae()}async function ce(){try{if(b.showVideo=!1,Y({handleError:pe,handleRemoteUserEnter:ve,handleRemoteAudioAvailable:de,handleRemoteUserExit:me,handleRemoteVideoAvailable:ue}),await L.exitRoom(),await L.stopLocalAudio(),J.value)return;await L.stopLocalVideo()}catch(e){console.log("error :>> ",e)}}async function ue(e){const{userId:o,streamType:n}=e;try{await L.startRemoteVideo({userId:o,streamType:n,view:Z.value})}catch(e){console.log("error :>> ",e)}}function de(e){}function ve(){oe.value=!0,$()}function me(e){console.log("event :>> 对方已挂断",e),ce()}function pe(e){console.log("error :>> ",e),b.showVideo=!1}return t((()=>re.value),(e=>{b.showVideo&&(e===V.IN_CALL?async function(){P.value?le():(ne&&clearTimeout(ne),ne=setTimeout((async()=>{oe.value||ae(V.NO_RESPONSE)}),6e4))}():ce())}),{immediate:!0}),r((()=>{ce()})),(o,n)=>(a(),l("div",j,[i(e("div",{class:"video-box",ref_key:"videoRef",ref:Z},null,512),[[c,oe.value]]),i(e("div",{class:"video-box--self",ref_key:"selfVideoRef",ref:ee},null,512),[[c,oe.value]]),i(e("div",x,[u(d(f),{size:58,round:"",src:d(se).avatar},null,8,["src"]),e("span",_,v(d(se).name),1),e("span",N,v(d(te)),1)],512),[[c,d(J)||!oe.value]]),e("div",H,[e("div",D,[d(P)&&!oe.value||oe.value?(a(),l(m,{key:0},[u(d(w),{circle:"",onClick:d(K),class:p({bordered:d(G)})},{icon:g((()=>[u(d(h),{size:"30",color:d(G)?"#fff":"#626262",component:d(G)?d(I):d(y)},null,8,["color","component"])])),_:1},8,["onClick","class"]),z],64)):(a(),l(m,{key:1},[u(d(w),{circle:"",color:"#f17568",class:"btn--rotate",onClick:n[0]||(n[0]=()=>ae(d(V).REJECTED))},{icon:g((()=>[u(d(h),{size:"30",component:d(A)},null,8,["component"])])),_:1}),B],64))]),e("div",U,[d(P)&&!oe.value||oe.value?(a(),l(m,{key:0},[u(d(w),{circle:"",color:"#f17568",class:"btn--rotate",onClick:ie},{icon:g((()=>[u(d(h),{size:"30",component:d(A)},null,8,["component"])])),_:1}),F],64)):(a(),l(m,{key:1},[u(d(w),{circle:"",color:"#2ac98b",onClick:le},{icon:g((()=>[u(d(h),{size:"30",component:d(A)},null,8,["component"])])),_:1}),O],64))])])]))}});export{G as default};
1
+ import{createElementVNode as e,defineComponent as o,ref as n,computed as s,watch as t,onBeforeUnmount as r,openBlock as a,createElementBlock as l,withDirectives as i,vShow as c,createVNode as u,unref as d,toDisplayString as v,Fragment as m,normalizeClass as p,withCtx as g}from"vue";import{NAvatar as f,NButton as w,NIcon as h}from"naive-ui";import{Mic as y,MicOffCircle as I,Call as A}from"@vicons/ionicons5";import{avFinishApi as k}from"../api/index.js";import"@vueuse/core";import{$message as E}from"../utils/index.js";import"lodash-es";import{AV_STATUS as V,CHAT_TYPE as R}from"../constants/index.js";import"../../../../shared/utils/index.js";import"date-fns";import"@vue/shared";import"@vueuse/shared";import"../../../../shared/hooks/selectHooks/useSearchContent.js";import"../../../../shared/hooks/useScrollLoading.js";import"stompjs";import"sockjs-client/dist/sockjs.min.js";import{useVideo as S}from"../hooks/useVideo.js";import C from"trtc-sdk-v5";var M,b,x,L;const T={class:"video-wrapper"},j={class:"user"},_={class:"name"},N={class:"tip"},H={class:"opt-btn"},D={class:"btn"},z=e("span",null,(null==(M=window.getLanguageByCode)?void 0:M.call(window,"10010.1.104"))||"静音",-1),B=e("span",null,(null==(b=window.getLanguageByCode)?void 0:b.call(window,"10010.1.113"))||"拒接",-1),U={class:"btn"},F=e("span",null,(null==(x=window.getLanguageByCode)?void 0:x.call(window,"10010.1.125"))||"挂断",-1),O=e("span",null,(null==(L=window.getLanguageByCode)?void 0:L.call(window,"10010.1.114"))||"接听",-1);var P=o({__name:"Video",setup(o){const{sendMessage:M,state:b,trtcProxy:x,trtc:L,timing:P,voiceClose:G,isAudio:J,isCall:$,startTimer:q,resetTimer:K,toggleAudio:Q,messageTypeText:W,time:X,installEventHandlers:Y,uninstallEventHandlers:Z}=S(),ee=n(),oe=n(),ne=n(!1);let se=null;const te=s((()=>{var e,o,n;return $.value?{avatar:b.currentSessionItem.avatar,name:b.currentSessionItem.name,userId:b.currentSessionItem.receiver}:{avatar:null==(e=b.currentAVMsg.currentMsg)?void 0:e.senderAvatar,name:null==(o=b.currentAVMsg.currentMsg)?void 0:o.senderName,userId:null==(n=b.currentAVMsg.currentMsg)?void 0:n.sender}})),re=s((()=>ne.value?J.value?P.value:"":$.value?"正在呼叫...":`邀请你${W.value}问诊...`)),ae=s((()=>{var e,o;return null==(o=null==(e=b.currentAVMsg.currentMsg)?void 0:e.content)?void 0:o.avStatus}));async function le(e=V.FINISHED){M({chatType:R.SINGLE,content:{msg:e===V.FINISHED?""+X.seconds:"s",chatMessageType:b.currentAVMsg.chatMessageType,avStatus:e},receiver:te.value.userId}),await k({recordId:b.currentAVMsg.currentMsg.id,status:e,duration:e===V.FINISHED?X.seconds:0})}async function ie(){const e=await C.isSupported();if(!e.result||!e.detail.isH264EncodeSupported||!e.detail.isH264DecodeSupported)return console.log("checkResult :>> ",e),void(b.showVideo=!1);try{if(await L.enterRoom({strRoomId:b.currentAVMsg.strRoomId,sdkAppId:parseInt(b.userInfo.sdkAppID),userId:b.userInfo.id,userSig:b.userInfo.userSig,proxy:x.value}),$.value||(ne.value=!0,q()),Y({handleError:ge,handleRemoteUserEnter:me,handleRemoteAudioAvailable:ve,handleRemoteUserExit:pe,handleRemoteVideoAvailable:de}),await L.startLocalAudio(),J.value)return;await L.startLocalVideo({view:oe.value})}catch(e){console.log("error :>> ",e),E.error(e),b.showVideo=!1}}function ce(){$.value&&!ne.value?le(V.CANCELED):le()}async function ue(){try{if(b.showVideo=!1,Z({handleError:ge,handleRemoteUserEnter:me,handleRemoteAudioAvailable:ve,handleRemoteUserExit:pe,handleRemoteVideoAvailable:de}),await L.exitRoom(),await L.stopLocalAudio(),J.value)return;await L.stopLocalVideo()}catch(e){console.log("error :>> ",e)}}async function de(e){const{userId:o,streamType:n}=e;try{await L.startRemoteVideo({userId:o,streamType:n,view:ee.value})}catch(e){console.log("error :>> ",e)}}function ve(e){}function me(){ne.value=!0,q()}function pe(e){console.log("event :>> 对方已挂断",e),ue()}function ge(e){console.log("error :>> ",e),b.showVideo=!1}return t((()=>ae.value),(e=>{b.showVideo&&(e===V.IN_CALL?async function(){$.value?ie():(se&&clearTimeout(se),se=setTimeout((async()=>{ne.value||le(V.NO_RESPONSE)}),6e4))}():ue())}),{immediate:!0}),r((()=>{ue()})),(o,n)=>(a(),l("div",T,[i(e("div",{class:"video-box",ref_key:"videoRef",ref:ee},null,512),[[c,ne.value]]),i(e("div",{class:"video-box--self",ref_key:"selfVideoRef",ref:oe},null,512),[[c,ne.value]]),i(e("div",j,[u(d(f),{size:58,round:"",src:d(te).avatar},null,8,["src"]),e("span",_,v(d(te).name),1),e("span",N,v(d(re)),1)],512),[[c,d(J)||!ne.value]]),e("div",H,[e("div",D,[d($)&&!ne.value||ne.value?(a(),l(m,{key:0},[u(d(w),{circle:"",onClick:d(Q),class:p({bordered:!d(G)})},{icon:g((()=>[u(d(h),{size:"30",color:d(G)?"#626262":"#fff",component:d(G)?d(I):d(y)},null,8,["color","component"])])),_:1},8,["onClick","class"]),z],64)):(a(),l(m,{key:1},[u(d(w),{circle:"",color:"#f17568",class:"btn--rotate",onClick:n[0]||(n[0]=()=>le(d(V).REJECTED))},{icon:g((()=>[u(d(h),{size:"30",component:d(A)},null,8,["component"])])),_:1}),B],64))]),e("div",U,[d($)&&!ne.value||ne.value?(a(),l(m,{key:0},[u(d(w),{circle:"",color:"#f17568",class:"btn--rotate",onClick:ce},{icon:g((()=>[u(d(h),{size:"30",component:d(A)},null,8,["component"])])),_:1}),F],64)):(a(),l(m,{key:1},[u(d(w),{circle:"",color:"#2ac98b",onClick:ie},{icon:g((()=>[u(d(h),{size:"30",component:d(A)},null,8,["component"])])),_:1}),O],64))])])]))}});export{P as default};
@@ -18,7 +18,8 @@ export declare enum MESSAGE_TYPE {
18
18
  FORWARD = "FORWARD",
19
19
  QUICK_REPLY = "QUICK_REPLY",
20
20
  AUDIO = "AUDIO",
21
- VIDEO = "VIDEO"
21
+ VIDEO = "VIDEO",
22
+ EVENT = "EVENT"
22
23
  }
23
24
  /**
24
25
  * 订阅消息类别
@@ -1 +1 @@
1
- var E=(E=>(E.SINGLE="SINGLE",E.GROUP="GROUP",E))(E||{}),S=(E=>(E.TEXT="TEXT",E.FILE="FILE",E.EMOJI="EMOJI",E.IMAGE="IMAGE",E.TEMPLATE="TEMPLATE",E.BLEND="BLEND",E.FORWARD="FORWARD",E.QUICK_REPLY="QUICK_REPLY",E.AUDIO="AUDIO",E.VIDEO="VIDEO",E))(S||{}),A=(E=>(E.JOIN_GROUP="JOIN_GROUP",E.LEAVE_GROUP="LEAVE_GROUP",E.NEW_SESSION="NEW_SESSION",E.MESSAGE="MESSAGE",E.AV_STATUS="AV_STATUS",E.RECALL_MESSAGE="RECALL_MESSAGE",E.DISABLE_SESSION="DISABLE_SESSION",E))(A||{}),L=(E=>(E.IN_CALL="IN_CALL",E.CALL_BUSY="CALL_BUSY",E.NO_RESPONSE="NO_RESPONSE",E.FINISHED="FINISHED",E.REJECTED="REJECTED",E.CANCELED="CANCELED",E))(L||{}),I=(E=>(E.REMOVED="REMOVED",E.ENABLED="ENABLED",E.ENDED="ENDED",E))(I||{});export{L as AV_STATUS,E as CHAT_TYPE,S as MESSAGE_TYPE,I as STATUS,A as SUBSCRIBE_MESSAGE_TYPE};
1
+ var E=(E=>(E.SINGLE="SINGLE",E.GROUP="GROUP",E))(E||{}),S=(E=>(E.TEXT="TEXT",E.FILE="FILE",E.EMOJI="EMOJI",E.IMAGE="IMAGE",E.TEMPLATE="TEMPLATE",E.BLEND="BLEND",E.FORWARD="FORWARD",E.QUICK_REPLY="QUICK_REPLY",E.AUDIO="AUDIO",E.VIDEO="VIDEO",E.EVENT="EVENT",E))(S||{}),A=(E=>(E.JOIN_GROUP="JOIN_GROUP",E.LEAVE_GROUP="LEAVE_GROUP",E.NEW_SESSION="NEW_SESSION",E.MESSAGE="MESSAGE",E.AV_STATUS="AV_STATUS",E.RECALL_MESSAGE="RECALL_MESSAGE",E.DISABLE_SESSION="DISABLE_SESSION",E))(A||{}),L=(E=>(E.IN_CALL="IN_CALL",E.CALL_BUSY="CALL_BUSY",E.NO_RESPONSE="NO_RESPONSE",E.FINISHED="FINISHED",E.REJECTED="REJECTED",E.CANCELED="CANCELED",E))(L||{}),I=(E=>(E.REMOVED="REMOVED",E.ENABLED="ENABLED",E.ENDED="ENDED",E))(I||{});export{L as AV_STATUS,E as CHAT_TYPE,S as MESSAGE_TYPE,I as STATUS,A as SUBSCRIBE_MESSAGE_TYPE};
@@ -3,10 +3,11 @@ import { ChatSock } from '../utils/chatSock';
3
3
  import { AnyObject } from '../../../../shared/types';
4
4
  export declare const InjectionIChatData: InjectionKey<ReturnType<typeof initData>>;
5
5
  export declare function initData(props: AnyObject, emit: (event: 'template-click' | 'unread-message-update' | 'session-change' | 'session-close', ...args: any[]) => void): {
6
+ filterable: import("vue").Ref<any>;
7
+ trtcProxy: import("vue").Ref<any>;
6
8
  cssVars: import("vue").ComputedRef<AnyObject>;
7
9
  stompClient: import("vue").Ref<ChatSock | undefined>;
8
10
  state: {
9
- filterable: boolean;
10
11
  orgId: string | number;
11
12
  currentSessionItem: AnyObject;
12
13
  id: string;
@@ -49,10 +50,11 @@ export declare function initData(props: AnyObject, emit: (event: 'template-click
49
50
  emit: (event: 'template-click' | 'unread-message-update' | 'session-change' | 'session-close', ...args: any[]) => void;
50
51
  };
51
52
  export declare const useData: () => {
53
+ filterable: import("vue").Ref<any>;
54
+ trtcProxy: import("vue").Ref<any>;
52
55
  cssVars: import("vue").ComputedRef<AnyObject>;
53
56
  stompClient: import("vue").Ref<ChatSock | undefined>;
54
57
  state: {
55
- filterable: boolean;
56
58
  orgId: string | number;
57
59
  currentSessionItem: AnyObject;
58
60
  id: string;