I hereby claim:
- I am craigderington on github.
- I am craigderington (https://keybase.io/craigderington) on keybase.
- I have a public key ASCbUM40Q7LxGnKSPW-ar29OyIwHMIHdiFCvctV6uhsAJQo
To claim this, I am signing this object:
| # *-* coding: utf-8 *-* | |
| lst_a = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14] | |
| lst_b = [1, 4, 5, 7, 9, 11, 14] | |
| def de_duplicate(l1, l2): | |
| """ | |
| Return a de-duplicated list | |
| :param l1: list splash visitor |
| # urls.py | |
| from django.conf.urls import url | |
| from views import CustomerListView | |
| urlpatterns = [ | |
| url(r'^customers/$', CustomerListView.as_view()), | |
| ] |
I hereby claim:
To claim this, I am signing this object:
| #!/bin/bash | |
| # Pretty Welcome Message | |
| echo -e " *************************************************** " | |
| echo -e " *************************************************** " | |
| echo -e " Amazon S3 Restore MySQL Databases " | |
| echo -e " 4-18-2017 - Craig Derington " | |
| echo -e " GitHub @craigderington " | |
| echo -e " " | |
| echo -e " *************************************************** " |
| from django.contrib import admin | |
| from django.forms.models import BaseInlineFormSet | |
| from .models import Item, ItemLocation | |
| @admin.register(Item) | |
| class ItemAdmin(admin.ModelAdmin): | |
| fieldsets = ( | |
| ('Item Details', { | |
| 'fields': ('sku', 'item_name', 'item_description', 'item_search', |
| class Location(BaseAddress, TimeStampedModel): | |
| location_name = models.CharField(max_length=50, blank=False, null=False) | |
| default_location = models.BooleanField(default=False) | |
| def __unicode__(self): | |
| if self.location_name and self.city: | |
| return unicode(str(self.location_name + '-' + self.city)) | |
| class Meta: | |
| verbose_name = 'Location' |
| class Item(TimeStampedModel): | |
| LEADTIME_PERIOD = ( | |
| ('D', 'DAYS'), | |
| ('W', 'WEEKS'), | |
| ('M', 'MONTHS'), | |
| ) | |
| sku = models.CharField(max_length=50, blank=False, null=False) | |
| item_name = models.CharField(max_length=50, blank=False, null=False) | |
| item_description = models.TextField() |
| #! flask/bin/python | |
| from flask import Flask, request, jsonify, abort, make_response, url_for | |
| from flask_restful import Api, Resource, reqparse, fields, marshal | |
| from flask_httpauth import HTTPBasicAuth | |
| from datetime import datetime | |
| import pyodbc | |
| import json | |
| import config |
| from django.contrib.auth.models import User | |
| from django.core.cache import cache | |
| from django.core.exceptions import ObjectDoesNotExist | |
| from django.core.urlresolvers import reverse | |
| from django.db import models | |
| from django.db.models import Q | |
| class Alert(models.Model): | |
| SYSTEM_ALERT = 'system_alert' |