ecinc-cloud-yoabase 9.6.249 → 9.6.250

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.
@@ -16602,7 +16602,7 @@ ___CSS_LOADER_EXPORT___.push([module.id, ".el-collapse[data-v-7531760d]{width:26
16602
16602
 
16603
16603
  /***/ }),
16604
16604
 
16605
- /***/ 3032:
16605
+ /***/ 2489:
16606
16606
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
16607
16607
 
16608
16608
  "use strict";
@@ -16616,7 +16616,7 @@ __webpack_require__.r(__webpack_exports__);
16616
16616
 
16617
16617
  var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
16618
16618
  // Module
16619
- ___CSS_LOADER_EXPORT___.push([module.id, "#center[data-v-30cb1c36]{height:100%;max-width:3000px}.center-container[data-v-30cb1c36]{height:calc(100vh - 60px);overflow-y:auto;overflow-x:auto}.dropdown-menu[data-v-30cb1c36]{width:160px;display:none;position:fixed;z-index:999999;min-width:160px;padding:5px 0;margin:2px 0 0;list-style:none;font-size:var(--portalFontSize14);text-align:left;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175);background-clip:padding-box}.dropdown-menu li a[data-v-30cb1c36]{padding:5px 20px;line-height:1.5;white-space:nowrap;color:#333}.dropdown-menu li[data-v-30cb1c36]:hover{background:#f5f5f5}[data-v-30cb1c36] .line_text{cursor:pointer;position:absolute;left:0;top:0;font-size:var(--portalFontSize14)}[data-v-30cb1c36] svg:hover path:last-child{fill:red}[data-v-30cb1c36] path{stroke-width:2;cursor:pointer}[data-v-30cb1c36] path:last-child{fill:#438eb9}[data-v-30cb1c36] circle{fill:#438eb9;stroke:none}li[data-v-30cb1c36],ul[data-v-30cb1c36]{list-style:none}", ""]);
16619
+ ___CSS_LOADER_EXPORT___.push([module.id, "#center[data-v-7f0a3c68]{height:100%;max-width:3000px}.center-container[data-v-7f0a3c68]{height:calc(100vh - 60px);overflow-y:auto;overflow-x:auto}.dropdown-menu[data-v-7f0a3c68]{width:160px;display:none;position:fixed;z-index:999999;min-width:160px;padding:5px 0;margin:2px 0 0;list-style:none;font-size:var(--portalFontSize14);text-align:left;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175);background-clip:padding-box}.dropdown-menu li a[data-v-7f0a3c68]{padding:5px 20px;line-height:1.5;white-space:nowrap;color:#333}.dropdown-menu li[data-v-7f0a3c68]:hover{background:#f5f5f5}[data-v-7f0a3c68] .line_text{cursor:pointer;position:absolute;left:0;top:0;font-size:var(--portalFontSize14)}[data-v-7f0a3c68] svg:hover path:last-child{fill:red}[data-v-7f0a3c68] path{stroke-width:2;cursor:pointer}[data-v-7f0a3c68] path:last-child{fill:#438eb9}[data-v-7f0a3c68] circle{fill:#438eb9;stroke:none}li[data-v-7f0a3c68],ul[data-v-7f0a3c68]{list-style:none}", ""]);
16620
16620
  // Exports
16621
16621
  /* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
16622
16622
 
@@ -92181,19 +92181,19 @@ var update = add("73096750", content, true, {"sourceMap":false,"shadowMode":fals
92181
92181
 
92182
92182
  /***/ }),
92183
92183
 
92184
- /***/ 3076:
92184
+ /***/ 1685:
92185
92185
  /***/ (function(module, __unused_webpack_exports, __webpack_require__) {
92186
92186
 
92187
92187
  // style-loader: Adds some css to the DOM by adding a <style> tag
92188
92188
 
92189
92189
  // load the styles
92190
- var content = __webpack_require__(3032);
92190
+ var content = __webpack_require__(2489);
92191
92191
  if(content.__esModule) content = content.default;
92192
92192
  if(typeof content === 'string') content = [[module.id, content, '']];
92193
92193
  if(content.locals) module.exports = content.locals;
92194
92194
  // add the styles to the DOM
92195
92195
  var add = (__webpack_require__(9548)/* ["default"] */ .A)
92196
- var update = add("35711c36", content, true, {"sourceMap":false,"shadowMode":false});
92196
+ var update = add("deaac1b8", content, true, {"sourceMap":false,"shadowMode":false});
92197
92197
 
92198
92198
  /***/ }),
92199
92199
 
@@ -227318,8 +227318,8 @@ var MenuBar_component = normalizeComponent(
227318
227318
  )
227319
227319
 
227320
227320
  /* harmony default export */ var MenuBar = (MenuBar_component.exports);
227321
- ;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use[0]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecyoa/yoabase/src/voice/Center/index.vue?vue&type=template&id=30cb1c36&scoped=true
227322
- var Centervue_type_template_id_30cb1c36_scoped_true_render = function render() {
227321
+ ;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use[0]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecyoa/yoabase/src/voice/Center/index.vue?vue&type=template&id=7f0a3c68&scoped=true
227322
+ var Centervue_type_template_id_7f0a3c68_scoped_true_render = function render() {
227323
227323
  var _vm = this,
227324
227324
  _c = _vm._self._c;
227325
227325
  return _c('div', {
@@ -227420,7 +227420,7 @@ var Centervue_type_template_id_30cb1c36_scoped_true_render = function render() {
227420
227420
  }
227421
227421
  }, [_vm._v("水平平局分布")])])])])]);
227422
227422
  };
227423
- var Centervue_type_template_id_30cb1c36_scoped_true_staticRenderFns = [];
227423
+ var Centervue_type_template_id_7f0a3c68_scoped_true_staticRenderFns = [];
227424
227424
 
227425
227425
  // EXTERNAL MODULE: ./node_modules/jquery/dist/jquery.js
227426
227426
  var jquery = __webpack_require__(4692);
@@ -227557,8 +227557,6 @@ var Base64 = {
227557
227557
  }
227558
227558
  };
227559
227559
 
227560
- // EXTERNAL MODULE: ./node_modules/jsplumb/dist/js/jsplumb.js
227561
- var jsplumb = __webpack_require__(1702);
227562
227560
  ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/scripts/model_data.js
227563
227561
 
227564
227562
  // 定义全局流程对象
@@ -227731,7 +227729,7 @@ var modeldata = [{
227731
227729
  }];
227732
227730
 
227733
227731
  ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/scripts/globalStyle.js
227734
- var globalStyle_jsPlumb = __webpack_require__(1702);
227732
+ var entry_lib_jsPlumb = window.jsPlumb;
227735
227733
 
227736
227734
  // 基本连接线样式
227737
227735
  // var connectorPaintStyle = {
@@ -227784,7 +227782,7 @@ var hollowCircle = {
227784
227782
  cssClass: 'line_text',
227785
227783
  events: {
227786
227784
  mousedown: function mousedown(labelOverlay, originalEvent) {
227787
- globalStyle_jsPlumb.draggable($('.line_text'));
227785
+ entry_lib_jsPlumb.draggable($('.line_text'));
227788
227786
  },
227789
227787
  mouseout: function mouseout() {
227790
227788
  return false;
@@ -227798,7 +227796,7 @@ var hollowCircle = {
227798
227796
  ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/scripts/menuCoulmn.js
227799
227797
  /* eslint-disable */
227800
227798
 
227801
-
227799
+ var menuCoulmn_jsPlumb = window.jsPlumb;
227802
227800
 
227803
227801
  // 说明:添加、移除、检测 className
227804
227802
  function hasClass(element, className) {
@@ -228264,7 +228262,7 @@ function SelectAlignLeft() {
228264
228262
  if (id !== arr[j].parentNode.id) continue;
228265
228263
  jquery_default()(arr[j]).css('left', iLeft + 'px');
228266
228264
  }
228267
- jsplumb.jsPlumb.repaintEverything();
228265
+ menuCoulmn_jsPlumb.repaintEverything();
228268
228266
  }
228269
228267
 
228270
228268
  // 垂直居中对齐
@@ -228284,7 +228282,7 @@ function SelectAlignCenter() {
228284
228282
  if (id !== arr[j].parentNode.id) continue;
228285
228283
  jquery_default()(arr[j]).css('left', iLeft - parseInt(GetStyle(arr[j], 'width')) / 2 + 'px');
228286
228284
  }
228287
- jsplumb.jsPlumb.repaintEverything();
228285
+ menuCoulmn_jsPlumb.repaintEverything();
228288
228286
  }
228289
228287
 
228290
228288
  // 垂直平局分布
@@ -228327,7 +228325,7 @@ function SelectAlignMean() {
228327
228325
  ic++;
228328
228326
  }
228329
228327
  }
228330
- jsplumb.jsPlumb.repaintEverything();
228328
+ menuCoulmn_jsPlumb.repaintEverything();
228331
228329
  }
228332
228330
  }
228333
228331
 
@@ -228368,7 +228366,7 @@ function SelectMeanCenter() {
228368
228366
  ic++;
228369
228367
  }
228370
228368
  }
228371
- jsplumb.jsPlumb.repaintEverything();
228369
+ menuCoulmn_jsPlumb.repaintEverything();
228372
228370
  }
228373
228371
  }
228374
228372
 
@@ -228388,7 +228386,7 @@ function SelectAlignRight() {
228388
228386
  if (id !== arr[j].parentNode.id) continue;
228389
228387
  $(arr[j]).css('left', iLeft - parseInt(GetStyle(arr[j], 'width')) + 'px');
228390
228388
  }
228391
- jsPlumb.repaintEverything();
228389
+ menuCoulmn_jsPlumb.repaintEverything();
228392
228390
  }
228393
228391
 
228394
228392
  // 上对齐
@@ -228407,7 +228405,7 @@ function SelectAlignTop() {
228407
228405
  if (id !== arr[j].parentNode.id) continue;
228408
228406
  jquery_default()(arr[j]).css('top', iTop + 'px');
228409
228407
  }
228410
- jsplumb.jsPlumb.repaintEverything();
228408
+ menuCoulmn_jsPlumb.repaintEverything();
228411
228409
  }
228412
228410
 
228413
228411
  // 垂直居中
@@ -228426,21 +228424,21 @@ function SelectAlignMiddle() {
228426
228424
  if (id !== arr[j].parentNode.id) continue;
228427
228425
  jquery_default()(arr[j]).css('top', iTop - parseInt(GetStyle(arr[j], 'height')) / 2 + 'px');
228428
228426
  }
228429
- jsplumb.jsPlumb.repaintEverything();
228427
+ menuCoulmn_jsPlumb.repaintEverything();
228430
228428
  }
228431
228429
 
228432
228430
  // 删除选中
228433
228431
  function DeleteSelect() {
228434
228432
  var arr = getSelectedRegions();
228435
228433
  for (var i = 0; i < arr.length; i++) {
228436
- jsPlumb.remove(arr[i], true);
228434
+ menuCoulmn_jsPlumb.remove(arr[i], true);
228437
228435
  // var points = jsPlumb.getEndpoints(arr[i]);
228438
228436
  // for (var j = 0; j < points.length; j++) {
228439
228437
  // jsPlumb.deleteEndpoint(points[j]);
228440
228438
  // }
228441
228439
  // arr[i].parentNode.removeChild(arr[i]);
228442
228440
  }
228443
- jsPlumb.repaintEverything();
228441
+ menuCoulmn_jsPlumb.repaintEverything();
228444
228442
  }
