From d27266ab7ae02b144605dffd7aded88b06c207bb Mon Sep 17 00:00:00 2001 From: zyy <1787816799@qq.com> Date: Mon, 12 Oct 2020 13:04:13 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E7=BA=BF=E6=AE=B5=E7=94=BB?= =?UTF-8?q?=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...sdfzxcg85039.png => iscs_kongzhixiang.png} | Bin 2249 -> 2270 bytes src/iscs/constant/deviceRender.js | 2 +- src/iscs/shape/line.js | 24 +++--- src/iscs/shape/picture.js | 52 +++++++------ .../iscs/iscsDraw/icscComponents/line.vue | 28 ++++--- .../iscs/iscsDraw/icscComponents/picture.vue | 71 +++++++++--------- 6 files changed, 96 insertions(+), 81 deletions(-) rename src/assets/iscs_picture/{sdfzxcg85039.png => iscs_kongzhixiang.png} (51%) diff --git a/src/assets/iscs_picture/sdfzxcg85039.png b/src/assets/iscs_picture/iscs_kongzhixiang.png similarity index 51% rename from src/assets/iscs_picture/sdfzxcg85039.png rename to src/assets/iscs_picture/iscs_kongzhixiang.png index 4a85d2131b7a530f325b36e1e38886c0ae305f81..d2590b473883c6f3f8cb22d9fdf1def8130905e0 100644 GIT binary patch delta 649 zcmX>pcu#PG1ryt;jaHpZe1-4{oxn{WEQPe~D<7QhSz7UUN^#iwDM9rwoPWRLT{7jxqCNdOP?ybiNu+4Rjc}MD%$~=YQMM7S^-B&rUe!ow|^{o~LzL#HTTuEDZ zrcY2DBD9d_l$9W*l)`s(d;?rwebE7|hUAe{+HX2s~Z=T-G@yGywnrHUgXg delta 727 zcmV;|0x1375y=sdI06Owu{wzY4lp?_GBH#!HaajkIx#hq(E=Y1FgYzUF;p=&Ixsjo zF*TF^0(p}~1tznd1406muLfCvhXR@&0007YNkl?TzX%5Jj(_wg5_S5%iRr z=!qgyLOSsNc+Wgz`7@K<@rZk*h+PV)eCUWh3E5GeC&R| z<2Vl7Za36o(pUi9xT~2x#@X}vbJ>x8C{2OPzIyEA@c_^e*pe5SIk4Y7l`VjKVt3M%xnZ`-!N!-Rd`iviyIS83E@&ct5H?0!e% zz4t@=X9)|TKp_+;gaUe7CVcYz?K{f;v#A#oR_DCaxI}IFfCW_{ae;~?_b;Ms0d8uuzA!4zi_r8&Tv-DPGxhoU627VaJ3=^!PdS!xjd4Tfufiw573fI7sY} { @@ -37,9 +37,9 @@ export default class line extends Group { }); }); if (model.gradualShow == 'level') { - strokeColor = new zrender.LinearGradient(1, 1, 0, 1, offsetList); + fillColor = new zrender.LinearGradient(1, 1, 0, 1, offsetList); } else { - strokeColor = new zrender.LinearGradient(1, 1, 1, 0, offsetList); + fillColor = new zrender.LinearGradient(1, 1, 1, 0, offsetList); } } const modelPoints = []; @@ -52,17 +52,21 @@ export default class line extends Group { }); this.iscsLine = new Polyline({ zlevel: model.zlevel, - z: model.z, - z2: model.z2||0, + z: model.z, + z2: model.z2 || 0, draggable: false, shape: { points: modelPoints }, style: { lineWidth: this.model.lineWidth, - stroke: strokeColor + stroke: this.model.fillColor } }); + console.log(this.model.fill); + if (fillColor) { + this.iscsLine.setStyle('fill', fillColor); + } if (model.classify == 'dashed') { this.iscsLine.setStyle('lineDash', [8, 6]); } @@ -75,8 +79,8 @@ export default class line extends Group { } this.arrows = new Polygon({ zlevel: model.zlevel, - z: model.z, - z2: model.z2||0, + z: model.z, + z2: model.z2 || 0, origin: [0, 0], rotation: rotation, shape: { @@ -103,8 +107,8 @@ export default class line extends Group { const y = model.points[this.model.points.length - 1].y - model.points[this.model.points.length - 2].y; this.arrows = new Polygon({ zlevel: model.zlevel, - z: model.z, - z2: model.z2||0, + z: model.z, + z2: model.z2 || 0, origin: [x, y], rotation: rotation, shape: { diff --git a/src/iscs/shape/picture.js b/src/iscs/shape/picture.js index a3953db31..3a782430b 100644 --- a/src/iscs/shape/picture.js +++ b/src/iscs/shape/picture.js @@ -20,35 +20,37 @@ import blowerRedRight from '@/assets/iscs_picture/gufengji-red-r.png'; import blowerGrayRight from '@/assets/iscs_picture/gufengji-gray-r.png'; import iscsAPF from '@/assets/iscs_picture/iscs_APF.png'; import drum from '@/assets/iscs_picture/drum.png'; -import exhaustFan from '@/assets/iscs_picture/exhaustFan.png' +import exhaustFan from '@/assets/iscs_picture/exhaustFan.png'; import waterCooler from '@/assets/iscs_picture/ZSDF533.png'; import textBgBluePoint from '@/assets/iscs_picture/textBgBluePoint.png'; -import ventilationFan from '@/assets/iscs_picture/ventilationFan.png' +import ventilationFan from '@/assets/iscs_picture/ventilationFan.png'; +import kongzhixiang from '@/assets/iscs_picture/iscs_kongzhixiang.png'; const pictureObj = { 'psdLeft': psdLeft, 'psdSystem': psdSystem, - 'psdRight': psdRight, - 'APF': iscsAPF, - 'envPersonDoor': envPersonDoor, + 'psdRight': psdRight, + 'APF': iscsAPF, + 'envPersonDoor': envPersonDoor, 's': fireBlue, - 'a': fireRed, - hand, - fmBlue, - fmGray, - fmGreen, - airCond, - airCondMul, - setting, - blowerRedLeft, - blowerGrayLeft, - blowerRedRight, - blowerGrayRight, - drum, - exhaustFan, - waterCooler, - textBgBluePoint, - ventilationFan + 'a': fireRed, + hand, + fmBlue, + fmGray, + fmGreen, + airCond, + airCondMul, + setting, + blowerRedLeft, + blowerGrayLeft, + blowerRedRight, + blowerGrayRight, + drum, + exhaustFan, + waterCooler, + textBgBluePoint, + ventilationFan, + kongzhixiang }; export default class Picture extends Group { constructor(device) { @@ -69,9 +71,9 @@ export default class Picture extends Group { }); this.imageButton = new Image({ zlevel: model.zlevel, - z: model.z, - origin: [model.width/2, model.height/2], - rotation: (model.rotation||0)*Math.PI/180, + z: model.z, + origin: [model.width / 2, model.height / 2], + rotation: (model.rotation || 0) * Math.PI / 180, style: { x: 0, y: 0, diff --git a/src/views/iscs/iscsDraw/icscComponents/line.vue b/src/views/iscs/iscsDraw/icscComponents/line.vue index a17c8f4fe..7c5263072 100644 --- a/src/views/iscs/iscsDraw/icscComponents/line.vue +++ b/src/views/iscs/iscsDraw/icscComponents/line.vue @@ -1,11 +1,11 @@