Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
doc_wei
Skyeye
提交
0f174da2
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看板
提交
0f174da2
编写于
8月 09, 2022
作者:
W
weizhiqiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
资产管理修改
上级
5098367f
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
51 addition
and
143 deletion
+51
-143
admin-assistant/src/main/resources/template/js/assetManage/assetManageList.js
...main/resources/template/js/assetManage/assetManageList.js
+28
-83
admin-assistant/src/main/resources/template/js/myHasMation/myAssetManagement.js
...in/resources/template/js/myHasMation/myAssetManagement.js
+23
-27
admin-assistant/src/main/resources/template/tpl/assetManage/assetManageList.html
...n/resources/template/tpl/assetManage/assetManageList.html
+0
-33
未找到文件。
admin-assistant/src/main/resources/template/js/assetManage/assetManageList.js
浏览文件 @
0f174da2
...
...
@@ -4,20 +4,19 @@ var taskType = "";//流程详情的主标题
var
processInstanceId
=
""
;
//流程id
layui
.
config
({
base
:
basePath
,
base
:
basePath
,
version
:
skyeyeVersion
}).
extend
({
window
:
'
js/winui.window
'
}).
define
([
'
window
'
,
'
table
'
,
'
jquery
'
,
'
winui
'
,
'
form
'
,
'
laydate
'
],
function
(
exports
)
{
}).
define
([
'
window
'
,
'
table
'
,
'
jquery
'
,
'
winui
'
,
'
form
'
],
function
(
exports
)
{
winui
.
renderColor
();
var
$
=
layui
.
$
,
form
=
layui
.
form
,
laydate
=
layui
.
laydate
,
table
=
layui
.
table
;
// 新增资产
authBtn
(
'
1566465526122
'
);
showAssetList
();
// 资产列表管理开始
function
showAssetList
(){
...
...
@@ -32,7 +31,7 @@ layui.config({
limits
:
getLimits
(),
limit
:
getLimit
(),
cols
:
[[
{
title
:
systemLanguage
[
"
com.skyeye.serialNumber
"
][
languageType
],
type
:
'
numbers
'
},
{
title
:
systemLanguage
[
"
com.skyeye.serialNumber
"
][
languageType
],
type
:
'
numbers
'
},
{
field
:
'
companyName
'
,
title
:
'
所属公司
'
,
align
:
'
center
'
,
width
:
170
},
{
field
:
'
assetName
'
,
title
:
'
名称
'
,
width
:
120
,
templet
:
function
(
d
)
{
return
'
<a lay-event="assetlistdetails" class="notice-title-click">
'
+
d
.
assetName
+
'
</a>
'
;
...
...
@@ -41,93 +40,40 @@ layui.config({
{
field
:
'
assetNum
'
,
title
:
'
资产编号
'
,
width
:
100
},
{
field
:
'
unitPrice
'
,
title
:
'
资产单价
'
,
align
:
'
center
'
,
width
:
80
},
{
field
:
'
employeeId
'
,
title
:
'
领用人
'
,
align
:
'
center
'
,
width
:
80
},
{
field
:
'
state
'
,
title
:
'
状态
'
,
width
:
80
,
align
:
'
center
'
,
templet
:
function
(
d
)
{
if
(
d
.
state
==
'
1
'
){
return
"
<span class='state-up'>正常</span>
"
;
}
else
if
(
d
.
state
==
'
2
'
){
return
"
<span class='state-down'>维修</span>
"
;
}
else
if
(
d
.
state
==
'
3
'
){
return
"
<span class='state-down'>报废</span>
"
;
}
else
{
return
"
参数错误
"
;
}
}},
{
title
:
systemLanguage
[
"
com.skyeye.operation
"
][
languageType
],
fixed
:
'
right
'
,
align
:
'
center
'
,
width
:
250
,
toolbar
:
'
#assetlisttableBar
'
}
{
title
:
systemLanguage
[
"
com.skyeye.operation
"
][
languageType
],
fixed
:
'
right
'
,
align
:
'
center
'
,
width
:
250
,
toolbar
:
'
#assetlisttableBar
'
}
]],
done
:
function
(){
matchingLanguage
();
}
});
}
// 资产的操作事件
table
.
on
(
'
tool(assetlistTable)
'
,
function
(
obj
)
{
var
data
=
obj
.
data
;
var
layEvent
=
obj
.
event
;
if
(
layEvent
===
'
assetlistrepair
'
)
{
//修复
assetlistrepair
(
data
);
}
else
if
(
layEvent
===
'
assetlistdetails
'
)
{
//详情
assetlistdetails
(
data
);
}
else
if
(
layEvent
===
'
assetlistscrap
'
){
//报废
assetlistscrap
(
data
);
}
else
if
(
layEvent
===
'
assetlistnormal
'
){
//恢复正常
assetlistnormal
(
data
);
}
else
if
(
layEvent
===
'
assetlistdelet
'
){
//删除
assetlistdelet
(
data
);
}
else
if
(
layEvent
===
'
assetlistedit
'
){
//编辑
assetlistedit
(
data
);
}
var
data
=
obj
.
data
;
var
layEvent
=
obj
.
event
;
if
(
layEvent
===
'
assetlistdetails
'
)
{
// 详情
assetlistdetails
(
data
);
}
else
if
(
layEvent
===
'
assetlistdelet
'
)
{
// 删除
assetlistdelet
(
data
);
}
else
if
(
layEvent
===
'
assetlistedit
'
)
{
// 编辑
assetlistedit
(
data
);
}
});
form
.
render
();
// 资产详情
function
assetlistdetails
(
data
){
rowId
=
data
.
id
;
_openNewWindows
({
url
:
"
../../tpl/assetManage/assetManageDetails.html
"
,
url
:
"
../../tpl/assetManage/assetManageDetails.html
"
,
title
:
systemLanguage
[
"
com.skyeye.detailsPageTitle
"
][
languageType
],
pageId
:
"
assetManageDetails
"
,
area
:
[
'
90vw
'
,
'
90vh
'
],
callBack
:
function
(
refreshCode
){
}});
}
// 维修
function
assetlistrepair
(
data
){
var
msg
=
'
确认维修该资产吗?
'
;
layer
.
confirm
(
msg
,
{
icon
:
3
,
title
:
'
维修操作
'
},
function
(
index
)
{
layer
.
close
(
index
);
AjaxPostUtil
.
request
({
url
:
flowableBasePath
+
"
asset008
"
,
params
:{
rowId
:
data
.
id
},
type
:
'
json
'
,
callback
:
function
(
json
)
{
winui
.
window
.
msg
(
systemLanguage
[
"
com.skyeye.successfulOperation
"
][
languageType
],
{
icon
:
1
,
time
:
2000
});
loadassetTable
();
}});
});
}
// 报废
function
assetlistscrap
(
data
){
var
msg
=
'
确认报废该资产吗?
'
;
layer
.
confirm
(
msg
,
{
icon
:
3
,
title
:
'
报废操作
'
},
function
(
index
)
{
layer
.
close
(
index
);
AjaxPostUtil
.
request
({
url
:
flowableBasePath
+
"
asset009
"
,
params
:{
rowId
:
data
.
id
},
type
:
'
json
'
,
callback
:
function
(
json
)
{
winui
.
window
.
msg
(
systemLanguage
[
"
com.skyeye.successfulOperation
"
][
languageType
],
{
icon
:
1
,
time
:
2000
});
loadassetTable
();
}});
});
}
// 恢复正常
function
assetlistnormal
(
data
){
var
msg
=
'
确认对该资产恢复正常吗?
'
;
layer
.
confirm
(
msg
,
{
icon
:
3
,
title
:
'
恢复操作
'
},
function
(
index
)
{
layer
.
close
(
index
);
AjaxPostUtil
.
request
({
url
:
flowableBasePath
+
"
asset007
"
,
params
:{
rowId
:
data
.
id
},
type
:
'
json
'
,
callback
:
function
(
json
)
{
winui
.
window
.
msg
(
systemLanguage
[
"
com.skyeye.successfulOperation
"
][
languageType
],
{
icon
:
1
,
time
:
2000
});
loadassetTable
();
}});
});
}
// 删除
function
assetlistdelet
(
data
){
...
...
@@ -143,7 +89,7 @@ layui.config({
// 新增资产
$
(
"
body
"
).
on
(
"
click
"
,
"
#assetlistaddBean
"
,
function
()
{
_openNewWindows
({
url
:
"
../../tpl/assetManage/assetManageAdd.html
"
,
url
:
"
../../tpl/assetManage/assetManageAdd.html
"
,
title
:
"
新增资产
"
,
pageId
:
"
assetManageAdd
"
,
area
:
[
'
90vw
'
,
'
90vh
'
],
...
...
@@ -152,12 +98,12 @@ layui.config({
loadassetTable
();
}});
});
// 编辑资产
function
assetlistedit
(
data
){
rowId
=
data
.
id
;
_openNewWindows
({
url
:
"
../../tpl/assetManage/assetManageEdit.html
"
,
url
:
"
../../tpl/assetManage/assetManageEdit.html
"
,
title
:
"
编辑资产
"
,
pageId
:
"
assetManageEdit
"
,
area
:
[
'
90vw
'
,
'
90vh
'
],
...
...
@@ -166,26 +112,25 @@ layui.config({
loadassetTable
();
}});
}
$
(
"
body
"
).
on
(
"
click
"
,
"
#assetlistreloadTable
"
,
function
()
{
loadassetTable
();
});
function
loadassetTable
(){
table
.
reload
(
"
assetlistTable
"
,
{
where
:
getTableParams
()});
}
// 搜索表单
$
(
"
body
"
).
on
(
"
click
"
,
"
#assetlistSearch
"
,
function
()
{
table
.
reload
(
"
assetlistTable
"
,
{
page
:
{
curr
:
1
},
where
:
getTableParams
()});
});
function
getTableParams
(){
return
{
assetName
:
$
(
"
#assetName
"
).
val
(),
state
:
$
(
"
#state
"
).
val
()
assetName
:
$
(
"
#assetName
"
).
val
()
};
}
exports
(
'
assetManageList
'
,
{});
});
admin-assistant/src/main/resources/template/js/myHasMation/myAssetManagement.js
浏览文件 @
0f174da2
...
...
@@ -12,34 +12,30 @@ layui.config({
form
=
layui
.
form
,
table
=
layui
.
table
;
showList
();
// 我名下的资产列表
function
showList
(){
table
.
render
({
id
:
'
messageTable
'
,
elem
:
'
#messageTable
'
,
method
:
'
post
'
,
url
:
flowableBasePath
+
'
myhasmation001
'
,
where
:
getTableParams
(),
even
:
true
,
page
:
true
,
limits
:
getLimits
(),
limit
:
getLimit
(),
cols
:
[[
{
title
:
systemLanguage
[
"
com.skyeye.serialNumber
"
][
languageType
],
type
:
'
numbers
'
},
{
field
:
'
companyName
'
,
title
:
'
所属公司
'
,
align
:
'
left
'
,
width
:
170
},
{
field
:
'
assetName
'
,
title
:
'
资产名称
'
,
align
:
'
left
'
,
width
:
120
},
{
field
:
'
typeName
'
,
title
:
'
资产类型
'
,
align
:
'
left
'
,
width
:
100
},
{
field
:
'
assetNum
'
,
title
:
'
资产编号
'
,
align
:
'
left
'
,
width
:
100
},
{
field
:
'
specifications
'
,
title
:
'
资产规格
'
,
align
:
'
left
'
,
width
:
120
},
{
field
:
'
employeeName
'
,
title
:
'
领用人
'
,
align
:
'
left
'
,
width
:
80
},
{
field
:
'
assetAdmin
'
,
title
:
'
管理员
'
,
align
:
'
left
'
,
width
:
80
},
]],
done
:
function
(){
matchingLanguage
();
}
});
}
table
.
render
({
id
:
'
messageTable
'
,
elem
:
'
#messageTable
'
,
method
:
'
post
'
,
url
:
flowableBasePath
+
'
myhasmation001
'
,
where
:
getTableParams
(),
even
:
true
,
page
:
true
,
limits
:
getLimits
(),
limit
:
getLimit
(),
cols
:
[[
{
title
:
systemLanguage
[
"
com.skyeye.serialNumber
"
][
languageType
],
type
:
'
numbers
'
},
{
field
:
'
assetName
'
,
title
:
'
资产名称
'
,
align
:
'
left
'
,
width
:
120
},
{
field
:
'
typeName
'
,
title
:
'
资产类型
'
,
align
:
'
left
'
,
width
:
100
},
{
field
:
'
assetNum
'
,
title
:
'
资产编号
'
,
align
:
'
left
'
,
width
:
100
},
{
field
:
'
specifications
'
,
title
:
'
资产规格
'
,
align
:
'
left
'
,
width
:
120
},
{
field
:
'
employeeName
'
,
title
:
'
领用人
'
,
align
:
'
left
'
,
width
:
120
},
{
field
:
'
assetAdmin
'
,
title
:
'
管理员
'
,
align
:
'
left
'
,
width
:
120
},
]],
done
:
function
(){
matchingLanguage
();
}
});
$
(
"
body
"
).
on
(
"
click
"
,
"
#reloadmessageTable
"
,
function
()
{
loadTable
();
...
...
admin-assistant/src/main/resources/template/tpl/assetManage/assetManageList.html
浏览文件 @
0f174da2
...
...
@@ -16,15 +16,6 @@
<div
class=
"layui-input-inline"
>
<input
type=
"text"
id=
"assetName"
name=
"assetName"
placeholder=
"请输入资产名称"
class=
"layui-input"
/>
</div>
<label
class=
"layui-form-label"
>
状态
</label>
<div
class=
"layui-input-inline"
>
<select
id=
"state"
name=
"state"
>
<option
value=
""
>
全部
</option>
<option
value=
"1"
>
正常
</option>
<option
value=
"2"
>
维修
</option>
<option
value=
"3"
>
报废
</option>
</select>
</div>
<button
type=
"reset"
class=
"layui-btn layui-btn-primary list-form-search"
><language
showName=
"com.skyeye.reset"
></language></button>
<button
class=
"layui-btn list-form-search"
type=
"button"
id=
"assetlistSearch"
><language
showName=
"com.skyeye.search2"
></language></button>
</div>
...
...
@@ -40,30 +31,6 @@
<div
style=
"margin:auto 10px;"
>
<table
id=
"assetlistTable"
lay-filter=
"assetlistTable"
></table>
<script
type=
"text/html"
id=
"assetlisttableBar"
>
{{
#
if
(
d
.
state
==
1
){
}}
{{
#
if
(
auth
(
'
1566466025361
'
)){
}}
<
a
class
=
"
layui-btn layui-btn-xs layui-btn-normal
"
lay
-
event
=
"
assetlistrepair
"
>
维修
<
/a
>
{{
#
}
}}
{{
#
if
(
auth
(
'
1566466057757
'
)){
}}
<
a
class
=
"
layui-btn layui-btn-xs layui-btn-danger
"
lay
-
event
=
"
assetlistscrap
"
>
报废
<
/a
>
{{
#
}
}}
{{
#
}
}}
{{
#
if
(
d
.
state
==
2
){
}}
{{
#
if
(
auth
(
'
1566466091879
'
)){
}}
<
a
class
=
"
layui-btn layui-btn-xs layui-btn-normal
"
lay
-
event
=
"
assetlistnormal
"
>
恢复正常
<
/a
>
{{
#
}
}}
{{
#
if
(
auth
(
'
1566466057757
'
)){
}}
<
a
class
=
"
layui-btn layui-btn-xs layui-btn-danger
"
lay
-
event
=
"
assetlistscrap
"
>
报废
<
/a
>
{{
#
}
}}
{{
#
}
}}
{{
#
if
(
d
.
state
==
3
){
}}
{{
#
if
(
auth
(
'
1566466091879
'
)){
}}
<
a
class
=
"
layui-btn layui-btn-xs layui-btn-normal
"
lay
-
event
=
"
assetlistnormal
"
>
恢复正常
<
/a
>
{{
#
}
}}
{{
#
if
(
auth
(
'
1566466025361
'
)){
}}
<
a
class
=
"
layui-btn layui-btn-xs layui-btn-normal
"
lay
-
event
=
"
assetlistrepair
"
>
维修
<
/a
>
{{
#
}
}}
{{
#
}
}}
{{
#
if
(
auth
(
'
1566465526122
'
)){
}}
<
a
class
=
"
layui-btn layui-btn-xs
"
lay
-
event
=
"
assetlistedit
"
><
language
showName
=
"
com.skyeye.editBtn
"
><
/language></
a
>
{{
#
}
}}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录