From 56cd1767883c3fa1030d967ca0434a872b1cdab3 Mon Sep 17 00:00:00 2001
From: Krivchikov Dmitry
Date: Mon, 7 Apr 2014 14:53:42 +0400
Subject: [PATCH] =?UTF-8?q?=D0=9A=D0=B0=D1=82=D0=B5=D0=B3=D0=BE=D1=80?=
=?UTF-8?q?=D0=B8=D0=B8=20=D0=B1=D0=B5=D1=80=D1=83=D1=82=D1=81=D1=8F=20?=
=?UTF-8?q?=D0=B8=D0=B7=20=D0=B1=D0=B0=D0=B7=D1=8B?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
public/js/main.js | 23 ++++++++++++++++-------
1 file changed, 16 insertions(+), 7 deletions(-)
diff --git a/public/js/main.js b/public/js/main.js
index 333abc3..293f8b3 100644
--- a/public/js/main.js
+++ b/public/js/main.js
@@ -1,10 +1,10 @@
/*
- * To change this template, choose Tools | Templates
- * and open the template in the editor.
+ * Let's GO!
*/
ymaps.ready(init);
var myMap;
+var categories;
function init() {
myMap = new ymaps.Map("map", {
@@ -18,6 +18,7 @@ function init() {
myMap.controls.add('smallZoomControl');
myMap.controls.add('scaleLine');
+ initCategories()
getPoints();
myMap.events.add('click', function (e) {
@@ -35,8 +36,7 @@ function init() {
'
' +
'Тип:
' +
'' +
'
Источник:
' +
'
' +
@@ -78,7 +78,16 @@ function getPoints()
return true;
}
-function addNewPoint()
+function initCategories()
{
- console.log($('#name').val());
-}
\ No newline at end of file
+ $.ajax({
+ url: "/json/categories/",
+ success: function(data){
+ for(var k in data) {
+ categories = categories + '';
+ }
+ }
+ });
+
+ return true;
+}