Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
此号慢热型
o2oa
提交
e9462a36
o2oa
项目概览
此号慢热型
/
o2oa
与 Fork 源项目一致
Fork自
浙江兰德纵横网络技术股份有限公司 / o2oa
通知
5
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
o2oa
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
e9462a36
编写于
7月 11, 2020
作者:
U
unknown
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
表单样式自定义
上级
621dc06d
变更
3
显示空白变更内容
内联
并排
Showing
3 changed file
with
41 addition
and
16 deletion
+41
-16
o2web/source/x_component_process_FormDesigner/Module/Form.js
o2web/source/x_component_process_FormDesigner/Module/Form.js
+20
-11
o2web/source/x_component_process_FormDesigner/Module/Form/form.html
...ce/x_component_process_FormDesigner/Module/Form/form.html
+6
-5
o2web/source/x_component_process_FormDesigner/Property.js
o2web/source/x_component_process_FormDesigner/Property.js
+15
-0
未找到文件。
o2web/source/x_component_process_FormDesigner/Module/Form.js
浏览文件 @
e9462a36
...
...
@@ -106,14 +106,15 @@ MWF.xApplication.process.FormDesigner.Module.Form = MWF.FCForm = new Class({
this
.
container
.
set
(
"
html
"
,
this
.
html
);
this
.
loadStylesList
(
function
(){
if
(
this
.
json
.
formStyleTypeType
===
"
custom
"
){
//如果是自定义表单样式
this
.
currentFormStyleType
=
this
.
json
.
formStyleCustom
;
this
.
loadCustomTemplateStyles
(
this
.
json
.
formStyleCustom
,
function
(
templateStyles
)
{
if
(
typeOf
(
this
.
json
.
currentFormStyle
)
===
"
object
"
){
//如果是自定义表单样式
this
.
loadCustomTemplateStyles
(
this
.
json
.
currentFormStyle
,
function
(
templateStyles
)
{
this
.
_load
(
templateStyles
);
}.
bind
(
this
))
}
else
{
var
oldStyleValue
=
""
;
if
((
!
this
.
json
.
formStyleType
)
||
!
this
.
stylesList
[
this
.
json
.
formStyleType
])
this
.
json
.
formStyleType
=
"
blue-simple
"
;
if
((
!
this
.
json
.
formStyleType
)
||
!
this
.
stylesList
[
this
.
json
.
formStyleType
]){
this
.
json
.
formStyleType
=
"
blue-simple
"
;
}
if
(
this
.
options
.
mode
==
"
Mobile
"
)
{
if
(
this
.
json
.
formStyleType
!=
"
defaultMobile
"
)
{
var
styles
=
this
.
stylesList
[
this
.
json
.
formStyleType
];
...
...
@@ -123,7 +124,7 @@ MWF.xApplication.process.FormDesigner.Module.Form = MWF.FCForm = new Class({
}
}
}
this
.
currentFormStyleTyp
e
=
this
.
json
.
formStyleType
;
if
(
!
this
.
json
.
currentFormStyle
)
this
.
json
.
currentFormStyl
e
=
this
.
json
.
formStyleType
;
this
.
loadTemplateStyles
(
this
.
stylesList
[
this
.
json
.
formStyleType
].
file
,
this
.
stylesList
[
this
.
json
.
formStyleType
].
extendFile
,
function
(
templateStyles
)
{
//this.templateStyles = (this.stylesList && this.json.formStyleType) ? this.stylesList[this.json.formStyleType] : null;
...
...
@@ -1160,22 +1161,21 @@ MWF.xApplication.process.FormDesigner.Module.Form = MWF.FCForm = new Class({
if
(
name
==
"
formStyleType
"
||
name
==
"
formStyleCustom
"
){
var
loadOldTemplateStyle
=
function
()
{
if
(
typeOf
(
this
.
currentFormStyleType
)
===
"
object
"
){
//如果是自定义表单样式
this
.
loadCustomTemplateStyles
(
this
.
json
.
formStyleCustom
,
function
(
oldTemplateStyles
)
{
this
.
json
.
styleConfig
=
this
.
json
.
formStyleCustom
;
if
(
typeOf
(
this
.
json
.
currentFormStyle
)
===
"
object
"
){
//如果原来是自定义表单样式
this
.
loadCustomTemplateStyles
(
this
.
json
.
currentFormStyle
,
function
(
oldTemplateStyles
)
{
this
.
switchTemplateStyles
(
oldTemplateStyles
);
this
.
currentFormStyleType
=
this
.
json
.
formStyleCustom
;
this
.
setCurrentFormStyle
(
name
)
;
}.
bind
(
this
))
}
else
{
if
(
!
oldValue
)
oldValue
=
this
.
json
.
currentFormStyle
;
var
oldFile
,
oldExtendFile
;
if
(
oldValue
&&
this
.
stylesList
[
oldValue
]
){
oldFile
=
this
.
stylesList
[
oldValue
].
file
;
oldExtendFile
=
this
.
stylesList
[
oldValue
].
extendFile
;
}
this
.
loadTemplateStyles
(
oldFile
,
oldExtendFile
,
function
(
oldTemplateStyles
){
this
.
json
.
styleConfig
=
(
this
.
stylesList
&&
this
.
json
.
formStyleType
)
?
this
.
stylesList
[
this
.
json
.
formStyleType
]
:
null
;
this
.
switchTemplateStyles
(
oldTemplateStyles
);
this
.
currentFormStyleType
=
this
.
json
.
formStyleCustom
;
this
.
setCurrentFormStyle
(
name
)
;
}.
bind
(
this
))
}
}.
bind
(
this
);
...
...
@@ -1213,6 +1213,15 @@ MWF.xApplication.process.FormDesigner.Module.Form = MWF.FCForm = new Class({
module
.
setAllStyles
();
}.
bind
(
this
));
},
setCurrentFormStyle
:
function
(
name
)
{
if
(
name
==
"
formStyleCustom
"
){
this
.
json
.
styleConfig
=
this
.
json
.
formStyleCustom
;
this
.
json
.
currentFormStyle
=
this
.
json
.
formStyleCustom
;
}
else
{
this
.
json
.
styleConfig
=
(
this
.
stylesList
&&
this
.
json
.
formStyleType
)
?
this
.
stylesList
[
this
.
json
.
formStyleType
]
:
null
;
this
.
json
.
currentFormStyle
=
this
.
json
.
formStyleType
;
}
},
parseCSS
:
function
(
css
){
var
rex
=
/
(
url
\(
.*
\))
/g
;
...
...
o2web/source/x_component_process_FormDesigner/Module/Form/form.html
浏览文件 @
e9462a36
...
...
@@ -29,21 +29,22 @@
<input
type=
"radio"
onclick=
"if (this.checked) {
$('text{$.pid}formStyleTypeTr').setStyle('display', '');
$('text{$.pid}formStyleTypeCustomTr').setStyle('display', 'none');
}"
name=
"formStyleType
Type"
value=
"default"
text
{($.
formStyleTypeType
!='
custom
'
)?'
checked
'
:
''}
/>
系统
}"
name=
"formStyleType
Radio"
value=
"default"
text
{(
typeOf
($.
currentFormStyle
)!='
object
'
)?'
checked
'
:
''}
/>
系统
<input
type=
"radio"
onclick=
"if (this.checked) {
$('text{$.pid}formStyleTypeTr').setStyle('display', 'none');
$('text{$.pid}formStyleTypeCustomTr').setStyle('display', '');
}"
name=
"formStyleType
Type"
value=
"custom"
text
{($
.formStyleTypeType=
='custom
')?'checked':''}/
>
自定义
}"
name=
"formStyleType
Radio"
value=
"custom"
text
{(
typeOf
($
.currentFormStyle)=
='object
')?'checked':''}/
>
自定义
</td>
</tr>
<tr
id=
"text{$.pid}formStyleTypeTr"
style=
"display: text{(
$.formStyleTypeType!='custom
')?'':'none'}"
>
<tr
id=
"text{$.pid}formStyleTypeTr"
style=
"display: text{(
typeOf($.currentFormStyle)!='object
')?'':'none'}"
>
<td
class=
"editTableValue"
>
<select
class=
"MWFFormStyle"
name=
"formStyleType"
></select>
</td>
</tr>
<tr
id=
"text{$.pid}formStyleTypeCustomTr"
style=
"display: text{(
$.formStyleTypeType=='custom
')?'':'none'}"
>
<tr
id=
"text{$.pid}formStyleTypeCustomTr"
style=
"display: text{(
typeOf($.currentFormStyle)=='object
')?'':'none'}"
>
<td
class=
"editTableValue"
>
<div
class=
"MWFScriptSelect"
name=
"formStyleCustom"
></div>
<div
class=
"MWFScriptSelectRefresh"
></div>
</td>
</tr>
<tr>
...
...
o2web/source/x_component_process_FormDesigner/Property.js
浏览文件 @
e9462a36
...
...
@@ -1135,6 +1135,7 @@ debugger;
}.
bind
(
this
));
},
loadStylesList
:
function
(){
var
_self
=
this
;
var
styleSelNodes
=
this
.
propertyContent
.
getElements
(
"
.MWFFormStyle
"
);
styleSelNodes
.
each
(
function
(
node
){
if
(
this
.
module
.
form
.
stylesList
){
...
...
@@ -1152,6 +1153,11 @@ debugger;
}
else
{
node
.
getParent
(
"
tr
"
).
setStyle
(
"
display
"
,
"
none
"
);
}
var
refreshNode
=
new
Element
(
"
div
"
,
{
"
styles
"
:
this
.
form
.
css
.
propertyRefreshFormNode
}).
inject
(
node
,
"
after
"
);
refreshNode
.
addEvent
(
"
click
"
,
function
(
e
){
_self
.
changeData
(
this
.
get
(
"
name
"
),
this
);
}.
bind
(
node
));
}.
bind
(
this
));
},
loadDivTemplateType
:
function
(){
...
...
@@ -1279,6 +1285,7 @@ debugger;
});
}.
bind
(
this
));
var
_self
=
this
;
scriptNodes
.
each
(
function
(
node
){
new
MWF
.
xApplication
.
process
.
ProcessDesigner
.
widget
.
PersonSelector
(
node
,
this
.
form
.
designer
,
{
"
type
"
:
"
Script
"
,
...
...
@@ -1286,6 +1293,14 @@ debugger;
"
names
"
:
[
this
.
data
[
node
.
get
(
"
name
"
)]],
"
onChange
"
:
function
(
ids
){
this
.
saveScriptSelectItem
(
node
,
ids
);}.
bind
(
this
)
});
var
next
=
node
.
getNext
();
if
(
next
&&
next
.
get
(
"
class
"
)
===
"
MWFScriptSelectRefresh
"
){
var
refreshNode
=
new
Element
(
"
div
"
,
{
"
styles
"
:
this
.
form
.
css
.
propertyRefreshFormNode
}).
inject
(
next
);
refreshNode
.
addEvent
(
"
click
"
,
function
(
e
){
_self
.
changeData
(
this
.
get
(
"
name
"
),
this
);
}.
bind
(
node
));
}
}.
bind
(
this
));
fileNodes
.
each
(
function
(
node
){
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录