We use Tock to track our time. You can read more about Tock in this blog post about its features.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import datetime | |
from random import randint | |
from django.contrib.auth.models import User | |
from employees.models import EmployeeGrade | |
def create_obj(): | |
objects = User.objects.filter() | |
for o in objects: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import os | |
select_url = raw_input("Which Tock API endpoint would you like to access? Type the number that corresponds with your choice:\n 1 = ...projects.json \n 2 = ...timecards_bulk.csv \n 3 = ...users.json \n \n >>>") | |
print "Gathering data..." | |
if select_url == "1": | |
url = "https://tock.18f.gov/api/projects.json" | |
fmt = "json" | |
elif select_url == "2": | |
url = "https://tock.18f.gov/api/timecards_bulk.csv" | |
fmt = "csv" |
NewerOlder