mirror of
https://gitee.com/java110/MicroCommunityWeb.git
synced 2026-06-12 10:00:56 +08:00
优化代码
This commit is contained in:
parent
6a71dbd1f0
commit
d0329097d8
@ -4,6 +4,8 @@
|
|||||||
<!--
|
<!--
|
||||||
required editor styles
|
required editor styles
|
||||||
-->
|
-->
|
||||||
|
<link rel="stylesheet" href="/css/bootstrap/bootstrap.min.css" />
|
||||||
|
<link rel="stylesheet" href="/css/vc-ui.css" />
|
||||||
<link rel="stylesheet" href="css/form-js.css">
|
<link rel="stylesheet" href="css/form-js.css">
|
||||||
<link rel="stylesheet" href="css/form-js-editor.css">
|
<link rel="stylesheet" href="css/form-js-editor.css">
|
||||||
<link rel="stylesheet" href="css/dragula.css">
|
<link rel="stylesheet" href="css/dragula.css">
|
||||||
@ -20,11 +22,35 @@
|
|||||||
#form {
|
#form {
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.r {
|
||||||
|
position: fixed;
|
||||||
|
margin: auto;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 20px;
|
||||||
|
width: 300px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
body{
|
||||||
|
background: #fff;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div id="form"></div>
|
<div id="form"></div>
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<div class="r btn-group">
|
||||||
|
<button type="button" class="btn btn-white ">返回</button>
|
||||||
|
<button type="button" class="btn btn-primary" style="margin-left:10px">
|
||||||
|
保存
|
||||||
|
</button>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<script src="js/form-editor.umd.js"></script>
|
<script src="js/form-editor.umd.js"></script>
|
||||||
<script src="/vcCore/vcFramework.js"></script>
|
<script src="/vcCore/vcFramework.js"></script>
|
||||||
<script src="editor.js"></script>
|
<script src="editor.js"></script>
|
||||||
|
|||||||
@ -58,34 +58,29 @@
|
|||||||
|
|
||||||
_initFormJs = function () {
|
_initFormJs = function () {
|
||||||
let _flowId = vc.getParam('flowId');
|
let _flowId = vc.getParam('flowId');
|
||||||
// let _param = {
|
let _param = {
|
||||||
// params: {
|
params: {
|
||||||
// flowId: _flowId,
|
flowId: _flowId,
|
||||||
// page: 1,
|
page: 1,
|
||||||
// row: 1
|
row: 1
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// vc.http.apiGet('/oaWorkflow/queryOaWorkflowXml',
|
vc.http.apiGet('/oaWorkflow/queryOaWorkflowForm',
|
||||||
// _param,
|
_param,
|
||||||
// function (json, res) {
|
function (json, res) {
|
||||||
// let _flowXml = JSON.parse(json);
|
let _flowXml = JSON.parse(json);
|
||||||
// if (_flowXml.data.length > 0) {
|
if (_flowXml.data.length > 0) {
|
||||||
// //初始化
|
//初始化
|
||||||
// initFormJs(_flowXml.data[0].bpmnXml);
|
initFormJs(_flowXml.data[0].bpmnXml);
|
||||||
// return;
|
return;
|
||||||
// }
|
}
|
||||||
// //初始化
|
//初始化
|
||||||
// window.initFormJs();
|
window.initFormJs(default_json);
|
||||||
// }, function (errInfo, error) {
|
}, function (errInfo, error) {
|
||||||
// console.log('请求失败处理');
|
console.log('请求失败处理');
|
||||||
// }
|
}
|
||||||
// );
|
);
|
||||||
|
|
||||||
window.initFormJs(default_json);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
_initFormJs();
|
_initFormJs();
|
||||||
|
|
||||||
_closeBpmnjs = function () {
|
_closeBpmnjs = function () {
|
||||||
|
|||||||
@ -1,3 +1,12 @@
|
|||||||
|
/**
|
||||||
|
* HC小区管理系统作者 吴学文(mail:928255095@qq.com) 对原有的https://bpmn.io 的 formjs 框架做了 相应修改 主要修改如下:
|
||||||
|
* 加入 多行文本框,时间组件,日期组件,部分汉化功能
|
||||||
|
*
|
||||||
|
* HC小区管理系统官方尊重作者的贡献未去除bpmn 版权信息,如果您想去除请先联系 bpmn作者,经作者同意后,可以在1758行去除bpmn版权,
|
||||||
|
* 在未经作者允许的情况下去除bpmn版权造成的侵权问题,HC小区管理系统将不会承担任何责任,由去除版权的公司或者个人承担相应的责任!
|
||||||
|
*
|
||||||
|
* 版权归 https://bpmn.io/ 所有,非常感谢bpmn.io 提供这么优秀的框架
|
||||||
|
*/
|
||||||
(function (global, factory) {
|
(function (global, factory) {
|
||||||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
|
||||||
typeof define === 'function' && define.amd ? define(['exports'], factory) :
|
typeof define === 'function' && define.amd ? define(['exports'], factory) :
|
||||||
@ -1746,6 +1755,16 @@
|
|||||||
onChange: onChange
|
onChange: onChange
|
||||||
}), o$1(PoweredBy, {})]
|
}), o$1(PoweredBy, {})]
|
||||||
});
|
});
|
||||||
|
//去除 bpmn 版权,开源不容易 官方不去除 bpmn 版权信息,如果 老铁们想去除 注释上面 开放下面即可
|
||||||
|
// return o$1("form", {
|
||||||
|
// class: "fjs-form",
|
||||||
|
// onSubmit: handleSubmit,
|
||||||
|
// onReset: handleReset,
|
||||||
|
// children: [o$1(FormField, {
|
||||||
|
// field: schema,
|
||||||
|
// onChange: onChange
|
||||||
|
// })]
|
||||||
|
// });
|
||||||
}
|
}
|
||||||
|
|
||||||
const type$2 = 'number';
|
const type$2 = 'number';
|
||||||
@ -5753,7 +5772,7 @@
|
|||||||
if (!field || field.type === 'default') {
|
if (!field || field.type === 'default') {
|
||||||
return o$1("div", {
|
return o$1("div", {
|
||||||
class: "fjs-properties-panel-placeholder",
|
class: "fjs-properties-panel-placeholder",
|
||||||
children: "Select a form field to edit its properties."
|
children: "请拖拽选择组件,自定义表单"
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user