GithubHelp home page GithubHelp logo

sandlbn / django-bootstrap-calendar Goto Github PK

View Code? Open in Web Editor NEW
102.0 11.0 57.0 472 KB

simple django calendar app based on the bootstrap calendar of http://bootstrap-calendar.azurewebsites.net/

License: BSD 3-Clause "New" or "Revised" License

Python 11.82% CSS 9.01% JavaScript 67.97% HTML 11.20%

django-bootstrap-calendar's Introduction

django-bootstrap-calendar

simple calendar based on the bootstrap calendar from http://bootstrap-calendar.azurewebsites.net/

https://raw.github.com/sandlbn/django-bootstrap-calendar/master/screenshot.png

Requirements

  • Python 2.6, 2.7
  • Django (1.4.3+)
  • jsmin (2.0.3+)

Instalation

Django:

settings.py:

INSTALLED_APPS = (
...
'django_bootstrap_calendar',
...
)

urls.py:

urlpatterns = patterns('',
...
(r'^calendar/', include('django_bootstrap_calendar.urls')),
...
)

Load templatetags:

{% load bootstrap_calendar %}

In your template file:

Calendar controls :

{% bootstrap_controls 'optional-css-classes' %}

Calendar:

{% bootstrap_calendar 'optional-css-classes' %}

In your base.html file css section:

{% bootstrap_calendar_css %}

In your base.html file javascript section:

{% bootstrap_calendar_js language="lang-code" %}
{% bootstrap_calendar_init language="lang-code" %}

django-bootstrap-calendar's People

Contributors

cesarcruz avatar humitos avatar ilizaran avatar sandlbn avatar sjdines avatar urtzai avatar uzzije avatar w3lly avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

django-bootstrap-calendar's Issues

Installation

The installation instructions say to add 'django_bootstrap_calendar', to the INSTALLED_APPS list in the settings.py but isn't this list for apps you make? Whenever I try to do this I get an error saying there isn't a module named django_bootstrap_calendar. I've tried making an app and adding this code and I've also just tried adding the 'django_bootstrap_calendar' without an app and neither works for setting up. I forked the repo to my django project but I'm stuck at this point.

EDIT:
I figured out that if you install the repo to the root directory for the project the installation works.

calendar_init.html File not exist.

HI. I am jongil.

I tried to use this module in my project.
but error occured.

Template-loader postmortem

Django tried loading these templates, in this order:
Using loader django.template.loaders.filesystem.Loader:
/home/nijin39/DEV/wedev/wedev/WEB/html/partial/calendar_init.html (File does not exist)
Using loader django.template.loaders.app_directories.Loader:
/home/nijin39/DEV/wedev/local/lib/python2.7/site-packages/django/contrib/admin/templates/partial/calendar_init.html (File does not exist)
/home/nijin39/DEV/wedev/local/lib/python2.7/site-packages/django/contrib/auth/templates/partial/calendar_init.html (File does not exist)
/home/nijin39/DEV/wedev/local/lib/python2.7/site-packages/django_bootstrap_calendar-0.1.0-py2.7.egg/django_bootstrap_calendar/templates/partial/calendar_init.html (File does not exist)

Invalid block tag: 'bootstrap_calendar_css'

Hi Guys,

Any idea what is the cause of this error?
Invalid block tag: 'bootstrap_calendar_css'

I have included the following in my base.html file in the css and js section
{% bootstrap_calendar_css %}
{% bootstrap_calendar_js language="lang-code" %}
{% bootstrap_calendar_init language="lang-code" %}

I'm on django 1.6, jsmin is installed via pip

Any ideas?

Cheers

Adam

not an issue but a question

I'm new to django and your calendar is just what I need for an existing project. Unfortunately I don't have enough experience to implement it. I've successfully installed it to my virtualenv and entered as an installed app. That's as far as I have got. Is this package to be used as a separate application within a project.

Any help or guidance would be greatly appreciated,

thanks in advance,

Michael

Add onAfterViewLoad in calendar_init.html

In file calendar_init.html between lines 17 and 18, add onAfterViewLoad attribute

onAfterViewLoad: function(view) {
    $('.page-header h3').text(this.getTitle());
    $('.btn-group button').removeClass('active');
    $('button[data-calendar-view="' + view + '"]').addClass('active');
},

jsmin dependency is missing

If you install this app in this way:

pip install git+https://github.com/sandlbn/django-bootstrap-calendar

You need to install "jsmin" by hand, running this:

pip install jsmin

Passing options to bootstrap_calendar_init seems to not be working

Hey I have tried to pass the "width" parameter to this templatetag but the calendar always displays at 100% no matter what, should the templatetag be called like this: {% bootstrap_calendar_init width="30%" %} if I wanted to change the width at initialization of the calendar?

Month/Year/Day Labels

the current templates do not display the name of the month, year or day you are looking at, as appropriate to month, year or day views.
I can see this displayed in demo's for the calendar this was originally based on, but cannot find the means to put this on anywhere in the code.

Database

I am kinda new to django, I was able to install the app, but when i try to create an event through the admin panel it says "no such table: django_bootstrap_calendar_calendarevent".
problemacalendardatabase

I have tried to migrate the project, but does not seem to even acknowledge that the calendar app exists.

Dependencies fault

There is some JS's on the project that is not inserted when we call the templatetag to initialize the calendar. The underscore-min.js and bootstrap.min.js. Without them, the calendar initialization breaks.

No module named 'utils'

I installed and followed your instructions to use the calendar, but when trying to use it in my own app, I get that error everytime. I checked and utils.py is in the path, but python can't find it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.