cnhis-design-vue 3.2.13-beta.3 → 3.2.13-beta.4
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.
@@ -1 +1 @@
|
|
1
|
-
import{defineComponent as
|
1
|
+
import{defineComponent as t,inject as e,ref as n,computed as i,createVNode as o}from"vue";import{NButton as l}from"naive-ui";import{InjectionAIChat as a}from"../types/index.js";import"../../../index.js";import{isArray as r}from"lodash-es";import s from"../../../form-render/index.js";import u from"../../../template-render/index.js";var d=t({name:"ChatCard",inheritAttrs:!1,props:{msgItem:{type:Object,default:()=>({})},instructionId:{type:String}},emits:["button-click"],setup(t,{attrs:d,slots:c,emit:m}){const{patientInfo:p,state:f}=e(a),v=n([]),g=n(),b=i((()=>{var e,n;return!!(null==(n=null==(e=t.msgItem)?void 0:e.content)?void 0:n.body)}));function y(t){try{return JSON.parse(t),!0}catch(t){return!1}}const h=t.msgItem.content;function I(t){const{eventName:e,data:n}=t;e&&m("button-click",{fieldItem:n,isBI:!0})}function x(t){h.data[t.button.id+"Disabled"]=!0,m("button-click",{button:t.button})}return b.value&&(v.value=(h.body.items||[]).map((e=>{var n,i;const o={html_type:e.type,val_key:e.code,name:e.name,elem_width:12,default_val:e.value,lazyRequest:!0,requestCache:!0,urlConfig:{nameKey:null!=(n=e.labelField)?n:"label"},option:[],is_null:e.required?"0":"1"};return"SELECT"===o.html_type&&(o.option=e.options,"fixed"===e.dataSourceType&&(null==(i=e.options)?void 0:i.length)||(o.html_type="REMOTE_SEARCH",Object.assign(o.urlConfig,{url:"/flow/api/instruction/parameter/getOptionsValues",method:"post",params:{instructionId:t.instructionId,code:e.code,configs:p},dependKey:[]}),r(e.dependencies)&&e.dependencies.length&&(o.urlConfig.dependKey=e.dependencies))),o}))),()=>{var e;return o("div",{class:"card"},[b.value?[o("p",null,[h.title||h.header.title]),o(s,{disabled:t.msgItem.disabled,column:12,ref:g,"field-list":v.value},null),h.footer.buttons.map((e=>function(e){const n={width:"100%","--n-height":"36px",fontSize:"15px",marginTop:"10px"},i=b.value?{...n,marginTop:"0"}:n;return o(l,{style:i,secondary:!0,class:"gradient",disabled:t.msgItem.disabled,onClick:async function(){if(b.value){if(!g.value)return;const t=g.value.getFormValues();try{await g.value.validate(),h.body.items.forEach((e=>{t[e.code]&&(e.value=t[e.code])})),f.loading=!0,m("button-click",{values:t,buttonInfo:e,isForm:!0})}catch(t){}}else m("button-click")}},{default:()=>[b.value?null==e?void 0:e.text:h.buttonName]})}(e)))]:o(u,{config:y(null==(e=h.settings)?void 0:e.setting)?JSON.parse(h.settings.setting):null,data:h.data,"onModule-click":I,"onButton-click":x},null)])}}});export{d as default};
|
@@ -1 +1 @@
|
|
1
|
-
var e="@cnhis-design-vue/shared",i="3.2.13-beta.
|
1
|
+
var e="@cnhis-design-vue/shared",i="3.2.13-beta.4",s="index.ts",n={"naive-ui":"^2.30.0",vue:"^3.2.0"},a={"@vicons/ionicons5":"^0.12.0","lodash-es":"^4.17.21",moment:"^2.29.1","video.js":"^7.19.2","videojs-contrib-hls":"^5.15.0",viewerjs:"^1.10.5","xe-utils":"^3.5.4"},d={name:e,version:"3.2.13-beta.4",private:!0,main:"index.ts",peerDependencies:n,dependencies:a};export{d as default,a as dependencies,s as main,e as name,n as peerDependencies,i as version};
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "cnhis-design-vue",
|
3
|
-
"version": "3.2.13-beta.
|
3
|
+
"version": "3.2.13-beta.4",
|
4
4
|
"license": "ISC",
|
5
5
|
"module": "./es/components/index.js",
|
6
6
|
"main": "./es/components/index.js",
|
@@ -72,5 +72,5 @@
|
|
72
72
|
"iOS 7",
|
73
73
|
"last 3 iOS versions"
|
74
74
|
],
|
75
|
-
"gitHead": "
|
75
|
+
"gitHead": "00724b4db7127eeb08a6ca9241f89d4cb29f18ec"
|
76
76
|
}
|