fixed issue in stock
This commit is contained in:
parent
6610d390e1
commit
fe127c216c
@ -195,7 +195,7 @@ class DocType:
|
|||||||
"""Update workstation rate and calculates totals"""
|
"""Update workstation rate and calculates totals"""
|
||||||
total_op_cost = 0
|
total_op_cost = 0
|
||||||
for d in getlist(self.doclist, 'bom_operations'):
|
for d in getlist(self.doclist, 'bom_operations'):
|
||||||
hour_rate = sql("select hour_rate from `tabWorkstation` where name = %s", d.workstation)
|
hour_rate = sql("select hour_rate from `tabWorkstation` where name = %s", cstr(d.workstation))
|
||||||
d.hour_rate = hour_rate and flt(hour_rate[0][0]) or 0
|
d.hour_rate = hour_rate and flt(hour_rate[0][0]) or 0
|
||||||
d.operating_cost = flt(d.hour_rate) * flt(d.time_in_mins) / 60
|
d.operating_cost = flt(d.hour_rate) * flt(d.time_in_mins) / 60
|
||||||
total_op_cost += d.operating_cost
|
total_op_cost += d.operating_cost
|
||||||
|
|||||||
@ -3,9 +3,9 @@
|
|||||||
|
|
||||||
# These values are common in all dictionaries
|
# These values are common in all dictionaries
|
||||||
{
|
{
|
||||||
'creation': '2009-05-12 16:46:45',
|
'creation': '2012-04-16 15:08:16',
|
||||||
'docstatus': 0,
|
'docstatus': 0,
|
||||||
'modified': '2012-04-13 14:12:02',
|
'modified': '2012-04-16 15:54:45',
|
||||||
'modified_by': u'Administrator',
|
'modified_by': u'Administrator',
|
||||||
'owner': u'Administrator'
|
'owner': u'Administrator'
|
||||||
},
|
},
|
||||||
@ -41,7 +41,7 @@
|
|||||||
'subject': u'%(remarks)s',
|
'subject': u'%(remarks)s',
|
||||||
'tag_fields': u'purpose',
|
'tag_fields': u'purpose',
|
||||||
'use_template': 0,
|
'use_template': 0,
|
||||||
'version': 263
|
'version': 264
|
||||||
},
|
},
|
||||||
|
|
||||||
# These values are common for all DocField
|
# These values are common for all DocField
|
||||||
@ -69,18 +69,6 @@
|
|||||||
'name': u'Stock Entry'
|
'name': u'Stock Entry'
|
||||||
},
|
},
|
||||||
|
|
||||||
# DocPerm
|
|
||||||
{
|
|
||||||
'amend': 1,
|
|
||||||
'cancel': 1,
|
|
||||||
'create': 1,
|
|
||||||
'doctype': u'DocPerm',
|
|
||||||
'permlevel': 0,
|
|
||||||
'role': u'Material User',
|
|
||||||
'submit': 1,
|
|
||||||
'write': 1
|
|
||||||
},
|
|
||||||
|
|
||||||
# DocPerm
|
# DocPerm
|
||||||
{
|
{
|
||||||
'amend': 1,
|
'amend': 1,
|
||||||
@ -93,30 +81,6 @@
|
|||||||
'write': 1
|
'write': 1
|
||||||
},
|
},
|
||||||
|
|
||||||
# DocPerm
|
|
||||||
{
|
|
||||||
'amend': 1,
|
|
||||||
'cancel': 1,
|
|
||||||
'create': 1,
|
|
||||||
'doctype': u'DocPerm',
|
|
||||||
'permlevel': 0,
|
|
||||||
'role': u'Production User',
|
|
||||||
'submit': 1,
|
|
||||||
'write': 1
|
|
||||||
},
|
|
||||||
|
|
||||||
# DocPerm
|
|
||||||
{
|
|
||||||
'amend': 1,
|
|
||||||
'cancel': 1,
|
|
||||||
'create': 1,
|
|
||||||
'doctype': u'DocPerm',
|
|
||||||
'permlevel': 0,
|
|
||||||
'role': u'Production Manager',
|
|
||||||
'submit': 1,
|
|
||||||
'write': 1
|
|
||||||
},
|
|
||||||
|
|
||||||
# DocPerm
|
# DocPerm
|
||||||
{
|
{
|
||||||
'amend': 0,
|
'amend': 0,
|
||||||
@ -124,11 +88,54 @@
|
|||||||
'create': 0,
|
'create': 0,
|
||||||
'doctype': u'DocPerm',
|
'doctype': u'DocPerm',
|
||||||
'permlevel': 1,
|
'permlevel': 1,
|
||||||
'role': u'All',
|
'role': u'Material Manager',
|
||||||
'submit': 0,
|
'submit': 0,
|
||||||
'write': 0
|
'write': 0
|
||||||
},
|
},
|
||||||
|
|
||||||
|
# DocPerm
|
||||||
|
{
|
||||||
|
'amend': 1,
|
||||||
|
'cancel': 1,
|
||||||
|
'create': 1,
|
||||||
|
'doctype': u'DocPerm',
|
||||||
|
'permlevel': 0,
|
||||||
|
'role': u'Material User',
|
||||||
|
'submit': 1,
|
||||||
|
'write': 1
|
||||||
|
},
|
||||||
|
|
||||||
|
# DocPerm
|
||||||
|
{
|
||||||
|
'amend': 0,
|
||||||
|
'cancel': 0,
|
||||||
|
'create': 0,
|
||||||
|
'doctype': u'DocPerm',
|
||||||
|
'permlevel': 1,
|
||||||
|
'role': u'Material User',
|
||||||
|
'submit': 0,
|
||||||
|
'write': 0
|
||||||
|
},
|
||||||
|
|
||||||
|
# DocPerm
|
||||||
|
{
|
||||||
|
'amend': 1,
|
||||||
|
'cancel': 1,
|
||||||
|
'create': 1,
|
||||||
|
'doctype': u'DocPerm',
|
||||||
|
'permlevel': 0,
|
||||||
|
'role': u'Production User',
|
||||||
|
'submit': 1,
|
||||||
|
'write': 1
|
||||||
|
},
|
||||||
|
|
||||||
|
# DocPerm
|
||||||
|
{
|
||||||
|
'doctype': u'DocPerm',
|
||||||
|
'permlevel': 1,
|
||||||
|
'role': u'Production User'
|
||||||
|
},
|
||||||
|
|
||||||
# DocPerm
|
# DocPerm
|
||||||
{
|
{
|
||||||
'create': 0,
|
'create': 0,
|
||||||
@ -138,6 +145,25 @@
|
|||||||
'write': 1
|
'write': 1
|
||||||
},
|
},
|
||||||
|
|
||||||
|
# DocPerm
|
||||||
|
{
|
||||||
|
'amend': 1,
|
||||||
|
'cancel': 1,
|
||||||
|
'create': 1,
|
||||||
|
'doctype': u'DocPerm',
|
||||||
|
'permlevel': 0,
|
||||||
|
'role': u'Production Manager',
|
||||||
|
'submit': 1,
|
||||||
|
'write': 1
|
||||||
|
},
|
||||||
|
|
||||||
|
# DocPerm
|
||||||
|
{
|
||||||
|
'doctype': u'DocPerm',
|
||||||
|
'permlevel': 1,
|
||||||
|
'role': u'Production Manager'
|
||||||
|
},
|
||||||
|
|
||||||
# DocPerm
|
# DocPerm
|
||||||
{
|
{
|
||||||
'doctype': u'DocPerm',
|
'doctype': u'DocPerm',
|
||||||
@ -149,6 +175,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'warehouse_section',
|
||||||
'fieldtype': u'Section Break',
|
'fieldtype': u'Section Break',
|
||||||
'label': u'Warehouse',
|
'label': u'Warehouse',
|
||||||
'oldfieldtype': u'Section Break',
|
'oldfieldtype': u'Section Break',
|
||||||
@ -158,6 +185,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'col1',
|
||||||
'fieldtype': u'Column Break',
|
'fieldtype': u'Column Break',
|
||||||
'oldfieldtype': u'Column Break',
|
'oldfieldtype': u'Column Break',
|
||||||
'permlevel': 0,
|
'permlevel': 0,
|
||||||
@ -498,6 +526,7 @@
|
|||||||
{
|
{
|
||||||
'colour': u'White:FFF',
|
'colour': u'White:FFF',
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'warehouse_html',
|
||||||
'fieldtype': u'HTML',
|
'fieldtype': u'HTML',
|
||||||
'label': u'Warehouse HTML',
|
'label': u'Warehouse HTML',
|
||||||
'no_copy': 0,
|
'no_copy': 0,
|
||||||
@ -568,6 +597,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'col2',
|
||||||
'fieldtype': u'Column Break',
|
'fieldtype': u'Column Break',
|
||||||
'oldfieldtype': u'Column Break',
|
'oldfieldtype': u'Column Break',
|
||||||
'permlevel': 0,
|
'permlevel': 0,
|
||||||
@ -773,6 +803,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'items_section',
|
||||||
'fieldtype': u'Section Break',
|
'fieldtype': u'Section Break',
|
||||||
'label': u'Items',
|
'label': u'Items',
|
||||||
'oldfieldtype': u'Section Break',
|
'oldfieldtype': u'Section Break',
|
||||||
@ -782,6 +813,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'get_stock_and_rate',
|
||||||
'fieldtype': u'Button',
|
'fieldtype': u'Button',
|
||||||
'label': u'Get Stock and Rate',
|
'label': u'Get Stock and Rate',
|
||||||
'oldfieldtype': u'Button',
|
'oldfieldtype': u'Button',
|
||||||
@ -793,6 +825,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'col3',
|
||||||
'fieldtype': u'Column Break',
|
'fieldtype': u'Column Break',
|
||||||
'oldfieldtype': u'Column Break',
|
'oldfieldtype': u'Column Break',
|
||||||
'permlevel': 0
|
'permlevel': 0
|
||||||
@ -803,6 +836,7 @@
|
|||||||
'allow_on_submit': 0,
|
'allow_on_submit': 0,
|
||||||
'colour': u'White:FFF',
|
'colour': u'White:FFF',
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'get_items',
|
||||||
'fieldtype': u'Button',
|
'fieldtype': u'Button',
|
||||||
'hidden': 0,
|
'hidden': 0,
|
||||||
'in_filter': 0,
|
'in_filter': 0,
|
||||||
@ -820,6 +854,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'item_section',
|
||||||
'fieldtype': u'Section Break',
|
'fieldtype': u'Section Break',
|
||||||
'oldfieldtype': u'Section Break',
|
'oldfieldtype': u'Section Break',
|
||||||
'options': u'Simple',
|
'options': u'Simple',
|
||||||
@ -869,6 +904,7 @@
|
|||||||
# DocField
|
# DocField
|
||||||
{
|
{
|
||||||
'doctype': u'DocField',
|
'doctype': u'DocField',
|
||||||
|
'fieldname': u'other_details_section',
|
||||||
'fieldtype': u'Section Break',
|
'fieldtype': u'Section Break',
|
||||||
'label': u'Other Details',
|
'label': u'Other Details',
|
||||||
'oldfieldtype': u'Section Break',
|
'oldfieldtype': u'Section Break',
|
||||||
|
|||||||
@ -3,9 +3,9 @@
|
|||||||
|
|
||||||
# These values are common in all dictionaries
|
# These values are common in all dictionaries
|
||||||
{
|
{
|
||||||
'creation': '2012-04-03 12:49:53',
|
'creation': '2012-04-16 11:42:44',
|
||||||
'docstatus': 0,
|
'docstatus': 0,
|
||||||
'modified': '2012-04-03 12:49:53',
|
'modified': '2012-04-16 16:00:35',
|
||||||
'modified_by': u'Administrator',
|
'modified_by': u'Administrator',
|
||||||
'owner': u'Administrator'
|
'owner': u'Administrator'
|
||||||
},
|
},
|
||||||
@ -15,13 +15,16 @@
|
|||||||
'add_col': u'`tabItem`.`item_name`\n`tabItem`.`description`',
|
'add_col': u'`tabItem`.`item_name`\n`tabItem`.`description`',
|
||||||
'add_cond': u'`tabItem`.`name` = `tabStock Ledger Entry`.`item_code`',
|
'add_cond': u'`tabItem`.`name` = `tabStock Ledger Entry`.`item_code`',
|
||||||
'add_tab': u'`tabItem`',
|
'add_tab': u'`tabItem`',
|
||||||
'columns': u'Stock Ledger Entry\x01Item Code,Stock Ledger Entry\x01Warehouse,Stock Ledger Entry\x01Posting Date,Stock Ledger Entry\x01Voucher Detail No,Stock Ledger Entry\x01Actual Quantity,Stock Ledger Entry\x01Bin Actual Qty After Transaction',
|
'columns': u'Stock Ledger Entry\x01Item Code,Stock Ledger Entry\x01Warehouse,Stock Ledger Entry\x01Posting Date,Stock Ledger Entry\x01Posting Time,Stock Ledger Entry\x01Actual Quantity,Stock Ledger Entry\x01Bin Actual Qty After Transaction,Stock Ledger Entry\x01Voucher Type,Stock Ledger Entry\x01Voucher No',
|
||||||
'criteria_name': u'Stock Ledger',
|
'criteria_name': u'Stock Ledger',
|
||||||
'doc_type': u'Stock Ledger Entry',
|
'doc_type': u'Stock Ledger Entry',
|
||||||
'doctype': 'Search Criteria',
|
'doctype': 'Search Criteria',
|
||||||
'filters': u"{'Stock Ledger Entry\x01Is Cancelled':'','Stock Ledger Entry\x01Is Stock Entry':''}",
|
'filters': u'{"Stock Ledger Entry\\u0001Warehouse Type":[""],"Stock Ledger Entry\\u0001Company":[""],"Stock Ledger Entry\\u0001Is Cancelled":[""],"Stock Ledger Entry\\u0001Is Stock Entry":[""]}',
|
||||||
'module': u'Stock',
|
'module': u'Stock',
|
||||||
'name': '__common__',
|
'name': '__common__',
|
||||||
|
'page_len': 50,
|
||||||
|
'sort_by': u'`tabStock Ledger Entry`.`item_code`',
|
||||||
|
'sort_order': u'DESC',
|
||||||
'standard': u'Yes'
|
'standard': u'Yes'
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user