diff --git a/package.json b/package.json index c5d6ee8f..96cd7454 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "go-admin", - "version": "2.0.0-beta.5", + "version": "2.0.0-beta.6", "description": "A magical vue admin. An out-of-box UI solution for enterprise applications. Newest development stack of vue. Lots of awesome features", "author": "https://github.com/wenjianzhang", "license": "MIT", diff --git a/src/api/admin/dict/data.js b/src/api/admin/dict/data.js index ce52b7ee..f8b09b71 100644 --- a/src/api/admin/dict/data.js +++ b/src/api/admin/dict/data.js @@ -46,8 +46,9 @@ export function updateData(data) { // 删除字典数据 export function delData(dictCode) { return request({ - url: '/api/v1/dict/data/' + dictCode, - method: 'delete' + url: '/api/v1/dict/data', + method: 'delete', + data: dictCode }) } diff --git a/src/api/admin/sys-post.js b/src/api/admin/sys-post.js index 9ee78b9f..eaca6d90 100644 --- a/src/api/admin/sys-post.js +++ b/src/api/admin/sys-post.js @@ -38,8 +38,9 @@ export function updatePost(data, id) { // 删除岗位 export function delPost(postId) { return request({ - url: '/api/v1/post/' + postId, - method: 'delete' + url: '/api/v1/post', + method: 'delete', + data: postId }) } diff --git a/src/api/cms/sys-category.js b/src/api/cms/sys-category.js deleted file mode 100644 index b889e619..00000000 --- a/src/api/cms/sys-category.js +++ /dev/null @@ -1,46 +0,0 @@ -import request from '@/utils/request' - -// 查询SysCategory列表 -export function listSysCategory(query) { - return request({ - url: '/api/v1/syscategory', - method: 'get', - params: query - }) -} - -// 查询SysCategory详细 -export function getSysCategory(ID) { - return request({ - url: '/api/v1/syscategory/' + ID, - method: 'get' - }) -} - -// 新增SysCategory -export function addSysCategory(data) { - return request({ - url: '/api/v1/syscategory', - method: 'post', - data: data - }) -} - -// 修改SysCategory -export function updateSysCategory(data) { - return request({ - url: '/api/v1/syscategory/' + data.id, - method: 'put', - data: data - }) -} - -// 删除SysCategory -export function delSysCategory(data) { - return request({ - url: '/api/v1/syscategory', - method: 'delete', - data: data - }) -} - diff --git a/src/api/cms/sys-content.js b/src/api/cms/sys-content.js deleted file mode 100644 index abd8a651..00000000 --- a/src/api/cms/sys-content.js +++ /dev/null @@ -1,46 +0,0 @@ -import request from '@/utils/request' - -// 查询SysContent列表 -export function listSysContent(query) { - return request({ - url: '/api/v1/syscontent', - method: 'get', - params: query - }) -} - -// 查询SysContent详细 -export function getSysContent(id) { - return request({ - url: '/api/v1/syscontent/' + id, - method: 'get' - }) -} - -// 新增SysContent -export function addSysContent(data) { - return request({ - url: '/api/v1/syscontent', - method: 'post', - data: data - }) -} - -// 修改SysContent -export function updateSysContent(data) { - return request({ - url: '/api/v1/syscontent/' + data.id, - method: 'put', - data: data - }) -} - -// 删除SysContent -export function delSysContent(data) { - return request({ - url: '/api/v1/syscontent', - method: 'delete', - data: data - }) -} - diff --git a/src/api/file.js b/src/api/file.js deleted file mode 100644 index f11bd5e9..00000000 --- a/src/api/file.js +++ /dev/null @@ -1,54 +0,0 @@ -import request from '@/utils/request' -import { data } from 'autoprefixer' - -export const sysfiledirList = data => request({ - url: '/api/v1/file-dir', - method: 'GET', - data -}) - -export const sysfiledirAcionAdd = data => request({ - url: '/api/v1/file-dir', - method: 'POST', - data -}) - -export const sysfiledirAcionEdit = data => request({ - url: '/api/v1/file-dir/' + data.id, - method: 'PUT', - data -}) - -export const sysfiledirAcionDel = data => request({ - url: '/api/v1/file-dir/' + data, - method: 'DELETE' -}) - -export const sysfileinfoList = data => request({ - url: `/api/v1/file-info?pId=${data.pId}&pageSize=${data.pageSize}&pageIndex=${data.pageIndex}`, - method: 'GET', - data -}) - -export const sysfileinfo = id => request({ - url: '/api/v1/file-info/' + id, - method: 'GET' -}) - -export const sysfileinfoAdd = data => request({ - url: '/api/v1/file-info', - method: 'POST', - data -}) - -export const sysfileinfoEdit = data => request({ - url: '/api/v1/file-info/' + data.id, - method: 'put', - data -}) - -export const sysfileinfoDelete = id => request({ - url: '/api/v1/file-info/' + id, - method: 'DELETE', - data -}) diff --git a/src/api/syschinaareadata.js b/src/api/syschinaareadata.js deleted file mode 100644 index 32e16534..00000000 --- a/src/api/syschinaareadata.js +++ /dev/null @@ -1,46 +0,0 @@ -import request from '@/utils/request' - -// 查询SysChinaAreaData列表 -export function listSysChinaAreaData(query) { - return request({ - url: '/api/v1/sys-area-data', - method: 'get', - params: query - }) -} - -// 查询SysChinaAreaData详细 -export function getSysChinaAreaData(id) { - return request({ - url: '/api/v1/sys-area-data/' + id, - method: 'get' - }) -} - -// 新增SysChinaAreaData -export function addSysChinaAreaData(data) { - return request({ - url: '/api/v1/sys-area-data', - method: 'post', - data: data - }) -} - -// 修改SysChinaAreaData -export function updateSysChinaAreaData(data) { - return request({ - url: '/api/v1/sys-area-data/' + data.id, - method: 'put', - data: data - }) -} - -// 删除SysChinaAreaData -export function delSysChinaAreaData(data) { - return request({ - url: '/api/v1/sys-area-data', - method: 'delete', - data: data - }) -} - diff --git a/src/components/FileChoose/index.vue b/src/components/FileChoose/index.vue deleted file mode 100644 index 89d71501..00000000 --- a/src/components/FileChoose/index.vue +++ /dev/null @@ -1,403 +0,0 @@ - - - - - 系统资源选择器(已选择:{{ resultList.length }}个) - - - - - - - 取 消 - 确 定 - - - - - - - - diff --git a/src/components/FileManage/Left.vue b/src/components/FileManage/Left.vue deleted file mode 100644 index 5060e624..00000000 --- a/src/components/FileManage/Left.vue +++ /dev/null @@ -1,350 +0,0 @@ - - - - - - - - - - - - - - - {{ node.label }} - - - - - - - - - - - {{ item.label }} - - - - - - - - - - - diff --git a/src/components/FileManage/Right.vue b/src/components/FileManage/Right.vue deleted file mode 100644 index 3fe5b3b1..00000000 --- a/src/components/FileManage/Right.vue +++ /dev/null @@ -1,660 +0,0 @@ - - - - - - - - {{ item.label }} - - - - - - - - - - - - - - - - - - - - - - - - {{ item.name }} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 操作 - - - 上传 - 重命名 - 删除 - 下载 - - - - - - - - - - - - - - - 上传 - - - - - 重命名 - - - - - 删除 - - - - - 下载 - - - - - - - - - diff --git a/src/components/UploadDialog/form.vue b/src/components/UploadDialog/form.vue deleted file mode 100644 index 04a014e6..00000000 --- a/src/components/UploadDialog/form.vue +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - 本地 - 阿里云OSS - - - - - - - - - 将文件拖到此处,或点击上传 - - - - - - - - - - - - - diff --git a/src/components/UploadDialog/index.vue b/src/components/UploadDialog/index.vue deleted file mode 100644 index 4d6dbc1a..00000000 --- a/src/components/UploadDialog/index.vue +++ /dev/null @@ -1,53 +0,0 @@ - - - - - - - - - - - diff --git a/src/views/admin/dict/data.vue b/src/views/admin/dict/data.vue index 3976cc8f..c236ce92 100644 --- a/src/views/admin/dict/data.vue +++ b/src/views/admin/dict/data.vue @@ -252,7 +252,7 @@ export default { dictLabel: undefined, dictValue: undefined, dictSort: 0, - status: '0', + status: '2', remark: undefined } this.resetForm('form') @@ -288,6 +288,7 @@ export default { const dictCode = row.dictCode || this.ids getData(dictCode).then(response => { this.form = response.data + this.form.status = String(this.form.status) this.open = true this.title = '修改字典数据' this.isEdit = true @@ -297,6 +298,7 @@ export default { submitForm: function() { this.$refs['form'].validate(valid => { if (valid) { + this.form.status = parseInt(this.form.status) if (this.form.dictCode !== undefined) { updateData(this.form).then(response => { if (response.code === 200) { @@ -329,7 +331,7 @@ export default { cancelButtonText: '取消', type: 'warning' }).then(function() { - return delData(dictCodes) + return delData({ 'ids': dictCodes }) }).then((response) => { if (response.code === 200) { this.msgSuccess(response.msg) diff --git a/src/views/admin/dict/index.vue b/src/views/admin/dict/index.vue index 46b9ffb3..560a28e6 100644 --- a/src/views/admin/dict/index.vue +++ b/src/views/admin/dict/index.vue @@ -246,7 +246,7 @@ export default { id: undefined, dictName: undefined, dictType: undefined, - status: '0', + status: '2', remark: undefined } this.resetForm('form') @@ -281,6 +281,7 @@ export default { const dictId = row.id || this.ids getType(dictId).then(response => { this.form = response.data + this.form.status = String(this.form.status) this.open = true this.title = '修改字典类型' this.isEdit = true @@ -290,6 +291,7 @@ export default { submitForm: function() { this.$refs['form'].validate(valid => { if (valid) { + this.form.status = parseInt(this.form.status) if (this.form.id !== undefined) { updateType(this.form).then(response => { if (response.code === 200) { @@ -322,7 +324,7 @@ export default { cancelButtonText: '取消', type: 'warning' }).then(function() { - return delType(dictIds) + return delType({ 'ids': dictIds }) }).then(() => { this.getList() this.msgSuccess('删除成功') diff --git a/src/views/admin/sys-config/index.vue b/src/views/admin/sys-config/index.vue index 28827eaa..0a3981e3 100644 --- a/src/views/admin/sys-config/index.vue +++ b/src/views/admin/sys-config/index.vue @@ -197,7 +197,7 @@ >{{ dict.dictLabel }} - + @@ -302,7 +302,7 @@ export default { configKey: undefined, configValue: undefined, configType: 'Y', - isFrontend: 1, + isFrontend: '1', remark: undefined } this.resetForm('form') diff --git a/src/views/admin/sys-dept/index.vue b/src/views/admin/sys-dept/index.vue index fed1e060..185c2eaf 100644 --- a/src/views/admin/sys-dept/index.vue +++ b/src/views/admin/sys-dept/index.vue @@ -54,7 +54,7 @@ {{ statusFormat(scope.row) }} @@ -185,7 +185,8 @@ export default { status: undefined }, // 表单参数 - form: {}, + form: { + }, // 表单校验 rules: { parentId: [ @@ -271,11 +272,11 @@ export default { deptId: undefined, parentId: undefined, deptName: undefined, - sorc: undefined, + sort: 10, leader: undefined, phone: undefined, email: undefined, - status: '0' + status: '2' } }, /** 搜索按钮操作 */ @@ -300,6 +301,8 @@ export default { getDept(row.deptId).then(response => { this.form = response.data + this.form.status = String(this.form.status) + this.form.sort = String(this.form.sort) this.open = true this.title = '修改部门' this.isEdit = true @@ -309,6 +312,8 @@ export default { submitForm: function() { this.$refs['form'].validate(valid => { if (valid) { + this.form.status = parseInt(this.form.status) + this.form.sort = parseInt(this.form.sort) if (this.form.deptId !== undefined) { updateDept(this.form, this.form.deptId).then(response => { if (response.code === 200) { diff --git a/src/views/admin/sys-post/index.vue b/src/views/admin/sys-post/index.vue index 8addb18e..d2064c08 100644 --- a/src/views/admin/sys-post/index.vue +++ b/src/views/admin/sys-post/index.vue @@ -87,7 +87,7 @@ {{ statusFormat(scope.row) }} @@ -242,7 +242,7 @@ export default { postCode: undefined, postName: undefined, sort: 0, - status: '0', + status: '1', remark: undefined } this.resetForm('form') @@ -276,6 +276,7 @@ export default { const postId = row.postId || this.ids getPost(postId).then(response => { this.form = response.data + this.form.status = String(this.form.status) this.open = true this.title = '修改岗位' }) @@ -284,6 +285,7 @@ export default { submitForm: function() { this.$refs['form'].validate(valid => { if (valid) { + this.form.status = parseInt(this.form.status) if (this.form.postId !== undefined) { updatePost(this.form, this.form.postId).then(response => { if (response.code === 200) { @@ -310,13 +312,14 @@ export default { }, /** 删除按钮操作 */ handleDelete(row) { - const postIds = row.postId || this.ids - this.$confirm('是否确认删除岗位编号为"' + postIds + '"的数据项?', '警告', { + // const postIds = row.postId || this.ids + const Ids = (row.postId && [row.postId]) || this.ids + this.$confirm('是否确认删除岗位编号为"' + Ids + '"的数据项?', '警告', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' }).then(function() { - return delPost(postIds) + return delPost({ 'ids': Ids }) }).then((response) => { if (response.code === 200) { this.msgSuccess(response.msg) diff --git a/src/views/cms/sys-category/index.vue b/src/views/cms/sys-category/index.vue deleted file mode 100644 index 8b77f160..00000000 --- a/src/views/cms/sys-category/index.vue +++ /dev/null @@ -1,370 +0,0 @@ - - - - - - - - - - - - - - - - 搜索 - 重置 - - - - - - 新增 - - - - 修改 - - - - 删除 - - - - - - - - {{ statusFormat(scope.row) }} - - - - - {{ parseTime(scope.row.createdAt) }} - - - - - 修改 - - 删除 - - - - - - - - - - - - - - - - - - - - - - - {{ dict.dictLabel }} - - - - - - - - - - - - - - - diff --git a/src/views/cms/sys-content/components/ArticleDetail.vue b/src/views/cms/sys-content/components/ArticleDetail.vue deleted file mode 100644 index f65779f7..00000000 --- a/src/views/cms/sys-content/components/ArticleDetail.vue +++ /dev/null @@ -1,277 +0,0 @@ - - - - - - - - - - Publish - - - Draft - - - - - - - - - - - Title - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {{ contentShortLength }}words - - - - - - - - - - - - - - - - - diff --git a/src/views/cms/sys-content/components/Dropdown/Comment.vue b/src/views/cms/sys-content/components/Dropdown/Comment.vue deleted file mode 100644 index d34b2b90..00000000 --- a/src/views/cms/sys-content/components/Dropdown/Comment.vue +++ /dev/null @@ -1,41 +0,0 @@ - - - - {{ !comment_disabled?'Comment: opened':'Comment: closed' }} - - - - - - - Close comment - - - Open comment - - - - - - - - diff --git a/src/views/cms/sys-content/components/Dropdown/Platform.vue b/src/views/cms/sys-content/components/Dropdown/Platform.vue deleted file mode 100644 index 0a527264..00000000 --- a/src/views/cms/sys-content/components/Dropdown/Platform.vue +++ /dev/null @@ -1,46 +0,0 @@ - - - - Platfroms({{ platforms.length }}) - - - - - - {{ item.name }} - - - - - - - diff --git a/src/views/cms/sys-content/components/Dropdown/SourceUrl.vue b/src/views/cms/sys-content/components/Dropdown/SourceUrl.vue deleted file mode 100644 index 8f47485a..00000000 --- a/src/views/cms/sys-content/components/Dropdown/SourceUrl.vue +++ /dev/null @@ -1,38 +0,0 @@ - - - - Link - - - - - - - URL - - - - - - - - diff --git a/src/views/cms/sys-content/components/Dropdown/index.js b/src/views/cms/sys-content/components/Dropdown/index.js deleted file mode 100644 index bc0c171b..00000000 --- a/src/views/cms/sys-content/components/Dropdown/index.js +++ /dev/null @@ -1,3 +0,0 @@ -export { default as CommentDropdown } from './Comment' -export { default as PlatformDropdown } from './Platform' -export { default as SourceUrlDropdown } from './SourceUrl' diff --git a/src/views/cms/sys-content/components/Warning.vue b/src/views/cms/sys-content/components/Warning.vue deleted file mode 100644 index 41b9b031..00000000 --- a/src/views/cms/sys-content/components/Warning.vue +++ /dev/null @@ -1,12 +0,0 @@ - - - diff --git a/src/views/cms/sys-content/create.vue b/src/views/cms/sys-content/create.vue deleted file mode 100644 index 4ebc1ede..00000000 --- a/src/views/cms/sys-content/create.vue +++ /dev/null @@ -1,141 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 提交 - - - 取消 - - - - - - - - - diff --git a/src/views/cms/sys-content/edit.vue b/src/views/cms/sys-content/edit.vue deleted file mode 100644 index 5a04bc06..00000000 --- a/src/views/cms/sys-content/edit.vue +++ /dev/null @@ -1,142 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 保 存 - - - 取 消 - - - - - - - - - diff --git a/src/views/cms/sys-content/index.vue b/src/views/cms/sys-content/index.vue deleted file mode 100644 index b1dc722f..00000000 --- a/src/views/cms/sys-content/index.vue +++ /dev/null @@ -1,270 +0,0 @@ - - - - - - - - - - - - - - - - - - 搜索 - 重置 - - - - - - 新增 - - - - 修改 - - - - 删除 - - - - - - - - - {{ cateIdFormat(scope.row) }} - - - - - {{ statusFormat(scope.row) }} - - - - - 修改 - - 删除 - - - - - - - - - - - - - diff --git a/src/views/other/fileManage/index.vue b/src/views/other/fileManage/index.vue deleted file mode 100644 index 39cb62b2..00000000 --- a/src/views/other/fileManage/index.vue +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - - - - - - - - - - - - - - diff --git a/src/views/sys-tools/sys-china-area-data/index.vue b/src/views/sys-tools/sys-china-area-data/index.vue deleted file mode 100644 index 4dc1babb..00000000 --- a/src/views/sys-tools/sys-china-area-data/index.vue +++ /dev/null @@ -1,336 +0,0 @@ - - - - - - - - - - - - - - 搜索 - 重置 - - - - - - 新增 - - - - 修改 - - - - 删除 - - - - - - - - - - 修改 - - 删除 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -