Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
T
topsun-baoshen-excel
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
何远江
topsun-baoshen-excel
Commits
6a0d260d
Commit
6a0d260d
authored
Apr 10, 2025
by
tanghao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
123
parent
39820aea
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
195 additions
and
2 deletions
+195
-2
customer.ts
src/api/customer.ts
+13
-0
index.ts
src/router/index.ts
+22
-2
Information.vue
src/views/information/Information.vue
+85
-0
InformationList.vue
src/views/information/InformationList.vue
+75
-0
No files found.
src/api/customer.ts
View file @
6a0d260d
...
...
@@ -69,3 +69,16 @@ export const getUserList = (params: any) => {
headers
:
formHeader
})
}
/**
* 获取客户资料列表
* @param params
* @returns
*/
export
const
getInformationList
=
(
params
:
any
)
=>
{
return
axios
.
get
(
'/api/information/typePage'
,
{
params
,
headers
:
formHeader
})
}
\ No newline at end of file
src/router/index.ts
View file @
6a0d260d
...
...
@@ -175,7 +175,24 @@ export const routes = [
meta
:
{
title
:
'产品对照'
}
}
},
// 客户资料管理相关菜单
{
path
:
'/customer-excel'
,
name
:
'CustomerExcel'
,
meta
:
{
title
:
'资料库'
},
component
:
()
=>
import
(
'@/views/information/Information.vue'
)
},
{
path
:
'/customer-excel-list'
,
name
:
'CustomerExcelList'
,
meta
:
{
title
:
'客户资料'
},
component
:
()
=>
import
(
'@/views/information/InformationList.vue'
)
},
]
},
{
...
...
@@ -229,7 +246,10 @@ export const routes = [
title
:
'预览'
},
component
:
()
=>
import
(
'@/views/order/preview/index.vue'
)
}
},
]
const
router
=
createRouter
({
...
...
src/views/information/Information.vue
0 → 100644
View file @
6a0d260d
<
template
>
<div
class=
"h-full flex flex-col bg-white p-2"
>
<p
class=
"font-bold text-lg leading-10 border-b-2"
>
资料库
</p>
<el-form
class=
"pt-2"
:model=
"formState"
inline
>
<el-form-item
label=
"资料名称"
>
<el-input
v-model=
"formState.customerName"
></el-input>
</el-form-item>
<el-form-item>
<el-button
@
click=
""
>
重置
</el-button>
<el-button
@
click=
""
type=
"primary"
>
查询
</el-button>
</el-form-item>
</el-form>
<el-space
wrap
>
<el-card
v-for=
"informationType in informationTypes"
:key=
"informationType"
class=
"box-card"
@
click=
"handleInfoTypeClick(informationType)"
>
<div
class=
"text item"
>
{{
informationType
}}
</div>
</el-card>
</el-space>
</div>
</
template
>
<
script
lang=
"ts"
setup
>
import
{
defineComponent
,
ref
,
onMounted
,
reactive
,
watch
,
unref
}
from
'vue'
import
{
getInformationList
}
from
'@/api/customer'
import
type
{
VxeTableInstance
}
from
'vxe-table'
import
{
useRouter
}
from
'vue-router'
const
loading
=
ref
(
false
)
const
router
=
useRouter
()
const
xTable
=
ref
<
VxeTableInstance
>
()
const
tableData
=
ref
([])
const
informationTypes
=
ref
([])
const
queryParam
=
reactive
({
type
:
""
})
const
formState
=
reactive
({
customerName
:
''
,
customerNickName
:
''
,
currentPage
:
1
,
pageSize
:
10
,
total
:
0
})
const
mode
=
ref
(
''
)
const
fileUpload
=
(
info
:
any
)
=>
{
mode
.
value
=
'edit'
}
const
queryCustomer
=
async
()
=>
{
loading
.
value
=
true
try
{
// 模糊查询
const
{
data
}
=
await
getInformationList
(
unref
(
formState
))
informationTypes
.
value
=
data
.
result
console
.
log
(
informationTypes
)
formState
.
total
=
+
data
.
result
.
total
}
catch
{}
loading
.
value
=
false
}
const
handleInfoTypeClick
=
(
informationType
:
any
)
=>
{
alert
(
informationType
)
}
onMounted
(()
=>
{
queryCustomer
()
})
</
script
>
<
style
lang=
"scss"
scoped
>
</
style
>
\ No newline at end of file
src/views/information/InformationList.vue
0 → 100644
View file @
6a0d260d
<
template
>
<div
class=
"h-full flex flex-col bg-white p-2"
>
<p
class=
"font-bold text-lg leading-10 border-b-2"
>
客户资料
</p>
<el-form
class=
"pt-2"
:model=
"formState"
inline
>
<el-form-item
label=
"资料名称"
>
<el-input
v-model=
"formState.customerName"
></el-input>
</el-form-item>
<el-form-item>
<el-button
@
click=
""
>
重置
</el-button>
<el-button
@
click=
""
type=
"primary"
>
查询
</el-button>
</el-form-item>
</el-form>
<el-space
wrap
>
<el-card
v-for=
"informationType in informationTypes"
:key=
"informationType"
class=
"box-card"
@
click=
"handleInfoTypeClick(informationType)"
>
<div
class=
"text item"
>
{{
informationType
}}
</div>
</el-card>
</el-space>
</div>
</
template
>
<
script
lang=
"ts"
setup
>
import
{
defineComponent
,
ref
,
onMounted
,
reactive
,
watch
,
unref
}
from
'vue'
import
{
getInformationList
}
from
'@/api/customer'
import
type
{
VxeTableInstance
}
from
'vxe-table'
import
{
useRouter
}
from
'vue-router'
const
loading
=
ref
(
false
)
const
router
=
useRouter
()
const
xTable
=
ref
<
VxeTableInstance
>
()
const
tableData
=
ref
([])
const
informationTypes
=
ref
([])
const
queryParam
=
reactive
({
type
:
""
})
const
formState
=
reactive
({
customerName
:
''
,
customerNickName
:
''
,
currentPage
:
1
,
pageSize
:
10
,
total
:
0
})
const
queryInfomartionList
=
async
()
=>
{
loading
.
value
=
true
try
{
// 模糊查询
const
{
data
}
=
await
getInformationList
(
unref
(
formState
))
informationTypes
.
value
=
data
.
result
console
.
log
(
informationTypes
)
formState
.
total
=
+
data
.
result
.
total
}
catch
{}
loading
.
value
=
false
}
const
handleInfoTypeClick
=
(
informationType
:
any
)
=>
{
alert
(
informationType
)
}
onMounted
(()
=>
{
queryInfomartionList
()
})
</
script
>
<
style
lang=
"scss"
scoped
>
</
style
>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment