Example #1
0
def processing3d(request, sketch_id=None, version_id=None):
    sketch = None
    version = None
    if sketch_id:
        sketch = Sketch.get_from_encoded_id_or_404(encoded_id=sketch_id)
        version = sketch.get_version_or_404(v=version_id)

    return render_to_response('pjs-editor-3d.jade',
                            {'version': version,
                             'sketch_id': sketch_id},
                            context_instance=RequestContext(request))
Example #2
0
    def save(self):
        sketch = Sketch.get_from_encoded_id(self.cleaned_data['sketch_id'])
        version = sketch.create_version(content=self.cleaned_data['content'])

        return version