From ce1cc10e518ddac71cfefd433f8a6af9fb46ed40 Mon Sep 17 00:00:00 2001 From: lixiaojun <1287241240@qq.com> Date: 星期五, 27 九月 2024 12:01:02 +0800 Subject: [PATCH] 更改事件名称 --- WinFrmUI/Yw.WinFrmUI.Bimface.Core/bimface/js/CustomLabels.js | 16 +++++++++------- 1 files changed, 9 insertions(+), 7 deletions(-) diff --git a/WinFrmUI/Yw.WinFrmUI.Bimface.Core/bimface/js/CustomLabels.js b/WinFrmUI/Yw.WinFrmUI.Bimface.Core/bimface/js/CustomLabels.js index 3250bd6..6c50e67 100644 --- a/WinFrmUI/Yw.WinFrmUI.Bimface.Core/bimface/js/CustomLabels.js +++ b/WinFrmUI/Yw.WinFrmUI.Bimface.Core/bimface/js/CustomLabels.js @@ -30,22 +30,21 @@ content.style.padding = '2px'; content.style.borderWidth = '1px'; content.style.borderRadius = '3px'; - content.style.background = color; + content.style.background = '#32D3A6'; content.innerHTML = getTdHtml(item.data); content.style.color = '#FFFFFF'; content.style.fontSize = '10px'; //content.style.textAlign = 'center'; content.style.lineHeight = '14px'; - let config = new Glodon.Bimface.Plugins.Drawable.CustomItemConfig(); config.content = content; config.viewer = _viewer; config.opacity = 1; - config.worldPosition = item.position; - + config.worldPosition = _modeler.getBoundingBoxById(item.id).min; let customLabelItem = new Glodon.Bimface.Plugins.Drawable.CustomItem(config); _drawableContainer.addItem(customLabelItem); } + //娓呴櫎鑷畾涔夋爣绛� function clearCustomLabels() { @@ -60,10 +59,13 @@ if (data == null || data.length < 1) { return ''; } - let html = '<table>' + let html = '<table>'; data.forEach(d => { html += '<tr><td style="width:50px">' + d.name + '</td><td style="width:40px">' + d.value + '</td><td>' + d.unit + '</td></tr>' - }) - return html += '</table>' + }); + return html += '</table>'; } + + + -- Gitblit v1.9.3