geopoint pointer 类型的存或取

来源:互联网 发布:生成淘宝无线链接地址 编辑:程序博客网 时间:2024/06/03 13:29
//存地址 geopoint 格式的     $point = new GeoPoint(lat,lon);// 存 pointer 格式的     $todo = Object::create("shop", $objectId);     $query->equalTo("shop_id", $todo);// pointer 格式取值 需要 先用指针指向var user_id = AV.Object.createWithoutData('你的用户表名',你的id);var lat =  new AV.Query('product'); //product 表名lat.select(['*']);lat.equalTo('user_id', user_id );lat.find().then(function(lat) {if (lat) {      response.success({          code: 1,          data: lat      });      }   }).catch(function(err) {  response.error(err);});geopoint  格式 取值$geo = $object->get("location");$lat = $geo->getLatitude();$long = $geo->getLongitude();object.get("Lon_lat").lat js 获取geopoint
原创粉丝点击