我将餐厅的地理坐标存储在MongoDB数据库中。 现在,我需要创建一个循环来获取所有餐馆的地理坐标和用户地理坐标,以获得最近的5家餐馆。我不知道如何循环和匹配用户的地理坐标。我想要恰好有5家餐厅在我附近,因为Google place API集成在前端,所以我只能获得我需要匹配的地理坐标,以便在我附近获得确切的餐厅。cordinates:[{ latit
address: " Apple CAP 3000 Avenue Eugène Donadeï, 06700 Saint-Laurent Du Var, France" map{marker: { address: " Apple CAP 3000 Avenue Eugène Donadeï, 06700 Saint-Laurent Du Var, France" },
通过