Skip to content
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

eladmin updated to modules #129

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
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
4 changes: 2 additions & 2 deletions src/api/generator/genConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ import request from '@/utils/request'

export function get(tableName) {
return request({
url: 'api/genConfig/' + tableName,
url: 'system/api/genConfig/' + tableName,
method: 'get'
})
}

export function update(data) {
return request({
url: 'api/genConfig',
url: 'system/api/genConfig',
data,
method: 'put'
})
Expand Down
8 changes: 4 additions & 4 deletions src/api/generator/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,30 @@ import request from '@/utils/request'

export function getAllTable() {
return request({
url: 'api/generator/tables/all',
url: 'system/api/generator/tables/all',
method: 'get'
})
}

export function generator(tableName, type) {
return request({
url: 'api/generator/' + tableName + '/' + type,
url: 'system/api/generator/' + tableName + '/' + type,
method: 'post',
responseType: type === 2 ? 'blob' : ''
})
}

export function save(data) {
return request({
url: 'api/generator',
url: 'system/api/generator',
data,
method: 'put'
})
}

export function sync(tables) {
return request({
url: 'api/generator/sync',
url: 'system/api/generator/sync',
method: 'post',
data: tables
})
Expand Down
8 changes: 4 additions & 4 deletions src/api/login.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import request from '@/utils/request'

export function login(username, password, code, uuid) {
return request({
url: 'auth/login',
url: 'system/auth/login',
method: 'post',
data: {
username,
Expand All @@ -15,21 +15,21 @@ export function login(username, password, code, uuid) {

export function getInfo() {
return request({
url: 'auth/info',
url: 'system/auth/info',
method: 'get'
})
}

export function getCodeImg() {
return request({
url: 'auth/code',
url: 'system/auth/code',
method: 'get'
})
}

export function logout() {
return request({
url: 'auth/logout',
url: 'system/auth/logout',
method: 'delete'
})
}
6 changes: 3 additions & 3 deletions src/api/mnt/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,23 @@ import request from '@/utils/request'

export function add(data) {
return request({
url: 'api/app',
url: 'mng/api/app',
method: 'post',
data
})
}

export function del(ids) {
return request({
url: 'api/app',
url: 'mng/api/app',
method: 'delete',
data: ids
})
}

export function edit(data) {
return request({
url: 'api/app',
url: 'mng/api/app',
method: 'put',
data
})
Expand Down
4 changes: 2 additions & 2 deletions src/api/mnt/connect.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ import request from '@/utils/request'

export function testDbConnect(data) {
return request({
url: 'api/database/testConnect',
url: 'mng/api/database/testConnect',
method: 'post',
data
})
}

export function testServerConnect(data) {
return request({
url: 'api/serverDeploy/testConnect',
url: 'mng/api/serverDeploy/testConnect',
method: 'post',
data
})
Expand Down
8 changes: 4 additions & 4 deletions src/api/mnt/database.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,31 @@ import request from '@/utils/request'

export function add(data) {
return request({
url: 'api/database',
url: 'mng/api/database',
method: 'post',
data
})
}

export function del(ids) {
return request({
url: 'api/database',
url: 'mng/api/database',
method: 'delete',
data: ids
})
}

export function edit(data) {
return request({
url: 'api/database',
url: 'mng/api/database',
method: 'put',
data
})
}

export function testDbConnection(data) {
return request({
url: 'api/database/testConnect',
url: 'mng/api/database/testConnect',
method: 'post',
data
})
Expand Down
16 changes: 8 additions & 8 deletions src/api/mnt/deploy.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,38 +2,38 @@ import request from '@/utils/request'

export function add(data) {
return request({
url: 'api/deploy',
url: 'mng/api/deploy',
method: 'post',
data
})
}

export function del(ids) {
return request({
url: 'api/deploy',
url: 'mng/api/deploy',
method: 'delete',
data: ids
})
}

export function edit(data) {
return request({
url: 'api/deploy',
url: 'mng/api/deploy',
method: 'put',
data
})
}

export function getApps() {
return request({
url: 'api/app',
url: 'mng/api/app',
method: 'get'
})
}

export function getServers() {
return request({
url: 'api/serverDeploy',
url: 'mng/api/serverDeploy',
method: 'get'
})
}
Expand All @@ -44,7 +44,7 @@ export function getServers() {
*/
export function startServer(data) {
return request({
url: 'api/deploy/startServer',
url: 'mng/api/deploy/startServer',
method: 'post',
data
})
Expand All @@ -56,7 +56,7 @@ export function startServer(data) {
*/
export function stopServer(data) {
return request({
url: 'api/deploy/stopServer',
url: 'mng/api/deploy/stopServer',
method: 'post',
data
})
Expand All @@ -68,7 +68,7 @@ export function stopServer(data) {
*/
export function serverStatus(data) {
return request({
url: 'api/deploy/serverStatus',
url: 'mng/api/deploy/serverStatus',
method: 'post',
data
})
Expand Down
4 changes: 2 additions & 2 deletions src/api/mnt/deployHistory.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import request from '@/utils/request'

export function del(ids) {
return request({
url: 'api/deployHistory',
url: 'mng/api/deployHistory',
method: 'delete',
data: ids
})
Expand All @@ -14,7 +14,7 @@ export function del(ids) {
*/
export function reducte(data) {
return request({
url: 'api/deploy/serverReduction',
url: 'mng/api/deploy/serverReduction',
method: 'post',
data
})
Expand Down
6 changes: 3 additions & 3 deletions src/api/mnt/serverDeploy.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,23 @@ import request from '@/utils/request'

export function add(data) {
return request({
url: 'api/serverDeploy',
url: 'mng/api/serverDeploy',
method: 'post',
data
})
}

export function del(ids) {
return request({
url: 'api/serverDeploy',
url: 'mng/api/serverDeploy',
method: 'delete',
data: ids
})
}

export function edit(data) {
return request({
url: 'api/serverDeploy',
url: 'mng/api/serverDeploy',
method: 'put',
data
})
Expand Down
6 changes: 3 additions & 3 deletions src/api/monitor/log.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@ import request from '@/utils/request'

export function getErrDetail(id) {
return request({
url: 'api/logs/error/' + id,
url: 'system/api/logs/error/' + id,
method: 'get'
})
}

export function delAllError() {
return request({
url: 'api/logs/del/error',
url: 'system/api/logs/del/error',
method: 'delete'
})
}

export function delAllInfo() {
return request({
url: 'api/logs/del/info',
url: 'system/api/logs/del/info',
method: 'delete'
})
}
2 changes: 1 addition & 1 deletion src/api/monitor/online.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import request from '@/utils/request'

export function del(keys) {
return request({
url: 'auth/online',
url: 'system/auth/online',
method: 'delete',
data: keys
})
Expand Down
4 changes: 2 additions & 2 deletions src/api/system/code.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ import request from '@/utils/request'

export function resetEmail(data) {
return request({
url: 'api/code/resetEmail?email=' + data,
url: 'system/api/code/resetEmail?email=' + data,
method: 'post'
})
}

export function updatePass(pass) {
return request({
url: 'api/users/updatePass/' + pass,
url: 'system/api/users/updatePass/' + pass,
method: 'get'
})
}
10 changes: 5 additions & 5 deletions src/api/system/dept.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import request from '@/utils/request'

export function getDepts(params) {
return request({
url: 'api/dept',
url: 'system/api/dept',
method: 'get',
params
})
Expand All @@ -12,31 +12,31 @@ export function getDeptSuperior(ids, exclude) {
exclude = exclude !== undefined ? exclude : false
const data = ids.length || ids.length === 0 ? ids : Array.of(ids)
return request({
url: 'api/dept/superior?exclude=' + exclude,
url: 'system/api/dept/superior?exclude=' + exclude,
method: 'post',
data
})
}

export function add(data) {
return request({
url: 'api/dept',
url: 'system/api/dept',
method: 'post',
data
})
}

export function del(ids) {
return request({
url: 'api/dept',
url: 'system/api/dept',
method: 'delete',
data: ids
})
}

export function edit(data) {
return request({
url: 'api/dept',
url: 'system/api/dept',
method: 'put',
data
})
Expand Down
Loading