-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into attendance-marking-ux
- Loading branch information
Showing
122 changed files
with
1,815 additions
and
759 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
accounts: | ||
- erpnext/accounts/* | ||
- erpnext/controllers/accounts_controller.py | ||
- erpnext/controllers/taxes_and_totals.py | ||
|
||
stock: | ||
- erpnext/stock/* | ||
- erpnext/controllers/stock_controller.py | ||
- erpnext/controllers/item_variant.py | ||
|
||
assets: | ||
- erpnext/assets/* | ||
|
||
regional: | ||
- erpnext/regional/* | ||
|
||
selling: | ||
- erpnext/selling/* | ||
- erpnext/controllers/selling_controller.py | ||
|
||
buying: | ||
- erpnext/buying/* | ||
- erpnext/controllers/buying_controller.py | ||
|
||
support: | ||
- erpnext/support/* | ||
|
||
POS: | ||
- pos* | ||
|
||
ecommerce: | ||
- erpnext/e_commerce/* | ||
|
||
maintenance: | ||
- erpnext/maintenance/* | ||
|
||
manufacturing: | ||
- erpnext/manufacturing/* | ||
|
||
crm: | ||
- erpnext/crm/* | ||
|
||
HR: | ||
- erpnext/hr/* | ||
|
||
payroll: | ||
- erpnext/payroll* | ||
|
||
projects: | ||
- erpnext/projects/* | ||
|
||
# Any python files modifed but no test files modified | ||
needs-tests: | ||
- any: ['erpnext/**/*.py'] | ||
all: ['!erpnext/**/test*.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
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,12 @@ | ||
name: "Pull Request Labeler" | ||
on: | ||
pull_request_target: | ||
types: [opened, reopened] | ||
|
||
jobs: | ||
triage: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/labeler@v3 | ||
with: | ||
repo-token: "${{ secrets.GITHUB_TOKEN }}" |
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
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
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
Empty file.
45 changes: 45 additions & 0 deletions
45
erpnext/accounts/doctype/currency_exchange_settings/currency_exchange_settings.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,45 @@ | ||
// Copyright (c) 2022, Frappe Technologies Pvt. Ltd. and contributors | ||
// For license information, please see license.txt | ||
|
||
frappe.ui.form.on('Currency Exchange Settings', { | ||
service_provider: function(frm) { | ||
if (frm.doc.service_provider == "exchangerate.host") { | ||
let result = ['result']; | ||
let params = { | ||
date: '{transaction_date}', | ||
from: '{from_currency}', | ||
to: '{to_currency}' | ||
}; | ||
add_param(frm, "https://api.exchangerate.host/convert", params, result); | ||
} else if (frm.doc.service_provider == "frankfurter.app") { | ||
let result = ['rates', '{to_currency}']; | ||
let params = { | ||
base: '{from_currency}', | ||
symbols: '{to_currency}' | ||
}; | ||
add_param(frm, "https://frankfurter.app/{transaction_date}", params, result); | ||
} | ||
} | ||
}); | ||
|
||
|
||
function add_param(frm, api, params, result) { | ||
var row; | ||
frm.clear_table("req_params"); | ||
frm.clear_table("result_key"); | ||
|
||
frm.doc.api_endpoint = api; | ||
|
||
$.each(params, function(key, value) { | ||
row = frm.add_child("req_params"); | ||
row.key = key; | ||
row.value = value; | ||
}); | ||
|
||
$.each(result, function(key, value) { | ||
row = frm.add_child("result_key"); | ||
row.key = value; | ||
}); | ||
|
||
frm.refresh_fields(); | ||
} |
126 changes: 126 additions & 0 deletions
126
erpnext/accounts/doctype/currency_exchange_settings/currency_exchange_settings.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,126 @@ | ||
{ | ||
"actions": [], | ||
"creation": "2022-01-10 13:03:26.237081", | ||
"doctype": "DocType", | ||
"editable_grid": 1, | ||
"engine": "InnoDB", | ||
"field_order": [ | ||
"api_details_section", | ||
"service_provider", | ||
"api_endpoint", | ||
"url", | ||
"column_break_3", | ||
"help", | ||
"section_break_2", | ||
"req_params", | ||
"column_break_4", | ||
"result_key" | ||
], | ||
"fields": [ | ||
{ | ||
"fieldname": "api_details_section", | ||
"fieldtype": "Section Break", | ||
"label": "API Details" | ||
}, | ||
{ | ||
"fieldname": "api_endpoint", | ||
"fieldtype": "Data", | ||
"in_list_view": 1, | ||
"label": "API Endpoint", | ||
"read_only_depends_on": "eval: doc.service_provider != \"Custom\"", | ||
"reqd": 1 | ||
}, | ||
{ | ||
"fieldname": "url", | ||
"fieldtype": "Data", | ||
"label": "Example URL", | ||
"read_only": 1 | ||
}, | ||
{ | ||
"fieldname": "column_break_3", | ||
"fieldtype": "Column Break" | ||
}, | ||
{ | ||
"fieldname": "help", | ||
"fieldtype": "HTML", | ||
"label": "Help", | ||
"options": "<h3>Currency Exchange Settings Help</h3>\n<p>There are 3 variables that could be used within the endpoint, result key and in values of the parameter.</p>\n<p>Exchange rate between {from_currency} and {to_currency} on {transaction_date} is fetched by the API.</p>\n<p>Example: If your endpoint is exchange.com/2021-08-01, then, you will have to input exchange.com/{transaction_date}</p>" | ||
}, | ||
{ | ||
"fieldname": "section_break_2", | ||
"fieldtype": "Section Break", | ||
"label": "Request Parameters" | ||
}, | ||
{ | ||
"fieldname": "req_params", | ||
"fieldtype": "Table", | ||
"label": "Parameters", | ||
"options": "Currency Exchange Settings Details", | ||
"read_only_depends_on": "eval: doc.service_provider != \"Custom\"", | ||
"reqd": 1 | ||
}, | ||
{ | ||
"fieldname": "column_break_4", | ||
"fieldtype": "Column Break" | ||
}, | ||
{ | ||
"fieldname": "result_key", | ||
"fieldtype": "Table", | ||
"label": "Result Key", | ||
"options": "Currency Exchange Settings Result", | ||
"read_only_depends_on": "eval: doc.service_provider != \"Custom\"", | ||
"reqd": 1 | ||
}, | ||
{ | ||
"fieldname": "service_provider", | ||
"fieldtype": "Select", | ||
"label": "Service Provider", | ||
"options": "frankfurter.app\nexchangerate.host\nCustom", | ||
"reqd": 1 | ||
} | ||
], | ||
"index_web_pages_for_search": 1, | ||
"issingle": 1, | ||
"links": [], | ||
"modified": "2022-01-10 15:51:14.521174", | ||
"modified_by": "Administrator", | ||
"module": "Accounts", | ||
"name": "Currency Exchange Settings", | ||
"owner": "Administrator", | ||
"permissions": [ | ||
{ | ||
"create": 1, | ||
"delete": 1, | ||
"email": 1, | ||
"print": 1, | ||
"read": 1, | ||
"role": "System Manager", | ||
"share": 1, | ||
"write": 1 | ||
}, | ||
{ | ||
"create": 1, | ||
"delete": 1, | ||
"email": 1, | ||
"print": 1, | ||
"read": 1, | ||
"role": "Accounts Manager", | ||
"share": 1, | ||
"write": 1 | ||
}, | ||
{ | ||
"create": 1, | ||
"delete": 1, | ||
"email": 1, | ||
"print": 1, | ||
"read": 1, | ||
"role": "Accounts User", | ||
"share": 1, | ||
"write": 1 | ||
} | ||
], | ||
"sort_field": "modified", | ||
"sort_order": "DESC", | ||
"states": [], | ||
"track_changes": 1 | ||
} |
Oops, something went wrong.