接口日志
This commit is contained in:
@@ -57,7 +57,7 @@
|
||||
|
||||
<script>
|
||||
import Search from './search'
|
||||
import { delAllInfo } from '@/api/monitor/log'
|
||||
import crudInterfaceLog from './interfaceLog'
|
||||
import CRUD, { presenter } from '@crud/crud'
|
||||
import crudOperation from '@crud/CRUD.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
@@ -85,7 +85,7 @@ export default {
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.crud.delAllLoading = true
|
||||
delAllInfo().then(res => {
|
||||
crudInterfaceLog.delLogs().then(res => {
|
||||
this.crud.delAllLoading = false
|
||||
this.crud.dleChangePage(1)
|
||||
this.crud.delSuccessNotify()
|
||||
|
||||
@@ -7,4 +7,16 @@ export function add(data) {
|
||||
data
|
||||
})
|
||||
}
|
||||
export default { add }
|
||||
export function delLogs() {
|
||||
return request({
|
||||
url: 'api/interfaceLog/delLogs',
|
||||
method: 'delete'
|
||||
})
|
||||
}
|
||||
export function getLogTypeList() {
|
||||
return request({
|
||||
url: 'api/interfaceLog/logTypeList',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
export default { add, delLogs, getLogTypeList }
|
||||
|
||||
@@ -8,6 +8,20 @@
|
||||
style="width: 200px;"
|
||||
class="filter-item"
|
||||
/>
|
||||
<el-select
|
||||
v-model="query.logType"
|
||||
clearable
|
||||
filterable
|
||||
size="mini"
|
||||
placeholder="日志类型"
|
||||
class="filter-item"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in logTypeList"
|
||||
:label="item"
|
||||
:value="item"
|
||||
/>
|
||||
</el-select>
|
||||
<date-range-picker v-model="query.createTime" class="date-item" />
|
||||
<rrOperation />
|
||||
</div>
|
||||
@@ -17,8 +31,19 @@
|
||||
import { header } from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import DateRangePicker from '@/components/DateRangePicker'
|
||||
import { getLogTypeList } from '@/views/monitor/interfaceLog/interfaceLog'
|
||||
export default {
|
||||
components: { rrOperation, DateRangePicker },
|
||||
mixins: [header()]
|
||||
mixins: [header()],
|
||||
data() {
|
||||
return {
|
||||
logTypeList: []
|
||||
}
|
||||
},
|
||||
created() {
|
||||
getLogTypeList().then(res => {
|
||||
this.logTypeList = res
|
||||
})
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user