def get_columns(filters):
    for fieldname in ["fiscal_year", "period", "target_on"]:
        if not filters.get(fieldname):
            label = (" ".join(fieldname.split("_"))).title()
            msgprint(_("Please specify") + ": " + label, raise_exception=True)

    columns = [
        "Sales Person:Link/Sales Person:120", "Item Group:Link/Item Group:120"
    ]

    group_months = False if filters["period"] == "Monthly" else True

    for from_date, to_date in get_period_date_ranges(filters["period"],
                                                     filters["fiscal_year"]):
        for label in ["Target (%s)", "Achieved (%s)", "Variance (%s)"]:
            if group_months:
                label = label % (from_date.strftime("%b") + " - " +
                                 to_date.strftime("%b"))
            else:
                label = label % from_date.strftime("%b")

            columns.append(label + ":Float:120")

    return columns + [
        "Total Target:Float:120", "Total Achieved:Float:120",
        "Total Variance:Float:120"
    ]
def get_columns(filters):
	for fieldname in ["fiscal_year", "period", "target_on"]:
		if not filters.get(fieldname):
			label = (" ".join(fieldname.split("_"))).title()
			msgprint(_("Please specify") + ": " + label, raise_exception=True)

	columns = ["Territory:Link/Territory:80", "Item Group:Link/Item Group:80"]

	group_months = False if filters["period"] == "Monthly" else True

	for from_date, to_date in get_period_date_ranges(filters["period"], filters["fiscal_year"]):
		for label in ["Target (%s)", "Achieved (%s)", "Variance (%s)"]:
			if group_months:
				columns.append(label % (from_date.strftime("%b") + " - " + to_date.strftime("%b")))				
			else:
				columns.append(label % from_date.strftime("%b"))

	return columns + ["Total Target::80", "Total Achieved::80", "Total Variance::80"]
def get_columns(filters):
	for fieldname in ["fiscal_year", "period", "company"]:
		if not filters.get(fieldname):
			label = (" ".join(fieldname.split("_"))).title()
			msgprint(_("Please specify") + ": " + label,
				raise_exception=True)

	columns = ["Cost Center:Link/Cost Center:120", "Account:Link/Account:120"]

	group_months = False if filters["period"] == "Monthly" else True

	for from_date, to_date in get_period_date_ranges(filters["period"], filters["fiscal_year"]):
		for label in ["Target (%s)", "Actual (%s)", "Variance (%s)"]:
			if group_months:
				label = label % (from_date.strftime("%b") + " - " + to_date.strftime("%b"))
			else:
				label = label % from_date.strftime("%b")
				
			columns.append(label+":Float:120")

	return columns + ["Total Target::120", "Total Actual::120", "Total Variance::120"]
def get_columns(filters):
    for fieldname in ["fiscal_year", "period", "company"]:
        if not filters.get(fieldname):
            label = (" ".join(fieldname.split("_"))).title()
            msgprint(_("Please specify") + ": " + label, raise_exception=True)

    columns = ["Cost Center:Link/Cost Center:100", "Account:Link/Account:100"]

    group_months = False if filters["period"] == "Monthly" else True

    for from_date, to_date in get_period_date_ranges(filters["period"],
                                                     filters["fiscal_year"]):
        for label in ["Target (%s)", "Actual (%s)", "Variance (%s)"]:
            if group_months:
                columns.append(label % (from_date.strftime("%b") + " - " +
                                        to_date.strftime("%b")))
            else:
                columns.append(label % from_date.strftime("%b"))

    return columns + [
        "Total Target::80", "Total Actual::80", "Total Variance::80"
    ]