up
This commit is contained in:
@ -220,6 +220,7 @@ onMounted(() => {
|
||||
function initonMounted() {
|
||||
getLhdyears();
|
||||
initmap(); //地图
|
||||
showDaChangArea();
|
||||
alter();
|
||||
getCityAndCountZbs();
|
||||
for (const key in dic) {
|
||||
@ -231,6 +232,10 @@ function initonMounted() {
|
||||
checkList.value = checkListdata.value;
|
||||
console.log(checkList.value);
|
||||
}
|
||||
onUpdated(() => {
|
||||
document.querySelector('.mode').style.display = 'none';
|
||||
window.document.querySelector('#screenfull').style.display = 'block';
|
||||
});
|
||||
watch(
|
||||
() => oldDatas.value,
|
||||
(val, oldVal) => {
|
||||
@ -393,7 +398,7 @@ function QueryData(e, name, url, item) {
|
||||
let code = data.result.recordsets[0].features.features[0].properties.XJQYDM;
|
||||
value.value = code;
|
||||
let arr = [];
|
||||
getAbandon().then(res => {
|
||||
getAbandon({ divisions: '370211', yearMonth: oldDatas.value.name }).then(res => {
|
||||
res.data.forEach(item => {
|
||||
console.log(item.subregionCode, code);
|
||||
if (item.subregionCode == code) {
|
||||
@ -410,7 +415,7 @@ function QueryData(e, name, url, item) {
|
||||
) {
|
||||
let code = data.result.recordsets[0].features.features[0].properties.CJQYDM;
|
||||
let arr = [];
|
||||
getNonFoodHuoChun({ divisions: code, yearMonth: '2023-05' }).then(res => {
|
||||
getNonFoodHuoChun({ divisions: code, yearMonth: oldDatas.value.name }).then(res => {
|
||||
res.data.forEach(item => {
|
||||
if (item.subregionCode == code) {
|
||||
name = item.subregionName;
|
||||
@ -492,11 +497,19 @@ const alter = () => {
|
||||
});
|
||||
map.addOverlay(overlay);
|
||||
};
|
||||
//创建蒙层,凸显黄岛区域
|
||||
function showDaChangArea() {
|
||||
axios.get('/json/huangdao.json').then(({ data }) => {
|
||||
const fts = new ol.format.GeoJSON().readFeatures(data);
|
||||
const ft = fts[0];
|
||||
addConver(ft.getGeometry().getCoordinates(),'huandao');
|
||||
});
|
||||
}
|
||||
//添加遮罩
|
||||
function addConver(data) {
|
||||
function addConver(data,name) {
|
||||
let source = new ol.source.Vector();
|
||||
var converLayer = new ol.layer.Vector({
|
||||
id: 'zhezhao',
|
||||
id: name ? name : 'zhezhao',
|
||||
source: source,
|
||||
style: new ol.style.Style({
|
||||
fill: new ol.style.Fill({
|
||||
|
Reference in New Issue
Block a user