Merge branch 'master' of github.com:webnotes/erpnext

This commit is contained in:
Rushabh Mehta 2012-12-01 13:35:08 +01:00
commit c713602ff0
27 changed files with 824 additions and 34 deletions

View File

@ -142,7 +142,7 @@ class DocType:
def save_entries(self, cancel, adv_adj, update_outstanding):
for le in self.entries:
# round off upto 2 decimal
le.debit, le.credit = round(le.debit, 2), round(le.credit, 2)
le.debit, le.credit = round(flt(le.debit), 2), round(flt(le.credit), 2)
#toggle debit, credit if negative entry
if flt(le.debit) < 0 or flt(le.credit) < 0:

View File

@ -107,8 +107,7 @@ class DocType(TransactionBase):
#validation for Naming Series mandatory field...
if get_defaults()['supp_master_name'] == 'Naming Series':
if not self.doc.naming_series:
msgprint("Series is Mandatory.")
raise Exception
msgprint("Series is Mandatory.", raise_exception=1)
def create_account_head(self):
if self.doc.company :

View File

@ -240,14 +240,12 @@ class DocType:
# add operation in op list
self.op.append(cstr(d.operation_no))
def validate_materials(self):
""" Validate raw material entries """
check_list = []
for m in getlist(self.doclist, 'bom_materials'):
# check if operation no not in op table
if m.operation_no not in self.op:
if cstr(m.operation_no) not in self.op:
msgprint("""Operation no: %s against item: %s at row no: %s is not present
at Operations table"""% (m.operation_no, m.item_code, m.idx), raise_exception = 1)

View File

@ -141,7 +141,7 @@ class DocType:
'is_purchase_item' :'Is Purchase Item',
'is_pro_applicable' :'Is Pro Applicable'}
for d in fl:
if cstr(self.doc.fields[d]) != 'Yes':
if cstr(self.doc.fields.get(d)) != 'Yes':
self.check_for_active_boms(check = fl[d])
self.check_ref_rate_detail()
self.fill_customer_code()

View File

@ -0,0 +1,192 @@
# ERPNext - web based ERP (http://erpnext.com)
# Copyright (C) 2012 Web Notes Technologies Pvt Ltd
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from __future__ import unicode_literals
import unittest
import webnotes
import webnotes.model
from webnotes.utils import nowdate
from accounts.utils import get_fiscal_year
company = webnotes.conn.get_default("company")
abbr = webnotes.conn.get_value("Company", company, "abbr")
def load_data():
insert_accounts()
# create default warehouse
if not webnotes.conn.exists("Warehouse", "Default Warehouse"):
webnotes.insert({"doctype": "Warehouse",
"warehouse_name": "Default Warehouse",
"warehouse_type": "Stores"})
# create UOM: Nos.
if not webnotes.conn.exists("UOM", "Nos"):
webnotes.insert({"doctype": "UOM", "uom_name": "Nos"})
from webnotes.tests import insert_test_data
# create item groups and items
insert_test_data("Item Group",
sort_fn=lambda ig: (ig[0].get('parent_item_group'), ig[0].get('name')))
insert_test_data("Item")
# create supplier type
webnotes.insert({"doctype": "Supplier Type", "supplier_type": "Manufacturing"})
# create supplier
webnotes.insert({"doctype": "Supplier", "supplier_name": "East Wind Inc.",
"supplier_type": "Manufacturing", "company": company})
# create default cost center if not exists
if not webnotes.conn.exists("Cost Center", "Default Cost Center - %s" % abbr):
dl = webnotes.insert({"doctype": "Cost Center", "group_or_ledger": "Ledger",
"cost_center_name": "Default Cost Center",
"parent_cost_center": "Root - %s" % abbr,
"company_name": company, "company_abbr": abbr})
# create account heads for taxes
webnotes.insert({"doctype": "Account", "account_name": "Shipping Charges",
"parent_account": "Stock Expenses - %s" % abbr, "company": company,
"group_or_ledger": "Ledger"})
webnotes.insert({"doctype": "Account", "account_name": "Customs Duty",
"parent_account": "Stock Expenses - %s" % abbr, "company": company,
"group_or_ledger": "Ledger"})
webnotes.insert({"doctype": "Account", "account_name": "Tax Assets",
"parent_account": "Current Assets - %s" % abbr, "company": company,
"group_or_ledger": "Group"})
webnotes.insert({"doctype": "Account", "account_name": "VAT - Test",
"parent_account": "Tax Assets - %s" % abbr, "company": company,
"group_or_ledger": "Ledger"})
# create BOM
webnotes.insert([
{"doctype": "BOM", "item": "Nebula 7", "quantity": 1,
"is_active": "Yes", "is_default": 1, "uom": "Nos"},
{"doctype": "BOM Operation", "operation_no": 1, "parentfield": "bom_operations",
"opn_description": "Development"},
{"doctype": "BOM Item", "item_code": "Android Jack D", "operation_no": 1,
"qty": 5, "rate": 20, "amount": 100, "stock_uom": "Nos",
"parentfield": "bom_materials"}
])
base_purchase_receipt = [
{
"doctype": "Purchase Receipt", "supplier": "East Wind Inc.",
"naming_series": "PR", "posting_date": nowdate(), "posting_time": "12:05",
"company": company, "fiscal_year": webnotes.conn.get_default("fiscal_year"),
"currency": webnotes.conn.get_default("currency"), "conversion_rate": 1
},
{
"doctype": "Purchase Receipt Item",
"item_code": "Home Desktop 100",
"qty": 10, "received_qty": 10, "rejected_qty": 0, "purchase_rate": 50,
"amount": 500, "warehouse": "Default Warehouse", "valuation_tax_amount": 250,
"parentfield": "purchase_receipt_details",
"conversion_factor": 1, "uom": "Nos", "stock_uom": "Nos"
},
{
"doctype": "Purchase Taxes and Charges", "charge_type": "Actual",
"account_head": "Shipping Charges - %s" % abbr, "purchase_rate": 100, "tax_amount": 100,
"category": "Valuation and Total", "parentfield": "purchase_tax_details",
"cost_center": "Default Cost Center - %s" % abbr
},
{
"doctype": "Purchase Taxes and Charges", "charge_type": "Actual",
"account_head": "VAT - Test - %s" % abbr, "purchase_rate": 120, "tax_amount": 120,
"category": "Total", "parentfield": "purchase_tax_details"
},
{
"doctype": "Purchase Taxes and Charges", "charge_type": "Actual",
"account_head": "Customs Duty - %s" % abbr, "purchase_rate": 150, "tax_amount": 150,
"category": "Valuation", "parentfield": "purchase_tax_details",
"cost_center": "Default Cost Center - %s" % abbr
}
]
def insert_accounts():
for d in webnotes.conn.sql("""select name, abbr from tabCompany""", as_dict=1):
acc_list = [
make_account_dict('Stock Assets', 'Current Assets', d, 'Group'),
make_account_dict('Stock In Hand', 'Stock Assets', d, 'Ledger'),
make_account_dict('Stock Delivered But Not Billed', 'Stock Assets',
d, 'Ledger'),
make_account_dict('Stock Liabilities', 'Current Liabilities', d, 'Group'),
make_account_dict('Stock Received But Not Billed', 'Stock Liabilities',
d, 'Ledger'),
make_account_dict('Stock Expenses', 'Direct Expenses', d, 'Group'),
make_account_dict('Stock Variance', 'Stock Expenses', d, 'Ledger'),
make_account_dict('Expenses Included In Valuation', 'Stock Expenses',
d, 'Ledger'),
]
for acc in acc_list:
acc_name = "%s - %s" % (acc['account_name'], d['abbr'])
if not webnotes.conn.exists('Account', acc_name):
webnotes.insert(acc)
else:
print "Account %s already exists" % acc_name
def make_account_dict(account, parent, company_detail, group_or_ledger):
return {
"doctype": "Account",
"account_name": account,
"parent_account": "%s - %s" % (parent, company_detail['abbr']),
"company": company_detail['name'],
"group_or_ledger": group_or_ledger
}
class TestPurchaseReceipt(unittest.TestCase):
def setUp(self):
webnotes.conn.begin()
load_data()
webnotes.conn.set_value("Global Defaults", None, "automatic_inventory_accounting", 1)
def test_purchase_receipt(self):
# warehouse does not have stock in hand specified
self.run_purchase_receipt_test(base_purchase_receipt,
"Stock In Hand - %s" % (abbr,),
"Stock Received But Not Billed - %s" % (abbr,), 750.0)
def run_purchase_receipt_test(self, purchase_receipt, debit_account,
credit_account, stock_value):
from webnotes.model.doclist import DocList
dl = webnotes.insert(DocList(purchase_receipt))
dl.submit()
dl.load_from_db()
gle = webnotes.conn.sql("""select account, ifnull(debit, 0), ifnull(credit, 0)
from `tabGL Entry` where voucher_no = %s""", dl.doclist[0].name)
gle_map = dict(((entry[0], entry) for entry in gle))
self.assertEquals(gle_map[debit_account], (debit_account, stock_value, 0.0))
self.assertEquals(gle_map[credit_account], (credit_account, 0.0, stock_value))
def atest_subcontracting(self):
pr = base_purchase_receipt.copy()
pr[1].update({"item_code": "Nebula 7"})
self.run_purchase_receipt_test(pr,
"Stock In Hand - %s" % (abbr,),
"Stock Received But Not Billed - %s" % (abbr,), 1750.0)
def tearDown(self):
webnotes.conn.rollback()

