Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
ghsby
o2oa
提交
658154aa
o2oa
项目概览
ghsby
/
o2oa
落后 Fork 源项目 2880 个版本
Fork自
浙江兰德纵横网络技术股份有限公司 / o2oa
通知
1
Star
1
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,发现更多精彩内容 >>
提交
658154aa
编写于
9月 09, 2020
作者:
NoSubject
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改组织字段的默认保存数据结构
上级
428744fc
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
40 addition
and
24 deletion
+40
-24
o2web/source/x_component_process_Xform/Org.js
o2web/source/x_component_process_Xform/Org.js
+21
-13
o2web/source/x_component_process_Xform/Orgfield.js
o2web/source/x_component_process_Xform/Orgfield.js
+5
-5
o2web/source/x_component_process_Xform/Personfield.js
o2web/source/x_component_process_Xform/Personfield.js
+14
-6
未找到文件。
o2web/source/x_component_process_Xform/Org.js
浏览文件 @
658154aa
...
...
@@ -93,12 +93,15 @@ MWF.xApplication.process.Xform.Org = MWF.APPOrg = new Class({
_computeValue
:
function
(){
var
simple
=
this
.
json
.
storeRange
===
"
simple
"
;
var
values
=
[];
if
(
this
.
json
.
identityValue
)
{
this
.
json
.
identityValue
.
each
(
function
(
v
){
if
(
v
)
values
.
push
(
v
)});
this
.
json
.
identityValue
.
each
(
function
(
v
){
if
(
v
)
values
.
push
(
MWF
.
org
.
parseOrgData
(
v
,
true
,
simple
))
});
}
if
(
this
.
json
.
unitValue
)
{
this
.
json
.
unitValue
.
each
(
function
(
v
){
if
(
v
)
values
.
push
(
v
)});
this
.
json
.
unitValue
.
each
(
function
(
v
){
if
(
v
)
values
.
push
(
MWF
.
org
.
parseOrgData
(
v
,
true
,
simple
)
)});
}
if
(
this
.
json
.
dutyValue
)
{
var
dutys
=
JSON
.
decode
(
this
.
json
.
dutyValue
);
...
...
@@ -109,7 +112,7 @@ MWF.xApplication.process.Xform.Org = MWF.APPOrg = new Class({
var
code
=
"
return this.org.getDuty(
\"
"
+
duty
.
name
+
"
\"
,
\"
"
+
par
+
"
\"
)
"
;
var
d
=
this
.
form
.
Macro
.
exec
(
code
,
this
);
if
(
typeOf
(
d
)
!==
"
array
"
)
d
=
(
d
)
?
[
d
.
toString
()]
:
[];
d
.
each
(
function
(
dd
){
if
(
dd
)
values
.
push
(
dd
);});
d
.
each
(
function
(
dd
){
if
(
dd
)
values
.
push
(
MWF
.
org
.
parseOrgData
(
dd
,
true
,
simple
)
);});
}.
bind
(
this
));
}
}
...
...
@@ -120,7 +123,7 @@ MWF.xApplication.process.Xform.Org = MWF.APPOrg = new Class({
if
(
fdd
){
if
(
typeOf
(
fdd
)
===
"
string
"
){
var
data
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
fdd
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
null
,
fdd
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
fdd
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
);
}.
bind
(
this
),
null
,
fdd
,
false
);
values
.
push
(
data
);
}
else
{
values
.
push
(
fdd
);
...
...
@@ -695,15 +698,17 @@ MWF.xApplication.process.Xform.Org = MWF.APPOrg = new Class({
},
addData
:
function
(
value
){
if
(
!
value
)
return
false
;
var
simple
=
this
.
json
.
storeRange
===
"
simple
"
;
value
.
each
(
function
(
v
){
var
vtype
=
typeOf
(
v
);
if
(
vtype
===
"
string
"
){
var
data
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
null
,
v
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
);
}.
bind
(
this
),
null
,
v
,
false
);
if
(
data
)
this
.
combox
.
addNewValue
(
this
.
getDataText
(
data
),
data
);
}
if
(
vtype
===
"
object
"
){
this
.
combox
.
addNewValue
(
this
.
getDataText
(
v
),
v
);
var
d
=
MWF
.
org
.
parseOrgData
(
v
,
true
,
simple
);
this
.
combox
.
addNewValue
(
this
.
getDataText
(
d
),
d
);
}
}.
bind
(
this
));
},
...
...
@@ -854,33 +859,36 @@ MWF.xApplication.process.Xform.Org = MWF.APPOrg = new Class({
var
values
=
[];
var
comboxValues
=
[];
var
type
=
typeOf
(
value
);
var
simple
=
this
.
json
.
storeRange
===
"
simple
"
;
if
(
type
===
"
array
"
){
value
.
each
(
function
(
v
){
var
data
=
null
;
var
vtype
=
typeOf
(
v
);
if
(
vtype
===
"
string
"
){
var
error
=
(
this
.
json
.
isInput
)
?
function
(){
comboxValues
.
push
(
v
);
}
:
null
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
error
,
v
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
);
}.
bind
(
this
),
error
,
v
,
false
);
}
if
(
vtype
===
"
object
"
)
data
=
v
;
if
(
data
){
values
.
push
(
data
);
comboxValues
.
push
({
"
text
"
:
this
.
getDataText
(
data
),
"
value
"
:
data
});
var
d
=
MWF
.
org
.
parseOrgData
(
data
,
true
,
simple
)
values
.
push
(
d
);
comboxValues
.
push
({
"
text
"
:
this
.
getDataText
(
d
),
"
value
"
:
d
});
}
}.
bind
(
this
));
}
if
(
type
===
"
string
"
){
var
vData
;
var
error
=
(
this
.
json
.
isInput
)
?
function
(){
comboxValues
.
push
(
value
);
}
:
null
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
value
)](
function
(
json
){
vData
=
json
.
data
}.
bind
(
this
),
error
,
value
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
value
)](
function
(
json
){
vData
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
);
}.
bind
(
this
),
error
,
value
,
false
);
if
(
vData
){
values
.
push
(
vData
);
comboxValues
.
push
({
"
text
"
:
this
.
getDataText
(
vData
),
"
value
"
:
vData
});
}
}
if
(
type
===
"
object
"
){
values
.
push
(
value
);
comboxValues
.
push
({
"
text
"
:
this
.
getDataText
(
value
),
"
value
"
:
value
});
var
v
=
MWF
.
org
.
parseOrgData
(
value
,
true
,
simple
)
values
.
push
(
v
);
comboxValues
.
push
({
"
text
"
:
this
.
getDataText
(
v
),
"
value
"
:
v
});
}
this
.
_setBusinessData
(
values
);
...
...
@@ -1884,4 +1892,4 @@ MWF.APPOrg.IdentityOptions = new Class({
}
return
rangeValues
;
}
});
\ No newline at end of file
});
o2web/source/x_component_process_Xform/Orgfield.js
浏览文件 @
658154aa
...
...
@@ -311,7 +311,7 @@ MWF.xApplication.process.Xform.Orgfield = MWF.APPOrgfield = new Class({
var
vtype
=
typeOf
(
v
);
if
(
vtype
===
"
string
"
){
var
data
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
null
,
v
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
);
}.
bind
(
this
),
null
,
v
,
false
);
if
(
data
)
this
.
combox
.
addNewValue
(
this
.
getDataText
(
data
),
data
);
}
if
(
vtype
===
"
object
"
){
...
...
@@ -337,7 +337,7 @@ MWF.xApplication.process.Xform.Orgfield = MWF.APPOrgfield = new Class({
if
(
fdd
){
if
(
typeOf
(
fdd
)
===
"
string
"
){
var
data
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
fdd
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
null
,
fdd
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
fdd
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
);
}.
bind
(
this
),
null
,
fdd
,
false
);
values
.
push
(
data
);
}
else
{
values
.
push
(
fdd
);
...
...
@@ -418,7 +418,7 @@ MWF.xApplication.process.Xform.Orgfield = MWF.APPOrgfield = new Class({
var
vtype
=
typeOf
(
v
);
if
(
vtype
===
"
string
"
){
var
error
=
(
this
.
json
.
isInput
)
?
function
(){
comboxValues
.
push
(
v
);
}
:
null
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
error
,
v
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
);
}.
bind
(
this
),
error
,
v
,
false
);
}
if
(
vtype
===
"
object
"
)
data
=
v
;
if
(
data
){
...
...
@@ -430,7 +430,7 @@ MWF.xApplication.process.Xform.Orgfield = MWF.APPOrgfield = new Class({
if
(
type
===
"
string
"
){
var
vData
;
var
error
=
(
this
.
json
.
isInput
)
?
function
(){
comboxValues
.
push
(
value
);
}
:
null
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
value
)](
function
(
json
){
vData
=
json
.
data
}.
bind
(
this
),
error
,
value
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
value
)](
function
(
json
){
vData
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
);
}.
bind
(
this
),
error
,
value
,
false
);
if
(
vData
){
values
.
push
(
vData
);
comboxValues
.
push
({
"
text
"
:
this
.
getDataText
(
vData
),
"
value
"
:
vData
});
...
...
@@ -605,4 +605,4 @@ MWF.xApplication.process.Xform.Orgfield = MWF.APPOrgfield = new Class({
}
}
}
});
\ No newline at end of file
});
o2web/source/x_component_process_Xform/Personfield.js
浏览文件 @
658154aa
...
...
@@ -156,6 +156,8 @@ MWF.xApplication.process.Xform.Personfield = MWF.APPPersonfield = new Class({
if
(
this
.
json
.
unitValue
)
{
this
.
json
.
unitValue
.
each
(
function
(
v
){
if
(
v
)
values
.
push
(
v
)});
}
var
simple
=
this
.
json
.
storeRange
===
"
simple
"
;
if
(
this
.
json
.
dutyValue
)
{
var
dutys
=
JSON
.
decode
(
this
.
json
.
dutyValue
);
var
par
;
...
...
@@ -167,7 +169,9 @@ MWF.xApplication.process.Xform.Personfield = MWF.APPPersonfield = new Class({
//var code = "return this.org.getDepartmentDuty({\"name\": \""+duty.name+"\", \"departmentName\": \""+par+"\"})";
var
d
=
this
.
form
.
Macro
.
exec
(
code
,
this
);
if
(
typeOf
(
d
)
!==
"
array
"
)
d
=
(
d
)
?
[
d
.
toString
()]
:
[];
d
.
each
(
function
(
dd
){
if
(
dd
)
values
.
push
(
dd
);});
d
.
each
(
function
(
dd
){
if
(
dd
)
values
.
push
(
MWF
.
org
.
parseOrgData
(
dd
,
true
,
simple
));
});
// code = "return this.org.getCompanyDuty({\"name\": \""+duty.name+"\", \"compName\": \""+par+"\"})";
// d = this.form.Macro.exec(code, this);
...
...
@@ -183,7 +187,7 @@ MWF.xApplication.process.Xform.Personfield = MWF.APPPersonfield = new Class({
if
(
fdd
){
if
(
typeOf
(
fdd
)
===
"
string
"
){
var
data
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
fdd
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
null
,
fdd
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
fdd
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
);
}.
bind
(
this
),
null
,
fdd
,
false
);
values
.
push
(
data
);
}
else
{
values
.
push
(
fdd
);
...
...
@@ -625,11 +629,12 @@ MWF.xApplication.process.Xform.Personfield = MWF.APPPersonfield = new Class({
},
addData
:
function
(
value
){
if
(
!
value
)
return
false
;
var
simple
=
this
.
json
.
storeRange
===
"
simple
"
;
value
.
each
(
function
(
v
){
var
vtype
=
typeOf
(
v
);
if
(
vtype
===
"
string
"
){
var
data
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
null
,
v
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
);
}.
bind
(
this
),
null
,
v
,
false
);
if
(
data
)
this
.
combox
.
addNewValue
(
this
.
getDataText
(
data
),
data
);
}
if
(
vtype
===
"
object
"
){
...
...
@@ -788,13 +793,16 @@ MWF.xApplication.process.Xform.Personfield = MWF.APPPersonfield = new Class({
var
values
=
[];
var
comboxValues
=
[];
var
type
=
typeOf
(
value
);
var
simple
=
this
.
json
.
storeRange
===
"
simple
"
;
if
(
type
===
"
array
"
){
value
.
each
(
function
(
v
){
var
data
=
null
;
var
vtype
=
typeOf
(
v
);
if
(
vtype
===
"
string
"
){
var
error
=
(
this
.
json
.
isInput
)
?
function
(){
comboxValues
.
push
(
v
);
}
:
null
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
json
.
data
}.
bind
(
this
),
error
,
v
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
v
)](
function
(
json
){
data
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
)
}.
bind
(
this
),
error
,
v
,
false
);
}
if
(
vtype
===
"
object
"
)
data
=
v
;
if
(
data
){
...
...
@@ -806,7 +814,7 @@ MWF.xApplication.process.Xform.Personfield = MWF.APPPersonfield = new Class({
if
(
type
===
"
string
"
){
var
vData
;
var
error
=
(
this
.
json
.
isInput
)
?
function
(){
comboxValues
.
push
(
value
);
}
:
null
;
this
.
getOrgAction
()[
this
.
getValueMethod
(
value
)](
function
(
json
){
vData
=
json
.
data
}.
bind
(
this
),
error
,
value
,
false
);
this
.
getOrgAction
()[
this
.
getValueMethod
(
value
)](
function
(
json
){
vData
=
MWF
.
org
.
parseOrgData
(
json
.
data
,
true
,
simple
)
}.
bind
(
this
),
error
,
value
,
false
);
if
(
vData
){
values
.
push
(
vData
);
comboxValues
.
push
({
"
text
"
:
this
.
getDataText
(
vData
),
"
value
"
:
vData
});
...
...
@@ -912,4 +920,4 @@ MWF.xApplication.process.Xform.Personfield = MWF.APPPersonfield = new Class({
}
}
});
\ No newline at end of file
});
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录