mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-19 13:09:17 +00:00
Merge branch 'develop'
This commit is contained in:
@@ -1,2 +1,2 @@
|
|||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
__version__ = '5.0.17'
|
__version__ = '5.0.18'
|
||||||
|
|||||||
@@ -2,6 +2,10 @@
|
|||||||
// License: GNU General Public License v3. See license.txt
|
// License: GNU General Public License v3. See license.txt
|
||||||
|
|
||||||
frappe.ui.form.on("Bank Reconciliation", {
|
frappe.ui.form.on("Bank Reconciliation", {
|
||||||
|
refresh: function(frm) {
|
||||||
|
frm.disable_save();
|
||||||
|
},
|
||||||
|
|
||||||
update_clearance_date: function(frm) {
|
update_clearance_date: function(frm) {
|
||||||
return frappe.call({
|
return frappe.call({
|
||||||
method: "update_details",
|
method: "update_details",
|
||||||
@@ -34,4 +38,3 @@ cur_frm.cscript.onload = function(doc, cdt, cdn) {
|
|||||||
cur_frm.set_value("from_date", frappe.datetime.month_start());
|
cur_frm.set_value("from_date", frappe.datetime.month_start());
|
||||||
cur_frm.set_value("to_date", frappe.datetime.month_end());
|
cur_frm.set_value("to_date", frappe.datetime.month_end());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -25,7 +25,8 @@ class BankReconciliation(Document):
|
|||||||
where
|
where
|
||||||
t2.parent = t1.name and t2.account = %s
|
t2.parent = t1.name and t2.account = %s
|
||||||
and t1.posting_date >= %s and t1.posting_date <= %s and t1.docstatus=1
|
and t1.posting_date >= %s and t1.posting_date <= %s and t1.docstatus=1
|
||||||
and ifnull(t1.is_opening, 'No') = 'No' %s""" %
|
and ifnull(t1.is_opening, 'No') = 'No' %s
|
||||||
|
order by t1.posting_date""" %
|
||||||
('%s', '%s', '%s', condition), (self.bank_account, self.from_date, self.to_date), as_dict=1)
|
('%s', '%s', '%s', condition), (self.bank_account, self.from_date, self.to_date), as_dict=1)
|
||||||
|
|
||||||
self.set('journal_entries', [])
|
self.set('journal_entries', [])
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
import frappe
|
import frappe
|
||||||
from frappe.utils import cstr, flt, fmt_money, formatdate, getdate, cint
|
from frappe.utils import cstr, flt, fmt_money, formatdate, getdate
|
||||||
from frappe import msgprint, _, scrub
|
from frappe import msgprint, _, scrub
|
||||||
from erpnext.setup.utils import get_company_currency
|
from erpnext.setup.utils import get_company_currency
|
||||||
from erpnext.controllers.accounts_controller import AccountsController
|
from erpnext.controllers.accounts_controller import AccountsController
|
||||||
@@ -428,12 +428,11 @@ class JournalEntry(AccountsController):
|
|||||||
def validate_expense_claim(self):
|
def validate_expense_claim(self):
|
||||||
for d in self.accounts:
|
for d in self.accounts:
|
||||||
if d.against_expense_claim:
|
if d.against_expense_claim:
|
||||||
sanctioned_amount, reimbursed_amount = frappe.db.get_value("Expense Claim", d.against_expense_claim,
|
sanctioned_amount, reimbursed_amount = frappe.db.get_value("Expense Claim",
|
||||||
("total_sanctioned_amount", "total_amount_reimbursed"))
|
d.against_expense_claim, ("total_sanctioned_amount", "total_amount_reimbursed"))
|
||||||
pending_amount = cint(sanctioned_amount) - cint(reimbursed_amount)
|
pending_amount = flt(sanctioned_amount) - flt(reimbursed_amount)
|
||||||
if d.debit > pending_amount:
|
if d.debit > pending_amount:
|
||||||
frappe.throw(_("Row No {0}: Amount cannot be greater than Pending Amount against Expense Claim {1}. \
|
frappe.throw(_("Row No {0}: Amount cannot be greater than Pending Amount against Expense Claim {1}. Pending Amount is {2}".format(d.idx, d.against_expense_claim, pending_amount)))
|
||||||
Pending Amount is {2}".format(d.idx, d.against_expense_claim, pending_amount)))
|
|
||||||
|
|
||||||
def validate_credit_debit_note(self):
|
def validate_credit_debit_note(self):
|
||||||
if self.stock_entry:
|
if self.stock_entry:
|
||||||
|
|||||||
@@ -45,6 +45,10 @@ erpnext.accounts.PaymentReconciliationController = frappe.ui.form.Controller.ext
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
refresh: function() {
|
||||||
|
this.frm.disable_save();
|
||||||
|
},
|
||||||
|
|
||||||
party: function() {
|
party: function() {
|
||||||
var me = this
|
var me = this
|
||||||
if(!me.frm.doc.receivable_payable_account && me.frm.doc.party_type && me.frm.doc.party) {
|
if(!me.frm.doc.receivable_payable_account && me.frm.doc.party_type && me.frm.doc.party) {
|
||||||
|
|||||||
@@ -32,6 +32,7 @@ frappe.ui.form.on("Payment Tool", "onload", function(frm) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
frappe.ui.form.on("Payment Tool", "refresh", function(frm) {
|
frappe.ui.form.on("Payment Tool", "refresh", function(frm) {
|
||||||
|
frm.disable_save();
|
||||||
frappe.ui.form.trigger("Payment Tool", "party_type");
|
frappe.ui.form.trigger("Payment Tool", "party_type");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -312,7 +312,7 @@
|
|||||||
"is_submittable": 0,
|
"is_submittable": 0,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"istable": 0,
|
"istable": 0,
|
||||||
"modified": "2015-02-21 03:59:08.154966",
|
"modified": "2015-06-05 11:17:33.843334",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Accounts",
|
"module": "Accounts",
|
||||||
"name": "Payment Tool",
|
"name": "Payment Tool",
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
<button class="btn btn-primary btn-lg">{%= __("Start") %}</button>
|
<button class="btn btn-primary btn-lg">{%= __("Start") %}</button>
|
||||||
</p>
|
</p>
|
||||||
<p class="pos-setting-message hide">
|
<p class="pos-setting-message hide">
|
||||||
<a class="btn btn-default btn-sm" href="#Form/POS Setting/New POS Setting">
|
<a class="btn btn-default btn-sm" href="#Form/POS Profile/New POS Profile">
|
||||||
{%= __("Make new POS Setting") %}</a>
|
{%= __("Make new POS Profile") %}</a>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ def execute(filters=None):
|
|||||||
source = gross_profit_data.grouped_data if filters.get("group_by") != "Invoice" else gross_profit_data.data
|
source = gross_profit_data.grouped_data if filters.get("group_by") != "Invoice" else gross_profit_data.data
|
||||||
|
|
||||||
group_wise_columns = frappe._dict({
|
group_wise_columns = frappe._dict({
|
||||||
"invoice": ["parent", "posting_date", "posting_time", "item_code", "item_name", "brand", "description", \
|
"invoice": ["parent", "customer", "posting_date", "posting_time", "item_code", "item_name", "brand", "description", \
|
||||||
"warehouse", "qty", "base_rate", "buying_rate", "base_amount",
|
"warehouse", "qty", "base_rate", "buying_rate", "base_amount",
|
||||||
"buying_amount", "gross_profit", "gross_profit_percent", "project"],
|
"buying_amount", "gross_profit", "gross_profit_percent", "project"],
|
||||||
"item_code": ["item_code", "item_name", "brand", "description", "warehouse", "qty", "base_rate",
|
"item_code": ["item_code", "item_name", "brand", "description", "warehouse", "qty", "base_rate",
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ app_publisher = "Frappe Technologies Pvt. Ltd. and Contributors"
|
|||||||
app_description = "Open Source Enterprise Resource Planning for Small and Midsized Organizations"
|
app_description = "Open Source Enterprise Resource Planning for Small and Midsized Organizations"
|
||||||
app_icon = "icon-th"
|
app_icon = "icon-th"
|
||||||
app_color = "#e74c3c"
|
app_color = "#e74c3c"
|
||||||
app_version = "5.0.17"
|
app_version = "5.0.18"
|
||||||
|
|
||||||
error_report_email = "support@erpnext.com"
|
error_report_email = "support@erpnext.com"
|
||||||
|
|
||||||
|
|||||||
@@ -25,3 +25,7 @@ cur_frm.cscript.allocation_type = function (doc, cdt, cdn){
|
|||||||
doc.no_of_days = '';
|
doc.no_of_days = '';
|
||||||
refresh_field('no_of_days');
|
refresh_field('no_of_days');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
frappe.ui.form.on("Leave Control Panel", "refresh", function(frm) {
|
||||||
|
frm.disable_save();
|
||||||
|
});
|
||||||
@@ -94,11 +94,11 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"hide_heading": 0,
|
"hide_heading": 0,
|
||||||
"hide_toolbar": 0,
|
"hide_toolbar": 1,
|
||||||
"icon": "icon-cog",
|
"icon": "icon-cog",
|
||||||
"idx": 1,
|
"idx": 1,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"modified": "2015-02-05 05:11:40.791976",
|
"modified": "2015-06-05 11:38:19.994852",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "HR",
|
"module": "HR",
|
||||||
"name": "Leave Control Panel",
|
"name": "Leave Control Panel",
|
||||||
@@ -110,7 +110,7 @@
|
|||||||
"read": 1,
|
"read": 1,
|
||||||
"report": 0,
|
"report": 0,
|
||||||
"role": "HR User",
|
"role": "HR User",
|
||||||
"share": 1,
|
"share": 0,
|
||||||
"submit": 0,
|
"submit": 0,
|
||||||
"write": 1
|
"write": 1
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -43,3 +43,8 @@ cur_frm.cscript.make_jv = function(doc, dt, dn) {
|
|||||||
frappe.set_route("Form", doc.doctype, doc.name);
|
frappe.set_route("Form", doc.doctype, doc.name);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
frappe.ui.form.on("Salary Manager", "refresh", function(frm) {
|
||||||
|
frm.disable_save();
|
||||||
|
});
|
||||||
@@ -150,10 +150,11 @@
|
|||||||
"permlevel": 0
|
"permlevel": 0
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"hide_toolbar": 1,
|
||||||
"icon": "icon-cog",
|
"icon": "icon-cog",
|
||||||
"idx": 1,
|
"idx": 1,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"modified": "2015-02-25 07:21:04.778082",
|
"modified": "2015-06-05 11:33:00.152362",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "HR",
|
"module": "HR",
|
||||||
"name": "Salary Manager",
|
"name": "Salary Manager",
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ erpnext.hr.AttendanceControlPanel = frappe.ui.form.Controller.extend({
|
|||||||
},
|
},
|
||||||
|
|
||||||
refresh: function() {
|
refresh: function() {
|
||||||
|
this.frm.disable_save();
|
||||||
this.show_upload();
|
this.show_upload();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
{
|
{
|
||||||
|
"allow_copy": 1,
|
||||||
"creation": "2013-01-25 11:34:53",
|
"creation": "2013-01-25 11:34:53",
|
||||||
"docstatus": 0,
|
"docstatus": 0,
|
||||||
"doctype": "DocType",
|
"doctype": "DocType",
|
||||||
@@ -53,11 +54,13 @@
|
|||||||
"permlevel": 0
|
"permlevel": 0
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"hide_heading": 0,
|
||||||
|
"hide_toolbar": 1,
|
||||||
"icon": "icon-upload-alt",
|
"icon": "icon-upload-alt",
|
||||||
"idx": 1,
|
"idx": 1,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"max_attachments": 1,
|
"max_attachments": 1,
|
||||||
"modified": "2015-02-05 05:11:48.540845",
|
"modified": "2015-06-05 11:37:04.348120",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "HR",
|
"module": "HR",
|
||||||
"name": "Upload Attendance",
|
"name": "Upload Attendance",
|
||||||
@@ -65,25 +68,25 @@
|
|||||||
"permissions": [
|
"permissions": [
|
||||||
{
|
{
|
||||||
"create": 1,
|
"create": 1,
|
||||||
"email": 1,
|
"email": 0,
|
||||||
"permlevel": 0,
|
"permlevel": 0,
|
||||||
"print": 1,
|
"print": 0,
|
||||||
"read": 1,
|
"read": 1,
|
||||||
"report": 0,
|
"report": 0,
|
||||||
"role": "HR User",
|
"role": "HR User",
|
||||||
"share": 1,
|
"share": 0,
|
||||||
"submit": 0,
|
"submit": 0,
|
||||||
"write": 1
|
"write": 1
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"create": 1,
|
"create": 1,
|
||||||
"email": 1,
|
"email": 0,
|
||||||
"permlevel": 0,
|
"permlevel": 0,
|
||||||
"print": 1,
|
"print": 0,
|
||||||
"read": 1,
|
"read": 1,
|
||||||
"report": 0,
|
"report": 0,
|
||||||
"role": "HR Manager",
|
"role": "HR Manager",
|
||||||
"share": 1,
|
"share": 0,
|
||||||
"submit": 0,
|
"submit": 0,
|
||||||
"write": 1
|
"write": 1
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
{
|
{
|
||||||
|
"allow_copy": 1,
|
||||||
"creation": "2013-01-21 12:03:47",
|
"creation": "2013-01-21 12:03:47",
|
||||||
"default_print_format": "Standard",
|
"default_print_format": "Standard",
|
||||||
"docstatus": 0,
|
"docstatus": 0,
|
||||||
@@ -154,11 +155,12 @@
|
|||||||
"permlevel": 0
|
"permlevel": 0
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"hide_toolbar": 1,
|
||||||
"icon": "icon-calendar",
|
"icon": "icon-calendar",
|
||||||
"idx": 1,
|
"idx": 1,
|
||||||
"in_create": 1,
|
"in_create": 1,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"modified": "2015-02-05 05:11:43.010625",
|
"modified": "2015-06-05 11:44:31.629114",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Manufacturing",
|
"module": "Manufacturing",
|
||||||
"name": "Production Planning Tool",
|
"name": "Production Planning Tool",
|
||||||
|
|||||||
@@ -163,3 +163,5 @@ execute:frappe.db.sql_list("delete from `tabDocPerm` where parent='Issue' and mo
|
|||||||
erpnext.patches.v5_0.update_item_and_description_again
|
erpnext.patches.v5_0.update_item_and_description_again
|
||||||
erpnext.patches.v5_0.repost_gle_for_jv_with_multiple_party
|
erpnext.patches.v5_0.repost_gle_for_jv_with_multiple_party
|
||||||
erpnext.patches.v5_0.portal_fixes
|
erpnext.patches.v5_0.portal_fixes
|
||||||
|
erpnext.patches.v5_0.reset_values_in_tools
|
||||||
|
execute:frappe.delete_doc("Page", "users")
|
||||||
11
erpnext/patches/v5_0/reset_values_in_tools.py
Normal file
11
erpnext/patches/v5_0/reset_values_in_tools.py
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
# Copyright (c) 2013, Frappe Technologies Pvt. Ltd. and Contributors
|
||||||
|
# License: GNU General Public License v3. See license.txt
|
||||||
|
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
import frappe
|
||||||
|
|
||||||
|
def execute():
|
||||||
|
for dt in ["Payment Tool", "Bank Reconciliation", "Payment Reconciliation", "Leave Control Panel",
|
||||||
|
"Salary Manager", "Upload Attenadance", "Production Planning Tool", "BOM Replace Tool"]:
|
||||||
|
frappe.db.sql("delete from `tabSingles` where doctype=%s", dt)
|
||||||
|
|
||||||
@@ -195,8 +195,6 @@ class TimeLog(Document):
|
|||||||
if self.for_manufacturing:
|
if self.for_manufacturing:
|
||||||
if not self.production_order:
|
if not self.production_order:
|
||||||
frappe.throw(_("Production Order is Mandatory"))
|
frappe.throw(_("Production Order is Mandatory"))
|
||||||
if not self.operation:
|
|
||||||
frappe.throw(_("Operation is Mandatory"))
|
|
||||||
if not self.completed_qty:
|
if not self.completed_qty:
|
||||||
self.completed_qty = 0
|
self.completed_qty = 0
|
||||||
|
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ class TestItem(unittest.TestCase):
|
|||||||
"income_account": "Sales - _TC",
|
"income_account": "Sales - _TC",
|
||||||
"expense_account": "_Test Account Cost for Goods Sold - _TC",
|
"expense_account": "_Test Account Cost for Goods Sold - _TC",
|
||||||
"cost_center": "_Test Cost Center 2 - _TC",
|
"cost_center": "_Test Cost Center 2 - _TC",
|
||||||
"qty": 0.0,
|
"qty": 1.0,
|
||||||
"price_list_rate": 100.0,
|
"price_list_rate": 100.0,
|
||||||
"base_price_list_rate": 0.0,
|
"base_price_list_rate": 0.0,
|
||||||
"discount_percentage": 0.0,
|
"discount_percentage": 0.0,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% $.each(visible_columns || [], function(i, df) { %}
|
{% $.each(visible_columns || [], function(i, df) { %}
|
||||||
{% var val = doc.get_formatted(df.fieldname);
|
{% var val = doc.get_formatted(df.fieldname);
|
||||||
if(val) { %}
|
if((df.fieldname !== "description") && val) { %}
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-xs-4 text-ellipsis">
|
<div class="col-xs-4 text-ellipsis">
|
||||||
<strong title="{%= __(df.label) %}">{%= __(df.label) %}:</strong>
|
<strong title="{%= __(df.label) %}">{%= __(df.label) %}:</strong>
|
||||||
|
|||||||
@@ -47,6 +47,12 @@
|
|||||||
|
|
||||||
{% if(doc.item_name != doc.item_code) { %}
|
{% if(doc.item_name != doc.item_code) { %}
|
||||||
<br>{%= doc.item_name %}{% } %}
|
<br>{%= doc.item_name %}{% } %}
|
||||||
|
|
||||||
|
{% if((doc.description != doc.item_code != doc.item_name) &&
|
||||||
|
in_list($.map(visible_columns, function(x, i) {return x.fieldname}), "description")) { %}
|
||||||
|
<br>
|
||||||
|
<strong>Description: </strong>
|
||||||
|
{%= doc.get_formatted("description") %}{% } %}
|
||||||
{% include "templates/form_grid/includes/visible_cols.html" %}
|
{% include "templates/form_grid/includes/visible_cols.html" %}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
2
setup.py
2
setup.py
@@ -1,6 +1,6 @@
|
|||||||
from setuptools import setup, find_packages
|
from setuptools import setup, find_packages
|
||||||
|
|
||||||
version = "5.0.17"
|
version = "5.0.18"
|
||||||
|
|
||||||
with open("requirements.txt", "r") as f:
|
with open("requirements.txt", "r") as f:
|
||||||
install_requires = f.readlines()
|
install_requires = f.readlines()
|
||||||
|
|||||||
Reference in New Issue
Block a user