[fix] [setup_wizard] fiscal year fix for setup wizard

This commit is contained in:
Akhilesh Darjee
2013-11-25 19:51:18 +05:30
parent 8991ad719c
commit ec0da0b177
16 changed files with 140 additions and 95 deletions

View File

@@ -45,11 +45,8 @@ class DocType:
raise Exception
def get_fy_start_end_dates(self):
return webnotes.conn.sql("""select year_start_date,
subdate(adddate(year_start_date, interval 1 year), interval 1 day)
as year_end_date
from `tabFiscal Year`
where name=%s""", (self.doc.fiscal_year,))[0]
return webnotes.conn.sql("""select year_start_date, year_end_date
from `tabFiscal Year` where name=%s""", (self.doc.fiscal_year,))[0]
def get_weekly_off_date_list(self, year_start_date, year_end_date):
from webnotes.utils import getdate

View File

@@ -59,7 +59,6 @@ class DocType:
return cond
def check_mandatory(self):
for f in ['company', 'month', 'fiscal_year']:
if not self.doc.fields[f]:
@@ -84,8 +83,6 @@ class DocType:
'month_days': month_days
}
def create_sal_slip(self):
"""
Creates salary slip for selected employees if already not created