feat: added link from desk page and some minor fixes

This commit is contained in:
Anurag Mishra 2020-08-18 15:02:32 +05:30
parent 25c356894d
commit 493eea19e8
3 changed files with 94 additions and 91 deletions

View File

@ -13,7 +13,7 @@
{ {
"hidden": 0, "hidden": 0,
"label": "Compensations", "label": "Compensations",
"links": "[\n {\n \"label\": \"Additional Salary\",\n \"name\": \"Additional Salary\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n \n },\n {\n \"label\": \"Retention Bonus\",\n \"name\": \"Retention Bonus\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Employee Incentive\",\n \"name\": \"Employee Incentive\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Employee Benefit Application\",\n \"name\": \"Employee Benefit Application\",\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Employee Benefit Claim\",\n \"name\": \"Employee Benefit Claim\",\n \"type\": \"doctype\"\n }\n]" "links": "[\n {\n \"label\": \"Additional Salary\",\n \"name\": \"Additional Salary\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n \n },\n {\n \"label\": \"Retention Bonus\",\n \"name\": \"Retention Bonus\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Employee Incentive\",\n \"name\": \"Employee Incentive\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Gratuity Rule\",\n \"name\": \"Gratuity Rule\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Gratuity\",\n \"name\": \"Gratuity\",\n \"onboard\": 1,\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Employee Benefit Application\",\n \"name\": \"Employee Benefit Application\",\n \"type\": \"doctype\"\n },\n {\n \"label\": \"Employee Benefit Claim\",\n \"name\": \"Employee Benefit Claim\",\n \"type\": \"doctype\"\n }\n]"
}, },
{ {
"hidden": 0, "hidden": 0,
@ -38,7 +38,7 @@
"idx": 0, "idx": 0,
"is_standard": 1, "is_standard": 1,
"label": "Payroll", "label": "Payroll",
"modified": "2020-08-10 19:38:45.976209", "modified": "2020-08-18 15:00:55.671767",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Payroll", "module": "Payroll",
"name": "Payroll", "name": "Payroll",

View File

@ -799,7 +799,7 @@ def get_tds_details(accounts, fiscal_year):
def create_gratuity_rule(): def create_gratuity_rule():
# Standard Indain Gratuity Rule # Standard Indain Gratuity Rule
if not frappe.db.exists("Gratuity Rule", "Indian Standard Gratuity Rule"):
rule = frappe.new_doc("Gratuity Rule") rule = frappe.new_doc("Gratuity Rule")
rule.name = "Indian Standard Gratuity Rule" rule.name = "Indian Standard Gratuity Rule"
rule.calculate_gratuity_amount_based_on = "Current Slab" rule.calculate_gratuity_amount_based_on = "Current Slab"

View File

@ -165,6 +165,7 @@ def create_gratuity_rule():
# Standard Gratuity Rules for UAE # Standard Gratuity Rules for UAE
# Rule Under Limited Contract # Rule Under Limited Contract
if not frappe.db.exists("Gratuity Rule", "Rule Under Limited Contract (UAE)"):
rule_1 = frappe.new_doc("Gratuity Rule") rule_1 = frappe.new_doc("Gratuity Rule")
rule_1.name = "Rule Under Limited Contract (UAE)" rule_1.name = "Rule Under Limited Contract (UAE)"
rule_1.calculate_gratuity_amount_based_on = "Sum of all previous slabs" rule_1.calculate_gratuity_amount_based_on = "Sum of all previous slabs"
@ -190,6 +191,7 @@ def create_gratuity_rule():
}) })
# Rule Under Unlimited Contract on termination # Rule Under Unlimited Contract on termination
if not frappe.db.exists("Gratuity Rule", "Rule Under Unlimited Contract on termination (UAE)"):
rule_2 = frappe.new_doc("Gratuity Rule") rule_2 = frappe.new_doc("Gratuity Rule")
rule_2.name = "Rule Under Unlimited Contract on termination (UAE)" rule_2.name = "Rule Under Unlimited Contract on termination (UAE)"
rule_2.calculate_gratuity_amount_based_on = "Current Slab" rule_2.calculate_gratuity_amount_based_on = "Current Slab"
@ -215,6 +217,7 @@ def create_gratuity_rule():
}) })
# Rule Under Unlimited Contract # Rule Under Unlimited Contract
if not frappe.db.exists("Gratuity Rule", "Rule Under Unlimited Contract on resignation (UAE)"):
rule_3 = frappe.new_doc("Gratuity Rule") rule_3 = frappe.new_doc("Gratuity Rule")
rule_3.name = "Rule Under Unlimited Contract on resignation (UAE)" rule_3.name = "Rule Under Unlimited Contract on resignation (UAE)"
rule_3.calculate_gratuity_amount_based_on = "Current Slab" rule_3.calculate_gratuity_amount_based_on = "Current Slab"