228445
228443
  function GetStyle(obj, attr) {
228446
228444
  if (obj.currentStyle) {
@@ -228452,14 +228450,14 @@ function GetStyle(obj, attr) {
228452
228450
  }
228453
228451
 
228454
228452
  /** Event handler for mouse wheel event.
228455
- *鼠标滚动事件
228456
- */
228453
+ *鼠标滚动事件
228454
+ */
228457
228455
  var wheel = function wheel(event) {
228458
228456
  var delta = 0;
228459
- if (!event) /* IE. */
228460
- {
228461
- event = window.event;
228462
- }
228457
+ if (!event) {
228458
+ /* IE. */
228459
+ event = window.event;
228460
+ }
228463
228461
  if (event.wheelDelta) {
228464
228462
  /* IE/Opera. */
228465
228463
  delta = event.wheelDelta / 120;
@@ -228524,7 +228522,7 @@ var Transform = {
228524
228522
  '-webkit-transform': 'scale(' + M11 + ',' + M22 + ')',
228525
228523
  // "-webkit-transform-origin": transformOriginString,
228526
228524
  '-o-transform': 'scale(' + M11 + ',' + M22 + ')',
228527
- 'transform': 'scale(' + M11 + ',' + M22 + ')'
228525
+ transform: 'scale(' + M11 + ',' + M22 + ')'
228528
228526
  // "-o-transform-origin": transformOriginString,
228529
228527
  // "filter": "progid:DXImageTransform.Microsoft.Matrix(M11=" + M11 + ",M12=" + M12 + ",M21=" + M21 + ",M22=" + M22 + ", sizingMethod='auto expand')"
228530
228528
  });
@@ -228535,7 +228533,7 @@ var Transform = {
228535
228533
  ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/scripts/drag.js
228536
228534
  /* eslint-disable */
228537
228535
 
228538
-
228536
+ var drag_jsPlumb = window.jsPlumb;
228539
228537
 
228540
228538
 
228541
228539
 
@@ -228567,7 +228565,7 @@ model.start = 0; // 用于判断开始节点是否存在
228567
228565
  function nodeEvents(id, wflow) {
228568
228566
  // 节点删除,包括连线以及数据
228569
228567
  jquery_default()('#' + id).bind('mousedown', function (e) {
228570
- var allConnection = jsplumb.jsPlumb.getAllConnections();
228568
+ var allConnection = drag_jsPlumb.getAllConnections();
228571
228569
  var pathArr = [];
228572
228570
  var curNode = jquery_default()(this).attr('id');
228573
228571
  if (e.which === 3) {
@@ -228607,7 +228605,7 @@ function nodeEvents(id, wflow) {
228607
228605
 
228608
228606
  // 2图形上删除node及path
228609
228607
 
228610
- jsplumb.jsPlumb.remove(id);
228608
+ drag_jsPlumb.remove(id);
228611
228609
  });
228612
228610
  }
228613
228611
  // 解决center的top无规则运动的bug
@@ -228651,24 +228649,24 @@ model.CreateModel = function (ui, select, resize, domJoin, modelType, type, wflo
228651
228649
 
228652
228650
  // 设置连接点
228653
228651
  if (domJoin === 1) {
228654
- jsplumb.jsPlumb.addEndpoint(id, {
228652
+ drag_jsPlumb.addEndpoint(id, {
228655
228653
  anchors: [0.5, 1, 0, 1],
228656
228654
  uuid: jsPlumbUtil.uuid()
228657
228655
  }, hollowCircle);
228658
228656
  } else {
228659
- jsplumb.jsPlumb.addEndpoint(id, {
228657
+ drag_jsPlumb.addEndpoint(id, {
228660
228658
  anchors: [1, 0.5, 1, 0],
228661
228659
  uuid: jsPlumbUtil.uuid()
228662
228660
  }, hollowCircle);
228663
- jsplumb.jsPlumb.addEndpoint(id, {
228661
+ drag_jsPlumb.addEndpoint(id, {
228664
228662
  anchors: [0, 0.5, -1, 0],
228665
228663
  uuid: jsPlumbUtil.uuid()
228666
228664
  }, hollowCircle);
228667
- jsplumb.jsPlumb.addEndpoint(id, {
228665
+ drag_jsPlumb.addEndpoint(id, {
228668
228666
  anchors: [0.5, 0, 0, -1],
228669
228667
  uuid: jsPlumbUtil.uuid()
228670
228668
  }, hollowCircle);
228671
- jsplumb.jsPlumb.addEndpoint(id, {
228669
+ drag_jsPlumb.addEndpoint(id, {
228672
228670
  anchors: [0.5, 1, 0, 1],
228673
228671
  uuid: jsPlumbUtil.uuid()
228674
228672
  }, hollowCircle);
@@ -228690,14 +228688,14 @@ model.CreateModel = function (ui, select, resize, domJoin, modelType, type, wflo
228690
228688
  jquery_default()('#' + id).draggable({
228691
228689
  start: function start() {
228692
228690
  startMove();
228693
- jsplumb.jsPlumb.repaintEverything();
228691
+ drag_jsPlumb.repaintEverything();
228694
228692
  },
228695
228693
  drag: function drag(event, ui) {
228696
228694
  MoveSelectDiv(event, ui, id);
228697
- jsplumb.jsPlumb.repaintEverything();
228695
+ drag_jsPlumb.repaintEverything();
228698
228696
  },
228699
228697
  stop: function stop() {
228700
- jsplumb.jsPlumb.repaintEverything();
228698
+ drag_jsPlumb.repaintEverything();
228701
228699
  }
228702
228700
  });
228703
228701
 
@@ -229057,952 +229055,960 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
229057
229055
  },
229058
229056
  mounted: function mounted() {
229059
229057
  var _this2 = this;
229060
- Centervue_type_script_lang_js_jsPlumb.importDefaults({
229061
- PaintStyle: {
229062
- lineWidth: 8,
229063
- stroke: '#00ff54'
229058
+ jquery_default()(function () {
229059
+ if (_this2.$route.path.indexOf('/designer/voice') !== -1) {
229060
+ _this2.initVoiceDesigner();
229064
229061
  }
229065
229062
  });
229066
- this.dragLineObj.init = function (connection, thisConnect) {
229067
- _this2.dragLine(connection, thisConnect);
229068
- };
229069
- // 区域选择
229070
- var oRegionSelect = new RegionSelect({
229071
- region: '#center div.process',
229072
- selectedClass: 'seled',
229073
- parentId: 'center'
229074
- });
229075
- oRegionSelect.select();
229076
- jquery_default()('#topAlign').click(function () {
229077
- SelectAlignTop();
229078
- });
229079
- jquery_default()('#leftAlign').click(function () {
229080
- SelectAlignLeft();
229081
- });
229082
- jquery_default()('#verticalAlign').click(function () {
229083
- SelectAlignCenter();
229084
- });
229085
- jquery_default()('#verticalMean').click(function () {
229086
- SelectAlignMean();
229087
- });
229088
- jquery_default()('#levelAlign').click(function () {
229089
- // SelectAlignCenter();
229090
- SelectAlignMiddle();
229091
- });
229092
- jquery_default()('#levelMean').click(function () {
229093
- // SelectAlignCenter();
229094
- SelectMeanCenter();
229095
- });
229096
- jquery_default()('#left ul').find('li').draggable({
229097
- helper: 'clone',
229098
- scope: 'plant'
229099
- });
229100
- var labelText = ''; // 请求过来数据时保存路径文字
229101
- // const pathNo = ''// 请求过来数据时保存路径编号
229102
- ecinc_process.init();
229103
- ecinc_attr_panel.init();
229104
- this.handleBtn();
229105
- if (this.id) {
229106
- this.$http({
229107
- method: 'GET',
229108
- params: {
229109
- product: this.product,
229110
- dwadmin: this.dwadmin,
229111
- copy: this.$route.query.copy
229112
- },
229113
- contentType: 'application/x-www-form-urlencoded',
229114
- url: '/voice/scene/getById?id=' + this.id + ''
229115
- }).then(function (response) {
229116
- _this2.dataStatus = true;
229117
- // this.getWflow = response.body.vo
229118
- _this2.wflow = response.body.vo;
229119
- _this2.wflow.speaks.forEach(function (item) {
229120
- _this2.$set(item, 'time', [item.startTime || '', item.endTime || '']);
229121
- });
229122
- _this2.wflow.nodes.forEach(function (item) {
229123
- _this2.$set(item, 'SpeakMethod', _this2.wflow.speaks.filter(function (list) {
229124
- return list.nodeId === item.id && list.type === 2;
229125
- }));
229126
- _this2.$set(item, 'successSpeakMethod', _this2.wflow.speaks.filter(function (list) {
229127
- return list.nodeId === item.id && list.type === 1;
229128
- }));
229129
- _this2.$set(item, 'errorSpeakMethod', _this2.wflow.speaks.filter(function (list) {
229130
- return list.nodeId === item.id && list.type === 0;
229131
- }));
229132
- });
229133
- var _nextNodes = [];
229134
- _this2.wflow.paths.forEach(function (item) {
229135
- var obj = {
229136
- nextNodeId: item.afterNodeId,
229137
- pathId: item.id
229138
- };
229139
- _nextNodes.push(obj);
229140
- });
229141
- _this2.$set(_this2.wflow, 'nextNodes', _nextNodes);
229142
- _this2.$set(_this2.wflow, 'pathFieldValues', []);
229143
- _this2.$set(_this2.wflow, 'nodeFieldValues', []);
229144
- // if (this.wflow.groupOrgans && this.wflow.groupOrgans.length > 1) {
229145
- // this.wflow.groupOrgans.push({ 'code': 'group_cur_corp', 'name': '当前用户所在单位(公司)' })
229146
- // this.wflow.groupOrgans.push({ 'code': 'group_drf_corp', 'name': '拟稿用户所在单位(公司)' })
229147
- // this.wflow.groupOrgans.push({ 'code': 'group_all_corp', 'name': '不限制(集团各公司)' })
229148
- // }
229149
- _this2.responseVo = JSON.parse(JSON.stringify(response.body.vo));
229150
- _this2.ideaL = _this2.wflow.ideaLabels;
229151
- for (var k = 0; k < _this2.wflow.paths.length; k++) {
229152
- _this2.getWflow.push(_this2.wflow.paths[k].id);
229153
- }
229154
- // for (let i = 0; i < this.wflow.ideaLabels.length; i++) {
229155
- // if (this.wflow.ideaLabels.length === 1) {
229156
- // this.ideaLables = this.wflow.ideaLabels[i].name
229157
- // } else if (this.wflow.ideaLabels.length > 1) {
229158
- // this.ideaLables += this.wflow.ideaLabels[i].name + '\n'
229159
- // } else {
229160
- // this.ideaLables = ''
229161
- // }
229162
- // }
229163
- for (var o = 0; o < _this2.wflow.paths.length; o++) {
229164
- _this2.pathObj.push(_this2.wflow.paths[o]);
229165
- }
229166
- _this2.wflow.paths.length = 0;
229167
- _this2.process = response.body.vo.scene;
229168
- _this2.emitData();
229169
- var chartData = JSON.parse(response.body.vo.scene.chartData);
229170
- var connectsArr = chartData.connects;
229171
- _this2.connectsArr = connectsArr;
229172
- var domHtmlArr = chartData.domHtml;
229173
- var nodeIdArr = [];
229174
- for (var i = 0; i < domHtmlArr.length; i++) {
229175
- // console.log(Base64.decode(domHtmlArr[i].domH))
229176
- // console.log($(Base64.decode(domHtmlArr[i].domH)))
229177
- jquery_default()('#center').append(Base64.decode(domHtmlArr[i].domH));
229063
+ },
229064
+ methods: {
229065
+ initVoiceDesigner: function initVoiceDesigner() {
229066
+ var _this3 = this;
229067
+ Centervue_type_script_lang_js_jsPlumb.importDefaults({
229068
+ PaintStyle: {
229069
+ lineWidth: 8,
229070
+ stroke: '#00ff54'
229178
229071
  }
229179
- jquery_default()('.process').removeClass('seled');
229180
- jquery_default()('.process').each(function (index, elem) {
229181
- nodeIdArr.push(jquery_default()(elem).attr('id'));
229182
- nodeEvents(jquery_default()(elem).attr('id'), _this2.wflow);
229183
- if (jquery_default()(elem).hasClass('ptjd')) {
229184
- jquery_default()(elem).find('img').attr('src', _this2.ptjd);
229185
- } else if (jquery_default()(elem).hasClass('jzjd')) {
229186
- jquery_default()(elem).find('img').attr('src', _this2.jzjd);
229187
- } else if (jquery_default()(elem).hasClass('drbx')) {
229188
- jquery_default()(elem).find('img').attr('src', _this2.drbx);
229189
- } else if (jquery_default()(elem).hasClass('drcx')) {
229190
- jquery_default()(elem).find('img').attr('src', _this2.drcx);
229191
- } else if (jquery_default()(elem).hasClass('hqjd')) {
229192
- jquery_default()(elem).find('img').attr('src', _this2.hqjd);
229193
- } else if (jquery_default()(elem).hasClass('ywjd')) {
229194
- jquery_default()(elem).find('img').attr('src', _this2.ywjd);
229195
- } else if (jquery_default()(elem).hasClass('childWf')) {
229196
- jquery_default()(elem).find('img').attr('src', _this2.zlx);
229072
+ });
229073
+ this.dragLineObj.init = function (connection, thisConnect) {
229074
+ _this3.dragLine(connection, thisConnect);
229075
+ };
229076
+ // 区域选择
229077
+ var oRegionSelect = new RegionSelect({
229078
+ region: '#center div.process',
229079
+ selectedClass: 'seled',
229080
+ parentId: 'center'
229081
+ });
229082
+ oRegionSelect.select();
229083
+ jquery_default()('#topAlign').click(function () {
229084
+ SelectAlignTop();
229085
+ });
229086
+ jquery_default()('#leftAlign').click(function () {
229087
+ SelectAlignLeft();
229088
+ });
229089
+ jquery_default()('#verticalAlign').click(function () {
229090
+ SelectAlignCenter();
229091
+ });
229092
+ jquery_default()('#verticalMean').click(function () {
229093
+ SelectAlignMean();
229094
+ });
229095
+ jquery_default()('#levelAlign').click(function () {
229096
+ // SelectAlignCenter();
229097
+ SelectAlignMiddle();
229098
+ });
229099
+ jquery_default()('#levelMean').click(function () {
229100
+ // SelectAlignCenter();
229101
+ SelectMeanCenter();
229102
+ });
229103
+ jquery_default()('#left ul').find('li').draggable({
229104
+ helper: 'clone',
229105
+ scope: 'plant'
229106
+ });
229107
+ var labelText = ''; // 请求过来数据时保存路径文字
229108
+ // const pathNo = ''// 请求过来数据时保存路径编号
229109
+ ecinc_process.init();
229110
+ ecinc_attr_panel.init();
229111
+ this.handleBtn();
229112
+ if (this.id) {
229113
+ this.$http({
229114
+ method: 'GET',
229115
+ params: {
229116
+ product: this.product,
229117
+ dwadmin: this.dwadmin,
229118
+ copy: this.$route.query.copy
229119
+ },
229120
+ contentType: 'application/x-www-form-urlencoded',
229121
+ url: '/voice/scene/getById?id=' + this.id + ''
229122
+ }).then(function (response) {
229123
+ _this3.dataStatus = true;
229124
+ // this.getWflow = response.body.vo
229125
+ _this3.wflow = response.body.vo;
229126
+ _this3.wflow.speaks.forEach(function (item) {
229127
+ _this3.$set(item, 'time', [item.startTime || '', item.endTime || '']);
229128
+ });
229129
+ _this3.wflow.nodes.forEach(function (item) {
229130
+ _this3.$set(item, 'SpeakMethod', _this3.wflow.speaks.filter(function (list) {
229131
+ return list.nodeId === item.id && list.type === 2;
229132
+ }));
229133
+ _this3.$set(item, 'successSpeakMethod', _this3.wflow.speaks.filter(function (list) {
229134
+ return list.nodeId === item.id && list.type === 1;
229135
+ }));
229136
+ _this3.$set(item, 'errorSpeakMethod', _this3.wflow.speaks.filter(function (list) {
229137
+ return list.nodeId === item.id && list.type === 0;
229138
+ }));
229139
+ });
229140
+ var _nextNodes = [];
229141
+ _this3.wflow.paths.forEach(function (item) {
229142
+ var obj = {
229143
+ nextNodeId: item.afterNodeId,
229144
+ pathId: item.id
229145
+ };
229146
+ _nextNodes.push(obj);
229147
+ });
229148
+ _this3.$set(_this3.wflow, 'nextNodes', _nextNodes);
229149
+ _this3.$set(_this3.wflow, 'pathFieldValues', []);
229150
+ _this3.$set(_this3.wflow, 'nodeFieldValues', []);
229151
+ // if (this.wflow.groupOrgans && this.wflow.groupOrgans.length > 1) {
229152
+ // this.wflow.groupOrgans.push({ 'code': 'group_cur_corp', 'name': '当前用户所在单位(公司)' })
229153
+ // this.wflow.groupOrgans.push({ 'code': 'group_drf_corp', 'name': '拟稿用户所在单位(公司)' })
229154
+ // this.wflow.groupOrgans.push({ 'code': 'group_all_corp', 'name': '不限制(集团各公司)' })
229155
+ // }
229156
+ _this3.responseVo = JSON.parse(JSON.stringify(response.body.vo));
229157
+ _this3.ideaL = _this3.wflow.ideaLabels;
229158
+ for (var k = 0; k < _this3.wflow.paths.length; k++) {
229159
+ _this3.getWflow.push(_this3.wflow.paths[k].id);
229160
+ }
229161
+ // for (let i = 0; i < this.wflow.ideaLabels.length; i++) {
229162
+ // if (this.wflow.ideaLabels.length === 1) {
229163
+ // this.ideaLables = this.wflow.ideaLabels[i].name
229164
+ // } else if (this.wflow.ideaLabels.length > 1) {
229165
+ // this.ideaLables += this.wflow.ideaLabels[i].name + '\n'
229166
+ // } else {
229167
+ // this.ideaLables = ''
229168
+ // }
229169
+ // }
229170
+ for (var o = 0; o < _this3.wflow.paths.length; o++) {
229171
+ _this3.pathObj.push(_this3.wflow.paths[o]);
229172
+ }
229173
+ _this3.wflow.paths.length = 0;
229174
+ _this3.process = response.body.vo.scene;
229175
+ _this3.emitData();
229176
+ var chartData = JSON.parse(response.body.vo.scene.chartData);
229177
+ var connectsArr = chartData.connects;
229178
+ _this3.connectsArr = connectsArr;
229179
+ var domHtmlArr = chartData.domHtml;
229180
+ var nodeIdArr = [];
229181
+ for (var i = 0; i < domHtmlArr.length; i++) {
229182
+ // console.log(Base64.decode(domHtmlArr[i].domH))
229183
+ // console.log($(Base64.decode(domHtmlArr[i].domH)))
229184
+ jquery_default()('#center').append(Base64.decode(domHtmlArr[i].domH));
229197
229185
  }
229198
- });
229199
- for (var u = 0; u < nodeIdArr.length; u++) {
229200
- if (jquery_default()('#' + nodeIdArr[u]).hasClass('start')) {
229201
- Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229202
- anchors: [0.5, 1, 0, 1]
229203
- }, hollowCircle);
229204
- model.start++;
229205
- } else {
229206
- Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229207
- anchors: [1, 0.5, 1, 0]
229208
- }, hollowCircle);
229209
- Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229210
- anchors: [0, 0.5, -1, 0]
229211
- }, hollowCircle);
229212
- Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229213
- anchors: [0.5, 0, 0, -1]
229214
- }, hollowCircle);
229215
- Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229216
- anchors: [0.5, 1, 0, 1]
229217
- }, hollowCircle);
229218
- }
229219
- }
229220
- // 划线
229221
- for (var j = 0; j < connectsArr.length; j++) {
229222
- // debugger
229223
- labelText = connectsArr[j].label;
229224
- var anchor = [connectsArr[j].firstEndpoints, connectsArr[j].secondEndpoints];
229225
- var lineDistance = 0;
229226
- var topY = 0;
229227
- var connector = void 0;
229228
- // type,pathMaxX
229229
- if (connectsArr[j].type === 'Straight') {
229230
- connector = ['Straight', {
229231
- stub: [0, 0]
229232
- }];
229233
- } else if (connectsArr[j].type === 'Flowchart') {
229234
- // lineDistance = Math.abs(connectsArr[j].pathMaxX) >= Math.abs(connectsArr[j].pathMinX) ? Math.abs(connectsArr[j].pathMaxX) : Math.abs(connectsArr[j].pathMinX)
229235
- if (connectsArr[j].PageSourceId === connectsArr[j].PageTargetId) {
229236
- connector = ['Flowchart', {
229237
- stub: [50, 50],
229238
- gap: 3,
229239
- cornerRadius: 5,
229240
- alwaysRespectStubs: false
229241
- }];
229186
+ jquery_default()('.process').removeClass('seled');
229187
+ jquery_default()('.process').each(function (index, elem) {
229188
+ nodeIdArr.push(jquery_default()(elem).attr('id'));
229189
+ nodeEvents(jquery_default()(elem).attr('id'), _this3.wflow);
229190
+ if (jquery_default()(elem).hasClass('ptjd')) {
229191
+ jquery_default()(elem).find('img').attr('src', _this3.ptjd);
229192
+ } else if (jquery_default()(elem).hasClass('jzjd')) {
229193
+ jquery_default()(elem).find('img').attr('src', _this3.jzjd);
229194
+ } else if (jquery_default()(elem).hasClass('drbx')) {
229195
+ jquery_default()(elem).find('img').attr('src', _this3.drbx);
229196
+ } else if (jquery_default()(elem).hasClass('drcx')) {
229197
+ jquery_default()(elem).find('img').attr('src', _this3.drcx);
229198
+ } else if (jquery_default()(elem).hasClass('hqjd')) {
229199
+ jquery_default()(elem).find('img').attr('src', _this3.hqjd);
229200
+ } else if (jquery_default()(elem).hasClass('ywjd')) {
229201
+ jquery_default()(elem).find('img').attr('src', _this3.ywjd);
229202
+ } else if (jquery_default()(elem).hasClass('childWf')) {
229203
+ jquery_default()(elem).find('img').attr('src', _this3.zlx);
229204
+ }
229205
+ });
229206
+ for (var u = 0; u < nodeIdArr.length; u++) {
229207
+ if (jquery_default()('#' + nodeIdArr[u]).hasClass('start')) {
229208
+ Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229209
+ anchors: [0.5, 1, 0, 1]
229210
+ }, hollowCircle);
229211
+ model.start++;
229242
229212
  } else {
229243
- if (connectsArr[j].firstEndpoints[1] === 0 && connectsArr[j].secondEndpoints[1] === 1 || connectsArr[j].firstEndpoints[1] === 1 && connectsArr[j].secondEndpoints[1] === 0) {
229244
- topY = connectsArr[j].topY;
229213
+ Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229214
+ anchors: [1, 0.5, 1, 0]
229215
+ }, hollowCircle);
229216
+ Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229217
+ anchors: [0, 0.5, -1, 0]
229218
+ }, hollowCircle);
229219
+ Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229220
+ anchors: [0.5, 0, 0, -1]
229221
+ }, hollowCircle);
229222
+ Centervue_type_script_lang_js_jsPlumb.addEndpoint(nodeIdArr[u], {
229223
+ anchors: [0.5, 1, 0, 1]
229224
+ }, hollowCircle);
229225
+ }
229226
+ }
229227
+ // 划线
229228
+ for (var j = 0; j < connectsArr.length; j++) {
229229
+ // debugger
229230
+ labelText = connectsArr[j].label;
229231
+ var anchor = [connectsArr[j].firstEndpoints, connectsArr[j].secondEndpoints];
229232
+ var lineDistance = 0;
229233
+ var topY = 0;
229234
+ var connector = void 0;
229235
+ // type,pathMaxX
229236
+ if (connectsArr[j].type === 'Straight') {
229237
+ connector = ['Straight', {
229238
+ stub: [0, 0]
229239
+ }];
229240
+ } else if (connectsArr[j].type === 'Flowchart') {
229241
+ // lineDistance = Math.abs(connectsArr[j].pathMaxX) >= Math.abs(connectsArr[j].pathMinX) ? Math.abs(connectsArr[j].pathMaxX) : Math.abs(connectsArr[j].pathMinX)
229242
+ if (connectsArr[j].PageSourceId === connectsArr[j].PageTargetId) {
229245
229243
  connector = ['Flowchart', {
229246
- stub: [0, 0],
229244
+ stub: [50, 50],
229247
229245
  gap: 3,
229248
229246
  cornerRadius: 5,
229249
- alwaysRespectStubs: true,
229250
- midpoint: topY
229247
+ alwaysRespectStubs: false
229251
229248
  }];
229252
229249
  } else {
229253
- if (Math.abs(connectsArr[j].pathMaxX) >= Math.abs(connectsArr[j].pathMinX)) {
229254
- if (connectsArr[j].type !== 'Flowchart') {
229255
- lineDistance = 0;
229256
- } else {
229257
- if (connectsArr[j].firstEndpoints.x === connectsArr[j].secondEndpoints.x) {
229258
- if (connectsArr[j].pathMaxX >= 0) {
229259
- lineDistance = Math.abs(connectsArr[j].pathMinX); // 自动计算
229250
+ if (connectsArr[j].firstEndpoints[1] === 0 && connectsArr[j].secondEndpoints[1] === 1 || connectsArr[j].firstEndpoints[1] === 1 && connectsArr[j].secondEndpoints[1] === 0) {
229251
+ topY = connectsArr[j].topY;
229252
+ connector = ['Flowchart', {
229253
+ stub: [0, 0],
229254
+ gap: 3,
229255
+ cornerRadius: 5,
229256
+ alwaysRespectStubs: true,
229257
+ midpoint: topY
229258
+ }];
229259
+ } else {
229260
+ if (Math.abs(connectsArr[j].pathMaxX) >= Math.abs(connectsArr[j].pathMinX)) {
229261
+ if (connectsArr[j].type !== 'Flowchart') {
229262
+ lineDistance = 0;
229263
+ } else {
229264
+ if (connectsArr[j].firstEndpoints.x === connectsArr[j].secondEndpoints.x) {
229265
+ if (connectsArr[j].pathMaxX >= 0) {
229266
+ lineDistance = Math.abs(connectsArr[j].pathMinX); // 自动计算
229267
+ } else {
229268
+ lineDistance = Math.abs(connectsArr[j].pathMaxX); // 自动计算
229269
+ }
229270
+
229271
+ // lineDistance = Math.abs(connectsArr[j].pathMaxX)// 自动计算
229272
+ connector = [connectsArr[j].type, {
229273
+ stub: [lineDistance, 20],
229274
+ gap: 3,
229275
+ cornerRadius: 5,
229276
+ alwaysRespectStubs: true
229277
+ }];
229278
+ } else if (connectsArr[j].PageSourceId === connectsArr[j].PageTargetId) {
229279
+ lineDistance = 10; // 暂时写死,研究上下拖拽时再计算
229280
+ connector = [connectsArr[j].type, {
229281
+ stub: [lineDistance, 20],
229282
+ gap: 3,
229283
+ cornerRadius: 5,
229284
+ alwaysRespectStubs: true
229285
+ }];
229260
229286
  } else {
229261
- lineDistance = Math.abs(connectsArr[j].pathMaxX); // 自动计算
229287
+ lineDistance = 0; // 防止其他折线解析初始值错误
229288
+ connector = [connectsArr[j].type, {
229289
+ stub: [lineDistance, 20],
229290
+ gap: 3,
229291
+ cornerRadius: 5,
229292
+ alwaysRespectStubs: true
229293
+ }];
229262
229294
  }
229263
-
229264
- // lineDistance = Math.abs(connectsArr[j].pathMaxX)// 自动计算
229265
- connector = [connectsArr[j].type, {
229266
- stub: [lineDistance, 20],
229267
- gap: 3,
229268
- cornerRadius: 5,
229269
- alwaysRespectStubs: true
229270
- }];
229271
- } else if (connectsArr[j].PageSourceId === connectsArr[j].PageTargetId) {
229272
- lineDistance = 10; // 暂时写死,研究上下拖拽时再计算
229273
- connector = [connectsArr[j].type, {
229274
- stub: [lineDistance, 20],
229275
- gap: 3,
229276
- cornerRadius: 5,
229277
- alwaysRespectStubs: true
229278
- }];
229279
- } else {
229280
- lineDistance = 0; // 防止其他折线解析初始值错误
229281
- connector = [connectsArr[j].type, {
229282
- stub: [lineDistance, 20],
229283
- gap: 3,
229284
- cornerRadius: 5,
229285
- alwaysRespectStubs: true
229286
- }];
229287
229295
  }
229296
+ } else {
229297
+ lineDistance = Math.abs(connectsArr[j].pathMinX);
229298
+ connector = [connectsArr[j].type, {
229299
+ stub: [lineDistance, 10],
229300
+ gap: 3,
229301
+ cornerRadius: 5,
229302
+ alwaysRespectStubs: true
229303
+ }];
229288
229304
  }
229289
- } else {
229290
- lineDistance = Math.abs(connectsArr[j].pathMinX);
229305
+ }
229306
+ if (connectsArr[j].firstEndpoints[1] === 0 && connectsArr[j].secondEndpoints[1] === 0 || connectsArr[j].firstEndpoints[1] === 1 && connectsArr[j].secondEndpoints[1] === 1) {
229307
+ console.log(connectsArr[j]);
229291
229308
  connector = [connectsArr[j].type, {
229292
- stub: [lineDistance, 10],
229309
+ stub: [50, 50],
229293
229310
  gap: 3,
229294
229311
  cornerRadius: 5,
229295
229312
  alwaysRespectStubs: true
229296
229313
  }];
229297
229314
  }
229298
229315
  }
229299
- if (connectsArr[j].firstEndpoints[1] === 0 && connectsArr[j].secondEndpoints[1] === 0 || connectsArr[j].firstEndpoints[1] === 1 && connectsArr[j].secondEndpoints[1] === 1) {
229300
- console.log(connectsArr[j]);
229301
- connector = [connectsArr[j].type, {
229302
- stub: [50, 50],
229303
- gap: 3,
229304
- cornerRadius: 5,
229305
- alwaysRespectStubs: true
229306
- }];
229307
- }
229316
+ } else if (connectsArr[j].type === 'Bezier') {
229317
+ connector = ['Bezier', {
229318
+ stub: [0, 0]
229319
+ }];
229320
+ }
229321
+ var a = Centervue_type_script_lang_js_jsPlumb.connect({
229322
+ source: connectsArr[j].PageSourceId,
229323
+ target: connectsArr[j].PageTargetId,
229324
+ anchors: anchor,
229325
+ editable: true,
229326
+ paintStyle: {
229327
+ strokeStyle: '#438eb9',
229328
+ fillStyle: '#438eb9',
229329
+ radius: 5,
229330
+ lineWidth: 2
229331
+ },
229332
+ parameters: {
229333
+ pathId: connectsArr[j].ConnectionId
229334
+ },
229335
+ endpointStyle: {
229336
+ fill: 'lightgray',
229337
+ outlineStroke: 'darkgray',
229338
+ outlineWidth: 2
229339
+ },
229340
+ connector: connector,
229341
+ overlays: [['Arrow', {
229342
+ width: 10,
229343
+ length: 10,
229344
+ location: 1
229345
+ }]],
229346
+ endpoint: ['Dot', {
229347
+ radius: 5
229348
+ }],
229349
+ cssClass: 'line_path'
229350
+ });
229351
+ try {
229352
+ a.setLabel({
229353
+ label: labelText,
229354
+ cssClass: 'line_text'
229355
+ });
229356
+ a = null;
229357
+ } catch (e) {
229358
+ console.log(e);
229308
229359
  }
229309
- } else if (connectsArr[j].type === 'Bezier') {
229310
- connector = ['Bezier', {
229311
- stub: [0, 0]
229312
- }];
229313
229360
  }
229314
- var a = Centervue_type_script_lang_js_jsPlumb.connect({
229315
- source: connectsArr[j].PageSourceId,
229316
- target: connectsArr[j].PageTargetId,
229317
- anchors: anchor,
229318
- editable: true,
229319
- paintStyle: {
229320
- strokeStyle: '#438eb9',
229321
- fillStyle: '#438eb9',
229322
- radius: 5,
229323
- lineWidth: 2
229324
- },
229325
- parameters: {
229326
- pathId: connectsArr[j].ConnectionId
229361
+ // 选择加载的node拖放,支持单个、多个
229362
+ jquery_default()('.right-form').draggable({
229363
+ containment: '#center'
229364
+ });
229365
+ jquery_default()('.process').draggable({
229366
+ containment: '#center'
229367
+ });
229368
+ jquery_default()('.process').draggable({
229369
+ distance: 20
229370
+ });
229371
+ jquery_default()('.process').draggable({
229372
+ start: function start() {
229373
+ startMove();
229374
+ Centervue_type_script_lang_js_jsPlumb.repaintEverything();
229327
229375
  },
229328
- endpointStyle: {
229329
- fill: 'lightgray',
229330
- outlineStroke: 'darkgray',
229331
- outlineWidth: 2
229376
+ drag: function drag(event, ui) {
229377
+ var uiid = event.target.id;
229378
+ MoveSelectDiv(event, ui, uiid);
229379
+ _this3.isDomChange = true; // 如果dom移动
229380
+ Centervue_type_script_lang_js_jsPlumb.repaintEverything();
229332
229381
  },
229333
- connector: connector,
229334
- overlays: [['Arrow', {
229335
- width: 10,
229336
- length: 10,
229337
- location: 1
229338
- }]],
229339
- endpoint: ['Dot', {
229340
- radius: 5
229341
- }],
229342
- cssClass: 'line_path'
229382
+ stop: function stop() {
229383
+ Centervue_type_script_lang_js_jsPlumb.repaintEverything();
229384
+ }
229343
229385
  });
229344
- try {
229345
- a.setLabel({
229346
- label: labelText,
229347
- cssClass: 'line_text'
229348
- });
229349
- a = null;
229350
- } catch (e) {
229351
- console.log(e);
229352
- }
229353
- }
229354
- // 选择加载的node拖放,支持单个、多个
229355
- jquery_default()('.right-form').draggable({
229356
- containment: '#center'
229357
- });
229358
- jquery_default()('.process').draggable({
229359
- containment: '#center'
229360
- });
229361
- jquery_default()('.process').draggable({
229362
- distance: 20
229363
- });
229364
- jquery_default()('.process').draggable({
229365
- start: function start() {
229366
- startMove();
229367
- Centervue_type_script_lang_js_jsPlumb.repaintEverything();
229368
- },
229369
- drag: function drag(event, ui) {
229370
- var uiid = event.target.id;
229371
- MoveSelectDiv(event, ui, uiid);
229372
- _this2.isDomChange = true; // 如果dom移动
229373
- Centervue_type_script_lang_js_jsPlumb.repaintEverything();
229374
- },
229375
- stop: function stop() {
229376
- Centervue_type_script_lang_js_jsPlumb.repaintEverything();
229377
- }
229378
- });
229379
- _this2.dataStatus = false;
229380
-
229381
- // 环节点击动态绑定
229382
- // nodeClick();
229383
- jquery_default()('.process').bind('click', function (el) {
229384
- jquery_default()('.process').removeClass('seled');
229385
- jquery_default()(el.currentTarget).addClass('seled');
229386
- _this2.getHistroyNodes();
229387
- var curId = jquery_default()(el.currentTarget).attr('id');
229388
- for (var _j = 0; _j < _this2.wflow.nodes.length; _j++) {
229389
- if (curId === _this2.wflow.nodes[_j].id) {
229390
- _this2.curNode = _this2.wflow.nodes[_j];
229391
- jquery_default()(el.currentTarget).attr('id', _this2.wflow.nodes[_j].id);
229392
- break;
229386
+ _this3.dataStatus = false;
229387
+
229388
+ // 环节点击动态绑定
229389
+ // nodeClick();
229390
+ jquery_default()('.process').bind('click', function (el) {
229391
+ jquery_default()('.process').removeClass('seled');
229392
+ jquery_default()(el.currentTarget).addClass('seled');
229393
+ _this3.getHistroyNodes();
229394
+ var curId = jquery_default()(el.currentTarget).attr('id');
229395
+ for (var _j = 0; _j < _this3.wflow.nodes.length; _j++) {
229396
+ if (curId === _this3.wflow.nodes[_j].id) {
229397
+ _this3.curNode = _this3.wflow.nodes[_j];
229398
+ jquery_default()(el.currentTarget).attr('id', _this3.wflow.nodes[_j].id);
229399
+ break;
229400
+ }
229393
229401
  }
229394
- }
229395
- _this2.curNodeOperationArr = [];
229396
- // console.log(this.wflow)
229397
- // for (let t = 0; t < this.wflow.operations.length; t++) {
229398
- // if (this.wflow.operations[t].nodeId === curId) {
229399
- // this.curNodeOperationArr.push(this.wflow.operations[t])
229400
- // }
229401
- // }
229402
+ _this3.curNodeOperationArr = [];
229403
+ // console.log(this.wflow)
229404
+ // for (let t = 0; t < this.wflow.operations.length; t++) {
229405
+ // if (this.wflow.operations[t].nodeId === curId) {
229406
+ // this.curNodeOperationArr.push(this.wflow.operations[t])
229407
+ // }
229408
+ // }
229402
229409
 
229403
- // 获取环节指定机构、指定群组、指定岗位、指定处理人
229404
- // this.getNodeSpecialData(curId)
229410
+ // 获取环节指定机构、指定群组、指定岗位、指定处理人
229411
+ // this.getNodeSpecialData(curId)
229405
229412
 
229406
- // 获取需要等待的环节
229407
- _this2.getWaitNode();
229408
- _this2.emitData();
229409
- // $scope.$apply()
229413
+ // 获取需要等待的环节
229414
+ _this3.getWaitNode();
229415
+ _this3.emitData();
229416
+ // $scope.$apply()
229417
+ });
229418
+ // 双击给该元素动态添加锚点
229419
+ _this3.AddAnchor();
229420
+ _this3.oldWflow = JSON.parse(JSON.stringify(_this3.wflow));
229421
+ }, function (error) {
229422
+ _this3.$message.error(error);
229410
229423
  });
229411
- // 双击给该元素动态添加锚点
229412
- _this2.AddAnchor();
229413
- _this2.oldWflow = JSON.parse(JSON.stringify(_this2.wflow));
229414
- }, function (error) {
229415
- _this2.$message.error(error);
229416
- });
229417
- } else {
229418
- // 新增流程配置
229419
- // this.process.createTim = moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
229420
- // this.process.creator = this.loginUser.personAccount
229421
- // this.$set(this.process, 'orgName', this.loginUser.orgName)
229422
- // this.$set(this.process, 'orgCode', this.loginUser.orgCode)
229423
- this.$http({
229424
- method: 'POST',
229425
- contentType: 'application/x-www-form-urlencoded',
229426
- url: '/voice/scene/addNew'
229427
- }).then(function (res) {
229428
- if (res.code === 'success') {
229429
- console.log(res);
229430
- _this2.process = res.body.vo.scene;
229431
- _this2.process.createName = _this2.loginUser.personAccount;
229432
- _this2.emitData();
229433
- }
229434
- });
229435
- }
229436
- /** *************************************路径数据******************************************/
229437
- // const a = null
229438
- var clickEndpoints = null; // 用于储存路径的目标端点
229439
- var isClickPath = false;
229440
- // 1路径创建
229441
- Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229442
- if (!jquery_default()(info.source).hasClass('dfzjd')) {
229443
- info.connection.setHoverPaintStyle({
229444
- stroke: 'red'
229424
+ } else {
229425
+ // 新增流程配置
229426
+ // this.process.createTim = moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
229427
+ // this.process.creator = this.loginUser.personAccount
229428
+ // this.$set(this.process, 'orgName', this.loginUser.orgName)
229429
+ // this.$set(this.process, 'orgCode', this.loginUser.orgCode)
229430
+ this.$http({
229431
+ method: 'POST',
229432
+ contentType: 'application/x-www-form-urlencoded',
229433
+ url: '/voice/scene/addNew'
229434
+ }).then(function (res) {
229435
+ if (res.code === 'success') {
229436
+ console.log(res);
229437
+ _this3.process = res.body.vo.scene;
229438
+ _this3.process.createName = _this3.loginUser.personAccount;
229439
+ _this3.emitData();
229440
+ }
229445
229441
  });
229446
229442
  }
229447
- info.connection.setPaintStyle({
229448
- stroke: '#438eb9',
229449
- fillStyle: '#438eb9',
229450
- radius: 5
229451
- });
229452
- _this2.dragPath(info);
229453
- // 用于比较数据是否改变
229454
- _this2.oldWflow = JSON.parse(JSON.stringify(_this2.wflow));
229455
- _this2.ComparePath();
229456
- _this2.emitData();
229457
- return false;
229458
- });
229459
- Centervue_type_script_lang_js_jsPlumb.bind('mousedown', function (connection, originalEvent) {
229460
- var thisConnect = {};
229461
- var len = _this2.connectsArr.length;
229462
- for (var i = 0; i < len; i++) {
229463
- if (connection.id === _this2.connectsArr[i].ConnectionId) {
229464
- thisConnect = _this2.connectsArr[i];
229465
- break;
229443
+ /** *************************************路径数据******************************************/
229444
+ // const a = null
229445
+ var clickEndpoints = null; // 用于储存路径的目标端点
229446
+ var isClickPath = false;
229447
+ // 1路径创建
229448
+ Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229449
+ if (!jquery_default()(info.source).hasClass('dfzjd')) {
229450
+ info.connection.setHoverPaintStyle({
229451
+ stroke: 'red'
229452
+ });
229466
229453
  }
229467
- }
229468
- // 1储存路径目标端点
229469
- clickEndpoints = connection.endpoints[1];
229470
- console.log;
229471
- // 2设置下一端点可分离
229472
- clickEndpoints._jsPlumb.maxConnections = 1;
229473
- _this2.clickPath(connection); //, 此事件会跟click事件冲突,可以把事件函数放在这里执行
229474
- // 设置路径颜色
229475
- _this2.dragLineObj.init(connection, thisConnect);
229476
- if (!jquery_default()(connection.source).hasClass('dfzjd')) {
229477
- connection.setPaintStyle({
229478
- stroke: 'red'
229454
+ info.connection.setPaintStyle({
229455
+ stroke: '#438eb9',
229456
+ fillStyle: '#438eb9',
229457
+ radius: 5
229479
229458
  });
229480
- }
229481
- var isPathFieldValue = true;
229482
- var isAddPathFieldValue = true;
229483
- var isJobPathFieldValue = true;
229484
- if (!_this2.curPath.multiLevelPathFieldValue) {
229485
- _this2.curPath.multiLevelPathFieldValue = {};
229486
- }
229487
- for (var _i = 0; _i < _this2.wflow.pathFieldValues.length; _i++) {
229488
- if (_this2.wflow.pathFieldValues[_i].pathId === _this2.curPath.id) {
229489
- if (_this2.wflow.pathFieldValues[_i].valueType === 0) {
229490
- _this2.curPath.multiLevelPathFieldValue[_this2.wflow.pathFieldValues[_i].value] = true;
229491
- }
229492
- if (_this2.wflow.pathFieldValues[_i].valueType === 1) {
229493
- _this2.pathFieldValue = _this2.wflow.pathFieldValues[_i];
229494
- isPathFieldValue = false;
229495
- } else if (_this2.wflow.pathFieldValues[_i].valueType === 2) {
229496
- _this2.addPathFieldValue = _this2.wflow.pathFieldValues[_i];
229497
- isAddPathFieldValue = false;
229498
- } else if (_this2.wflow.pathFieldValues[_i].valueType === 3) {
229499
- _this2.jobPathFieldValue = _this2.wflow.pathFieldValues[_i];
229500
- isJobPathFieldValue = false;
229501
- }
229502
- } else {
229503
- if (isPathFieldValue) {
229504
- _this2.pathFieldValue = {};
229505
- }
229506
- if (isAddPathFieldValue) {
229507
- _this2.addPathFieldValue = {};
229508
- }
229509
- if (isJobPathFieldValue) {
229510
- _this2.jobPathFieldValue = {};
229459
+ _this3.dragPath(info);
229460
+ // 用于比较数据是否改变
229461
+ _this3.oldWflow = JSON.parse(JSON.stringify(_this3.wflow));
229462
+ _this3.ComparePath();
229463
+ _this3.emitData();
229464
+ return false;
229465
+ });
229466
+ Centervue_type_script_lang_js_jsPlumb.bind('mousedown', function (connection, originalEvent) {
229467
+ var thisConnect = {};
229468
+ var len = _this3.connectsArr.length;
229469
+ for (var i = 0; i < len; i++) {
229470
+ if (connection.id === _this3.connectsArr[i].ConnectionId) {
229471
+ thisConnect = _this3.connectsArr[i];
229472
+ break;
229511
229473
  }
229512
229474
  }
229513
- }
229514
- _this2.emitData();
229515
- // $scope.$apply();
229516
- return false;
229517
- });
229518
- // 2路径点击
229519
- Centervue_type_script_lang_js_jsPlumb.bind('click', function (conn, originalEvent) {
229520
- console.log('路径点击');
229521
- if (jquery_default()('.panel_path').css('display') !== 'none') {
229522
- if (!jquery_default()(conn.source).hasClass('dfzjd')) {
229523
- conn.setPaintStyle({
229475
+ // 1储存路径目标端点
229476
+ clickEndpoints = connection.endpoints[1];
229477
+ console.log;
229478
+ // 2设置下一端点可分离
229479
+ clickEndpoints._jsPlumb.maxConnections = 1;
229480
+ _this3.clickPath(connection); //, 此事件会跟click事件冲突,可以把事件函数放在这里执行
229481
+ // 设置路径颜色
229482
+ _this3.dragLineObj.init(connection, thisConnect);
229483
+ if (!jquery_default()(connection.source).hasClass('dfzjd')) {
229484
+ connection.setPaintStyle({
229524
229485
  stroke: 'red'
229525
229486
  });
229526
229487
  }
229527
- }
229528
- jquery_default()('.process').removeClass('seled');
229529
- isClickPath = true;
229530
- return false;
229531
- });
229488
+ var isPathFieldValue = true;
229489
+ var isAddPathFieldValue = true;
229490
+ var isJobPathFieldValue = true;
229491
+ if (!_this3.curPath.multiLevelPathFieldValue) {
229492
+ _this3.curPath.multiLevelPathFieldValue = {};
229493
+ }
229494
+ for (var _i = 0; _i < _this3.wflow.pathFieldValues.length; _i++) {
229495
+ if (_this3.wflow.pathFieldValues[_i].pathId === _this3.curPath.id) {
229496
+ if (_this3.wflow.pathFieldValues[_i].valueType === 0) {
229497
+ _this3.curPath.multiLevelPathFieldValue[_this3.wflow.pathFieldValues[_i].value] = true;
229498
+ }
229499
+ if (_this3.wflow.pathFieldValues[_i].valueType === 1) {
229500
+ _this3.pathFieldValue = _this3.wflow.pathFieldValues[_i];
229501
+ isPathFieldValue = false;
229502
+ } else if (_this3.wflow.pathFieldValues[_i].valueType === 2) {
229503
+ _this3.addPathFieldValue = _this3.wflow.pathFieldValues[_i];
229504
+ isAddPathFieldValue = false;
229505
+ } else if (_this3.wflow.pathFieldValues[_i].valueType === 3) {
229506
+ _this3.jobPathFieldValue = _this3.wflow.pathFieldValues[_i];
229507
+ isJobPathFieldValue = false;
229508
+ }
229509
+ } else {
229510
+ if (isPathFieldValue) {
229511
+ _this3.pathFieldValue = {};
229512
+ }
229513
+ if (isAddPathFieldValue) {
229514
+ _this3.addPathFieldValue = {};
229515
+ }
229516
+ if (isJobPathFieldValue) {
229517
+ _this3.jobPathFieldValue = {};
229518
+ }
229519
+ }
229520
+ }
229521
+ _this3.emitData();
229522
+ // $scope.$apply();
229523
+ return false;
229524
+ });
229525
+ // 2路径点击
229526
+ Centervue_type_script_lang_js_jsPlumb.bind('click', function (conn, originalEvent) {
229527
+ console.log('路径点击');
229528
+ if (jquery_default()('.panel_path').css('display') !== 'none') {
229529
+ if (!jquery_default()(conn.source).hasClass('dfzjd')) {
229530
+ conn.setPaintStyle({
229531
+ stroke: 'red'
229532
+ });
229533
+ }
229534
+ }
229535
+ jquery_default()('.process').removeClass('seled');
229536
+ isClickPath = true;
229537
+ return false;
229538
+ });
229532
229539
 
229533
- // 3路径删除
229534
- // 3.1自定义右键菜单
229535
- jquery_default()(document).bind('contextmenu', function () {
229536
- return false;
229537
- });
229538
- jquery_default()(document).click(function () {
229539
- jquery_default()('#centextMenu').hide();
229540
- });
229540
+ // 3路径删除
229541
+ // 3.1自定义右键菜单
229542
+ jquery_default()(document).bind('contextmenu', function () {
229543
+ return false;
229544
+ });
229545
+ jquery_default()(document).click(function () {
229546
+ jquery_default()('#centextMenu').hide();
229547
+ });
229541
229548
 
229542
- // 处理兼容点击连线状态
229549
+ // 处理兼容点击连线状态
229543
229550
 
229544
- jquery_default()('#center').click(function () {
229545
- var aConn = Centervue_type_script_lang_js_jsPlumb.getConnections(); // 获取容器所有的连接线
229546
- for (var i = 0; i < aConn.length; i++) {
229547
- aConn[i].setPaintStyle({
229548
- stroke: '#438eb9',
229549
- fillStyle: '#438eb9',
229550
- radius: 5
229551
- });
229552
- }
229553
- // 处理端点最大连接数
229554
- if (clickEndpoints) {
229555
- if (isClickPath && clickEndpoints._jsPlumb) {
229556
- clickEndpoints._jsPlumb.maxConnections = -1;
229557
- // console.log('连接多个')
229558
- }
229559
- isClickPath = false;
229560
- }
229561
- });
229562
- Centervue_type_script_lang_js_jsPlumb.bind('contextmenu', function (conn, originalEvent) {
229563
- // console.log(conn.id)
229564
- // for (let i = 0; i < this.wflow.paths.length; i++) {
229565
- // console.log(this.wflow.paths[i].id)
229566
- // }
229567
- // onst centerLeft = $('#center').css('marginLeft')
229568
- // const leftVal = parseInt(centerLeft.slice(0, centerLeft.indexOf('px')))
229569
- // const topVal = $('#head').outerHeight()
229570
- if (jquery_default()('#centextMenu').length > 0) {
229571
- jquery_default()('#centextMenu').remove();
229572
- }
229573
- var centextMenu = '<div id="centextMenu" style=" top:' + originalEvent.pageY + 'px;left:' + originalEvent.pageX + 'px;">' + '<a class="delete_line" href="javascript:;">删除连接线</a><a class="change_line_workline" href="javascript:;">转变为折线</a>' + '<a class="change_line_stright" href="javascript:;">转变为直线</a><a class="change_line_Bezier" href="javascript:;">转变为曲线</a></div>';
229574
- jquery_default()('#center').append(centextMenu);
229575
- jquery_default()('.delete_line').bind('click', function () {
229576
- // 删除连线时,获取连线的id,循环所有nextNodes的pathId,如果是删除的连线id,删除nextNode
229577
- var deleteConnId = conn.id;
229578
- console.log(conn.sourceId);
229579
- for (var i = 0; i < _this2.wflow.nextNodes.length; i++) {
229580
- if (_this2.wflow.nextNodes[i].pathId === deleteConnId || _this2.wflow.nextNodes[i].nextNodeId === conn.targetId) {
229581
- _this2.wflow.nextNodes.splice(i, 1);
229582
- }
229583
- }
229584
- for (var _i2 = 0; _i2 < _this2.wflow.pathFieldValues.length; _i2++) {
229585
- if (_this2.wflow.pathFieldValues[_i2].pathId === deleteConnId) {
229586
- _this2.wflow.pathFieldValues.splice(_i2, 1);
229587
- }
229588
- }
229589
- for (var _i3 = 0; _i3 < _this2.wflow.paths.length; _i3++) {
229590
- console.log(_this2.wflow.paths[_i3].id);
229591
- if (conn.id === _this2.wflow.paths[_i3].id) {
229592
- _this2.wflow.paths.splice(_i3, 1);
229593
- }
229594
- }
229595
- Centervue_type_script_lang_js_jsPlumb.deleteConnection(conn);
229596
- // 删除wflow.paths中的path
229597
- });
229598
- // 改变为直线
229599
- jquery_default()('.change_line_stright').bind('click', function () {
229600
- // 删除连线时,获取连线的id,循环所有nextNodes的pathId,如果是删除的连线id,删除nextNode
229601
- if (conn.type === 'Straight') return;
229602
- console.log(_this2.getWflow, _this2.getWflow.length);
229603
- var result = _this2.getWflow.some(function (item) {
229604
- return conn.id === item;
229605
- });
229606
- if (!result) {
229607
- _this2.$message({
229608
- type: 'warning',
229609
- message: '请先保存后再进行此操作'
229551
+ jquery_default()('#center').click(function () {
229552
+ var aConn = Centervue_type_script_lang_js_jsPlumb.getConnections(); // 获取容器所有的连接线
229553
+ for (var i = 0; i < aConn.length; i++) {
229554
+ aConn[i].setPaintStyle({
229555
+ stroke: '#438eb9',
229556
+ fillStyle: '#438eb9',
229557
+ radius: 5
229610
229558
  });
229611
- return;
229612
- } else {
229613
- _this2.dataStatus = true;
229614
- // const fristrow = [conn.endpoints[0].anchor.x, conn.endpoints[0].anchor.y, conn.endpoints[0].anchor.orientation[0], conn.endpoints[0].anchor.orientation[1]]
229615
- // const secrow = [conn.endpoints[1].anchor.x, conn.endpoints[1].anchor.y, conn.endpoints[1].anchor.orientation[0], conn.endpoints[1].anchor.orientation[1]]
229616
- // const anchor = [fristrow, secrow]
229559
+ }
229560
+ // 处理端点最大连接数
229561
+ if (clickEndpoints) {
229562
+ if (isClickPath && clickEndpoints._jsPlumb) {
229563
+ clickEndpoints._jsPlumb.maxConnections = -1;
229564
+ // console.log('连接多个')
229565
+ }
229566
+ isClickPath = false;
229567
+ }
229568
+ });
229569
+ Centervue_type_script_lang_js_jsPlumb.bind('contextmenu', function (conn, originalEvent) {
229570
+ // console.log(conn.id)
229571
+ // for (let i = 0; i < this.wflow.paths.length; i++) {
229572
+ // console.log(this.wflow.paths[i].id)
229573
+ // }
229574
+ // onst centerLeft = $('#center').css('marginLeft')
229575
+ // const leftVal = parseInt(centerLeft.slice(0, centerLeft.indexOf('px')))
229576
+ // const topVal = $('#head').outerHeight()
229577
+ if (jquery_default()('#centextMenu').length > 0) {
229578
+ jquery_default()('#centextMenu').remove();
229579
+ }
229580
+ var centextMenu = '<div id="centextMenu" style=" top:' + originalEvent.pageY + 'px;left:' + originalEvent.pageX + 'px;">' + '<a class="delete_line" href="javascript:;">删除连接线</a><a class="change_line_workline" href="javascript:;">转变为折线</a>' + '<a class="change_line_stright" href="javascript:;">转变为直线</a><a class="change_line_Bezier" href="javascript:;">转变为曲线</a></div>';
229581
+ jquery_default()('#center').append(centextMenu);
229582
+ jquery_default()('.delete_line').bind('click', function () {
229583
+ // 删除连线时,获取连线的id,循环所有nextNodes的pathId,如果是删除的连线id,删除nextNode
229617
229584
  var deleteConnId = conn.id;
229618
- for (var i = 0; i < _this2.wflow.nextNodes.length; i++) {
229619
- if (_this2.wflow.nextNodes[i].pathId === deleteConnId) {
229620
- _this2.wflow.nextNodes.splice(i, 1);
229585
+ console.log(conn.sourceId);
229586
+ for (var i = 0; i < _this3.wflow.nextNodes.length; i++) {
229587
+ if (_this3.wflow.nextNodes[i].pathId === deleteConnId || _this3.wflow.nextNodes[i].nextNodeId === conn.targetId) {
229588
+ _this3.wflow.nextNodes.splice(i, 1);
229589
+ }
229590
+ }
229591
+ for (var _i2 = 0; _i2 < _this3.wflow.pathFieldValues.length; _i2++) {
229592
+ if (_this3.wflow.pathFieldValues[_i2].pathId === deleteConnId) {
229593
+ _this3.wflow.pathFieldValues.splice(_i2, 1);
229621
229594
  }
229622
229595
  }
229623
- for (var _i4 = 0; _i4 < _this2.wflow.pathFieldValues.length; _i4++) {
229624
- if (_this2.wflow.pathFieldValues[_i4].pathId === deleteConnId) {
229625
- _this2.wflow.pathFieldValues.splice(_i4, 1);
229596
+ for (var _i3 = 0; _i3 < _this3.wflow.paths.length; _i3++) {
229597
+ console.log(_this3.wflow.paths[_i3].id);
229598
+ if (conn.id === _this3.wflow.paths[_i3].id) {
229599
+ _this3.wflow.paths.splice(_i3, 1);
229626
229600
  }
229627
229601
  }
229628
229602
  Centervue_type_script_lang_js_jsPlumb.deleteConnection(conn);
229629
229603
  // 删除wflow.paths中的path
229630
- for (var _i5 = 0; _i5 < _this2.connectsArr.length; _i5++) {
229631
- if (conn.id === _this2.connectsArr[_i5].ConnectionId) {
229632
- _this2.PathLabelText = _this2.connectsArr[_i5].label;
229633
- // conn.connector.type = 'Straight'
229634
- _this2.wflow.paths.splice(_i5, 1);
229635
- // console.log(this.wflow.paths)
229636
- var fristrow = _this2.connectsArr[_i5].firstEndpoints;
229637
- var secrow = _this2.connectsArr[_i5].secondEndpoints;
229638
- var anchor = [fristrow, secrow];
229639
- var a = Centervue_type_script_lang_js_jsPlumb.connect({
229640
- source: _this2.connectsArr[_i5].PageSourceId,
229641
- target: _this2.connectsArr[_i5].PageTargetId,
229642
- anchors: anchor,
229643
- editable: true,
229644
- paintStyle: {
229645
- strokeStyle: '#438eb9',
229646
- fillStyle: '#438eb9',
229647
- radius: 5,
229648
- lineWidth: 2
229649
- },
229650
- parameters: {
229651
- pathId: _this2.connectsArr[_i5].ConnectionId
229652
- },
229653
- endpointStyle: {
229654
- fill: 'lightgray',
229655
- outlineStroke: 'darkgray',
229656
- outlineWidth: 2
229657
- },
229658
- connector: ['Straight', {
229659
- stub: 0,
229660
- gap: 0
229661
- }],
229662
- overlays: [['Arrow', {
229663
- width: 10,
229664
- length: 10,
229665
- location: 1
229666
- }]],
229667
- endpoint: ['Dot', {
229668
- radius: 5
229669
- }],
229670
- cssClass: 'line_path'
229671
- });
229672
- try {
229673
- a.setLabel({
229674
- label: _this2.PathLabelText
229604
+ });
229605
+ // 改变为直线
229606
+ jquery_default()('.change_line_stright').bind('click', function () {
229607
+ // 删除连线时,获取连线的id,循环所有nextNodes的pathId,如果是删除的连线id,删除nextNode
229608
+ if (conn.type === 'Straight') return;
229609
+ console.log(_this3.getWflow, _this3.getWflow.length);
229610
+ var result = _this3.getWflow.some(function (item) {
229611
+ return conn.id === item;
229612
+ });
229613
+ if (!result) {
229614
+ _this3.$message({
229615
+ type: 'warning',
229616
+ message: '请先保存后再进行此操作'
229617
+ });
229618
+ return;
229619
+ } else {
229620
+ _this3.dataStatus = true;
229621
+ // const fristrow = [conn.endpoints[0].anchor.x, conn.endpoints[0].anchor.y, conn.endpoints[0].anchor.orientation[0], conn.endpoints[0].anchor.orientation[1]]
229622
+ // const secrow = [conn.endpoints[1].anchor.x, conn.endpoints[1].anchor.y, conn.endpoints[1].anchor.orientation[0], conn.endpoints[1].anchor.orientation[1]]
229623
+ // const anchor = [fristrow, secrow]
229624
+ var deleteConnId = conn.id;
229625
+ for (var i = 0; i < _this3.wflow.nextNodes.length; i++) {
229626
+ if (_this3.wflow.nextNodes[i].pathId === deleteConnId) {
229627
+ _this3.wflow.nextNodes.splice(i, 1);
229628
+ }
229629
+ }
229630
+ for (var _i4 = 0; _i4 < _this3.wflow.pathFieldValues.length; _i4++) {
229631
+ if (_this3.wflow.pathFieldValues[_i4].pathId === deleteConnId) {
229632
+ _this3.wflow.pathFieldValues.splice(_i4, 1);
229633
+ }
229634
+ }
229635
+ Centervue_type_script_lang_js_jsPlumb.deleteConnection(conn);
229636
+ // 删除wflow.paths中的path
229637
+ for (var _i5 = 0; _i5 < _this3.connectsArr.length; _i5++) {
229638
+ if (conn.id === _this3.connectsArr[_i5].ConnectionId) {
229639
+ _this3.PathLabelText = _this3.connectsArr[_i5].label;
229640
+ // conn.connector.type = 'Straight'
229641
+ _this3.wflow.paths.splice(_i5, 1);
229642
+ // console.log(this.wflow.paths)
229643
+ var fristrow = _this3.connectsArr[_i5].firstEndpoints;
229644
+ var secrow = _this3.connectsArr[_i5].secondEndpoints;
229645
+ var anchor = [fristrow, secrow];
229646
+ var a = Centervue_type_script_lang_js_jsPlumb.connect({
229647
+ source: _this3.connectsArr[_i5].PageSourceId,
229648
+ target: _this3.connectsArr[_i5].PageTargetId,
229649
+ anchors: anchor,
229650
+ editable: true,
229651
+ paintStyle: {
229652
+ strokeStyle: '#438eb9',
229653
+ fillStyle: '#438eb9',
229654
+ radius: 5,
229655
+ lineWidth: 2
229656
+ },
229657
+ parameters: {
229658
+ pathId: _this3.connectsArr[_i5].ConnectionId
229659
+ },
229660
+ endpointStyle: {
229661
+ fill: 'lightgray',
229662
+ outlineStroke: 'darkgray',
229663
+ outlineWidth: 2
229664
+ },
229665
+ connector: ['Straight', {
229666
+ stub: 0,
229667
+ gap: 0
229668
+ }],
229669
+ overlays: [['Arrow', {
229670
+ width: 10,
229671
+ length: 10,
229672
+ location: 1
229673
+ }]],
229674
+ endpoint: ['Dot', {
229675
+ radius: 5
229676
+ }],
229677
+ cssClass: 'line_path'
229675
229678
  });
229676
- a = null;
229677
- } catch (e) {
229678
- console.log(e);
229679
+ try {
229680
+ a.setLabel({
229681
+ label: _this3.PathLabelText
229682
+ });
229683
+ a = null;
229684
+ } catch (e) {
229685
+ console.log(e);
229686
+ }
229679
229687
  }
229680
229688
  }
229681
- }
229682
- Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229683
- if (!jquery_default()(info.source).hasClass('dfzjd')) {
229684
- info.connection.setHoverPaintStyle({
229685
- stroke: 'red'
229689
+ Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229690
+ if (!jquery_default()(info.source).hasClass('dfzjd')) {
229691
+ info.connection.setHoverPaintStyle({
229692
+ stroke: 'red'
229693
+ });
229694
+ }
229695
+ info.connection.setPaintStyle({
229696
+ stroke: '#438eb9',
229697
+ fillStyle: '#438eb9',
229698
+ radius: 5
229686
229699
  });
229687
- }
229688
- info.connection.setPaintStyle({
229689
- stroke: '#438eb9',
229690
- fillStyle: '#438eb9',
229691
- radius: 5
229700
+ _this3.dragPath(info);
229701
+ // 用于比较数据是否改变
229702
+ _this3.oldWflow = JSON.parse(JSON.stringify(_this3.wflow));
229703
+ _this3.emitData();
229704
+ return false;
229692
229705
  });
229693
- _this2.dragPath(info);
229694
- // 用于比较数据是否改变
229695
- _this2.oldWflow = JSON.parse(JSON.stringify(_this2.wflow));
229696
- _this2.emitData();
229697
- return false;
229698
- });
229699
- }
229700
- });
229701
- // 改变为曲线
229702
- jquery_default()('.change_line_Bezier').bind('click', function () {
229703
- // 删除连线时,获取连线的id,循环所有nextNodes的pathId,如果是删除的连线id,删除nextNode
229704
- if (conn.type === 'Bezier') return;
229705
- var result = _this2.getWflow.some(function (item) {
229706
- return conn.id === item;
229706
+ }
229707
229707
  });
229708
- if (!result) {
229709
- _this2.$message({
229710
- type: 'warning',
229711
- message: '请先保存后再进行次操作'
229708
+ // 改变为曲线
229709
+ jquery_default()('.change_line_Bezier').bind('click', function () {
229710
+ // 删除连线时,获取连线的id,循环所有nextNodes的pathId,如果是删除的连线id,删除nextNode
229711
+ if (conn.type === 'Bezier') return;
229712
+ var result = _this3.getWflow.some(function (item) {
229713
+ return conn.id === item;
229712
229714
  });
229713
- return;
229714
- } else {
229715
- _this2.dataStatus = true;
229716
- var fristrow = [conn.endpoints[0].anchor.x, conn.endpoints[0].anchor.y, conn.endpoints[0].anchor.orientation[0], conn.endpoints[0].anchor.orientation[1]];
229717
- var secrow = [conn.endpoints[1].anchor.x, conn.endpoints[1].anchor.y, conn.endpoints[1].anchor.orientation[0], conn.endpoints[1].anchor.orientation[1]];
229718
- var anchor = [fristrow, secrow];
229719
- console.log(anchor);
229720
- var deleteConnId = conn.id;
229721
- for (var i = 0; i < _this2.wflow.nextNodes.length; i++) {
229722
- if (_this2.wflow.nextNodes[i].pathId === deleteConnId) {
229723
- _this2.wflow.nextNodes.splice(i, 1);
229715
+ if (!result) {
229716
+ _this3.$message({
229717
+ type: 'warning',
229718
+ message: '请先保存后再进行次操作'
229719
+ });
229720
+ return;
229721
+ } else {
229722
+ _this3.dataStatus = true;
229723
+ var fristrow = [conn.endpoints[0].anchor.x, conn.endpoints[0].anchor.y, conn.endpoints[0].anchor.orientation[0], conn.endpoints[0].anchor.orientation[1]];
229724
+ var secrow = [conn.endpoints[1].anchor.x, conn.endpoints[1].anchor.y, conn.endpoints[1].anchor.orientation[0], conn.endpoints[1].anchor.orientation[1]];
229725
+ var anchor = [fristrow, secrow];
229726
+ console.log(anchor);
229727
+ var deleteConnId = conn.id;
229728
+ for (var i = 0; i < _this3.wflow.nextNodes.length; i++) {
229729
+ if (_this3.wflow.nextNodes[i].pathId === deleteConnId) {
229730
+ _this3.wflow.nextNodes.splice(i, 1);
229731
+ }
229724
229732
  }
229725
- }
229726
- for (var _i6 = 0; _i6 < _this2.wflow.pathFieldValues.length; _i6++) {
229727
- if (_this2.wflow.pathFieldValues[_i6].pathId === deleteConnId) {
229728
- _this2.wflow.pathFieldValues.splice(_i6, 1);
229733
+ for (var _i6 = 0; _i6 < _this3.wflow.pathFieldValues.length; _i6++) {
229734
+ if (_this3.wflow.pathFieldValues[_i6].pathId === deleteConnId) {
229735
+ _this3.wflow.pathFieldValues.splice(_i6, 1);
229736
+ }
229729
229737
  }
229730
- }
229731
- Centervue_type_script_lang_js_jsPlumb.deleteConnection(conn);
229732
- // 删除wflow.paths中的path
229733
- for (var _i7 = 0; _i7 < _this2.connectsArr.length; _i7++) {
229734
- if (conn.id === _this2.connectsArr[_i7].ConnectionId) {
229735
- _this2.PathLabelText = _this2.connectsArr[_i7].label;
229736
- // conn.connector.type = 'Straight'
229737
- _this2.wflow.paths.splice(_i7, 1);
229738
- var _fristrow = _this2.connectsArr[_i7].firstEndpoints;
229739
- var _secrow = _this2.connectsArr[_i7].secondEndpoints;
229740
- var _anchor = [_fristrow, _secrow];
229741
- var a = Centervue_type_script_lang_js_jsPlumb.connect({
229742
- source: _this2.connectsArr[_i7].PageSourceId,
229743
- target: _this2.connectsArr[_i7].PageTargetId,
229744
- anchors: _anchor,
229745
- editable: true,
229746
- paintStyle: {
229747
- strokeStyle: '#438eb9',
229748
- fillStyle: '#438eb9',
229749
- radius: 5,
229750
- lineWidth: 2
229751
- },
229752
- parameters: {
229753
- pathId: _this2.connectsArr[_i7].ConnectionId
229754
- },
229755
- endpointStyle: {
229756
- fill: 'lightgray',
229757
- outlineStroke: 'darkgray',
229758
- outlineWidth: 2
229759
- },
229760
- connector: ['Bezier', {
229761
- stub: 0,
229762
- gap: 0
229763
- }],
229764
- overlays: [['Arrow', {
229765
- width: 10,
229766
- length: 10,
229767
- location: 1
229768
- }]],
229769
- endpoint: ['Dot', {
229770
- radius: 5
229771
- }],
229772
- cssClass: 'line_path'
229773
- });
229774
- try {
229775
- a.setLabel({
229776
- label: _this2.PathLabelText
229738
+ Centervue_type_script_lang_js_jsPlumb.deleteConnection(conn);
229739
+ // 删除wflow.paths中的path
229740
+ for (var _i7 = 0; _i7 < _this3.connectsArr.length; _i7++) {
229741
+ if (conn.id === _this3.connectsArr[_i7].ConnectionId) {
229742
+ _this3.PathLabelText = _this3.connectsArr[_i7].label;
229743
+ // conn.connector.type = 'Straight'
229744
+ _this3.wflow.paths.splice(_i7, 1);
229745
+ var _fristrow = _this3.connectsArr[_i7].firstEndpoints;
229746
+ var _secrow = _this3.connectsArr[_i7].secondEndpoints;
229747
+ var _anchor = [_fristrow, _secrow];
229748
+ var a = Centervue_type_script_lang_js_jsPlumb.connect({
229749
+ source: _this3.connectsArr[_i7].PageSourceId,
229750
+ target: _this3.connectsArr[_i7].PageTargetId,
229751
+ anchors: _anchor,
229752
+ editable: true,
229753
+ paintStyle: {
229754
+ strokeStyle: '#438eb9',
229755
+ fillStyle: '#438eb9',
229756
+ radius: 5,
229757
+ lineWidth: 2
229758
+ },
229759
+ parameters: {
229760
+ pathId: _this3.connectsArr[_i7].ConnectionId
229761
+ },
229762
+ endpointStyle: {
229763
+ fill: 'lightgray',
229764
+ outlineStroke: 'darkgray',
229765
+ outlineWidth: 2
229766
+ },
229767
+ connector: ['Bezier', {
229768
+ stub: 0,
229769
+ gap: 0
229770
+ }],
229771
+ overlays: [['Arrow', {
229772
+ width: 10,
229773
+ length: 10,
229774
+ location: 1
229775
+ }]],
229776
+ endpoint: ['Dot', {
229777
+ radius: 5
229778
+ }],
229779
+ cssClass: 'line_path'
229777
229780
  });
229778
- a = null;
229779
- } catch (e) {
229780
- console.log(e);
229781
+ try {
229782
+ a.setLabel({
229783
+ label: _this3.PathLabelText
229784
+ });
229785
+ a = null;
229786
+ } catch (e) {
229787
+ console.log(e);
229788
+ }
229781
229789
  }
229782
229790
  }
229783
- }
229784
- Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229785
- if (!jquery_default()(info.source).hasClass('dfzjd')) {
229786
- info.connection.setHoverPaintStyle({
229787
- stroke: 'red'
229791
+ Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229792
+ if (!jquery_default()(info.source).hasClass('dfzjd')) {
229793
+ info.connection.setHoverPaintStyle({
229794
+ stroke: 'red'
229795
+ });
229796
+ }
229797
+ info.connection.setPaintStyle({
229798
+ stroke: '#438eb9',
229799
+ fillStyle: '#438eb9',
229800
+ radius: 5
229788
229801
  });
229789
- }
229790
- info.connection.setPaintStyle({
229791
- stroke: '#438eb9',
229792
- fillStyle: '#438eb9',
229793
- radius: 5
229802
+ _this3.dragPath(info);
229803
+ // 用于比较数据是否改变
229804
+ _this3.oldWflow = JSON.parse(JSON.stringify(_this3.wflow));
229805
+ _this3.emitData();
229806
+ return false;
229794
229807
  });
229795
- _this2.dragPath(info);
229796
- // 用于比较数据是否改变
229797
- _this2.oldWflow = JSON.parse(JSON.stringify(_this2.wflow));
229798
- _this2.emitData();
229799
- return false;
229800
- });
229801
- }
229802
- });
229803
- jquery_default()('.change_line_workline').bind('click', function () {
229804
- console.log(conn.type);
229805
- if (conn.type === 'Flowchart') return;
229806
- if (conn.type === 'Bezier') return;
229807
- var result = _this2.getWflow.some(function (item) {
229808
- return conn.id === item;
229808
+ }
229809
229809
  });
229810
- if (!result) {
229811
- _this2.$message({
229812
- type: 'warning',
229813
- message: '请先保存后再进行次操作'
229810
+ jquery_default()('.change_line_workline').bind('click', function () {
229811
+ console.log(conn.type);
229812
+ if (conn.type === 'Flowchart') return;
229813
+ if (conn.type === 'Bezier') return;
229814
+ var result = _this3.getWflow.some(function (item) {
229815
+ return conn.id === item;
229814
229816
  });
229815
- return;
229816
- } else {
229817
- _this2.dataStatus = true;
229818
- var fristrow = [conn.endpoints[0].anchor.x, conn.endpoints[0].anchor.y, conn.endpoints[0].anchor.orientation[0], conn.endpoints[0].anchor.orientation[1]];
229819
- var secrow = [conn.endpoints[1].anchor.x, conn.endpoints[1].anchor.y, conn.endpoints[1].anchor.orientation[0], conn.endpoints[1].anchor.orientation[1]];
229820
- var anchor = [fristrow, secrow];
229821
- console.log(anchor);
229822
- var deleteConnId = conn.id;
229823
- for (var i = 0; i < _this2.wflow.nextNodes.length; i++) {
229824
- if (_this2.wflow.nextNodes[i].pathId === deleteConnId) {
229825
- _this2.wflow.nextNodes.splice(i, 1);
229817
+ if (!result) {
229818
+ _this3.$message({
229819
+ type: 'warning',
229820
+ message: '请先保存后再进行次操作'
229821
+ });
229822
+ return;
229823
+ } else {
229824
+ _this3.dataStatus = true;
229825
+ var fristrow = [conn.endpoints[0].anchor.x, conn.endpoints[0].anchor.y, conn.endpoints[0].anchor.orientation[0], conn.endpoints[0].anchor.orientation[1]];
229826
+ var secrow = [conn.endpoints[1].anchor.x, conn.endpoints[1].anchor.y, conn.endpoints[1].anchor.orientation[0], conn.endpoints[1].anchor.orientation[1]];
229827
+ var anchor = [fristrow, secrow];
229828
+ console.log(anchor);
229829
+ var deleteConnId = conn.id;
229830
+ for (var i = 0; i < _this3.wflow.nextNodes.length; i++) {
229831
+ if (_this3.wflow.nextNodes[i].pathId === deleteConnId) {
229832
+ _this3.wflow.nextNodes.splice(i, 1);
229833
+ }
229826
229834
  }
229827
- }
229828
- for (var _i8 = 0; _i8 < _this2.wflow.pathFieldValues.length; _i8++) {
229829
- if (_this2.wflow.pathFieldValues[_i8].pathId === deleteConnId) {
229830
- _this2.wflow.pathFieldValues.splice(_i8, 1);
229835
+ for (var _i8 = 0; _i8 < _this3.wflow.pathFieldValues.length; _i8++) {
229836
+ if (_this3.wflow.pathFieldValues[_i8].pathId === deleteConnId) {
229837
+ _this3.wflow.pathFieldValues.splice(_i8, 1);
229838
+ }
229831
229839
  }
229832
- }
229833
- Centervue_type_script_lang_js_jsPlumb.deleteConnection(conn);
229834
- // 删除wflow.paths中的path
229835
- for (var _i9 = 0; _i9 < _this2.connectsArr.length; _i9++) {
229836
- if (conn.id === _this2.connectsArr[_i9].ConnectionId) {
229837
- _this2.PathLabelText = _this2.connectsArr[_i9].label;
229838
- // conn.connector.type = 'Straight'
229839
- _this2.wflow.paths.splice(_i9, 1);
229840
- var _fristrow2 = _this2.connectsArr[_i9].firstEndpoints;
229841
- var _secrow2 = _this2.connectsArr[_i9].secondEndpoints;
229842
- var _anchor2 = [_fristrow2, _secrow2];
229843
- var a = Centervue_type_script_lang_js_jsPlumb.connect({
229844
- source: _this2.connectsArr[_i9].PageSourceId,
229845
- target: _this2.connectsArr[_i9].PageTargetId,
229846
- anchors: _anchor2,
229847
- editable: true,
229848
- paintStyle: {
229849
- strokeStyle: '#438eb9',
229850
- fillStyle: '#438eb9',
229851
- radius: 5,
229852
- lineWidth: 2
229853
- },
229854
- parameters: {
229855
- pathId: _this2.connectsArr[_i9].ConnectionId
229856
- },
229857
- endpointStyle: {
229858
- fill: 'lightgray',
229859
- outlineStroke: 'darkgray',
229860
- outlineWidth: 2
229861
- },
229862
- connector: ['Flowchart', {
229863
- stub: [50, 50],
229864
- gap: 3,
229865
- cornerRadius: 5,
229866
- alwaysRespectStubs: false
229867
- }],
229868
- overlays: [['Arrow', {
229869
- width: 10,
229870
- length: 10,
229871
- location: 1
229872
- }]],
229873
- endpoint: ['Dot', {
229874
- radius: 5
229875
- }],
229876
- cssClass: 'line_path'
229877
- });
229878
- try {
229879
- a.setLabel({
229880
- label: _this2.PathLabelText
229840
+ Centervue_type_script_lang_js_jsPlumb.deleteConnection(conn);
229841
+ // 删除wflow.paths中的path
229842
+ for (var _i9 = 0; _i9 < _this3.connectsArr.length; _i9++) {
229843
+ if (conn.id === _this3.connectsArr[_i9].ConnectionId) {
229844
+ _this3.PathLabelText = _this3.connectsArr[_i9].label;
229845
+ // conn.connector.type = 'Straight'
229846
+ _this3.wflow.paths.splice(_i9, 1);
229847
+ var _fristrow2 = _this3.connectsArr[_i9].firstEndpoints;
229848
+ var _secrow2 = _this3.connectsArr[_i9].secondEndpoints;
229849
+ var _anchor2 = [_fristrow2, _secrow2];
229850
+ var a = Centervue_type_script_lang_js_jsPlumb.connect({
229851
+ source: _this3.connectsArr[_i9].PageSourceId,
229852
+ target: _this3.connectsArr[_i9].PageTargetId,
229853
+ anchors: _anchor2,
229854
+ editable: true,
229855
+ paintStyle: {
229856
+ strokeStyle: '#438eb9',
229857
+ fillStyle: '#438eb9',
229858
+ radius: 5,
229859
+ lineWidth: 2
229860
+ },
229861
+ parameters: {
229862
+ pathId: _this3.connectsArr[_i9].ConnectionId
229863
+ },
229864
+ endpointStyle: {
229865
+ fill: 'lightgray',
229866
+ outlineStroke: 'darkgray',
229867
+ outlineWidth: 2
229868
+ },
229869
+ connector: ['Flowchart', {
229870
+ stub: [50, 50],
229871
+ gap: 3,
229872
+ cornerRadius: 5,
229873
+ alwaysRespectStubs: false
229874
+ }],
229875
+ overlays: [['Arrow', {
229876
+ width: 10,
229877
+ length: 10,
229878
+ location: 1
229879
+ }]],
229880
+ endpoint: ['Dot', {
229881
+ radius: 5
229882
+ }],
229883
+ cssClass: 'line_path'
229881
229884
  });
229882
- a = null;
229883
- } catch (e) {
229884
- console.log(e);
229885
+ try {
229886
+ a.setLabel({
229887
+ label: _this3.PathLabelText
229888
+ });
229889
+ a = null;
229890
+ } catch (e) {
229891
+ console.log(e);
229892
+ }
229885
229893
  }
229886
229894
  }
229887
- }
229888
- Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229889
- if (!jquery_default()(info.source).hasClass('dfzjd')) {
229890
- info.connection.setHoverPaintStyle({
229891
- stroke: 'red'
229895
+ Centervue_type_script_lang_js_jsPlumb.bind('connection', function (info) {
229896
+ if (!jquery_default()(info.source).hasClass('dfzjd')) {
229897
+ info.connection.setHoverPaintStyle({
229898
+ stroke: 'red'
229899
+ });
229900
+ }
229901
+ info.connection.setPaintStyle({
229902
+ stroke: '#438eb9',
229903
+ fillStyle: '#438eb9',
229904
+ radius: 5
229892
229905
  });
229893
- }
229894
- info.connection.setPaintStyle({
229895
- stroke: '#438eb9',
229896
- fillStyle: '#438eb9',
229897
- radius: 5
229906
+ _this3.dragPath(info);
229907
+ // 用于比较数据是否改变
229908
+ _this3.oldWflow = JSON.parse(JSON.stringify(_this3.wflow));
229909
+ _this3.emitData();
229910
+ return false;
229898
229911
  });
229899
- _this2.dragPath(info);
229900
- // 用于比较数据是否改变
229901
- _this2.oldWflow = JSON.parse(JSON.stringify(_this2.wflow));
229902
- _this2.emitData();
229903
- return false;
229904
- });
229905
- }
229906
- });
229907
- _this2.dataStatus = false;
229908
- });
229909
- // 中间放置
229910
- jquery_default()('#center').droppable({
229911
- scope: 'plant',
229912
- drop: function drop(event, ui) {
229913
- // 工厂方式模型创建
229914
- var modelType = jquery_default()(ui.draggable).attr('associated');
229915
- var resize = jquery_default()(ui.draggable).attr('resize');
229916
- var domJoin = jquery_default()(ui.draggable).attr('domJoin');
229917
- var type = jquery_default()(ui.draggable).attr('type');
229918
-
229919
- // if ($(ui.draggable).attr('associated') === 'start') {
229920
- // model.start++
229921
- // }
229922
- // 1获取id,添加模型
229923
- var nid = model.CreateModel(ui, jquery_default()(event.target), resize, domJoin, modelType, type, _this2.wflow);
229924
- _this2.getProcessNum(modelType);
229925
-
229926
- // node创建时,初始化数据
229927
- _this2.curNode = {
229928
- sceneId: '',
229929
- // id
229930
- status: -1,
229931
- name: '',
229932
- // 节点名称
229933
- type: 1,
229934
- // 节点类型
229935
- problem: [],
229936
- // 问题示例
229937
- keywords: '',
229938
- // 匹配关键词
229939
- serial: _this2.wflow.nodes.length + 1,
229940
- // 节点顺序
229941
- // serial: 50, // 节点顺序
229942
- speakType: 0,
229943
- // 话术类型
229944
- performId: '',
229945
- // 执行动作id
229946
- createTime: '',
229947
- // 创建时间
229948
- updateTime: '',
229949
- // 更新时间
229950
- memo: '',
229951
- // 备注
229952
- id: nid,
229953
- SpeakMethod: [],
229954
- successSpeakMethod: [],
229955
- errorSpeakMethod: []
229956
- };
229957
- if (modelType === 'ptjd') {
229958
- _this2.curNode.type = 0;
229959
- } else if (modelType === 'zxjd') {
229960
- _this2.curNode.type = 1;
229961
- }
229962
- // 2把当前环境添加到全局nodes对象中
229963
- _this2.wflow.nodes.push(_this2.curNode);
229964
-
229965
- // 3当前node对象根据id=全局对象的id
229966
- for (var i = 0; i < _this2.wflow.nodes.length; i++) {
229967
- if (_this2.curNode.id === _this2.wflow.nodes[i].id) {
229968
- _this2.curNode = _this2.wflow.nodes[i];
229969
- break;
229970
229912
  }
229971
- }
229972
- _this2.emitData();
229973
-
229974
- // node点击动态绑定
229975
- // nodeClick();
229976
- jquery_default()('.process').bind('click', function (el) {
229977
- // debugger
229978
- jquery_default()('.process').removeClass('seled');
229979
- jquery_default()(el.currentTarget).addClass('seled');
229980
- _this2.getHistroyNodes();
229981
- var curId = jquery_default()(el.currentTarget).attr('id');
229982
- for (var j = 0; j < _this2.wflow.nodes.length; j++) {
229983
- if (curId === _this2.wflow.nodes[j].id) {
229984
- _this2.curNode = _this2.wflow.nodes[j];
229985
- jquery_default()(el.currentTarget).attr('id', _this2.wflow.nodes[j].id);
229913
+ });
229914
+ _this3.dataStatus = false;
229915
+ });
229916
+ // 中间放置
229917
+ jquery_default()('#center').droppable({
229918
+ scope: 'plant',
229919
+ drop: function drop(event, ui) {
229920
+ // 工厂方式模型创建
229921
+ var modelType = jquery_default()(ui.draggable).attr('associated');
229922
+ var resize = jquery_default()(ui.draggable).attr('resize');
229923
+ var domJoin = jquery_default()(ui.draggable).attr('domJoin');
229924
+ var type = jquery_default()(ui.draggable).attr('type');
229925
+
229926
+ // if ($(ui.draggable).attr('associated') === 'start') {
229927
+ // model.start++
229928
+ // }
229929
+ // 1获取id,添加模型
229930
+ var nid = model.CreateModel(ui, jquery_default()(event.target), resize, domJoin, modelType, type, _this3.wflow);
229931
+ _this3.getProcessNum(modelType);
229932
+
229933
+ // node创建时,初始化数据
229934
+ _this3.curNode = {
229935
+ sceneId: '',
229936
+ // id
229937
+ status: -1,
229938
+ name: '',
229939
+ // 节点名称
229940
+ type: 1,
229941
+ // 节点类型
229942
+ problem: [],
229943
+ // 问题示例
229944
+ keywords: '',
229945
+ // 匹配关键词
229946
+ serial: _this3.wflow.nodes.length + 1,
229947
+ // 节点顺序
229948
+ // serial: 50, // 节点顺序
229949
+ speakType: 0,
229950
+ // 话术类型
229951
+ performId: '',
229952
+ // 执行动作id
229953
+ createTime: '',
229954
+ // 创建时间
229955
+ updateTime: '',
229956
+ // 更新时间
229957
+ memo: '',
229958
+ // 备注
229959
+ id: nid,
229960
+ SpeakMethod: [],
229961
+ successSpeakMethod: [],
229962
+ errorSpeakMethod: []
229963
+ };
229964
+ if (modelType === 'ptjd') {
229965
+ _this3.curNode.type = 0;
229966
+ } else if (modelType === 'zxjd') {
229967
+ _this3.curNode.type = 1;
229968
+ }
229969
+ // 2把当前环境添加到全局nodes对象中
229970
+ _this3.wflow.nodes.push(_this3.curNode);
229971
+
229972
+ // 3当前node对象根据id=全局对象的id
229973
+ for (var i = 0; i < _this3.wflow.nodes.length; i++) {
229974
+ if (_this3.curNode.id === _this3.wflow.nodes[i].id) {
229975
+ _this3.curNode = _this3.wflow.nodes[i];
229986
229976
  break;
229987
229977
  }
229988
229978
  }
229989
- _this2.changeCurNodeType(jquery_default()(el.currentTarget));
229979
+ _this3.emitData();
229990
229980
 
229991
- // this.getNodeSpecialData(curId)// 点击环节时,设置环节指定处理人、指定岗位、指定群组、指定机构信息
229981
+ // node点击动态绑定
229982
+ // nodeClick();
229983
+ jquery_default()('.process').bind('click', function (el) {
229984
+ // debugger
229985
+ jquery_default()('.process').removeClass('seled');
229986
+ jquery_default()(el.currentTarget).addClass('seled');
229987
+ _this3.getHistroyNodes();
229988
+ var curId = jquery_default()(el.currentTarget).attr('id');
229989
+ for (var j = 0; j < _this3.wflow.nodes.length; j++) {
229990
+ if (curId === _this3.wflow.nodes[j].id) {
229991
+ _this3.curNode = _this3.wflow.nodes[j];
229992
+ jquery_default()(el.currentTarget).attr('id', _this3.wflow.nodes[j].id);
229993
+ break;
229994
+ }
229995
+ }
229996
+ _this3.changeCurNodeType(jquery_default()(el.currentTarget));
229992
229997
 
229993
- _this2.clickNodeFieldValues(); // 点击环节更新多域值
229994
- // this.clickNodeOperation()// 点击环节更新操作按钮
229995
- _this2.getWaitNode(); // 点击环节计算需要等待环节
229996
- _this2.emitData();
229997
- // $scope.$apply()
229998
- });
229999
- _this2.AddAnchor();
230000
- }
230001
- });
230002
- this.wflow.ideaLabels = [{}];
230003
- this.ideaArr = [];
230004
- },
230005
- methods: {
229998
+ // this.getNodeSpecialData(curId)// 点击环节时,设置环节指定处理人、指定岗位、指定群组、指定机构信息
229999
+
230000
+ _this3.clickNodeFieldValues(); // 点击环节更新多域值
230001
+ // this.clickNodeOperation()// 点击环节更新操作按钮
230002
+ _this3.getWaitNode(); // 点击环节计算需要等待环节
230003
+ _this3.emitData();
230004
+ // $scope.$apply()
230005
+ });
230006
+ _this3.AddAnchor();
230007
+ }
230008
+ });
230009
+ this.wflow.ideaLabels = [{}];
230010
+ this.ideaArr = [];
230011
+ },
230006
230012
  getNodeSpecialData: function getNodeSpecialData(curId) {
230007
230013
  // 点击环节时,设置环节指定处理人、指定岗位、指定群组、指定机构信息
230008
230014
  this.nodeFieldValue = {}; // 处理人-指定机构
@@ -230118,13 +230124,13 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230118
230124
  },
230119
230125
  // 点击环节计算需要等待环节
230120
230126
  getWaitNode: function getWaitNode() {
230121
- var _this3 = this;
230127
+ var _this4 = this;
230122
230128
  // waitNodeArr
230123
230129
  this.waitNodeArr = [];
230124
230130
  var ptNodeList = [];
230125
230131
  var ptNode = jquery_default()('#center').find('.process');
230126
230132
  ptNode.each(function (i, elem) {
230127
- var isPtNode = ptNode.eq(i).hasClass('start') || ptNode.eq(i).hasClass('jsrw') || ptNode.eq(i).hasClass('jslc') || ptNode.eq(i).hasClass('jcjd') || ptNode.eq(i).hasClass('zyjd') || ptNode.eq(i).hasClass('dfzjd') || ptNode.eq(i).hasClass('jhjd') || ptNode.eq(i).attr('id') === _this3.curNode.id;
230133
+ var isPtNode = ptNode.eq(i).hasClass('start') || ptNode.eq(i).hasClass('jsrw') || ptNode.eq(i).hasClass('jslc') || ptNode.eq(i).hasClass('jcjd') || ptNode.eq(i).hasClass('zyjd') || ptNode.eq(i).hasClass('dfzjd') || ptNode.eq(i).hasClass('jhjd') || ptNode.eq(i).attr('id') === _this4.curNode.id;
230128
230134
  if (!isPtNode) {
230129
230135
  ptNodeList.push(ptNode.eq(i));
230130
230136
  }
@@ -230153,18 +230159,18 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230153
230159
  }
230154
230160
  },
230155
230161
  dragPath: function dragPath(pathTarget) {
230156
- var _this4 = this;
230162
+ var _this5 = this;
230157
230163
  var isDargPath = false;
230158
230164
  // 连接被重绘时通知
230159
230165
  Centervue_type_script_lang_js_jsPlumb.bind('connectionMoved', function (info, originalEvent) {
230160
230166
  // 存储路径信息,然后删除
230161
230167
  // alert(333)
230162
230168
  isDargPath = true;
230163
- for (var i = 0; i < _this4.wflow.paths.length; i++) {
230164
- if (_this4.wflow.paths[i].id === info.connection.id) {
230165
- _this4.curp = _this4.wflow.paths[i];
230169
+ for (var i = 0; i < _this5.wflow.paths.length; i++) {
230170
+ if (_this5.wflow.paths[i].id === info.connection.id) {
230171
+ _this5.curp = _this5.wflow.paths[i];
230166
230172
  // const a = this.wflow.paths[i].name
230167
- _this4.wflow.paths.splice(i, 1);
230173
+ _this5.wflow.paths.splice(i, 1);
230168
230174
  }
230169
230175
  }
230170
230176
  });
@@ -230252,8 +230258,8 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230252
230258
  }
230253
230259
  if (this.curPath.beforNodeId !== '') {
230254
230260
  this.wflow.nodes.forEach(function (node) {
230255
- if (_this4.curPath.beforNodeId === node.id) {
230256
- _this4.curPath.preNodeName = node.name;
230261
+ if (_this5.curPath.beforNodeId === node.id) {
230262
+ _this5.curPath.preNodeName = node.name;
230257
230263
  }
230258
230264
  });
230259
230265
  }
@@ -230286,8 +230292,8 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230286
230292
  this.curPath.beforNodeId = jquery_default()(pathTarget.source).attr('id');
230287
230293
  this.curPath.ctrlType = 6;
230288
230294
  this.wflow.nodes.forEach(function (node) {
230289
- if (_this4.curPath.beforNodeId === node.id) {
230290
- _this4.curPath.preNodeName = node.name;
230295
+ if (_this5.curPath.beforNodeId === node.id) {
230296
+ _this5.curPath.preNodeName = node.name;
230291
230297
  }
230292
230298
  });
230293
230299
  // pathTarget.connection.id = uuid();
@@ -230674,7 +230680,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230674
230680
  },
230675
230681
  // 改变当前的环节类型
230676
230682
  changeCurNodeType: function changeCurNodeType(_this) {
230677
- var _this5 = this;
230683
+ var _this6 = this;
230678
230684
  if (_this.hasClass('ptjd')) {
230679
230685
  this.curNode.processType = 0;
230680
230686
  this.curNode.nodeType = 1;
@@ -230693,8 +230699,8 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230693
230699
  } else if (_this.hasClass('ywjd')) {
230694
230700
  // eslint-disable-next-line no-undef
230695
230701
  setTimeout(function () {
230696
- _this5.curNode.processType = 0;
230697
- _this5.curNode.nodeType = 3;
230702
+ _this6.curNode.processType = 0;
230703
+ _this6.curNode.nodeType = 3;
230698
230704
  }, 100);
230699
230705
  }
230700
230706
  // $scope.$apply();
@@ -230816,7 +230822,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230816
230822
  },
230817
230823
  // 保存流程验证
230818
230824
  customValidate: function customValidate(wflow) {
230819
- var _this6 = this;
230825
+ var _this7 = this;
230820
230826
  // 验证场景名称,场景类型
230821
230827
  if (this.wflow.scene.name === '' || this.wflow.scene.name === undefined || this.wflow.scene.name === null) {
230822
230828
  this.$message({
@@ -230834,67 +230840,67 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230834
230840
  }
230835
230841
  // 验证节点参数
230836
230842
  var _loop = function _loop(i) {
230837
- if (_this6.wflow.nodes[i].name === '' || _this6.wflow.nodes[i].name === undefined) {
230838
- _this6.validateNode(_this6.wflow.nodes[i], '请填写任务名称');
230843
+ if (_this7.wflow.nodes[i].name === '' || _this7.wflow.nodes[i].name === undefined) {
230844
+ _this7.validateNode(_this7.wflow.nodes[i], '请填写任务名称');
230839
230845
  return {
230840
230846
  v: false
230841
230847
  };
230842
230848
  }
230843
- if (_this6.wflow.nodes[i].problem.length === 0 && _this6.wflow.nodes[i].type === 0) {
230844
- _this6.validateNode(_this6.wflow.nodes[i], '请添加问题示例');
230849
+ if (_this7.wflow.nodes[i].problem.length === 0 && _this7.wflow.nodes[i].type === 0) {
230850
+ _this7.validateNode(_this7.wflow.nodes[i], '请添加问题示例');
230845
230851
  return {
230846
230852
  v: false
230847
230853
  };
230848
230854
  }
230849
- if ((_this6.wflow.nodes[i].keywords === '' || _this6.wflow.nodes[i].keywords === undefined) && _this6.wflow.nodes[i].type === 0) {
230850
- _this6.validateNode(_this6.wflow.nodes[i], '请填写匹配关键词');
230855
+ if ((_this7.wflow.nodes[i].keywords === '' || _this7.wflow.nodes[i].keywords === undefined) && _this7.wflow.nodes[i].type === 0) {
230856
+ _this7.validateNode(_this7.wflow.nodes[i], '请填写匹配关键词');
230851
230857
  return {
230852
230858
  v: false
230853
230859
  };
230854
230860
  }
230855
- if (_this6.wflow.nodes[i].speakType === '' || _this6.wflow.nodes[i].speakType === undefined || _this6.wflow.nodes[i].speakType === null) {
230856
- _this6.validateNode(_this6.wflow.nodes[i], '请选择Ai话术切换类型');
230861
+ if (_this7.wflow.nodes[i].speakType === '' || _this7.wflow.nodes[i].speakType === undefined || _this7.wflow.nodes[i].speakType === null) {
230862
+ _this7.validateNode(_this7.wflow.nodes[i], '请选择Ai话术切换类型');
230857
230863
  return {
230858
230864
  v: false
230859
230865
  };
230860
230866
  }
230861
- if (_this6.wflow.nodes[i].SpeakMethod.length === 0 && _this6.wflow.nodes[i].type === 0) {
230862
- _this6.validateNode(_this6.wflow.nodes[i], '请添加AI话术');
230867
+ if (_this7.wflow.nodes[i].SpeakMethod.length === 0 && _this7.wflow.nodes[i].type === 0) {
230868
+ _this7.validateNode(_this7.wflow.nodes[i], '请添加AI话术');
230863
230869
  return {
230864
230870
  v: false
230865
230871
  };
230866
230872
  }
230867
- if (_this6.wflow.nodes[i].successSpeakMethod.length === 0 && _this6.wflow.nodes[i].type === 1) {
230868
- _this6.validateNode(_this6.wflow.nodes[i], '请添加AI成功话术');
230873
+ if (_this7.wflow.nodes[i].successSpeakMethod.length === 0 && _this7.wflow.nodes[i].type === 1) {
230874
+ _this7.validateNode(_this7.wflow.nodes[i], '请添加AI成功话术');
230869
230875
  return {
230870
230876
  v: false
230871
230877
  };
230872
230878
  }
230873
- if (_this6.wflow.nodes[i].errorSpeakMethod.length === 0 && _this6.wflow.nodes[i].type === 1) {
230874
- _this6.validateNode(_this6.wflow.nodes[i], '请添加AI失败话术');
230879
+ if (_this7.wflow.nodes[i].errorSpeakMethod.length === 0 && _this7.wflow.nodes[i].type === 1) {
230880
+ _this7.validateNode(_this7.wflow.nodes[i], '请添加AI失败话术');
230875
230881
  return {
230876
230882
  v: false
230877
230883
  };
230878
230884
  }
230879
- if (_this6.wflow.nodes[i].type === 1 && (_this6.wflow.nodes[i].performId === '' || _this6.wflow.nodes[i].performId === null)) {
230880
- _this6.validateNode(_this6.wflow.nodes[i], '请选择执行动作');
230885
+ if (_this7.wflow.nodes[i].type === 1 && (_this7.wflow.nodes[i].performId === '' || _this7.wflow.nodes[i].performId === null)) {
230886
+ _this7.validateNode(_this7.wflow.nodes[i], '请选择执行动作');
230881
230887
  return {
230882
230888
  v: false
230883
230889
  };
230884
230890
  }
230885
230891
  // 话术类型为时间的 验证时间是否填写
230886
- if (_this6.wflow.nodes[i].speakType === 1) {
230887
- var list = _this6.wflow.speaks.filter(function (item) {
230888
- return _this6.wflow.nodes[i].id === item.nodeId;
230892
+ if (_this7.wflow.nodes[i].speakType === 1) {
230893
+ var list = _this7.wflow.speaks.filter(function (item) {
230894
+ return _this7.wflow.nodes[i].id === item.nodeId;
230889
230895
  })[0];
230890
230896
  if (list.startTime === '' || list.startTime === null || list.startTime === undefined) {
230891
- _this6.validateNode(_this6.wflow.nodes[i], '请选择开始时间');
230897
+ _this7.validateNode(_this7.wflow.nodes[i], '请选择开始时间');
230892
230898
  return {
230893
230899
  v: false
230894
230900
  };
230895
230901
  }
230896
230902
  if (list.endTime === '' || list.endTime === null || list.endTime === undefined) {
230897
- _this6.validateNode(_this6.wflow.nodes[i], '请选择结束时间');
230903
+ _this7.validateNode(_this7.wflow.nodes[i], '请选择结束时间');
230898
230904
  return {
230899
230905
  v: false
230900
230906
  };
@@ -230980,7 +230986,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
230980
230986
  },
230981
230987
  // 保存
230982
230988
  saveWorkflow: function saveWorkflow(actionType) {
230983
- var _this7 = this;
230989
+ var _this8 = this;
230984
230990
  this.$bus.emit('SplicingAttavhStr');
230985
230991
  this.process.chartData = {};
230986
230992
  // console.log(this.connectsArr)
@@ -231034,13 +231040,13 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231034
231040
  }
231035
231041
  var SpeakMethod = [];
231036
231042
  this.wflow.nodes.forEach(function (item) {
231037
- item.sceneId = _this7.wflow.scene.id;
231038
- item.createTime = _this7.wflow.scene.createTime;
231043
+ item.sceneId = _this8.wflow.scene.id;
231044
+ item.createTime = _this8.wflow.scene.createTime;
231039
231045
  SpeakMethod = [].concat(_toConsumableArray(SpeakMethod), _toConsumableArray(item.SpeakMethod), _toConsumableArray(item.successSpeakMethod), _toConsumableArray(item.errorSpeakMethod));
231040
231046
  });
231041
231047
  this.$set(this.wflow, 'speaks', SpeakMethod);
231042
231048
  this.wflow.paths.forEach(function (item) {
231043
- var list = _this7.wflow.nextNodes.filter(function (el) {
231049
+ var list = _this8.wflow.nextNodes.filter(function (el) {
231044
231050
  return el.pathId === item.id;
231045
231051
  })[0];
231046
231052
  item.afterNodeId = list.nextNodeId;
@@ -231062,29 +231068,29 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231062
231068
  }).then(function () {
231063
231069
  // console.log(this)
231064
231070
  // 修改状态
231065
- if (actionType === 'save' && _this7.wflow.scene.status === -1) {
231066
- _this7.wflow.scene.status = 0;
231071
+ if (actionType === 'save' && _this8.wflow.scene.status === -1) {
231072
+ _this8.wflow.scene.status = 0;
231067
231073
  }
231068
231074
  if (actionType === 'online') {
231069
- _this7.wflow.scene.status = 1;
231075
+ _this8.wflow.scene.status = 1;
231070
231076
  }
231071
231077
  if (actionType === 'outline') {
231072
- _this7.wflow.scene.status = 2;
231078
+ _this8.wflow.scene.status = 2;
231073
231079
  }
231074
- _this7.$http(req).then(function (response) {
231080
+ _this8.$http(req).then(function (response) {
231075
231081
  // console.log(response)
231076
231082
  if (response.code === 'success') {
231077
231083
  // 保存成功
231078
- _this7.$message({
231084
+ _this8.$message({
231079
231085
  message: '保存成功',
231080
231086
  type: 'success'
231081
231087
  });
231082
231088
  var btnRefresh = opener.document.querySelector('.el-icon-refresh');
231083
231089
  if (btnRefresh !== null) btnRefresh.click();
231084
231090
  if (actionType !== 'SaveAndClose') {
231085
- if (_this7.$route.query.id) {
231091
+ if (_this8.$route.query.id) {
231086
231092
  // 如果你是打开流程,刷新当前页面
231087
- if (_this7.$route.query.id === response.body.vo.scene.id) {
231093
+ if (_this8.$route.query.id === response.body.vo.scene.id) {
231088
231094
  location.reload();
231089
231095
  } else {
231090
231096
  setTimeout(function () {
@@ -231114,14 +231120,14 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231114
231120
  }
231115
231121
  } else {
231116
231122
  // 保存异常
231117
- _this7.$message({
231123
+ _this8.$message({
231118
231124
  message: response.message,
231119
231125
  type: 'warning'
231120
231126
  });
231121
231127
  }
231122
231128
  }, function (error) {
231123
231129
  console.log(error);
231124
- _this7.$message.error(_this7.$tx('yoabase.messages.saveError', '保存失败'));
231130
+ _this8.$message.error(_this8.$tx('yoabase.messages.saveError', '保存失败'));
231125
231131
  });
231126
231132
  }).catch(function () {
231127
231133
  return;
@@ -231337,7 +231343,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231337
231343
  * 选择部门/科室/班组对话框确认完成
231338
231344
  */
231339
231345
  nodeFieldValueFn: function nodeFieldValueFn(type, nodeId, department, text) {
231340
- var _this8 = this;
231346
+ var _this9 = this;
231341
231347
  // type,类型,nodeId:当前环节ID,department:选择框id,text:选择后部门名字
231342
231348
  // 选择机构
231343
231349
  var fieldValue = {
@@ -231396,7 +231402,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231396
231402
  var nodeFieldValue = JSON.parse(JSON.stringify(fieldValue));
231397
231403
  nodeFieldValue.value = v;
231398
231404
  nodeFieldValue.id = common_uuid();
231399
- _this8.wflow.nodeFieldValues.push(nodeFieldValue);
231405
+ _this9.wflow.nodeFieldValues.push(nodeFieldValue);
231400
231406
  });
231401
231407
  } else {
231402
231408
  for (var _i17 = 0; _i17 < this.wflow.pathFieldValues.length; _i17++) {
@@ -231410,7 +231416,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231410
231416
  var pathFieldValue = JSON.parse(JSON.stringify(fieldValue));
231411
231417
  pathFieldValue.value = v;
231412
231418
  pathFieldValue.id = common_uuid();
231413
- _this8.wflow.pathFieldValues.push(pathFieldValue);
231419
+ _this9.wflow.pathFieldValues.push(pathFieldValue);
231414
231420
  });
231415
231421
  }
231416
231422
  },
@@ -231444,7 +231450,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231444
231450
  * 选择机构人员对话框确认完成
231445
231451
  */
231446
231452
  onSelectStaffCompleted: function onSelectStaffCompleted(selectedNodes, attr) {
231447
- var _this9 = this;
231453
+ var _this10 = this;
231448
231454
  var departmentId = '';
231449
231455
  var selected = '';
231450
231456
  var type = attr.nodefield;
@@ -231453,7 +231459,7 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231453
231459
  selected += ',';
231454
231460
  departmentId += ',';
231455
231461
  }
231456
- if (node.orgCode && (_this9.curNode.selectOrg === 'group_all_corp' || _this9.curNode.selectOrg === 'group_cur_corp')) {
231462
+ if (node.orgCode && (_this10.curNode.selectOrg === 'group_all_corp' || _this10.curNode.selectOrg === 'group_cur_corp')) {
231457
231463
  selected += node.name + '/' + node.orgCode;
231458
231464
  } else {
231459
231465
  selected += node.name;
@@ -231550,19 +231556,19 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231550
231556
  },
231551
231557
  // 选择添加常用按钮
231552
231558
  selAddButton: function selAddButton(selectedBtns) {
231553
- var _this10 = this;
231559
+ var _this11 = this;
231554
231560
  selectedBtns.forEach(function (btn) {
231555
231561
  var newBtn = JSON.parse(JSON.stringify(btn));
231556
- newBtn.nodeId = _this10.curNode.id;
231557
- _this10.curNodeOperationArr.push(newBtn);
231558
- _this10.wflow.operations.push(newBtn);
231562
+ newBtn.nodeId = _this11.curNode.id;
231563
+ _this11.curNodeOperationArr.push(newBtn);
231564
+ _this11.wflow.operations.push(newBtn);
231559
231565
  });
231560
231566
  this.$bus.emit('closeButtonForm');
231561
231567
  this.emitData();
231562
231568
  },
231563
231569
  // 删除操作按钮
231564
231570
  deleteButton: function deleteButton(nodeOperationId, nodeOperationName, nodeOperationType, $event) {
231565
- var _this11 = this;
231571
+ var _this12 = this;
231566
231572
  var confirmMsg = '确认要删除“' + nodeOperationName + '”按钮吗?';
231567
231573
  if (nodeOperationType === 2) {
231568
231574
  confirmMsg = '确认要删除“' + nodeOperationName + '”下拉按钮及全部子按钮吗?';
@@ -231574,14 +231580,14 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231574
231580
  cancelButtonText: '取消',
231575
231581
  type: 'warning'
231576
231582
  }).then(function () {
231577
- for (var i = 0; i < _this11.curNodeOperationArr.length; i++) {
231578
- if (_this11.curNodeOperationArr[i].id === nodeOperationId || _this11.curNodeOperationArr[i].btnGroupId === nodeOperationId) {
231579
- _this11.curNodeOperationArr.splice(i--, 1);
231583
+ for (var i = 0; i < _this12.curNodeOperationArr.length; i++) {
231584
+ if (_this12.curNodeOperationArr[i].id === nodeOperationId || _this12.curNodeOperationArr[i].btnGroupId === nodeOperationId) {
231585
+ _this12.curNodeOperationArr.splice(i--, 1);
231580
231586
  }
231581
231587
  }
231582
- for (var j = 0; j < _this11.wflow.operations.length; j++) {
231583
- if (_this11.wflow.operations[j].id === nodeOperationId || _this11.wflow.operations[j].btnGroupId === nodeOperationId) {
231584
- _this11.wflow.operations.splice(j--, 1);
231588
+ for (var j = 0; j < _this12.wflow.operations.length; j++) {
231589
+ if (_this12.wflow.operations[j].id === nodeOperationId || _this12.wflow.operations[j].btnGroupId === nodeOperationId) {
231590
+ _this12.wflow.operations.splice(j--, 1);
231585
231591
  }
231586
231592
  }
231587
231593
  // console.log(this.curNodeOperationArr)
@@ -231945,9 +231951,9 @@ var Centervue_type_script_lang_js_jsPlumb = window.jsPlumb;
231945
231951
  });
231946
231952
  ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/Center/index.vue?vue&type=script&lang=js
231947
231953
  /* harmony default export */ var voice_Centervue_type_script_lang_js = (Centervue_type_script_lang_js);
231948
- // EXTERNAL MODULE: ./node_modules/vue-style-loader/index.js??clonedRuleSet-64.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-64.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[2]!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[3]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-64.use[4]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecyoa/yoabase/src/voice/Center/index.vue?vue&type=style&index=0&id=30cb1c36&prod&scoped=true&lang=scss
231949
- var Centervue_type_style_index_0_id_30cb1c36_prod_scoped_true_lang_scss = __webpack_require__(3076);
231950
- ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/Center/index.vue?vue&type=style&index=0&id=30cb1c36&prod&scoped=true&lang=scss
231954
+ // EXTERNAL MODULE: ./node_modules/vue-style-loader/index.js??clonedRuleSet-64.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-64.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[2]!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-64.use[3]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-64.use[4]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecyoa/yoabase/src/voice/Center/index.vue?vue&type=style&index=0&id=7f0a3c68&prod&scoped=true&lang=scss
231955
+ var Centervue_type_style_index_0_id_7f0a3c68_prod_scoped_true_lang_scss = __webpack_require__(1685);
231956
+ ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/Center/index.vue?vue&type=style&index=0&id=7f0a3c68&prod&scoped=true&lang=scss
231951
231957
 
231952
231958
  ;// CONCATENATED MODULE: ./packages/ecyoa/yoabase/src/voice/Center/index.vue
231953
231959
 
@@ -231960,11 +231966,11 @@ var Centervue_type_style_index_0_id_30cb1c36_prod_scoped_true_lang_scss = __webp
231960
231966
 
231961
231967
  var Center_component = normalizeComponent(
231962
231968
  voice_Centervue_type_script_lang_js,
231963
- Centervue_type_template_id_30cb1c36_scoped_true_render,
231964
- Centervue_type_template_id_30cb1c36_scoped_true_staticRenderFns,
231969
+ Centervue_type_template_id_7f0a3c68_scoped_true_render,
231970
+ Centervue_type_template_id_7f0a3c68_scoped_true_staticRenderFns,
231965
231971
  false,
231966
231972
  null,
231967
- "30cb1c36",
231973
+ "7f0a3c68",
231968
231974
  null
231969
231975
 
231970
231976
  )