diff --git a/src/apis/modules/area.js b/src/apis/modules/area.js
index b8e570c..9247dd2 100644
--- a/src/apis/modules/area.js
+++ b/src/apis/modules/area.js
@@ -3,12 +3,12 @@
*/
import request from '@/utils/request'
// 获取项目列表
-export const getProjectList = (params) => request.basic.get('/api/v1/companies', params)
-// 获取role条数据
-export const getRole = (id) => request.basic.get(`/api/v1/roles/${id}`)
+export const getProjectList = (params) => request.basic.get('/api/v1/areas', params)
+// 获取单挑数据
+export const getItem = (id) => request.basic.get(`/api/v1/areas/${id}`)
// 添加条目
-export const createProject = (params) => request.basic.post('/api/v1/companies', params)
+export const createProject = (params) => request.basic.post('/api/v1/areas', params)
// 更新role
-export const updateRole = (id, params) => request.basic.put(`/api/v1/roles/${id}`, params)
-// 删除role
-export const delRole = (id) => request.basic.delete(`/api/v1/roles/${id}`)
+export const updateItem = (id, params) => request.basic.put(`/api/v1/areas/${id}`, params)
+// 删除数据
+export const delItem = (id) => request.basic.delete(`/api/v1/areas/${id}`)
diff --git a/src/apis/modules/customer.js b/src/apis/modules/customer.js
new file mode 100644
index 0000000..71c1392
--- /dev/null
+++ b/src/apis/modules/customer.js
@@ -0,0 +1,14 @@
+/**
+ * 区域模块接口
+ */
+import request from '@/utils/request'
+// 获取项目列表
+export const getProjectList = (params) => request.basic.get('/api/v1/customers', params)
+// 获取单挑数据
+export const getItem = (id) => request.basic.get(`/api/v1/customers/${id}`)
+// 添加条目
+export const createProject = (params) => request.basic.post('/api/v1/customers', params)
+// 更新role
+export const updateItem = (id, params) => request.basic.put(`/api/v1/customers/${id}`, params)
+// 删除数据
+export const delItem = (id) => request.basic.delete(`/api/v1/customers/${id}`)
diff --git a/src/apis/modules/project.js b/src/apis/modules/project.js
new file mode 100644
index 0000000..c3df609
--- /dev/null
+++ b/src/apis/modules/project.js
@@ -0,0 +1,14 @@
+/**
+ * 区域模块接口
+ */
+import request from '@/utils/request'
+// 获取项目列表
+export const getProjectList = (params) => request.basic.get('/api/v1/companies', params)
+// 获取单挑数据
+export const getItem = (id) => request.basic.get(`/api/v1/companies/${id}`)
+// 添加条目
+export const createProject = (params) => request.basic.post('/api/v1/companies', params)
+// 更新role
+export const updateItem = (id, params) => request.basic.put(`/api/v1/companies/${id}`, params)
+// 删除数据
+export const delItem = (id) => request.basic.delete(`/api/v1/companies/${id}`)
diff --git a/src/components/GxUpload/index.vue b/src/components/GxUpload/index.vue
index a2424e2..747845a 100644
--- a/src/components/GxUpload/index.vue
+++ b/src/components/GxUpload/index.vue
@@ -14,7 +14,7 @@
diff --git a/src/views/regional/houseList/components/EditDepartmentDialog.vue b/src/views/regional/houseList/components/EditDepartmentDialog.vue
deleted file mode 100644
index e5a271f..0000000
--- a/src/views/regional/houseList/components/EditDepartmentDialog.vue
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/regional/houseList/components/EditDialog.vue b/src/views/regional/houseList/components/EditDialog.vue
index 3f3aa09..e5480ac 100644
--- a/src/views/regional/houseList/components/EditDialog.vue
+++ b/src/views/regional/houseList/components/EditDialog.vue
@@ -1,274 +1,186 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 南通
+ 盐城
+
+
+
+
+
+
+
updateLabel(index, e.target.value)">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/regional/projectList/components/EditDialog.vue b/src/views/regional/projectList/components/EditDialog.vue
index c74df84..240abf2 100644
--- a/src/views/regional/projectList/components/EditDialog.vue
+++ b/src/views/regional/projectList/components/EditDialog.vue
@@ -20,7 +20,8 @@
-
+
@@ -50,10 +51,11 @@ const cancelText = ref(t('button.cancel'))
const okText = ref(t('button.confirm'))
const rolesValue = ref([])
const roles = ref([])
-const imgUrl = ref('')
+const ceshi = ref('1222')
+
const areaList = ref([])
const childOpen = ref(false)
-const fileList=ref([])
+const fileList = ref([])
const formArea = ref({ name: '', status: 'enabled' })
formRules.value = {
title: { required: true, message: '请输入项目名称' },
@@ -64,23 +66,7 @@ const areaFormRules = {
status: [{ required: true, message: '请选择状态', trigger: 'change' }],
// fileList: [{ required: true, message: '请选择状态', trigger: 'change' }],
}
-const initData = async () => {
- try {
- showSpining()
- const { success, data, total } = await apis.recruitment.getAreasList({ pageSize: 999, page: 1, })
- if (config('http.code.success') === success) {
- hideSpining()
- areaList.value = data.map(item => {
- if (item.status === 'enabled') {
- return { code: item.id, name: item.name }
- }
- })
- }
- } catch (error) {
- message.error({ content: error.message })
- hideSpining()
- }
-}
+
/**
* 新建
@@ -100,39 +86,51 @@ function handleCreate() {
async function handleEdit(record = {}) {
showModal({
type: 'edit',
- title: t('pages.system.user.edit'),
+ title: '编辑项目',
})
- const { data, success } = await apis.recruitment.getItem(record.id).catch()
- if (!success) {
- hideModal()
- return
+ try {
+ showSpining()
+ const { data, success } = await apis.project.getItem(record.id).catch()
+ if (!success) {
+ hideModal()
+ return
+ }
+ hideSpining()
+ formData.value = { ...data }
+ if(data.img){
+ formData.value.fileList = [config('http.apiBasic')+data.img]
+ }
+ } catch (error) {
+ message.error({ content: error.message })
+ hideSpining()
}
- formData.value = { ...data }
- imgUrl.value = config('http.apiBasic') + data.img
-}
+}
+const uploadSuccess = (data) => {
+ fileList.value.push(data)
+}
/**
* 确定
*/
function handleOk() {
- if(formData.value.fileList.length===0) return message.error('请上传图片')
+ if (fileList.value.length === 0) return message.error('请上传图片')
formRef.value.validateFields().then(async (values) => {
try {
showLoading()
const params = {
- d
+ name: formData.value.name,
+ status: formData.value.status,
+ img: fileList.value[0]
}
let result = null
switch (modal.value.type) {
case 'create':
- result = await apis.area.createProject(params).catch((error) => {
-
-
+ result = await apis.project.createProject(params).catch((error) => {
throw new Error(error)
})
break
case 'edit':
- result = await apis.recruitment.updateItem(formData.value.id, params).catch(() => {
+ result = await apis.project.updateItem(formData.value.id, params).catch(() => {
throw new Error(error)
})
break
@@ -148,7 +146,6 @@ function handleOk() {
}
})
.catch((e) => {
- console.log(e)
hideLoading()
})
}
@@ -158,7 +155,6 @@ function handleOk() {
* 取消
*/
function handleCancel() {
- imgUrl.value = ''
hideModal()
}
diff --git a/src/views/regional/projectList/index.vue b/src/views/regional/projectList/index.vue
index 0082d35..1d441de 100644
--- a/src/views/regional/projectList/index.vue
+++ b/src/views/regional/projectList/index.vue
@@ -1,11 +1,11 @@
-
+
@@ -44,18 +44,10 @@
-
-
-
- {{ record.introduce }}
-
+
+
+
-
-
- {{ record.duty }}
-
-
-
启用
停用
@@ -92,13 +84,13 @@ import EditDialog from './components/EditDialog.vue'
import { PlusOutlined, EditOutlined, DeleteOutlined } from '@ant-design/icons-vue'
import { useI18n } from 'vue-i18n'
defineOptions({
- name: 'homeBanner',
+ name: 'projectList',
})
const { t } = useI18n() // 解构出t方法
const columns = [
- { title: '图片', dataIndex: 'img', width: 120, },
- { title: '项目名称', dataIndex: 'name', key: 'title', width: 150 },
- { title: '状态', dataIndex: 'status', key: 'introduce',width:100},
+ { title: '图片', dataIndex: 'img', width: 120,align:'center'},
+ { title: '项目名称', dataIndex: 'name', key: 'title' },
+ { title: '状态', dataIndex: 'status', key: 'introduce', width: 100,align:'center' },
{ title: t('button.action'), key: 'action', fixed: 'right', width: 100, align: 'center' },
]
@@ -108,14 +100,14 @@ const { listData, loading, showLoading, hideLoading, paginationState, resetPagin
const editDialogRef = ref()
getPageList()
/**
- * 获取用户列表
+ * 获取表格数据
* @returns {Promise}
*/
async function getPageList() {
try {
showLoading()
const { pageSize, current } = paginationState
- const { success, data, total } = await apis.area
+ const { success, data, total } = await apis.project
.getProjectList({
pageSize,
page: current,
@@ -146,7 +138,7 @@ function handleDelete({ id }) {
return new Promise((resolve, reject) => {
; (async () => {
try {
- const { success } = await apis.recruitment.delItem(id).catch(() => {
+ const { success } = await apis.project.delItem(id).catch(() => {
throw new Error()
})
if (config('http.code.success') === success) {
diff --git a/src/views/regional/regionalList/components/Department.vue b/src/views/regional/regionalList/components/Department.vue
deleted file mode 100644
index efaefad..0000000
--- a/src/views/regional/regionalList/components/Department.vue
+++ /dev/null
@@ -1,169 +0,0 @@
-
-
-
-
-
-
-
-
-
- {{ title }}
-
-
-
-
-
-
-
-
- 添加子部门
-
-
- 编辑
-
- 删除
-
-
-
-
-
-
-
-
-
-
-
-
- 新建部门
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/regional/regionalList/components/EditDepartmentDialog.vue b/src/views/regional/regionalList/components/EditDepartmentDialog.vue
deleted file mode 100644
index e5a271f..0000000
--- a/src/views/regional/regionalList/components/EditDepartmentDialog.vue
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/regional/regionalList/components/EditDialog.vue b/src/views/regional/regionalList/components/EditDialog.vue
index 3f3aa09..80d9bf2 100644
--- a/src/views/regional/regionalList/components/EditDialog.vue
+++ b/src/views/regional/regionalList/components/EditDialog.vue
@@ -1,154 +1,59 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
diff --git a/src/views/userManagement/allList/components/Department.vue b/src/views/userManagement/allList/components/Department.vue
deleted file mode 100644
index efaefad..0000000
--- a/src/views/userManagement/allList/components/Department.vue
+++ /dev/null
@@ -1,169 +0,0 @@
-
-
-
-
-
-
-
-
-
- {{ title }}
-
-
-
-
-
-
-
-
- 添加子部门
-
-
- 编辑
-
- 删除
-
-
-
-
-
-
-
-
-
-
-
-
- 新建部门
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/userManagement/allList/components/EditDepartmentDialog.vue b/src/views/userManagement/allList/components/EditDepartmentDialog.vue
deleted file mode 100644
index e5a271f..0000000
--- a/src/views/userManagement/allList/components/EditDepartmentDialog.vue
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/userManagement/allList/components/EditDialog.vue b/src/views/userManagement/allList/components/EditDialog.vue
index 3f3aa09..b2feb6b 100644
--- a/src/views/userManagement/allList/components/EditDialog.vue
+++ b/src/views/userManagement/allList/components/EditDialog.vue
@@ -1,155 +1,111 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
+ {{ item + '级' }}
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
diff --git a/src/views/userManagement/clientList/components/EditDepartmentDialog.vue b/src/views/userManagement/clientList/components/EditDepartmentDialog.vue
deleted file mode 100644
index e5a271f..0000000
--- a/src/views/userManagement/clientList/components/EditDepartmentDialog.vue
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/userManagement/clientList/components/EditDialog.vue b/src/views/userManagement/clientList/components/EditDialog.vue
index 3f3aa09..b2feb6b 100644
--- a/src/views/userManagement/clientList/components/EditDialog.vue
+++ b/src/views/userManagement/clientList/components/EditDialog.vue
@@ -1,155 +1,111 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
+ {{ item + '级' }}
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
diff --git a/src/views/userManagement/intermediaryAgentList/components/EditDepartmentDialog.vue b/src/views/userManagement/intermediaryAgentList/components/EditDepartmentDialog.vue
deleted file mode 100644
index e5a271f..0000000
--- a/src/views/userManagement/intermediaryAgentList/components/EditDepartmentDialog.vue
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/userManagement/intermediaryAgentList/components/EditDialog.vue b/src/views/userManagement/intermediaryAgentList/components/EditDialog.vue
index 3f3aa09..b2feb6b 100644
--- a/src/views/userManagement/intermediaryAgentList/components/EditDialog.vue
+++ b/src/views/userManagement/intermediaryAgentList/components/EditDialog.vue
@@ -1,155 +1,111 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
+ {{ item + '级' }}
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
diff --git a/src/views/userManagement/potentialclientsList/components/EditDepartmentDialog.vue b/src/views/userManagement/potentialclientsList/components/EditDepartmentDialog.vue
deleted file mode 100644
index e5a271f..0000000
--- a/src/views/userManagement/potentialclientsList/components/EditDepartmentDialog.vue
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/userManagement/potentialclientsList/components/EditDialog.vue b/src/views/userManagement/potentialclientsList/components/EditDialog.vue
index 3f3aa09..b2feb6b 100644
--- a/src/views/userManagement/potentialclientsList/components/EditDialog.vue
+++ b/src/views/userManagement/potentialclientsList/components/EditDialog.vue
@@ -1,155 +1,111 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
+ {{ item + '级' }}
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
-
-
diff --git a/src/views/userManagement/tourList/components/EditDepartmentDialog.vue b/src/views/userManagement/tourList/components/EditDepartmentDialog.vue
deleted file mode 100644
index e5a271f..0000000
--- a/src/views/userManagement/tourList/components/EditDepartmentDialog.vue
+++ /dev/null
@@ -1,131 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/views/userManagement/tourList/components/EditDialog.vue b/src/views/userManagement/tourList/components/EditDialog.vue
index 3f3aa09..b2feb6b 100644
--- a/src/views/userManagement/tourList/components/EditDialog.vue
+++ b/src/views/userManagement/tourList/components/EditDialog.vue
@@ -1,155 +1,111 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
+ {{ item + '级' }}
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+ {{
+ item.name }}
+
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+