Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
device-new-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
device-new-platform
Commits
cebea70f
Commit
cebea70f
authored
2 years ago
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更改上传文件大小限制
parent
bdc01737
master
changemap
dm_branch
reg
No related merge requests found
Changes
19
Hide whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
950 additions
and
107 deletions
+950
-107
assembly/assembly-manager-ui.xml
assembly/assembly-manager-ui.xml
+0
-2
assembly/assembly.xml
assembly/assembly.xml
+12
-11
device-manager-ui/admin/.env.test
device-manager-ui/admin/.env.test
+1
-1
device-manager-ui/admin/package.json
device-manager-ui/admin/package.json
+1
-1
device-manager-ui/admin/src/views/site/dialogshow.vue
device-manager-ui/admin/src/views/site/dialogshow.vue
+160
-0
device-manager-ui/admin/src/views/site/list.vue
device-manager-ui/admin/src/views/site/list.vue
+252
-0
device-manager-ui/admin/src/views/site/show.vue
device-manager-ui/admin/src/views/site/show.vue
+65
-0
device-manager-ui/admin/src/views/site/view.vue
device-manager-ui/admin/src/views/site/view.vue
+172
-0
device-manager/db/add.sql
device-manager/db/add.sql
+0
-0
device-manager/db/base.sql
device-manager/db/base.sql
+0
-0
device-manager/db/init_area.sql
device-manager/db/init_area.sql
+0
-0
device-manager/db/menu.sql
device-manager/db/menu.sql
+0
-0
device-manager/db/module.sql
device-manager/db/module.sql
+0
-0
device-manager/db/params.sql
device-manager/db/params.sql
+0
-0
device-manager/pom.xml
device-manager/pom.xml
+32
-25
device-manager/src/main/bin/deploy.sh
device-manager/src/main/bin/deploy.sh
+180
-0
device-manager/src/main/bin/shutdown.sh
device-manager/src/main/bin/shutdown.sh
+15
-15
device-manager/src/main/bin/stop.sh
device-manager/src/main/bin/stop.sh
+0
-52
device-manager/src/test/java/com/mortals/httpclient/face/FaceController.http
...test/java/com/mortals/httpclient/face/FaceController.http
+60
-0
No files found.
assembly/assembly-ui.xml
→
assembly/assembly-
manager-
ui.xml
View file @
cebea70f
...
...
@@ -7,8 +7,6 @@
<format>
tar.gz
</format>
</formats>
<!-- <includeBaseDirectory>false</includeBaseDirectory>-->
<!-- 需要打包的文件集 -->
<fileSets>
<fileSet>
...
...
This diff is collapsed.
Click to expand it.
assembly/assembly.xml
View file @
cebea70f
...
...
@@ -7,18 +7,9 @@
<format>
tar.gz
</format>
</formats>
<!-- <includeBaseDirectory>false</includeBaseDirectory>-->
<!-- <files>-->
<!-- <file>-->
<!-- <source>${project.parent.basedir}/dist/${project.parent.artifactId}</source>-->
<!-- <destName>XXX-webdemo-2.0.0.jar</destName>-->
<!-- </file>-->
<!-- </files>-->
<fileSets>
<fileSet>
<directory>
${project.parent.basedir}/dist/${project.parent.artifactId}
/bin
</directory>
<directory>
target
/bin
</directory>
<outputDirectory>
bin
</outputDirectory>
<fileMode>
0755
</fileMode>
</fileSet>
...
...
@@ -28,9 +19,19 @@
<fileMode>
0755
</fileMode>
</fileSet>
<fileSet>
<directory>
${project.parent.basedir}/dist/${project.parent.artifactId}/db
</directory>
<directory>
./db
</directory>
<includes>
<include>
*.sql
</include>
</includes>
<outputDirectory>
db
</outputDirectory>
<fileMode>
0755
</fileMode>
</fileSet>
</fileSets>
<files>
<file>
<source>
target/${project.artifactId}-${project.version}.jar
</source>
<outputDirectory>
boot
</outputDirectory>
</file>
</files>
</assembly>
\ No newline at end of file
This diff is collapsed.
Click to expand it.
device-manager-ui/admin/.env.
stage
→
device-manager-ui/admin/.env.
test
View file @
cebea70f
# 测试环境配置
NODE_ENV = '
production
'
NODE_ENV
=
'
test
'
# 地址
VUE_APP_BASE_API
=
http
://
192.168
.
0.98
:
11091
/
m
...
...
This diff is collapsed.
Click to expand it.
device-manager-ui/admin/package.json
View file @
cebea70f
...
...
@@ -5,7 +5,7 @@
"scripts"
:
{
"dev"
:
"vue-cli-service serve"
,
"build"
:
"vue-cli-service build"
,
"
stage"
:
"vue-cli-service build --mode stage
"
,
"
test"
:
"vue-cli-service build --mode test
"
,
"build:prod"
:
"vue-cli-service build --model prod"
},
"dependencies"
:
{
...
...
This diff is collapsed.
Click to expand it.
device-manager-ui/admin/src/views/site/dialogshow.vue
0 → 100644
View file @
cebea70f
<
template
>
<!-- 弹出框表单 -->
<el-dialog
:title=
"title"
:visible.sync=
"open"
width=
"90%"
append-to-body
>
<el-form
ref=
"form"
:model=
"form"
:rules=
"rules"
label-width=
"120px"
>
<el-row>
<Field
label=
"站点名称"
prop=
"siteName"
v-model=
"form.siteName"
placeholder=
"请输入站点名称"
/>
<!--
<Field
label=
"站点编号"
prop=
"siteCode"
v-model=
"form.siteCode"
placeholder=
"请输入站点编号"
/>
-->
<Field
label=
"区域编号"
disabled
prop=
"areaCode"
v-model=
"form.areaCode"
/>
<Field
label=
"区域名称"
disabled
prop=
"areaName"
v-model=
"form.areaName"
/>
<Field
label=
"省编码"
prop=
"proCode"
v-model=
"form.proCode"
placeholder=
"请输入省编码"
/>
<Field
label=
"市编码"
prop=
"cityCode"
v-model=
"form.cityCode"
placeholder=
"请输入市编码"
/>
<Field
label=
"区编码"
prop=
"districtCode"
v-model=
"form.districtCode"
placeholder=
"请输入区编码"
/>
<Field
label=
"站点服务器ip"
prop=
"siteIp"
v-model=
"form.siteIp"
placeholder=
"请输入站点服务器ip"
/>
<Field
label=
"站点服务器端口"
prop=
"sitePort"
v-model=
"form.sitePort"
placeholder=
"请输入站点服务器端口"
/>
<Field
label=
"经度"
prop=
"longitude"
v-model=
"form.longitude"
placeholder=
"请输入经度"
/>
<Field
label=
"纬度"
prop=
"latitude"
v-model=
"form.latitude"
placeholder=
"请输入纬度"
/>
<Field
label=
"中心联系电话"
prop=
"siteTel"
v-model=
"form.siteTel"
placeholder=
"请输入中心联系电话"
/>
<Field
label=
"中心详细地址"
prop=
"detailAddress"
v-model=
"form.detailAddress"
type=
"textarea"
placeholder=
"请输入中心详细地址"
/>
<Field
label=
"中心介绍"
prop=
"siteRemark"
v-model=
"form.siteRemark"
type=
"textarea"
placeholder=
"请输入中心介绍"
/>
<Field
label=
"上午上班开始时间"
prop=
"amWorkStartTime"
v-model=
"form.amWorkStartTime"
type=
"date"
/>
<Field
label=
"上午上班结束时间"
prop=
"amWorkEndTime"
v-model=
"form.amWorkEndTime"
type=
"date"
/>
<Field
label=
"下午上班开始时间"
prop=
"pmWorkStartTime"
mo-model=
"form.pmWorkStartTime"
type=
"date"
/>
<Field
label=
"下午上班结束时间"
prop=
"pmWorkEndTime"
v-model=
"form.pmWorkEndTime"
type=
"date"
/>
<Field
label=
"周一 "
prop=
"workday1"
v-model=
"form.workday1"
type=
"select"
:enumData=
"dict.workday1"
placeholder=
"请选择周一 "
/>
<Field
label=
"周二 "
prop=
"workday2"
v-model=
"form.workday2"
type=
"select"
:enumData=
"dict.workday2"
placeholder=
"请选择周二 "
/>
<Field
label=
"周三 "
prop=
"workday3"
v-model=
"form.workday3"
type=
"select"
:enumData=
"dict.workday3"
placeholder=
"请选择周三 "
/>
<Field
label=
"周四 "
prop=
"workday4"
v-model=
"form.workday4"
type=
"select"
:enumData=
"dict.workday4"
placeholder=
"请选择周四 "
/>
<Field
label=
"周五 "
prop=
"workday5"
v-model=
"form.workday5"
type=
"select"
:enumData=
"dict.workday5"
placeholder=
"请选择周五 "
/>
<Field
label=
"周六 "
prop=
"workday6"
v-model=
"form.workday6"
type=
"select"
:enumData=
"dict.workday6"
placeholder=
"请选择周六 "
/>
<Field
label=
"周日 "
prop=
"workday7"
v-model=
"form.workday7"
type=
"select"
:enumData=
"dict.workday7"
placeholder=
"请选择周日 "
/>
<Field
label=
"楼层"
prop=
"level"
v-model=
"form.level"
placeholder=
"请输入楼层"
/>
<Field
label=
"楼栋"
prop=
"building"
v-model=
"form.building"
placeholder=
"请输入楼栋"
/>
</el-row>
</el-form>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
type=
"primary"
v-if=
"pageInfo.type !== 'view'"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
@
click=
"cancel"
>
取 消
</el-button>
</div>
</el-dialog>
</
template
>
<
script
>
import
form
from
"
@/assets/mixins/formdialog
"
;
import
dialogShow
from
"
./dialogshow
"
;
export
default
{
mixins
:
[
form
],
components
:
{
dialogShow
,
},
data
()
{
return
{
// 遮罩层
loading
:
true
,
// 弹出层标题
title
:
"
站点
"
,
// 是否显示弹出层
open
:
false
,
toString
:[
"
workday1
"
,
"
workday2
"
,
"
workday3
"
,
"
workday4
"
,
"
workday5
"
,
"
workday6
"
,
"
workday7
"
,
],
// 表单校验
rules
:
{
}
};
},
methods
:
{
/** 编辑 */
edit
(
row
)
{
this
.
reset
()
this
.
query
=
{
id
:
row
.
id
};
this
.
urls
.
currUrl
=
this
.
pageInfo
.
editUrl
;;
this
.
getData
();
this
.
pageInfo
.
type
=
"
edit
"
this
.
title
=
"
修改站点
"
;
},
/** 新增 */
add
(
row
)
{
this
.
reset
()
this
.
query
=
{
id
:
row
.
id
};
this
.
urls
.
currUrl
=
this
.
pageInfo
.
addUrl
;
this
.
form
.
areaCode
=
row
.
areaCode
this
.
form
.
areaName
=
row
.
areaName
this
.
getData
();
this
.
pageInfo
.
type
=
"
add
"
this
.
title
=
"
新增站点
"
;
},
/** 查看*/
view
(
row
)
{
this
.
reset
()
this
.
query
=
{
id
:
row
.
id
};
this
.
urls
.
currUrl
=
this
.
pageInfo
.
viewUrl
;;
this
.
getData
();
this
.
pageInfo
.
type
=
"
view
"
this
.
title
=
"
站点详细
"
;
},
/**取消按钮 */
cancel
()
{
this
.
open
=
false
;
},
/**获取数据后弹框 */
afterRender
(
data
)
{
this
.
open
=
true
;
},
afterSubmit
(
data
)
{
this
.
open
=
false
;
this
.
$emit
(
"
ok
"
);
},
// 表单重置
reset
()
{
this
.
form
=
{
siteName
:
null
,
siteCode
:
null
,
areaID
:
null
,
areaCode
:
null
,
areaName
:
null
,
proCode
:
null
,
cityCode
:
null
,
districtCode
:
null
,
siteIp
:
null
,
sitePort
:
null
,
longitude
:
null
,
latitude
:
null
,
siteTel
:
null
,
detailAddress
:
null
,
siteRemark
:
null
,
amWorkStartTime
:
null
,
amWorkEndTime
:
null
,
pmWorkStartTime
:
null
,
pmWorkEndTime
:
null
,
workday1
:
1
,
workday2
:
1
,
workday3
:
1
,
workday4
:
1
,
workday5
:
1
,
workday6
:
0
,
workday7
:
0
,
level
:
1
,
building
:
1
,
};
this
.
resetForm
(
"
form
"
);
},
resetForm
(
refName
)
{
if
(
this
.
$refs
[
refName
])
{
this
.
$refs
[
refName
].
resetFields
();
}
},
},
};
</
script
>
This diff is collapsed.
Click to expand it.
device-manager-ui/admin/src/views/site/list.vue
0 → 100644
View file @
cebea70f
<
template
>
<div
class=
"page"
>
<el-row
:gutter=
"20"
style=
"margin-top:5px"
>
<el-col
:span=
"8"
:xs=
"12"
class=
"mytree"
>
<el-card>
<div
slot=
"header"
>
<span>
站点结构
</span>
</div>
<el-scrollbar
style=
"height: 100%"
>
<el-tree
size=
"mini"
ref=
"areaTree"
:data=
"areaData"
id=
"el-tree"
node-key=
"id"
indent=
"2"
:props=
"treeProps"
:load=
"loadNode"
highlight-current
lazy
:render-content=
"renderContent"
@
node-click=
"handleNodeClick"
>
</el-tree>
</el-scrollbar>
</el-card>
</el-col>
<el-col
:span=
"16"
:xs=
"12"
>
<el-card>
<el-row>
<el-tooltip
effect=
"light"
content=
"新增站点"
>
<el-button
circle
@
click=
"toAdd"
icon=
"el-icon-plus"
size=
"mini"
></el-button>
</el-tooltip>
<el-tooltip
effect=
"light"
content=
"编辑当前产品"
>
<el-button
circle
@
click=
"toEdit"
icon=
"el-icon-edit"
size=
"mini"
></el-button>
</el-tooltip>
</el-row>
<el-divider></el-divider>
<!--
<view-show
ref=
"viewform"
/>
-->
</el-card>
</el-col>
</el-row>
<!--
<LayoutTable
:data=
"tableData"
:config=
"tableConfig"
>
</LayoutTable>
-->
<dialog-show
ref=
"dialogform"
@
ok=
"refreshNodeBy"
/>
</div>
</
template
>
<
script
>
/** 表单弹出框模式需引入 */
import
dialogShow
from
"
./dialogshow
"
;
import
viewShow
from
"
./view
"
;
import
tree
from
"
@/assets/mixins/tree
"
;
export
default
{
name
:
"
Site
"
,
components
:
{
dialogShow
,
viewShow
},
mixins
:
[
tree
],
created
()
{
this
.
$get
(
"
/area/getListByParentId
"
,
{
parentId
:
0
,
}).
then
(({
data
})
=>
{
this
.
areaData
=
data
.
data
});
},
methods
:
{
/** 重写新增方法 */
toAdd
(
row
)
{
if
(
Object
.
keys
(
this
.
currentNode
).
length
===
0
){
this
.
$message
.
info
(
"
请选择区域后新增站点!
"
)
return
}
if
(
this
.
currentNode
.
type
!==
'
area
'
){
this
.
$message
.
info
(
"
请选择区域后新增站点!
"
)
return
}
row
.
areaCode
=
this
.
currentNode
.
areaCode
row
.
areaName
=
this
.
currentNode
.
label
this
.
$refs
.
dialogform
.
add
(
row
);
},
/** 重写编辑方法 */
toEdit
(
row
)
{
if
(
Object
.
keys
(
this
.
currentNode
).
length
===
0
){
this
.
$message
.
info
(
"
请选择站点后再编辑!
"
)
return
}
if
(
this
.
currentNode
.
type
!==
'
site
'
){
this
.
$message
.
info
(
"
请选择站点后再编辑!
"
)
return
}
row
.
id
=
this
.
currentNode
.
id
this
.
$refs
.
dialogform
.
edit
(
row
);
},
toView
(
row
)
{
//console.log("toView", this.$refs.viewform);
// console.log("dialogform", this.$refs.dialogform);
this
.
$refs
.
viewform
.
handleView
(
row
);
},
handleNodeClick
(
node
)
{
this
.
currentNode
=
node
if
(
node
.
type
==
'
site
'
){
this
.
toView
(
this
.
currentNode
);
}
},
renderContent
:
function
(
h
,
{
node
,
data
,
store
})
{
return
(
<
span
>
<
i
style
=
"
font-size:16px;color:#409EFF
"
class
=
{
data
.
icon
}
><
/i
>
<
span
style
=
"
padding-left: 2px;font-size:14px
"
>
{
node
.
label
}
<
/span
>
<
/span
>
);
},
refreshNodeBy
(
id
)
{
let
node
=
this
.
$refs
.
areaTree
.
getNode
(
this
.
currentNode
.
id
);
// 通过节点id找到对应树节点对象
node
.
loaded
=
false
;
node
.
expand
();
// 主动调用展开节点方法,重新查询该节点下的所有子节点
this
.
toView
(
this
.
currentNode
);
},
async
loadNode
(
node
,
resolve
)
{
if
(
node
.
level
===
0
)
{
return
;
}
this
.
$get
(
"
/area/getListByParentId
"
,
{
parentId
:
node
.
data
.
id
,
}).
then
(({
data
})
=>
{
resolve
(
data
.
data
);
});
},
},
data
()
{
return
{
treeProps
:
{
id
:
"
id
"
,
label
:
"
label
"
,
areaCode
:
"
areaCode
"
,
type
:
"
type
"
,
isLeaf
:
"
isLeaf
"
,
children
:
"
children
"
,
icon
:
"
icon
"
,
},
areaData
:[],
currentNode
:{},
};
},
};
</
script
>
<
style
>
.el-card__body
{
padding
:
10px
;
}
.el-calendar-table
.el-calendar-day
{
height
:
70px
;
}
.is-selected
{
color
:
#fa3b19
;
}
</
style
>
<
style
lang=
"scss"
scoped
>
.
mytree
:
:
v-deep
{
.
el-tree--highlight-current
:
:
v-deep
.
el-tree-node
.
is-checked
>
.
el-tree-node__content
{
background-color
:
rgb
(
255
,
255
,
255
);
color
:
rgb
(
64
,
158
,
255
);
}
.
el-tree--highlight-current
:
:
v-deep
.
el-tree-node
.
is-current
>
.
el-tree-node__content
{
background-color
:
rgb
(
255
,
255
,
255
);
color
:
rgb
(
64
,
158
,
255
);
}
.el-tree
>
.el-tree-node
:after
{
border-top
:
none
;
}
.el-tree-node
{
position
:
relative
;
padding-left
:
16px
;
}
//节点有间隙,隐藏掉展开按钮就好了,如果觉得空隙没事可以删掉
.el-tree-node__expand-icon.is-leaf
{
display
:
none
;
}
.el-tree-node__children
{
padding-left
:
16px
;
}
.el-tree-node
:last-child:before
{
height
:
38px
;
}
.el-tree
>
.el-tree-node
:before
{
border-left
:
none
;
}
.el-tree
>
.el-tree-node
:after
{
border-top
:
none
;
}
.el-tree-node
:before
{
content
:
""
;
left
:
-4px
;
position
:
absolute
;
right
:
auto
;
border-width
:
1px
;
}
.el-tree-node
:after
{
content
:
""
;
left
:
-4px
;
position
:
absolute
;
right
:
auto
;
border-width
:
1px
;
}
.el-tree-node
:before
{
border-left
:
1px
dashed
#4386c6
;
bottom
:
0px
;
height
:
100%
;
top
:
-26px
;
width
:
1px
;
}
.el-tree-node
:after
{
border-top
:
1px
dashed
#4386c6
;
height
:
20px
;
top
:
12px
;
width
:
24px
;
}
}
</
style
>
\ No newline at end of file
This diff is collapsed.
Click to expand it.
device-manager-ui/admin/src/views/site/show.vue
0 → 100644
View file @
cebea70f
<
template
>
<layout-form>
<el-form
:model=
"form"
:loading=
"loading"
:rules=
"rules"
size=
'small'
style=
"width:100%"
label-width=
'120px'
ref=
"form"
>
<el-row>
<Field
label=
"站点名称"
prop=
"siteName"
v-model=
"form.siteName"
type=
"textarea"
placeholder=
"请输入站点名称"
/>
<Field
label=
"站点编号"
prop=
"siteCode"
v-model=
"form.siteCode"
placeholder=
"请输入站点编号"
/>
<Field
label=
"区域编号"
prop=
"areaCode"
v-model=
"form.areaCode"
placeholder=
"请输入区域编号"
/>
<Field
label=
"区域名称"
prop=
"areaName"
v-model=
"form.areaName"
placeholder=
"请输入区域名称"
/>
<Field
label=
"省编码"
prop=
"proCode"
v-model=
"form.proCode"
placeholder=
"请输入省编码"
/>
<Field
label=
"市编码"
prop=
"cityCode"
v-model=
"form.cityCode"
placeholder=
"请输入市编码"
/>
<Field
label=
"区编码"
prop=
"districtCode"
v-model=
"form.districtCode"
placeholder=
"请输入区编码"
/>
<Field
label=
"站点服务器ip"
prop=
"siteIp"
v-model=
"form.siteIp"
placeholder=
"请输入站点服务器ip"
/>
<Field
label=
"站点服务器端口"
prop=
"sitePort"
v-model=
"form.sitePort"
placeholder=
"请输入站点服务器端口"
/>
<Field
label=
"经度"
prop=
"longitude"
v-model=
"form.longitude"
placeholder=
"请输入经度"
/>
<Field
label=
"纬度"
prop=
"latitude"
v-model=
"form.latitude"
placeholder=
"请输入纬度"
/>
<Field
label=
"中心联系电话"
prop=
"siteTel"
v-model=
"form.siteTel"
placeholder=
"请输入中心联系电话"
/>
<Field
label=
"中心详细地址"
prop=
"detailAddress"
v-model=
"form.detailAddress"
type=
"textarea"
placeholder=
"请输入中心详细地址"
/>
<Field
label=
"中心介绍"
prop=
"siteRemark"
v-model=
"form.siteRemark"
type=
"textarea"
placeholder=
"请输入中心介绍"
/>
<Field
label=
"上午上班开始时间"
prop=
"amWorkStartTime"
v-model=
"form.amWorkStartTime"
type=
"date"
/>
<Field
label=
"上午上班结束时间"
prop=
"amWorkEndTime"
v-model=
"form.amWorkEndTime"
type=
"date"
/>
<Field
label=
"下午上班开始时间"
prop=
"pmWorkStartTime"
v-model=
"form.pmWorkStartTime"
type=
"date"
/>
<Field
label=
"下午上班结束时间"
prop=
"pmWorkEndTime"
v-model=
"form.pmWorkEndTime"
type=
"date"
/>
<Field
label=
"周一 "
prop=
"workday1"
v-model=
"form.workday1"
type=
"select"
:enumData=
"dict.workday1"
placeholder=
"请选择周一 "
/>
<Field
label=
"周二 "
prop=
"workday2"
v-model=
"form.workday2"
type=
"select"
:enumData=
"dict.workday2"
placeholder=
"请选择周二 "
/>
<Field
label=
"周三 "
prop=
"workday3"
v-model=
"form.workday3"
type=
"select"
:enumData=
"dict.workday3"
placeholder=
"请选择周三 "
/>
<Field
label=
"周四 "
prop=
"workday4"
v-model=
"form.workday4"
type=
"select"
:enumData=
"dict.workday4"
placeholder=
"请选择周四 "
/>
<Field
label=
"周五 "
prop=
"workday5"
v-model=
"form.workday5"
type=
"select"
:enumData=
"dict.workday5"
placeholder=
"请选择周五 "
/>
<Field
label=
"周六 "
prop=
"workday6"
v-model=
"form.workday6"
type=
"select"
:enumData=
"dict.workday6"
placeholder=
"请选择周六 "
/>
<Field
label=
"周日 "
prop=
"workday7"
v-model=
"form.workday7"
type=
"select"
:enumData=
"dict.workday7"
placeholder=
"请选择周日 "
/>
<Field
label=
"楼层"
prop=
"level"
v-model=
"form.level"
placeholder=
"请输入楼层"
/>
<Field
label=
"楼栋"
prop=
"building"
v-model=
"form.building"
placeholder=
"请输入楼栋"
/>
</el-row>
<form-buttons
@
submit=
'submitForm'
:noSaveBtn=
"pageInfo.type === 'view'"
/>
</el-form>
</layout-form>
</
template
>
<
script
>
import
form
from
"
@/assets/mixins/form
"
;
export
default
{
mixins
:
[
form
],
components
:
{
},
methods
:
{
},
data
()
{
return
{
toString
:[
"
workday1
"
,
"
workday2
"
,
"
workday3
"
,
"
workday4
"
,
"
workday5
"
,
"
workday6
"
,
"
workday7
"
,
],
rules
:
{
}
};
}
};
</
script
>
\ No newline at end of file
This diff is collapsed.
Click to expand it.
device-manager-ui/admin/src/views/site/view.vue
0 → 100644
View file @
cebea70f
<
template
>
<div
v-if=
"form.id"
>
<el-descriptions
class=
"descClass"
:title=
"title"
:column=
"column"
:size=
"size"
:colon=
"false"
border
>
<template
slot=
"title"
>
<i
class=
"el-icon-tickets"
></i>
基本信息
</
template
>
<el-descriptions-item
label=
"站点名称"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.siteName}}
</el-descriptions-item>
<el-descriptions-item
label=
"区域编号"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.areaCode}}
</el-descriptions-item>
<el-descriptions-item
label=
"区域名称"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.areaName}}
</el-descriptions-item>
<el-descriptions-item
label=
"站点编号"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.siteCode}}
</el-descriptions-item>
<el-descriptions-item
label=
"省编码"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.proCode}}
</el-descriptions-item>
<el-descriptions-item
label=
"区编码"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.areaCode}}
</el-descriptions-item>
<el-descriptions-item
label=
"市编码"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.cityCode}}
</el-descriptions-item>
<el-descriptions-item
label=
"站点服务器ip"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.siteIp}}
</el-descriptions-item>
<el-descriptions-item
label=
"站点服务器端口"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.sitePort}}
</el-descriptions-item>
<el-descriptions-item
label=
"经度"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.longitude}}
</el-descriptions-item>
<el-descriptions-item
label=
"纬度"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.latitude}}
</el-descriptions-item>
<el-descriptions-item
label=
"中心联系电话"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.siteTel}}
</el-descriptions-item>
<el-descriptions-item
label=
"中心详细地址"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.detailAddress}}
</el-descriptions-item>
<el-descriptions-item
label=
"中心介绍"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.siteRemark}}
</el-descriptions-item>
<el-descriptions-item
label=
"楼层"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.level}}
</el-descriptions-item>
<el-descriptions-item
label=
"楼栋"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.building}}
</el-descriptions-item>
</el-descriptions>
<el-descriptions
class=
"descClass"
:title=
"title"
:column=
"column"
:size=
"size"
:colon=
"false"
border
>
<
template
slot=
"title"
>
<i
class=
"el-icon-tickets"
></i>
办公信息
</
template
>
<el-descriptions-item
label=
"上午上班开始时间"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.amWorkStartTime}}
</el-descriptions-item>
<el-descriptions-item
label=
"上午上班结束时间"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.amWorkEndTime}}
</el-descriptions-item>
<el-descriptions-item
label=
"下午上班开始时间"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.pmWorkStartTime}}
</el-descriptions-item>
<el-descriptions-item
label=
"下午上班结束时间"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{form.pmWorkEndTime}}
</el-descriptions-item>
<el-descriptions-item
label=
"周一 "
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("workday1", form.workday1) }}
</el-descriptions-item>
<el-descriptions-item
label=
"周二 "
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("workday2", form.workday2) }}
</el-descriptions-item>
<el-descriptions-item
label=
"周三 "
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("workday3", form.workday3) }}
</el-descriptions-item>
<el-descriptions-item
label=
"周四 "
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("workday4", form.workday4) }}
</el-descriptions-item>
<el-descriptions-item
label=
"周五 "
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("workday5", form.workday5) }}
</el-descriptions-item>
<el-descriptions-item
label=
"周六 "
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("workday6", form.workday6) }}
</el-descriptions-item>
<el-descriptions-item
label=
"周日 "
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("workday7", form.workday7) }}
</el-descriptions-item>
</el-descriptions>
<el-descriptions
class=
"descClass"
:title=
"title"
:column=
"column"
:size=
"size"
:colon=
"false"
border
>
<
template
slot=
"title"
>
<i
class=
"el-icon-tickets"
></i>
部署模块
</
template
>
<el-descriptions-item
label=
"模块"
label-class-name=
"labelClass"
content-class-name=
"contentClass"
>
{{ util_formatters("modelIds", form.modelIds) }}
</el-descriptions-item>
</el-descriptions>
</div>
</template>
<
script
>
import
view
from
"
@/assets/mixins/view
"
;
export
default
{
mixins
:
[
view
],
components
:
{
},
methods
:
{
/** 查看*/
handleView
(
row
)
{
this
.
query
=
{
id
:
row
.
id
};
this
.
urls
.
currUrl
=
this
.
pageInfo
.
viewUrl
;;
this
.
getData
();
},
},
data
()
{
return
{
size
:
"
small
"
,
column
:
2
,
toString
:[
"
workday1
"
,
"
workday2
"
,
"
workday3
"
,
"
workday4
"
,
"
workday5
"
,
"
workday6
"
,
"
workday7
"
,
],
toArrays
:
[
],
toDate
:
[
]
}
}
}
</
script
>
<
style
lang=
"less"
>
.descClass{
margin-top:5px;
margin-bottom:5px
}
.labelClass{
width: 200px;
}
.el-descriptions__body{
margin-left: 5px;
margin-right: 5px;
color: #606266;
background-color: #FFF;
}
.contentClass{
width: 600px;
}
</
style
>
\ No newline at end of file
This diff is collapsed.
Click to expand it.
db/add.sql
→
d
evice-manager/d
b/add.sql
View file @
cebea70f
File moved
This diff is collapsed.
Click to expand it.
db/base.sql
→
d
evice-manager/d
b/base.sql
View file @
cebea70f
File moved
This diff is collapsed.
Click to expand it.
db/init_area.sql
→
d
evice-manager/d
b/init_area.sql
View file @
cebea70f
File moved
This diff is collapsed.
Click to expand it.
db/menu.sql
→
d
evice-manager/d
b/menu.sql
View file @
cebea70f
File moved
This diff is collapsed.
Click to expand it.
db/module.sql
→
d
evice-manager/d
b/module.sql
View file @
cebea70f
File moved
This diff is collapsed.
Click to expand it.
db/params.sql
→
d
evice-manager/d
b/params.sql
View file @
cebea70f
File moved
This diff is collapsed.
Click to expand it.
device-manager/pom.xml
View file @
cebea70f
...
...
@@ -50,7 +50,6 @@
<profiles.log.level>
DEBUG
</profiles.log.level>
<profiles.log.path>
/logs
</profiles.log.path>
<profiles.data.path>
/data
</profiles.data.path>
<profiles.nacos.server-addr>
127.0.0.1:8848
</profiles.nacos.server-addr>
<profiles.nacos.group>
DEFAULT_GROUP
</profiles.nacos.group>
<profiles.nacos.namespace>
smart-gov
</profiles.nacos.namespace>
...
...
@@ -62,9 +61,12 @@
<id>
test
</id>
<properties>
<profiles.active>
test
</profiles.active>
<profiles.server.ip>
192.168.0.98
</profiles.server.ip>
<profiles.server.port>
18222
</profiles.server.port>
<profiles.nginx.port>
11091
</profiles.nginx.port>
<profiles.server.path>
/sampleform
</profiles.server.path>
<profiles.publish.path>
/home/publish
</profiles.publish.path>
<profiles.platform.type>
cloud
</profiles.platform.type>
<profiles.queue.type>
rabbitmq
</profiles.queue.type>
<profiles.datasource.uri>
<![CDATA[jdbc:mysql://192.168.0.98:3306/device-new-platform?useUnicode=true&characterEncoding=utf8&useSSL=false&serverTimezone=Hongkong]]>
</profiles.datasource.uri>
<profiles.datasource.username>
root
</profiles.datasource.username>
...
...
@@ -74,8 +76,6 @@
<profiles.redis.username></profiles.redis.username>
<profiles.redis.password>
hotel@2020
</profiles.redis.password>
<profiles.redis.database>
6
</profiles.redis.database>
<profiles.kafka.brokers>
192.168.0.251:9092
</profiles.kafka.brokers>
<profiles.queue.type>
rabbitmq
</profiles.queue.type>
<profiles.rabbitmq.host>
192.168.0.98
</profiles.rabbitmq.host>
<profiles.rabbitmq.port>
5672
</profiles.rabbitmq.port>
<profiles.rabbitmq.username>
taxi_mq
</profiles.rabbitmq.username>
...
...
@@ -91,8 +91,8 @@
<profiles.nacos.server-addr>
192.168.0.252:8848
</profiles.nacos.server-addr>
<profiles.nacos.group>
DEFAULT_GROUP
</profiles.nacos.group>
<profiles.nacos.namespace>
smart-gov
</profiles.nacos.namespace>
<profiles.log.path>
/mortals/app/logs
</profiles.log.path>
<package.environment>
stage
</package.environment>
<profiles.log.path>
/
home/
mortals/app/logs
</profiles.log.path>
<package.environment>
test
</package.environment>
<skipDeploy>
false
</skipDeploy>
</properties>
</profile>
...
...
@@ -100,6 +100,11 @@
<id>
product
</id>
<properties>
<profiles.active>
product
</profiles.active>
<profiles.server.ip>
192.168.0.251
</profiles.server.ip>
<profiles.server.port>
17002
</profiles.server.port>
<profiles.nginx.port>
11099
</profiles.nginx.port>
<profiles.server.path>
/sampleform
</profiles.server.path>
<profiles.publish.path>
/home/publish
</profiles.publish.path>
<profiles.server.port>
18222
</profiles.server.port>
<profiles.platform.type>
cloud
</profiles.platform.type>
<profiles.queue.type>
rabbitmq
</profiles.queue.type>
...
...
@@ -223,11 +228,6 @@
<plugin>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-maven-plugin
</artifactId>
<configuration>
<jvmArguments>
-Dfile.encoding=UTF-8
</jvmArguments>
<outputDirectory>
${project.parent.basedir}/dist/${project.parent.artifactId}/boot
</outputDirectory>
<layout>
ZIP
</layout>
</configuration>
</plugin>
<plugin>
<groupId>
org.apache.maven.plugins
</groupId>
...
...
@@ -251,28 +251,36 @@
</goals>
<configuration>
<encoding>
UTF-8
</encoding>
<outputDirectory>
${project.parent.basedir}/dist/${project.parent.artifactId}/bin
</outputDirectory>
<outputDirectory>
target/bin
</outputDirectory>
<resources>
<resource>
<directory>
src/main/bin/
</directory>
<excludes>
<exclude>
deploy.sh
</exclude>
</excludes>
<filtering>
true
</filtering>
</resource>
</resources>
</configuration>
</execution>
<execution>
<id>
copy-d
b
</id>
<id>
copy-d
eploy
</id>
<phase>
package
</phase>
<goals>
<goal>
copy-resources
</goal>
</goals>
<configuration>
<skip>
${skipDeploy}
</skip>
<encoding>
UTF-8
</encoding>
<outputDirectory>
${project.parent.basedir}/dist/${project.parent.artifactId}/db
</outputDirectory>
<outputDirectory>
${project.parent.basedir}/dist/${project.artifactId}/
</outputDirectory>
<resources>
<resource>
<directory>
../db/
</directory>
<directory>
src/main/bin
</directory>
<includes>
<include>
deploy.sh
</include>
</includes>
<filtering>
true
</filtering>
</resource>
</resources>
...
...
@@ -296,9 +304,9 @@
<goal>
exec
</goal>
</goals>
<configuration>
<executable>
npm
</executable>
<executable>
yarn
</executable>
<arguments>
<argument>
install
</argument>
<argument></argument>
</arguments>
<workingDirectory>
${project.parent.basedir}/device-manager-ui/admin
</workingDirectory>
</configuration>
...
...
@@ -311,7 +319,7 @@
<goal>
exec
</goal>
</goals>
<configuration>
<executable>
npm
</executable>
<executable>
yarn
</executable>
<arguments>
<argument>
run
</argument>
<arguments>
${package.environment}
</arguments>
...
...
@@ -322,7 +330,6 @@
</executions>
</plugin>
<plugin>
<artifactId>
maven-assembly-plugin
</artifactId>
<version>
3.3.0
</version>
...
...
@@ -337,12 +344,12 @@
<goal>
single
</goal>
</goals>
<configuration>
<finalName>
device-platform
</finalName>
<finalName>
${project.artifactId}
</finalName>
<appendAssemblyId>
false
</appendAssemblyId>
<descriptors>
<descriptor>
../assembly/assembly.xml
</descriptor>
</descriptors>
<outputDirectory>
${project.parent.basedir}/dist/
device-platform
</outputDirectory>
<outputDirectory>
${project.parent.basedir}/dist/
${project.artifactId}
</outputDirectory>
</configuration>
</execution>
<execution>
...
...
@@ -352,12 +359,12 @@
<goal>
single
</goal>
</goals>
<configuration>
<finalName>
device-platform
-ui
</finalName>
<finalName>
${project.artifactId}
-ui
</finalName>
<appendAssemblyId>
false
</appendAssemblyId>
<descriptors>
<descriptor>
../assembly/assembly-ui.xml
</descriptor>
<descriptor>
../assembly/assembly-
manager-
ui.xml
</descriptor>
</descriptors>
<outputDirectory>
${project.parent.basedir}/dist/
device-platform
</outputDirectory>
<outputDirectory>
${project.parent.basedir}/dist/
${project.artifactId}
</outputDirectory>
</configuration>
</execution>
</executions>
...
...
This diff is collapsed.
Click to expand it.
device-manager/src/main/bin/deploy.sh
0 → 100644
View file @
cebea70f
#!/bin/sh
RETVAL
=
$?
SHELL_NAME
=
$0
BASEDIR
=
$(
dirname
$0
)
BASEDIR
=
$(
(
cd
"
$BASEDIR
"
pwd
)
)
LOCK_FILE
=
"/tmp/deploy.lock"
# 时间变量
LOG_DATE
=
'date "+%Y-%m-%d"'
LOG_TIME
=
'date "+%H-%M-%S"'
PUBLISH_PATH
=
"@profiles.publish.path@"
PROJECT_NAME
=
"@project.artifactId@"
IP
=
"@profiles.server.ip@"
PORT
=
"@profiles.server.port@"
SHELL_LOG
=
"
${
BASEDIR
}
/
${
SHELL_NAME
}
.log"
SERVICE_PATH
=
"/usr/lib/systemd/system"
JAVA_HOME
=
"/usr/local/java/jdk1.8"
NGINX_CONF_PATH
=
"/etc/nginx/conf.d/"
NGINX_PORT
=
"@profiles.nginx.port@"
NGINX_SERVER_PATH
=
"@profiles.server.path@/"
PROJECT_EXECPATH
=
"
${
PUBLISH_PATH
}
/
${
PROJECT_NAME
}
"
PROJECT_UI_EXECPATH
=
"
${
PUBLISH_PATH
}
/
${
PROJECT_NAME
}
-ui"
PROJECT_FILENAME
=
"
${
PROJECT_NAME
}
.tar.gz"
PROJECT_UI_FILENAME
=
"
${
PROJECT_NAME
}
-ui.tar.gz"
PROJECT_SERVICE
=
"
${
SERVICE_PATH
}
/
${
PROJECT_NAME
}
.service"
PROJECT_NGINX_CONF
=
"
${
NGINX_CONF_PATH
}
/
${
PROJECT_NAME
}
.conf"
#加锁
shell_lock
()
{
touch
${
LOCK_FILE
}
}
#删除锁
shell_unlock
()
{
rm
-f
${
LOCK_FILE
}
}
#写日志
writelog
()
{
LOGINFO
=
$1
echo
"
${
CDATE
}
${
CTIME
}
:
${
SHELL_NAME
}
:
${
LOGINFO
}
"
>>
${
SHELL_LOG
}
echo
${
LOGINFO
}
}
#清理目标
clear_deploy
()
{
SERVICE
=
$1
EXECPATH
=
$2
#清理后台自启服务
rm
-rf
${
SERVICE
}
#清理执行文件目录
rm
-rf
${
EXECPATH
}
#清理nginx服务配置文件
rm
-f
${
NGINX_CONF_PATH
}
/
${
PROJECT_NAME
}
.conf
mkdir
-p
${
EXECPATH
}
}
#清理ui
clear_ui_deploy
()
{
EXEC_UI_PATH
=
$1
rm
-rf
${
EXEC_UI_PATH
}
mkdir
-p
${
EXEC_UI_PATH
}
}
build_service
()
{
SERVICE
=
$1
EXECPATH
=
$2
echo
""
>
${
SERVICE
}
echo
"[Unit]"
>>
${
SERVICE
}
echo
"Description=
${
PROJECT_NAME
}
"
>>
${
SERVICE
}
echo
"After=network.target"
>>
${
SERVICE
}
echo
""
>>
${
SERVICE
}
echo
"[Service]"
>>
${
SERVICE
}
echo
"Environment=
\"
JAVA_HOME=
$JAVA_HOME
\"
"
>>
${
SERVICE
}
echo
"Type=forking"
>>
${
SERVICE
}
echo
"ExecStart=
${
EXECPATH
}
/bin/start.sh"
>>
${
SERVICE
}
echo
"ExecStop=
${
EXECPATH
}
/bin/shutdown.sh"
>>
${
SERVICE
}
echo
"PrivateTmp=true"
>>
${
SERVICE
}
echo
""
>>
${
SERVICE
}
echo
"[Install]"
>>
${
SERVICE
}
echo
"WantedBy=multi-user.target"
>>
${
SERVICE
}
writelog
"
${
PROJECT_NAME
}
服务创建完成!"
}
build_nginx
()
{
echo
"server{
gzip on;
gzip_min_length 1k;
gzip_buffers 4 16k;
#gzip_http_version 1.0;
gzip_comp_level 2;
gzip_types text/plain application/javascript application/x-javascript text/css application/xml text/javascript application/x-httpd-php image/jpeg image/gif image/png;
gzip_vary off;
gzip_disable
\"
MSIE [1-6]
\.\"
;
listen
${
NGINX_PORT
}
;
server_name localhost;
location / {
root
${
PROJECT_UI_EXECPATH
}
/dist;
index index.html index.htm;
}
location
${
NGINX_SERVER_PATH
}
{
proxy_pass http://
${
IP
}
:
${
PORT
}
;
proxy_set_header Host
\$
host;
proxy_set_header X-Real-IP
\$
remote_addr;
proxy_set_header X-Forwarded-For
\$
proxy_add_x_forwarded_for;
}
location /doc/ {
root
${
PROJECT_EXECPATH
}
;
index api.html;
}
location /file/fileupload/ {
alias /mortals/app/data/file/fileupload/;
autoindex on;
autoindex_exact_size off;
}
location /file/uploadfile/ {
alias /mortals/app/data/file/uploadfile/;
autoindex on;
autoindex_exact_size off;
}
location /file/preview/ {
alias /mortals/app/data/file/preview/;
autoindex on;
autoindex_exact_size off;
}
}
"
>
${
PROJECT_NGINX_CONF
}
}
#启动服务与nginx
start_service_and_nginx
()
{
writelog
"
${
PROJECT_NAME
}
服务启动..."
systemctl
enable
${
PROJECT_NAME
}
systemctl daemon-reload
systemctl stop
${
PROJECT_NAME
}
systemctl start
${
PROJECT_NAME
}
nginx
-t
nginx
-s
reload
jcpid
=
$(
ps
-ef
|
grep
-v
"grep"
|
grep
"
${
PROJECT_NAME
}
"
|
awk
'{print $2}'
)
writelog
"
${
PROJECT_NAME
}
服务启动,PID is
${
jcpid
}
"
}
#部署后台服务
project_deploy
()
{
writelog
"
${
PROJECT_NAME
}
_deploy"
clear_deploy
${
PROJECT_SERVICE
}
${
PROJECT_EXECPATH
}
writelog
"
${
PROJECT_NAME
}
_clear_finish"
tar
-zvxf
./
${
PROJECT_FILENAME
}
-C
${
PUBLISH_PATH
}
build_service
${
PROJECT_SERVICE
}
${
PROJECT_EXECPATH
}
build_nginx
start_service_and_nginx
writelog
"
${
PROJECT_NAME
}
_deploy_finish"
}
#部署前台服务
project_ui_deploy
()
{
writelog
"
${
PROJECT_NAME
}
_ui_deploy"
clear_ui_deploy
${
PROJECT_UI_EXECPATH
}
tar
-zvxf
./
${
PROJECT_UI_FILENAME
}
-C
${
PUBLISH_PATH
}
writelog
"
${
PROJECT_NAME
}
_ui_deploy_finish"
}
#主函数
main
()
{
echo
"后台服务部署"
project_deploy
echo
"前端服务部署"
project_ui_deploy
exit
${
RETVAL
}
}
main
$1
This diff is collapsed.
Click to expand it.
device-manager/src/main/bin/shutdown.sh
View file @
cebea70f
#! /bin/sh
PORT
=
"17211"
BASEDIR
=
`
dirname
$0
`
BASEDIR
=
`
(
cd
"
$BASEDIR
"
;
pwd
)
`
PORT
=
"@profiles.server.port@"
BASEDIR
=
$(
dirname
$0
)
BASEDIR
=
$(
(
cd
"
$BASEDIR
"
pwd
)
)
PROJECT_NAME
=
"@project.artifactId@"
MAIN_CLASS
=
"
$PROJECT_NAME
"
;
MAIN_CLASS
=
"
$PROJECT_NAME
"
if
[
!
-n
"
$PORT
"
]
;
then
echo
$"Usage:
$0
{port}"
exit
$FAIL
if
[
!
-n
"
$PORT
"
]
;
then
echo
$"Usage:
$0
{port}"
exit
$FAIL
fi
pid
=
`
ps ax |
grep
-i
"
$MAIN_CLASS
"
|
grep
java |
grep
-v
grep
|
awk
'{print $1}'
`
if
[
-z
"
$pid
"
]
;
then
echo
"No Server running."
exit
-1
;
pid
=
$(
ps ax |
grep
-i
"
$MAIN_CLASS
"
|
grep
java |
grep
-v
grep
|
awk
'{print $1}'
)
if
[
-z
"
$pid
"
]
;
then
echo
"No Server running."
exit
1
fi
echo
"stoping application
$PROJECT_NAME
......"
kill
-
9
${
pid
}
kill
-
15
${
pid
}
echo
"Send shutdown request to Server
$PROJECT_NAME
OK"
This diff is collapsed.
Click to expand it.
device-manager/src/main/bin/stop.sh
deleted
100644 → 0
View file @
bdc01737
#! /bin/sh
PORT
=
"@profiles.server.port@"
BASEDIR
=
`
dirname
$0
`
BASEDIR
=
`
(
cd
"
$BASEDIR
"
;
pwd
)
`
PROJECT_NAME
=
"@project.artifactId@"
MAIN_CLASS
=
"
$PROJECT_NAME
"
;
if
[
!
-n
"
$PORT
"
]
;
then
echo
$"Usage:
$0
{port}"
exit
$FAIL
fi
echo
"stoping application
$PROJECT_NAME
......"
jcpid
=
`
ps
-ef
|
grep
-v
"grep"
|
grep
"
$MAIN_CLASS
"
|
grep
"app.port=
$PORT
"
|
sed
-n
'1P'
|
awk
'{print $2}'
`
if
[
-z
$jcpid
]
;
then
echo
"
$PROJECT_NAME
is not started or has been stopped!"
else
curl
-X
POST
-i
-u
$SECURITY_USERNAME
:
$SECURITY_PASSWORD
http://127.0.0.1:
$PORT
/xxx_manager/shutdown
for
i
in
{
1..60
}
do
jcpid
=
`
ps
-ef
|
grep
-v
"grep"
|
grep
"
$MAIN_CLASS
"
|
grep
"app.port=
$PORT
"
|
sed
-n
'1P'
|
awk
'{print $2}'
`
if
[
-z
$jcpid
]
;
then
echo
"
$PROJECT_NAME
has been stopped!"
break
else
echo
"stoping the application ..
$i
"
sleep
1
fi
done
jcpid
=
`
ps
-ef
|
grep
-v
"grep"
|
grep
"
$MAIN_CLASS
"
|
grep
"app.port=
$PORT
"
|
sed
-n
'1P'
|
awk
'{print $2}'
`
if
[
$jcpid
]
;
then
[
-z
$jcpid
]
||
kill
-15
$jcpid
for
i
in
{
1..30
}
do
jcpid
=
`
ps
-ef
|
grep
-v
"grep"
|
grep
"
$MAIN_CLASS
"
|
grep
"app.port=
$PORT
"
|
sed
-n
'1P'
|
awk
'{print $2}'
`
if
[
-z
$jcpid
]
;
then
echo
"
$PROJECT_NAME
has been stopped!"
break
else
echo
"stoping the application ..
$i
"
sleep
1
fi
done
fi
jcpid
=
`
ps
-ef
|
grep
-v
"grep"
|
grep
"
$MAIN_CLASS
"
|
grep
"app.port=
$PORT
"
|
sed
-n
'1P'
|
awk
'{print $2}'
`
if
[
$jcpid
]
;
then
[
-z
$jcpid
]
||
kill
-9
$jcpid
[
$?
-eq
0
]
&&
echo
"Stop
$PROJECT_NAME
OK!"
||
echo
"Stop
$PROJECT_NAME
Fail!"
fi
fi
This diff is collapsed.
Click to expand it.
device-manager/src/test/java/com/mortals/httpclient/face/FaceController.http
0 → 100644
View file @
cebea70f
###登录
POST {{baseUrl}}/login/login
Content-Type: application/json
{
"loginName":"admin",
"password":"admin",
"securityCode":"8888"
}
> {%
client.global.set("SmsSet_id", JSON.parse(response.body).data.id);
client.global.set("authToken", JSON.parse(response.body).data.token);
%}
###人脸识别信息列表
POST {{baseUrl}}/face/list
Authorization: {{authToken}}
Content-Type: application/json
{
"page":1,
"size":10
}
###人脸识别信息更新与保存
POST {{baseUrl}}/face/save
Authorization: {{authToken}}
Content-Type: application/json
{
"placeName":"h4w1jo",
"placeId":"zituyj",
"idCard":"0"
}
> {%
client.global.set("Face_id", JSON.parse(response.body).data.id);
%}
###人脸识别信息查看
GET {{baseUrl}}/face/info?id={{Face_id}}
Authorization: {{authToken}}
Accept: application/json
###人脸识别信息编辑
GET {{baseUrl}}/face/edit?id={{Face_id}}
Authorization: {{authToken}}
Accept: application/json
###人脸识别信息删除
GET {{baseUrl}}/face/delete?id={{Face_id}}
Authorization: {{authToken}}
Accept: application/json
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment