Skip to content

Commit

Permalink
feat: ✨ ykc 图标联调
Browse files Browse the repository at this point in the history
  • Loading branch information
dizuncainiao committed Apr 28, 2024
1 parent 28ca8e5 commit 3d3930b
Show file tree
Hide file tree
Showing 6 changed files with 45 additions and 42 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@ defineOptions({
</div>
<br />
<br />
<CrmConversionRateAnalysisDemo />
<!-- <CrmConversionRateAnalysisDemo />-->
</template>
13 changes: 9 additions & 4 deletions examples/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,22 +12,27 @@ export default defineConfig(({ command, mode }) => {
server: {
proxy: {
'/bdcloud-call-analytic': {
target: 'https://demo.bdsaas.cn/',
target: 'https://im.bdsaas.cn/',
changeOrigin: true,
secure: true
},
'/pscrm-rest': {
target: 'https://demo.bdsaas.cn/',
target: 'https://im.bdsaas.cn/',
changeOrigin: true,
secure: true
},
'/associate-web': {
target: 'https://demo.bdsaas.cn/',
target: 'https://im.bdsaas.cn/',
changeOrigin: true,
secure: true
},
'/badu-expand-customer-rest': {
target: 'https://im.bdsaas.cn/',
changeOrigin: true,
secure: true
},
'/bdsaas': {
target: 'https://demo.bdsaas.cn/',
target: 'https://im.bdsaas.cn/',
changeOrigin: true,
secure: true
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import BasicChart from '../basic-chart/BasicChart.vue'
import type { PropType } from 'vue'
import type { ChartType } from '../basic-chart/echarts-options'
import type { RequestMethod } from '../../_plugins/axios-http/http'
import { cloneDeep } from 'lodash-es'
type SetOption = (data: any, option: any) => void
Expand Down Expand Up @@ -71,7 +72,7 @@ export default defineComponent({
const chartOptions = getChartOption(unref(chartType))
function getData() {
const _params = unref(params)
const _params = cloneDeep(unref(params))
// 删除部门名称,避免影响请求
Reflect.deleteProperty(_params, 'depName')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<BasicBusinessLayout
title="线索使用统计"
chart-type="basicLine"
url="/associate-web/callReport/callConnectedTimesRankStatistics"
url="/badu-expand-customer-rest/overview/queryYkcLeadUsageStatistics"
:params="params"
:set-option="setOption"
>
Expand Down Expand Up @@ -38,32 +38,35 @@ export default defineComponent({
const dateText = computed(() => getDateText(params.value))
function setOption(data, option) {
option.xAxis.data = data?.xaxisList || [
'2024-03-01',
'2024-03-02',
'2024-03-03',
'2024-03-04',
'2024-03-05',
'2024-03-06',
'2024-03-07'
]
option.xAxis.data = (data || []).map((item: any) => item.createdTime)
option.series = [
{
name: '领取线索量',
type: 'line',
data: [150, 230, 224, 218, 135, 147, 260]
data: (data || []).map((item: any) => item.receiveCount)
},
{
name: '分配线索量',
type: 'line',
data: [250, 130, 124, 318, 235, 247, 160]
data: (data || []).map((item: any) => item.allocationCount)
},
{
name: '加入公海的线索量',
type: 'line',
data: [450, 530, 324, 118, 335, 347, 60]
data: (data || []).map((item: any) => item.seaCount)
}
]
option.dataZoom = [
{
type: 'inside'
},
{
type: 'slider'
}
]
option.grid = {
bottom: 60
}
}
return {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<BasicBusinessLayout
title="企业解锁量排行榜"
chart-type="basicBar"
url="/associate-web/callReport/callConnectedTimesRankStatistics"
url="/badu-expand-customer-rest/overview/queryYkcRankingListOfEnterpriseUnlockVolume"
:params="params"
:set-option="setOption"
>
Expand All @@ -29,25 +29,16 @@ export default defineComponent({
const params = ref({
cdId: 0,
endDate: '',
pageNo: 0,
pageSize: 0,
startDate: '',
depName: ''
})
const dateText = computed(() => getDateText(params.value))
function setOption(data, option) {
option.yAxis.data = data?.xaxisList || [
'张三',
'张三2',
'张三3',
'张三4',
'张三5',
'张三6',
'张三7'
]
option.series[0].data = data?.dataList || [0, 60, 120, 180, 240, 360, 400]
console.log(data, 'lin 39')
option.yAxis.data = (data || []).map((item: any) => item.profileName)
option.series[0].data = (data || []).map((item: any) => item.unlockNum)
}
return {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<BasicBusinessLayout
title="近七日解锁量趋势"
chart-type="basicLine"
url="/associate-web/callReport/callConnectedTimesRankStatistics"
url="/badu-expand-customer-rest/overview/queryYkcUnlockVolumeTrendInThePastSevenDays"
:params="params"
:set-option="setOption"
>
Expand Down Expand Up @@ -38,16 +38,19 @@ export default defineComponent({
const dateText = computed(() => getDateText(params.value))
function setOption(data, option) {
option.xAxis.data = data?.xaxisList || [
'2024-03-01',
'2024-03-02',
'2024-03-03',
'2024-03-04',
'2024-03-05',
'2024-03-06',
'2024-03-07'
option.xAxis.data = (data || []).map(item => item.createdTime)
option.series[0].data = (data || []).map(item => item.unlockNum)
option.dataZoom = [
{
type: 'inside'
},
{
type: 'slider'
}
]
option.series[0].data = data?.dataList || [0, 60, 120, 180, 240, 360, 400]
option.grid = {
bottom: 60
}
}
return {
Expand Down

0 comments on commit 3d3930b

Please sign in to comment.