Skip to content

Instantly share code, notes, and snippets.

@mariodev
mariodev / html
Created November 16, 2018 08:39
Awesome mapbox gist for Agata
{% extends "calf_tracker/base.html" %}
{% load i18n %}
{% load staticfiles %}
{% load common_tags %}
{% block extrastyle %}
{{ block.super }}
{% endblock %}
<div class="column col-3">
<span class="h4">Quality of Life Questions</span>
<div class="popover popover-bottom-right">
<a href="javascript:void(0)" onclick="javascript:void(0)"><i class="fa fa-info-circle"></i></a>
<div class="popover-container">
<div class="card">
<div class="card-body">
Higher scores correspond with a better quality of life. The range for
quality of life scores is between 0-100.
</div>
@mariodev
mariodev / filter.py
Created September 24, 2013 18:51
Custom filter field for django-filter. Control two fields in a flexible manner.
from django import forms
import django_filters
from django_filters.filters import Filter
CHOICES = (('AND', 'AND'), ('OR', 'OR'))
class NamePriceWidget(forms.MultiWidget):
def __init__(self, attrs=None):
widgets = (
forms.TextInput(attrs=attrs),
@mariodev
mariodev / make.bat
Created September 12, 2012 14:37
makefile for twitter bootstrap (Win)
@echo off
set BOOTSTRAP_LESS=./less/bootstrap.less
set BOOTSTRAP_RESPONSIVE_LESS=./less/responsive.less
set BIN_DIR="C:\Program Files (x86)\Git\bin"
%BIN_DIR%\mkdir -p bootstrap/img
%BIN_DIR%\mkdir -p bootstrap/css
%BIN_DIR%\mkdir -p bootstrap/js
%BIN_DIR%\cp img/* bootstrap/img/