Merge pull request #2145 from nabinhait/hotfix

Minor fixes
This commit is contained in:
Anand Doshi 2014-09-04 15:38:00 +05:30
commit 4c93f35c2b
3 changed files with 8 additions and 7 deletions

View File

@ -24,7 +24,8 @@ class BankReconciliation(Document):
`tabJournal Voucher` t1, `tabJournal Voucher Detail` t2
where
t2.parent = t1.name and t2.account = %s
and t1.posting_date >= %s and t1.posting_date <= %s and t1.docstatus=1 %s""" %
and t1.posting_date >= %s and t1.posting_date <= %s and t1.docstatus=1
and ifnull(t1.is_opening, 'No') = 'No' %s""" %
('%s', '%s', '%s', condition), (self.bank_account, self.from_date, self.to_date), as_dict=1)
self.set('entries', [])

View File

@ -1,5 +1,5 @@
{
"allow_copy": 0,
"allow_copy": 0,
"allow_import": 1,
"allow_rename": 0,
"autoname": "naming_series:",
@ -577,7 +577,7 @@
"is_submittable": 1,
"issingle": 0,
"max_attachments": 0,
"modified": "2014-08-12 05:24:41.892586",
"modified": "2014-09-03 11:01:23.159584",
"modified_by": "Administrator",
"module": "Stock",
"name": "Stock Entry",
@ -644,7 +644,7 @@
],
"read_only": 0,
"read_only_onload": 0,
"search_fields": "transfer_date, from_warehouse, to_warehouse, purpose, remarks",
"search_fields": "posting_date, from_warehouse, to_warehouse, purpose, remarks",
"sort_field": "modified",
"sort_order": "DESC"
}

View File

@ -243,12 +243,12 @@ class StockEntry(StockController):
d.incoming_rate = incoming_rate
d.amount = flt(d.transfer_qty) * flt(d.incoming_rate)
raw_material_cost += flt(d.amount)
if not d.t_warehouse:
raw_material_cost += flt(d.amount)
# set incoming rate for fg item
if self.purpose == "Manufacture/Repack":
number_of_fg_items = len([t.t_warehouse for t in self.get("mtn_details")])
number_of_fg_items = len([t.t_warehouse for t in self.get("mtn_details") if t.t_warehouse])
for d in self.get("mtn_details"):
if d.bom_no or (d.t_warehouse and number_of_fg_items == 1):
if not flt(d.incoming_rate) or force: