[Serial No] Major updates, code cleanup, "In Store" is now "Available". Serial No can only be created via Stock Entry / Purchase Receipt. Serial No can be auto created using Series if mentioned in Item master

This commit is contained in:
Rushabh Mehta
2013-08-14 18:37:28 +05:30
parent ffe64db8f7
commit 62030e05cc
30 changed files with 686 additions and 656 deletions

View File

@@ -1,10 +0,0 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd.
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
def execute():
import webnotes
from webnotes.modules import reload_doc
reload_doc('stock', 'doctype', 'serial_no')
webnotes.conn.sql("update `tabSerial No` set sle_exists = 1")

View File

@@ -0,0 +1,5 @@
import webnotes
def execute():
webnotes.conn.sql("""update `tabSerial No` set status = 'Not Available' where status='Not In Store'""")
webnotes.conn.sql("""update `tabSerial No` set status = 'Available' where status='In Store'""")

View File

@@ -39,7 +39,7 @@ def execute():
status = 'Not in Use'
if sle and flt(sle[0]['actual_qty']) > 0:
status = 'In Store'
status = 'Available'
elif sle and flt(sle[0]['actual_qty']) < 0:
status = 'Delivered'

View File

@@ -22,7 +22,6 @@ patch_list = [
"patches.april_2012.update_role_in_address",
"patches.april_2012.update_permlevel_in_address",
"patches.april_2012.update_appraisal_permission",
"patches.april_2012.serial_no_fixes",
"patches.april_2012.repost_stock_for_posting_time",
"patches.may_2012.cleanup_property_setter",
"patches.may_2012.rename_prev_doctype",
@@ -255,4 +254,5 @@ patch_list = [
"patches.august_2013.p02_rename_price_list",
"patches.august_2013.p03_pos_setting_replace_customer_account",
"patches.august_2013.p04_employee_birthdays",
"patches.august_2013.p05_update_serial_no_status",
]