Skip to content

+log4js records sensitive operation user ip/account/client information #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 17, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ $ npm run generate
## Features

* NestJS + MySql output API.
* API calls sensitive operation records IP, administrator and client information.
* NuxtJS + Vue + Bootstrap-vue can generate static HTML for the whole site (SEO).
* Nuxtjs vue implements SSR server-side rendering (SEO).
* Element UI + Vue realizes CMS management.
Expand Down
1 change: 1 addition & 0 deletions README.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ $ npm run generate
## 特色

* NestJS + MySql 输出 API。
* API 调用敏感操作记录 IP、管理员及客户端信息。
* Nuxtjs 实现 Vue SSR 服务端渲染 (SEO)。
* NuxtJS + Vue + Bootstrap-vue 实现整站生成 HTML 静态网站 (SEO)。
* Element UI + Vue 实现 CMS 系统管理。
Expand Down
5 changes: 5 additions & 0 deletions admin/src/styles/element-ui.scss
Original file line number Diff line number Diff line change
Expand Up @@ -88,3 +88,8 @@
width: 148px;
height: 148px;
}


.el-upload-list--picture-card .el-upload-list__item-thumbnail {
height: auto !important;
}
10 changes: 5 additions & 5 deletions admin/src/utils/request.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ import { getToken } from '@/utils/auth'
// create an axios instance
const service = axios.create({
baseURL: process.env.VUE_APP_BASE_API, // url = base url + request url
// withCredentials: true, // send cookies when cross-domain requests
withCredentials: true, // send cookies when cross-domain requests
timeout: 5000, // request timeout
})

// request interceptor
service.interceptors.request.use(
config => {
(config) => {
// do something before request is sent

if (store.getters.token) {
Expand All @@ -23,7 +23,7 @@ service.interceptors.request.use(
}
return config
},
error => {
(error) => {
// do something with request error
console.log(error) // for debug
return Promise.reject(error)
Expand All @@ -42,7 +42,7 @@ service.interceptors.response.use(
* Here is just an example
* You can also judge the status by HTTP Status Code
*/
response => {
(response) => {
const { status, data } = response
const res = data

Expand Down Expand Up @@ -86,7 +86,7 @@ service.interceptors.response.use(
return res
}
},
error => {
(error) => {
console.log('err' + error) // for debug
Message({
message: error.message,
Expand Down
Loading