예제 #1
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        c = Context({'dajaxice_config': dajaxice_config})
        return get_template('dajaxice/dajaxice.core.js').render(c)
예제 #2
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        c = {'dajaxice_config': dajaxice_config}
        return get_template(os.path.join('dajaxice', 'dajaxice.core.js')).render(c)
예제 #3
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        c = {'dajaxice_config': dajaxice_config}
        return get_template(os.path.join('dajaxice', 'dajaxice.core.js')).render(c)
예제 #4
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        c = Context({'dajaxice_config': dajaxice_config})
        return get_template('dajaxice/dajaxice.core.js').render(c)
예제 #5
0
def dajaxice_core_js(request):
    dajaxice_autodiscover()

    return render(
        request,
        os.path.join('dajaxice', 'dajaxice.core.js'),
        {'dajaxice_config': dajaxice_config}
    )
예제 #6
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        #older versions of django require Context
        if get_version() < '1.9':
            c = Context({'dajaxice_config': dajaxice_config})
        else:
            c = {'dajaxice_config': dajaxice_config}

        return get_template(os.path.join('dajaxice', 'dajaxice.core.js')).render(c)
예제 #7
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        # older versions of django require Context
        if list(map(lambda x: int(x), get_version().split('.'))) < [1, 9]:
            c = Context({'dajaxice_config': dajaxice_config})
        else:
            c = {'dajaxice_config': dajaxice_config}

        return get_template(os.path.join('dajaxice', 'dajaxice.core.js')).render(c)
예제 #8
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        # older versions of django require Context
        if map(lambda x: int(x), get_version().split('.')) < [1, 9]:
            c = Context({'dajaxice_config': dajaxice_config})
        else:
            c = {'dajaxice_config': dajaxice_config}

        return get_template(os.path.join('dajaxice',
                                         'dajaxice.core.js')).render(c)
예제 #9
0
    def dajaxice_core_js(self):
        from dajaxice.core import dajaxice_autodiscover, dajaxice_config

        dajaxice_autodiscover()

        #older versions of django require Context
        if get_version() < '1.9':
            c = Context({'dajaxice_config': dajaxice_config})
        else:
            c = {'dajaxice_config': dajaxice_config}

        return get_template(os.path.join('dajaxice',
                                         'dajaxice.core.js')).render(c)
예제 #10
0
파일: urls.py 프로젝트: Miguel-Cayo/sapec
from django.conf.urls import patterns, include, url
from django.contrib import admin
from django.conf import settings

from django.contrib.staticfiles.urls import staticfiles_urlpatterns
from dajaxice.core import dajaxice_autodiscover, dajaxice_config
dajaxice_autodiscover()

admin.autodiscover()

urlpatterns = patterns('',
    (r'^grappelli/', include('grappelli.urls')),
    url(dajaxice_config.dajaxice_url, include('dajaxice.urls')),
    url(r'^media/(?P<path>.*)$','django.views.static.serve', {'document_root':settings.MEDIA_ROOT,} ),
    
    # ABIERTO
    url(r'^$', 'abierto.views.index'),
    #ADMINISTRADOR
    url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
    url(r'^admin/', include(admin.site.urls)),

    #ORGANIZACION
    #unidad
    url(r'^organizacion/$', 'organizacion.views.index_organizacion'),
    url(r'^unidad/new/$', 'organizacion.views.nueva_unidad'),
    url(r'^unidad/option/$', 'organizacion.views.option_unidad'),
    url(r'^unidad/update/(?P<id_unidad>\d+)/$', 'organizacion.views.update_unidad'),
    #url(r'^show/$', 'ejemplo.views.show_persona'),
    url(r'^unidad/planificacion/(?P<id_cargo>\d+)/$', 'organizacion.views.cargo_plani'),
    #planificacion
    url(r'^planificacion/new/$', 'organizacion.views.nueva_plani'),
예제 #11
0
from django.conf.urls import patterns, include, url
from django.contrib import admin

from mezzanine.core.views import direct_to_template
from dajaxice.core import dajaxice_autodiscover, dajaxice_config
dajaxice_autodiscover()

admin.autodiscover()

# Add the urlpatterns for any custom Django applications here.
# You can also change the ``home`` view to add your own functionality
# to the project's homepage.

urlpatterns = patterns(
    "",

    # Change the admin prefix here to use an alternate URL for the
    # admin interface, which would be marginally more secure.
    ("^admin/", include(admin.site.urls)),

    # We don't want to presume how your homepage works, so here are a
    # few patterns you can use to set it up.

    # HOMEPAGE AS STATIC TEMPLATE
    # ---------------------------
    # This pattern simply loads the index.html template. It isn't
    # commented out like the others, so it's the default. You only need
    # one homepage pattern, so if you use a different one, comment this
    # one out.
    url("^organizations/", include('artifacts.urls')),
    url(dajaxice_config.dajaxice_url, include('dajaxice.urls')),
예제 #12
0
from django.conf.urls import patterns, include, url
import settings

from django.contrib import admin
admin.autodiscover()

from dajaxice.core import dajaxice_autodiscover, dajaxice_config
dajaxice_autodiscover()  # dajaxice
# dajaxice 
from django.contrib.staticfiles.urls import staticfiles_urlpatterns

import public
urlpatterns = patterns('',
    url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
    url(r'^admin/', include(admin.site.urls)),
    url(r'^public/',include('public.urls')),
    url(r'^forum/',include('forum.urls')),
    # dajaxice
    url(dajaxice_config.dajaxice_url, include('dajaxice.urls')),
    url(r'^image_upload/(?P<path>.*)$', 'django.views.static.serve',
            {'document_root': settings.MEDIA_ROOT, 'show_indexes': True }),
)

urlpatterns += staticfiles_urlpatterns()
예제 #13
0
from django.conf.urls import patterns, include, url
import settings

from django.contrib import admin
admin.autodiscover()

from dajaxice.core import dajaxice_autodiscover, dajaxice_config
dajaxice_autodiscover()  # dajaxice
# dajaxice
from django.contrib.staticfiles.urls import staticfiles_urlpatterns

import public
urlpatterns = patterns(
    '',
    url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
    url(r'^admin/', include(admin.site.urls)),
    url(r'^public/', include('public.urls')),
    url(r'^forum/', include('forum.urls')),
    # dajaxice
    url(dajaxice_config.dajaxice_url, include('dajaxice.urls')),
    url(r'^image_upload/(?P<path>.*)$', 'django.views.static.serve', {
        'document_root': settings.MEDIA_ROOT,
        'show_indexes': True
    }),
)

urlpatterns += staticfiles_urlpatterns()