Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Skyeye云
Skyeye
提交
9cc54484
S
Skyeye
项目概览
Skyeye云
/
Skyeye
通知
1425
Star
162
Fork
130
代码
文件
提交
分支
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看板
提交
9cc54484
编写于
3月 04, 2023
作者:
Skyeye云
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
数据表格支持自定义数据属性的数据回显
上级
ac5850db
变更
11
隐藏空白更改
内联
并排
Showing
11 changed file
with
409 addition
and
23 deletion
+409
-23
common/src/main/resources/template/js/dsFormPage/dsFormDetailsPageDesign.js
...sources/template/js/dsFormPage/dsFormDetailsPageDesign.js
+251
-0
common/src/main/resources/template/js/dsFormPage/pageList.js
common/src/main/resources/template/js/dsFormPage/pageList.js
+2
-0
common/src/main/resources/template/js/dsFormPage/pageShow.js
common/src/main/resources/template/js/dsFormPage/pageShow.js
+8
-0
common/src/main/resources/template/tpl/dsFormPage/dsFormDetailsPageDesign.html
...rces/template/tpl/dsFormPage/dsFormDetailsPageDesign.html
+73
-0
common/src/main/resources/template/tpl/dsFormPage/writePage.html
...src/main/resources/template/tpl/dsFormPage/writePage.html
+1
-1
crm/src/main/resources/template/js/customerManage/customerManage.js
...in/resources/template/js/customerManage/customerManage.js
+1
-1
web/src/main/resources/template/assets/lib/layui/customer/common/systemCommonUtil.js
...late/assets/lib/layui/customer/common/systemCommonUtil.js
+17
-0
web/src/main/resources/template/assets/lib/layui/customer/skyeye/dsFormUtil.js
...s/template/assets/lib/layui/customer/skyeye/dsFormUtil.js
+49
-2
web/src/main/resources/template/js/index/index.js
web/src/main/resources/template/js/index/index.js
+1
-10
web/src/main/resources/template/js/traditionpage/index.js
web/src/main/resources/template/js/traditionpage/index.js
+2
-5
web/src/main/resources/template/json/skyeyeClassEnum.json
web/src/main/resources/template/json/skyeyeClassEnum.json
+4
-4
未找到文件。
common/src/main/resources/template/js/dsFormPage/dsFormDetailsPageDesign.js
0 → 100644
浏览文件 @
9cc54484
var
pageId
=
GetUrlParam
(
"
pageId
"
);
var
layedit
,
form
;
// 选中的表单布局组件信息
var
contentData
;
// 表单布局里的组件列表
var
contentList
=
[];
// 子页面调用的函数
var
sortDataIn
;
// 业务对象的属性信息
var
attrList
=
[];
layui
.
config
({
base
:
basePath
,
version
:
skyeyeVersion
}).
extend
({
window
:
'
js/winui.window
'
}).
define
([
'
window
'
,
'
jquery
'
,
'
winui
'
,
'
dragula
'
,
'
tagEditor
'
].
concat
(
dsFormUtil
.
mastHaveImport
),
function
(
exports
)
{
winui
.
renderColor
();
var
index
=
parent
.
layer
.
getFrameIndex
(
window
.
name
);
var
$
=
layui
.
$
;
layedit
=
layui
.
layedit
,
form
=
layui
.
form
;
var
inPageTitle
=
"
已存在布局中,不可选择.
"
;
var
noComponentTitle
=
"
未绑定组件,不可选择.
"
;
// 表单控件集合
var
componentList
=
[];
var
className
=
GetUrlParam
(
"
className
"
);
if
(
isNull
(
className
))
{
winui
.
window
.
msg
(
"
请传入适用对象信息
"
,
{
icon
:
2
,
time
:
2000
});
return
false
;
}
// 加载表单控件
loadLeftBoxItem
();
AjaxPostUtil
.
request
({
url
:
reqBasePath
+
"
dsformpage006
"
,
params
:
{
id
:
pageId
},
type
:
'
json
'
,
method
:
'
GET
'
,
callback
:
function
(
json
)
{
// 加载页面内容
loadPageMation
({
rows
:
json
.
bean
.
dsFormPageContents
});
}});
// 加载新增加的控件信息
function
loadNewControl
(
item
)
{
item
=
dsFormUtil
.
loadComponent
(
'
showForm
'
,
item
);
$
(
"
#showForm div[contentId='
"
+
item
.
id
+
"
']
"
).
append
(
`<div class="btn-base">
<button type="button" class="btn btn-danger removeThis" title="删除"><i class="fa fa-trash"></i></button>
</div>`
);
var
attrKey
=
item
.
attrKey
;
if
(
!
isNull
(
attrKey
))
{
$
(
`#attrBox div[attrKey=
${
attrKey
}
]`
).
attr
(
'
title
'
,
inPageTitle
);
$
(
`#attrBox div[attrKey=
${
attrKey
}
]`
).
find
(
'
i
'
).
removeClass
(
"
i-label-class
"
);
$
(
`#attrBox div[attrKey=
${
attrKey
}
]`
).
addClass
(
"
no-choose
"
);
$
(
`#attrBox div[attrKey=
${
attrKey
}
]`
).
find
(
'
label
'
).
addClass
(
"
no-choose
"
);
}
contentList
.
push
(
item
);
form
.
render
();
}
// 删除
$
(
"
body
"
).
on
(
"
click
"
,
"
.removeThis
"
,
function
(
e
)
{
var
contentId
=
$
(
this
).
parents
(
'
.layui-form-item
'
).
attr
(
"
contentId
"
);
$
(
"
#showForm div[contentId='
"
+
contentId
+
"
']
"
).
remove
();
var
content
=
getInPoingArr
(
contentList
,
'
id
'
,
contentId
);
if
(
!
isNull
(
content
.
attrKey
))
{
$
(
`#attrBox div[attrKey=
${
content
.
attrKey
}
]`
).
attr
(
'
title
'
,
''
);
$
(
`#attrBox div[attrKey=
${
content
.
attrKey
}
]`
).
removeClass
(
"
no-choose
"
);
$
(
`#attrBox div[attrKey=
${
content
.
attrKey
}
]`
).
find
(
'
i
'
).
addClass
(
"
i-label-class
"
);
$
(
`#attrBox div[attrKey=
${
content
.
attrKey
}
]`
).
find
(
'
label
'
).
removeClass
(
"
no-choose
"
);
}
contentList
=
arrayUtil
.
removeArrayPointKey
(
contentList
,
'
id
'
,
contentId
);
contentData
=
null
;
$
(
"
#editPageContent
"
).
attr
(
"
src
"
,
"
../../tpl/dsFormPage/editPageContent.html
"
);
});
function
loadPageMation
(
json
)
{
$
(
"
#attrBox
"
).
html
(
getDataUseHandlebars
(
$
(
"
#leftAttrBoxItem
"
).
html
(),
{
rows
:
attrList
}));
$
.
each
(
json
.
rows
,
function
(
i
,
item
)
{
loadNewControl
(
item
);
});
matchingLanguage
();
}
// 加载表单控件
function
loadLeftBoxItem
()
{
showGrid
({
id
:
"
btnBox
"
,
url
:
reqBasePath
+
"
queryAllDsFormComponentList
"
,
params
:
{
serviceClassName
:
className
},
pagination
:
false
,
method
:
'
GET
'
,
template
:
$
(
"
#leftBoxItem
"
).
html
(),
ajaxSendLoadBefore
:
function
(
hdb
,
json
)
{
$
.
each
(
json
.
bean
,
function
(
key
,
value
)
{
$
.
each
(
value
,
function
(
j
,
bean
)
{
bean
.
logo
=
systemCommonUtil
.
initIconShow
(
bean
);
componentList
.
push
(
bean
);
});
});
},
ajaxSendAfter
:
function
(
json
)
{
// 加载属性
loadClassAttr
();
}
});
}
// 加载属性
function
loadClassAttr
()
{
showGrid
({
id
:
"
attrBox
"
,
url
:
reqBasePath
+
"
queryAttrDefinitionList
"
,
params
:
{
className
:
className
},
pagination
:
false
,
method
:
'
POST
'
,
template
:
$
(
"
#leftAttrBoxItem
"
).
html
(),
ajaxSendLoadBefore
:
function
(
hdb
,
json
)
{
$
.
each
(
json
.
rows
,
function
(
i
,
item
)
{
if
(
isNull
(
item
.
attrDefinitionCustom
)
||
isNull
(
item
.
attrDefinitionCustom
.
dsFormComponent
))
{
item
.
class
=
"
no-choose
"
;
item
.
showTitle
=
noComponentTitle
;
}
else
{
item
.
name
=
item
.
attrDefinitionCustom
.
name
;
var
temp
=
getInPoingArr
(
contentList
,
'
attrKey
'
,
item
.
attrKey
);
if
(
!
isNull
(
temp
))
{
item
.
class
=
"
no-choose
"
;
item
.
showTitle
=
inPageTitle
;
}
else
{
item
.
iLabelClass
=
"
i-label-class
"
;
}
}
});
attrList
=
[].
concat
(
json
.
rows
);
},
ajaxSendAfter
:
function
(
json
)
{
form
.
render
();
dragula
([
document
.
getElementById
(
'
btnBox
'
),
document
.
getElementById
(
'
attrBox
'
),
document
.
getElementById
(
'
showForm
'
)],
{
copy
:
function
(
el
,
source
)
{
//复制
var
check
=
checkMove
(
el
);
if
(
!
check
)
{
return
false
;
}
return
source
===
document
.
getElementById
(
'
btnBox
'
)
||
source
===
document
.
getElementById
(
'
attrBox
'
);
},
accepts
:
function
(
el
,
target
)
{
//移动
var
check
=
checkMove
(
el
);
if
(
!
check
)
{
return
false
;
}
return
target
!=
document
.
getElementById
(
'
btnBox
'
)
&&
target
!=
document
.
getElementById
(
'
attrBox
'
);
}
}).
on
(
'
drop
'
,
function
(
el
,
container
)
{
//放置
if
(
$
(
container
).
attr
(
"
id
"
)
==
'
showForm
'
)
{
var
attrKey
=
$
(
el
).
attr
(
"
attrKey
"
);
attrKey
=
isNull
(
attrKey
)
?
''
:
attrKey
;
addPageContent
(
$
(
el
).
attr
(
"
componentId
"
),
attrKey
);
}
});
}
});
}
function
checkMove
(
el
)
{
if
(
el
.
className
.
indexOf
(
'
no-choose
'
)
>=
0
)
{
return
false
;
}
return
true
;
}
function
addPageContent
(
id
,
attrKey
)
{
var
dsFormComponent
=
getInPoingArr
(
componentList
,
'
id
'
,
id
);
if
(
isNull
(
dsFormComponent
))
{
return
false
;
}
var
params
=
{
width
:
'
layui-col-xs12
'
,
formContentId
:
id
,
dsFormComponent
:
dsFormComponent
,
title
:
dsFormComponent
.
name
,
attrKey
:
attrKey
,
attrDefinition
:
!
isNull
(
attrKey
)
?
getInPoingArr
(
attrList
,
'
attrKey
'
,
attrKey
)
:
null
,
id
:
getRandomValueToString
()
};
loadNewControl
(
params
);
sortDataIn
();
}
// 页面控件点击事件
$
(
"
body
"
).
on
(
"
click
"
,
"
#showForm .layui-form-item
"
,
function
()
{
initFormItemClick
(
$
(
this
));
});
function
initFormItemClick
(
_this
)
{
$
(
"
#showForm .layui-form-item
"
).
removeClass
(
'
ui-sortable-placeholder-choose
'
);
$
(
"
#showForm .layui-form-item
"
).
find
(
'
.btn-base
'
).
hide
();
_this
.
addClass
(
"
ui-sortable-placeholder-choose
"
);
var
contentId
=
_this
.
attr
(
"
contentId
"
);
$
(
"
#showForm div[contentId='
"
+
contentId
+
"
']
"
).
find
(
'
.btn-base
'
).
show
();
contentData
=
getInPoingArr
(
contentList
,
'
id
'
,
contentId
);
$
(
"
#editPageContent
"
).
attr
(
"
src
"
,
"
../../tpl/dsFormPage/editPageContent.html
"
);
}
sortDataIn
=
function
()
{
// 对控件进行排序
$
.
each
(
contentList
,
function
(
i
,
item
)
{
var
inIndex
=
$
(
"
#showForm div[contentId='
"
+
item
.
id
+
"
']
"
).
index
();
contentList
[
i
].
orderBy
=
inIndex
;
});
$
(
"
#showForm
"
).
empty
();
contentList
.
sort
(
getSortFun
(
'
asc
'
,
'
orderBy
'
));
var
newJson
=
[].
concat
(
contentList
);
contentList
=
[];
loadPageMation
({
rows
:
newJson
});
}
var
tip_index
;
$
(
"
body
"
).
on
(
"
mouseenter
"
,
"
.attr-mation
"
,
function
(
e
)
{
var
title
=
$
(
this
).
attr
(
'
title
'
);
if
(
isNull
(
title
))
{
return
false
;
}
tip_index
=
layer
.
tips
(
title
,
this
,
{
time
:
0
,
tips
:
3
});
}).
on
(
'
mouseleave
'
,
"
.attr-mation
"
,
function
()
{
layer
.
close
(
tip_index
);
});
// 保存
$
(
"
body
"
).
on
(
"
click
"
,
"
#save
"
,
function
()
{
for
(
var
i
=
0
;
i
<
contentList
.
length
;
i
++
)
{
var
item
=
contentList
[
i
];
if
(
isNull
(
item
.
attrKey
)
&&
$
.
inArray
(
'
attrKeyBox
'
,
item
.
dsFormComponent
.
attrKeys
)
>=
0
)
{
winui
.
window
.
msg
(
"
存在无关联属性的组件,请移除.
"
,
{
icon
:
2
,
time
:
2000
});
initFormItemClick
(
$
(
"
#showForm div[contentId='
"
+
item
.
id
+
"
']
"
));
return
false
;
}
}
sortDataIn
();
var
params
=
{
pageId
:
pageId
,
dsFormPageContentList
:
encodeURIComponent
(
JSON
.
stringify
(
contentList
))
}
AjaxPostUtil
.
request
({
url
:
reqBasePath
+
"
writeDsFormPageContent
"
,
params
:
params
,
type
:
'
json
'
,
method
:
'
POST
'
,
callback
:
function
(
json
)
{
winui
.
window
.
msg
(
"
保存成功
"
,
{
icon
:
1
,
time
:
2000
});
parent
.
refreshCode
=
'
0
'
;
}});
});
});
\ No newline at end of file
common/src/main/resources/template/js/dsFormPage/pageList.js
浏览文件 @
9cc54484
...
...
@@ -79,6 +79,8 @@ layui.config({
var
url
=
'
../../tpl/dsFormPage/dsFormPageDesign.html
'
;
if
(
data
.
type
==
'
simpleTable
'
)
{
url
=
'
../../tpl/dsFormPage/simpleTableDesign.html
'
;
}
else
if
(
data
.
type
==
'
details
'
)
{
url
=
'
../../tpl/dsFormPage/dsFormDetailsPageDesign.html
'
;
}
url
+=
'
?className=
'
+
objectId
+
'
&pageId=
'
+
data
.
id
+
'
&pageType=
'
+
data
.
type
;
parent
.
parent
.
_openNewWindows
({
...
...
common/src/main/resources/template/js/dsFormPage/pageShow.js
浏览文件 @
9cc54484
...
...
@@ -24,6 +24,14 @@ layui.config({
winui
.
window
.
msg
(
"
该布局信息不存在
"
,
{
icon
:
2
,
time
:
2000
});
return
false
;
}
else
{
if
(
pageMation
.
serviceBeanCustom
.
serviceBean
.
teamAuth
)
{
objectKey
=
GetUrlParam
(
"
objectKey
"
);
objectId
=
GetUrlParam
(
"
objectId
"
);
if
(
isNull
(
objectKey
)
||
isNull
(
objectId
))
{
winui
.
window
.
msg
(
"
请传入适用对象信息
"
,
{
icon
:
2
,
time
:
2000
});
return
false
;
}
}
init
();
}
}});
...
...
common/src/main/resources/template/tpl/dsFormPage/dsFormDetailsPageDesign.html
0 → 100644
浏览文件 @
9cc54484
<!DOCTYPE html>
<html>
<head>
<meta
charset=
"utf-8"
/>
<title></title>
<link
href=
"../../assets/lib/layui/css/layui.css"
rel=
"stylesheet"
/>
<link
href=
"../../assets/lib/winui/css/winui.css"
rel=
"stylesheet"
/>
<link
href=
"../../assets/lib/layui/css/codemirror.css"
rel=
"stylesheet"
/>
<link
href=
"dsFormPageDesign.css"
rel=
"stylesheet"
/>
</head>
<body
style=
"background-color: rgb(234, 234, 234)"
>
<div
class=
"left-box-form"
>
<div
class=
"layui-tab layui-tab-brief"
>
<ul
class=
"layui-tab-title"
>
<li
class=
"layui-this"
>
基本组件
</li>
<li
class=
""
>
属性
</li>
</ul>
<div
class=
"layui-tab-content"
>
<div
class=
"layui-tab-item layui-show"
id=
"btnBox"
></div>
<div
class=
"layui-tab-item"
id=
"attrBox"
></div>
</div>
</div>
</div>
<div
class=
"winui-toolbar center-box-form-toolbar"
>
<div
class=
"winui-tool"
>
<button
id=
"save"
class=
"winui-toolbtn"
><i
class=
"fa fa-save"
aria-hidden=
"true"
></i><language
showName=
"com.skyeye.save"
></language></button>
</div>
</div>
<div
class=
"center-box-form"
>
<form
class=
"layui-form"
action=
""
id=
"showForm"
autocomplete=
"off"
>
</form>
</div>
<div
class=
"right-box-form"
id=
"btnBoxDesign"
>
<iframe
style=
"width: 100%; border: 0px; height: 100%"
scrolling=
"no"
id=
"editPageContent"
></iframe>
</div>
<script
type=
"text/html"
id=
"leftBoxItem"
>
{{
#
each
bean
}}
<
div
class
=
"
layui-form-item layui-col-xs12
"
>
<
span
class
=
"
hr-title
"
>
{{@
key
}}
<
/span><hr
>
<
/div
>
{{
#
each
@
this
}}
<
div
class
=
"
btntext
"
componentId
=
"
{{id}}
"
>
<
div
class
=
"
icon
"
>
{{{
logo
}}}
<
/div
>
<
label
class
=
"
col-sm-12
"
>
{{
name
}}
<
/label
>
<
/div
>
{{
/
each
}}
{{
/
each
}}
</script>
<script
type=
"text/html"
id=
"leftAttrBoxItem"
>
{{
#
each
rows
}}
<
div
class
=
"
btntext attr-mation {{class}}
"
attrKey
=
"
{{attrKey}}
"
componentId
=
"
{{attrDefinitionCustom.dsFormComponent.id}}
"
title
=
"
{{showTitle}}
"
>
<
label
class
=
"
col-sm-12 {{class}}
"
>
<
i
class
=
"
fa fa-arrows fa-fw {{iLabelClass}}
"
><
/i>{{name}
}
<
/label
>
<
/div
>
{{
/
each
}}
</script>
<script
src=
"../../assets/lib/layui/layui.js"
></script>
<script
src=
"../../assets/lib/layui/custom.js"
></script>
<script
type=
"text/javascript"
>
layui
.
config
({
base
:
'
../../js/dsFormPage/
'
}).
use
(
'
dsFormDetailsPageDesign
'
);
</script>
</body>
</html>
\ No newline at end of file
common/src/main/resources/template/tpl/dsFormPage/writePage.html
浏览文件 @
9cc54484
...
...
@@ -53,7 +53,7 @@
<label
class=
"layui-form-label"
>
接口地址
<i
class=
"red"
>
*
</i></label>
<div
class=
"layui-input-block"
>
<input
type=
"text"
id=
"api"
name=
"api"
placeholder=
"请输入接口地址"
win-verify=
"required"
class=
"layui-input"
maxlength=
"200"
/>
<div
class=
"layui-form-mid layui-word-aux"
>
该接口地址为数据保存
/查询
的接口地址,如果不需要填写该接口,请填写:-
</div>
<div
class=
"layui-form-mid layui-word-aux"
>
该接口地址为数据保存的接口地址,如果不需要填写该接口,请填写:-
</div>
</div>
</div>
<div
class=
"layui-form-item layui-col-xs6"
>
...
...
crm/src/main/resources/template/js/customerManage/customerManage.js
浏览文件 @
9cc54484
...
...
@@ -16,7 +16,7 @@ layui.config({
id
:
'
tab
'
,
prefixData
:
[{
title
:
'
详情
'
,
pageUrl
:
'
../../tpl/customerManage/customerDetails.html
'
pageUrl
:
systemCommonUtil
.
getUrl
(
''
,
null
)
}],
element
:
layui
.
element
,
objectType
:
"
1
"
,
...
...
web/src/main/resources/template/assets/lib/layui/customer/common/systemCommonUtil.js
浏览文件 @
9cc54484
...
...
@@ -325,6 +325,23 @@ var systemCommonUtil = {
return
(
url
.
startsWith
(
'
../
'
)
||
url
.
startsWith
(
'
--
'
));
},
/**
* 获取url地址
*
* @param url 系统自定义路径
* @param menuSysWinUrl 分布式系统域名
* @returns {string|*}
*/
getUrl
:
function
(
url
,
menuSysWinUrl
)
{
if
(
systemCommonUtil
.
checkUrl
(
url
))
{
// 自定义页面
url
=
indexMenu
.
getUrlPath
(
url
,
menuSysWinUrl
);
}
else
{
url
=
dsFormPageUrl
+
url
;
}
return
url
},
/**
* 对页面url添加版本控制
*
...
...
web/src/main/resources/template/assets/lib/layui/customer/skyeye/dsFormUtil.js
浏览文件 @
9cc54484
...
...
@@ -128,6 +128,12 @@ var dsFormUtil = {
// 编辑布局
params
[
"
id
"
]
=
GetUrlParam
(
"
id
"
);
}
var
teamAuth
=
dsFormUtil
.
pageMation
.
serviceBeanCustom
.
serviceBean
.
teamAuth
;
if
(
teamAuth
)
{
// 开启团队权限
params
[
'
objectId
'
]
=
objectId
;
params
[
'
objectKey
'
]
=
objectKey
;
}
// 发送请求
dsFormUtil
.
sendRequest
({
businessApi
:
dsFormUtil
.
pageMation
.
businessApi
,
...
...
@@ -508,6 +514,12 @@ var dsFormUtil = {
url
+=
`&
${
key
}
=
${
value
}
`
;
});
}
var
teamAuth
=
dsFormUtil
.
pageMation
.
serviceBeanCustom
.
serviceBean
.
teamAuth
;
if
(
teamAuth
)
{
// 开启团队权限
url
+=
`&objectId=
${
objectId
}
`
;
url
+=
`&objectKey=
${
objectKey
}
`
;
}
_openNewWindows
({
url
:
url
,
title
:
operateOpenPage
.
name
,
...
...
@@ -577,6 +589,7 @@ var dsFormTableUtil = {
// 初始化动态表格
initDynamicTable
:
function
(
id
,
pageMation
)
{
dsFormUtil
.
pageMation
=
pageMation
;
var
tableColumnList
=
pageMation
.
tableColumnList
;
$
.
each
(
tableColumnList
,
function
(
i
,
item
)
{
item
.
label
=
dsFormUtil
.
getLable
(
item
);
...
...
@@ -676,8 +689,9 @@ var dsFormTableUtil = {
hide
:
(
!
isNull
(
item
.
hide
)
&&
item
.
hide
==
1
)
?
true
:
false
,
templet
:
null
};
if
(
!
isNull
(
item
.
templet
))
{
field
[
'
templet
'
]
=
eval
(
'
(
'
+
item
.
templet
+
'
)
'
);
var
templet
=
dsFormTableUtil
.
getTemplateFun
(
item
);
if
(
!
isNull
(
templet
))
{
field
[
'
templet
'
]
=
eval
(
'
(
'
+
templet
+
'
)
'
);
}
header
.
push
(
field
);
});
...
...
@@ -693,6 +707,39 @@ var dsFormTableUtil = {
return
[
header
];
},
getTemplateFun
:
function
(
item
)
{
if
(
!
isNull
(
item
.
templet
))
{
return
item
.
templet
;
}
else
{
if
(
isNull
(
item
.
attrDefinition
)
||
isNull
(
item
.
attrDefinition
.
attrDefinitionCustom
))
{
return
null
;
}
var
customAttr
=
item
.
attrDefinition
.
attrDefinitionCustom
;
var
dataType
=
customAttr
.
dataType
;
if
(
isNull
(
customAttr
.
objectId
)
&&
isNull
(
customAttr
.
defaultData
))
{
return
null
;
}
if
(
dataType
==
1
)
{
// 自定义
var
obj
=
isNull
(
customAttr
.
defaultData
)
?
[]
:
customAttr
.
defaultData
;
if
(
typeof
obj
==
'
string
'
)
{
obj
=
JSON
.
parse
(
obj
);
}
return
`function (d) {
var json =
${
obj
}
;
return getInPoingArr(json, "id", d.
${
item
.
attrKey
}
, "name");
}`
;
}
else
if
(
dataType
==
2
)
{
// 枚举
return
`function (d) {return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey('
${
customAttr
.
objectId
}
', 'id', d.
${
item
.
attrKey
}
, 'name');}`
;
}
else
if
(
dataType
==
3
)
{
// 数据字典
return
`function (d) {return sysDictDataUtil.getDictDataNameByCodeAndKey('
${
customAttr
.
objectId
}
', d.
${
item
.
attrKey
}
);}`
;
}
}
return
null
;
},
initEvent
:
function
(
table
,
form
)
{
form
.
render
();
$
(
"
body
"
).
on
(
"
click
"
,
"
#reloadTable
"
,
function
()
{
...
...
web/src/main/resources/template/js/index/index.js
浏览文件 @
9cc54484
...
...
@@ -962,16 +962,7 @@ layui.config({
return
;
}
if
(
systemCommonUtil
.
checkUrl
(
url
))
{
// 自定义页面
if
(
url
==
'
theme
'
)
{
winui
.
window
.
openTheme
(
loadBottomMenuIcon
);
return
;
}
url
=
indexMenu
.
getUrlPath
(
url
,
menuSysWinUrl
);
}
else
{
url
=
dsFormPageUrl
+
url
;
}
url
=
systemCommonUtil
.
getUrl
(
url
,
menuSysWinUrl
);
if
(
type
===
1
)
{
// 新窗口打开
...
...
web/src/main/resources/template/js/traditionpage/index.js
浏览文件 @
9cc54484
...
...
@@ -147,11 +147,8 @@ layui.config({
active
=
{
//在这里给active绑定几项事件,后面可通过active调用这些事件
tabAdd
:
function
(
url
,
id
,
name
)
{
if
(
systemCommonUtil
.
checkUrl
(
url
))
{
url
=
systemCommonUtil
.
getHasVersionUrl
(
url
);
}
else
{
url
=
dsFormPageUrl
+
url
;
}
url
=
systemCommonUtil
.
getUrl
(
url
,
null
);
//新增一个Tab项 传入三个参数,分别对应其标题,tab页面的地址,还有一个规定的id,是标签中data-id的属性值
//关于tabAdd的方法所传入的参数可看layui的开发文档中基础方法部分
element
.
tabAdd
(
'
menubox
'
,
{
...
...
web/src/main/resources/template/json/skyeyeClassEnum.json
浏览文件 @
9cc54484
...
...
@@ -46,8 +46,8 @@
"eventType"
:
{
"name"
:
"操作按钮事件类型"
,
"className"
:
"skyeye-pro#com.skyeye.operate.classenum.EventType"
},
"operatePosition"
:
{
"name"
:
"操作按钮展示位置"
,
"className"
:
"skyeye-pro#com.skyeye.operate.classenum.OperatePosition"
},
"crmContractStateEnum"
:
{
"name"
:
"
CRM客户
合同状态"
,
"className"
:
"skyeye-crm#com.skyeye.contract.classenum.CrmContractStateEnum"
},
"crmContractAuthEnum"
:
{
"name"
:
"
CRM客户
合同权限"
,
"className"
:
"skyeye-crm#com.skyeye.contract.classenum.CrmContractAuthEnum"
},
"crmOpportunityStateEnum"
:
{
"name"
:
"
CRM客户
商机状态"
,
"className"
:
"skyeye-crm#com.skyeye.opportunity.classenum.CrmOpportunityStateEnum"
},
"crmOpportunityAuthEnum"
:
{
"name"
:
"
CRM客户
商机权限"
,
"className"
:
"skyeye-crm#com.skyeye.opportunity.classenum.CrmOpportunityAuthEnum"
}
"crmContractStateEnum"
:
{
"name"
:
"合同状态"
,
"className"
:
"skyeye-crm#com.skyeye.contract.classenum.CrmContractStateEnum"
},
"crmContractAuthEnum"
:
{
"name"
:
"合同权限"
,
"className"
:
"skyeye-crm#com.skyeye.contract.classenum.CrmContractAuthEnum"
},
"crmOpportunityStateEnum"
:
{
"name"
:
"商机状态"
,
"className"
:
"skyeye-crm#com.skyeye.opportunity.classenum.CrmOpportunityStateEnum"
},
"crmOpportunityAuthEnum"
:
{
"name"
:
"商机权限"
,
"className"
:
"skyeye-crm#com.skyeye.opportunity.classenum.CrmOpportunityAuthEnum"
}
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录