{"action":"created","issue":{"url":"https://api.github.com/repos/CartoDB/cartodb/issues/2145","labels_url":"https://api.github.com/repos/CartoDB/cartodb/issues/2145/labels{/name}","comments_url":"https://api.github.com/repos/CartoDB/cartodb/issues/2145/comments","events_url":"https://api.github.com/repos/CartoDB/cartodb/issues/2145/events","html_url":"https://github.com/CartoDB/cartodb/issues/2145","id":57145716,"number":2145,"title":"Spurious vizualization step discards data from second table","user":{"login":"cshirky","id":226500,"avatar_url":"https://avatars.githubusercontent.com/u/226500?v=3","gravatar_id":"","url":"https://api.github.com/users/cshirky","html_url":"https://github.com/cshirky","followers_url":"https://api.github.com/users/cshirky/followers","following_url":"https://api.github.com/users/cshirky/following{/other_user}","gists_url":"https://api.github.com/users/cshirky/gists{/gist_id}","starred_url":"https://api.github.com/users/cshirky/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cshirky/subscriptions","organizations_url":"https://api.github.com/users/cshirky/orgs","repos_url":"https://api.github.com/users/cshirky/repos","events_url":"https://api.github.com/users/cshirky/events{/privacy}","received_events_url":"https://api.github.com/users/cshirky/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"javierarce","id":4933,"avatar_url":"https://avatars.githubusercontent.com/u/4933?v=3","gravatar_id":"","url":"https://api.github.com/users/javierarce","html_url":"https://github.com/javierarce","followers_url":"https://api.github.com/users/javierarce/followers","following_url":"https://api.github.com/users/javierarce/following{/other_user}","gists_url":"https://api.github.com/users/javierarce/gists{/gist_id}","starred_url":"https://api.github.com/users/javierarce/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/javierarce/subscriptions","organizations_url":"https://api.github.com/users/javierarce/orgs","repos_url":"https://api.github.com/users/javierarce/repos","events_url":"https://api.github.com/users/javierarce/events{/privacy}","received_events_url":"https://api.github.com/users/javierarce/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/CartoDB/cartodb/milestones/32","labels_url":"https://api.github.com/repos/CartoDB/cartodb/milestones/32/labels","id":916728,"number":32,"title":"Sanabria","description":"- [ ] Temp. Maps API Experiments (@rochoa)\r\n- [ ] Limits per user / plan (@lbosque)\r\n- [ ] URL rewrite (@kartones)\r\n- [ ] Medusa fixes (@javierarce)\r\n- [ ] Odyssey fixes (@javierarce)\r\n- [ ] Limit per user per plans (@rochoa)\r\n- [ ] Security fixes (@rochoa)\r\n- [ ] Perf. Editor (@rtorre)\r\n- [ ] Common data v2 (@juanignaciosl)\r\n- [ ] New Dashboard (@xavijam / @viddo)\r\n- [ ] fixes mobile (@xapy)\r\n- [ ] torque performance/fixes UI (@fdansv)","creator":{"login":"saleiva","id":132149,"avatar_url":"https://avatars.githubusercontent.com/u/132149?v=3","gravatar_id":"","url":"https://api.github.com/users/saleiva","html_url":"https://github.com/saleiva","followers_url":"https://api.github.com/users/saleiva/followers","following_url":"https://api.github.com/users/saleiva/following{/other_user}","gists_url":"https://api.github.com/users/saleiva/gists{/gist_id}","starred_url":"https://api.github.com/users/saleiva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saleiva/subscriptions","organizations_url":"https://api.github.com/users/saleiva/orgs","repos_url":"https://api.github.com/users/saleiva/repos","events_url":"https://api.github.com/users/saleiva/events{/privacy}","received_events_url":"https://api.github.com/users/saleiva/received_events","type":"User","site_admin":false},"open_issues":73,"closed_issues":19,"state":"open","created_at":"2014-12-29T14:59:00Z","updated_at":"2015-02-10T09:00:58Z","due_on":"2015-02-18T23:00:00Z","closed_at":null},"comments":2,"created_at":"2015-02-10T08:44:49Z","updated_at":"2015-02-10T09:10:22Z","closed_at":null,"body":"Carto now requires the creation of a visualization whenever a second layer is created in map view.\r\n\r\nThe interface reports that data added to this second layer gets saved, when in fact it is discarded, and the newly created layer is destroyed.\r\n\r\nSteps to reproduce.\r\n\r\n1. Create a new table with one layer and at least one data point.\r\n2. Go to map view.\r\n3. Add layer, using Empty Table.\r\n4. A dialog box pops up asking you to name a new visualization. Provide a name and submit. (Note that the upper-right button will still read Visualize, not Share.)\r\n5. Add an element to layer #2 in Map view. (I drew a box around the original point.) Carto will show elements in both layers, and the popup above the map will show \"Saving...\" and then \"Saved\".\r\n![screen shot 2015-02-10 at 4 32 12 pm](https://cloud.githubusercontent.com/assets/226500/6123859/74e927fa-b142-11e4-895a-3751a7c725a1.png)\r\n\r\n6. Switch to data view. The screen will briefly switch to the table from layer #2, with an overlay reading \"Setting table...\", then redirect to table #1.\r\n7. Switch back to Map view. Layer #2 has been deleted.\r\n![screen shot 2015-02-10 at 4 39 26 pm](https://cloud.githubusercontent.com/assets/226500/6123944/9299517a-b143-11e4-9ad6-493c71af8c14.png)\r\n\r\nThe workaround is to name a visualization in step #4, then click Visualize and name a second Visualization before step #6, making the named visualization in step #4 completely spurious, and the \"Saving.../Saved\" dialog inaccurate.\r\n \r\nThe right behaviors would be:\r\n\r\na) Making the visualization from step #4 save any subsequent layers or, \r\nb) leaving the creation of a visualization to the Vizualize button, and just showing the user layered maps until they want to create a Visualization. \r\n\r\nI prefer a, as it's closer to the right behavior, but either a or b would be much better than this. \r\n"},"comment":{"url":"https://api.github.com/repos/CartoDB/cartodb/issues/comments/73666432","html_url":"https://github.com/CartoDB/cartodb/issues/2145#issuecomment-73666432","issue_url":"https://api.github.com/repos/CartoDB/cartodb/issues/2145","id":73666432,"user":{"login":"iriberri","id":1730320,"avatar_url":"https://avatars.githubusercontent.com/u/1730320?v=3","gravatar_id":"","url":"https://api.github.com/users/iriberri","html_url":"https://github.com/iriberri","followers_url":"https://api.github.com/users/iriberri/followers","following_url":"https://api.github.com/users/iriberri/following{/other_user}","gists_url":"https://api.github.com/users/iriberri/gists{/gist_id}","starred_url":"https://api.github.com/users/iriberri/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iriberri/subscriptions","organizations_url":"https://api.github.com/users/iriberri/orgs","repos_url":"https://api.github.com/users/iriberri/repos","events_url":"https://api.github.com/users/iriberri/events{/privacy}","received_events_url":"https://api.github.com/users/iriberri/received_events","type":"User","site_admin":false},"created_at":"2015-02-10T09:10:22Z","updated_at":"2015-02-10T09:10:22Z","body":"The visualization remains with the two layers, the issue is that clicking on the \"Table view\" is using the URL of the first table (tablename/table) instead of the table view of the visualization (viz-id/table). So you get redirected to your actual table and you're no longer browsing your visualization (check that in your step 7 you're again in the \"Visualize\" process, which belongs to a table).\r\n\r\nIf you check your saved visualizations, the two layers are there. The issue is that creating a visualization from a table is not updating the links in the view."}}