View File

@ -1,27 +0,0 @@
# ERPNext - web based ERP (http://erpnext.com)
# Copyright (C) 2012 Web Notes Technologies Pvt Ltd
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from __future__ import unicode_literals
import unittest
import sys
sys.path.append('/Users/rushabh/Workbench/www/wnframework/cgi-bin/')
sys.path.append('/Users/rushabh/Workbench/www/erpnext/')
from material_management.doctype.delivery_note.tests import *
if __name__ == '__main__':
unittest.main()

View File

@ -0,0 +1,37 @@
# Item, Android Jack D
[
# These values are common in all dictionaries
{
u'creation': '2012-08-26 11:30:44',
u'docstatus': 0,
u'modified': '2012-08-26 11:30:44',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item
{
'description': u'Android Jack D',
'doctype': 'Item',
'has_batch_no': u'No',
'has_serial_no': u'No',
'inspection_required': u'No',
'is_purchase_item': u'Yes',
'is_sales_item': u'Yes',
'is_service_item': u'No',
'is_stock_item': u'Yes',
'item_code': u'Android Jack D',
'item_group': u'Android',
'item_name': u'Android Jack D',
u'name': u'__common__',
'stock_uom': u'Nos',
'default_warehouse': u'Default Warehouse'
},
# Item, Android Jack D
{
u'doctype': 'Item',
'name': u'Android Jack D'
}
]

View File

@ -0,0 +1,37 @@
# Item, Android Jack S
[
# These values are common in all dictionaries
{
u'creation': '2012-08-26 11:29:22',
u'docstatus': 0,
u'modified': '2012-08-26 11:29:22',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item
{
'description': u'Android Jack S',
'doctype': 'Item',
'has_batch_no': u'No',
'has_serial_no': u'No',
'inspection_required': u'No',
'is_purchase_item': u'Yes',
'is_sales_item': u'Yes',
'is_service_item': u'No',
'is_stock_item': u'Yes',
'item_code': u'Android Jack S',
'item_group': u'Android',
'item_name': u'Android Jack S',
u'name': u'__common__',
'stock_uom': u'Nos',
'default_warehouse': u'Default Warehouse'
},
# Item, Android Jack S
{
u'doctype': 'Item',
'name': u'Android Jack S'
}
]

View File

@ -0,0 +1,37 @@
# Item, Home Desktop 100
[
# These values are common in all dictionaries
{
u'creation': '2012-08-26 11:25:28',
u'docstatus': 0,
u'modified': '2012-08-26 11:25:28',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item
{
'description': u'Home Desktop 100',
'doctype': 'Item',
'has_batch_no': u'No',
'has_serial_no': u'No',
'inspection_required': u'No',
'is_purchase_item': u'Yes',
'is_sales_item': u'Yes',
'is_service_item': u'No',
'is_stock_item': u'Yes',
'item_code': u'Home Desktop 100',
'item_group': u'Home Series',
'item_name': u'Home Desktop 100',
u'name': u'__common__',
'stock_uom': u'Nos',
'default_warehouse': u'Default Warehouse'
},
# Item, Home Desktop 100
{
u'doctype': 'Item',
'name': u'Home Desktop 100'
}
]

View File

@ -0,0 +1,37 @@
# Item, Home Desktop 200
[
# These values are common in all dictionaries
{
u'creation': '2012-08-26 11:25:54',
u'docstatus': 0,
u'modified': '2012-08-26 11:25:54',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item
{
'description': u'Home Desktop 200',
'doctype': 'Item',
'has_batch_no': u'No',
'has_serial_no': u'No',
'inspection_required': u'No',
'is_purchase_item': u'Yes',
'is_sales_item': u'Yes',
'is_service_item': u'No',
'is_stock_item': u'Yes',
'item_code': u'Home Desktop 200',
'item_group': u'Home Series',
'item_name': u'Home Desktop 200',
u'name': u'__common__',
'stock_uom': u'Nos',
'default_warehouse': u'Default Warehouse'
},
# Item, Home Desktop 200
{
u'doctype': 'Item',
'name': u'Home Desktop 200'
}
]

View File

@ -0,0 +1,37 @@
# Item, Home Desktop 300
[
# These values are common in all dictionaries
{
u'creation': '2012-08-26 11:26:37',
u'docstatus': 0,
u'modified': '2012-08-26 11:26:37',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item
{
'description': u'Home Desktop 300',
'doctype': 'Item',
'has_batch_no': u'No',
'has_serial_no': u'No',
'inspection_required': u'No',
'is_purchase_item': u'Yes',
'is_sales_item': u'Yes',
'is_service_item': u'No',
'is_stock_item': u'Yes',
'item_code': u'Home Desktop 300',
'item_group': u'Home Series',
'item_name': u'Home Desktop 300',
u'name': u'__common__',
'stock_uom': u'Nos',
'default_warehouse': u'Default Warehouse'
},
# Item, Home Desktop 300
{
u'doctype': 'Item',
'name': u'Home Desktop 300'
}
]

View File

@ -0,0 +1,38 @@
# Item, Nebula 7
[
# These values are common in all dictionaries
{
u'creation': '2012-08-26 11:32:02',
u'docstatus': 0,
u'modified': '2012-08-26 11:32:02',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item
{
'description': u'Nebula 7',
'doctype': 'Item',
'has_batch_no': u'No',
'has_serial_no': u'No',
'inspection_required': u'No',
'is_sub_contracted_item': 'Yes',
'is_purchase_item': u'No',
'is_sales_item': u'Yes',
'is_service_item': u'No',
'is_stock_item': u'Yes',
'item_code': u'Nebula 7',
'item_group': u'Small Tablets',
'item_name': u'Nebula 7',
u'name': u'__common__',
'stock_uom': u'Nos',
'default_warehouse': u'Default Warehouse'
},
# Item, Nebula 7
{
u'doctype': 'Item',
'name': u'Nebula 7'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Accessories
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:55:59',
u'docstatus': 0,
u'modified': '2012-08-07 09:55:59',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'Yes',
'item_group_name': u'Accessories',
u'name': u'__common__',
'parent_item_group': u'All Item Groups'
},
# Item Group, Accessories
{
u'doctype': 'Item Group',
u'name': u'Accessories'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Android
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:57:11',
u'docstatus': 0,
u'modified': '2012-08-07 09:57:11',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Android',
u'name': u'__common__',
'parent_item_group': u'Smartphones'
},
# Item Group, Android
{
u'doctype': 'Item Group',
u'name': u'Android'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Desktops
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:55:28',
u'docstatus': 0,
u'modified': '2012-08-07 09:55:28',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'Yes',
'item_group_name': u'Desktops',
u'name': u'__common__',
'parent_item_group': u'All Item Groups'
},
# Item Group, Desktops
{
u'doctype': 'Item Group',
u'name': u'Desktops'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Full Size Tablets
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:58:20',
u'docstatus': 0,
u'modified': '2012-08-07 09:58:20',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Full Size Tablets',
u'name': u'__common__',
'parent_item_group': u'Tablets'
},
# Item Group, Full Size Tablets
{
u'doctype': 'Item Group',
u'name': u'Full Size Tablets'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Gamer
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:56:27',
u'docstatus': 0,
u'modified': '2012-08-07 09:56:27',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Gamer',
u'name': u'__common__',
'parent_item_group': u'Desktops'
},
# Item Group, Gamer
{
u'doctype': 'Item Group',
u'name': u'Gamer'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Home Series
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:56:15',
u'docstatus': 0,
u'modified': '2012-08-07 09:56:15',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Home Series',
u'name': u'__common__',
'parent_item_group': u'Desktops'
},
# Item Group, Home Series
{
u'doctype': 'Item Group',
u'name': u'Home Series'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Laptops
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:55:36',
u'docstatus': 0,
u'modified': '2012-08-07 09:55:36',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'Yes',
'item_group_name': u'Laptops',
u'name': u'__common__',
'parent_item_group': u'All Item Groups'
},
# Item Group, Laptops
{
u'doctype': 'Item Group',
u'name': u'Laptops'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Lightweight
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:56:57',
u'docstatus': 0,
u'modified': '2012-08-07 09:56:58',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Lightweight',
u'name': u'__common__',
'parent_item_group': u'Laptops'
},
# Item Group, Lightweight
{
u'doctype': 'Item Group',
u'name': u'Lightweight'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Medium Tablets
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:57:51',
u'docstatus': 0,
u'modified': '2012-08-07 09:57:51',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Medium Tablets',
u'name': u'__common__',
'parent_item_group': u'Tablets'
},
# Item Group, Medium Tablets
{
u'doctype': 'Item Group',
u'name': u'Medium Tablets'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Pro Series
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:56:20',
u'docstatus': 0,
u'modified': '2012-08-07 09:56:20',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Pro Series',
u'name': u'__common__',
'parent_item_group': u'Desktops'
},
# Item Group, Pro Series
{
u'doctype': 'Item Group',
u'name': u'Pro Series'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Small Tablets
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:57:44',
u'docstatus': 0,
u'modified': '2012-08-07 09:57:44',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Small Tablets',
u'name': u'__common__',
'parent_item_group': u'Tablets'
},
# Item Group, Small Tablets
{
u'doctype': 'Item Group',
u'name': u'Small Tablets'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Smartphones
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:55:49',
u'docstatus': 0,
u'modified': '2012-08-07 09:55:49',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'Yes',
'item_group_name': u'Smartphones',
u'name': u'__common__',
'parent_item_group': u'All Item Groups'
},
# Item Group, Smartphones
{
u'doctype': 'Item Group',
u'name': u'Smartphones'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Tablets
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:55:42',
u'docstatus': 0,
u'modified': '2012-08-07 09:55:42',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'Yes',
'item_group_name': u'Tablets',
u'name': u'__common__',
'parent_item_group': u'All Item Groups'
},
# Item Group, Tablets
{
u'doctype': 'Item Group',
u'name': u'Tablets'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Tough
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:56:41',
u'docstatus': 0,
u'modified': '2012-08-07 09:56:41',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Tough',
u'name': u'__common__',
'parent_item_group': u'Laptops'
},
# Item Group, Tough
{
u'doctype': 'Item Group',
u'name': u'Tough'
}
]

View File

@ -0,0 +1,27 @@
# Item Group, Ultrabook
[
# These values are common in all dictionaries
{
u'creation': '2012-08-07 09:56:50',
u'docstatus': 0,
u'modified': '2012-08-07 09:56:50',
u'modified_by': u'Administrator',
u'owner': u'Administrator'
},
# These values are common for all Item Group
{
u'doctype': 'Item Group',
'is_group': u'No',
'item_group_name': u'Ultrabook',
u'name': u'__common__',
'parent_item_group': u'Laptops'
},
# Item Group, Ultrabook
{
u'doctype': 'Item Group',
u'name': u'Ultrabook'
}
]