make private annotations private

This commit is contained in:
j 2011-02-11 15:51:25 +05:30
commit 866d60b467
4 changed files with 38 additions and 8 deletions

View file

@ -6,11 +6,13 @@ from ox.utils import json
from ox.django.decorators import login_required_json
from ox.django.shortcuts import render_to_json_response, get_object_or_404_json, json_response
import models
from item.models import Item
from app.models import site_config
from item.models import Item
from api.actions import actions
import models
def findAnnotations(request):
'''
@ -56,6 +58,9 @@ def addAnnotation(request):
return render_to_json_response(json_response(status=400,
text='invalid data'))
#FIXME: this should be only called starting up server
models.load_layers(site_config()['layers'])
item = get_object_or_404_json(Item, itemId=data['item'])
layer = get_object_or_404_json(models.Layer, name=data['layer'])