Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
ghsby
o2oa
提交
5ff74ba6
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,发现更多精彩内容 >>
提交
5ff74ba6
编写于
6月 25, 2020
作者:
NoSubject
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
版式文件word拷贝缩进优化,以及半角空格转全角空格
上级
a592de7e
变更
3
显示空白变更内容
内联
并排
Showing
3 changed file
with
90 addition
and
16 deletion
+90
-16
o2web/source/x_component_process_FormDesigner/Module/Documenteditor/documenteditor.html
...ss_FormDesigner/Module/Documenteditor/documenteditor.html
+11
-0
o2web/source/x_component_process_Xform/Documenteditor.js
o2web/source/x_component_process_Xform/Documenteditor.js
+77
-15
o2web/source/x_component_process_Xform/lp/zh-cn.js
o2web/source/x_component_process_Xform/lp/zh-cn.js
+2
-1
未找到文件。
o2web/source/x_component_process_FormDesigner/Module/Documenteditor/documenteditor.html
浏览文件 @
5ff74ba6
...
...
@@ -82,6 +82,17 @@
</table>
<div
id=
"text{$.pid}allowHistoryScriptArea"
style=
"display: text{($.allowHistory=='s')?'block':'none'}"
class=
"MWFFormulaArea"
name=
"allowHistoryScript"
title=
"允许查看痕迹脚本 (S)"
></div>
<table
width=
"100%"
border=
"0"
cellpadding=
"5"
cellspacing=
"0"
class=
"editTable"
>
<tr>
<td
class=
"editTableTitle"
>
全角转换:
</td>
<td
class=
"editTableValue"
>
<input
class=
"editTableRadio"
name=
"fullWidth"
text
{($
.fullWidth=
='y')?'checked':''}
type=
"radio"
value=
"y"
/>
是
<input
class=
"editTableRadio"
name=
"fullWidth"
text
{($.
fullWidth
!='
y
')?'
checked
'
:
''}
type=
"radio"
value=
"n"
/>
否
<div>
选择“是”自动将输入的半角空格转换为全角
</div>
</td>
</tr>
</table>
<table
width=
"100%"
border=
"0"
cellpadding=
"5"
cellspacing=
"0"
class=
"editTable"
>
<tr>
<td
class=
"editTableTitle"
>
WORD转换:
</td>
...
...
o2web/source/x_component_process_Xform/Documenteditor.js
浏览文件 @
5ff74ba6
...
...
@@ -935,7 +935,8 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor = new Cla
if
(
this
.
allowEdit
)
{
var
button
=
this
.
toolbar
.
childrenButton
[
0
];
button
.
setText
(
MWF
.
xApplication
.
process
.
Xform
.
LP
.
editdoc
);
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc.png
"
)
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc.png
"
);
//this.getFullWidthFlagNode().dispose();
}
this
.
editMode
=
false
;
}
else
{
...
...
@@ -943,7 +944,9 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor = new Cla
if
(
this
.
allowEdit
)
{
var
button
=
this
.
toolbar
.
childrenButton
[
0
];
button
.
setText
(
MWF
.
xApplication
.
process
.
Xform
.
LP
.
editdocCompleted
);
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc_completed.png
"
)
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc_completed.png
"
);
//this.toolbar.node.inject(this.getFullWidthFlagNode());
}
this
.
editMode
=
true
;
}
...
...
@@ -955,11 +958,14 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor = new Cla
if
(
!
layout
.
mobile
)
{
var
button
=
this
.
sideToolbar
.
childrenButton
[
0
];
button
.
setText
(
MWF
.
xApplication
.
process
.
Xform
.
LP
.
editdoc
);
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc.png
"
)
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc.png
"
);
//this.getFullWidthFlagNode().dispose();
}
button
=
this
.
toolbar
.
childrenButton
[
0
];
button
.
setText
(
MWF
.
xApplication
.
process
.
Xform
.
LP
.
editdoc
);
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc.png
"
)
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc.png
"
);
//this.getFullWidthFlagNode().dispose();
// if (!layout.mobile)this.sideToolbar.childrenButton[0].setText(MWF.xApplication.process.Xform.LP.editdoc);
// this.toolbar.childrenButton[0].setText(MWF.xApplication.process.Xform.LP.editdoc);
...
...
@@ -971,17 +977,32 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor = new Cla
if
(
!
layout
.
mobile
)
{
var
button
=
this
.
sideToolbar
.
childrenButton
[
0
];
button
.
setText
(
MWF
.
xApplication
.
process
.
Xform
.
LP
.
editdocCompleted
);
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc_completed.png
"
)
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc_completed.png
"
);
//this.toolbar.node.inject(this.getFullWidthFlagNode());
}
button
=
this
.
toolbar
.
childrenButton
[
0
];
button
.
setText
(
MWF
.
xApplication
.
process
.
Xform
.
LP
.
editdocCompleted
);
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc_completed.png
"
)
button
.
picNode
.
getElement
(
"
img
"
).
set
(
"
src
"
,
"
../x_component_process_Xform/$Form/default/icon/editdoc_completed.png
"
);
//this.toolbar.node.inject(this.getFullWidthFlagNode());
// if (!layout.mobile) this.sideToolbar.childrenButton[0].setText(MWF.xApplication.process.Xform.LP.editdocCompleted);
// this.toolbar.childrenButton[0].setText(MWF.xApplication.process.Xform.LP.editdocCompleted);
}
this
.
editMode
=
true
;
}
},
// getFullWidthFlagNode: function(){
// if (!this.fullWidthFlagNode){
// this.fullWidthFlagNode = new Element("span", {
// "styles": {
// "line-height": "26px",
// "color": "#999999",
// "font-size": "12px"
// },
// "text": MWF.xApplication.process.Xform.LP.fullWidth
// });
// }
// return this.fullWidthFlagNode;
// },
_printDoc
:
function
(){
this
.
toWord
(
function
(
data
){
if
(
this
.
form
.
businessData
.
work
&&
!
this
.
form
.
businessData
.
work
.
completedTime
){
...
...
@@ -1228,6 +1249,10 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor = new Cla
if
(
this
.
allowHistory
){
html
+=
"
<span MWFnodetype=
\"
MWFToolBarButton
\"
MWFButtonImage=
\"
../x_component_process_Xform/$Form/default/icon/versions.png
\"
title=
\"
"
+
MWF
.
xApplication
.
process
.
Xform
.
LP
.
history
+
"
\"
MWFButtonAction=
\"
_historyDoc
\"
MWFButtonText=
\"
"
+
MWF
.
xApplication
.
process
.
Xform
.
LP
.
history
+
"
\"
></span>
"
;
}
// if (this.json.fullWidth=="y"){
// html += "<span style='line-height: 26px; color: #999999; font-size: 12px'>已启用半角空格自动转换为全角空格,如需输入半角空格,请使用:SHIFT+空格</span>"
// }
this
.
toolbarNode
=
new
Element
(
"
div
"
,
{
"
styles
"
:
this
.
css
.
doc_toolbar_node
}).
inject
(
this
.
toolNode
);
this
.
toolbarNode
.
set
(
"
html
"
,
html
);
...
...
@@ -1689,6 +1714,20 @@ debugger;
}
},
transWidth
:
function
(
node
){
if
(
!
node
)
return
''
;
while
(
node
){
if
(
node
.
nodeType
==
3
){
node
.
nodeValue
=
node
.
nodeValue
.
replace
(
/
\x
20/g
,
"
"
);
}
else
if
(
node
.
nodeType
==
8
){
//nothing
}
else
{
this
.
transWidth
(
node
.
firstChild
);
}
node
=
node
.
nextSibling
;
}
},
loadCkeditorFiletext
:
function
(
callback
,
inline
){
if
(
this
.
layout_filetext
){
o2
.
load
(
"
../o2_lib/htmleditor/ckeditor4130/ckeditor.js
"
,
function
(){
...
...
@@ -1708,25 +1747,48 @@ debugger;
}.
bind
(
this
)
);
this
.
filetextEditor
.
on
(
'
paste
'
,
function
(
e
)
{
debugger
;
var
html
=
e
.
data
.
dataValue
;
//if (this.json.fullWidth=="y") html = html.replace(/\x20/g, " ");
var
tmp
=
new
Element
(
"
div
"
)
tmp
.
set
(
"
html
"
,
html
);
var
pList
=
tmp
.
getElements
(
"
p
"
);
pList
.
each
(
function
(
p
,
i
){
if
(
Browser
.
name
==
"
ie
"
){
p
.
appendText
(
"
"
,
"
top
"
);
}
else
{
var
textIndent
=
p
.
getStyle
(
"
text-indent
"
);
if
(
textIndent
.
toInt
())
p
.
appendText
(
"
"
,
"
top
"
);
}
});
//if (Browser.name=="ie"){
if
(
this
.
json
.
fullWidth
==
"
y
"
)
this
.
transWidth
(
p
);
if
(
!
p
.
getParent
(
"
table
"
)){
var
text
=
p
.
get
(
"
text
"
);
var
rex
=
/^
\u
3000*/
;
var
m
=
text
.
match
(
rex
);
var
l
=
(
m
[
0
])
?
Math
.
max
((
2
-
m
[
0
].
length
),
0
):
2
;
for
(
var
i
=
0
;
i
<
l
;
i
++
)
p
.
appendText
(
"
"
,
"
top
"
);
}
//}else{
// var textIndent = p.getStyle("text-indent");
// if (textIndent.toInt()) p.appendText(" ","top");
//}
}.
bind
(
this
));
e
.
data
.
dataValue
=
tmp
.
get
(
"
html
"
);
tmp
.
destroy
();
}.
bind
(
this
)
);
// this.filetextEditor.on("key", function(e){
// debugger;
// }.bind(this));
if
(
this
.
json
.
fullWidth
==
"
y
"
){
this
.
filetextEditor
.
addCommand
(
'
insertHalfSpace
'
,
{
exec
:
function
(
editor
)
{
editor
.
insertText
(
"
"
);
}
}
);
this
.
filetextEditor
.
setKeystroke
(
CKEDITOR
.
SHIFT
+
32
,
'
insertHalfSpace
'
)
this
.
filetextEditor
.
on
(
"
key
"
,
function
(
e
){
if
(
this
.
json
.
fullWidth
==
"
y
"
)
if
(
e
.
data
.
keyCode
==
32
){
e
.
editor
.
insertText
(
"
"
);
e
.
cancel
();
}
}.
bind
(
this
));
}
}.
bind
(
this
));
}
...
...
o2web/source/x_component_process_Xform/lp/zh-cn.js
浏览文件 @
5ff74ba6
...
...
@@ -225,6 +225,7 @@ MWF.xApplication.process.Xform.LP = {
"
diff_patch_count
"
:
"
共有{history}个历史版本,{diff}处修订。
"
,
"
original
"
:
"
原始版本
"
,
"
nodiff
"
:
"
目前还没有历史修改信息
"
}
},
"
fullWidth
"
:
"
已启用半角空格自动转换为全角空格,如需输入半角空格,请使用:SHIFT+空格
"
};
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录