def handle(self, *args, **options):
        fp = form_parser()

        all_f3xwsked_es = F3X_Summary.objects.filter(
            total_sched_e__gte=0).values('filing_number')
        for filing in all_f3xwsked_es:
            this_filing_number = filing['filing_number']
            handle_filing_num(this_filing_number, fp)
예제 #2
0
 def __init__(self):
     self.fp = form_parser()
     self.FEClogger=fec_logger()
예제 #3
0
 def __init__(self):
     self.fp = form_parser()
예제 #4
0
from django.core.management.base import BaseCommand, CommandError
from django.db.models import Sum

from outside_spending.models import *

from outside_spending.form_parser import form_parser
from outside_spending.filing import filing

import csv

fp = form_parser()
dumpfilename = "outside_spending/data/F3X_sbdump.csv"


def map_parsed_line(line):
    ordered_list = (line['form_type'], line['transaction_id_number'],
                    line['expenditure_date'], line['expenditure_amount'],
                    line['entity_type'], line['payee_first_name'],
                    line['payee_last_name'], line['payee_organization_name'],
                    line['payee_street_1'], line['payee_street_2'],
                    line['payee_city'], line['filer_committee_id_number'],
                    line['expenditure_purpose_descrip'],
                    line['beneficiary_committee_name'],
                    line['beneficiary_committee_fec_id'], line['conduit_name'],
                    line['conduit_city'], line['conduit_state'],
                    line['memo_code'])
    print ordered_list


def process_file(filingnum, csvwriter):
    f1 = filing(filingnum)