北京经济技术开发区经开区虚拟城市项目-【前端】--政府服务中心-1号屏Web
lixuliang
2023-10-07 bc9913b5abd7166fbb38f575060e9f3be4596835
src/assets/js/rpc.js
@@ -116,12 +116,14 @@
            var LandArr = result[2].candidates.filter((item) => {
                return item.attributes.QYMC.includes(res);
            })
            // 结果根据QYMC从短到长排序
            LandArr.sort((a, b) => (b.attributes.QYMC.length === a.attributes.QYMC.length ? 0 : a.attributes.QYMC.length > b.attributes.QYMC.length ? 1 : -1))
            LandArr.forEach((val) => {
                let itemObj = {
                    type: "地块",
                    name: val.attributes.QYMC,
                    area: val.attributes.area,
                    code: val.attributes["地块编"],
                    lon: val.location.x,
                    lat: val.location.y,
                };