Commit df1744b8 by 李伟康

commit 话术质检

1 parent 50639c7d
...@@ -89,5 +89,10 @@ export default { ...@@ -89,5 +89,10 @@ export default {
getCustomerClueStatistics(data) { getCustomerClueStatistics(data) {
return api.post('dj.api.smartcarlife.customer.clue.statistics.status', data) return api.post('dj.api.smartcarlife.customer.clue.statistics.status', data)
}, },
/**分页查询接待批次列表 */
getInspectionList(data){
return api.post('dj.api.smartcarlife.inspection.conversation.batch.page', data ,[], '/rop-dj-smartcarlife/router')
}
} }
\ No newline at end of file \ No newline at end of file
// packageEquity/pages/aiInspection/aiInspection.js // packageEquity/pages/aiInspection/aiInspection.js
import carLifeApi from '../../carEquityApi'
Page({ Page({
/** /**
...@@ -6,42 +8,23 @@ Page({ ...@@ -6,42 +8,23 @@ Page({
*/ */
data: { data: {
flag: true, flag: true,
list: [new Array(10)] list: [new Array(10)],
}, },
/** /**
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
*/ */
onLoad(options) { onLoad(options) {
this.setData({ this.getInspectionList()
num: 88
})
setTimeout(() => {
this.selectComponent('#arc').drawData()
setTimeout(() => {
this.setData({
num: 10
})
this.selectComponent('#arc').drawData()
setTimeout(() => {
this.setData({
num: 50
})
this.selectComponent('#arc').drawData()
setTimeout(() => {
this.setData({
num: 44
})
this.selectComponent('#arc').drawData()
}, 2e3)
}, 2e3)
}, 2e3)
}, 2e3)
}, },
changeDate(e) { changeDate(e) {
console.log(e) console.log(e)
}, },
async getInspectionList() {
const res = await carLifeApi.getInspectionList({})
console.log(res)
},
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
*/ */
......
...@@ -57,6 +57,8 @@ Component({ ...@@ -57,6 +57,8 @@ Component({
y: width / 2, y: width / 2,
innerRadius: this.toRpx(58), innerRadius: this.toRpx(58),
outerRadius: this.toRpx(34), outerRadius: this.toRpx(34),
lineWidth: this.toRpx(22),
arcRadius: this.toRpx(46)
} }
this.canvas = canvas this.canvas = canvas
this.drawBackground() this.drawBackground()
...@@ -89,11 +91,12 @@ Component({ ...@@ -89,11 +91,12 @@ Component({
ctx.save() ctx.save()
this.drawTips() this.drawTips()
}, },
drawData(){ drawData() {
const {num} = this.data const {
this.drawBackground() num
} = this.data
this.part = Math.ceil(num / 20) this.part = Math.ceil(num / 20)
this.fillArc(Start_Angle, 0, Start_Angle + Angle) if (num) this.fillArc(Start_Angle, 0, Start_Angle + Angle)
}, },
drawTips(data) { drawTips(data) {
let { let {
...@@ -101,8 +104,8 @@ Component({ ...@@ -101,8 +104,8 @@ Component({
y, y,
} = this.arcInfo } = this.arcInfo
x = x / 2 x = x / 2
// if (data) this.ctx.clearRect(x + 10, y / 2 + 20, this.toRpx(52), this.toRpx(30))
this.ctx.clearRect(x + 15, y / 2 + 15, this.toRpx(45), this.toRpx(60)) this.ctx.clearRect(x + 10, y / 2 + 60, this.toRpx(50), this.toRpx(30))
this.drawText({ this.drawText({
text: data || '···', text: data || '···',
x, x,
...@@ -124,7 +127,7 @@ Component({ ...@@ -124,7 +127,7 @@ Component({
textBaseline: 'middle' textBaseline: 'middle'
}) })
}, },
fillArc(startAngle, index, endAngle) { fillArc(startAngle, index, endAngle) {
const { const {
ctx, ctx,
...@@ -132,8 +135,8 @@ Component({ ...@@ -132,8 +135,8 @@ Component({
arcInfo: { arcInfo: {
x, x,
y, y,
innerRadius, lineWidth,
outerRadius arcRadius
}, },
data: { data: {
num num
...@@ -142,10 +145,10 @@ Component({ ...@@ -142,10 +145,10 @@ Component({
a = startAngle a = startAngle
let b = startAngle + Math.PI / 70 let b = startAngle + Math.PI / 70
ctx.beginPath() ctx.beginPath()
ctx.fillStyle = Arc_Data_Background[index] ctx.strokeStyle = Arc_Data_Background[index]
ctx.arc(x, y, innerRadius, a, b) ctx.lineWidth = lineWidth
ctx.arc(x, y, outerRadius, b, a, true) ctx.arc(x, y, arcRadius, a, b)
ctx.fill() ctx.stroke()
ctx.save() ctx.save()
this.drawImg() this.drawImg()
setTimeout(() => { setTimeout(() => {
...@@ -173,23 +176,22 @@ Component({ ...@@ -173,23 +176,22 @@ Component({
arcInfo: { arcInfo: {
x, x,
y, y,
innerRadius, lineWidth,
outerRadius arcRadius
} }
} = this } = this
let startAngle = Start_Angle let startAngle = Start_Angle
for (let i = 0; i < part; i++) { for (let i = 0; i < part; i++) {
ctx.beginPath() ctx.beginPath()
ctx.strokeStyle = Arc_Data_Background[i]
ctx.lineWidth = lineWidth
if (i == part - 1) { if (i == part - 1) {
ctx.arc(x, y, innerRadius, startAngle, remainder) ctx.arc(x, y, arcRadius, startAngle, remainder)
ctx.arc(x, y, outerRadius, remainder, startAngle, true)
} else { } else {
ctx.arc(x, y, innerRadius, startAngle, startAngle + Angle) ctx.arc(x, y, arcRadius, startAngle, startAngle + Angle)
ctx.arc(x, y, outerRadius, startAngle + Angle, startAngle, true)
} }
ctx.fillStyle = Arc_Data_Background[i] // ctx.fillStyle = Arc_Data_Background[i]
ctx.stroke() ctx.stroke()
ctx.fill()
startAngle += Angle startAngle += Angle
} }
ctx.save() ctx.save()
......
...@@ -33,7 +33,23 @@ page { ...@@ -33,7 +33,23 @@ page {
height: 100%; height: 100%;
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
position: relative;
&::after {
content: '';
position: absolute;
right: 0;
top: 50%;
transform: translateY(-50%);
width: var(--fontSize1);
height: var(--fontSize56);
background-color: #E4E8EE;
}
&:last-of-type{
&::after{
display: none;
}
}
.title { .title {
font-weight: 500; font-weight: 500;
font-size: var(--fontSize22); font-size: var(--fontSize22);
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!