Socket
Socket
Sign inDemoInstall

bpmn-modeler-antdv

Package Overview
Dependencies
Maintainers
1
Versions
114
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bpmn-modeler-antdv - npm Package Compare versions

Comparing version 1.0.4 to 1.0.5

package/common/mixinOperation.js

4

package.json
{
"name": "bpmn-modeler-antdv",
"version": "1.0.4",
"version": "1.0.5",
"description": "基于 `vue` 和 `bpmn.io@7.0` ,实现 flowable 的 modeler 模型设计器 Antdv版",
"main": "dist/workflow-bpmn-modeler-antdv.umd.min.js",
"main": "dist/bpmn-modeler-antdv.umd.min.js",
"scripts": {

@@ -7,0 +7,0 @@ "dev": "vue-cli-service serve --open",

@@ -1,2 +0,2 @@

import showConfig from '../flowable/showConfig'
import showConfig from "../flowable/showConfig";

@@ -7,7 +7,7 @@ export default {

type: Array,
default: () => []
default: () => [],
},
associateFormConfig:{
type:Object,
default:() => {
associateFormConfig: {
type: Object,
default: () => {
return {

@@ -17,120 +17,123 @@ enable: false, //此项为false,后设置两项均无效

isCreate: true,
}
}
};
},
},
associateFormDataOptions: {
type: Array,
default:() => []
default: () => [],
},
modeler: {
type: Object,
required: true
required: true,
},
element: {
type: Object,
required: true
required: true,
},
categories: {
type: Array,
default: () => []
default: () => [],
},
skipExpressionDataSource: {
type: Array,
default: () => []
default: () => [],
},
conditionExpressionDataSource: {
type: Array,
default: () => []
}
default: () => [],
},
},
watch: {
'formData.id': function(val) {
this.updateProperties({ id: val })
"formData.id": function(val) {
this.updateProperties({ id: val });
},
'formData.name': function(val) {
this.updateProperties({ name: val })
"formData.name": function(val) {
this.updateProperties({ name: val });
},
'formData.documentation': function(val) {
"formData.documentation": function(val) {
if (!val) {
this.updateProperties({ documentation: [] })
return
this.updateProperties({ documentation: [] });
return;
}
const documentationElement = this.modeler.get('moddle').create('bpmn:Documentation', { text: val })
this.updateProperties({ documentation: [documentationElement] })
}
const documentationElement = this.modeler
.get("moddle")
.create("bpmn:Documentation", { text: val });
this.updateProperties({ documentation: [documentationElement] });
},
},
methods: {
updateProperties(properties) {
const modeling = this.modeler.get('modeling')
modeling.updateProperties(this.element, properties)
const modeling = this.modeler.get("modeling");
modeling.updateProperties(this.element, properties);
},
getSignalElements(){
getSignalElements() {
var signals = [];
this.rootElements = this.modeler.getDefinitions().rootElements;
if (this.rootElements.length > 0){
this.rootElements.forEach(item=>{
if (item.$type==='bpmn:Signal'){
if (this.rootElements.length > 0) {
this.rootElements.forEach((item) => {
if (item.$type === "bpmn:Signal") {
signals.push(item);
}
})
});
}
return signals;
},
getSignalElementIds(){
getSignalElementIds() {
var signals = [];
this.rootElements = this.modeler.getDefinitions().rootElements;
if (this.rootElements.length > 0){
this.rootElements.forEach(item=>{
if (item.$type==='bpmn:Signal'){
if (this.rootElements.length > 0) {
this.rootElements.forEach((item) => {
if (item.$type === "bpmn:Signal") {
signals.push(item.id);
}
})
});
}
return signals;
},
getMessageElements(){
getMessageElements() {
var signals = [];
this.rootElements = this.modeler.getDefinitions().rootElements;
if (this.rootElements.length > 0){
this.rootElements.forEach(item=>{
if (item.$type==='bpmn:Message'){
if (this.rootElements.length > 0) {
this.rootElements.forEach((item) => {
if (item.$type === "bpmn:Message") {
signals.push(item);
}
})
});
}
return signals;
},
getMessageElementIds(){
getMessageElementIds() {
var signals = [];
this.rootElements = this.modeler.getDefinitions().rootElements;
if (this.rootElements.length > 0){
this.rootElements.forEach(item=>{
if (item.$type==='bpmn:Message'){
if (this.rootElements.length > 0) {
this.rootElements.forEach((item) => {
if (item.$type === "bpmn:Message") {
signals.push(item.id);
}
})
});
}
return signals;
},
filter(name){
return this.filters.indexOf(name) !== -1
filter(name) {
return this.filters.indexOf(name) !== -1;
},
showAssociateForm(formKey){
this.$emit("showForm",formKey)
showAssociateForm(formKey) {
this.$emit("showForm", formKey);
},
createAssociateForm(){
this.$emit("createForm")
}
createAssociateForm() {
this.$emit("createForm");
},
},
computed: {
elementType() {
const bizObj = this.element.businessObject
const bizObj = this.element.businessObject;
console.log(bizObj, "bizObj");
return bizObj.eventDefinitions
? bizObj.eventDefinitions[0].$type
: bizObj.$type
: bizObj.$type;
},
showConfig() {
return showConfig[this.elementType] || {}
}
}
}
return showConfig[this.elementType] || {};
},
},
};

@@ -0,12 +1,20 @@

/*
* @Author: phie 1532124521@qq.com
* @Date: 2022-09-01 12:29:33
* @LastEditors: phie 1532124521@qq.com
* @LastEditTime: 2022-09-08 15:07:43
* @FilePath: \workflow-bpmn-modeler-antdv\package\flowable\showConfig.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
export default {
'bpmn:EndEvent': {},
'bpmn:StartEvent': {
"bpmn:EndEvent": {},
"bpmn:StartEvent": {
initiator: true,
formKey: true
formKey: true,
},
'bpmn:SequenceFlow': {
"bpmn:SequenceFlow": {
skipExpression: true,
conditionExpression: true
conditionExpression: true,
},
'bpmn:UserTask': {
"bpmn:UserTask": {
userType: true,

@@ -22,6 +30,8 @@ dataType: true,

dueDate: true,
followUpDate:true,
taskListener: true
followUpDate: true,
taskListener: true,
formUrl: true, // 路由表单
formType: true, //表单类型
},
'bpmn:ServiceTask': {
"bpmn:ServiceTask": {
async: true,

@@ -31,5 +41,5 @@ skipExpression: true,

triggerable: true,
class: true
class: true,
},
'bpmn:ScriptTask': {
"bpmn:ScriptTask": {
async: true,

@@ -45,17 +55,17 @@ isForCompensation: true,

resultVariable: true,
autoStoreVariables: true
autoStoreVariables: true,
},
'bpmn:ManualTask': {
"bpmn:ManualTask": {
async: true,
isForCompensation: true
isForCompensation: true,
},
'bpmn:ReceiveTask': {
"bpmn:ReceiveTask": {
async: true,
isForCompensation: true
isForCompensation: true,
},
'bpmn:SendTask': {
"bpmn:SendTask": {
async: true,
isForCompensation: true
isForCompensation: true,
},
'bpmn:BusinessRuleTask': {
"bpmn:BusinessRuleTask": {
async: true,

@@ -66,4 +76,4 @@ isForCompensation: true,

resultVariable: true,
exclude: true
}
}
exclude: true,
},
};

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc