Merge pull request #537 from saurabh6790/master

[Trend Reports] Cleanup
This commit is contained in:
Nabin Hait 2013-06-27 23:17:50 -07:00
commit 0fd1d88710
7 changed files with 8 additions and 18 deletions

View File

@ -21,8 +21,7 @@ from controllers.trends import get_columns,get_data
def execute(filters=None): def execute(filters=None):
if not filters: filters ={} if not filters: filters ={}
data = [] data = []
trans = "Purchase Invoice" conditions = get_columns(filters, "Purchase Invoice")
conditions = get_columns(filters, trans)
data = get_data(filters, conditions) data = get_data(filters, conditions)
return conditions["columns"], data return conditions["columns"], data

View File

@ -21,8 +21,7 @@ from controllers.trends import get_columns,get_data
def execute(filters=None): def execute(filters=None):
if not filters: filters ={} if not filters: filters ={}
data = [] data = []
trans = "Sales Invoice" conditions = get_columns(filters, "Sales Invoice")
conditions = get_columns(filters, trans)
data = get_data(filters, conditions) data = get_data(filters, conditions)
return conditions["columns"], data return conditions["columns"], data

View File

@ -21,8 +21,7 @@ from controllers.trends import get_columns,get_data
def execute(filters=None): def execute(filters=None):
if not filters: filters ={} if not filters: filters ={}
data = [] data = []
trans = "Purchase Order" conditions = get_columns(filters, "Purchase Order")
conditions = get_columns(filters, trans)
data = get_data(filters, conditions) data = get_data(filters, conditions)
return conditions["columns"], data return conditions["columns"], data

View File

@ -21,8 +21,7 @@ from controllers.trends import get_columns, get_data
def execute(filters=None): def execute(filters=None):
if not filters: filters ={} if not filters: filters ={}
data = [] data = []
trans = "Quotation" conditions = get_columns(filters, "Quotation")
conditions = get_columns(filters, trans)
data = get_data(filters, conditions) data = get_data(filters, conditions)
return conditions["columns"], data return conditions["columns"], data

View File

@ -21,8 +21,7 @@ from controllers.trends import get_columns,get_data
def execute(filters=None): def execute(filters=None):
if not filters: filters ={} if not filters: filters ={}
data = [] data = []
trans = "Sales Order" conditions = get_columns(filters, "Sales Order")
conditions = get_columns(filters, trans)
data = get_data(filters, conditions) data = get_data(filters, conditions)
return conditions["columns"], data return conditions["columns"], data

View File

@ -21,8 +21,7 @@ from controllers.trends import get_columns,get_data
def execute(filters=None): def execute(filters=None):
if not filters: filters ={} if not filters: filters ={}
data = [] data = []
trans = "Delivery Note" conditions = get_columns(filters, "Delivery Note")
conditions = get_columns(filters, trans)
data = get_data(filters, conditions) data = get_data(filters, conditions)
return conditions["columns"], data return conditions["columns"], data

View File

@ -21,11 +21,7 @@ from controllers.trends import get_columns,get_data
def execute(filters=None): def execute(filters=None):
if not filters: filters ={} if not filters: filters ={}
data = [] data = []
trans = "Purchase Receipt" conditions = get_columns(filters, "Purchase Receipt")
conditions = get_columns(filters, trans) data = get_data(filters, conditions)
data = get_data(filters, tab, conditions)
if not data :
webnotes.msgprint("Data not found for selected criterias")
return conditions["columns"], data return conditions["columns"], data