Merge branch 'master' of github.com:webnotes/erpnext
Conflicts: accounts/search_criteria/lease_agreement_list/lease_agreement_list.txt accounts/search_criteria/lease_receipt_summary_month_wise/lease_receipt_summary_month_wise.txt accounts/search_criteria/lease_receipts_client_wise/lease_receipts_client_wise.txt
This commit is contained in:
commit
27f9f5edb7
@ -94,8 +94,8 @@ class DocType:
|
||||
def convert_group_to_ledger(self):
|
||||
if self.check_if_child_exists():
|
||||
msgprint("Account: %s has existing child. You can not convert this account to ledger" % (self.doc.name), raise_exception=1)
|
||||
elif self.check_prev_bal_exists():
|
||||
msgprint("Account with balance can not be converted to ledger.", raise_exception=1)
|
||||
elif self.check_gle_exists():
|
||||
msgprint("Account with existing transaction can not be converted to ledger.", raise_exception=1)
|
||||
else:
|
||||
self.doc.group_or_ledger = 'Ledger'
|
||||
self.doc.save()
|
||||
@ -104,8 +104,8 @@ class DocType:
|
||||
# Convert ledger to group
|
||||
# ==================================================================
|
||||
def convert_ledger_to_group(self):
|
||||
if self.check_prev_bal_exists():
|
||||
msgprint("Account with balance can not be converted to group.", raise_exception=1)
|
||||
if self.check_gle_exists():
|
||||
msgprint("Account with existing transaction can not be converted to group.", raise_exception=1)
|
||||
else:
|
||||
self.doc.group_or_ledger = 'Group'
|
||||
self.doc.save()
|
||||
@ -113,9 +113,9 @@ class DocType:
|
||||
|
||||
# Check if any previous balance exists
|
||||
# ==================================================================
|
||||
def check_prev_bal_exists(self):
|
||||
bal = sql("select balance from `tabAccount Balance` where parent = '%s' and ifnull(balance, 0) > 0" % (self.doc.name))
|
||||
return bal and flt(bal[0][0]) or 0
|
||||
def check_gle_exists(self):
|
||||
exists = sql("select name from `tabGL Entry` where account = '%s' and ifnull(is_cancelled, 'No') = 'No'" % (self.doc.name))
|
||||
return exists and exists[0][0] or ''
|
||||
|
||||
# check if child exists
|
||||
# ==================================================================
|
||||
@ -231,8 +231,8 @@ class DocType:
|
||||
# Account with balance cannot be inactive
|
||||
# ==================================================================
|
||||
def check_balance_before_trash(self):
|
||||
if flt(self.get_curr_bal()) != 0:
|
||||
msgprint("Account with existing balance can not be trashed", raise_exception=1)
|
||||
if self.check_gle_exists():
|
||||
msgprint("Account with existing transaction can not be trashed", raise_exception=1)
|
||||
if self.check_if_child_exists():
|
||||
msgprint("Child account exists for this account. You can not trash this account.", raise_exception=1)
|
||||
|
||||
|
@ -1,30 +0,0 @@
|
||||
# Search Criteria, lease_agreement_list
|
||||
[
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2011-07-26 17:01:34',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-28 11:18:26',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
||||
# These values are common for all Search Criteria
|
||||
{
|
||||
'columns': 'GL Entry\x01ID,GL Entry\x01Owner,GL Entry\x01Posting Date,GL Entry\x01Aging Date,GL Entry\x01Account,GL Entry\x01Cost Center,GL Entry\x01Against,GL Entry\x01Against Voucher,GL Entry\x01Voucher Type,GL Entry\x01Voucher No,GL Entry\x01Remarks,GL Entry\x01Is Cancelled,GL Entry\x01Is Opening,GL Entry\x01Fiscal Year,GL Entry\x01Company',
|
||||
'criteria_name': 'Lease Agreement List',
|
||||
'doc_type': 'GL Entry',
|
||||
'doctype': 'Search Criteria',
|
||||
'filters': "{'GL Entry\x01Voucher Type':'','GL Entry\x01Is Cancelled':'','GL Entry\x01Is Opening':'','GL Entry\x01Fiscal Year':''}",
|
||||
'module': 'Accounts',
|
||||
'name': '__common__',
|
||||
'standard': 'Yes'
|
||||
},
|
||||
|
||||
# Search Criteria, lease_agreement_list
|
||||
{
|
||||
'doctype': 'Search Criteria',
|
||||
'name': 'lease_agreement_list'
|
||||
}
|
||||
]
|
@ -3,9 +3,9 @@
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2011-07-26 16:45:07',
|
||||
'creation': '2011-07-27 13:14:29',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-26 18:26:16',
|
||||
'modified': '2011-07-27 13:14:29',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
@ -3,9 +3,9 @@
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2011-07-26 18:11:10',
|
||||
'creation': '2011-07-27 13:14:29',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-26 18:26:40',
|
||||
'modified': '2011-07-27 13:14:29',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
@ -1,30 +0,0 @@
|
||||
# Search Criteria, lease_receipt_summary_month_wise
|
||||
[
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2011-07-27 18:48:29',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-28 09:59:51',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
||||
# These values are common for all Search Criteria
|
||||
{
|
||||
'columns': 'GL Entry\x01ID,GL Entry\x01Owner,GL Entry\x01Posting Date,GL Entry\x01Aging Date,GL Entry\x01Account,GL Entry\x01Cost Center,GL Entry\x01Against,GL Entry\x01Against Voucher,GL Entry\x01Voucher Type,GL Entry\x01Voucher No,GL Entry\x01Remarks,GL Entry\x01Is Cancelled,GL Entry\x01Is Opening,GL Entry\x01Fiscal Year,GL Entry\x01Company',
|
||||
'criteria_name': 'Lease Receipt Summary Month Wise',
|
||||
'doc_type': 'GL Entry',
|
||||
'doctype': 'Search Criteria',
|
||||
'filters': "{'GL Entry\x01Voucher Type':'','GL Entry\x01Is Cancelled':'','GL Entry\x01Is Opening':'','GL Entry\x01Fiscal Year':''}",
|
||||
'module': 'Accounts',
|
||||
'name': '__common__',
|
||||
'standard': 'Yes'
|
||||
},
|
||||
|
||||
# Search Criteria, lease_receipt_summary_month_wise
|
||||
{
|
||||
'doctype': 'Search Criteria',
|
||||
'name': 'lease_receipt_summary_month_wise'
|
||||
}
|
||||
]
|
@ -1,31 +0,0 @@
|
||||
# Search Criteria, lease_receipts_client_wise
|
||||
[
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2011-07-28 12:13:41',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-28 12:16:13',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
||||
# These values are common for all Search Criteria
|
||||
{
|
||||
'columns': 'GL Entry\x01ID,GL Entry\x01Owner,GL Entry\x01Posting Date,GL Entry\x01Aging Date,GL Entry\x01Account,GL Entry\x01Cost Center,GL Entry\x01Against,GL Entry\x01Against Voucher,GL Entry\x01Voucher Type,GL Entry\x01Voucher No,GL Entry\x01Remarks,GL Entry\x01Is Cancelled,GL Entry\x01Is Opening,GL Entry\x01Fiscal Year,GL Entry\x01Company',
|
||||
'criteria_name': 'Lease Receipts Client Wise',
|
||||
'doc_type': 'GL Entry',
|
||||
'doctype': 'Search Criteria',
|
||||
'filters': "{'GL Entry\x01Voucher Type':'','GL Entry\x01Is Cancelled':'','GL Entry\x01Is Opening':'','GL Entry\x01Fiscal Year':''}",
|
||||
'module': 'Accounts',
|
||||
'name': '__common__',
|
||||
'page_len': 50,
|
||||
'standard': 'Yes'
|
||||
},
|
||||
|
||||
# Search Criteria, lease_receipts_client_wise
|
||||
{
|
||||
'doctype': 'Search Criteria',
|
||||
'name': 'lease_receipts_client_wise'
|
||||
}
|
||||
]
|
@ -3,9 +3,9 @@
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2011-07-26 16:24:45',
|
||||
'creation': '2011-07-27 13:14:29',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-26 18:28:03',
|
||||
'modified': '2011-07-27 13:14:29',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
@ -195,7 +195,7 @@ class DocType:
|
||||
# Get Children
|
||||
# ------------
|
||||
def get_children(self, parent_account, level, pl, company, fy):
|
||||
cl = sql("select distinct account_name, name, debit_or_credit, lft, rgt from `tabAccount` where ifnull(parent_account, '') = %s and ifnull(is_pl_account, 'No')=%s and company=%s order by name asc", (parent_account, pl, company))
|
||||
cl = sql("select distinct account_name, name, debit_or_credit, lft, rgt from `tabAccount` where ifnull(parent_account, '') = %s and ifnull(is_pl_account, 'No')=%s and company=%s and docstatus != 2 order by name asc", (parent_account, pl, company))
|
||||
level0_diff = [0 for p in self.period_list]
|
||||
if pl=='Yes' and level==0: # switch for income & expenses
|
||||
cl = [c for c in cl]
|
||||
@ -295,7 +295,7 @@ class DocType:
|
||||
sd = self.ysd.strftime('%Y-%m-%d')
|
||||
cond = ""
|
||||
|
||||
bal = sql("select SUM(t1.debit), SUM(t1.credit) from `tabGL Entry` t1, `tabAccount` t2 WHERE t1.posting_date >= '%s' AND t1.posting_date <= '%s' AND t1.company = '%s' AND t1.account = t2.name AND t2.lft >= %s AND t2.rgt <= %s and ifnull(is_opening,'No') = 'No' %s" % (sd,ed,company,lft,rgt, cond))
|
||||
bal = sql("select SUM(t1.debit), SUM(t1.credit) from `tabGL Entry` t1, `tabAccount` t2 WHERE t1.posting_date >= '%s' AND t1.posting_date <= '%s' AND t1.company = '%s' AND t1.account = t2.name AND t2.lft >= %s AND t2.rgt <= %s and ifnull(t1.is_opening,'No') = 'No' and ifnull(t1.is_cancelled, 'No') = 'No' %s" % (sd,ed,company,lft,rgt, cond))
|
||||
|
||||
|
||||
bal = bal and (flt(bal[0][0]) - flt(bal[0][1])) or 0
|
||||
@ -316,7 +316,7 @@ class DocType:
|
||||
a = sql("select account_name, name, debit_or_credit, lft, rgt, is_pl_account from `tabAccount` where account_name=%s and company=%s", (acc, company), as_dict=1)
|
||||
if a:
|
||||
a = a[0]
|
||||
bal = sql("select SUM(IFNULL(t1.debit,0)), SUM(IFNULL(t1.credit,0)) from `tabGL Entry` t1, `tabAccount` t2 WHERE t1.posting_date >= %s AND t1.posting_date <= %s AND t1.account = t2.name AND t2.lft >= %s AND t2.rgt <= %s and ifnull(is_opening, 'No') = 'No'", (sd,ed,a['lft'],a['rgt']))
|
||||
bal = sql("select SUM(IFNULL(t1.debit,0)), SUM(IFNULL(t1.credit,0)) from `tabGL Entry` t1, `tabAccount` t2 WHERE t1.posting_date >= %s AND t1.posting_date <= %s AND t1.account = t2.name AND t2.lft >= %s AND t2.rgt <= %s and ifnull(is_opening, 'No') = 'No' and ifnull(t1.is_cancelled, 'No') = 'No'", (sd,ed,a['lft'],a['rgt']))
|
||||
if a['debit_or_credit']=='Debit':
|
||||
bal = flt(flt(bal[0][0]) - flt(bal[0][1]))
|
||||
else:
|
||||
@ -341,13 +341,13 @@ class DocType:
|
||||
rec_grp = sql("select receivables_group from tabCompany where name=%s", company)
|
||||
if rec_grp:
|
||||
pa_lft_rgt = sql("select lft, rgt from tabAccount where name=%s and company=%s", (rec_grp[0][0], company))[0]
|
||||
return sql("select t1.account_name, SUM(t2.debit) from tabAccount t1, `tabGL Entry` t2 where t1.lft > %s and t1.rgt < %s and t2.account = t1.name GROUP BY t1.name ORDER BY SUM(t2.debit) desc limit 5", (pa_lft_rgt[0], pa_lft_rgt[1]))
|
||||
return sql("select t1.account_name, SUM(t2.debit) from tabAccount t1, `tabGL Entry` t2 where t1.lft > %s and t1.rgt < %s and t2.account = t1.name and ifnull(t2.is_cancelled, 'No') = 'No' GROUP BY t1.name ORDER BY SUM(t2.debit) desc limit 5", (pa_lft_rgt[0], pa_lft_rgt[1]))
|
||||
else:
|
||||
return []
|
||||
|
||||
def get_top_5_exp(self, company):
|
||||
a = sql("select distinct account_name, name, debit_or_credit, lft, rgt from `tabAccount` where account_name=%s and company=%s", ('Expenses', company), as_dict=1)[0]
|
||||
return sql("select t1.account_name, SUM(t2.debit) from tabAccount t1, `tabGL Entry` t2 where t1.lft>%s and t1.rgt<%s and t1.group_or_ledger = 'Ledger' and t2.account = t1.name and t2.voucher_type != 'Period Closing Voucher' GROUP BY t1.name ORDER BY SUM(t2.debit) desc limit 5", (a['lft'],a['rgt']))
|
||||
return sql("select t1.account_name, SUM(t2.debit) from tabAccount t1, `tabGL Entry` t2 where t1.lft>%s and t1.rgt<%s and t1.group_or_ledger = 'Ledger' and t2.account = t1.name and ifnull(t2.is_cancelled, 'No') = 'No' and t2.voucher_type != 'Period Closing Voucher' GROUP BY t1.name ORDER BY SUM(t2.debit) desc limit 5", (a['lft'],a['rgt']))
|
||||
|
||||
def bl(self, acc, company):
|
||||
dt = getdate(nowdate())
|
||||
|
602
hr/doctype/salary_slip/salary_slip.txt
Normal file
602
hr/doctype/salary_slip/salary_slip.txt
Normal file
@ -0,0 +1,602 @@
|
||||
# DocType, Salary Slip
|
||||
[
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2010-08-08 17:09:20',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-27 13:10:28',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
||||
# These values are common for all DocType
|
||||
{
|
||||
'_last_update': '1310019491',
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocType',
|
||||
'module': 'HR',
|
||||
'name': '__common__',
|
||||
'section_style': 'Simple',
|
||||
'server_code_error': ' ',
|
||||
'show_in_menu': 0,
|
||||
'subject': 'For %(employee_name)s, %(designation)s',
|
||||
'version': 393
|
||||
},
|
||||
|
||||
# These values are common for all DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'name': '__common__',
|
||||
'parent': 'Salary Slip',
|
||||
'parentfield': 'fields',
|
||||
'parenttype': 'DocType'
|
||||
},
|
||||
|
||||
# These values are common for all DocPerm
|
||||
{
|
||||
'doctype': 'DocPerm',
|
||||
'name': '__common__',
|
||||
'parent': 'Salary Slip',
|
||||
'parentfield': 'permissions',
|
||||
'parenttype': 'DocType',
|
||||
'read': 1
|
||||
},
|
||||
|
||||
# DocType, Salary Slip
|
||||
{
|
||||
'doctype': 'DocType',
|
||||
'name': 'Salary Slip'
|
||||
},
|
||||
|
||||
# DocPerm
|
||||
{
|
||||
'amend': 0,
|
||||
'cancel': 0,
|
||||
'create': 0,
|
||||
'doctype': 'DocPerm',
|
||||
'idx': 1,
|
||||
'match': 'owner',
|
||||
'permlevel': 0,
|
||||
'role': 'Employee',
|
||||
'submit': 0,
|
||||
'write': 0
|
||||
},
|
||||
|
||||
# DocPerm
|
||||
{
|
||||
'amend': 0,
|
||||
'create': 1,
|
||||
'doctype': 'DocPerm',
|
||||
'idx': 2,
|
||||
'permlevel': 0,
|
||||
'role': 'HR User',
|
||||
'submit': 1,
|
||||
'write': 1
|
||||
},
|
||||
|
||||
# DocPerm
|
||||
{
|
||||
'amend': 1,
|
||||
'cancel': 1,
|
||||
'create': 1,
|
||||
'doctype': 'DocPerm',
|
||||
'idx': 3,
|
||||
'permlevel': 0,
|
||||
'role': 'HR Manager',
|
||||
'submit': 1,
|
||||
'write': 1
|
||||
},
|
||||
|
||||
# DocPerm
|
||||
{
|
||||
'doctype': 'DocPerm',
|
||||
'idx': 4,
|
||||
'permlevel': 1,
|
||||
'role': 'HR User'
|
||||
},
|
||||
|
||||
# DocPerm
|
||||
{
|
||||
'doctype': 'DocPerm',
|
||||
'idx': 5,
|
||||
'permlevel': 1,
|
||||
'role': 'HR Manager'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Section Break',
|
||||
'idx': 1,
|
||||
'label': 'Basic Info',
|
||||
'oldfieldtype': 'Section Break',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Column Break',
|
||||
'idx': 2,
|
||||
'oldfieldtype': 'Column Break',
|
||||
'permlevel': 0,
|
||||
'width': '50%'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'employee',
|
||||
'fieldtype': 'Link',
|
||||
'idx': 3,
|
||||
'in_filter': 1,
|
||||
'label': 'Employee',
|
||||
'oldfieldname': 'employee',
|
||||
'oldfieldtype': 'Link',
|
||||
'options': 'Employee',
|
||||
'permlevel': 0,
|
||||
'reqd': 1,
|
||||
'search_index': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'employee_name',
|
||||
'fieldtype': 'Data',
|
||||
'idx': 4,
|
||||
'in_filter': 1,
|
||||
'label': 'Employee Name',
|
||||
'oldfieldname': 'employee_name',
|
||||
'oldfieldtype': 'Data',
|
||||
'permlevel': 1,
|
||||
'reqd': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'department',
|
||||
'fieldtype': 'Link',
|
||||
'idx': 5,
|
||||
'in_filter': 1,
|
||||
'label': 'Department',
|
||||
'oldfieldname': 'department',
|
||||
'oldfieldtype': 'Link',
|
||||
'options': 'Department',
|
||||
'permlevel': 1,
|
||||
'reqd': 0,
|
||||
'search_index': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'designation',
|
||||
'fieldtype': 'Link',
|
||||
'idx': 6,
|
||||
'in_filter': 1,
|
||||
'label': 'Designation',
|
||||
'oldfieldname': 'designation',
|
||||
'oldfieldtype': 'Link',
|
||||
'options': 'Designation',
|
||||
'permlevel': 1,
|
||||
'search_index': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'branch',
|
||||
'fieldtype': 'Link',
|
||||
'idx': 7,
|
||||
'in_filter': 1,
|
||||
'label': 'Branch',
|
||||
'oldfieldname': 'branch',
|
||||
'oldfieldtype': 'Link',
|
||||
'options': 'Branch',
|
||||
'permlevel': 1,
|
||||
'search_index': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'grade',
|
||||
'fieldtype': 'Link',
|
||||
'idx': 8,
|
||||
'in_filter': 1,
|
||||
'label': 'Grade',
|
||||
'oldfieldname': 'grade',
|
||||
'oldfieldtype': 'Link',
|
||||
'options': 'Grade',
|
||||
'permlevel': 1,
|
||||
'search_index': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'pf_no',
|
||||
'fieldtype': 'Data',
|
||||
'idx': 9,
|
||||
'label': 'PF No.',
|
||||
'oldfieldname': 'pf_no',
|
||||
'oldfieldtype': 'Data',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'esic_no',
|
||||
'fieldtype': 'Data',
|
||||
'idx': 10,
|
||||
'label': 'ESIC No.',
|
||||
'oldfieldname': 'esic_no',
|
||||
'oldfieldtype': 'Data',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'letter_head',
|
||||
'fieldtype': 'Link',
|
||||
'idx': 11,
|
||||
'label': 'Letter Head',
|
||||
'options': 'Letter Head',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Column Break',
|
||||
'idx': 12,
|
||||
'oldfieldtype': 'Column Break',
|
||||
'permlevel': 0,
|
||||
'width': '50%'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'fiscal_year',
|
||||
'fieldtype': 'Link',
|
||||
'idx': 13,
|
||||
'in_filter': 1,
|
||||
'label': 'Fiscal Year',
|
||||
'oldfieldname': 'fiscal_year',
|
||||
'oldfieldtype': 'Data',
|
||||
'options': 'Fiscal Year',
|
||||
'permlevel': 0,
|
||||
'reqd': 1,
|
||||
'search_index': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'company',
|
||||
'fieldtype': 'Select',
|
||||
'idx': 14,
|
||||
'in_filter': 1,
|
||||
'label': 'Company',
|
||||
'options': 'link:Company',
|
||||
'permlevel': 0,
|
||||
'reqd': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'month',
|
||||
'fieldtype': 'Select',
|
||||
'idx': 15,
|
||||
'in_filter': 1,
|
||||
'label': 'Month',
|
||||
'oldfieldname': 'month',
|
||||
'oldfieldtype': 'Select',
|
||||
'options': '\n01\n02\n03\n04\n05\n06\n07\n08\n09\n10\n11\n12',
|
||||
'permlevel': 0,
|
||||
'reqd': 1,
|
||||
'search_index': 1,
|
||||
'trigger': 'Client',
|
||||
'width': '37%'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'total_days_in_month',
|
||||
'fieldtype': 'Data',
|
||||
'idx': 16,
|
||||
'label': 'Total days in month',
|
||||
'oldfieldname': 'total_days_in_month',
|
||||
'oldfieldtype': 'Int',
|
||||
'permlevel': 1,
|
||||
'reqd': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'leave_without_pay',
|
||||
'fieldtype': 'Currency',
|
||||
'idx': 17,
|
||||
'label': 'Leave Without Pay',
|
||||
'oldfieldname': 'leave_without_pay',
|
||||
'oldfieldtype': 'Currency',
|
||||
'permlevel': 0,
|
||||
'trigger': 'Client'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'payment_days',
|
||||
'fieldtype': 'Float',
|
||||
'idx': 18,
|
||||
'label': 'Payment days',
|
||||
'oldfieldname': 'payment_days',
|
||||
'oldfieldtype': 'Float',
|
||||
'permlevel': 1,
|
||||
'reqd': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'bank_name',
|
||||
'fieldtype': 'Data',
|
||||
'idx': 19,
|
||||
'label': 'Bank Name',
|
||||
'oldfieldname': 'bank_name',
|
||||
'oldfieldtype': 'Data',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'bank_account_no',
|
||||
'fieldtype': 'Data',
|
||||
'idx': 20,
|
||||
'label': 'Bank Account No.',
|
||||
'oldfieldname': 'bank_account_no',
|
||||
'oldfieldtype': 'Data',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'email_check',
|
||||
'fieldtype': 'Check',
|
||||
'idx': 21,
|
||||
'label': 'Email',
|
||||
'no_copy': 1,
|
||||
'oldfieldname': 'email_check',
|
||||
'oldfieldtype': 'Check',
|
||||
'permlevel': 0,
|
||||
'print_hide': 1,
|
||||
'report_hide': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'amended_from',
|
||||
'fieldtype': 'Data',
|
||||
'hidden': 0,
|
||||
'idx': 22,
|
||||
'label': 'Amended From',
|
||||
'no_copy': 1,
|
||||
'oldfieldname': 'amended_from',
|
||||
'oldfieldtype': 'Data',
|
||||
'permlevel': 0,
|
||||
'print_hide': 1,
|
||||
'report_hide': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'amendment_date',
|
||||
'fieldtype': 'Date',
|
||||
'hidden': 0,
|
||||
'idx': 23,
|
||||
'label': 'Amendment Date',
|
||||
'no_copy': 1,
|
||||
'oldfieldname': 'amendment_date',
|
||||
'oldfieldtype': 'Date',
|
||||
'permlevel': 0,
|
||||
'print_hide': 1,
|
||||
'report_hide': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Section Break',
|
||||
'idx': 24,
|
||||
'label': 'Earning & Deduction',
|
||||
'oldfieldtype': 'Section Break',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Column Break',
|
||||
'idx': 25,
|
||||
'label': 'Earning',
|
||||
'oldfieldtype': 'Column Break',
|
||||
'permlevel': 0,
|
||||
'reqd': 0,
|
||||
'width': '50%'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'earning_details',
|
||||
'fieldtype': 'Table',
|
||||
'idx': 26,
|
||||
'label': 'Earning Details',
|
||||
'oldfieldname': 'earning_details',
|
||||
'oldfieldtype': 'Table',
|
||||
'options': 'SS Earning Detail',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Column Break',
|
||||
'idx': 27,
|
||||
'label': 'Deduction',
|
||||
'oldfieldtype': 'Column Break',
|
||||
'permlevel': 0,
|
||||
'width': '50%'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'deduction_details',
|
||||
'fieldtype': 'Table',
|
||||
'idx': 28,
|
||||
'label': 'Deduction Details',
|
||||
'oldfieldname': 'deduction_details',
|
||||
'oldfieldtype': 'Table',
|
||||
'options': 'SS Deduction Detail',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Section Break',
|
||||
'idx': 29,
|
||||
'label': 'Totals',
|
||||
'oldfieldtype': 'Section Break',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Column Break',
|
||||
'idx': 30,
|
||||
'oldfieldtype': 'Column Break',
|
||||
'permlevel': 0,
|
||||
'width': '50%'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'arrear_amount',
|
||||
'fieldtype': 'Currency',
|
||||
'idx': 31,
|
||||
'label': 'Arrear Amount',
|
||||
'oldfieldname': 'arrear_amount',
|
||||
'oldfieldtype': 'Currency',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'leave_encashment_amount',
|
||||
'fieldtype': 'Currency',
|
||||
'idx': 32,
|
||||
'label': 'Leave Encashment Amount',
|
||||
'oldfieldname': 'encashment_amount',
|
||||
'oldfieldtype': 'Currency',
|
||||
'permlevel': 0
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'gross_pay',
|
||||
'fieldtype': 'Currency',
|
||||
'idx': 33,
|
||||
'label': 'Gross Pay',
|
||||
'oldfieldname': 'gross_pay',
|
||||
'oldfieldtype': 'Currency',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'total_deduction',
|
||||
'fieldtype': 'Currency',
|
||||
'idx': 34,
|
||||
'label': 'Total Deduction',
|
||||
'oldfieldname': 'total_deduction',
|
||||
'oldfieldtype': 'Currency',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldtype': 'Column Break',
|
||||
'idx': 35,
|
||||
'oldfieldtype': 'Column Break',
|
||||
'permlevel': 0,
|
||||
'width': '50%'
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'colour': 'White:FFF',
|
||||
'description': 'Gross Pay + Arrear Amount +Encashment Amount - Total Deduction',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'net_pay',
|
||||
'fieldtype': 'Currency',
|
||||
'idx': 36,
|
||||
'label': 'Net Pay',
|
||||
'oldfieldname': 'net_pay',
|
||||
'oldfieldtype': 'Currency',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'rounded_total',
|
||||
'fieldtype': 'Currency',
|
||||
'idx': 37,
|
||||
'label': 'Rounded Total',
|
||||
'permlevel': 1
|
||||
},
|
||||
|
||||
# DocField
|
||||
{
|
||||
'description': 'Net Pay (in words) will be visible once you save the Salary Slip.',
|
||||
'doctype': 'DocField',
|
||||
'fieldname': 'total_in_words',
|
||||
'fieldtype': 'Data',
|
||||
'idx': 38,
|
||||
'label': 'Total in words',
|
||||
'oldfieldname': 'net_pay_in_words',
|
||||
'oldfieldtype': 'Data',
|
||||
'permlevel': 1
|
||||
}
|
||||
]
|
@ -195,6 +195,6 @@ def run_patches():
|
||||
sync_mapper()
|
||||
delete_unwanted_modules()
|
||||
# landed cost wizard link in stock
|
||||
reload_doc('stock', 'Module Def', 'stock')
|
||||
reload_doc('stock', 'Module Def', 'Stock')
|
||||
|
||||
sql("commit")
|
||||
|
@ -1,7 +1,7 @@
|
||||
# REMEMBER to update this
|
||||
# ========================
|
||||
|
||||
last_patch = 330
|
||||
last_patch = 332
|
||||
|
||||
#-------------------------------------------
|
||||
|
||||
@ -1346,3 +1346,5 @@ def execute(patch_no):
|
||||
# permission
|
||||
p.add_permission('Lease Agreement', 'Accounts Manager', 0, read = 1, write=1,submit=1, cancel=1,amend=1)
|
||||
p.add_permission('Lease Agreement', 'Accounts Manager', 1, read = 1)
|
||||
elif patch_no == 332:
|
||||
sql("update `tabDocField` set permlevel=1, hidden = 1 where parent = 'Bulk Rename Tool' and fieldname = 'file_list'")
|
||||
|
@ -3,16 +3,16 @@
|
||||
|
||||
# These values are common in all dictionaries
|
||||
{
|
||||
'creation': '2011-07-08 11:14:15',
|
||||
'creation': '2011-07-07 17:47:52',
|
||||
'docstatus': 0,
|
||||
'modified': '2011-07-26 00:59:27',
|
||||
'modified': '2011-07-27 13:19:22',
|
||||
'modified_by': 'Administrator',
|
||||
'owner': 'Administrator'
|
||||
},
|
||||
|
||||
# These values are common for all DocType
|
||||
{
|
||||
'_last_update': '1310035501',
|
||||
'_last_update': '1311622167',
|
||||
'allow_attach': 1,
|
||||
'autoname': 'field:rename_doctype',
|
||||
'colour': 'White:FFF',
|
||||
@ -21,7 +21,7 @@
|
||||
'name': '__common__',
|
||||
'section_style': 'Simple',
|
||||
'show_in_menu': 0,
|
||||
'version': 6
|
||||
'version': 7
|
||||
},
|
||||
|
||||
# These values are common for all DocField
|
||||
|
Loading…
x
Reference in New Issue
Block a user