forked from frappe/erpnext
-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
325 additions
and
23 deletions.
There are no files selected for viewing
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
{ | ||
"creation": "2021-06-29 23:42:47.804616", | ||
"doctype": "DocType", | ||
"editable_grid": 1, | ||
"engine": "InnoDB", | ||
"field_order": [ | ||
"minimum_qty", | ||
"maximum_qty", | ||
"column_break_3", | ||
"discount_type", | ||
"discount_percentage", | ||
"discount_amount", | ||
"amended_from" | ||
], | ||
"fields": [ | ||
{ | ||
"fieldname": "minimum_qty", | ||
"fieldtype": "Int", | ||
"in_list_view": 1, | ||
"label": "Minimum Qty" | ||
}, | ||
{ | ||
"fieldname": "maximum_qty", | ||
"fieldtype": "Int", | ||
"in_list_view": 1, | ||
"label": "Maximum Qty" | ||
}, | ||
{ | ||
"fieldname": "column_break_3", | ||
"fieldtype": "Column Break" | ||
}, | ||
{ | ||
"fieldname": "discount_type", | ||
"fieldtype": "Select", | ||
"in_list_view": 1, | ||
"label": "Discount type", | ||
"options": "\nPercentage\nAmount" | ||
}, | ||
{ | ||
"depends_on": "eval:doc.discount_type==\"Percentage\"", | ||
"fieldname": "discount_percentage", | ||
"fieldtype": "Percent", | ||
"in_list_view": 1, | ||
"label": "Discount Percentage" | ||
}, | ||
{ | ||
"depends_on": "eval:doc.discount_type==\"Amount\"", | ||
"fieldname": "discount_amount", | ||
"fieldtype": "Currency", | ||
"in_list_view": 1, | ||
"label": "Discount Amount" | ||
}, | ||
{ | ||
"fieldname": "amended_from", | ||
"fieldtype": "Link", | ||
"label": "Amended From", | ||
"no_copy": 1, | ||
"options": "Bulk Discount", | ||
"print_hide": 1, | ||
"read_only": 1 | ||
}, | ||
{ | ||
"fieldname": "amended_from", | ||
"fieldtype": "Link", | ||
"label": "Amended From", | ||
"no_copy": 1, | ||
"options": "Bulk Discount", | ||
"print_hide": 1, | ||
"read_only": 1 | ||
} | ||
], | ||
"is_submittable": 1, | ||
"istable": 1, | ||
"modified": "2021-06-30 01:01:34.307743", | ||
"modified_by": "Administrator", | ||
"module": "Selling", | ||
"name": "Bulk Discount", | ||
"owner": "Administrator", | ||
"permissions": [], | ||
"quick_entry": 1, | ||
"sort_field": "modified", | ||
"sort_order": "DESC", | ||
"track_changes": 1 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# -*- coding: utf-8 -*- | ||
# Copyright (c) 2021, Frappe Technologies Pvt. Ltd. and contributors | ||
# For license information, please see license.txt | ||
|
||
from __future__ import unicode_literals | ||
# import frappe | ||
from frappe.model.document import Document | ||
|
||
class BulkDiscount(Document): | ||
pass |
Empty file.
8 changes: 8 additions & 0 deletions
8
erpnext/selling/doctype/bulk_discount_scheme/bulk_discount_scheme.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
// Copyright (c) 2021, Frappe Technologies Pvt. Ltd. and contributors | ||
// For license information, please see license.txt | ||
|
||
frappe.ui.form.on('Bulk Discount Scheme', { | ||
// refresh: function(frm) { | ||
|
||
// } | ||
}); |
63 changes: 63 additions & 0 deletions
63
erpnext/selling/doctype/bulk_discount_scheme/bulk_discount_scheme.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
{ | ||
"autoname": "field:scheme_name", | ||
"creation": "2021-06-29 23:42:53.901998", | ||
"doctype": "DocType", | ||
"editable_grid": 1, | ||
"engine": "InnoDB", | ||
"field_order": [ | ||
"scheme_name", | ||
"bulk_disount", | ||
"amended_from" | ||
], | ||
"fields": [ | ||
{ | ||
"fieldname": "bulk_disount", | ||
"fieldtype": "Table", | ||
"label": "Bulk Disount", | ||
"options": "Bulk Discount" | ||
}, | ||
{ | ||
"fieldname": "amended_from", | ||
"fieldtype": "Link", | ||
"label": "Amended From", | ||
"no_copy": 1, | ||
"options": "Bulk Discount Scheme", | ||
"print_hide": 1, | ||
"read_only": 1 | ||
}, | ||
{ | ||
"fieldname": "scheme_name", | ||
"fieldtype": "Data", | ||
"in_list_view": 1, | ||
"label": "Name", | ||
"reqd": 1, | ||
"unique": 1 | ||
} | ||
], | ||
"is_submittable": 1, | ||
"modified": "2021-06-29 23:53:29.887064", | ||
"modified_by": "Administrator", | ||
"module": "Selling", | ||
"name": "Bulk Discount Scheme", | ||
"name_case": "UPPER CASE", | ||
"owner": "Administrator", | ||
"permissions": [ | ||
{ | ||
"create": 1, | ||
"delete": 1, | ||
"email": 1, | ||
"export": 1, | ||
"print": 1, | ||
"read": 1, | ||
"report": 1, | ||
"role": "System Manager", | ||
"share": 1, | ||
"submit": 1, | ||
"write": 1 | ||
} | ||
], | ||
"quick_entry": 1, | ||
"sort_field": "modified", | ||
"sort_order": "DESC", | ||
"track_changes": 1 | ||
} |
10 changes: 10 additions & 0 deletions
10
erpnext/selling/doctype/bulk_discount_scheme/bulk_discount_scheme.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# -*- coding: utf-8 -*- | ||
# Copyright (c) 2021, Frappe Technologies Pvt. Ltd. and contributors | ||
# For license information, please see license.txt | ||
|
||
from __future__ import unicode_literals | ||
# import frappe | ||
from frappe.model.document import Document | ||
|
||
class BulkDiscountScheme(Document): | ||
pass |
10 changes: 10 additions & 0 deletions
10
erpnext/selling/doctype/bulk_discount_scheme/test_bulk_discount_scheme.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# -*- coding: utf-8 -*- | ||
# Copyright (c) 2021, Frappe Technologies Pvt. Ltd. and Contributors | ||
# See license.txt | ||
from __future__ import unicode_literals | ||
|
||
# import frappe | ||
import unittest | ||
|
||
class TestBulkDiscountScheme(unittest.TestCase): | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.