Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
doc_wei
Skyeye
提交
d9779d50
S
Skyeye
项目概览
doc_wei
/
Skyeye
通知
1173
Star
154
Fork
127
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
S
Skyeye
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
d9779d50
编写于
2月 20, 2023
作者:
doc_wei
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
表单加载组件修改,解决handlebar传递对象的问题
上级
1543900e
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
15 addition
and
6 deletion
+15
-6
common/src/main/resources/template/js/codeRule/codeRuleEdit.js
...n/src/main/resources/template/js/codeRule/codeRuleEdit.js
+1
-2
web/src/main/resources/template/assets/lib/layui/custom.js
web/src/main/resources/template/assets/lib/layui/custom.js
+1
-1
web/src/main/resources/template/assets/lib/layui/customer/skyeye/dsFormUtil.js
...s/template/assets/lib/layui/customer/skyeye/dsFormUtil.js
+12
-2
web/src/main/resources/template/assets/lib/layui/lay/modules/jQuery.upload.min.js
...emplate/assets/lib/layui/lay/modules/jQuery.upload.min.js
+1
-1
未找到文件。
common/src/main/resources/template/js/codeRule/codeRuleEdit.js
浏览文件 @
d9779d50
...
@@ -10,8 +10,7 @@ layui.config({
...
@@ -10,8 +10,7 @@ layui.config({
var
index
=
parent
.
layer
.
getFrameIndex
(
window
.
name
);
var
index
=
parent
.
layer
.
getFrameIndex
(
window
.
name
);
var
$
=
layui
.
$
,
var
$
=
layui
.
$
,
textool
=
layui
.
textool
;
textool
=
layui
.
textool
;
var
selOption
=
getFileContent
(
'
tpl/template/select-option.tpl
'
);
showGrid
({
showGrid
({
id
:
"
showForm
"
,
id
:
"
showForm
"
,
url
:
reqBasePath
+
"
queryCodeRuleMationById
"
,
url
:
reqBasePath
+
"
queryCodeRuleMationById
"
,
...
...
web/src/main/resources/template/assets/lib/layui/custom.js
浏览文件 @
d9779d50
...
@@ -121,7 +121,7 @@ function setRequestHeaders(xmlhttp) {
...
@@ -121,7 +121,7 @@ function setRequestHeaders(xmlhttp) {
// 编辑加载自定义的js文件
// 编辑加载自定义的js文件
layui
.
each
(
customerJS
,
function
(
key
,
jsPath
){
layui
.
each
(
customerJS
,
function
(
key
,
jsPath
){
if
(
jsPath
.
lastIndexOf
(
"
.js
"
)
>=
0
)
{
if
(
jsPath
.
lastIndexOf
(
"
.js
"
)
>=
0
)
{
document
.
write
(
'
<script type="text/javascript" src="
'
+
jsPath
+
'
?v=
'
+
skyeyeVersion
+
'
"></script>
'
);
document
.
write
(
'
<script type="text/javascript" src="
'
+
jsPath
+
'
?v=
'
+
skyeyeVersion
+
'
"></script>
'
);
}
else
{
}
else
{
document
.
write
(
'
<link rel="stylesheet" type="text/css" href="
'
+
jsPath
+
'
?v=
'
+
skyeyeVersion
+
'
"/>
'
);
document
.
write
(
'
<link rel="stylesheet" type="text/css" href="
'
+
jsPath
+
'
?v=
'
+
skyeyeVersion
+
'
"/>
'
);
...
...
web/src/main/resources/template/assets/lib/layui/customer/skyeye/dsFormUtil.js
浏览文件 @
d9779d50
...
@@ -134,6 +134,9 @@ var dsFormUtil = {
...
@@ -134,6 +134,9 @@ var dsFormUtil = {
* @param content
* @param content
*/
*/
loadComponent
:
function
(
boxId
,
content
)
{
loadComponent
:
function
(
boxId
,
content
)
{
if
(
!
dsFormUtil
.
checkLoadHandlebar
)
{
dsFormUtil
.
loadHandlebar
();
}
var
component
=
content
.
dsFormComponent
;
var
component
=
content
.
dsFormComponent
;
if
(
component
.
linkedData
==
1
)
{
if
(
component
.
linkedData
==
1
)
{
// 关联数据
// 关联数据
...
@@ -145,8 +148,6 @@ var dsFormUtil = {
...
@@ -145,8 +148,6 @@ var dsFormUtil = {
}
}
var
jsonStr
=
{
bean
:
content
};
var
jsonStr
=
{
bean
:
content
};
// 对象的传递转换,用于组件使用,组件中需要使用 {{{attrDefinitionJson}}} 接收
jsonStr
.
bean
.
attrDefinitionJson
=
JSON
.
stringify
(
jsonStr
.
bean
.
attrDefinition
);
var
html
=
getDataUseHandlebars
(
'
{{#bean}}
'
+
component
.
htmlContent
+
'
{{/bean}}
'
,
jsonStr
);
var
html
=
getDataUseHandlebars
(
'
{{#bean}}
'
+
component
.
htmlContent
+
'
{{/bean}}
'
,
jsonStr
);
var
html_js
=
getDataUseHandlebars
(
'
{{#bean}}
'
+
component
.
jsContent
+
'
{{/bean}}
'
,
jsonStr
);
var
html_js
=
getDataUseHandlebars
(
'
{{#bean}}
'
+
component
.
jsContent
+
'
{{/bean}}
'
,
jsonStr
);
var
jsCon
=
`<script>
${
html_js
}
</script>`
;
var
jsCon
=
`<script>
${
html_js
}
</script>`
;
...
@@ -159,6 +160,15 @@ var dsFormUtil = {
...
@@ -159,6 +160,15 @@ var dsFormUtil = {
return
content
;
return
content
;
},
},
checkLoadHandlebar
:
false
,
loadHandlebar
:
function
()
{
dsFormUtil
.
checkLoadHandlebar
=
true
;
// 加载json对象
Handlebars
.
registerHelper
(
'
json
'
,
function
(
context
)
{
return
JSON
.
stringify
(
context
);
});
},
getLable
:
function
(
content
)
{
getLable
:
function
(
content
)
{
var
attr
=
content
.
attrDefinition
;
var
attr
=
content
.
attrDefinition
;
if
(
!
isNull
(
attr
)
&&
!
$
.
isEmptyObject
(
attr
))
{
if
(
!
isNull
(
attr
)
&&
!
$
.
isEmptyObject
(
attr
))
{
...
...
web/src/main/resources/template/assets/lib/layui/lay/modules/jQuery.upload.min.js
浏览文件 @
d9779d50
...
@@ -413,7 +413,7 @@ layui.define(["jquery"], function(exports) {
...
@@ -413,7 +413,7 @@ layui.define(["jquery"], function(exports) {
if
([
"
avi
"
,
"
wmv
"
,
"
mpeg
"
,
"
mp4
"
,
"
mov
"
,
"
mkv
"
,
"
flv
"
,
"
f4v
"
,
"
m4v
"
,
"
rmvb
"
,
"
rm
"
,
"
3gp
"
,
"
dat
"
,
"
ts
"
,
"
mts
"
,
"
vob
"
].
indexOf
(
i
)
>=
0
)
{
if
([
"
avi
"
,
"
wmv
"
,
"
mpeg
"
,
"
mp4
"
,
"
mov
"
,
"
mkv
"
,
"
flv
"
,
"
f4v
"
,
"
m4v
"
,
"
rmvb
"
,
"
rm
"
,
"
3gp
"
,
"
dat
"
,
"
ts
"
,
"
mts
"
,
"
vob
"
].
indexOf
(
i
)
>=
0
)
{
return
'
<svg xmlns="http://www.w3.org/2000/svg" class="icon" version="1" viewBox="0 0 1024 1024"><path fill="#8095FF" d="M80 34h864v960H80z"/><path fill="#FFF" d="M136 112a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 272a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 432a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 592a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 752a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 912a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 112a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 272a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 432a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 592a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 752a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 912a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM648 508L436 362c-5-3-11-4-17 0-5 3-9 8-9 14v290c0 6 4 12 9 15 6 3 12 2 17-1l212-146c5-3 7-8 7-13s-3-10-7-13z"/></svg>
'
return
'
<svg xmlns="http://www.w3.org/2000/svg" class="icon" version="1" viewBox="0 0 1024 1024"><path fill="#8095FF" d="M80 34h864v960H80z"/><path fill="#FFF" d="M136 112a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 272a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 432a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 592a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 752a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM136 912a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 112a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 272a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 432a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 592a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 752a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM824 912a40 40 0 1 0 80 0 40 40 0 1 0-80 0zM648 508L436 362c-5-3-11-4-17 0-5 3-9 8-9 14v290c0 6 4 12 9 15 6 3 12 2 17-1l212-146c5-3 7-8 7-13s-3-10-7-13z"/></svg>
'
}
}
if
(
[
"
gif
"
,
"
jpg
"
,
"
jpeg
"
,
"
png
"
,
"
bmp
"
]
.
indexOf
(
i
)
>=
0
)
{
if
(
imageType
.
indexOf
(
i
)
>=
0
)
{
return
'
<svg xmlns="http://www.w3.org/2000/svg" class="icon" version="1" viewBox="0 0 1024 1024"><defs/><path fill="#FF5562" d="M160 32a49 49 0 0 0-48 48v864c0 12 5 25 14 34 10 9 22 14 34 14h704c12 0 25-5 34-14 9-10 14-22 14-34V304L640 32H160z"/><path fill="#FFBBC0" d="M912 304H688c-12 0-25-5-34-14s-14-22-14-34V32l272 272z"/><path fill="#FFF" d="M758 706L658 550c-3-4-8-7-13-7s-11 3-14 7l-53 84-120-195c-4-5-8-7-14-7s-10 3-14 7L266 706c-4 4-4 11 0 16 3 5 8 8 13 8h466c5 0 11-4 14-8 3-6 3-12-1-16zM622 412a40 40 0 1 0 80 0 40 40 0 1 0-80 0z"/></svg>
'
return
'
<svg xmlns="http://www.w3.org/2000/svg" class="icon" version="1" viewBox="0 0 1024 1024"><defs/><path fill="#FF5562" d="M160 32a49 49 0 0 0-48 48v864c0 12 5 25 14 34 10 9 22 14 34 14h704c12 0 25-5 34-14 9-10 14-22 14-34V304L640 32H160z"/><path fill="#FFBBC0" d="M912 304H688c-12 0-25-5-34-14s-14-22-14-34V32l272 272z"/><path fill="#FFF" d="M758 706L658 550c-3-4-8-7-13-7s-11 3-14 7l-53 84-120-195c-4-5-8-7-14-7s-10 3-14 7L266 706c-4 4-4 11 0 16 3 5 8 8 13 8h466c5 0 11-4 14-8 3-6 3-12-1-16zM622 412a40 40 0 1 0 80 0 40 40 0 1 0-80 0z"/></svg>
'
}
}
return
'
<svg xmlns="http://www.w3.org/2000/svg" class="icon" version="1" viewBox="0 0 1024 1024"><path fill="#E5E5E5" d="M160 32a49 49 0 0 0-48 48v864c0 12 5 25 14 34 10 9 22 14 34 14h704c12 0 25-5 34-14 9-10 14-22 14-34V304L640 32H160z"/><path fill="#CCC" d="M912 304H688c-12 0-25-5-34-14s-14-22-14-34V32l272 272z"/></svg>
'
return
'
<svg xmlns="http://www.w3.org/2000/svg" class="icon" version="1" viewBox="0 0 1024 1024"><path fill="#E5E5E5" d="M160 32a49 49 0 0 0-48 48v864c0 12 5 25 14 34 10 9 22 14 34 14h704c12 0 25-5 34-14 9-10 14-22 14-34V304L640 32H160z"/><path fill="#CCC" d="M912 304H688c-12 0-25-5-34-14s-14-22-14-34V32l272 272z"/></svg>
'
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录