cnhis-design-vue 3.2.10-release.2 → 3.2.11-beta.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.
@@ -1 +1 @@
1
- import t from"axios";import{cloneDeep as e,isArray as i}from"lodash-es";import{IdentityVerificationDialog as r,PreviewDialog as s}from"./dialog.js";import{isIReport as a,getFileUrl as n,useBrowserPrint as o}from"./browserPrint.js";import{getCurrentInstance as l}from"vue";import{uuidGenerator as c}from"../../../../shared/utils/index.js";import{format as h}from"date-fns";import{io as p}from"socket.io-client";const u=String(navigator.platform).toLowerCase().includes("linux"),m=t.create({timeout:6e4,withCredentials:!1}),d=`${window.location.protocol}//${window.location.host}`,g=`${d}/fdp-api/print/assembly/printIReport`,y=`${d}/bi-api/reprot/print/open/client/printIReportForBase64`,f=`${d}/bi-api/reprot/print/open/client/printIReportForHex`,w=`${d}/bi-api/reprot/print/open/client/previewIReport`,v=`${d}/bi-api/reprot/print/open/client/getRemote`,P=`${d}/printService/file`;let _=null;class b{constructor(){var t,e,i;if(this.webview=null,this.dialog=new r,this.dialogPreview=new s,this.instance=null,this.downloadPath="",this.printOrigin="http://127.0.0.1:11111",this.printDomesticOrigin="http://127.0.0.1:17521",this.isRemote=!1,this.CMonitor=null,this.queryServicesParams=null,this.isConnectHiPrint=!1,this.clientInfo=null,this.printerList=[],this.hiPrintSocket=null,this.base64Fragment="",this._successCallbackFn=null,this._errorCallbackFn=null,this._cancelCallbackFn=null,this.messageHandlerQueue=[],this.getIReportFormatId=(t,e)=>t?e.split("_")[1]:e,_)return _;_=this;const a=window;this.CMonitor=a.$CMonitor;try{this.webview=a.top?null==(t=a.top.chrome)?void 0:t.webview:null==(e=a.chrome)?void 0:e.webview}catch(t){console.log(t),this.webview=null==(i=a.chrome)?void 0:i.webview}if(this.webview){this.currentMessageHandler=this.messageHandler.bind(this),this.webview.addEventListener("message",this.currentMessageHandler);try{this.webview.postMessage({exec:"config",data:""})}catch(t){const e="当前浏览器版本不支持获取配置接口";this._handleMonitorNotify(e),console.log("非封装浏览器或者"+e)}}}messageHandler(t){var e;if(console.log("打印事件message",t),!t)return this._handleMonitorNotify("接收到空的浏览器事件,"+t),console.log("当前回执",t,"接收到空的浏览器事件");let i;try{i=JSON.parse(t.data||"{}")}catch(e){console.log("解析e.data失败,"+e),this._handleMonitorNotify("解析e.data失败,"+t)}if(["print","pdf","resetprint"].includes(null==i?void 0:i.cmd)){console.log("打印命令执行了",i);const e=this.messageHandlerQueue.shift();if(!e)return console.log("当前回执",t,"没有可用的handler");const{resolve:r,reject:s}=e;try{if("resetprint"===(null==i?void 0:i.cmd))return void r({result:(null==i?void 0:i.res)?"success":"fail"});r(i.res||"")}catch(t){s(t)}}else"config"===(null==i?void 0:i.exec)&&(this.downloadPath=(null==(e=i.res)?void 0:e.downloadpath)||"")}_initDomesticSystem(t){try{if(this.hiPrintSocket)return this.isConnectHiPrint;this.hiPrintSocket=p(this.printDomesticOrigin,{reconnection:!1,transports:["websocket"],auth:{token:"no-use-vue-plugin-hiprint"}}),this.hiPrintSocket&&(this.hiPrintSocket.on("connect",(()=>{this.isConnectHiPrint=!0})),this.hiPrintSocket.on("disconnect",(()=>{this.isConnectHiPrint=!1,this.hiPrintSocket=null})),this.hiPrintSocket.on("clientInfo",(t=>{console.log("获取到客户端信息>>>>>",t),t.clientUrl&&(this.clientInfo=t)})),this.hiPrintSocket.on("printerList",(e=>{console.log("获取到打印机列表信息>>>>>",e),this.printerList=e,t&&t(!0)})),this.hiPrintSocket.on("success",(t=>{console.log("打印成功>>>>>",t),this.base64Fragment="",this._successCallbackFn&&this._successCallbackFn(t)})),this.hiPrintSocket.on("replayPrinterTemplate",(t=>{console.log("获取到数据的回复>>>>>",t),t&&this.hiPrintSocket.emit("news",t)})),this.hiPrintSocket.on("error",(t=>{console.log("打印失败>>>>>",t),this.base64Fragment="","cancel"==(null==t?void 0:t.result)?this._cancelCallbackFn&&this._cancelCallbackFn(t):this._errorCallbackFn&&this._errorCallbackFn(t)})))}catch(e){console.log("ihoPrint系统连接失败",e),t&&t(!1)}}async getPicAndUpload(t){try{const e=t=>"[object Object]"===Object.prototype.toString.call(t);if("success"===(null==t?void 0:t.result)&&"Y"==(null==t?void 0:t.uploadTemplateFlag)&&!(null==t?void 0:t.filebase64)&&this.queryServicesParams){const t=e(this.queryServicesParams.params)?this.queryServicesParams.params:JSON.parse(this.queryServicesParams.params);t.uploadTemplateFlag="Y",this.queryServicesParams.params=JSON.stringify(t),this.queryServicesParams.cmdid="7",this.queryServicesParams.print={print:1,type:6,zip:0},this.queryServicesParams.paramsArr=[{params:JSON.stringify(t)}];await this._queryBase64ServicesPrint(this.queryServicesParams)}}catch(t){console.log(t)}finally{this.queryServicesParams=null}}async postMessage(t,e=0){if(!this.webview)return Promise.reject();const i=c();return e&&e>0?this.messageCollectAndNotifyFail(i,t,e):this.messageCollect(i,t)}messageCollect(t,e){return new Promise(((i,r)=>{this.messageHandlerQueue.push({resolve:i,reject:r,id:t}),this.webview.postMessage(e)}))}messageCollectAndNotifyFail(t,e,i){return Promise.race([new Promise(((i,r)=>{this.messageHandlerQueue.push({resolve:i,reject:r,id:t}),this.webview.postMessage(e)})),new Promise(((e,r)=>{setTimeout((()=>{const e=this.messageHandlerQueue.findIndex((e=>e.id===t));e>-1&&this.messageHandlerQueue.splice(e,1),r({type:"timeout"})}),i)}))])}destroy(){}show(...t){return this.dialog.show(...t)}showPreview(...t){return this.dialogPreview.show(...t)}_testDomesticSystemConnection(){return new Promise((t=>{m({url:`${this.printDomesticOrigin}/test`,method:"get",withCredentials:!1,params:{}}).then((({data:e})=>{e.status?t(!0):t(!1)})).catch((e=>{t(!1)}))}))}_testConnection(){return this.webview?Promise.resolve(!0):new Promise((t=>{m({url:`${this.printOrigin}/test`,method:"get",withCredentials:!1,params:{inputdata:{result:"success"}}}).then((({data:e})=>{"success"===e.result?t(!0):t(!1)})).catch((e=>{t(!1)}))}))}async resetPrinter(t,e){const i=a(t),r=this.getIReportFormatId(i,t);if(i&&(u||2==e)){return await this._testDomesticSystemConnection()?m({url:`${this.printDomesticOrigin}/resetPrint`,method:"get",withCredentials:!1,params:{formatId:r}}).then((({data:t})=>t.status?{type:"resetSuccess",result:"success",message:null==t?void 0:t.message}:{type:"resetError",result:"error",message:null==t?void 0:t.message})).catch((t=>({type:"resetError",result:"error",message:"重置打印机错误"}))):{type:"notOpenedApp",result:"error",message:"请开启ihoPrint客户端"}}return this.webview?this.postMessage({exec:"resetprint",data:{formatID:r}}):m({url:`${this.printOrigin}/services/printset`,method:"get",withCredentials:!1,params:{inputdata:r}}).then((({data:t})=>t))}_queryServicesPrint(e){return this.webview?this.postMessage({exec:"print",data:{inputData:e}},null==e?void 0:e.messageTimeout):t({url:this.printOrigin+"/services/print",method:"get",params:{inputData:JSON.stringify(e)}}).then((({data:t})=>t))}_queryBase64ServicesPrint(t){return this.webview?this.postMessage({exec:"print",data:{inputData:t}}):m({url:this.printOrigin+"/services/Printqueue",method:"get",params:{inputData:JSON.stringify(t)}}).then((({data:t})=>t))}_callPrintWithFile(t){const e={cmdid:"7",flag:"1"},i={inputData:JSON.stringify(Object.assign({},e,t))};return this.webview?this.postMessage({exec:"print",data:r(i)}):m({url:this.printOrigin+"/PrintLocal",method:"post",data:i,transformRequest:[r]}).then((({data:t})=>t));function r(t){let e="";for(const i in t)e+=encodeURIComponent(i)+"="+encodeURIComponent(t[i])+"&";return e=e.slice(0,-1),e}}_handleMonitorNotify(t){var e,i;null==(i=null==(e=this.CMonitor)?void 0:e.notify)||i.call(e,{name:"custom_info",message:t,businessName:"打印sdk"})}_handleResult(t,e,i){if(!t){const t="打印命令返回空数据";return this._handleMonitorNotify(""),null==e||e({type:"printError",message:t,result:"error",errinfo:t}),!1}if("success"!==t.result){const r=t.message||t.Message;this._handleMonitorNotify(r);const s={type:"printError",message:r,result:t.result,errinfo:t.errinfo};return"cancel"==t.result?(i&&i({type:"printCancel",message:r,result:t.result,errinfo:t.errinfo}),!1):(null==e||e(s),!1)}return t}_handleResultTest(t,e){return!!t||(console.log("notInstalledApp"),null==e||e({type:"notInstalledApp",message:"请打开打印服务器插件",result:"error"}),!1)}async _handleEventQueryPrintData(t,e,i,r,s){const a={templateId:t,formatId:e,params:i,cmdid:"7",messageTimeout:r},n=await this._queryServicesPrint(a);return this._handleQueryPrintDataResult(n,e,s)}_handleQueryPrintDataResult(t,e,i){if(!(null==t?void 0:t.file)){try{const e=t.message||t.Message;console.log(e),null==i||i({result:"error",type:"queryPrintDataFailure",message:e})}catch(t){console.log(t)}return!1}return{file:t.file,printerName:t.defprinter,pageCount:t.pagecount,formatId:e}}async _handleEventDirect({templateId:t,formatId:e,svrUpdateIp:i,params:r,paramsArr:s,cmdid:a,print:n,signature:o,copies:l,printdlgshow:c="0",nobillnode:p="1",btnprint:u="1",messageTimeout:m=0}){const d={templateId:t,formatId:e,svrUpdateIp:i,params:r,cmdid:a,nobillnode:p,printdlgshow:c,btnprint:u,copies:l,messageTimeout:m,...o?{signature:o}:{}};if(s&&(d.paramsArr=s),n){try{n=JSON.parse(n)}catch(t){}d.print=n}else if(this.isRemote){const t=h(new Date,"yyyyMMddHHmmss");d.print={print:"1",type:"1",zip:"0",filename:`F:\\WorkSpace\\crmweb\\web\\${t}\\${t}`}}return this.queryServicesParams=d,await this._queryServicesPrint(d)}async _handleEventEditFormat({templateId:t,formatId:e="",params:i="",token:r,messageTimeout:s=0}){const a={};let n={};try{n=Object.assign({},a,JSON.parse(i))}catch(t){n=a}const o={templateId:t,formatId:e,cmdid:"9",token:r,params:JSON.stringify(n),messageTimeout:s};return await this._queryServicesPrint(o)}async _queryProxyOrigin(){if(this.isRemote)return;const{data:t}=await m({method:"get",url:v})||{},{map:e={}}=t;e.isRemote&&(this.printOrigin=d+"/printService",this.isRemote=!0)}async _queryPrintFile(t,e=""){const{data:i}=await m({method:"post",url:g,responseType:"blob",params:{formatId:t.split("_")[1],params:e}})||{};return i}paramsSerializer(t){return Object.keys(t).forEach((e=>{const i=t[e];t[e]=i,"biParams"==e&&(t[e]=encodeURIComponent(i))})),t}async _queryPrintForBase64(t,e,i="",r){const s="object"==typeof i?i:JSON.parse(i),{data:a}=await m({method:"post",url:y,params:{id:t,formatId:e,params:this.paramsSerializer(s),authorizationKey:r}})||{};return a}async _queryPrintForBase16(t,e,i="",r){const s="object"==typeof i?i:JSON.parse(i),{data:a}=await m({method:"post",url:f,params:{id:t,formatId:e,params:this.paramsSerializer(s),authorizationKey:r}})||{};return a}async _queryPrintForPdf(t,e,i="",r){const s="object"==typeof i?i:JSON.parse(i),{data:a}=await m({method:"post",url:w,responseType:"blob",params:{id:t,formatId:e,params:this.paramsSerializer(s),authorizationKey:r}})||{};return a}async _browserPrint(t,e){if(this.isRemote){const{filedir:i}=t,r=JSON.parse(i)[0].replace(/\\/g,"/").split("/"),s=r[r.length-2],a=r[r.length-1],l=await n(`${P}/${s}/${a}`),c=o(null,e,l);if("preview"===e)return c}}_base64ToBlob(t,e){const i=window.atob(t);let r=i.length;const s=new Uint8Array(r);for(;r--;)s[r]=i.charCodeAt(r);return new Blob([s],{type:e})}async preview({iReportExecuteMode:t,templateId:e,formatId:i,params:r="",paramsArr:s,authorizationKey:n,signature:c,btnprint:h,messageTimeout:p=0},m,d){const g=a(i),y=this.getIReportFormatId(g,i);if(g&&(u||2==t)){const t=await this._queryPrintForPdf(e,y,r,n);if(!t)return null==d?void 0:d({type:"queryPrintDataFailure",result:"error",message:"获取文件失败!"});const i=o(t,"preview");return this.instance||(this.instance=l()),this.showPreview(this.instance,i),null==m?void 0:m({result:"success",message:"",file:t})}await this._queryProxyOrigin();const f=await this._testConnection();if(!this._handleResultTest(f,d))return!1;try{const t=await this._handleEventDirect({templateId:e,formatId:y,params:r,paramsArr:s,cmdid:this.isRemote?"7":"8",signature:c,btnprint:h,messageTimeout:p}),i=this._handleResult(t,d);if(!i)return!1;if(this.isRemote){const t=await this._browserPrint(i,"preview");this.instance||(this.instance=l()),this.showPreview(this.instance,t)}await this.getPicAndUpload(i),null==m||m(i)}catch(t){const e="预览失败",i="timeout"===(null==t?void 0:t.type)?{...t,message:e,result:"error"}:{message:e,result:"error"};null==d||d(i),this._handleMonitorNotify(i)}}async printSync(t,e,i){const r=t.map((t=>{const e={params:"",printdlgshow:"0",nobillnode:"1",btnprint:"1",...t,cmdid:"7",...t.signature?{signature:t.signature}:{}};if(e.print)try{e.print=JSON.parse(e.print)}catch(t){}return{inputData:e}}));try{const t=c(),s=await this.messageCollect(t,{exec:"printA",data:r});if(s&&Array.isArray(s)){s.some((t=>"success"===t.res.result))?null==e||e(s):(null==i||i(s),this._handleMonitorNotify(s))}else{const t="打印命令返回无效数据";this._handleMonitorNotify(s||""),null==i||i({type:"printError",message:t,result:"error",errinfo:t})}}catch(t){const e={error:t,result:"error",message:"打印失败"};null==i||i(e),this._handleMonitorNotify(e)}}async printDirect({iReportExecuteMode:t,templateId:e,formatId:i,params:r="",paramsArr:s,authorizationKey:n,print:o,signature:l,printdlgshow:c,nobillnode:h,copies:p,svrUpdateIp:m,isDownloadFile:d=!0,messageTimeout:g=0},y,f,w,v="printDirect"){const P=a(i),_=this.getIReportFormatId(P,i);if(P&&(u||2==t)){if(!await this._testDomesticSystemConnection())return void f({type:"notOpenedApp",result:"error",message:"请开启ihoPrint客户端"});return void(this._initDomesticSystem((async t=>{t?await this.printToHiPrint({templateId:e,formatId:_,params:r,authorizationKey:n},y,f,w):f({type:"connectAppFail",result:"error",message:"连接ihoPrint客户端失败"})}))&&await this.printToHiPrint({templateId:e,formatId:_,params:r,authorizationKey:n},y,f,w))}await this._queryProxyOrigin();const b=await this._testConnection();if(!this._handleResultTest(b,f))return!1;try{const t=await this._handleEventDirect({templateId:e,formatId:_,params:r,paramsArr:s,cmdid:"7",print:o,signature:l,printdlgshow:c,nobillnode:h,copies:p,svrUpdateIp:m,messageTimeout:g}),i=this._handleResult(t,f,w);if(!i)return!1;d&&["downloadPDF"].includes(v)&&await this._browserPrint(i,v),null==y||y(i)}catch(t){const e="printDirect"===v?"打印失败":"下载失败",i="timeout"===(null==t?void 0:t.type)?{...t,message:e,result:"error"}:{message:e,result:"error"};null==f||f(i),this._handleMonitorNotify(i)}}async printToHiPrint({templateId:t,formatId:e,params:i,authorizationKey:r},s,a,n){const o=await this._queryPrintForBase64(t,e,i,r);if(!o.success)return a({message:o.resultMsg,result:"error"});const{base64:l,formatId:c}=o.map;this.base64Fragment=l,this._successCallbackFn=s,this._errorCallbackFn=a,n&&(this._cancelCallbackFn=n),this.hiPrintSocket.emit("news",{printerList:this.printerList,type:"askPrinterTemplate",markTemplateId:c,pdf_stream:this.base64Fragment})}_downloadPDF(t){return this.webview?this.postMessage({exec:"pdf",data:{file:t}}):m.get(this.printOrigin+"/download",{params:{inputData:t}}).then((({data:t})=>t))}async downloadPDF(t,r,s){var n;const o=e(t);if(this.webview&&this.downloadPath&&(Reflect.has(o,"print")||Reflect.set(o,"print",{print:"1",type:"1"}),!o.print.filename)){const t=h(new Date,"yyyy-MM-dd"),e=c(),i=h(new Date,"yyyyMMddHHmmss")+e;o.print.filename=`${this.downloadPath}/${t}/${i}/${i}`.replace(/\\/g,"/")}const l=a(o.formatId);if(o.formatId=this.getIReportFormatId(l,o.formatId),l&&(u||2==o.iReportExecuteMode)){const t=await this._queryPrintForBase16(o.templateId||"",o.formatId,o.params||"",o.authorizationKey);return(null==t?void 0:t.success)?r({filebase64:null==(n=null==t?void 0:t.map)?void 0:n.hex,isIreport:!0}):null==s?void 0:s({type:"queryPrintDataFailure",result:"error",message:"获取文件失败!"})}this.printDirect(o,(async t=>{t||s({result:"error",message:""});const e=this,a=await async function(t){const r=[],s=JSON.parse(t);if(!i(s))return await e._downloadPDF("");if(1===s.length)return await e._downloadPDF(s[0]||"");for(let t=0,i=s.length;t<i;t++)r.push(await e._downloadPDF(s[t]||""));return r}(t.filedir);r(a,t)}),(t=>s(t)),(t=>{console.log(t)}),"downloadPDF")}async print({templateId:t,formatId:e,params:i="",messageTimeout:r=0},s,a){const n=await this._testConnection();if(!this._handleResultTest(n,a))return!1;const o=await this.queryPrintData({templateId:t,formatId:e,params:i,messageTimeout:r},void 0,a);if(!o)return!1;const l=this.printFileData({formatId:e,file:o.file,printerName:o.printerName},void 0,a);if(!l)return!1;s&&s(l)}async queryPrintData({templateId:t,formatId:e,params:i="",messageTimeout:r=0},s,a){const n=await this._testConnection();if(!this._handleResultTest(n,a))return!1;const o=await this._handleEventQueryPrintData(t,e,i,r,a);return!!o&&(s&&s(o),o)}async printFileData({formatId:t,file:e,printerName:i="Default"},r,s){const a=await this._testConnection();if(!this._handleResultTest(a,s))return!1;const n=await this._callPrintWithFile({formatId:t,printname:i,file:e}),o=this._handleResult(n,s);return!!o&&(r&&r(o),o)}async editPrintFormat({templateId:t,formatId:e,params:i,token:r,messageTimeout:s=0},a,n){const o=await this._testConnection();if(!this._handleResultTest(o,n))return!1;const l=await this._handleEventEditFormat({templateId:t,formatId:e,params:i,token:r,messageTimeout:s}),c=this._handleResult(l,n);if(!c)return!1;a&&a(c)}async addPrintFormat({templateId:t,params:e,token:i},r,s){const a=await this._testConnection();if(!this._handleResultTest(a,s))return!1;const n=await this._handleEventEditFormat({templateId:t,params:e,token:i}),o=this._handleResult(n,s);if(!o)return!1;r&&r(o)}}export{b as Print};
1
+ import t from"axios";import{cloneDeep as e,isArray as i}from"lodash-es";import{IdentityVerificationDialog as r,PreviewDialog as s}from"./dialog.js";import{isIReport as a,getFileUrl as n,useBrowserPrint as o}from"./browserPrint.js";import{getCurrentInstance as l}from"vue";import{uuidGenerator as c}from"../../../../shared/utils/index.js";import{format as h}from"date-fns";import{io as p}from"socket.io-client";const u=String(navigator.platform).toLowerCase().includes("linux"),m=t.create({timeout:6e4,withCredentials:!1}),d=`${window.location.protocol}//${window.location.host}`,g=`${d}/fdp-api/print/assembly/printIReport`,y=`${d}/bi-api/reprot/print/open/client/printIReportForBase64`,f=`${d}/bi-api/reprot/print/open/client/printIReportForHex`,w=`${d}/bi-api/reprot/print/open/client/previewIReport`,v=`${d}/bi-api/reprot/print/open/client/getRemote`,P=`${d}/printService/file`;let _=null;class I{constructor(){var t,e,i;if(this.webview=null,this.dialog=new r,this.dialogPreview=new s,this.instance=null,this.downloadPath="",this.printOrigin="http://127.0.0.1:11111",this.printDomesticOrigin="http://127.0.0.1:17521",this.isRemote=!1,this.CMonitor=null,this.queryServicesParams=null,this.isConnectHiPrint=!1,this.clientInfo=null,this.printerList=[],this.hiPrintSocket=null,this.base64Fragment="",this._successCallbackFn=null,this._errorCallbackFn=null,this._cancelCallbackFn=null,this.messageHandlerQueue=[],this.getIReportFormatId=(t,e)=>t?e.split("_")[1]:e,_)return _;_=this;const a=window;this.CMonitor=a.$CMonitor;try{this.webview=a.top?null==(t=a.top.chrome)?void 0:t.webview:null==(e=a.chrome)?void 0:e.webview}catch(t){console.log(t),this.webview=null==(i=a.chrome)?void 0:i.webview}if(this.webview){this.currentMessageHandler=this.messageHandler.bind(this),this.webview.addEventListener("message",this.currentMessageHandler);try{this.webview.postMessage({exec:"config",data:""})}catch(t){const e="当前浏览器版本不支持获取配置接口";this._handleMonitorNotify(e),console.log("非封装浏览器或者"+e)}}}messageHandler(t){var e;if(console.log("打印事件message",t),!t)return this._handleMonitorNotify("接收到空的浏览器事件,"+t),console.log("当前回执",t,"接收到空的浏览器事件");let i;try{i=JSON.parse(t.data||"{}")}catch(e){console.log("解析e.data失败,"+e),this._handleMonitorNotify("解析e.data失败,"+t)}if(["print","pdf","resetprint"].includes(null==i?void 0:i.cmd)){console.log("打印命令执行了",i);const e=this.messageHandlerQueue.shift();if(!e)return console.log("当前回执",t,"没有可用的handler");const{resolve:r,reject:s}=e;try{if("resetprint"===(null==i?void 0:i.cmd))return void r({result:(null==i?void 0:i.res)?"success":"fail"});r(i.res||"")}catch(t){s(t)}}else"config"===(null==i?void 0:i.exec)&&(this.downloadPath=(null==(e=i.res)?void 0:e.downloadpath)||"")}_initDomesticSystem(t){try{if(this.hiPrintSocket)return this.isConnectHiPrint;this.hiPrintSocket=p(this.printDomesticOrigin,{reconnection:!1,transports:["websocket"],auth:{token:"no-use-vue-plugin-hiprint"}}),this.hiPrintSocket&&(this.hiPrintSocket.on("connect",(()=>{this.isConnectHiPrint=!0})),this.hiPrintSocket.on("disconnect",(()=>{this.isConnectHiPrint=!1,this.hiPrintSocket=null})),this.hiPrintSocket.on("clientInfo",(t=>{console.log("获取到客户端信息>>>>>",t),t.clientUrl&&(this.clientInfo=t)})),this.hiPrintSocket.on("printerList",(e=>{console.log("获取到打印机列表信息>>>>>",e),this.printerList=e,t&&t(!0)})),this.hiPrintSocket.on("success",(t=>{console.log("打印成功>>>>>",t),this.base64Fragment="",this._successCallbackFn&&this._successCallbackFn(t)})),this.hiPrintSocket.on("replayPrinterTemplate",(t=>{console.log("获取到数据的回复>>>>>",t),t&&this.hiPrintSocket.emit("news",t)})),this.hiPrintSocket.on("error",(t=>{console.log("打印失败>>>>>",t),this.base64Fragment="","cancel"==(null==t?void 0:t.result)?this._cancelCallbackFn&&this._cancelCallbackFn(t):this._errorCallbackFn&&this._errorCallbackFn(t)})))}catch(e){console.log("ihoPrint系统连接失败",e),t&&t(!1)}}async getPicAndUpload(t){try{const e=t=>"[object Object]"===Object.prototype.toString.call(t);if("success"===(null==t?void 0:t.result)&&"Y"==(null==t?void 0:t.uploadTemplateFlag)&&!(null==t?void 0:t.filebase64)&&this.queryServicesParams){const t=e(this.queryServicesParams.params)?this.queryServicesParams.params:JSON.parse(this.queryServicesParams.params);t.uploadTemplateFlag="Y",this.queryServicesParams.params=JSON.stringify(t),this.queryServicesParams.cmdid="7",this.queryServicesParams.print={print:1,type:6,zip:0},this.queryServicesParams.paramsArr=[{params:JSON.stringify(t)}];await this._queryBase64ServicesPrint(this.queryServicesParams)}}catch(t){console.log(t)}finally{this.queryServicesParams=null}}async postMessage(t,e=0){if(!this.webview)return Promise.reject();const i=c();return e&&e>0?this.messageCollectAndNotifyFail(i,t,e):this.messageCollect(i,t)}messageCollect(t,e){return new Promise(((i,r)=>{this.messageHandlerQueue.push({resolve:i,reject:r,id:t}),this.webview.postMessage(e)}))}messageCollectAndNotifyFail(t,e,i){return Promise.race([new Promise(((i,r)=>{this.messageHandlerQueue.push({resolve:i,reject:r,id:t}),this.webview.postMessage(e)})),new Promise(((e,r)=>{setTimeout((()=>{const e=this.messageHandlerQueue.findIndex((e=>e.id===t));e>-1&&this.messageHandlerQueue.splice(e,1),r({type:"timeout"})}),i)}))])}destroy(){}show(...t){return this.dialog.show(...t)}showPreview(...t){return this.dialogPreview.show(...t)}_testDomesticSystemConnection(){return new Promise((t=>{m({url:`${this.printDomesticOrigin}/test`,method:"get",withCredentials:!1,params:{}}).then((({data:e})=>{e.status?t(!0):t(!1)})).catch((e=>{t(!1)}))}))}_testConnection(){return this.webview?Promise.resolve(!0):new Promise((t=>{m({url:`${this.printOrigin}/test`,method:"get",withCredentials:!1,params:{inputdata:{result:"success"}}}).then((({data:e})=>{"success"===e.result?t(!0):t(!1)})).catch((e=>{t(!1)}))}))}async resetPrinter(t,e){const i=a(t),r=this.getIReportFormatId(i,t);if(i&&(u||2==e)){return await this._testDomesticSystemConnection()?m({url:`${this.printDomesticOrigin}/resetPrint`,method:"get",withCredentials:!1,params:{formatId:r}}).then((({data:t})=>t.status?{type:"resetSuccess",result:"success",message:null==t?void 0:t.message}:{type:"resetError",result:"error",message:null==t?void 0:t.message})).catch((t=>({type:"resetError",result:"error",message:"重置打印机错误"}))):{type:"notInstalledApp",result:"error",message:"请开启ihoPrint客户端"}}return this.webview?this.postMessage({exec:"resetprint",data:{formatID:r}}):m({url:`${this.printOrigin}/services/printset`,method:"get",withCredentials:!1,params:{inputdata:r}}).then((({data:t})=>t))}_queryServicesPrint(e){return this.webview?this.postMessage({exec:"print",data:{inputData:e}},null==e?void 0:e.messageTimeout):t({url:this.printOrigin+"/services/print",method:"get",params:{inputData:JSON.stringify(e)}}).then((({data:t})=>t))}_queryBase64ServicesPrint(t){return this.webview?this.postMessage({exec:"print",data:{inputData:t}}):m({url:this.printOrigin+"/services/Printqueue",method:"get",params:{inputData:JSON.stringify(t)}}).then((({data:t})=>t))}_callPrintWithFile(t){const e={cmdid:"7",flag:"1"},i={inputData:JSON.stringify(Object.assign({},e,t))};return this.webview?this.postMessage({exec:"print",data:r(i)}):m({url:this.printOrigin+"/PrintLocal",method:"post",data:i,transformRequest:[r]}).then((({data:t})=>t));function r(t){let e="";for(const i in t)e+=encodeURIComponent(i)+"="+encodeURIComponent(t[i])+"&";return e=e.slice(0,-1),e}}_handleMonitorNotify(t){var e,i;null==(i=null==(e=this.CMonitor)?void 0:e.notify)||i.call(e,{name:"custom_info",message:t,businessName:"打印sdk"})}_handleResult(t,e,i){if(!t){const t="打印命令返回空数据";return this._handleMonitorNotify(""),null==e||e({type:"printError",message:t,result:"error",errinfo:t}),!1}if("success"!==t.result){const r=t.message||t.Message;this._handleMonitorNotify(r);const s={type:"printError",message:r,result:t.result,errinfo:t.errinfo};return"cancel"==t.result?(i&&i({type:"printCancel",message:r,result:t.result,errinfo:t.errinfo}),!1):(null==e||e(s),!1)}return t}_handleResultTest(t,e){return!!t||(console.log("notInstalledApp"),null==e||e({type:"notInstalledApp",message:"请打开打印服务器插件",result:"error"}),!1)}async _handleEventQueryPrintData(t,e,i,r,s){const a={templateId:t,formatId:e,params:i,cmdid:"7",messageTimeout:r},n=await this._queryServicesPrint(a);return this._handleQueryPrintDataResult(n,e,s)}_handleQueryPrintDataResult(t,e,i){if(!(null==t?void 0:t.file)){try{const e=t.message||t.Message;console.log(e),null==i||i({result:"error",type:"queryPrintDataFailure",message:e})}catch(t){console.log(t)}return!1}return{file:t.file,printerName:t.defprinter,pageCount:t.pagecount,formatId:e}}async _handleEventDirect({templateId:t,formatId:e,svrUpdateIp:i,params:r,paramsArr:s,cmdid:a,print:n,signature:o,copies:l,printdlgshow:c="0",nobillnode:p="1",btnprint:u="1",messageTimeout:m=0}){const d={templateId:t,formatId:e,svrUpdateIp:i,params:r,cmdid:a,nobillnode:p,printdlgshow:c,btnprint:u,copies:l,messageTimeout:m,...o?{signature:o}:{}};if(s&&(d.paramsArr=s),n){try{n=JSON.parse(n)}catch(t){}d.print=n}else if(this.isRemote){const t=h(new Date,"yyyyMMddHHmmss");d.print={print:"1",type:"1",zip:"0",filename:`F:\\WorkSpace\\crmweb\\web\\${t}\\${t}`}}return this.queryServicesParams=d,await this._queryServicesPrint(d)}async _handleEventEditFormat({templateId:t,formatId:e="",params:i="",token:r,messageTimeout:s=0}){const a={};let n={};try{n=Object.assign({},a,JSON.parse(i))}catch(t){n=a}const o={templateId:t,formatId:e,cmdid:"9",token:r,params:JSON.stringify(n),messageTimeout:s};return await this._queryServicesPrint(o)}async _queryProxyOrigin(){if(this.isRemote)return;const{data:t}=await m({method:"get",url:v})||{},{map:e={}}=t;e.isRemote&&(this.printOrigin=d+"/printService",this.isRemote=!0)}async _queryPrintFile(t,e=""){const{data:i}=await m({method:"post",url:g,responseType:"blob",params:{formatId:t.split("_")[1],params:e}})||{};return i}paramsSerializer(t){return Object.keys(t).forEach((e=>{const i=t[e];t[e]=i,"biParams"==e&&(t[e]=encodeURIComponent(i))})),t}async _queryPrintForBase64(t,e,i="",r){const s="object"==typeof i?i:JSON.parse(i),{data:a}=await m({method:"post",url:y,params:{id:t,formatId:e,params:this.paramsSerializer(s),authorizationKey:r}})||{};return a}async _queryPrintForBase16(t,e,i="",r){const s="object"==typeof i?i:JSON.parse(i),{data:a}=await m({method:"post",url:f,params:{id:t,formatId:e,params:this.paramsSerializer(s),authorizationKey:r}})||{};return a}async _queryPrintForPdf(t,e,i="",r){const s="object"==typeof i?i:JSON.parse(i),{data:a}=await m({method:"post",url:w,responseType:"blob",params:{id:t,formatId:e,params:this.paramsSerializer(s),authorizationKey:r}})||{};return a}async _browserPrint(t,e){if(this.isRemote){const{filedir:i}=t,r=JSON.parse(i)[0].replace(/\\/g,"/").split("/"),s=r[r.length-2],a=r[r.length-1],l=await n(`${P}/${s}/${a}`),c=o(null,e,l);if("preview"===e)return c}}_base64ToBlob(t,e){const i=window.atob(t);let r=i.length;const s=new Uint8Array(r);for(;r--;)s[r]=i.charCodeAt(r);return new Blob([s],{type:e})}async preview({iReportExecuteMode:t,templateId:e,formatId:i,params:r="",paramsArr:s,authorizationKey:n,signature:c,btnprint:h,messageTimeout:p=0},m,d){const g=a(i),y=this.getIReportFormatId(g,i);if(g&&(u||2==t)){const t=await this._queryPrintForPdf(e,y,r,n);if(!t)return null==d?void 0:d({type:"queryPrintDataFailure",result:"error",message:"获取文件失败!"});const i=o(t,"preview");return this.instance||(this.instance=l()),this.showPreview(this.instance,i),null==m?void 0:m({result:"success",message:"",file:t})}await this._queryProxyOrigin();const f=await this._testConnection();if(!this._handleResultTest(f,d))return!1;try{const t=await this._handleEventDirect({templateId:e,formatId:y,params:r,paramsArr:s,cmdid:this.isRemote?"7":"8",signature:c,btnprint:h,messageTimeout:p}),i=this._handleResult(t,d);if(!i)return!1;if(this.isRemote){const t=await this._browserPrint(i,"preview");this.instance||(this.instance=l()),this.showPreview(this.instance,t)}await this.getPicAndUpload(i),null==m||m(i)}catch(t){const e="预览失败",i="timeout"===(null==t?void 0:t.type)?{...t,message:e,result:"error"}:{message:e,result:"error"};null==d||d(i),this._handleMonitorNotify(i)}}async printSync(t,e,i){const r=t.map((t=>{const e={params:"",printdlgshow:"0",nobillnode:"1",btnprint:"1",...t,cmdid:"7",...t.signature?{signature:t.signature}:{}};if(e.print)try{e.print=JSON.parse(e.print)}catch(t){}return{inputData:e}}));try{const t=c(),s=await this.messageCollect(t,{exec:"printA",data:r});if(s&&Array.isArray(s)){s.some((t=>"success"===t.res.result))?null==e||e(s):(null==i||i(s),this._handleMonitorNotify(s))}else{const t="打印命令返回无效数据";this._handleMonitorNotify(s||""),null==i||i({type:"printError",message:t,result:"error",errinfo:t})}}catch(t){const e={error:t,result:"error",message:"打印失败"};null==i||i(e),this._handleMonitorNotify(e)}}async printDirect({iReportExecuteMode:t,templateId:e,formatId:i,params:r="",paramsArr:s,authorizationKey:n,print:o,signature:l,printdlgshow:c,nobillnode:h,copies:p,svrUpdateIp:m,isDownloadFile:d=!0,messageTimeout:g=0},y,f,w,v="printDirect"){const P=a(i),_=this.getIReportFormatId(P,i);if(P&&(u||2==t)){if(!await this._testDomesticSystemConnection())return void f({type:"notInstalledApp",result:"error",message:"请开启ihoPrint客户端"});return void(this._initDomesticSystem((async t=>{t?await this.printToHiPrint({templateId:e,formatId:_,params:r,authorizationKey:n},y,f,w):f({type:"notInstalledApp",result:"error",message:"连接ihoPrint客户端失败"})}))&&await this.printToHiPrint({templateId:e,formatId:_,params:r,authorizationKey:n},y,f,w))}await this._queryProxyOrigin();const I=await this._testConnection();if(!this._handleResultTest(I,f))return!1;try{const t=await this._handleEventDirect({templateId:e,formatId:_,params:r,paramsArr:s,cmdid:"7",print:o,signature:l,printdlgshow:c,nobillnode:h,copies:p,svrUpdateIp:m,messageTimeout:g}),i=this._handleResult(t,f,w);if(!i)return!1;d&&["downloadPDF"].includes(v)&&await this._browserPrint(i,v),null==y||y(i)}catch(t){const e="printDirect"===v?"打印失败":"下载失败",i="timeout"===(null==t?void 0:t.type)?{...t,message:e,result:"error"}:{message:e,result:"error"};null==f||f(i),this._handleMonitorNotify(i)}}async printToHiPrint({templateId:t,formatId:e,params:i,authorizationKey:r},s,a,n){const o=await this._queryPrintForBase64(t,e,i,r);if(!o.success)return a({message:o.resultMsg,result:"error"});const{base64:l,formatId:c}=o.map;this.base64Fragment=l,this._successCallbackFn=s,this._errorCallbackFn=a,n&&(this._cancelCallbackFn=n),this.hiPrintSocket.emit("news",{printerList:this.printerList,type:"askPrinterTemplate",markTemplateId:c,pdf_stream:this.base64Fragment})}_downloadPDF(t){return this.webview?this.postMessage({exec:"pdf",data:{file:t}}):m.get(this.printOrigin+"/download",{params:{inputData:t}}).then((({data:t})=>t))}async downloadPDF(t,r,s){var n;const o=e(t);if(this.webview&&this.downloadPath&&(Reflect.has(o,"print")||Reflect.set(o,"print",{print:"1",type:"1"}),!o.print.filename)){const t=h(new Date,"yyyy-MM-dd"),e=c(),i=h(new Date,"yyyyMMddHHmmss")+e;o.print.filename=`${this.downloadPath}/${t}/${i}/${i}`.replace(/\\/g,"/")}const l=a(o.formatId);if(o.formatId=this.getIReportFormatId(l,o.formatId),l&&(u||2==o.iReportExecuteMode)){const t=await this._queryPrintForBase16(o.templateId||"",o.formatId,o.params||"",o.authorizationKey);return(null==t?void 0:t.success)?r({filebase64:null==(n=null==t?void 0:t.map)?void 0:n.hex,isIreport:!0}):null==s?void 0:s({type:"queryPrintDataFailure",result:"error",message:"获取文件失败!"})}this.printDirect(o,(async t=>{t||s({result:"error",message:""});const e=this,a=await async function(t){const r=[],s=JSON.parse(t);if(!i(s))return await e._downloadPDF("");if(1===s.length)return await e._downloadPDF(s[0]||"");for(let t=0,i=s.length;t<i;t++)r.push(await e._downloadPDF(s[t]||""));return r}(t.filedir);r(a,t)}),(t=>s(t)),(t=>{console.log(t)}),"downloadPDF")}async print({templateId:t,formatId:e,params:i="",messageTimeout:r=0},s,a){const n=await this._testConnection();if(!this._handleResultTest(n,a))return!1;const o=await this.queryPrintData({templateId:t,formatId:e,params:i,messageTimeout:r},void 0,a);if(!o)return!1;const l=this.printFileData({formatId:e,file:o.file,printerName:o.printerName},void 0,a);if(!l)return!1;s&&s(l)}async queryPrintData({templateId:t,formatId:e,params:i="",messageTimeout:r=0},s,a){const n=await this._testConnection();if(!this._handleResultTest(n,a))return!1;const o=await this._handleEventQueryPrintData(t,e,i,r,a);return!!o&&(s&&s(o),o)}async printFileData({formatId:t,file:e,printerName:i="Default"},r,s){const a=await this._testConnection();if(!this._handleResultTest(a,s))return!1;const n=await this._callPrintWithFile({formatId:t,printname:i,file:e}),o=this._handleResult(n,s);return!!o&&(r&&r(o),o)}async editPrintFormat({templateId:t,formatId:e,params:i,token:r,messageTimeout:s=0},a,n){const o=await this._testConnection();if(!this._handleResultTest(o,n))return!1;const l=await this._handleEventEditFormat({templateId:t,formatId:e,params:i,token:r,messageTimeout:s}),c=this._handleResult(l,n);if(!c)return!1;a&&a(c)}async addPrintFormat({templateId:t,params:e,token:i},r,s){const a=await this._testConnection();if(!this._handleResultTest(a,s))return!1;const n=await this._handleEventEditFormat({templateId:t,params:e,token:i}),o=this._handleResult(n,s);if(!o)return!1;r&&r(o)}}export{I as Print};
@@ -1 +1 @@
1
- import{fabric as e}from"../../../../../shared/utils/fabricjs/index.js";import{drawLine as t,drawArrow as n,drawText as o,defaultTextStyle as i,drawPoint as r,drawTextAndIconGroup as l,defaultStyle as s,defaultRectStyle as a}from"../useDraw.js";import{useGrid as u}from"../useGrid.js";import{useBirthProcessCumputedPoint as c}from"../useCumputedPoint.js";import"../useEvent.js";import{getScaleInfo as d,drawScaleNumber as f,drawScaleLine as p}from"../useScaleColumn.js";import{useCommon as h}from"../useCommon.js";import"vue";import{getIndex as g,isEffectiveNode as m,getTime as v,getScaleNumberList as y}from"../../utils/index.js";import{cloneDeep as k,last as w,range as x}from"lodash-es";import"../temperature/useShadow.js";import"@vueuse/shared";import{format as b}from"date-fns";import"naive-ui";import"@vueuse/core";function j(j,C,P,S,E){const{computedX:X,computedY:G,getXValue:T,getYValue:A}=c(C),{getEqualXTypes:L,handleAddPrevent:Y,isGridLimit:M,setPrevAndNextPoint:I,getPointEventProps:H}=h(j,P,C),{xAxis:W,grid:D,originX:N,originY:O,xCellWidth:V,endY:R,startTime:$,leftAddAreaWidth:B,leftScales:F,rightScales:q,yCellHeight:z,endX:J,scaleValues:K,canvasWidth:Q,borderStyle:U,rightAddAreaWidth:Z,event:_,originYCervix:ee,other:te,canvasHeight:ne}=C,oe=k(K),ie=new Set;function re(){oe.filter((({showData:e=!0})=>e)).forEach(((e,l)=>{var s;const a=[],u=[],c=[];null==(s=e.data)||s.forEach(((s,d)=>{!function(s,d,f){let p,h;const{pointAttr:g={},lineAttr:m={},title:v="",key:y,type:k="circle",childbirthStyle:w={}}=e,x=e.data[f+1],b=ce(x,e);if(s&&b&&!d.breakpoint)h=t([...s,...b],{...m});else if(s&&!b&&!d.breakpoint){const n=ce(x,e);h=n?t([...s,...n],{...m}):null}let C,E;if(d.childbirth){const e=s[1]+z;C=n([s[0],s[1],e],w),c.push(C),E=o([s[0]+V/2,e-z/2],{value:String(d.childbirth),...i,originX:"left",originY:"center",...w}),c.push(E)}const X=u[f-1],G={origin:{data:d,title:v,key:y||"",dataIndex:l,index:f},leftLine:X,rightLine:h,arrowGroup:C,arrowGroupText:E,...g,...H()};s&&(X||(G.leftLine=null),p=r(k,{left:s[0],top:s[1],...G}));u.push(h),p&&(!function(e){_.hovered&&(e.on("mouseover",(()=>{ue(e,"hover")})),e.on("mouseout",(()=>{S.show=!1})));if(e.lockMovementX&&e.lockMovementY)return;e.on("moving",(()=>{ae(e),function(e){var t,n,o,i;null==(t=e.leftLine)||t.setCoords().set({x2:e.left,y2:e.top}),null==(n=e.rightLine)||n.setCoords().set({x1:e.left,y1:e.top}),null==(o=e.arrowGroup)||o.setCoords().set({left:e.left,top:e.top}),null==(i=e.arrowGroupText)||i.setCoords().set({left:e.left+V/2,top:e.top+z/2})}(e),_.hovered&&ue(e)})),e.on("mouseup",(t=>{if(S.show=!1,1===t.button){const{key:t}=e.origin,n={...e.origin,data:{...e.origin.data,time:T(e.left),value:A(t,e.top)}};j.value.discardActiveObject(),P("change",n),le(n,"change")}}))}(p),a.push(p),ie.add(p))}(ce(s,e),s,d)})),Promise.all(a).then((e=>{const t=u.filter((e=>e));I(e),Promise.all(c).then((n=>{j.value.add(...t,...e,...n),e.forEach((e=>{null==e||e.bringToFront()}))}))}))}))}function le(e,t="add"){const{dataIndex:n,data:o,index:i,key:r}=e,l=oe.find((e=>e.key===r));switch(t){case"remove":l.data.splice(i,1);break;case"change":l.data[i]=o;break;default:{const e=g(o.time,l.data);l.data.splice(e,0,o);break}}se()}function se(){var e;ie.size&&(null==(e=j.value)||e.remove(...function(e){const t=[];return e.forEach((e=>{e&&t.push(e),(null==e?void 0:e.leftLine)&&t.push(null==e?void 0:e.leftLine),(null==e?void 0:e.rightLine)&&t.push(null==e?void 0:e.rightLine),(null==e?void 0:e.arrowGroup)&&t.push(null==e?void 0:e.arrowGroup),(null==e?void 0:e.arrowGroupText)&&t.push(null==e?void 0:e.arrowGroupText)})),t}([...ie]))),ie.clear(),re()}function ae(e){const t=e.prevPoint?e.prevPoint.left:N,n=e.nextPoint?e.nextPoint.left:J;e.setCoords(),["cervix","fetalPresentation"].includes(e.origin.key)&&e.top<ee&&e.set("top",ee),e.top<O&&e.set("top",O),e.top>R&&e.set("top",R),e.left<t&&e.set("left",t),e.left>n&&e.set("left",n)}function ue(e,t="moving"){const{title:n,key:o,data:i}=e.origin;S.point={x:e.left,y:e.top},S.list=[`${n} ${"hover"===t?i.value:A(o,e.top)}`,`时间 ${T(e.left).slice(-5)}`],S.show=!0}function ce(e,t){if(m(e)&&function(e){const t=$+864e5,n=v(e);return n>=$&&n<=t}(e.time)){const n=X(e.time),o=G(t.key,t.range,e.value);return[n,o<O?O:o>R?R:o]}}function de(e,t){return e+1>t[1]?t[0]:e+1}return u(j,C),function(){const t=new e.Rect({...U,width:Q-B-Z-1,height:R-1,left:B,top:0,fill:"transparent"});j.value.add(t)}(),function(){function t(t,n="left"){let r="left"===n?B:J;t.forEach(((t,n)=>{const{range:l,spaceValue:u,width:c,title:h,titleStyle:g,key:m,position:v="center",spaceGridNumber:k=1,showNumber:w,showMaxMinNumber:x}=t,b=[],C=[],P=r+c/2,S=y(l,u),E=S.length,{lineXMain:X,lineXSub:G,textLeft:T}=d(v,r,c);S.forEach(((e,n)=>{const o=R-n*z*k,i=0===n?R-8:n!==S.length-1||O||ee&&"FHR"!==m?o:O+8;!w||(0===n||n===E-1)&&!x||b.push(f(String(e),t,T,i)),C.push(...p(t,n,X,G,o,z,O,E,1))}));const A=new e.Rect({...a,strokeWidth:.5,width:c,height:R,left:P,top:R/2}),L=o([P,O>0?O-z/2:z/2],{value:String(h),...i,...g}),Y=new e.Group([...C,...b,A,...L?[L]:[]],{objectCaching:!1,...s});j.value.add(Y),Y.sendToBack(),r+=c}))}t(F),t(q,"right")}(),function(){const{show:t,startTime:n,range:r=[0,23],position:l="top",style:a}=W.time,{show:u,range:c=[0,23],position:d,style:f={}}=W.processTime;if(t||u){const p=[],h=x(c[0],c[1]+1),g=[],m=[],v=z/2;for(let e=0;e<D.mainXCell;e++){if(t){const{textAlign:t="center"}=a,s=N+("center"===t?V/2:0),u=0===e&&"center"!==t?s+5:s,c=0===e?+n.slice(11,13):de(w(p),r);p.push(c);const d="top"===l?O-v:R+v;g.push(o([u+e*V,d],{value:String(c),...i,...a})),e===D.mainXCell-1&&"center"!==t&&g.push(o([J-1,d],{value:String(de(w(p),r)),...i,...a,originX:"center"!==t?"right":"center"}))}if(u&&e<=h.length){const{textAlign:t="center"}=f,n=N+("center"===t?V/2:0),r=0===e&&"center"!==t?n+5:n,l="top"===d?v:ne-v;m.push(o([r+e*V,l],{value:String(h[e]),...i,...f})),e===D.mainXCell-1&&"center"!==t&&m.push(o([J-1,l],{value:String(w(h)),...i,...a,originX:"center"!==t?"right":"center"}))}}const y=new e.Group([...g,...m],{objectCaching:!1,...s});j.value.add(y),j.value.sendToBack(y)}}(),function(){var e;const n=Object.values(te),o=[],i={},r=oe.find((e=>"cervix"===e.key&&e.show)),l=null==(e=null==r?void 0:r.data)?void 0:e.find((e=>3==+e.value));function s(e,t){const{key:n,range:o}=r||{},i=G(n,o,10),l=[0,t],s=[-t/e,0],a=[(R-i-t)/e,R-i],u=[J-N,e*(J-N)+t];let c=[],d=[];function f([n,o]){return Math.abs(o-e*n-t)<=1}function p([e,t]){const[n,o]=[...h([e,t])];return n>=N&&n<=J&&o>=i&&o<=R}function h([e,t]){return[N+e,R-t]}return f(l)&&p(l)&&(c=h(l)),f(s)&&p(s)&&(c=h(s)),f(a)&&p(a)&&(d=h(a)),f(u)&&p(u)&&(d=h(u)),[...c,...d]}n.forEach((e=>{if(!e.show)return;const{key:n}=e;switch(n){case"fetalPresentation":{const{range:i,show:r}=oe.find((e=>e.key===n));if(r){const r=G(n,i,0);o.push(t([N,r,J,r],{...e}))}break}case"alert":if(l){const{key:n,range:a}=r||{},u=216e5,c={time:b(new Date(v(l.time)+u),"yyyy-MM-dd HH:mm"),value:10},[d,f]=[X(l.time)-N,R-G(n,a,l.value)],[p,h]=[X(c.time)-N,R-G(n,a,c.value)],g=(h-f)/(p-d),m=f-d*g,y=s(g,m);y.length>0&&(o.push(t(y,{...e})),Object.assign(i,{k:g,b:m}))}break;case"handling":if(l){const{k:n,b:r}=i,a=144e5,u=s(n,r-(X(b(new Date(v(l.time)+a),"yyyy-MM-dd HH:mm"))-X(l.time))*n);u.length>0&&o.push(t(u,{...e}))}}})),j.value.add(...o)}(),re(),function(){function e(e,t){const n=oe.findIndex((t=>t.key===e.key));return{renderItem:()=>e.title,origin:{title:e.title,unit:e.unit,dataIndex:n,key:e.key},pointer:t}}C.event.evented&&j.value.on("mouse:up",(t=>{if(3===t.button){const{x:n=0,y:o=0}=t.pointer||{};n>=N&&n<=J&&o>=O&&o<=R&&(E.point={x:n,y:o},E.show=!0,t.target?(E.target=t.target,E.list=["删除节点"],[...ie].forEach((e=>{e.origin&&e.left===t.target.left&&e.top===t.target.top&&E.list.push({renderItem:()=>e.origin.title,origin:{...e.origin},mode:"remove",pointer:t.pointer})}))):(E.target=null,E.list=["新增节点"],oe.filter((e=>e.show)).forEach((i=>{if(!L([...ie],n,"key").includes(i.key)){if(["cervix","fetalPresentation"].includes(i.key)&&o<ee)return;E.list.push(e(i,t.pointer))}})),1===E.list.length&&(E.show=!1,Y("repeat"),console.log("当前时间段内无可新增节点"))))}}))}(),function(){const e=Q-Z/2;function t(e,t){if(!e.length)return;let o=O;const i=[];e.forEach((e=>{const n=e.title.split("").join("\n"),r=K.findIndex((t=>t.key===e.key)),{text:s,icon:a}=l(n,e,{text:{originY:"top",left:t,top:o},icon:{left:t,topY:o,originY:"top",origin:{type:e.type,dataIndex:r},...C.event}},"vertical");var u;o+=s.height+a.height+15,(u=a).on("moving",(()=>{u.set("originY","center"),M(u)?(ae(u),ue(u)):S.show=!1})),u.on("mouseup:before",(e=>{if(S.show=!1,0===e.e.button&&M(u))if(L([...ie],u.left,"key").includes(u.origin.key))Y("repeat");else{const e={data:{time:T(u.left),value:A(u.origin.key,u.top)},...u.origin};P("add",e),le(e)}!function(e){e.setCoords().set({originY:"top",left:e.originLeft,top:e.originTop})}(u)})),i.push(s,a)})),n(i),j.value.add(...i)}function n(e){const t=w(e),n=(R-O)/2,o=(t.height+t.top-O)/2;e.forEach((e=>{const t=e.top+n-o;e.set({top:t,originTop:t})}))}t(F,B/2),t(q,e)}(),{clickMenu:function({item:e,target:t}){const n={...e.origin};"remove"===e.mode?(P("remove",n),le(n,"remove")):(Object.assign(n,{data:{time:T(e.pointer.x),value:A(e.origin.key,e.pointer.y)}}),P("add",n),le(n))},redrawPoints:se}}export{j as useBirthProcess};
1
+ import{fabric as t}from"../../../../../shared/utils/fabricjs/index.js";import{drawLine as e,drawArrow as n,drawPoint as i,defaultStyle as o,drawText as r,defaultTextStyle as l,drawTextAndIconGroup as s,defaultRectStyle as a}from"../useDraw.js";import{useGrid as c}from"../useGrid.js";import{useBirthProcessCumputedPoint as u}from"../useCumputedPoint.js";import"../useEvent.js";import{getScaleInfo as d,drawScaleNumber as h,drawScaleLine as f}from"../useScaleColumn.js";import{useCommon as p}from"../useCommon.js";import"vue";import{getIndex as g,isEffectiveNode as m,getTime as v,getScaleNumberList as y}from"../../utils/index.js";import{cloneDeep as k,last as b,range as x}from"lodash-es";import"../temperature/useShadow.js";import"@vueuse/shared";import{format as w}from"date-fns";import"naive-ui";import"@vueuse/core";function S(S,C,j,P,I){const{computedX:E,computedY:T,getXValue:X,getYValue:A}=u(C),{getEqualXTypes:L,handleAddPrevent:Y,isGridLimit:M,setPrevAndNextPoint:H,getPointEventProps:z}=p(S,j,C),{xAxis:G,grid:W,originX:D,originY:N,xCellWidth:O,endY:R,startTime:V,leftAddAreaWidth:B,leftScales:F,rightScales:$,yCellHeight:q,endX:J,scaleValues:K,canvasWidth:Q,borderStyle:U,rightAddAreaWidth:Z,event:_,originYCervix:tt,other:et,canvasHeight:nt,scalebarBorder:it}=C,ot=k(K),rt=new Set;function lt(){ot.filter((({showData:t=!0})=>t)).forEach(((t,s)=>{var a;const c=[],u=[],d=[];null==(a=t.data)||a.forEach(((a,h)=>{!function(a,h,f){let p,g;const{pointAttr:m={},lineAttr:v={},title:y="",key:k,type:b="circle",childbirthStyle:x={}}=t,w=t.data[f+1],C=dt(w,t);if(a&&C&&!h.breakpoint)g=e([...a,...C],{...v});else if(a&&!C&&!h.breakpoint){const n=dt(w,t);g=n?e([...a,...n],{...v}):null}let I,E;if(h.childbirth){const{type:t="arrow",style:e={}}=x;if("arrow"===t){const t=a[1]+q;I=n([a[0],a[1],t],e)}else I=i(t,{left:a[0],top:a[1],...e,...o,hoverCursor:"default"});E=r([a[0]+O/2,a[1]+q/2],{value:String(h.childbirth),...l,originX:"left",originY:"center",fill:e.stroke||e.fill,fontSize:e.fontSize||l.fontSize}),I&&d.push(I),d.push(E)}const T=u[f-1],L={origin:{data:h,title:y,key:k||"",dataIndex:s,index:f},leftLine:T,rightLine:g,childbirthIcon:I,childbirthText:E,...m,...z()};a&&(T||(L.leftLine=null),p=i(b,{left:a[0],top:a[1],...L}));u.push(g),p&&(!function(t){_.hovered&&(t.on("mouseover",(()=>{ut(t,"hover")})),t.on("mouseout",(()=>{P.show=!1})));if(t.lockMovementX&&t.lockMovementY)return;t.on("moving",(()=>{ct(t),function(t){var e,n,i,o;null==(e=t.leftLine)||e.setCoords().set({x2:t.left,y2:t.top}),null==(n=t.rightLine)||n.setCoords().set({x1:t.left,y1:t.top}),null==(i=t.childbirthIcon)||i.setCoords().set({left:t.left,top:t.top}),null==(o=t.childbirthText)||o.setCoords().set({left:t.left+O/2,top:t.top+q/2})}(t),_.hovered&&ut(t)})),t.on("mouseup",(e=>{if(P.show=!1,1===e.button){const{key:e}=t.origin,n={...t.origin,data:{...t.origin.data,time:X(t.left),value:A(e,t.top)}};S.value.discardActiveObject(),j("change",n),st(n,"change")}}))}(p),c.push(p),rt.add(p))}(dt(a,t),a,h)})),Promise.all(c).then((t=>{const e=u.filter((t=>t));H(t),Promise.all(d).then((n=>{S.value.add(...e,...t,...n),t.forEach((t=>{null==t||t.bringToFront();const{childbirthIcon:e}=t;e&&Reflect.has(e,"zIndex")&&e.zIndex>0&&e.bringToFront()}))}))}))}))}function st(t,e="add"){const{dataIndex:n,data:i,index:o,key:r}=t,l=ot.find((t=>t.key===r));switch(e){case"remove":l.data.splice(o,1);break;case"change":l.data[o]=i;break;default:{const t=g(i.time,l.data);l.data.splice(t,0,i);break}}at()}function at(){var t;rt.size&&(null==(t=S.value)||t.remove(...function(t){const e=[];return t.forEach((t=>{t&&e.push(t),(null==t?void 0:t.leftLine)&&e.push(null==t?void 0:t.leftLine),(null==t?void 0:t.rightLine)&&e.push(null==t?void 0:t.rightLine),(null==t?void 0:t.childbirthIcon)&&e.push(null==t?void 0:t.childbirthIcon),(null==t?void 0:t.childbirthText)&&e.push(null==t?void 0:t.childbirthText)})),e}([...rt]))),rt.clear(),lt()}function ct(t){const e=t.prevPoint?t.prevPoint.left:D,n=t.nextPoint?t.nextPoint.left:J;t.setCoords(),["cervix","fetalPresentation"].includes(t.origin.key)&&t.top<tt&&t.set("top",tt),t.top<N&&t.set("top",N),t.top>R&&t.set("top",R),t.left<e&&t.set("left",e),t.left>n&&t.set("left",n)}function ut(t,e="moving"){const{title:n,key:i,data:o}=t.origin;P.point={x:t.left,y:t.top},P.list=[`${n} ${"hover"===e?o.value:A(i,t.top)}`,`时间 ${X(t.left).slice(-5)}`],P.show=!0}function dt(t,e){if(m(t)&&function(t){const e=V+864e5,n=v(t);return n>=V&&n<=e}(t.time)){const n=E(t.time),i=T(e.key,e.range,t.value);return[n,i<N?N:i>R?R:i]}}function ht(t,e){return t+1>e[1]?e[0]:t+1}return c(S,C),function(){const e=it?{width:Q-B-Z-1,left:B}:{width:J-D-($.length?0:1),left:D},n=new t.Rect({...U,height:R-1,top:0,fill:"transparent",...e});S.value.add(n)}(),function(){function e(e,n="left"){let i="left"===n?B:J;e.forEach(((e,n)=>{const{range:s,spaceValue:c,width:u,title:p,titleStyle:g,key:m,position:v="center",spaceGridNumber:k=1,showNumber:b,showMaxMinNumber:x}=e,w=[],C=[],j=i+u/2,P=y(s,c),I=P.length,{lineXMain:E,lineXSub:T,textLeft:X}=d(v,i,u);P.forEach(((t,n)=>{const i=R-n*q*k,o=0===n?R-8:n!==P.length-1||N||tt&&"FHR"!==m?i:N+8;!b||(0===n||n===I-1)&&!x||w.push(h(String(t),e,X,o)),C.push(...f(e,n,E,T,i,q,N,I,1))}));const A=[],L=it?new t.Rect({...a,strokeWidth:.5,width:u,height:R,left:j,top:R/2}):null;L&&A.push(L);const Y=r([j,N>0?N-q/2:q/2],{value:String(p),...l,...g});Y&&A.push(Y);const M=new t.Group([...C,...w,...A],{objectCaching:!1,...o});S.value.add(M),M.sendToBack(),i+=u}))}e(F),e($,"right")}(),function(){const{show:e,startTime:n,range:i=[0,23],position:s="top",style:a}=G.time,{show:c,range:u=[0,23],position:d,style:h={}}=G.processTime;if(e||c){const f=[],p=x(u[0],u[1]+1),g=[],m=[],v=q/2;for(let t=0;t<W.mainXCell;t++){if(e){const{textAlign:e="center"}=a,o=D+("center"===e?O/2:0),c=0===t&&"center"!==e?o+5:o,u=0===t?+n.slice(11,13):ht(b(f),i);f.push(u);const d="top"===s?N-v:R+v;g.push(r([c+t*O,d],{value:String(u),...l,...a})),t===W.mainXCell-1&&"center"!==e&&g.push(r([J-1,d],{value:String(ht(b(f),i)),...l,...a,originX:"center"!==e?"right":"center"}))}if(c&&t<=p.length){const{textAlign:e="center"}=h,n=D+("center"===e?O/2:0),i=0===t&&"center"!==e?n+5:n,o="top"===d?v:nt-v;m.push(r([i+t*O,o],{value:String(p[t]),...l,...h})),t===W.mainXCell-1&&"center"!==e&&m.push(r([J-1,o],{value:String(b(p)),...l,...a,originX:"center"!==e?"right":"center"}))}}const y=new t.Group([...g,...m],{objectCaching:!1,...o});S.value.add(y),S.value.sendToBack(y)}}(),function(){var t;const n=Object.values(et),i=[],o={},r=ot.find((t=>"cervix"===t.key&&t.show)),l=null==(t=null==r?void 0:r.data)?void 0:t.find((t=>3==+t.value));function s(t,e){const{key:n,range:i}=r||{},o=T(n,i,10),l=[0,e],s=[-e/t,0],a=[(R-o-e)/t,R-o],c=[J-D,t*(J-D)+e];let u=[],d=[];function h([n,i]){return Math.abs(i-t*n-e)<=1}function f([t,e]){const[n,i]=[...p([t,e])];return n>=D&&n<=J&&i>=o&&i<=R}function p([t,e]){return[D+t,R-e]}return h(l)&&f(l)&&(u=p(l)),h(s)&&f(s)&&(u=p(s)),h(a)&&f(a)&&(d=p(a)),h(c)&&f(c)&&(d=p(c)),[...u,...d]}n.forEach((t=>{if(!t.show)return;const{key:n}=t;switch(n){case"fetalPresentation":{const{range:o,show:r}=ot.find((t=>t.key===n));if(r){const r=T(n,o,0);i.push(e([D,r,J,r],{...t}))}break}case"alert":if(l){const{key:n,range:a}=r||{},c=216e5,u={time:w(new Date(v(l.time)+c),"yyyy-MM-dd HH:mm"),value:10},[d,h]=[E(l.time)-D,R-T(n,a,l.value)],[f,p]=[E(u.time)-D,R-T(n,a,u.value)],g=(p-h)/(f-d),m=h-d*g,y=s(g,m);y.length>0&&(i.push(e(y,{...t})),Object.assign(o,{k:g,b:m}))}break;case"handling":if(l){const{k:n,b:r}=o,a=144e5,c=s(n,r-(E(w(new Date(v(l.time)+a),"yyyy-MM-dd HH:mm"))-E(l.time))*n);c.length>0&&i.push(e(c,{...t}))}}})),S.value.add(...i)}(),lt(),function(){function t(t,e){const n=ot.findIndex((e=>e.key===t.key));return{renderItem:()=>t.title,origin:{title:t.title,unit:t.unit,dataIndex:n,key:t.key},pointer:e}}C.event.evented&&S.value.on("mouse:up",(e=>{if(3===e.button){const{x:n=0,y:i=0}=e.pointer||{};n>=D&&n<=J&&i>=N&&i<=R&&(I.point={x:n,y:i},I.show=!0,e.target?(I.target=e.target,I.list=["删除节点"],[...rt].forEach((t=>{t.origin&&t.left===e.target.left&&t.top===e.target.top&&I.list.push({renderItem:()=>t.origin.title,origin:{...t.origin},mode:"remove",pointer:e.pointer})}))):(I.target=null,I.list=["新增节点"],ot.filter((t=>t.show)).forEach((o=>{if(!L([...rt],n,"key").includes(o.key)){if(["cervix","fetalPresentation"].includes(o.key)&&i<tt)return;I.list.push(t(o,e.pointer))}})),1===I.list.length&&(I.show=!1,Y("repeat"),console.log("当前时间段内无可新增节点"))))}}))}(),function(){const t=Q-Z/2;function e(t,e){if(!t.length)return;let i=N;const o=[];t.forEach((t=>{const n=t.title.split("").join("\n"),r=K.findIndex((e=>e.key===t.key)),{text:l,icon:a}=s(n,t,{text:{originY:"top",left:e,top:i},icon:{left:e,topY:i,originY:"top",origin:{type:t.type,dataIndex:r},...C.event}},"vertical");var c;i+=l.height+a.height+15,(c=a).on("moving",(()=>{c.set("originY","center"),M(c)?(ct(c),ut(c)):P.show=!1})),c.on("mouseup:before",(t=>{if(P.show=!1,0===t.e.button&&M(c))if(L([...rt],c.left,"key").includes(c.origin.key))Y("repeat");else{const t={data:{time:X(c.left),value:A(c.origin.key,c.top)},...c.origin};j("add",t),st(t)}!function(t){t.setCoords().set({originY:"top",left:t.originLeft,top:t.originTop})}(c)})),o.push(l,a)})),n(o),S.value.add(...o)}function n(t){const e=b(t),n=(R-N)/2,i=(e.height+e.top-N)/2;t.forEach((t=>{const e=t.top+n-i;t.set({top:e,originTop:e})}))}e(F,B/2),e($,t)}(),{clickMenu:function({item:t,target:e}){const n={...t.origin};"remove"===t.mode?(j("remove",n),st(n,"remove")):(Object.assign(n,{data:{time:X(t.pointer.x),value:A(t.origin.key,t.pointer.y)}}),j("add",n),st(n))},redrawPoints:at}}export{S as useBirthProcess};
@@ -1 +1 @@
1
- import{reactive as e,computed as a,watch as t,toRefs as l}from"vue";import{defaultBorderStyle as u}from"../useDraw.js";import"../../../../../shared/utils/fabricjs/index.js";import"date-fns";import{getTime as r}from"../../utils/index.js";import"lodash-es";import"../useEvent.js";import"../temperature/useShadow.js";import"@vueuse/shared";import"naive-ui";import"@vueuse/core";import{useBirthProcess as i}from"./useBirthProcess.js";function s(s,n,d,o,v,c){const h=e({select:null,redrawPoints:null,clickMenu:null}),m=a((()=>n.data.scaleValues.filter((({layout:e="left",show:a=!0})=>"left"===e&&a)))),f=a((()=>n.data.scaleValues.filter((({layout:e="left",show:a=!0})=>"right"===e&&a)))),p=a((()=>{var e;return(null==(e=f.value)?void 0:e.length)?30:0})),g=a((()=>{var e;return 30+(null==(e=m.value)?void 0:e.reduce(((e,a)=>e+=a.width),0))})),x=a((()=>{var e;const{width:a}=n.data,t=null==(e=f.value)?void 0:e.reduce(((e,a)=>e+=a.width),0);return a-p.value-t})),w=a((()=>n.data.grid.mainXCell)),y=a((()=>{const e=n.data.grid.mainYCell||14;return n.data.scaleValues.find((e=>e.show&&"FHR"===e.key))||14!==e?e:10})),V=a((()=>(x.value-g.value)/w.value)),b=a((()=>{const{xAxis:e,height:a}=n.data,t=Object.values(e).reduce(((e,a)=>(a.show&&e++,e)),0);return a/(y.value+t)})),j=a((()=>{const{xAxis:e}=n.data,a=Object.values(e).reduce(((e,a)=>(a.show&&"top"===a.position&&e++,e)),0);return b.value*a})),A=a((()=>{var e;const{scaleValues:a}=n.data;if(!(null==(e=a.find((e=>"FHR"===e.key)))?void 0:e.show)&&!j.value)return j.value;const t=a.find((e=>"cervix"===e.key)),[,l]=(null==t?void 0:t.range)||[0,10],u=(null==t?void 0:t.spaceValue)||1;return k.value-l*u*b.value})),k=a((()=>{const{xAxis:e,height:a}=n.data,t=Object.values(e).reduce(((e,a)=>(a.show&&"bottom"===a.position&&e++,e)),0);return a-b.value*t})),C=a((()=>r(n.data.xAxis.time.startTime))),Y=a((()=>36e5/V.value)),S=a((()=>{const{scaleValues:e}=n.data,a=e.find((e=>"cervix"===e.key));return b.value/((null==a?void 0:a.spaceValue)||1)})),H=a((()=>{const{scaleValues:e}=n.data,a=e.find((e=>"FHR"===e.key));return b.value/((null==a?void 0:a.spaceValue)||10)})),P=a((()=>{const{scaleValues:e}=n.data,a=e.find((e=>"fetalPresentation"===e.key));return b.value/((null==a?void 0:a.spaceValue)||1)})),X=a((()=>{var e;return(null==(e=n.data.grid)?void 0:e.event)||{selectable:!0,evented:!0,hovered:!0}})),F=e({canvasWidth:n.data.width,canvasHeight:n.data.height,borderStyle:{...u,...n.data.borderStyle||{}},selectionStyle:n.data.selectionStyle||{},grid:n.data.grid,other:n.data.other,originX:g.value,endX:x.value,originY:j.value,endY:k.value,xCellWidth:V.value,yCellHeight:b.value,gridXNumber:w.value,gridYNumber:y.value,xAxis:n.data.xAxis,leftScales:m.value,rightScales:f.value,leftAddAreaWidth:30,rightAddAreaWidth:p.value,startTime:C.value,timeXCell:Y.value,cervixYCell:S.value,FHRYCell:H.value,fetalPresentationYCell:P.value,scaleValues:n.data.scaleValues,event:X.value,originYCervix:A.value});return t((()=>s.value),(e=>{e&&function(){const{clickMenu:e,redrawPoints:a}=i(s,F,d,v,c);h.redrawPoints=a,h.clickMenu=e}()}),{immediate:!0}),{propItems:F,...l(h)}}export{s as useBirthProcessChart};
1
+ import{reactive as e,computed as a,watch as t,toRefs as l}from"vue";import{defaultBorderStyle as r}from"../useDraw.js";import"../../../../../shared/utils/fabricjs/index.js";import"date-fns";import{getTime as u}from"../../utils/index.js";import"lodash-es";import"../useEvent.js";import"../temperature/useShadow.js";import"@vueuse/shared";import"naive-ui";import"@vueuse/core";import{useBirthProcess as i}from"./useBirthProcess.js";function s(s,d,n,o,v,c){const h=e({select:null,redrawPoints:null,clickMenu:null}),m=a((()=>d.data.scaleValues.map((e=>{var a;return{...e,width:null!=(a=e.width)?a:60}})).filter((({layout:e="left",show:a=!0})=>"left"===e&&a)))),f=a((()=>d.data.scaleValues.map((e=>{var a;return{...e,width:null!=(a=e.width)?a:60}})).filter((({layout:e="left",show:a=!0})=>"right"===e&&a)))),p=a((()=>{var e;return(null==(e=f.value)?void 0:e.length)?30:0})),g=a((()=>{var e;return 30+(null==(e=m.value)?void 0:e.reduce(((e,a)=>e+=a.width),0))})),w=a((()=>{var e;const{width:a}=d.data,t=null==(e=f.value)?void 0:e.reduce(((e,a)=>e+=a.width),0);return a-p.value-t})),x=a((()=>d.data.grid.mainXCell)),b=a((()=>{const e=d.data.grid.mainYCell||14;return d.data.scaleValues.find((e=>e.show&&"FHR"===e.key))||14!==e?e:10})),y=a((()=>(w.value-g.value)/x.value)),V=a((()=>{const{xAxis:e,height:a}=d.data,t=Object.values(e).reduce(((e,a)=>(a.show&&e++,e)),0);return a/(b.value+t)})),j=a((()=>{const{xAxis:e}=d.data,a=Object.values(e).reduce(((e,a)=>(a.show&&"top"===a.position&&e++,e)),0);return V.value*a})),A=a((()=>{var e;const{scaleValues:a}=d.data;if(!(null==(e=a.find((e=>"FHR"===e.key)))?void 0:e.show)&&!j.value)return j.value;const t=a.find((e=>"cervix"===e.key)),[,l]=(null==t?void 0:t.range)||[0,10],r=(null==t?void 0:t.spaceValue)||1;return k.value-l*r*V.value})),k=a((()=>{const{xAxis:e,height:a}=d.data,t=Object.values(e).reduce(((e,a)=>(a.show&&"bottom"===a.position&&e++,e)),0);return a-V.value*t})),C=a((()=>u(d.data.xAxis.time.startTime))),Y=a((()=>36e5/y.value)),S=a((()=>{const{scaleValues:e}=d.data,a=e.find((e=>"cervix"===e.key));return V.value/((null==a?void 0:a.spaceValue)||1)})),H=a((()=>{const{scaleValues:e}=d.data,a=e.find((e=>"FHR"===e.key));return V.value/((null==a?void 0:a.spaceValue)||10)})),P=a((()=>{const{scaleValues:e}=d.data,a=e.find((e=>"fetalPresentation"===e.key));return V.value/((null==a?void 0:a.spaceValue)||1)})),R=a((()=>{var e;return(null==(e=d.data.grid)?void 0:e.event)||{selectable:!0,evented:!0,hovered:!0}})),X=e({canvasWidth:d.data.width,canvasHeight:d.data.height,borderStyle:{...r,...d.data.borderStyle||{}},selectionStyle:d.data.selectionStyle||{},grid:d.data.grid,other:d.data.other,originX:g.value,endX:w.value,originY:j.value,endY:k.value,xCellWidth:y.value,yCellHeight:V.value,gridXNumber:x.value,gridYNumber:b.value,xAxis:d.data.xAxis,leftScales:m.value,rightScales:f.value,leftAddAreaWidth:30,rightAddAreaWidth:p.value,startTime:C.value,timeXCell:Y.value,cervixYCell:S.value,FHRYCell:H.value,fetalPresentationYCell:P.value,scaleValues:d.data.scaleValues,event:R.value,originYCervix:A.value,scalebarBorder:!Reflect.has(d.data,"scalebarBorder")||d.data.scalebarBorder});return t((()=>s.value),(e=>{e&&function(){const{clickMenu:e,redrawPoints:a}=i(s,X,n,v,c);h.redrawPoints=a,h.clickMenu=e}()}),{immediate:!0}),{propItems:X,...l(h)}}export{s as useBirthProcessChart};
@@ -1 +1 @@
1
- import{reactive as e,ref as t,computed as a,unref as r,onMounted as i,nextTick as o,onBeforeUnmount as l,watch as n,toRefs as u}from"vue";import{useDialog as s}from"naive-ui";import{defaultBorderStyle as d}from"../useDraw.js";import"../../../../../shared/utils/fabricjs/index.js";import{format as c}from"date-fns";import{getChildrenSize as p}from"../../utils/index.js";import{cloneDeep as m,range as v,flatten as h}from"lodash-es";import"../useEvent.js";import"../temperature/useShadow.js";import{OTHER_MENU as f}from"../../constants/index.js";import"@vueuse/shared";import"@vueuse/core";import{useTop as g}from"./useTop.js";import{useLeft as w}from"./useLeft.js";import{useCenter as y}from"./useCenter.js";import{useOther as b}from"./useOther.js";function x(x,j,C,Y,H,S,T){var D;const M=s(),k=e({redrawPoints:null,clickMenu:null}),A=t();let P=null;const X=p((null==(D=j.data.top)?void 0:D.treeData)||[]),G=a((()=>j.data.layout||{top:"drug",center:"xAxis",bottom:"intraoperatively"})),N=a((()=>{var e;return null!=(e=j.data.left.width)?e:0})),V=a((()=>{const{grid:e}=j.data;return e.mainXCell*e.subXCell})),L=a((()=>{const{grid:e}=j.data;return e.mainYCell*e.subYCell})),O=a((()=>{const{show:e=!0,tree:t={}}=j.data.top;if(!e)return 0;const{rowNumber:a=X}=t;return X<a?a:X})),E=a((()=>j.data.top.tree.cellHeight)),W=a((()=>E.value*O.value)),I=a((()=>ne(oe("drug")||"top"))),F=a((()=>I.value+W.value)),q=a((()=>{var e;return Date.parse((null==(e=j.data.xAxis)?void 0:e.startTime)||c(new Date,"yyyy-MM-dd HH:mm:ss"))})),z=a((()=>{const e=m(j.data.xAxis),{spaceValue:t,spaceTimeStamp:a}=e,r=v(V.value/t+1).map((r=>0===r?e.startTime:c(new Date(q.value+r*t*a),"yyyy-MM-dd HH:mm:ss")));return{...e,list:r,left:N.value}})),B=function(){const{show:e=!0,tree:t={}}=j.data.top;if(!e)return[];const a=m(j.data.top.treeData);let r=0;const{cellWidth:i,cellHeight:o}=j.data.top.tree,{rowNumber:l=X}=t;X<l&&a.push(...v(l-X).map((()=>({}))));return function e(t,a=0){t.forEach((t=>{var l;const n={top:r*o+I.value,left:a*i,width:i,height:o};if(r++,null==(l=t.children)?void 0:l.length){r--;const i=p(t.children);n.height=i*o,e(t.children,a+1)}else n.width=N.value-n.left;Object.assign(t,n)}))}(a),a}(),J=a((()=>ne(oe("xAxis")||"center"))),K=a((()=>{var e;const{width:t,right:a}=j.data;if(!a)return t;return t-(null!=(e=a.width)?e:0)})),Q=a((()=>ne(oe("intraoperatively")||"bottom"))),R=a((()=>{var e;const{show:t=!0,height:a}=(null==(e=j.data.other)?void 0:e.mark)||{};return t&&a?a:0})),U=a((()=>Q.value+(j.data.height-W.value-z.value.height-R.value))),Z=a((()=>(K.value-N.value)/V.value)),$=a((()=>(U.value-Q.value)/L.value)),_=a((()=>z.value.spaceTimeStamp/Z.value)),ee=a((()=>{const{scaleValues:e}=j.data;return h(e.map((e=>e.dataList.filter((e=>e.show)).map(((t,a)=>({...t,bigType:e.type,unit:e.unit,dataIndex:a}))))))})),te=a((()=>ue("pulse"))),ae=a((()=>ue("temperature"))),re=a((()=>{var e;return(null==(e=j.data.grid)?void 0:e.event)||{selectable:!0,evented:!0,hovered:!0}})),ie=e({canvasWidth:j.data.width,canvasHeight:j.data.height,borderStyle:{...d,...j.data.borderStyle},pointSelectionStyle:j.data.pointSelectionStyle||{},grid:j.data.grid,top:j.data.top,left:j.data.left,other:j.data.other,topGridYNumber:r(O),topGridYCellHeight:r(E),topGridOriginY:r(I),topGridEndY:r(F),treeData:B,xAxis:r(z),originYXAxis:r(J),startTime:r(q),timeXCell:r(_),gridXNumber:r(V),gridYNumber:r(L),xCellWidth:r(Z),yCellHeight:r($),originX:r(N),endX:r(K),originY:r(Q),endY:r(U),markHeight:r(R),itemList:r(ee),scaleValues:j.data.scaleValues,pulseYCell:r(te),temperatureYCell:r(ae),event:r(re),dialog:M});function oe(e){let t="";return Object.entries(G.value).some((([a,r])=>{if(r===e)return t=a,!0})),t}function le(e){const t=G.value[e],a=z.value.height;switch(t){case"drug":return W.value;case"xAxis":return a;default:return j.data.height-W.value-a}}function ne(e){switch(e){case"top":return 0;case"center":return le("top");default:return le("top")+le("center")}}function ue(e){const{scaleValues:t}=j.data,a=t.find((t=>t.type===e));return $.value*(a.spaceGridNumber||1)/(a.spaceValue||1)}return i((async()=>{await o(),g(x,ie,C,H);const{redrawPoints:e,clickMenu:t,moveLimit:a,setPopup:r,updateData:i,getGridPoints:l,getContainPoints:n,showDialog:u,removeCurrentSelection:s,pauseFlickerPoint:d}=y(x,ie,C,H,S,T);A.value=d,w(x,ie,C,H,a,r,i,l);const{clickMenu:c}=b(x,ie,C,H,S,a,n,u,s);k.redrawPoints=e,k.clickMenu=e=>{const{item:a}=e;a.type&&f.map((e=>e.type)).includes(a.type)?c(e):t(e)}})),l((()=>{A.value()})),T&&n((()=>null==H?void 0:H.point),(()=>{H.movable?(H.show=!0,P&&clearTimeout(P),P=setTimeout((()=>{H.show=!1,H.movable=!1}),3e3)):P&&clearTimeout(P)}),{deep:!0}),{propItems:ie,...u(k)}}export{x as useSurgicalAnesthesiaChart};
1
+ import{reactive as e,ref as t,computed as a,unref as r,onMounted as i,nextTick as o,onBeforeUnmount as l,watch as n,toRefs as u}from"vue";import{useDialog as s}from"naive-ui";import{defaultBorderStyle as d}from"../useDraw.js";import"../../../../../shared/utils/fabricjs/index.js";import{format as c}from"date-fns";import{getChildrenSize as p}from"../../utils/index.js";import{cloneDeep as m,range as v,flatten as h}from"lodash-es";import"../useEvent.js";import"../temperature/useShadow.js";import{OTHER_MENU as f}from"../../constants/index.js";import"@vueuse/shared";import"@vueuse/core";import{useTop as g}from"./useTop.js";import{useLeft as w}from"./useLeft.js";import{useCenter as y}from"./useCenter.js";import{useOther as b}from"./useOther.js";function x(x,j,C,Y,H,S,T){var D;const M=s(),k=e({redrawPoints:null,clickMenu:null}),A=t();let P=null;const X=p((null==(D=j.data.top)?void 0:D.treeData)||[]),G=a((()=>j.data.layout||{top:"drug",center:"xAxis",bottom:"intraoperatively"})),N=a((()=>{var e;return null!=(e=j.data.left.width)?e:0})),V=a((()=>{const{grid:e}=j.data;return e.mainXCell*e.subXCell})),L=a((()=>{const{grid:e}=j.data;return e.mainYCell*e.subYCell})),O=a((()=>{const{show:e=!0,tree:t={}}=j.data.top;if(!e)return 0;const{rowNumber:a=X}=t;return X<a?a:X})),E=a((()=>j.data.top.tree.cellHeight)),W=a((()=>E.value*O.value)),I=a((()=>ne(oe("drug")||"top"))),F=a((()=>I.value+W.value)),q=a((()=>{var e;return Date.parse((null==(e=j.data.xAxis)?void 0:e.startTime)||c(new Date,"yyyy-MM-dd HH:mm:ss"))})),z=a((()=>{const e=m(j.data.xAxis),{spaceValue:t,spaceTimeStamp:a}=e,r=v(V.value/t+1).map((r=>0===r?e.startTime:c(new Date(q.value+r*t*a),"yyyy-MM-dd HH:mm:ss")));return{...e,list:r,left:N.value}})),B=function(){const{show:e=!0,tree:t={}}=j.data.top;if(!e)return[];const a=m(j.data.top.treeData);let r=0;const{cellWidth:i,cellHeight:o}=j.data.top.tree,{rowNumber:l=X}=t;X<l&&a.push(...v(l-X).map((()=>({}))));return function e(t,a=0){t.forEach((t=>{var l;const n={top:r*o+I.value,left:a*i,width:i,height:o};if(r++,null==(l=t.children)?void 0:l.length){r--;const i=p(t.children);n.height=i*o,e(t.children,a+1)}else n.width=N.value-n.left;Object.assign(t,n)}))}(a),a}(),J=a((()=>ne(oe("xAxis")||"center"))),K=a((()=>{var e;const{width:t,right:a}=j.data;if(!a)return t;return t-(null!=(e=a.width)?e:0)})),Q=a((()=>ne(oe("intraoperatively")||"bottom"))),R=a((()=>{var e;const{show:t,height:a}=(null==(e=j.data.other)?void 0:e.mark)||{};return t&&a?a:0})),U=a((()=>Q.value+(j.data.height-W.value-z.value.height-R.value))),Z=a((()=>(K.value-N.value)/V.value)),$=a((()=>(U.value-Q.value)/L.value)),_=a((()=>z.value.spaceTimeStamp/Z.value)),ee=a((()=>{const{scaleValues:e}=j.data;return h(e.map((e=>e.dataList.filter((e=>e.show)).map(((t,a)=>({...t,bigType:e.type,unit:e.unit,dataIndex:a}))))))})),te=a((()=>ue("pulse"))),ae=a((()=>ue("temperature"))),re=a((()=>{var e;return(null==(e=j.data.grid)?void 0:e.event)||{selectable:!0,evented:!0,hovered:!0}})),ie=e({canvasWidth:j.data.width,canvasHeight:j.data.height,borderStyle:{...d,...j.data.borderStyle},pointSelectionStyle:j.data.pointSelectionStyle||{},grid:j.data.grid,top:j.data.top,left:j.data.left,other:j.data.other,topGridYNumber:r(O),topGridYCellHeight:r(E),topGridOriginY:r(I),topGridEndY:r(F),treeData:B,xAxis:r(z),originYXAxis:r(J),startTime:r(q),timeXCell:r(_),gridXNumber:r(V),gridYNumber:r(L),xCellWidth:r(Z),yCellHeight:r($),originX:r(N),endX:r(K),originY:r(Q),endY:r(U),markHeight:r(R),itemList:r(ee),scaleValues:j.data.scaleValues,pulseYCell:r(te),temperatureYCell:r(ae),event:r(re),dialog:M});function oe(e){let t="";return Object.entries(G.value).some((([a,r])=>{if(r===e)return t=a,!0})),t}function le(e){const t=G.value[e],a=z.value.height;switch(t){case"drug":return W.value;case"xAxis":return a;default:return j.data.height-W.value-a}}function ne(e){switch(e){case"top":return 0;case"center":return le("top");default:return le("top")+le("center")}}function ue(e){const{scaleValues:t}=j.data,a=t.find((t=>t.type===e));return $.value*(a.spaceGridNumber||1)/(a.spaceValue||1)}return i((async()=>{await o(),g(x,ie,C,H);const{redrawPoints:e,clickMenu:t,moveLimit:a,setPopup:r,updateData:i,getGridPoints:l,getContainPoints:n,showDialog:u,removeCurrentSelection:s,pauseFlickerPoint:d}=y(x,ie,C,H,S,T);A.value=d,w(x,ie,C,H,a,r,i,l);const{clickMenu:c}=b(x,ie,C,H,S,a,n,u,s);k.redrawPoints=e,k.clickMenu=e=>{const{item:a}=e;a.type&&f.map((e=>e.type)).includes(a.type)?c(e):t(e)}})),l((()=>{A.value()})),T&&n((()=>null==H?void 0:H.point),(()=>{H.movable?(H.show=!0,P&&clearTimeout(P),P=setTimeout((()=>{H.show=!1,H.movable=!1}),3e3)):P&&clearTimeout(P)}),{deep:!0}),{propItems:ie,...u(k)}}export{x as useSurgicalAnesthesiaChart};
@@ -55,6 +55,7 @@ declare const _default: import("vue").DefineComponent<{
55
55
  isShow: import("vue").Ref<boolean>;
56
56
  timePickerRef: import("vue").Ref<any>;
57
57
  inputValue: import("vue").Ref<any>;
58
+ newValue: string | undefined;
58
59
  inputProps: import("vue").ComputedRef<{
59
60
  style: string;
60
61
  } | {
@@ -65,11 +66,12 @@ declare const _default: import("vue").DefineComponent<{
65
66
  valueFormat: any;
66
67
  timeConfig: AnyObject;
67
68
  clickShortcutOption: (item: string) => void;
68
- onUpdateFormattedValue: (value: string | null) => void;
69
+ saveValue: (value: string | null) => void;
69
70
  isDisabled: (value: string) => boolean;
70
71
  onChange: () => void;
71
72
  onKeydown: (event: KeyboardEvent) => void;
72
73
  formatTime: (time: string) => string;
74
+ updateFormattedValue: () => void;
73
75
  NInput: any;
74
76
  NPopover: any;
75
77
  NSpace: any;
@@ -1 +1 @@
1
- import{defineComponent as e,useAttrs as t,inject as l,ref as a,computed as r,reactive as o,watch as u,nextTick as n,openBlock as i,createBlock as m,unref as d,withCtx as c,createVNode as v,mergeProps as s,isRef as f,createElementBlock as p,Fragment as h,renderList as b,createTextVNode as y,toDisplayString as g,createCommentVNode as k}from"vue";import{noop as w}from"lodash-es";import{NPopover as _,NInput as F,NSpace as S,NScrollbar as $,NButton as V}from"naive-ui";import{useIhoTableFormEvent as C}from"../../../../utils/index.js";import H from"../../../../../../time-picker/index.js";import{parse as x,isValid as D,format as O,getHours as j,getMinutes as E,getSeconds as A}from"date-fns";var I=e({__name:"editTime",props:{formattedValue:{type:String},column:{type:Object},row:{type:Object},rowIndex:{type:Number},shortcutOptions:{type:Array,default:()=>[]},ignoreGlobEmit:{type:Boolean,default:!1}},emits:["update:formattedValue","click"],setup(e,{emit:I}){const P=e,R=t(),{emitFormChangeWithParams:q=w}=P.ignoreGlobEmit?{}:C({...P,$table:l("$xetable")}),G=a(null),M=a(!1),N=a(),U=a(),W=r((()=>U.value&&L(U.value)?{style:"text-decoration: line-through"}:{})),z=r({get(){if(!U.value)return null;const e=x(U.value,T.valueFormat,new Date);return D(e)?O(e,T.valueFormat):P.formattedValue?Y(P.formattedValue):null},set(e){J(e)}}),{placeholder:B="请选择",valueFormat:K="HH:mm"}=R,T=o({...R,placeholder:B,valueFormat:K,format:K});function J(e){if(U.value=e||"",e&&L(e))return;const t=P.formattedValue;t!==e&&(I("update:formattedValue",e),q({oldValue:t}))}function L(e){var t,l,a;const r=x(e,T.format,new Date),o=j(r),u=E(r),n=A(r),i=null==(t=T.isHourDisabled)?void 0:t.call(T,o),m=null==(l=T.isMinuteDisabled)?void 0:l.call(T,u,o),d=null==(a=T.isSecondDisabled)?void 0:a.call(T,n,u,o);return i||m||d}function Q(){[T.valueFormat.replace(/[^\w]/g,""),T.valueFormat].some((e=>{const t=x(U.value,e,new Date);if(!U.value||D(t)){return J(U.value?O(t,T.valueFormat):null),!0}return!1}))}function X(e){var t;const{key:l}=e;"Enter"===l&&(null==(t=G.value)||t.blur(),M.value=!1)}function Y(e){var t;const l=T.valueFormat.match(/\W/)[0]||":",a=e.split(l).map(Number),r=`${a[0].toString().padStart(2,"0")}${l}${a[1].toString().padStart(2,"0")}`;return"HH:mm"===T.valueFormat?r:"HH:mm:ss"===T.valueFormat?`${r}${l}${(null!=(t=a[2])?t:0).toString().padStart(2,"0")}`:e}return u((()=>P.formattedValue),(e=>{if(!e)return"";U.value=Y(e)}),{immediate:!0}),u((()=>M.value),(async e=>{var t,l,a,r,o;e&&(await n(),null==(o=null==(r=null==(a=null==(l=null==(t=N.value)?void 0:t.$timePicker)?void 0:l.panelInstRef)?void 0:a.$el)?void 0:r.querySelectorAll(".n-time-picker-col"))||o.forEach((e=>{var t,l;return null==(l=null==(t=null==e?void 0:e.querySelector)?void 0:t.call(e,".n-time-picker-col__item--active"))?void 0:l.scrollIntoView()})))})),(t,l)=>(i(),m(d(_),{show:M.value,trigger:"click",showArrow:!1,placement:"bottom-start",style:{padding:"0"},onClickoutside:l[4]||(l[4]=()=>M.value=!1)},{trigger:c((()=>[v(d(F),{ref_key:"formRef",ref:G,clearable:"",placeholder:d(B),value:U.value,"onUpdate:value":l[0]||(l[0]=e=>U.value=e),valueModifiers:{trim:!0},"input-props":d(W),onClick:l[1]||(l[1]=()=>M.value=!0),onChange:Q,onKeydown:X},null,8,["placeholder","value","input-props"])])),default:c((()=>[v(d(S),null,{default:c((()=>[v(d(H),s({ref_key:"timePickerRef",ref:N,show:""},d(T),{class:"iho-table__time-picker",to:!1,"formatted-value":d(z),"onUpdate:formatted-value":l[2]||(l[2]=e=>f(z)?z.value=e:null),onConfirm:l[3]||(l[3]=()=>M.value=!1)}),null,16,["formatted-value"]),v(d($),{class:"iho-table__scrollbar"},{default:c((()=>[e.shortcutOptions.length?(i(),m(d(S),{key:0,vertical:"",wrap:!1},{default:c((()=>[(i(!0),p(h,null,b(e.shortcutOptions,(e=>(i(),m(d(V),{size:"tiny",key:e,disabled:L(e),onClick:t=>function(e){J(Y(e)),M.value=!1}(e)},{default:c((()=>[y(g(e),1)])),_:2},1032,["disabled","onClick"])))),128))])),_:1})):k("v-if",!0)])),_:1})])),_:1})])),_:1},8,["show"]))}});export{I as default};
1
+ import{defineComponent as e,useAttrs as t,inject as l,ref as a,computed as r,reactive as o,watch as u,nextTick as n,onBeforeUnmount as i,openBlock as m,createBlock as d,unref as v,withCtx as c,createVNode as s,mergeProps as f,isRef as p,createElementBlock as h,Fragment as b,renderList as y,createTextVNode as g,toDisplayString as w,createCommentVNode as k}from"vue";import{noop as _}from"lodash-es";import{NPopover as V,NInput as F,NSpace as S,NScrollbar as $,NButton as H}from"naive-ui";import{useIhoTableFormEvent as x}from"../../../../utils/index.js";import D from"../../../../../../time-picker/index.js";import{parse as C,isValid as O,format as j,getHours as E,getMinutes as A,getSeconds as I}from"date-fns";var P=e({__name:"editTime",props:{formattedValue:{type:String},column:{type:Object},row:{type:Object},rowIndex:{type:Number},shortcutOptions:{type:Array,default:()=>[]},ignoreGlobEmit:{type:Boolean,default:!1}},emits:["update:formattedValue","click"],setup(e,{emit:P}){const R=e,U=t(),{emitFormChangeWithParams:q=_}=R.ignoreGlobEmit?{}:x({...R,$table:l("$xetable")}),G=a(null),M=a(!1),N=a(),W=a();let z=R.formattedValue;const B=r((()=>W.value&&X(W.value)?{style:"text-decoration: line-through"}:{})),K=r({get(){if(!W.value)return null;const e=C(W.value,L.valueFormat,new Date);return O(e)?j(e,L.valueFormat):R.formattedValue?ee(R.formattedValue):null},set(e){Q(e)}}),{placeholder:T="请选择",valueFormat:J="HH:mm"}=U,L=o({...U,placeholder:T,valueFormat:J,format:J});function Q(e){if(W.value=e||"",e&&X(e))return;R.formattedValue!==e&&(z=e)}function X(e){var t,l,a;const r=C(e,L.format,new Date),o=E(r),u=A(r),n=I(r),i=null==(t=L.isHourDisabled)?void 0:t.call(L,o),m=null==(l=L.isMinuteDisabled)?void 0:l.call(L,u,o),d=null==(a=L.isSecondDisabled)?void 0:a.call(L,n,u,o);return i||m||d}function Y(){[L.valueFormat.replace(/[^\w]/g,""),L.valueFormat].some((e=>{const t=C(W.value,e,new Date);if(!W.value||O(t)){return Q(W.value?j(t,L.valueFormat):null),!0}return!1}))}function Z(e){var t;const{key:l}=e;"Enter"===l&&(null==(t=G.value)||t.blur(),M.value=!1)}function ee(e){var t;const l=L.valueFormat.match(/\W/)[0]||":",a=e.split(l).map(Number),r=`${a[0].toString().padStart(2,"0")}${l}${a[1].toString().padStart(2,"0")}`;return"HH:mm"===L.valueFormat?r:"HH:mm:ss"===L.valueFormat?`${r}${l}${(null!=(t=a[2])?t:0).toString().padStart(2,"0")}`:e}function te(){z&&X(z)||R.formattedValue!==z&&(P("update:formattedValue",z),q({oldValue:R.formattedValue}))}return u((()=>R.formattedValue),(e=>{if(!e)return"";W.value=ee(e)}),{immediate:!0}),u((()=>M.value),(async e=>{var t,l,a,r,o;e?(z=K.value,await n(),null==(o=null==(r=null==(a=null==(l=null==(t=N.value)?void 0:t.$timePicker)?void 0:l.panelInstRef)?void 0:a.$el)?void 0:r.querySelectorAll(".n-time-picker-col"))||o.forEach((e=>{var t,l;return null==(l=null==(t=null==e?void 0:e.querySelector)?void 0:t.call(e,".n-time-picker-col__item--active"))?void 0:l.scrollIntoView()}))):te()})),i((()=>{te()})),(t,l)=>(m(),d(v(V),{show:M.value,"onUpdate:show":l[3]||(l[3]=e=>M.value=e),trigger:"click",showArrow:!1,placement:"bottom-start",style:{padding:"0"}},{trigger:c((()=>[s(v(F),{ref_key:"formRef",ref:G,clearable:"",placeholder:v(T),value:W.value,"onUpdate:value":l[0]||(l[0]=e=>W.value=e),valueModifiers:{trim:!0},"input-props":v(B),onChange:Y,onKeydown:Z},null,8,["placeholder","value","input-props"])])),default:c((()=>[s(v(S),null,{default:c((()=>[s(v(D),f({ref_key:"timePickerRef",ref:N,show:""},v(L),{class:"iho-table__time-picker",to:!1,"formatted-value":v(K),"onUpdate:formatted-value":l[1]||(l[1]=e=>p(K)?K.value=e:null),onConfirm:l[2]||(l[2]=()=>M.value=!1)}),null,16,["formatted-value"]),s(v($),{class:"iho-table__scrollbar"},{default:c((()=>[e.shortcutOptions.length?(m(),d(v(S),{key:0,vertical:"",wrap:!1},{default:c((()=>[(m(!0),h(b,null,y(e.shortcutOptions,(e=>(m(),d(v(H),{size:"tiny",key:e,disabled:X(e),onClick:t=>function(e){Q(ee(e)),M.value=!1}(e)},{default:c((()=>[g(w(e),1)])),_:2},1032,["disabled","onClick"])))),128))])),_:1})):k("v-if",!0)])),_:1})])),_:1})])),_:1},8,["show"]))}});export{P as default};
@@ -1 +1 @@
1
- import{traverse as e,findAncestor as n,getStringWidth as t}from"../../../../../../shared/utils/index.js";import{isString as r,isNumber as i,constant as o,isFunction as a,noop as l,range as d,property as u}from"lodash-es";import{IhoTableRenderHelper as c}from"../../../utils/index.js";import{VERTICAL_CELL_TYPE as f}from"./constants.js";function s(e){var n;return!!(null==(n=e.verticalConfig)?void 0:n.enable)}function h(e){return!!r(e)&&e.startsWith("header_")}function p(e){return!!r(e)&&e.startsWith("body_")}function _(e){var n;return r(e)?+(null!=(n=e.split("_")[1])?n:-1):-1}function m(n,t){const r=[];return e(n,((e,n,o)=>{e.parent=o,e.children||(!function(e,n){let t=e,r=n;if(!e.parent)return e[`header_${n}`]=e.title,void d(n+1).forEach((t=>{e[`header_${t}_colspan`]=t===n?n+1:0,e[`header_${t}_rowspan`]=t===n?1:0}));for(;t;)e[`header_${r}`]=t.title,e[`header_${r}_rowspan`]=i(t),e[`header_${r}_colspan`]=1,r--,t=t.parent}(e,t),r.push(e))})),r.forEach(((e,n)=>{const i=r[n-1];i&&Object.entries(e).forEach((([n,r])=>{n.match(/^header_(\d+)$/)&&r===i[n]&&r&&n!==`header_${t}`&&(e[`${n}_colspan`]=0,e[`${n}_rowspan`]=0)}))})),r;function i(n){if(!n.children)return 1;let t=0;return e(n.children,(e=>{e.children||t++})),t}}function g({row:e,column:n}){var t,r;return h(n.field)?{rowspan:null!=(t=e[n.field+"_rowspan"])?t:1,colspan:null!=(r=e[n.field+"_colspan"])?r:1}:{colspan:1,rowspan:1}}const x=({cell:e}={})=>{const n=e&&e.querySelector("input,.n-input__input-el,.n-input__textarea-el");return n&&n.click(),n};function w(n,r){let i=120;return e(r,((e,r,o,a)=>{a===n&&(i=Math.max(i,t(e.title||"")+20+(c.hasTitlePrefix(e)?20:0)))})),Math.ceil(i)}function $(e,n,t){const r=T(t);let u=r.getTableConfig("verticalConfig.headerWidth");u="auto"===u?w:i(u)?o(u):a(u)?u:w;let c=r.getTableConfig("verticalConfig.bodyWidth");c=i(c)?o(c):a(c)?c:l;let s=r.getTableConfig("verticalConfig.bodyMinWidth");return s=i(s)?o(s):a(s)?s:o(120),[...d(n+1).map((e=>({field:`header_${e}`,title:`header_${e}`,width:u(e,t.originalFieldList),fixed:"left",editRender:{name:f,props:{},enable:!1}}))),...e.map(((e,n)=>({field:`body_${n}`,title:`body_${n}`,minWidth:s(n),width:c(n),editRender:{name:f,props:{},enable:!0,autofocus:x}})))]}function y(e){const t=n(e.target,(e=>"TD"===e.tagName||"TH"===e.tagName));if(!t)return;const r=t.className.match(/(body|header)_(\d+)/);if(!r)return;const[i,o,a]=r;return{fieldKey:i,type:o,sequence:+a}}function b(e){return u("originalField")(e)}function v(e,n){return u(`originalData.${n}`)(e)}function I(e,n){const t=_(n.field),r=b(e);return{row:v(e,t),rowIndex:t,$rowIndex:t,column:r,fixed:r.fixed,type:r.type}}function C(n){const t=[];return e(n,(e=>{"left"===e.fixed&&t.push(e)})),t}function T(e){return{getOriginDataByColumn(n){const{originalData:t=[]}=e;return t[_(n.field)]},getTableConfig:n=>u(n)(e.originalTableConfig)}}function D(e,n){return new Proxy({},{get(t,r){var i;if("originalField"===r)return e;if("originalData"===r)return a(n)?n():n;if(h(r))return e[r];if(p(r)){const t=_(r);return"seq"===e.type?t+1:null==(i=n[t])?void 0:i[e.field]}return t[r]},set(t,r,i){if(!h(r)){const t=_(r);t>=0&&n[t]&&(n[t][e.field]=i)}return!0}})}function W({$columnIndex:e,$rowIndex:n,column:t,columnIndex:r,row:i,rowIndex:o,type:a,_columnIndex:l,_rowIndex:d},u){var c;if(t){const f=a;if(a=h(t.field)?"header":"body",i){const s=_(t.field);t=b(i),i="header"===a?void 0:v(i,s),l=r=e="header"===f?n||0:((null==(c=u.fixedLeftVerticalData)?void 0:c.length)||0)+(n||0),d=o=n="header"===a?-1:s}}return{column:t,row:i,_columnIndex:l,_rowIndex:d,columnIndex:r,rowIndex:o,$columnIndex:e,$rowIndex:n,type:a}}x.toString=()=>"input,.n-input__input-el";export{W as basicParamsConvert,m as bindHeaderInfoAndFlatten,D as createDataProxy,$ as createVerticalFieldList,T as createVerticalStateHandler,C as findFixedLeftFields,_ as getHeaderDepthByField,I as getOriginBasePayload,b as getOriginFieldFromRowData,v as getOriginRowFromRowData,g as getSpanInfo,y as getVerticalInfoFromEvent,p as isVerticalBody,h as isVerticalHeader,s as isVerticalTable};
1
+ import{traverse as e,findAncestor as n,getStringWidth as t}from"../../../../../../shared/utils/index.js";import{isString as r,isNumber as i,constant as o,isFunction as a,noop as l,range as d,property as u}from"lodash-es";import{IhoTableRenderHelper as c}from"../../../utils/index.js";import{VERTICAL_CELL_TYPE as f}from"./constants.js";function s(e){var n;return!!(null==(n=e.verticalConfig)?void 0:n.enable)}function h(e){return!!r(e)&&e.startsWith("header_")}function p(e){return!!r(e)&&e.startsWith("body_")}function _(e){var n;return r(e)?+(null!=(n=e.split("_")[1])?n:-1):-1}function m(n,t){const r=[];return e(n,((n,i,o)=>{n.parent=o,n.children||(!function(n,t){if(!n.parent)return n[`header_${t}`]=n.title,void d(t+1).forEach((e=>{n[`header_${e}_colspan`]=e===t?t+1:0,n[`header_${e}_rowspan`]=e===t?1:0}));let r=0,i=n;const o=[n];for(;i.parent;)r++,i=i.parent,o.unshift(i);d(t+1).forEach((i=>{var a,l;const d=o[i];if(!d)return n[`header_${i}`]="",n[`header_${i}_colspan`]=0,void(n[`header_${i}_rowspan`]=0);n[`header_${i}`]=null!=(l=null==(a=o[i])?void 0:a.title)?l:"",n[`header_${i}_colspan`]=i<r?1:t-r+1,n[`header_${i}_rowspan`]=function(n){if(!n.children)return 1;let t=0;return e(n.children,(e=>{e.children||t++})),t}(d)}))}(n,t),r.push(n))})),r.forEach(((e,n)=>{const i=r[n-1];i&&Object.entries(e).forEach((([n,r])=>{n.match(/^header_(\d+)$/)&&r===i[n]&&r&&n!==`header_${t}`&&(e[`${n}_colspan`]=0,e[`${n}_rowspan`]=0)}))})),r}function g({row:e,column:n}){var t,r;return h(n.field)?{rowspan:null!=(t=e[n.field+"_rowspan"])?t:1,colspan:null!=(r=e[n.field+"_colspan"])?r:1}:{colspan:1,rowspan:1}}const x=({cell:e}={})=>{const n=e&&e.querySelector("input,.n-input__input-el,.n-input__textarea-el");return n&&n.click(),n};function $(n,r){let i=120;return e(r,((e,r,o,a)=>{a===n&&(i=Math.max(i,t(e.title||"")+20+(c.hasTitlePrefix(e)?20:0)))})),Math.ceil(i)}function w(e,n,t){const r=T(t);let u=r.getTableConfig("verticalConfig.headerWidth");u="auto"===u?$:i(u)?o(u):a(u)?u:$;let c=r.getTableConfig("verticalConfig.bodyWidth");c=i(c)?o(c):a(c)?c:l;let s=r.getTableConfig("verticalConfig.bodyMinWidth");return s=i(s)?o(s):a(s)?s:o(120),[...d(n+1).map((e=>({field:`header_${e}`,title:`header_${e}`,width:u(e,t.originalFieldList),fixed:"left",editRender:{name:f,props:{},enable:!1}}))),...e.map(((e,n)=>({field:`body_${n}`,title:`body_${n}`,minWidth:s(n),width:c(n),editRender:{name:f,props:{},enable:!0,autofocus:x}})))]}function v(e){const t=n(e.target,(e=>"TD"===e.tagName||"TH"===e.tagName));if(!t)return;const r=t.className.match(/(body|header)_(\d+)/);if(!r)return;const[i,o,a]=r;return{fieldKey:i,type:o,sequence:+a}}function y(e){return u("originalField")(e)}function b(e,n){return u(`originalData.${n}`)(e)}function I(e,n){const t=_(n.field),r=y(e);return{row:b(e,t),rowIndex:t,$rowIndex:t,column:r,fixed:r.fixed,type:r.type}}function C(n){const t=[];return e(n,(e=>{"left"===e.fixed&&t.push(e)})),t}function T(e){return{getOriginDataByColumn(n){const{originalData:t=[]}=e;return t[_(n.field)]},getTableConfig:n=>u(n)(e.originalTableConfig)}}function D(e,n){return new Proxy({},{get(t,r){var i;if("originalField"===r)return e;if("originalData"===r)return a(n)?n():n;if(h(r))return e[r];if(p(r)){const t=_(r);return"seq"===e.type?t+1:null==(i=n[t])?void 0:i[e.field]}return t[r]},set(t,r,i){if(!h(r)){const t=_(r);t>=0&&n[t]&&(n[t][e.field]=i)}return!0}})}function W({$columnIndex:e,$rowIndex:n,column:t,columnIndex:r,row:i,rowIndex:o,type:a,_columnIndex:l,_rowIndex:d},u){var c;if(t){const f=a;if(a=h(t.field)?"header":"body",i){const s=_(t.field);t=y(i),i="header"===a?void 0:b(i,s),l=r=e="header"===f?n||0:((null==(c=u.fixedLeftVerticalData)?void 0:c.length)||0)+(n||0),d=o=n="header"===a?-1:s}}return{column:t,row:i,_columnIndex:l,_rowIndex:d,columnIndex:r,rowIndex:o,$columnIndex:e,$rowIndex:n,type:a}}x.toString=()=>"input,.n-input__input-el";export{W as basicParamsConvert,m as bindHeaderInfoAndFlatten,D as createDataProxy,w as createVerticalFieldList,T as createVerticalStateHandler,C as findFixedLeftFields,_ as getHeaderDepthByField,I as getOriginBasePayload,y as getOriginFieldFromRowData,b as getOriginRowFromRowData,g as getSpanInfo,v as getVerticalInfoFromEvent,p as isVerticalBody,h as isVerticalHeader,s as isVerticalTable};
@@ -1 +1 @@
1
- .iho-table{height:100%;position:relative}.iho-table .vxe-header--column{font-weight:400;text-shadow:0 0 1px}.iho-table .vxe-body--column.col--drag{cursor:move}.iho-table .vxe-table.size--mini{font-size:14px}.iho-table .vxe-table.size--mini .vxe-body--column:not(.col--ellipsis),.iho-table .vxe-table.size--mini .vxe-footer--column:not(.col--ellipsis),.iho-table .vxe-table.size--mini .vxe-header--column:not(.col--ellipsis){padding:4px 0}.iho-table .vxe-table.size--mini .vxe-sort--asc-btn{top:-2px}.iho-table .vxe-table.size--mini .vxe-sort--desc-btn{bottom:0}.iho-table__headerWrapper{display:inline-flex;flex-wrap:nowrap}.iho-table__boldCell{font-weight:700}.iho-table .vxe-table .vxe-table--header-wrapper,.iho-table .vxe-table.vxe-table--render-default{color:#212121}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar{background-color:transparent;height:10px;width:10px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#b2b2b2;border:3px dashed transparent;border-radius:5px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb:hover,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb:hover{background:#b2b2b2}.iho-table .vxe-table--empty-content{height:100%;width:100%}.iho-table .vxe-table--empty-content>div,.iho-table .vxe-tree-cell{height:100%}.iho-table .vxe-table--header{background-color:#f2f2f2}.iho-table .vxe-table--header .checkbox-cell--disable{border:2px solid #c0c4cc;border-radius:50%;box-sizing:border-box;cursor:not-allowed;display:inline-block;height:18px;left:-2px;position:relative;top:3px;width:18px}.iho-table .vxe-table--header .checkbox-cell--disable:before{background-color:#c0c4cc;content:"";height:16px;left:50%;position:absolute;top:-2px;transform:translate(-60%) rotate(-45deg);width:2px}.iho-table .vxe-footer--row .vxe-footer--column>.vxe-cell .vxe-cell--item{height:30px;line-height:30px}.iho-table .vxe-table--render-default .vxe-body--column.col--selected{box-shadow:inset 0 0 0 2px var(--c-primary-color)}.iho-table .vxe-table--render-default .vxe-body--row.row--hover,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--stripe{background-color:var(--c-hover-color)}.iho-table .vxe-table--render-default .vxe-body--row.row--stripe{background-color:var(--c-stripe-color)}.iho-table .vxe-table--render-default .vxe-body--row.row--checked,.iho-table .vxe-table--render-default .vxe-body--row.row--current,.iho-table .vxe-table--render-default .vxe-body--row.row--radio{background-color:var(--c-primary-color-opacity2);text-shadow:0 0 1px}.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--checked,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--current,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--radio{background-color:var(--c-primary-color-opacity3);text-shadow:0 0 1px}.iho-table .vxe-body--expanded-column,.iho-table .vxe-table--border-line{border-color:var(--c-border-color)!important}.iho-table .vxe-table--footer-wrapper{border-top-color:var(--c-border-color)!important}.iho-table .border--default .vxe-body--column,.iho-table .border--default .vxe-footer--column,.iho-table .border--default .vxe-header--column,.iho-table .border--inner .vxe-body--column,.iho-table .border--inner .vxe-footer--column,.iho-table .border--inner .vxe-header--column{background-image:linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .border--full .vxe-body--column,.iho-table .border--full .vxe-footer--column,.iho-table .border--full .vxe-header--column{background-image:linear-gradient(var(--c-border-color),var(--c-border-color)),linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .border--default .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--full .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--inner .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--outer .vxe-header--row:last-child .vxe-header--gutter{background-image:linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .vxe-table--header-border-line{border-bottom-color:var(--c-border-color)!important}.iho-table .vxe-table--fixed-left-wrapper.scrolling--middle{box-shadow:7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .vxe-table--fixed-right-wrapper.scrolling--middle{box-shadow:-7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .icon-dot{background:var(--table-icon-color);box-shadow:0 2px 4px 0 var(--table-icon-shadow)}.iho-table .icon-dot,.iho-table .icon-dot-red{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-red{background:red;box-shadow:0 2px 4px 0 rgba(255,0,0,.5)}.iho-table .icon-dot-blue{background:blue;box-shadow:0 2px 4px 0 rgba(0,0,255,.5)}.iho-table .icon-dot-blue,.iho-table .icon-dot-green{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-green{background:green;box-shadow:0 2px 4px 0 rgba(0,128,0,.5)}.iho-table .icon-dot-gray{background:gray;box-shadow:0 2px 4px 0 hsla(0,0%,50%,.5)}.iho-table .icon-dot-gray,.iho-table .icon-dot-yellow{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-yellow{background:#ff0;box-shadow:0 2px 4px 0 rgba(255,255,0,.5)}.iho-table .icon-dot-resolved{background:#36be8c;box-shadow:0 2px 4px 0 rgba(54,190,140,.5)}.iho-table .icon-dot-huifu,.iho-table .icon-dot-resolved{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-huifu{background:#42d0f6;box-shadow:0 2px 4px 0 rgba(66,208,246,.5)}.iho-table .icon-dot-close{background:#718391;box-shadow:0 2px 4px 0 rgba(113,131,145,.5)}.iho-table .icon-dot-audit,.iho-table .icon-dot-close{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-audit{background:#f4ba32;box-shadow:0 2px 4px 0 rgba(244,186,50,.5)}.iho-table .icon-dot-design{background:#927ce1;box-shadow:0 2px 4px 0 rgba(146,124,225,.5)}.iho-table .icon-dot-design,.iho-table .icon-dot-develop{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-develop{background:#4eb0ef;box-shadow:0 2px 4px 0 rgba(78,176,239,.5)}.iho-table .icon-dot-develop-complete{background:#6381f9;border-radius:50%;box-shadow:0 2px 4px 0 rgba(99,129,249,.5);display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .is--filter-active .vxe-cell--filter .vxe-filter--btn{color:var(--c-primary-color)}.iho-table__filterIcon{cursor:pointer;padding:0 4px}.iho-table__filterIcon:hover{opacity:.7}.iho-table__filterIcon.is-active{color:var(--c-primary-color)}.iho-table__filterWrapper{display:flex;flex-direction:column;gap:8px;margin:8px 12px;width:240px}.iho-table__filterCheckAllWrapper{display:flex;justify-content:space-between}.iho-table__filterCheckAllWrapper>div{flex:1}.iho-table__filterButton{align-items:center;border-radius:4px;cursor:pointer;display:flex;height:30px;padding:0 8px}.iho-table__filterButton--active{color:var(--c-primary-color)}.iho-table__filterButton:hover{background:rgba(0,0,0,.05)}.iho-table__filterListWrapper{border:1px solid rgba(0,0,0,.05);overflow-x:hidden}.iho-table__filterListItem{align-items:center;border-radius:4px;display:flex;padding:0 8px}.iho-table__filterListItem:hover{background:var(--c-primary-color-opacity2)}.iho-table__filterListItem .n-checkbox,.iho-table__filterListItem .n-radio{width:100%}.iho-table__filterListItem>*{padding:5px 0}.iho-table__filterListItemContent{overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap;width:190px}.iho-table__filterFooter{display:flex;justify-content:space-between}.iho-table__time-picker{position:unset}.iho-table__time-picker .n-input{display:none}.iho-table__time-picker .v-binder-follower-container{height:auto;position:unset}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content{position:unset;transform:none!important}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content .n-time-picker-panel{box-shadow:none}.iho-table__scrollbar{margin:8px 8px 8px 0;max-height:255px}.iho-table .variable-height .vxe-cell,.iho-table .variable-height .vxe-cell--tree-node,.iho-table .variable-height .vxe-tree-cell{line-height:1.3;max-height:fit-content!important;white-space:break-spaces!important}.iho-table__selectMenu .n-scrollbar-rail__scrollbar{display:none!important}.iho-table__selectMenu .n-virtual-list::-webkit-scrollbar,.iho-table__selectMenu .n-virtual-list::-webkit-scrollbar-thumb{display:unset!important;height:6px;width:6px}.iho-table__selectMenu .n-virtual-list::-webkit-scrollbar-thumb{background:#bfbfbf;border-radius:4px}.iho-table__selectMenu .v-vl-items{min-width:100%;width:max-content}.iho-table__selectOption .n-base-select-option__content{overflow:visible!important;text-overflow:unset!important;word-break:keep-all!important}.iho-table__selectOptionWrapper{align-items:center;display:flex}.iho-select-menu-width{width:var(--iho-select-menu-width)!important}.iho-table .is--checked.vxe-checkbox,.iho-table .is--checked.vxe-checkbox .vxe-checkbox--icon,.iho-table .is--checked.vxe-custom--option,.iho-table .is--checked.vxe-custom--option .vxe-checkbox--icon,.iho-table .is--checked.vxe-export--panel-column-option,.iho-table .is--checked.vxe-export--panel-column-option .vxe-checkbox--icon,.iho-table .is--checked.vxe-table--filter-option,.iho-table .is--checked.vxe-table--filter-option .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-checkbox,.iho-table .is--indeterminate.vxe-checkbox .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-custom--option,.iho-table .is--indeterminate.vxe-custom--option .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-export--panel-column-option,.iho-table .is--indeterminate.vxe-export--panel-column-option .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-table--filter-option,.iho-table .is--indeterminate.vxe-table--filter-option .vxe-checkbox--icon,.iho-table .vxe-checkbox:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-custom--option:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-export--panel-column-option:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-table .vxe-sort--asc-btn.sort--active,.iho-table .vxe-table .vxe-sort--desc-btn.sort--active,.iho-table .vxe-table--filter-option:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-table--render-default .is--checked.vxe-cell--checkbox,.iho-table .vxe-table--render-default .is--checked.vxe-cell--checkbox .vxe-checkbox--icon,.iho-table .vxe-table--render-default .is--indeterminate.vxe-cell--checkbox,.iho-table .vxe-table--render-default .is--indeterminate.vxe-cell--checkbox .vxe-checkbox--icon,.iho-table .vxe-table--render-default .vxe-cell--checkbox:not(.is--disabled):hover .vxe-checkbox--icon{color:var(--c-primary-color)}.iho-table .vxe-header--column [annotation-hover-show=true]{visibility:hidden}.iho-table .vxe-header--column:hover [annotation-hover-show=true]{visibility:visible}@font-face{font-family:iho-table-iconfont;src:url(iconfont.ttf) format("truetype")}.iho-table .iho-table--iconfont{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:iho-table-iconfont!important;font-size:15px;font-style:normal}.iho-table .iho-table-icon-filter{display:inline-block;font-size:17px;transform:translateY(-1px);vertical-align:middle}.iho-table .iho-table-icon-filter:before{content:"\c2001"}.iho-table .iho-table-icon-date-filter{display:inline-block;transform:translateY(-1px)}.iho-table .iho-table-icon-date-filter:before{content:"\c2002"}.iho-table .row--custom{background-color:var(--row-background-color)}.iho-table__colorAndIcon{background-color:var(--color-and-icon-background-color-type);color:var(--color-and-icon-color-type)}.iho-table__htmlRender *{display:inline!important}.iho-table__ellipsis{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.iho-table .vxe-grid[vertical] .vxe-table--header-wrapper.body--wrapper{background:transparent}.iho-table .vxe-grid[vertical] .vxe-cell{min-height:var(--iho-table-vertical-table-min-height,unset)}.iho-table__pagerScrollWrapper{background:#fff;height:30px;overflow:auto;position:absolute;right:1px;width:9px;z-index:3000}.iho-table__pagerScrollWrapper::-webkit-scrollbar{background-color:transparent;height:8px;width:8px}.iho-table__pagerScrollWrapper::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#b2b2b2;border:2px dashed transparent;border-radius:5px}.iho-table__pagerScrollWrapper::-webkit-scrollbar-thumb:hover{background:#b2b2b2}.iho-table--fixed-left,.iho-table--fixed-right{position:sticky!important;width:calc(var(--iho-table-fixed-width)*1px);z-index:5}.iho-table--fixed-left.vxe-header--column .vxe-resizable.is--line:before,.iho-table--fixed-right.vxe-header--column .vxe-resizable.is--line:before{width:2px}.iho-table--fixed-left{left:calc(var(--iho-table-fixed-left)*1px + 1px)}.iho-table--fixed-right.vxe-header--column{right:calc(var(--iho-table-fixed-right)*1px + var(--c-scrollbar-width))}.iho-table--fixed-right.vxe-body--column{right:calc(var(--iho-table-fixed-right)*1px)}.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-left.vxe-body--column,.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-right.vxe-body--column{background-color:#fff}.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-left.vxe-header--column,.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-right.vxe-header--column{background-color:var(--c-head-bg-color)}.iho-table tr.row--hover .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--hover.row--stripe .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--stripe .iho-table--fixed-right.vxe-body--column{background-color:var(--c-hover-color)}.iho-table tr.row--stripe .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--stripe .iho-table--fixed-right.vxe-body--column{background-color:var(--c-stripe-color)}.iho-table tr.row--checked .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--checked .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--current .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--current .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--radio .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--radio .iho-table--fixed-right.vxe-body--column{background-color:var(--c-primary-color-opacity2)}.iho-table tr.row--hover.row--checked .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--checked .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--hover.row--current .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--current .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--hover.row--radio .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--radio .iho-table--fixed-right.vxe-body--column{background-color:var(--c-primary-color-opacity3)}.iho-table__fixedLeftBorderLeft{border-left:1px solid var(--c-border-color);height:calc(100% - 8px);left:0;overflow:hidden;position:absolute;width:0;z-index:5}.iho-table__fixedLeftShadow{height:calc(100% - 8px);position:absolute;top:0;width:3px;z-index:5}.iho-table__fixedLeftShadow.scrolling--middle{box-shadow:4px 3px 4px 0 rgba(0,0,0,.12)}.iho-table__fixedLeftBorderTop{background:var(--c-border-color);height:1px;left:0;position:absolute;top:0;z-index:6}.iho-table__fixedRightBorderLeft{border-left:1px solid var(--c-border-color);height:calc(100% - 8px);overflow:hidden;position:absolute;top:0;width:3px;z-index:5}.iho-table__fixedRightBorderLeft.scrolling--middle{box-shadow:-4px 3px 4px 0 rgba(0,0,0,.12)}.iho-table__fixedRightBorderTop{background:var(--c-border-color);height:1px;position:absolute;right:0;top:0;z-index:6}.iho-table__fixedRightBorderTop:after{background:var(--c-head-bg-color);content:"";height:var(--c-header-height);position:absolute;right:1px;top:1px;width:calc(var(--c-scrollbar-width) - 1px)}
1
+ .iho-table{height:100%;position:relative}.iho-table .vxe-header--column{font-weight:400;text-shadow:0 0 1px}.iho-table .vxe-body--column.col--drag{cursor:move}.iho-table .vxe-table.size--mini{font-size:14px}.iho-table .vxe-table.size--mini .vxe-body--column:not(.col--ellipsis),.iho-table .vxe-table.size--mini .vxe-footer--column:not(.col--ellipsis),.iho-table .vxe-table.size--mini .vxe-header--column:not(.col--ellipsis){padding:4px 0}.iho-table .vxe-table.size--mini .vxe-sort--asc-btn{top:-2px}.iho-table .vxe-table.size--mini .vxe-sort--desc-btn{bottom:0}.iho-table__headerWrapper{display:inline-flex;flex-wrap:nowrap}.iho-table__boldCell{font-weight:700}.iho-table .vxe-table .vxe-table--header-wrapper,.iho-table .vxe-table.vxe-table--render-default{color:#212121}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar{background-color:transparent;height:10px;width:10px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#b2b2b2;border:3px dashed transparent;border-radius:5px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb:hover,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb:hover{background:#b2b2b2}.iho-table .vxe-table--empty-content{height:100%;width:100%}.iho-table .vxe-table--empty-content>div,.iho-table .vxe-tree-cell{height:100%}.iho-table .vxe-table--header{background-color:var(--c-head-bg-color)}.iho-table .vxe-table--header .checkbox-cell--disable{border:2px solid #c0c4cc;border-radius:50%;box-sizing:border-box;cursor:not-allowed;display:inline-block;height:18px;left:-2px;position:relative;top:3px;width:18px}.iho-table .vxe-table--header .checkbox-cell--disable:before{background-color:#c0c4cc;content:"";height:16px;left:50%;position:absolute;top:-2px;transform:translate(-60%) rotate(-45deg);width:2px}.iho-table .vxe-footer--row .vxe-footer--column>.vxe-cell .vxe-cell--item{height:30px;line-height:30px}.iho-table .vxe-table--render-default .vxe-body--column.col--selected{box-shadow:inset 0 0 0 2px var(--c-primary-color)}.iho-table .vxe-table--render-default .vxe-body--row.row--hover,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--stripe{background-color:var(--c-hover-color)}.iho-table .vxe-table--render-default .vxe-body--row.row--stripe{background-color:var(--c-stripe-color)}.iho-table .vxe-table--render-default .vxe-body--row.row--checked,.iho-table .vxe-table--render-default .vxe-body--row.row--current,.iho-table .vxe-table--render-default .vxe-body--row.row--radio{background-color:var(--c-primary-color-opacity2);text-shadow:0 0 1px}.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--checked,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--current,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--radio{background-color:var(--c-primary-color-opacity3);text-shadow:0 0 1px}.iho-table .vxe-body--expanded-column,.iho-table .vxe-table--border-line{border-color:var(--c-border-color)!important}.iho-table .vxe-table--footer-wrapper{border-top-color:var(--c-border-color)!important}.iho-table .border--default .vxe-body--column,.iho-table .border--default .vxe-footer--column,.iho-table .border--default .vxe-header--column,.iho-table .border--inner .vxe-body--column,.iho-table .border--inner .vxe-footer--column,.iho-table .border--inner .vxe-header--column{background-image:linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .border--full .vxe-body--column,.iho-table .border--full .vxe-footer--column,.iho-table .border--full .vxe-header--column{background-image:linear-gradient(var(--c-border-color),var(--c-border-color)),linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .border--default .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--full .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--inner .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--outer .vxe-header--row:last-child .vxe-header--gutter{background-image:linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .vxe-table--header-border-line{border-bottom-color:var(--c-border-color)!important}.iho-table .vxe-table--fixed-left-wrapper.scrolling--middle{box-shadow:7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .vxe-table--fixed-right-wrapper.scrolling--middle{box-shadow:-7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .icon-dot{background:var(--table-icon-color);box-shadow:0 2px 4px 0 var(--table-icon-shadow)}.iho-table .icon-dot,.iho-table .icon-dot-red{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-red{background:red;box-shadow:0 2px 4px 0 rgba(255,0,0,.5)}.iho-table .icon-dot-blue{background:blue;box-shadow:0 2px 4px 0 rgba(0,0,255,.5)}.iho-table .icon-dot-blue,.iho-table .icon-dot-green{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-green{background:green;box-shadow:0 2px 4px 0 rgba(0,128,0,.5)}.iho-table .icon-dot-gray{background:gray;box-shadow:0 2px 4px 0 hsla(0,0%,50%,.5)}.iho-table .icon-dot-gray,.iho-table .icon-dot-yellow{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-yellow{background:#ff0;box-shadow:0 2px 4px 0 rgba(255,255,0,.5)}.iho-table .icon-dot-resolved{background:#36be8c;box-shadow:0 2px 4px 0 rgba(54,190,140,.5)}.iho-table .icon-dot-huifu,.iho-table .icon-dot-resolved{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-huifu{background:#42d0f6;box-shadow:0 2px 4px 0 rgba(66,208,246,.5)}.iho-table .icon-dot-close{background:#718391;box-shadow:0 2px 4px 0 rgba(113,131,145,.5)}.iho-table .icon-dot-audit,.iho-table .icon-dot-close{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-audit{background:#f4ba32;box-shadow:0 2px 4px 0 rgba(244,186,50,.5)}.iho-table .icon-dot-design{background:#927ce1;box-shadow:0 2px 4px 0 rgba(146,124,225,.5)}.iho-table .icon-dot-design,.iho-table .icon-dot-develop{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-develop{background:#4eb0ef;box-shadow:0 2px 4px 0 rgba(78,176,239,.5)}.iho-table .icon-dot-develop-complete{background:#6381f9;border-radius:50%;box-shadow:0 2px 4px 0 rgba(99,129,249,.5);display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .is--filter-active .vxe-cell--filter .vxe-filter--btn{color:var(--c-primary-color)}.iho-table__filterIcon{cursor:pointer;padding:0 4px}.iho-table__filterIcon:hover{opacity:.7}.iho-table__filterIcon.is-active{color:var(--c-primary-color)}.iho-table__filterWrapper{display:flex;flex-direction:column;gap:8px;margin:8px 12px;width:240px}.iho-table__filterCheckAllWrapper{display:flex;justify-content:space-between}.iho-table__filterCheckAllWrapper>div{flex:1}.iho-table__filterButton{align-items:center;border-radius:4px;cursor:pointer;display:flex;height:30px;padding:0 8px}.iho-table__filterButton--active{color:var(--c-primary-color)}.iho-table__filterButton:hover{background:rgba(0,0,0,.05)}.iho-table__filterListWrapper{border:1px solid rgba(0,0,0,.05);overflow-x:hidden}.iho-table__filterListItem{align-items:center;border-radius:4px;display:flex;padding:0 8px}.iho-table__filterListItem:hover{background:var(--c-primary-color-opacity2)}.iho-table__filterListItem .n-checkbox,.iho-table__filterListItem .n-radio{width:100%}.iho-table__filterListItem>*{padding:5px 0}.iho-table__filterListItemContent{overflow:hidden;text-align:left;text-overflow:ellipsis;white-space:nowrap;width:190px}.iho-table__filterFooter{display:flex;justify-content:space-between}.iho-table__time-picker{position:unset}.iho-table__time-picker .n-input{display:none}.iho-table__time-picker .v-binder-follower-container{height:auto;position:unset}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content{position:unset;transform:none!important}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content .n-time-picker-panel{box-shadow:none}.iho-table__scrollbar{margin:8px 8px 8px 0;max-height:255px}.iho-table .variable-height .vxe-cell,.iho-table .variable-height .vxe-cell--tree-node,.iho-table .variable-height .vxe-tree-cell{line-height:1.3;max-height:fit-content!important;white-space:break-spaces!important}.iho-table__selectMenu .n-scrollbar-rail__scrollbar{display:none!important}.iho-table__selectMenu .n-virtual-list::-webkit-scrollbar,.iho-table__selectMenu .n-virtual-list::-webkit-scrollbar-thumb{display:unset!important;height:6px;width:6px}.iho-table__selectMenu .n-virtual-list::-webkit-scrollbar-thumb{background:#bfbfbf;border-radius:4px}.iho-table__selectMenu .v-vl-items{min-width:100%;width:max-content}.iho-table__selectOption .n-base-select-option__content{overflow:visible!important;text-overflow:unset!important;word-break:keep-all!important}.iho-table__selectOptionWrapper{align-items:center;display:flex}.iho-select-menu-width{width:var(--iho-select-menu-width)!important}.iho-table .is--checked.vxe-checkbox,.iho-table .is--checked.vxe-checkbox .vxe-checkbox--icon,.iho-table .is--checked.vxe-custom--option,.iho-table .is--checked.vxe-custom--option .vxe-checkbox--icon,.iho-table .is--checked.vxe-export--panel-column-option,.iho-table .is--checked.vxe-export--panel-column-option .vxe-checkbox--icon,.iho-table .is--checked.vxe-table--filter-option,.iho-table .is--checked.vxe-table--filter-option .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-checkbox,.iho-table .is--indeterminate.vxe-checkbox .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-custom--option,.iho-table .is--indeterminate.vxe-custom--option .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-export--panel-column-option,.iho-table .is--indeterminate.vxe-export--panel-column-option .vxe-checkbox--icon,.iho-table .is--indeterminate.vxe-table--filter-option,.iho-table .is--indeterminate.vxe-table--filter-option .vxe-checkbox--icon,.iho-table .vxe-checkbox:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-custom--option:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-export--panel-column-option:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-table .vxe-sort--asc-btn.sort--active,.iho-table .vxe-table .vxe-sort--desc-btn.sort--active,.iho-table .vxe-table--filter-option:not(.is--disabled):hover .vxe-checkbox--icon,.iho-table .vxe-table--render-default .is--checked.vxe-cell--checkbox,.iho-table .vxe-table--render-default .is--checked.vxe-cell--checkbox .vxe-checkbox--icon,.iho-table .vxe-table--render-default .is--indeterminate.vxe-cell--checkbox,.iho-table .vxe-table--render-default .is--indeterminate.vxe-cell--checkbox .vxe-checkbox--icon,.iho-table .vxe-table--render-default .vxe-cell--checkbox:not(.is--disabled):hover .vxe-checkbox--icon{color:var(--c-primary-color)}.iho-table .vxe-header--column [annotation-hover-show=true]{visibility:hidden}.iho-table .vxe-header--column:hover [annotation-hover-show=true]{visibility:visible}@font-face{font-family:iho-table-iconfont;src:url(iconfont.ttf) format("truetype")}.iho-table .iho-table--iconfont{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:iho-table-iconfont!important;font-size:15px;font-style:normal}.iho-table .iho-table-icon-filter{display:inline-block;font-size:17px;transform:translateY(-1px);vertical-align:middle}.iho-table .iho-table-icon-filter:before{content:"\c2001"}.iho-table .iho-table-icon-date-filter{display:inline-block;transform:translateY(-1px)}.iho-table .iho-table-icon-date-filter:before{content:"\c2002"}.iho-table .row--custom{background-color:var(--row-background-color)}.iho-table__colorAndIcon{background-color:var(--color-and-icon-background-color-type);color:var(--color-and-icon-color-type)}.iho-table__htmlRender *{display:inline!important}.iho-table__ellipsis{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.iho-table .vxe-grid[vertical] .vxe-table--header-wrapper.body--wrapper{background:transparent}.iho-table .vxe-grid[vertical] .vxe-cell{min-height:var(--iho-table-vertical-table-min-height,unset)}.iho-table__pagerScrollWrapper{background:#fff;height:30px;overflow:auto;position:absolute;right:1px;width:9px;z-index:3000}.iho-table__pagerScrollWrapper::-webkit-scrollbar{background-color:transparent;height:8px;width:8px}.iho-table__pagerScrollWrapper::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#b2b2b2;border:2px dashed transparent;border-radius:5px}.iho-table__pagerScrollWrapper::-webkit-scrollbar-thumb:hover{background:#b2b2b2}.iho-table--fixed-left,.iho-table--fixed-right{position:sticky!important;width:calc(var(--iho-table-fixed-width)*1px);z-index:5}.iho-table--fixed-left.vxe-header--column .vxe-resizable.is--line:before,.iho-table--fixed-right.vxe-header--column .vxe-resizable.is--line:before{width:2px}.iho-table--fixed-left{left:calc(var(--iho-table-fixed-left)*1px + 1px)}.iho-table--fixed-right.vxe-header--column{right:calc(var(--iho-table-fixed-right)*1px + var(--c-scrollbar-width))}.iho-table--fixed-right.vxe-body--column{right:calc(var(--iho-table-fixed-right)*1px)}.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-left.vxe-body--column,.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-right.vxe-body--column{background-color:#fff}.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-left.vxe-header--column,.iho-table tr:not(.row--current,.row--hover,.row--checked,.row--radio) .iho-table--fixed-right.vxe-header--column{background-color:var(--c-head-bg-color)}.iho-table tr.row--hover .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--hover.row--stripe .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--stripe .iho-table--fixed-right.vxe-body--column{background-color:var(--c-hover-color)}.iho-table tr.row--stripe .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--stripe .iho-table--fixed-right.vxe-body--column{background-color:var(--c-stripe-color)}.iho-table tr.row--checked .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--checked .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--current .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--current .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--radio .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--radio .iho-table--fixed-right.vxe-body--column{background-color:var(--c-primary-color-opacity2)}.iho-table tr.row--hover.row--checked .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--checked .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--hover.row--current .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--current .iho-table--fixed-right.vxe-body--column,.iho-table tr.row--hover.row--radio .iho-table--fixed-left.vxe-body--column,.iho-table tr.row--hover.row--radio .iho-table--fixed-right.vxe-body--column{background-color:var(--c-primary-color-opacity3)}.iho-table__fixedLeftBorderLeft{border-left:1px solid var(--c-border-color);height:calc(100% - 8px);left:0;overflow:hidden;position:absolute;width:0;z-index:5}.iho-table__fixedLeftShadow{height:calc(100% - 8px);position:absolute;top:0;width:3px;z-index:5}.iho-table__fixedLeftShadow.scrolling--middle{box-shadow:4px 3px 4px 0 rgba(0,0,0,.12)}.iho-table__fixedLeftBorderTop{background:var(--c-border-color);height:1px;left:0;position:absolute;top:0;z-index:6}.iho-table__fixedRightBorderLeft{border-left:1px solid var(--c-border-color);height:calc(100% - 8px);overflow:hidden;position:absolute;top:0;width:3px;z-index:5}.iho-table__fixedRightBorderLeft.scrolling--middle{box-shadow:-4px 3px 4px 0 rgba(0,0,0,.12)}.iho-table__fixedRightBorderTop{background:var(--c-border-color);height:1px;position:absolute;right:0;top:0;z-index:6}.iho-table__fixedRightBorderTop:after{background:var(--c-head-bg-color);content:"";height:var(--c-header-height);position:absolute;right:1px;top:1px;width:calc(var(--c-scrollbar-width) - 1px)}