uniapp怎么实现轨迹显示

想要做一个根据n条经纬度来实现回显车辆的行驶轨迹,现在是使用map的polyline属性来实现,但是地图显示一直是乱的。

selectMap(data).then(res => {
                    if (res.success) {
                        const that = this;
                        that.polylines=[{
                            points:res.data,
                            width: 2,
                            color: "0000CC"
                        }];
                        uni.showToast({
                            icon: 'none',
                            title: "获取位置成功"
                        });
                    } else {
                        uni.showToast({
                            icon: 'none',
                            title: res.msg
                        });
                    }
                })

图片说明

http://www.imooc.com/article/289978