Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_web
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pseer
gxpt_web
Commits
44a93a28
Commit
44a93a28
authored
Jan 16, 2024
by
YG8999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
短信日志、扫呗日志
parent
fa313fc7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
263 additions
and
1 deletions
+263
-1
smsLog.js
src/api/system/smsLog.js
+44
-0
index.vue
src/views/system/saobeiApiLog/index.vue
+0
-0
index.vue
src/views/system/smsLog/index.vue
+218
-0
index.vue
src/views/system/statusLog/index.vue
+1
-1
No files found.
src/api/system/smsLog.js
0 → 100644
View file @
44a93a28
import
request
from
'@/utils/request'
// 查询短信日志列表
export
function
listLog
(
query
)
{
return
request
({
url
:
'/system/sms/log/list'
,
method
:
'get'
,
params
:
query
})
}
// 查询短信日志详细
export
function
getLog
(
id
)
{
return
request
({
url
:
'/system/sms/log/'
+
id
,
method
:
'get'
})
}
// 新增短信日志
export
function
addLog
(
data
)
{
return
request
({
url
:
'/system/sms/log'
,
method
:
'post'
,
data
:
data
})
}
// 修改短信日志
export
function
updateLog
(
data
)
{
return
request
({
url
:
'/system/sms/log'
,
method
:
'put'
,
data
:
data
})
}
// 删除短信日志
export
function
delLog
(
id
)
{
return
request
({
url
:
'/system/sms/log/'
+
id
,
method
:
'delete'
})
}
src/views/system/saobeiApiLog/index.vue
View file @
44a93a28
This diff is collapsed.
Click to expand it.
src/views/system/smsLog/index.vue
0 → 100644
View file @
44a93a28
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<el-form-item
label=
"手机号码"
prop=
"phone"
>
<el-input
v-model=
"queryParams.phone"
placeholder=
"请输入发送手机号码"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"发送结果"
prop=
"result"
>
<el-select
v-model=
"queryParams.result"
placeholder=
"请选择"
>
<el-option
v-for=
"item in options"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
icon=
"el-icon-search"
size=
"mini"
@
click=
"handleQuery"
>
搜索
</el-button>
<el-button
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
<el-row
:gutter=
"10"
class=
"mb8"
>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
</el-row>
<el-table
v-loading=
"loading"
:data=
"logList"
>
<!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
-->
<!--
<el-table-column
label=
"主键"
align=
"center"
prop=
"id"
/>
-->
<el-table-column
label=
"手机号码"
align=
"center"
prop=
"phone"
/>
<!--
<el-table-column
label=
"短信模版"
align=
"center"
prop=
"templateId"
/>
-->
<el-table-column
label=
"签名"
align=
"center"
prop=
"signature"
/>
<el-table-column
label=
"短信内容"
align=
"center"
prop=
"content"
width=
"450"
/>
<el-table-column
label=
"短信类型"
align=
"center"
prop=
"smsType"
>
<template
slot-scope=
"scope"
>
<dict-tag
:options=
"dict.type.sms_type"
:value=
"scope.row.smsType"
/>
</
template
>
</el-table-column>
<!-- <el-table-column label="备注" align="center" prop="remark" />-->
<el-table-column
label=
"发送结果"
align=
"center"
prop=
"result"
:formatter=
"(row) => resultFormatter(row.result)"
/>
<!-- <el-table-column label="返回内容" align="center" prop="resultParam" />-->
<el-table-column
label=
"记录时间"
align=
"center"
prop=
"createTime"
width=
"100"
>
<
template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
createTime
,
'{y
}
-{m
}
-{d
}
{h
}
:{i
}
:{s
}
'
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<
el
-
table
-
column
label
=
"操作"
align
=
"center"
class
-
name
=
"small-padding fixed-width"
>
<
template
slot
-
scope
=
"scope"
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-edit"
@
click
=
"handleUpdate(scope.row)"
>
详情
<
/el-button
>
<
/template
>
<
/el-table-column
>
<
/el-table
>
<
pagination
v
-
show
=
"total>0"
:
total
=
"total"
:
page
.
sync
=
"queryParams.pageNum"
:
limit
.
sync
=
"queryParams.pageSize"
@
pagination
=
"getList"
/>
<!--
添加或修改短信日志对话框
-->
<
el
-
dialog
:
title
=
"title"
:
visible
.
sync
=
"open"
width
=
"50%"
append
-
to
-
body
>
<
el
-
form
ref
=
"form"
:
model
=
"form"
:
rules
=
"rules"
label
-
width
=
"100px"
>
<
el
-
form
-
item
label
=
"发送手机号码"
prop
=
"phone"
>
<
el
-
input
v
-
model
=
"form.phone"
placeholder
=
"请输入发送手机号码"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"签名"
prop
=
"signature"
>
<
el
-
input
v
-
model
=
"form.signature"
placeholder
=
"请输入签名"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"短信内容"
>
<
el
-
input
type
=
"textarea"
v
-
model
=
"form.content"
:
rows
=
"4"
/>
<
/el-form-item
>
<!--
<
el
-
form
-
item
label
=
"备注"
prop
=
"remark"
>-->
<!--
<
el
-
input
v
-
model
=
"form.remark"
placeholder
=
"请输入备注"
/>-->
<!--
<
/el-form-item>--
>
<
el
-
form
-
item
label
=
"发送结果"
prop
=
"result"
>
<
el
-
input
v
-
model
=
"form.result"
placeholder
=
"请输入结果:1-成功,2-失败"
/>
<
/el-form-item
>
<
el
-
form
-
item
label
=
"返回内容"
prop
=
"resultParam"
>
<
el
-
input
v
-
model
=
"form.resultParam"
type
=
"textarea"
:
rows
=
"3"
/>
<
/el-form-item
>
<
/el-form
>
<
div
slot
=
"footer"
class
=
"dialog-footer"
>
<
el
-
button
@
click
=
"cancel"
>
取
消
<
/el-button
>
<
/div
>
<
/el-dialog
>
<
/div
>
<
/template
>
<
script
>
import
{
listLog
,
getLog
,
delLog
,
addLog
,
updateLog
}
from
"@/api/system/smsLog"
;
export
default
{
name
:
"SmsLog"
,
dicts
:
[
'sms_type'
],
data
()
{
return
{
// 遮罩层
loading
:
true
,
// 选中数组
ids
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 短信日志表格数据
logList
:
[],
// 弹出层标题
title
:
""
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
pageNum
:
1
,
pageSize
:
10
,
phone
:
null
,
templateId
:
null
,
signature
:
null
,
content
:
null
,
smsType
:
null
,
result
:
null
,
resultParam
:
null
}
,
// 表单参数
form
:
{
}
,
// 表单校验
rules
:
{
}
,
options
:
[{
value
:
'1'
,
label
:
'成功'
}
,
{
value
:
'0'
,
label
:
'失败'
}
]
}
;
}
,
created
()
{
this
.
getList
();
}
,
methods
:
{
/** 查询短信日志列表 */
getList
()
{
this
.
loading
=
true
;
listLog
(
this
.
queryParams
).
then
(
response
=>
{
this
.
logList
=
response
.
rows
;
this
.
total
=
response
.
total
;
this
.
loading
=
false
;
}
);
}
,
// 取消按钮
cancel
()
{
this
.
open
=
false
;
this
.
reset
();
}
,
// 表单重置
reset
()
{
this
.
form
=
{
id
:
null
,
phone
:
null
,
templateId
:
null
,
signature
:
null
,
content
:
null
,
smsType
:
null
,
createBy
:
null
,
createTime
:
null
,
updateBy
:
null
,
updateTime
:
null
,
remark
:
null
,
result
:
null
,
resultParam
:
null
}
;
this
.
resetForm
(
"form"
);
}
,
/** 搜索按钮操作 */
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
;
this
.
getList
();
}
,
/** 重置按钮操作 */
resetQuery
()
{
this
.
resetForm
(
"queryForm"
);
this
.
handleQuery
();
}
,
/** 修改按钮操作 */
handleUpdate
(
row
)
{
this
.
reset
();
const
id
=
row
.
id
||
this
.
ids
getLog
(
id
).
then
(
response
=>
{
this
.
form
=
response
.
data
;
this
.
form
.
result
=
this
.
resultFormatter
(
response
.
data
.
result
)
this
.
open
=
true
;
this
.
title
=
"查看短信日志"
;
}
);
}
,
resultFormatter
(
value
)
{
return
value
===
1
?
'成功'
:
value
===
0
?
'失败'
:
''
;
}
}
}
;
<
/script
>
src/views/system/statusLog/index.vue
View file @
44a93a28
...
@@ -41,7 +41,7 @@
...
@@ -41,7 +41,7 @@
</el-row>
</el-row>
<el-table
v-loading=
"loading"
:data=
"logList"
>
<el-table
v-loading=
"loading"
:data=
"logList"
>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/
>
<!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
--
>
<el-table-column
label=
"设备ID"
align=
"center"
prop=
"devId"
/>
<el-table-column
label=
"设备ID"
align=
"center"
prop=
"devId"
/>
<el-table-column
label=
"设备mac"
align=
"center"
prop=
"devMac"
/>
<el-table-column
label=
"设备mac"
align=
"center"
prop=
"devMac"
/>
<el-table-column
label=
"是否异常变更"
align=
"center"
prop=
"isAbnormal"
:formatter=
"(row) => filedFormatter(row.isAbnormal)"
/>
<el-table-column
label=
"是否异常变更"
align=
"center"
prop=
"isAbnormal"
:formatter=
"(row) => filedFormatter(row.isAbnormal)"
/>
...
...
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