resolved merge conflicts
This commit is contained in:
commit
2e7a45dbb4
@ -5,7 +5,7 @@ import frappe
|
|||||||
from erpnext.hooks import regional_overrides
|
from erpnext.hooks import regional_overrides
|
||||||
from frappe.utils import getdate
|
from frappe.utils import getdate
|
||||||
|
|
||||||
__version__ = '10.1.23'
|
__version__ = '10.1.24'
|
||||||
|
|
||||||
def get_default_company(user=None):
|
def get_default_company(user=None):
|
||||||
'''Get default company for user'''
|
'''Get default company for user'''
|
||||||
|
@ -71,7 +71,7 @@ frappe.treeview_settings["Account"] = {
|
|||||||
|
|
||||||
// financial statements
|
// financial statements
|
||||||
for (let report of ['Trial Balance', 'General Ledger', 'Balance Sheet',
|
for (let report of ['Trial Balance', 'General Ledger', 'Balance Sheet',
|
||||||
'Profit and Loss', 'Cash Flow Statement', 'Accounts Payable', 'Accounts Receivable']) {
|
'Profit and Loss Statement', 'Cash Flow Statement', 'Accounts Payable', 'Accounts Receivable']) {
|
||||||
treeview.page.add_inner_button(__(report), function() {
|
treeview.page.add_inner_button(__(report), function() {
|
||||||
frappe.set_route('query-report', report, {company: get_company()});
|
frappe.set_route('query-report', report, {company: get_company()});
|
||||||
}, __('Financial Statements'));
|
}, __('Financial Statements'));
|
||||||
|
@ -165,7 +165,7 @@ def build_account_tree(tree, parent, all_accounts):
|
|||||||
tree[child.account_name] = {}
|
tree[child.account_name] = {}
|
||||||
|
|
||||||
# assign account_type and root_type
|
# assign account_type and root_type
|
||||||
if child.account_type:
|
if child.account_number:
|
||||||
tree[child.account_name]["account_number"] = child.account_number
|
tree[child.account_name]["account_number"] = child.account_number
|
||||||
if child.account_type:
|
if child.account_type:
|
||||||
tree[child.account_name]["account_type"] = child.account_type
|
tree[child.account_name]["account_type"] = child.account_type
|
||||||
|
@ -29,11 +29,11 @@ def create_or_update_cheque_print_format(template_name):
|
|||||||
cheque_print.html = """
|
cheque_print.html = """
|
||||||
<div style="position: relative; top:%(starting_position_from_top_edge)scm">
|
<div style="position: relative; top:%(starting_position_from_top_edge)scm">
|
||||||
<div style="width:%(cheque_width)scm;height:%(cheque_height)scm;">
|
<div style="width:%(cheque_width)scm;height:%(cheque_height)scm;">
|
||||||
<span style="top: {{ %(acc_pay_dist_from_top_edge)s }}cm; left: {{ %(acc_pay_dist_from_left_edge)s }}cm;
|
<span style="top:%(acc_pay_dist_from_top_edge)scm; left:%(acc_pay_dist_from_left_edge)scm;
|
||||||
border-bottom: solid 1px;border-top:solid 1px; position: absolute;">
|
border-bottom: solid 1px;border-top:solid 1px; position: absolute;">
|
||||||
%(message_to_show)s
|
%(message_to_show)s
|
||||||
</span>
|
</span>
|
||||||
<span style="top:%(date_dist_from_top_edge)s cm; left:%(date_dist_from_left_edge)scm;
|
<span style="top:%(date_dist_from_top_edge)scm; left:%(date_dist_from_left_edge)scm;
|
||||||
position: absolute;">
|
position: absolute;">
|
||||||
{{ frappe.utils.formatdate(doc.reference_date) or '' }}
|
{{ frappe.utils.formatdate(doc.reference_date) or '' }}
|
||||||
</span>
|
</span>
|
||||||
|
@ -4,7 +4,7 @@ We can also send the feedback request to Customer/User without configuring the
|
|||||||
Feedback Trigger.
|
Feedback Trigger.
|
||||||
|
|
||||||
To request a feedback manually go to respective document e.g. Sales Order, Issue etc.
|
To request a feedback manually go to respective document e.g. Sales Order, Issue etc.
|
||||||
and click on Ask a Feedback option in Menu.
|
and click on Request Feedback option in Menu.
|
||||||
|
|
||||||
<img class="screenshot" alt="Setting Condition" src="{{docs_base_url}}/assets/img/setup/feedback/manual-feedback-request-option.png">
|
<img class="screenshot" alt="Setting Condition" src="{{docs_base_url}}/assets/img/setup/feedback/manual-feedback-request-option.png">
|
||||||
|
|
||||||
|
@ -82,6 +82,8 @@ frappe.ui.form.on("Student Group", {
|
|||||||
max_roll_no = d.group_roll_number;
|
max_roll_no = d.group_roll_number;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if(frm.doc.academic_year) {
|
||||||
frappe.call({
|
frappe.call({
|
||||||
method: "erpnext.education.doctype.student_group.student_group.get_students",
|
method: "erpnext.education.doctype.student_group.student_group.get_students",
|
||||||
args: {
|
args: {
|
||||||
@ -112,6 +114,7 @@ frappe.ui.form.on("Student Group", {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
frappe.msgprint(__("Select students manually for the Activity based Group"));
|
frappe.msgprint(__("Select students manually for the Activity based Group"));
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
|
|
||||||
frappe.views.calendar["Patient Appointment"] = {
|
frappe.views.calendar["Patient Appointment"] = {
|
||||||
field_map: {
|
field_map: {
|
||||||
"start": "start",
|
"start": "appointment_date",
|
||||||
"end": "end",
|
"end": "appointment_datetime",
|
||||||
"id": "name",
|
"id": "name",
|
||||||
"title": "patient",
|
"title": "patient",
|
||||||
"allDay": "allDay",
|
"allDay": "allDay",
|
||||||
|
@ -3,8 +3,8 @@
|
|||||||
|
|
||||||
frappe.views.calendar["Holiday List"] = {
|
frappe.views.calendar["Holiday List"] = {
|
||||||
field_map: {
|
field_map: {
|
||||||
"start": "holiday_date",
|
"start": "from_date",
|
||||||
"end": "holiday_date",
|
"end": "to_date",
|
||||||
"id": "name",
|
"id": "name",
|
||||||
"title": "description",
|
"title": "description",
|
||||||
"allDay": "allDay"
|
"allDay": "allDay"
|
||||||
|
@ -816,7 +816,7 @@ class POSCart {
|
|||||||
});
|
});
|
||||||
this.numpad.reset_value();
|
this.numpad.reset_value();
|
||||||
} else {
|
} else {
|
||||||
const item_code = this.selected_item.attr('data-item-code');
|
const item_code = unescape(this.selected_item.attr('data-item-code'));
|
||||||
const batch_no = this.selected_item.attr('data-batch-no');
|
const batch_no = this.selected_item.attr('data-batch-no');
|
||||||
const field = this.selected_item.active_field;
|
const field = this.selected_item.active_field;
|
||||||
const value = this.numpad.get_value();
|
const value = this.numpad.get_value();
|
||||||
@ -863,7 +863,7 @@ class POSCart {
|
|||||||
|
|
||||||
update_item(item) {
|
update_item(item) {
|
||||||
const item_selector = item.batch_no ?
|
const item_selector = item.batch_no ?
|
||||||
`[data-batch-no="${item.batch_no}"]` : `[data-item-code="${item.item_code}"]`;
|
`[data-batch-no="${item.batch_no}"]` : `[data-item-code="${escape(item.item_code)}"]`;
|
||||||
|
|
||||||
const $item = this.$cart_items.find(item_selector);
|
const $item = this.$cart_items.find(item_selector);
|
||||||
|
|
||||||
@ -889,7 +889,7 @@ class POSCart {
|
|||||||
const batch_no = item.batch_no || '';
|
const batch_no = item.batch_no || '';
|
||||||
|
|
||||||
return `
|
return `
|
||||||
<div class="list-item indicator ${indicator_class}" data-item-code="${item.item_code}"
|
<div class="list-item indicator ${indicator_class}" data-item-code="${escape(item.item_code)}"
|
||||||
data-batch-no="${batch_no}" title="Item: ${item.item_name} Available Qty: ${item.actual_qty}">
|
data-batch-no="${batch_no}" title="Item: ${item.item_name} Available Qty: ${item.actual_qty}">
|
||||||
<div class="item-name list-item__content list-item__content--flex-1.5 ellipsis">
|
<div class="item-name list-item__content list-item__content--flex-1.5 ellipsis">
|
||||||
${item.item_name}
|
${item.item_name}
|
||||||
@ -933,20 +933,21 @@ class POSCart {
|
|||||||
|
|
||||||
exists(item_code, batch_no) {
|
exists(item_code, batch_no) {
|
||||||
const is_exists = batch_no ?
|
const is_exists = batch_no ?
|
||||||
`[data-batch-no="${batch_no}"]` : `[data-item-code="${item_code}"]`;
|
`[data-batch-no="${batch_no}"]` : `[data-item-code="${escape(item_code)}"]`;
|
||||||
|
|
||||||
let $item = this.$cart_items.find(is_exists);
|
let $item = this.$cart_items.find(is_exists);
|
||||||
|
|
||||||
return $item.length > 0;
|
return $item.length > 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
highlight_item(item_code) {
|
highlight_item(item_code) {
|
||||||
const $item = this.$cart_items.find(`[data-item-code="${item_code}"]`);
|
const $item = this.$cart_items.find(`[data-item-code="${escape(item_code)}"]`);
|
||||||
$item.addClass('highlight');
|
$item.addClass('highlight');
|
||||||
setTimeout(() => $item.removeClass('highlight'), 1000);
|
setTimeout(() => $item.removeClass('highlight'), 1000);
|
||||||
}
|
}
|
||||||
|
|
||||||
scroll_to_item(item_code) {
|
scroll_to_item(item_code) {
|
||||||
const $item = this.$cart_items.find(`[data-item-code="${item_code}"]`);
|
const $item = this.$cart_items.find(`[data-item-code="${escape(item_code)}"]`);
|
||||||
if ($item.length === 0) return;
|
if ($item.length === 0) return;
|
||||||
const scrollTop = $item.offset().top - this.$cart_items.offset().top + this.$cart_items.scrollTop();
|
const scrollTop = $item.offset().top - this.$cart_items.offset().top + this.$cart_items.scrollTop();
|
||||||
this.$cart_items.animate({ scrollTop });
|
this.$cart_items.animate({ scrollTop });
|
||||||
@ -961,7 +962,7 @@ class POSCart {
|
|||||||
'[data-action="increment"], [data-action="decrement"]', function() {
|
'[data-action="increment"], [data-action="decrement"]', function() {
|
||||||
const $btn = $(this);
|
const $btn = $(this);
|
||||||
const $item = $btn.closest('.list-item[data-item-code]');
|
const $item = $btn.closest('.list-item[data-item-code]');
|
||||||
const item_code = $item.attr('data-item-code');
|
const item_code = unescape($item.attr('data-item-code'));
|
||||||
const action = $btn.attr('data-action');
|
const action = $btn.attr('data-action');
|
||||||
|
|
||||||
if(action === 'increment') {
|
if(action === 'increment') {
|
||||||
@ -984,7 +985,7 @@ class POSCart {
|
|||||||
this.$cart_items.on('change', '.quantity input', function() {
|
this.$cart_items.on('change', '.quantity input', function() {
|
||||||
const $input = $(this);
|
const $input = $(this);
|
||||||
const $item = $input.closest('.list-item[data-item-code]');
|
const $item = $input.closest('.list-item[data-item-code]');
|
||||||
const item_code = $item.attr('data-item-code');
|
const item_code = unescape($item.attr('data-item-code'));
|
||||||
events.on_field_change(item_code, 'qty', flt($input.val()));
|
events.on_field_change(item_code, 'qty', flt($input.val()));
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -1252,7 +1253,7 @@ class POSItems {
|
|||||||
var me = this;
|
var me = this;
|
||||||
this.wrapper.on('click', '.pos-item-wrapper', function() {
|
this.wrapper.on('click', '.pos-item-wrapper', function() {
|
||||||
const $item = $(this);
|
const $item = $(this);
|
||||||
const item_code = $item.attr('data-item-code');
|
const item_code = unescape($item.attr('data-item-code'));
|
||||||
me.events.update_cart(item_code, 'qty', '+1');
|
me.events.update_cart(item_code, 'qty', '+1');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -1278,7 +1279,7 @@ class POSItems {
|
|||||||
const item_title = item_name || item_code;
|
const item_title = item_name || item_code;
|
||||||
|
|
||||||
const template = `
|
const template = `
|
||||||
<div class="pos-item-wrapper image-view-item" data-item-code="${item_code}">
|
<div class="pos-item-wrapper image-view-item" data-item-code="${escape(item_code)}">
|
||||||
<div class="image-view-header">
|
<div class="image-view-header">
|
||||||
<div>
|
<div>
|
||||||
<a class="grey list-id" data-name="${item_code}" title="${item_title}">
|
<a class="grey list-id" data-name="${item_code}" title="${item_title}">
|
||||||
|
@ -203,6 +203,7 @@ def get_item_details(items, sle, filters):
|
|||||||
if not items:
|
if not items:
|
||||||
items = list(set([d.item_code for d in sle]))
|
items = list(set([d.item_code for d in sle]))
|
||||||
|
|
||||||
|
if items:
|
||||||
for item in frappe.db.sql("""
|
for item in frappe.db.sql("""
|
||||||
select name, item_name, description, item_group, brand, stock_uom
|
select name, item_name, description, item_group, brand, stock_uom
|
||||||
from `tabItem`
|
from `tabItem`
|
||||||
@ -217,6 +218,9 @@ def get_item_details(items, sle, filters):
|
|||||||
return item_details
|
return item_details
|
||||||
|
|
||||||
def get_item_reorder_details(items):
|
def get_item_reorder_details(items):
|
||||||
|
item_reorder_details = frappe._dict()
|
||||||
|
|
||||||
|
if items:
|
||||||
item_reorder_details = frappe.db.sql("""
|
item_reorder_details = frappe.db.sql("""
|
||||||
select parent, warehouse, warehouse_reorder_qty, warehouse_reorder_level
|
select parent, warehouse, warehouse_reorder_qty, warehouse_reorder_level
|
||||||
from `tabItem Reorder`
|
from `tabItem Reorder`
|
||||||
|
@ -93,11 +93,14 @@ def get_item_details(items, sl_entries):
|
|||||||
if not items:
|
if not items:
|
||||||
items = list(set([d.item_code for d in sl_entries]))
|
items = list(set([d.item_code for d in sl_entries]))
|
||||||
|
|
||||||
|
if not items:
|
||||||
|
return item_details
|
||||||
|
|
||||||
for item in frappe.db.sql("""
|
for item in frappe.db.sql("""
|
||||||
select name, item_name, description, item_group, brand, stock_uom
|
select name, item_name, description, item_group, brand, stock_uom
|
||||||
from `tabItem`
|
from `tabItem`
|
||||||
where name in ({0})
|
where name in ({0})
|
||||||
""".format(', '.join(['"' + frappe.db.escape(i,percent=False) + '"' for i in items])), as_dict=1):
|
""".format(', '.join(['"' + frappe.db.escape(i,percent=False) + '"' for i in items])), as_dict=1, debug=1):
|
||||||
item_details.setdefault(item.name, item)
|
item_details.setdefault(item.name, item)
|
||||||
|
|
||||||
return item_details
|
return item_details
|
||||||
|
@ -24,7 +24,7 @@ frappe.Leaderboard = Class.extend({
|
|||||||
"Item": ["total_sales_amount", "total_qty_sold", "total_purchase_amount",
|
"Item": ["total_sales_amount", "total_qty_sold", "total_purchase_amount",
|
||||||
"total_qty_purchased", "available_stock_qty", "available_stock_value"],
|
"total_qty_purchased", "available_stock_qty", "available_stock_value"],
|
||||||
"Supplier": ["total_purchase_amount", "total_qty_purchased", "outstanding_amount"],
|
"Supplier": ["total_purchase_amount", "total_qty_purchased", "outstanding_amount"],
|
||||||
"Sales Partner": ["total_sales_amount", "total_commision"],
|
"Sales Partner": ["total_sales_amount", "total_commission"],
|
||||||
"Sales Person": ["total_sales_amount"],
|
"Sales Person": ["total_sales_amount"],
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user