From 3361d70e0a9d4cfdb484bbccce43b60c8311fdea Mon Sep 17 00:00:00 2001 From: Andros Fenollosa Date: Thu, 5 Apr 2018 09:22:34 +0200 Subject: [PATCH] Update index filter --- app.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app.py b/app.py index b20aabc..ebbadd7 100644 --- a/app.py +++ b/app.py @@ -29,7 +29,8 @@ CORS(app, resources={r"/api/*": {"origins": "*"}}) @app.route(PRE_URL + 'index/') def index(id): match = POSTALS.loc[[id]] - return match.reset_index().to_json(orient='records') + results = match.filter(items=['postal_code', 'poblacion', 'lat', 'lng']) + return results.reset_index().to_json(orient='records') # Get data from postal code