|
126 | 126 | return this.$root.$children[0].process; |
127 | 127 | }, |
128 | 128 | assignmentLockGetter () { |
129 | | - if (this.node.$type === 'bpmn:CallActivity') { |
130 | | - return _.get(this.node.config && this.safeJsonParse(this.node.config), "assignmentLock") || false; |
131 | | - } else { |
132 | | - return _.get(this.node, "assignmentLock") || false; |
133 | | - } |
| 129 | + return _.get(this.node, "assignmentLock") || false; |
134 | 130 | }, |
135 | 131 | allowReassignmentGetter () { |
136 | | - if (this.node.$type === 'bpmn:CallActivity') { |
137 | | - return _.get(this.node.config && this.safeJsonParse(this.node.config), "allowReassignment") || false; |
138 | | - } else { |
139 | | - return _.get(this.node, "allowReassignment") || false; |
140 | | - } |
| 132 | + return _.get(this.node, "allowReassignment") || false; |
141 | 133 | }, |
142 | 134 | assignedUserGetter () { |
143 | 135 | let value = _.get(this.node, "assignedUsers"); |
|
280 | 272 | case 'ALLOW_REASSIGNMENT': |
281 | 273 | return this.allowReassignmentGetter; |
282 | 274 | default: |
283 | | - const config = this.node.config && this.safeJsonParse(this.node.config) || {}; |
| 275 | + const config = this.node.config && JSON.parse(this.node.config) || {}; |
284 | 276 | return config[window._.camelCase(configurable)] || false; |
285 | 277 | } |
286 | 278 | }, |
|
291 | 283 | case 'ALLOW_REASSIGNMENT': |
292 | 284 | return this.allowReassignmentSetter(value); |
293 | 285 | default: |
294 | | - const config = this.node.config && this.safeJsonParse(this.node.config) || {}; |
| 286 | + const config = this.node.config && JSON.parse(this.node.config) || {}; |
295 | 287 | config[window._.camelCase(configurable)] = value; |
296 | 288 | this.$set(this.node, "config", JSON.stringify(config)); |
297 | 289 | } |
|
319 | 311 | * Update assignmentLock property |
320 | 312 | */ |
321 | 313 | assignmentLockSetter (value) { |
322 | | - if (this.node.$type === 'bpmn:CallActivity') { |
323 | | - const config = this.node.config && this.safeJsonParse(this.node.config) || {}; |
324 | | - config.assignmentLock = value; |
325 | | - this.$set(this.node, "config", JSON.stringify(config)); |
326 | | - } else { |
327 | | - this.$set(this.node, "assignmentLock", value); |
328 | | - } |
| 314 | + this.$set(this.node, "assignmentLock", value); |
329 | 315 | }, |
330 | 316 | /** |
331 | 317 | * Update allowReassignment property |
332 | 318 | */ |
333 | 319 | allowReassignmentSetter (value) { |
334 | | - if (this.node.$type === 'bpmn:CallActivity') { |
335 | | - const config = this.node.config && this.safeJsonParse(this.node.config) || {}; |
336 | | - config.allowReassignment = value; |
337 | | - this.$set(this.node, "config", JSON.stringify(config)); |
338 | | - } else { |
339 | | - this.$set(this.node, "allowReassignment", value); |
340 | | - } |
| 320 | + this.$set(this.node, "allowReassignment", value); |
341 | 321 | }, |
342 | 322 | /** |
343 | 323 | * Update the event of the editer property |
|
0 commit comments