import { httpget } from '../../utils/request'; import apiurl from '../apiurl'; import { HDRealPromise } from './real'; export async function hdyjUnclose() { const { data } = await httpget(apiurl.stwarnrecord.unclose) || {}; const ret = data || []; const list = await HDRealPromise.get() || []; ret.forEach(item => { const record = list.find(o => o.stcd === item.stcd) || {}; item.adcd = record.adcd; item.lgtd = record.lgtd; item.lttd = record.lttd; item.real = record; }); // return ret; return [{ "stcd": "61612900", "stnm": "阎家河", "adcd": null, "wscd": null, "importancy": 0, "lgtd": 115.128722, "lttd": 31.207, "elev": null, "hasRz": true, "type": "sw", "tm": "2025-06-03T02:00:00.000Z", "rz": 61.75, "state": 1 }] } export async function hdyjLatestClosed() { const { data } = await httpget(apiurl.stwarnrecord.find, { status: 3, page: 1, size: 10 }) || {}; const ret = data?.list || []; return ret; }