From 565eefe8e5df565dd46a9431da0ec293e6f1c5f4 Mon Sep 17 00:00:00 2001 From: milo <315045773@qq.com> Date: Sun, 10 Apr 2022 22:03:40 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=A7=E5=93=81=E5=88=97=E8=A1=A8=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/customer.ts | 4 ++++ src/api/customerAdd.ts | 4 ---- src/api/customerEdit.ts | 4 ---- src/api/project.ts | 6 ++++++ src/api/projectAdd.ts | 4 ---- src/api/source.ts | 4 ++++ src/api/sourceAdd.ts | 4 ---- src/api/sourceEdit.ts | 4 ---- src/api/user.ts | 4 ++++ src/views/Customer.vue | 6 +++--- src/views/Project.vue | 31 +++++++++++++++++++++++++++++-- src/views/Source.vue | 6 +++--- 12 files changed, 53 insertions(+), 28 deletions(-) delete mode 100644 src/api/customerAdd.ts delete mode 100644 src/api/customerEdit.ts create mode 100644 src/api/project.ts delete mode 100644 src/api/projectAdd.ts delete mode 100644 src/api/sourceAdd.ts delete mode 100644 src/api/sourceEdit.ts create mode 100644 src/api/user.ts diff --git a/src/api/customer.ts b/src/api/customer.ts index 99d25a5..580d830 100644 --- a/src/api/customer.ts +++ b/src/api/customer.ts @@ -2,3 +2,7 @@ import axios from 'axios' import qs from 'qs' export const customerData = query => axios.post('http://oa-dxtc.test/customer', qs.stringify(query)); + +export const customerAdd = addQuery => axios.post('http://oa-dxtc.test/customer/add', qs.stringify(addQuery)); + +export const customerEdit = editQuery => axios.post('http://oa-dxtc.test/customer/edit', qs.stringify(editQuery)); \ No newline at end of file diff --git a/src/api/customerAdd.ts b/src/api/customerAdd.ts deleted file mode 100644 index 409918f..0000000 --- a/src/api/customerAdd.ts +++ /dev/null @@ -1,4 +0,0 @@ -import axios from 'axios' -import qs from 'qs' - -export const customerAdd = query => axios.post('http://oa-dxtc.test/customer/add', qs.stringify(query)); diff --git a/src/api/customerEdit.ts b/src/api/customerEdit.ts deleted file mode 100644 index efe84c5..0000000 --- a/src/api/customerEdit.ts +++ /dev/null @@ -1,4 +0,0 @@ -import axios from 'axios' -import qs from 'qs' - -export const customerEdit = query => axios.post('http://oa-dxtc.test/customer/edit', qs.stringify(query)); diff --git a/src/api/project.ts b/src/api/project.ts new file mode 100644 index 0000000..eccb022 --- /dev/null +++ b/src/api/project.ts @@ -0,0 +1,6 @@ +import axios from 'axios' +import qs from 'qs' + +export const projectData = query => axios.post('http://oa-dxtc.test/project/index', qs.stringify(query)); + +export const projectAdd = addQuery => axios.post('http://oa-dxtc.test/project/add', qs.stringify(addQuery)); diff --git a/src/api/projectAdd.ts b/src/api/projectAdd.ts deleted file mode 100644 index 0aba5ed..0000000 --- a/src/api/projectAdd.ts +++ /dev/null @@ -1,4 +0,0 @@ -import axios from 'axios' -import qs from 'qs' - -export const projectAdd = query => axios.post('http://oa-dxtc.test/project/add', qs.stringify(query)); diff --git a/src/api/source.ts b/src/api/source.ts index bba9012..48545c8 100644 --- a/src/api/source.ts +++ b/src/api/source.ts @@ -2,3 +2,7 @@ import axios from 'axios' import qs from 'qs' export const sourceData = query => axios.post('http://oa-dxtc.test/source/index', qs.stringify(query)); + +export const sourceAdd = addQuery => axios.post('http://oa-dxtc.test/source/add', qs.stringify(addQuery)); + +export const sourceEdit = editQuery => axios.post('http://oa-dxtc.test/source/edit', qs.stringify(editQuery)); \ No newline at end of file diff --git a/src/api/sourceAdd.ts b/src/api/sourceAdd.ts deleted file mode 100644 index 7571a5e..0000000 --- a/src/api/sourceAdd.ts +++ /dev/null @@ -1,4 +0,0 @@ -import axios from 'axios' -import qs from 'qs' - -export const sourceAdd = query => axios.post('http://oa-dxtc.test/source/add', qs.stringify(query)); diff --git a/src/api/sourceEdit.ts b/src/api/sourceEdit.ts deleted file mode 100644 index bc19216..0000000 --- a/src/api/sourceEdit.ts +++ /dev/null @@ -1,4 +0,0 @@ -import axios from 'axios' -import qs from 'qs' - -export const sourceEdit = query => axios.post('http://oa-dxtc.test/source/edit', qs.stringify(query)); diff --git a/src/api/user.ts b/src/api/user.ts new file mode 100644 index 0000000..c9105d2 --- /dev/null +++ b/src/api/user.ts @@ -0,0 +1,4 @@ +import axios from 'axios' +import qs from 'qs' + +export const userData = query => axios.post('http://oa-dxtc.test/user/index', qs.stringify(query)); diff --git a/src/views/Customer.vue b/src/views/Customer.vue index 322d6a6..3ec0ce5 100644 --- a/src/views/Customer.vue +++ b/src/views/Customer.vue @@ -121,9 +121,9 @@