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

This commit is contained in:
Nabin Hait
2013-02-21 14:53:42 +05:30
417 changed files with 3228 additions and 1987 deletions

View File

@@ -0,0 +1,107 @@
[
{
"creation": "2013-02-20 16:54:17",
"docstatus": 0,
"modified": "2013-02-20 16:54:17",
"modified_by": "Administrator",
"owner": "Administrator"
},
{
"doctype": "Table Mapper Detail",
"name": "__common__",
"parent": "Material Request-Stock Entry",
"parentfield": "table_mapper_details",
"parenttype": "DocType Mapper"
},
{
"doctype": "Field Mapper Detail",
"map": "Yes",
"name": "__common__",
"parent": "Material Request-Stock Entry",
"parentfield": "field_mapper_details",
"parenttype": "DocType Mapper"
},
{
"doctype": "DocType Mapper",
"from_doctype": "Material Request",
"module": "Stock",
"name": "__common__",
"ref_doc_submitted": 1,
"to_doctype": "Stock Entry"
},
{
"doctype": "DocType Mapper",
"name": "Material Request-Stock Entry"
},
{
"doctype": "Field Mapper Detail",
"from_field": "eval:\"Material Transfer\"",
"match_id": 0,
"to_field": "purpose"
},
{
"checking_operator": "=",
"doctype": "Field Mapper Detail",
"from_field": "company",
"match_id": 0,
"to_field": "company"
},
{
"doctype": "Field Mapper Detail",
"from_field": "parent",
"match_id": 1,
"to_field": "material_request"
},
{
"doctype": "Field Mapper Detail",
"from_field": "name",
"match_id": 1,
"to_field": "material_request_item"
},
{
"doctype": "Field Mapper Detail",
"from_field": "uom",
"match_id": 1,
"to_field": "stock_uom"
},
{
"doctype": "Field Mapper Detail",
"from_field": "eval:flt(1)",
"match_id": 1,
"to_field": "conversion_factor"
},
{
"doctype": "Field Mapper Detail",
"from_field": "eval:flt(obj.qty) - flt(obj.ordered_qty)",
"match_id": 1,
"to_field": "transfer_qty"
},
{
"doctype": "Field Mapper Detail",
"from_field": "eval:flt(obj.qty) - flt(obj.ordered_qty)",
"match_id": 1,
"to_field": "qty"
},
{
"doctype": "Field Mapper Detail",
"from_field": "warehouse",
"match_id": 1,
"to_field": "t_warehouse"
},
{
"doctype": "Table Mapper Detail",
"from_table": "Material Request",
"match_id": 0,
"to_table": "Stock Entry",
"validation_logic": "docstatus = 1"
},
{
"doctype": "Table Mapper Detail",
"from_field": "indent_details",
"from_table": "Material Request Item",
"match_id": 1,
"to_field": "mtn_details",
"to_table": "Stock Entry Detail",
"validation_logic": "qty > ifnull(ordered_qty,0) and docstatus =1"
}
]

View File

@@ -16,15 +16,19 @@
from __future__ import unicode_literals
import webnotes
from webnotes import _
from webnotes.utils import add_days, cint, cstr, flt, get_defaults, now, nowdate
from webnotes.utils import add_days, cint, cstr, flt, now, nowdate, \
get_url_to_form, formatdate
from webnotes.model import db_exists
from webnotes.model.doc import Document, addchild
from webnotes.model.wrapper import copy_doclist
from webnotes.model.bean import copy_doclist
from webnotes.model.code import get_obj
from webnotes import msgprint
sql = webnotes.conn.sql
import webnotes.defaults
class DocType:
def __init__(self, doc, doclist=[]):
@@ -79,7 +83,7 @@ class DocType:
flt(self.doc.indented_qty) + flt(self.doc.planned_qty) - flt(self.doc.reserved_qty)
self.doc.save()
if (flt(args.get("actual_qty")) < 0 or flt(args.get("reserved_qty")) > 0) \
and args.get("is_cancelled") == 'No' and args.get("is_amended")=='No':
self.reorder_item(args.get("voucher_type"), args.get("voucher_no"))
@@ -97,60 +101,67 @@ class DocType:
def reorder_item(self,doc_type,doc_name):
""" Reorder item if stock reaches reorder level"""
if not hasattr(webnotes, "auto_indent"):
webnotes.auto_indent = webnotes.conn.get_value('Global Defaults', None, 'auto_indent')
if webnotes.conn.get_value('Global Defaults', None, 'auto_indent'):
if webnotes.auto_indent:
#check if re-order is required
ret = sql("""select re_order_level, item_name, description, brand, item_group,
lead_time_days, min_order_qty, email_notify, re_order_qty
from tabItem where name = %s""", (self.doc.item_code), as_dict=1)
item_reorder = webnotes.conn.get("Item Reorder",
{"parent": self.doc.item_code, "warehouse": self.doc.warehouse})
current_qty = sql("""
select sum(t1.actual_qty) + sum(t1.indented_qty) + sum(t1.ordered_qty) -sum(t1.reserved_qty)
from tabBin t1, tabWarehouse t2
where t1.item_code = %s
and t1.warehouse = t2.name
and t2.warehouse_type in ('Stores', 'Reserved', 'Default Warehouse Type')
and t1.docstatus != 2
""", self.doc.item_code)
if item_reorder:
reorder_level = item_reorder.warehouse_reorder_level
reorder_qty = item_reorder.warehouse_reorder_qty
material_request_type = item_reorder.material_request_type
else:
reorder_level, reorder_qty = webnotes.conn.get_value("Item", self.doc.item_code,
["re_order_level", "re_order_qty"])
material_request_type = "Purchase"
if flt(reorder_qty) and flt(self.doc.projected_qty) < flt(reorder_level):
self.create_material_request(doc_type, doc_name, reorder_level, reorder_qty,
material_request_type)
if ret[0]["re_order_level"] and current_qty and \
(flt(ret[0]['re_order_level']) > flt(current_qty[0][0])):
self.create_auto_indent(ret[0], doc_type, doc_name, current_qty[0][0])
def create_auto_indent(self, i , doc_type, doc_name, cur_qty):
def create_material_request(self, doc_type, doc_name, reorder_level, reorder_qty, material_request_type):
""" Create indent on reaching reorder level """
indent = Document('Purchase Request')
indent.transaction_date = nowdate()
indent.naming_series = 'IDT'
indent.company = get_defaults()['company']
indent.fiscal_year = get_defaults()['fiscal_year']
indent.remark = """This is an auto generated Purchase Request.
It was raised because the (actual + ordered + indented - reserved) quantity
reaches re-order level when %s %s was created""" % (doc_type,doc_name)
indent.save(1)
indent_obj = get_obj('Purchase Request',indent.name,with_children=1)
indent_details_child = addchild(indent_obj.doc,'indent_details','Purchase Request Item')
indent_details_child.item_code = self.doc.item_code
indent_details_child.uom = self.doc.stock_uom
indent_details_child.warehouse = self.doc.warehouse
indent_details_child.schedule_date= add_days(nowdate(),cint(i['lead_time_days']))
indent_details_child.item_name = i['item_name']
indent_details_child.description = i['description']
indent_details_child.item_group = i['item_group']
indent_details_child.qty = i['re_order_qty'] or (flt(i['re_order_level']) - flt(cur_qty))
indent_details_child.brand = i['brand']
indent_details_child.save()
indent_obj = get_obj('Purchase Request',indent.name,with_children=1)
indent_obj.validate()
webnotes.conn.set(indent_obj.doc,'docstatus',1)
indent_obj.on_submit()
msgprint("""Item: %s is to be re-ordered. Purchase Request %s raised.
defaults = webnotes.defaults.get_defaults()
item = webnotes.doc("Item", self.doc.item_code)
mr = webnotes.bean([{
"doctype": "Material Request",
"company": defaults.company,
"fiscal_year": defaults.fiscal_year,
"transaction_date": nowdate(),
"material_request_type": material_request_type,
"remark": _("This is an auto generated Material Request.") + \
_("It was raised because the (actual + ordered + indented - reserved) quantity reaches re-order level when the following record was created") + \
": " + _(doc_type) + " " + doc_name
}, {
"doctype": "Material Request Item",
"parenttype": "Material Request",
"parentfield": "indent_details",
"item_code": self.doc.item_code,
"schedule_date": add_days(nowdate(),cint(item.lead_time_days)),
"uom": self.doc.stock_uom,
"warehouse": self.doc.warehouse,
"item_name": item.item_name,
"description": item.description,
"item_group": item.item_group,
"qty": reorder_qty,
"brand": item.brand,
}])
mr.insert()
mr.submit()
msgprint("""Item: %s is to be re-ordered. Material Request %s raised.
It was generated from %s: %s""" %
(self.doc.item_code, indent.name, doc_type, doc_name ))
if(i['email_notify']):
self.send_email_notification(doc_type, doc_name)
(self.doc.item_code, mr.doc.name, doc_type, doc_name))
if(item.email_notify):
self.send_email_notification(doc_type, doc_name, mr)
def send_email_notification(self, doc_type, doc_name):
def send_email_notification(self, doc_type, doc_name, bean):
""" Notify user about auto creation of indent"""
from webnotes.utils.email_lib import sendmail
@@ -158,6 +169,10 @@ class DocType:
where p.name = r.parent and p.enabled = 1 and p.docstatus < 2
and r.role in ('Purchase Manager','Material Manager')
and p.name not in ('Administrator', 'All', 'Guest')""")]
msg="""A Purchase Request has been raised
for item %s: %s on %s """ % (doc_type, doc_name, nowdate())
sendmail(email_list, subject='Auto Purchase Request Generation Notification', msg = msg)
msg="""A new Material Request has been raised for Item: %s and Warehouse: %s \
on %s due to %s: %s. See %s: %s """ % (self.doc.item_code, self.doc.warehouse,
formatdate(), doc_type, doc_name, bean.doc.doctype,
get_url_to_form(bean.doc.doctype, bean.doc.name))
sendmail(email_list, subject='Auto Material Request Generation Notification', msg = msg)

View File

@@ -18,7 +18,7 @@ from __future__ import unicode_literals
import webnotes
from webnotes.utils import cstr, flt, getdate
from webnotes.model.wrapper import getlist
from webnotes.model.bean import getlist
from webnotes.model.code import get_obj
from webnotes import msgprint
@@ -312,9 +312,9 @@ class DocType(SellingController):
""", self.doc.name)
if res and res[0][1]>0:
from webnotes.model.wrapper import ModelWrapper
from webnotes.model.bean import Bean
for r in res:
ps = ModelWrapper(dt='Packing Slip', dn=r[0])
ps = Bean(dt='Packing Slip', dn=r[0])
ps.cancel()
webnotes.msgprint("%s Packing Slip(s) Cancelled" % res[0][1])

View File

@@ -19,7 +19,7 @@ import webnotes
from webnotes.utils import cstr, flt
from webnotes.model.doc import addchild
from webnotes.model.wrapper import getlist
from webnotes.model.bean import getlist
from webnotes import msgprint
sql = webnotes.conn.sql

View File

@@ -1,8 +1,8 @@
[
{
"creation": "2013-01-21 18:19:22",
"creation": "2013-02-20 13:26:14",
"docstatus": 0,
"modified": "2013-01-29 13:32:21",
"modified": "2013-02-20 18:14:06",
"modified_by": "Administrator",
"owner": "Administrator"
},
@@ -28,14 +28,13 @@
"permlevel": 0
},
{
"amend": 0,
"doctype": "DocPerm",
"name": "__common__",
"parent": "Item",
"parentfield": "permissions",
"parenttype": "DocType",
"permlevel": 0,
"read": 1,
"report": 1,
"submit": 0
},
{
@@ -200,32 +199,6 @@
"oldfieldname": "tolerance",
"oldfieldtype": "Currency"
},
{
"depends_on": "eval:doc.is_stock_item==\"Yes\"",
"description": "The system will generate a Purchase Request automatically when stock quantity goes below re-order level in warehouse of type \"Stores\" or \"Reserved Warehouse\".",
"doctype": "DocField",
"fieldname": "re_order_level",
"fieldtype": "Float",
"label": "Re-Order Level",
"oldfieldname": "re_order_level",
"oldfieldtype": "Currency"
},
{
"depends_on": "eval:doc.is_stock_item==\"Yes\"",
"description": "The quantity for the Purchase Request when the stock goes below re-order level.",
"doctype": "DocField",
"fieldname": "re_order_qty",
"fieldtype": "Float",
"label": "Re-Order Qty"
},
{
"depends_on": "eval:doc.is_stock_item==\"Yes\"",
"description": "Send an email to users of role \"Material Manager\" and \"Purchase Manager\" when re-order level is crossed.",
"doctype": "DocField",
"fieldname": "email_notify",
"fieldtype": "Check",
"label": "Notify by Email on Re-order"
},
{
"depends_on": "eval:doc.is_stock_item==\"Yes\"",
"doctype": "DocField",
@@ -327,6 +300,55 @@
"label": "Weight UOM",
"options": "UOM"
},
{
"description": "Auto-raise Material Request if quantity goes below re-order level in a warehouse",
"doctype": "DocField",
"fieldname": "reorder_section",
"fieldtype": "Section Break",
"label": "Re-order"
},
{
"depends_on": "eval:doc.is_stock_item==\"Yes\"",
"doctype": "DocField",
"fieldname": "re_order_level",
"fieldtype": "Float",
"label": "Re-Order Level",
"oldfieldname": "re_order_level",
"oldfieldtype": "Currency"
},
{
"depends_on": "eval:doc.is_stock_item==\"Yes\"",
"doctype": "DocField",
"fieldname": "re_order_qty",
"fieldtype": "Float",
"label": "Re-Order Qty"
},
{
"doctype": "DocField",
"fieldname": "column_break_31",
"fieldtype": "Column Break"
},
{
"depends_on": "eval:doc.is_stock_item==\"Yes\"",
"description": "Send an email to users of role \"Material Manager\" and \"Purchase Manager\" when re-order level is crossed.",
"doctype": "DocField",
"fieldname": "email_notify",
"fieldtype": "Check",
"label": "Notify by Email on Re-order"
},
{
"doctype": "DocField",
"fieldname": "section_break_31",
"fieldtype": "Section Break",
"options": "Simple"
},
{
"doctype": "DocField",
"fieldname": "item_reorder",
"fieldtype": "Table",
"label": "Warehouse-wise Item Reorder",
"options": "Item Reorder"
},
{
"doctype": "DocField",
"fieldname": "purchase_details",
@@ -348,7 +370,7 @@
},
{
"depends_on": "eval:doc.is_purchase_item==\"Yes\"",
"description": "Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.",
"description": "Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.",
"doctype": "DocField",
"fieldname": "lead_time_days",
"fieldtype": "Int",
@@ -791,18 +813,38 @@
"label": "Website Description"
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"report": 0,
"role": "Material Manager",
"write": 0
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "Material Manager",
"write": 0
},
{
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"report": 0,
"role": "Material User",
"write": 0
},
{
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "Material User",
"write": 0
},
@@ -810,7 +852,36 @@
"cancel": 1,
"create": 1,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "Material Master Manager",
"write": 1
},
{
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"report": 0,
"role": "Material Master Manager",
"write": 0
},
{
"cancel": 1,
"create": 1,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "System Manager",
"write": 1
},
{
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"report": 0,
"role": "System Manager",
"write": 0
}
]

View File

@@ -24,10 +24,12 @@
"Last Purchase Rate",
"Website Item Groups",
"Default Expense Account",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.",
"Manufacturing",
"Net Weight",
"Mandatory if Stock Item is \"Yes\"",
"Show in Website",
"Re-order",
"For the convenience of customers, these codes can be used in print formats like Invoices and Delivery Notes",
"UOM Conversion Details",
"FIFO",
@@ -49,14 +51,12 @@
"Selecting \"Yes\" will give a unique identity to each entity of this item which can be viewed in the Serial No master.",
"Website",
"Website Price List",
"The quantity for the Purchase Request when the stock goes below re-order level.",
"Has Batch No",
"Item Code",
"Buying Cost",
"website page link",
"Max Discount (%)",
"Image",
"The system will generate a Purchase Request automatically when stock quantity goes below re-order level in warehouse of type \"Stores\" or \"Reserved Warehouse\".",
"Is Asset Item",
"Sales Details",
"Standard Rate",
@@ -98,6 +98,7 @@
"Item Quality Inspection Parameter",
"Description",
"End of Life",
"Warehouse-wise Item Reorder",
"Barcode",
"Website Description",
"You can enter the minimum quantity of this item to be ordered.",
@@ -108,7 +109,6 @@
"Weightage",
"Is Purchase Item",
"Item",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.",
"Yes",
"Is Sub Contracted Item",
"Item Prices",

View File

@@ -56,6 +56,7 @@
"Item will be saved by this name in the data base.": "\u0633\u064a\u062a\u0645 \u062d\u0641\u0638 \u0627\u0644\u0639\u0646\u0635\u0631 \u0628\u0647\u0630\u0627 \u0627\u0644\u0627\u0633\u0645 \u0641\u064a \u0642\u0627\u0639\u062f\u0629 \u0627\u0644\u0628\u064a\u0627\u0646\u0627\u062a.",
"Last Purchase Rate": "\u0645\u0634\u0627\u0631\u0643\u0629 \u0627\u0644\u0634\u0631\u0627\u0621 \u0642\u064a\u0645",
"Lead Time Days": "\u064a\u0624\u062f\u064a \u064a\u0648\u0645\u0627 \u0645\u0631\u0629",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.": "\u064a\u0624\u062f\u064a \u0627\u0644\u0648\u0642\u062a \u0647\u0648 \u0623\u064a\u0627\u0645 \u0639\u062f\u062f \u0627\u0644\u0623\u064a\u0627\u0645 \u0627\u0644\u062a\u064a \u0645\u0646 \u0627\u0644\u0645\u062a\u0648\u0642\u0639 \u0647\u0630\u0627 \u0627\u0644\u0628\u0646\u062f \u0641\u064a \u0627\u0644\u0645\u0633\u062a\u0648\u062f\u0639 \u0627\u0644\u062e\u0627\u0635 \u0628\u0643. \u064a\u062a\u0645 \u0625\u062d\u0636\u0627\u0631 \u0647\u0630\u0647 \u0627\u0644\u0623\u064a\u0627\u0645 \u0641\u064a \u0637\u0644\u0628 \u0627\u0644\u0645\u0648\u0627\u062f \u0639\u0646\u062f \u0627\u062e\u062a\u064a\u0627\u0631 \u0647\u0630\u0627 \u0627\u0644\u0628\u0646\u062f.",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.": "\u064a\u0624\u062f\u064a \u0627\u0644\u0648\u0642\u062a \u0647\u0648 \u0623\u064a\u0627\u0645 \u0639\u062f\u062f \u0627\u0644\u0623\u064a\u0627\u0645 \u0627\u0644\u062a\u064a \u0645\u0646 \u0627\u0644\u0645\u062a\u0648\u0642\u0639 \u0647\u0630\u0627 \u0627\u0644\u0628\u0646\u062f \u0641\u064a \u0627\u0644\u0645\u0633\u062a\u0648\u062f\u0639 \u0627\u0644\u062e\u0627\u0635 \u0628\u0643. \u064a\u062a\u0645 \u0625\u062d\u0636\u0627\u0631 \u0647\u0630\u0647 \u0627\u0644\u0623\u064a\u0627\u0645 \u0641\u064a \u0637\u0644\u0628 \u0634\u0631\u0627\u0621 \u0639\u0646\u062f \u0627\u062e\u062a\u064a\u0627\u0631 \u0647\u0630\u0627 \u0627\u0644\u0628\u0646\u062f.",
"List this Item in multiple groups on the website.": "\u0642\u0627\u0626\u0645\u0629 \u0647\u0630\u0627 \u0627\u0644\u0628\u0646\u062f \u0641\u064a \u0645\u062c\u0645\u0648\u0639\u0627\u062a \u0645\u062a\u0639\u062f\u062f\u0629 \u0639\u0644\u0649 \u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0646\u062a\u0631\u0646\u062a.",
"Mandatory if Stock Item is \"Yes\"": "\u0625\u0644\u0632\u0627\u0645\u064a\u0629 \u0627\u0644\u0625\u063a\u0644\u0627\u0642 \u0627\u0644\u0623\u0633\u0647\u0645 \u0625\u0630\u0627 \u0647\u0648 &quot;\u0646\u0639\u0645&quot;",
@@ -77,6 +78,7 @@
"Quality Inspection Parameters": "\u0645\u0639\u0627\u064a\u064a\u0631 \u0627\u0644\u062c\u0648\u062f\u0629 \u0627\u0644\u062a\u0641\u062a\u064a\u0634",
"Re-Order Level": "\u0625\u0639\u0627\u062f\u0629 \u062a\u0631\u062a\u064a\u0628 \u0645\u0633\u062a\u0648\u0649",
"Re-Order Qty": "\u0625\u0639\u0627\u062f\u0629 \u062a\u0631\u062a\u064a\u0628 \u0627\u0644\u0643\u0645\u064a\u0629",
"Re-order": "\u0625\u0639\u0627\u062f\u0629 \u062a\u0631\u062a\u064a\u0628",
"Sales Details": "\u0645\u0628\u064a\u0639\u0627\u062a \u062a\u0641\u0627\u0635\u064a\u0644",
"Sales Rate": "\u0645\u0628\u064a\u0639\u0627\u062a \u0642\u064a\u0645",
"Select \"Yes\" if this item is to be sent to a customer or received from a supplier as a sample. Delivery notes and Purchase Receipts will update stock levels but there will be no invoice against this item.": "\u062d\u062f\u062f &quot;\u0646\u0639\u0645&quot; \u0625\u0630\u0627 \u0643\u0627\u0646\u062a \u0647\u0630\u0647 \u0627\u0644\u0633\u0644\u0639\u0629 \u063a\u064a\u0631 \u0645\u062a\u0648\u0641\u0631\u0629 \u0644\u064a\u062a\u0645 \u0625\u0631\u0633\u0627\u0644\u0647\u0627 \u0625\u0644\u0649 \u0627\u0644\u0639\u0645\u0644\u0627\u0621 \u0623\u0648 \u0627\u0644\u0648\u0627\u0631\u062f\u0629 \u0645\u0646 \u0627\u0644\u0645\u0648\u0631\u062f \u0643\u0639\u064a\u0646\u0629. \u0633\u0648\u0641 \u062a\u0644\u0627\u062d\u0638 \u0627\u0644\u062a\u0633\u0644\u064a\u0645 \u0648\u0625\u064a\u0635\u0627\u0644\u0627\u062a \u0634\u0631\u0627\u0621 \u062a\u062d\u062f\u064a\u062b \u0645\u0633\u062a\u0648\u064a\u0627\u062a \u0627\u0644\u0645\u062e\u0632\u0648\u0646 \u0648\u0644\u0643\u0646 \u0644\u0646 \u064a\u0643\u0648\u0646 \u0647\u0646\u0627\u0643 \u0641\u0627\u062a\u0648\u0631\u0629 \u0636\u062f \u0647\u0630\u0627 \u0627\u0644\u0628\u0646\u062f.",
@@ -102,6 +104,7 @@
"UOM Conversion Details": "\u062a\u0641\u0627\u0635\u064a\u0644 \u0627\u0644\u062a\u062d\u0648\u064a\u0644 UOM",
"Unit of measurement of this item (e.g. Kg, Unit, No, Pair).": "\u0648\u062d\u062f\u0629 \u0627\u0644\u0642\u064a\u0627\u0633 \u0641\u064a \u0647\u0630\u0627 \u0627\u0644\u0628\u0646\u062f (\u0645\u062b\u0644 \u0643\u062c\u0645\u060c \u0648\u062d\u062f\u0629\u060c \u0644\u0627\u060c \u0627\u0644\u0632\u0648\u062c).",
"Valuation Method": "\u062a\u0642\u064a\u064a\u0645 \u0627\u0644\u0637\u0631\u064a\u0642\u0629",
"Warehouse-wise Item Reorder": "\u0645\u0633\u062a\u0648\u062f\u0639 \u0627\u0644\u0645\u062f\u064a\u0646\u0629 \u0645\u0646 \u0627\u0644\u062d\u0643\u0645\u0629 \u0625\u0639\u0627\u062f\u0629 \u062a\u0631\u062a\u064a\u0628",
"Warranty Period (in days)": "\u0641\u062a\u0631\u0629 \u0627\u0644\u0636\u0645\u0627\u0646 (\u0628\u0627\u0644\u0623\u064a\u0627\u0645)",
"Website": "\u0627\u0644\u0645\u0648\u0642\u0639",
"Website Description": "\u0627\u0644\u0645\u0648\u0642\u0639 \u0648\u0635\u0641",

View File

@@ -56,6 +56,7 @@
"Item will be saved by this name in the data base.": "El art\u00edculo ser\u00e1 salvado por este nombre en la base de datos.",
"Last Purchase Rate": "Tarifa de \u00daltimo",
"Lead Time Days": "Plomo d\u00edas Tiempo",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.": "Lead Time d\u00eda es el n\u00famero de d\u00edas en que se espera para este art\u00edculo en su almac\u00e9n. Estos d\u00edas se recupera en la solicitud de material cuando se selecciona este elemento.",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.": "Lead Time d\u00eda es el n\u00famero de d\u00edas en que se espera para este art\u00edculo en su almac\u00e9n. Estos d\u00edas se recupera en solicitud de compra al seleccionar este elemento.",
"List this Item in multiple groups on the website.": "Enumero este art\u00edculo en varios grupos en la web.",
"Mandatory if Stock Item is \"Yes\"": "Punto Obligatorio de si es &quot;S\u00ed&quot;",
@@ -77,6 +78,7 @@
"Quality Inspection Parameters": "Par\u00e1metros de Calidad Inspecci\u00f3n",
"Re-Order Level": "Re-Order Nivel",
"Re-Order Qty": "Re-Order Cantidad",
"Re-order": "Reordenar",
"Sales Details": "Ventas Details",
"Sales Rate": "Ventas Precio",
"Select \"Yes\" if this item is to be sent to a customer or received from a supplier as a sample. Delivery notes and Purchase Receipts will update stock levels but there will be no invoice against this item.": "Seleccione &quot;S\u00ed&quot; si este art\u00edculo se va a enviar a un cliente o recibido de un proveedor como muestra. Albaranes y facturas de compra se actualizar\u00e1n los niveles de existencias, pero no habr\u00e1 ninguna factura en contra de este art\u00edculo.",
@@ -102,6 +104,7 @@
"UOM Conversion Details": "UOM detalles de la conversi\u00f3n",
"Unit of measurement of this item (e.g. Kg, Unit, No, Pair).": "Unidad de medida de este art\u00edculo (Kg por ejemplo, Unidad, No, par).",
"Valuation Method": "M\u00e9todo de valoraci\u00f3n",
"Warehouse-wise Item Reorder": "Warehouse-sabio art\u00edculo reorden",
"Warranty Period (in days)": "Per\u00edodo de garant\u00eda (en d\u00edas)",
"Website": "Sitio web",
"Website Description": "Descripci\u00f3n del sitio",

View File

@@ -56,6 +56,7 @@
"Item will be saved by this name in the data base.": "L&#39;article sera sauv\u00e9 par ce nom dans la base de donn\u00e9es.",
"Last Purchase Rate": "Purchase Rate Derni\u00e8re",
"Lead Time Days": "Diriger jours Temps",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.": "Diriger jours Temps est le nombre de jours dont cet article est pr\u00e9vu dans votre entrep\u00f4t. Ces jours sont r\u00e9cup\u00e9r\u00e9es dans la Demande de Mat\u00e9riel quand vous s\u00e9lectionnez cette option.",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.": "Diriger jours Temps est le nombre de jours dont cet article est pr\u00e9vu dans votre entrep\u00f4t. Ces jours sont r\u00e9cup\u00e9r\u00e9es dans la demande d&#39;achat lorsque vous s\u00e9lectionnez cette option.",
"List this Item in multiple groups on the website.": "Liste cet article dans plusieurs groupes sur le site.",
"Mandatory if Stock Item is \"Yes\"": "Produit en stock obligatoire si &quot;Oui&quot;",
@@ -77,6 +78,7 @@
"Quality Inspection Parameters": "Param\u00e8tres inspection de la qualit\u00e9",
"Re-Order Level": "Re-Order niveau",
"Re-Order Qty": "Re-Cdt",
"Re-order": "Re-order",
"Sales Details": "D\u00e9tails ventes",
"Sales Rate": "Taux de vente",
"Select \"Yes\" if this item is to be sent to a customer or received from a supplier as a sample. Delivery notes and Purchase Receipts will update stock levels but there will be no invoice against this item.": "S\u00e9lectionnez \u00abOui\u00bb si cet article doit \u00eatre envoy\u00e9 \u00e0 un client ou re\u00e7u d&#39;un fournisseur comme un \u00e9chantillon. Les bons de livraison et factures d&#39;achat va mettre \u00e0 jour les niveaux de stocks, mais il n&#39;y aura pas de facture contre cet article.",
@@ -102,6 +104,7 @@
"UOM Conversion Details": "D\u00e9tails conversion UOM",
"Unit of measurement of this item (e.g. Kg, Unit, No, Pair).": "Unit\u00e9 de mesure de cet article (Kg par exemple, unit\u00e9, Non, Pair).",
"Valuation Method": "M\u00e9thode d&#39;\u00e9valuation",
"Warehouse-wise Item Reorder": "Warehouse-sage R\u00e9organiser article",
"Warranty Period (in days)": "P\u00e9riode de garantie (en jours)",
"Website": "Site Web",
"Website Description": "Description du site Web",

View File

@@ -56,6 +56,7 @@
"Item will be saved by this name in the data base.": "\u0906\u0907\u091f\u092e \u0921\u093e\u091f\u093e \u092c\u0947\u0938 \u092e\u0947\u0902 \u0907\u0938 \u0928\u093e\u092e \u0938\u0947 \u092c\u091a\u093e\u092f\u093e \u091c\u093e\u090f\u0917\u093e.",
"Last Purchase Rate": "\u092a\u093f\u091b\u0932\u0947 \u0916\u0930\u0940\u0926 \u0926\u0930",
"Lead Time Days": "\u0932\u0940\u0921 \u0938\u092e\u092f \u0926\u093f\u0928",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.": "\u0932\u0940\u0921 \u0938\u092e\u092f \u0926\u093f\u0928\u094b\u0902 \u0926\u093f\u0928 \u091c\u093f\u0938\u0915\u0947 \u0926\u094d\u0935\u093e\u0930\u093e \u0907\u0938 \u0906\u0907\u091f\u092e \u0905\u092a\u0928\u0947 \u0917\u094b\u0926\u093e\u092e \u092e\u0947\u0902 \u0909\u092e\u094d\u092e\u0940\u0926 \u0939\u0948 \u0915\u0940 \u0938\u0902\u0916\u094d\u092f\u093e \u0939\u0948. \u0907\u0938 \u0926\u093f\u0928 \u0938\u093e\u092e\u0917\u094d\u0930\u0940 \u0915\u0947 \u0905\u0928\u0941\u0930\u094b\u0927 \u092e\u0947\u0902 \u0926\u093f\u0932\u0935\u093e\u092f\u093e \u0939\u0948 \u091c\u092c \u0906\u092a \u0907\u0938 \u092e\u0926 \u0915\u093e \u091a\u092f\u0928 \u0915\u0930\u0947\u0902.",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.": "\u0932\u0940\u0921 \u0938\u092e\u092f \u0926\u093f\u0928\u094b\u0902 \u0926\u093f\u0928 \u091c\u093f\u0938\u0915\u0947 \u0926\u094d\u0935\u093e\u0930\u093e \u0907\u0938 \u0906\u0907\u091f\u092e \u0905\u092a\u0928\u0947 \u0917\u094b\u0926\u093e\u092e \u092e\u0947\u0902 \u0909\u092e\u094d\u092e\u0940\u0926 \u0939\u0948 \u0915\u0940 \u0938\u0902\u0916\u094d\u092f\u093e \u0939\u0948. \u0907\u0938 \u0926\u093f\u0928 \u0916\u0930\u0940\u0926 \u0915\u0947 \u0905\u0928\u0941\u0930\u094b\u0927 \u092e\u0947\u0902 \u0926\u093f\u0932\u0935\u093e\u092f\u093e \u0939\u0948 \u091c\u092c \u0906\u092a \u0907\u0938 \u092e\u0926 \u0915\u093e \u091a\u092f\u0928 \u0915\u0930\u0947\u0902.",
"List this Item in multiple groups on the website.": "\u0915\u0908 \u0938\u092e\u0942\u0939\u094b\u0902 \u092e\u0947\u0902 \u0935\u0947\u092c\u0938\u093e\u0907\u091f \u092a\u0930 \u0907\u0938 \u092e\u0926 \u0915\u0940 \u0938\u0942\u091a\u0940.",
"Mandatory if Stock Item is \"Yes\"": "\u0905\u0928\u093f\u0935\u093e\u0930\u094d\u092f \u0905\u0917\u0930 \u0938\u094d\u091f\u0949\u0915 \u0906\u0907\u091f\u092e \u0939\u0948 &quot;\u0939\u093e\u0901&quot;",
@@ -77,6 +78,7 @@
"Quality Inspection Parameters": "\u0917\u0941\u0923\u0935\u0924\u094d\u0924\u093e \u0928\u093f\u0930\u0940\u0915\u094d\u0937\u0923 \u092a\u0948\u0930\u093e\u092e\u0940\u091f\u0930",
"Re-Order Level": "\u092a\u0941\u0928 \u0906\u0926\u0947\u0936 \u0938\u094d\u0924\u0930",
"Re-Order Qty": "\u092a\u0941\u0928 \u0906\u0926\u0947\u0936 \u092e\u093e\u0924\u094d\u0930\u093e",
"Re-order": "\u092a\u0941\u0928\u0903 \u0906\u0926\u0947\u0936",
"Sales Details": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0935\u093f\u0935\u0930\u0923",
"Sales Rate": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0926\u0930",
"Select \"Yes\" if this item is to be sent to a customer or received from a supplier as a sample. Delivery notes and Purchase Receipts will update stock levels but there will be no invoice against this item.": "&quot;\u0939\u093e\u0901&quot; \u091a\u0941\u0928\u0947\u0902 \u092f\u0926\u093f \u0907\u0938 \u092e\u0926 \u0915\u0947 \u0932\u093f\u090f \u090f\u0915 \u0917\u094d\u0930\u093e\u0939\u0915 \u0915\u0947 \u0932\u093f\u090f \u092d\u0947\u091c\u093e \u091c\u093e \u0938\u0915\u0924\u093e \u0939\u0948 \u092f\u093e \u090f\u0915 \u0928\u092e\u0942\u0928\u093e \u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u090f\u0915 \u0938\u092a\u094d\u0932\u093e\u092f\u0930 \u0938\u0947 \u092a\u094d\u0930\u093e\u092a\u094d\u0924 \u0939\u0948. \u0921\u093f\u0932\u093f\u0935\u0930\u0940 \u0928\u094b\u091f\u094d\u0938 \u0914\u0930 \u0916\u0930\u0940\u0926 \u0930\u0938\u0940\u0926 \u0938\u094d\u091f\u0949\u0915 \u0915\u0947 \u0938\u094d\u0924\u0930 \u0915\u094b \u0905\u092a\u0921\u0947\u091f \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902, \u0932\u0947\u0915\u093f\u0928 \u0935\u0939\u093e\u0901 \u0907\u0938 \u0906\u0907\u091f\u092e \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u0915\u094b\u0908 \u091a\u093e\u0932\u093e\u0928 \u0939\u094b \u091c\u093e\u090f\u0917\u093e.",
@@ -103,6 +105,7 @@
"UOM Conversion Details": "UOM \u0930\u0942\u092a\u093e\u0902\u0924\u0930\u0923 \u0935\u093f\u0935\u0930\u0923",
"Unit of measurement of this item (e.g. Kg, Unit, No, Pair).": "\u0907\u0938 \u092e\u0926 \u0915\u0947 \u092e\u093e\u092a \u0915\u0940 \u0907\u0915\u093e\u0908 (\u091c\u0948\u0938\u0947 \u0915\u093f\u0932\u094b\u0917\u094d\u0930\u093e\u092e, \u092f\u0942\u0928\u093f\u091f, \u0928\u0939\u0940\u0902, \u091c\u094b\u0921\u093c\u0940).",
"Valuation Method": "\u092e\u0942\u0932\u094d\u092f\u0928 \u0935\u093f\u0927\u093f",
"Warehouse-wise Item Reorder": "\u0917\u094b\u0926\u093e\u092e \u0935\u093e\u0930 \u0906\u0907\u091f\u092e \u092a\u0941\u0928\u0903 \u0915\u094d\u0930\u092e\u093f\u0924 \u0915\u0930\u0947\u0902",
"Warranty Period (in days)": "\u0935\u093e\u0930\u0902\u091f\u0940 \u0905\u0935\u0927\u093f (\u0926\u093f\u0928\u094b\u0902 \u092e\u0947\u0902)",
"Website": "\u0935\u0947\u092c\u0938\u093e\u0907\u091f",
"Website Description": "\u0935\u0947\u092c\u0938\u093e\u0907\u091f \u0935\u093f\u0935\u0930\u0923",

View File

@@ -56,6 +56,7 @@
"Item will be saved by this name in the data base.": "Stavka \u0107e biti spremljena pod ovim imenom u bazi podataka.",
"Last Purchase Rate": "Zadnja Kupnja Ocijenite",
"Lead Time Days": "Olovo vrijeme Dane",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.": "Olovo vrijeme dana je broj dana koji ovaj predmet se o\u010dekuje u skladi\u0161tu. Ovih dana je preuzeta u Materijal Zahtjev kada odaberete ovu stavku.",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.": "Olovo vrijeme dana je broj dana koji ovaj predmet se o\u010dekuje u skladi\u0161tu. Ovih dana je preuzeta u zahtjev za kupnju kada odaberete ovu stavku.",
"List this Item in multiple groups on the website.": "Popis ovaj predmet u vi\u0161e grupa na web stranici.",
"Mandatory if Stock Item is \"Yes\"": "Obvezni ako katalo\u0161ki Stavka je &quot;Da&quot;",
@@ -77,6 +78,7 @@
"Quality Inspection Parameters": "Inspekcija kvalitete Parametri",
"Re-Order Level": "Re-Order Razina",
"Re-Order Qty": "Re-Order Kol",
"Re-order": "Ponovno bi",
"Sales Details": "Prodaja Detalji",
"Sales Rate": "Prodaja Stopa",
"Select \"Yes\" if this item is to be sent to a customer or received from a supplier as a sample. Delivery notes and Purchase Receipts will update stock levels but there will be no invoice against this item.": "Odaberite &quot;Da&quot; ako je ova stavka \u0107e biti poslan na kupca ili dobio od dobavlja\u010da kao uzorak. Otpremnice i kupnju primitke \u0107e a\u017eurirati burzovne razinama, ali ne\u0107e biti faktura protiv ove stavke.",
@@ -102,6 +104,7 @@
"UOM Conversion Details": "UOM pretvorbe Detalji",
"Unit of measurement of this item (e.g. Kg, Unit, No, Pair).": "Jedinica za mjerenje ove to\u010dke (npr. kg, Jedinica Ne, Par).",
"Valuation Method": "Vrednovanje metoda",
"Warehouse-wise Item Reorder": "Warehouse-mudar Stavka redoslijeda",
"Warranty Period (in days)": "Jamstveno razdoblje (u danima)",
"Website": "Website",
"Website Description": "Web stranica Opis",

View File

@@ -56,6 +56,7 @@
"Item will be saved by this name in the data base.": "Het punt zal worden opgeslagen met deze naam in de databank.",
"Last Purchase Rate": "Laatste Purchase Rate",
"Lead Time Days": "Lead Time Dagen",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.": "Levertijd dagen is het aantal dagen waarmee dit artikel wordt verwacht in uw magazijn. Deze dag wordt opgehaald in Laden en aanvragen als u dit item.",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.": "Levertijd dagen is het aantal dagen waarmee dit artikel wordt verwacht in uw magazijn. Deze dag wordt opgehaald in Purchase Request als u dit item.",
"List this Item in multiple groups on the website.": "Lijst deze post in meerdere groepen op de website.",
"Mandatory if Stock Item is \"Yes\"": "Verplicht als Stock Item &quot;ja&quot;",
@@ -77,6 +78,7 @@
"Quality Inspection Parameters": "Quality Inspection Parameters",
"Re-Order Level": "Re-Order Level",
"Re-Order Qty": "Re-Order Aantal",
"Re-order": "Re-order",
"Sales Details": "Verkoop Details",
"Sales Rate": "Sales Rate",
"Select \"Yes\" if this item is to be sent to a customer or received from a supplier as a sample. Delivery notes and Purchase Receipts will update stock levels but there will be no invoice against this item.": "Selecteer &quot;Ja&quot; als dit voorwerp dient te worden verzonden naar een klant of ontvangen van een leverancier als een monster. Pakbonnen en aankoopbewijzen zal update voorraadniveaus, maar er zal geen factuur tegen deze item.",
@@ -102,6 +104,7 @@
"UOM Conversion Details": "Verpakking Conversie Details",
"Unit of measurement of this item (e.g. Kg, Unit, No, Pair).": "Meeteenheid van dit artikel (bijvoorbeeld kg, eenheid, Nee, Pair).",
"Valuation Method": "Waardering Methode",
"Warehouse-wise Item Reorder": "Warehouse-wise Item opnieuw ordenen",
"Warranty Period (in days)": "Garantieperiode (in dagen)",
"Website": "Website",
"Website Description": "Website Beschrijving",

View File

@@ -56,6 +56,7 @@
"Item will be saved by this name in the data base.": "O artigo ser\u00e1 salva por este nome na base de dados.",
"Last Purchase Rate": "Compra de \u00faltima",
"Lead Time Days": "Levar dias Tempo",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Material Request when you select this item.": "Levar dias Tempo \u00e9 o n\u00famero de dias em que este item \u00e9 esperado no seu armaz\u00e9m. Este dia \u00e9 buscada em solicitar material ao selecionar este item.",
"Lead Time days is number of days by which this item is expected in your warehouse. This days is fetched in Purchase Request when you select this item.": "Levar dias Tempo \u00e9 o n\u00famero de dias em que este item \u00e9 esperado no seu armaz\u00e9m. Este dia \u00e9 buscada em Pedido de Compra quando voc\u00ea selecionar este item.",
"List this Item in multiple groups on the website.": "Lista este item em v\u00e1rios grupos no site.",
"Mandatory if Stock Item is \"Yes\"": "Item de estoque \u00e9 obrigat\u00f3ria se &quot;Sim&quot;",
@@ -77,6 +78,7 @@
"Quality Inspection Parameters": "Inspe\u00e7\u00e3o par\u00e2metros de qualidade",
"Re-Order Level": "Re Ordem N\u00edvel",
"Re-Order Qty": "Re-Ordem Qtde",
"Re-order": "Re-vista",
"Sales Details": "Detalhes de vendas",
"Sales Rate": "Taxa de vendas",
"Select \"Yes\" if this item is to be sent to a customer or received from a supplier as a sample. Delivery notes and Purchase Receipts will update stock levels but there will be no invoice against this item.": "Selecione &quot;Sim&quot; se este item \u00e9 para ser enviado para um cliente ou recebidas de um fornecedor como amostra. Notas de entrega e recibos de compra ir\u00e1 atualizar os n\u00edveis de estoque, mas n\u00e3o haver\u00e1 fatura contra este item.",
@@ -102,6 +104,7 @@
"UOM Conversion Details": "Convers\u00e3o Detalhes UOM",
"Unit of measurement of this item (e.g. Kg, Unit, No, Pair).": "Unidade de medida do item (por exemplo kg Unidade, n\u00e3o, par).",
"Valuation Method": "M\u00e9todo de Avalia\u00e7\u00e3o",
"Warehouse-wise Item Reorder": "Armaz\u00e9m-s\u00e1bio item Reordenar",
"Warranty Period (in days)": "Per\u00edodo de Garantia (em dias)",
"Website": "Site",
"Website Description": "Descri\u00e7\u00e3o do site",

View File

@@ -19,7 +19,7 @@ import unittest
import webnotes
import copy
from webnotes.model.wrapper import ModelWrapper
from webnotes.model.bean import Bean
from webnotes.model.doc import Document
from webnotes.utils import flt
@@ -34,7 +34,7 @@ class TestItem(unittest.TestCase):
webnotes.conn.rollback()
def testInsert(self):
d = ModelWrapper()
d = Bean()
count_before = flt(sql("select count(*) from tab"+_doctype)[0][0])
if docok:
@@ -49,7 +49,7 @@ class TestItem(unittest.TestCase):
def testFailAssert(self):
if docnotok:
with self.assertRaises(Exception) as context:
d = ModelWrapper()
d = Bean()
d.doc = docnotok[0]
d.children = None
d.doc.fields['__islocal']=1
@@ -77,6 +77,31 @@ docnotok = [Document(fielddata=r) for r in tabNotOK]
test_records = [
[{
"doctype": "Item",
"item_code": "_Test Item",
"item_name": "_Test Item",
"description": "_Test Item",
"item_group": "_Test Item Group",
"is_stock_item": "Yes",
"is_asset_item": "No",
"has_batch_no": "No",
"has_serial_no": "No",
"is_purchase_item": "Yes",
"is_sales_item": "Yes",
"is_service_item": "No",
"is_sample_item": "No",
"inspection_required": "No",
"is_pro_applicable": "No",
"is_sub_contracted_item": "No",
"stock_uom": "_Test UOM"
}, {
"doctype": "Item Reorder",
"parentfield": "item_reorder",
"warehouse": "_Test Warehouse",
"warehouse_reorder_level": 20,
"warehouse_reorder_qty": 20
}],
[{
"doctype": "Item",
"item_code": "_Test Item Home Desktop 100",

View File

View File

@@ -0,0 +1,8 @@
# For license information, please see license.txt
from __future__ import unicode_literals
import webnotes
class DocType:
def __init__(self, d, dl):
self.doc, self.doclist = d, dl

View File

@@ -0,0 +1,56 @@
[
{
"creation": "2013-02-18 12:48:07",
"docstatus": 0,
"modified": "2013-02-18 12:54:46",
"modified_by": "Administrator",
"owner": "Administrator"
},
{
"autoname": "REORD-.#####",
"doctype": "DocType",
"in_create": 1,
"istable": 1,
"module": "Stock",
"name": "__common__"
},
{
"doctype": "DocField",
"name": "__common__",
"parent": "Item Reorder",
"parentfield": "fields",
"parenttype": "DocType",
"permlevel": 0
},
{
"doctype": "DocType",
"name": "Item Reorder"
},
{
"doctype": "DocField",
"fieldname": "warehouse",
"fieldtype": "Link",
"label": "Warehouse",
"options": "Warehouse",
"reqd": 1
},
{
"doctype": "DocField",
"fieldname": "warehouse_reorder_level",
"fieldtype": "Float",
"label": "Re-order Level"
},
{
"doctype": "DocField",
"fieldname": "warehouse_reorder_qty",
"fieldtype": "Float",
"label": "Re-order Qty"
},
{
"doctype": "DocField",
"fieldname": "material_request_type",
"fieldtype": "Select",
"label": "Material Request Type",
"options": "Purchase\nTransfer"
}
]

View File

@@ -0,0 +1,10 @@
[
"Purchase",
"Re-order Level",
"Material Request Type",
"Item Reorder",
"Transfer",
"Warehouse",
"Re-order Qty",
"Stock"
]

View File

@@ -0,0 +1,10 @@
{
"Item Reorder": "\u0627\u0644\u0628\u0646\u062f \u0625\u0639\u0627\u062f\u0629 \u062a\u0631\u062a\u064a\u0628",
"Material Request Type": "\u0637\u0644\u0628 \u0646\u0648\u0639 \u0627\u0644\u0645\u0648\u0627\u062f",
"Purchase": "\u0634\u0631\u0627\u0621",
"Re-order Level": "\u0625\u0639\u0627\u062f\u0629 \u062a\u0631\u062a\u064a\u0628 \u0645\u0633\u062a\u0648\u0649",
"Re-order Qty": "\u0625\u0639\u0627\u062f\u0629 \u062a\u0631\u062a\u064a\u0628 \u0627\u0644\u0643\u0645\u064a\u0629",
"Stock": "\u0627\u0644\u0623\u0648\u0631\u0627\u0642 \u0627\u0644\u0645\u0627\u0644\u064a\u0629",
"Transfer": "\u0646\u0642\u0644",
"Warehouse": "\u0645\u0633\u062a\u0648\u062f\u0639"
}

View File

@@ -0,0 +1,10 @@
{
"Item Reorder": "Art\u00edculo reorden",
"Material Request Type": "Tipo de material Solicitud",
"Purchase": "Comprar",
"Re-order Level": "Reordenar Nivel",
"Re-order Qty": "Reordenar Cantidad",
"Stock": "Valores",
"Transfer": "Transferir",
"Warehouse": "Almac\u00e9n"
}

View File

@@ -0,0 +1,10 @@
{
"Item Reorder": "R\u00e9organiser article",
"Material Request Type": "Type de demande de mat\u00e9riel",
"Purchase": "Acheter",
"Re-order Level": "Re-order niveau",
"Re-order Qty": "Re-order Quantit\u00e9",
"Stock": "Stock",
"Transfer": "Transf\u00e9rer",
"Warehouse": "Entrep\u00f4t"
}

View File

@@ -0,0 +1,10 @@
{
"Item Reorder": "\u0906\u0907\u091f\u092e \u092a\u0941\u0928\u0903 \u0915\u094d\u0930\u092e\u093f\u0924 \u0915\u0930\u0947\u0902",
"Material Request Type": "\u0938\u093e\u092e\u0917\u094d\u0930\u0940 \u0905\u0928\u0941\u0930\u094b\u0927 \u092a\u094d\u0930\u0915\u093e\u0930",
"Purchase": "\u0915\u094d\u0930\u092f",
"Re-order Level": "\u092a\u0941\u0928 \u0906\u0926\u0947\u0936 \u0938\u094d\u0924\u0930",
"Re-order Qty": "\u092a\u0941\u0928\u0903 \u0906\u0926\u0947\u0936 \u092e\u093e\u0924\u094d\u0930\u093e",
"Stock": "\u0938\u094d\u091f\u0949\u0915",
"Transfer": "\u0939\u0938\u094d\u0924\u093e\u0902\u0924\u0930\u0923",
"Warehouse": "\u0917\u094b\u0926\u093e\u092e"
}

View File

@@ -0,0 +1,10 @@
{
"Item Reorder": "Stavka redoslijeda",
"Material Request Type": "Materijal Zahtjev Tip",
"Purchase": "Kupiti",
"Re-order Level": "Ponovno bi Razina",
"Re-order Qty": "Ponovno bi Kol",
"Stock": "Zaliha",
"Transfer": "Prijenos",
"Warehouse": "Skladi\u0161te"
}

View File

@@ -0,0 +1,10 @@
{
"Item Reorder": "Item opnieuw ordenen",
"Material Request Type": "Materiaal Soort aanvraag",
"Purchase": "Kopen",
"Re-order Level": "Re-order Level",
"Re-order Qty": "Re-order Aantal",
"Stock": "Voorraad",
"Transfer": "Overdracht",
"Warehouse": "Magazijn"
}

View File

@@ -0,0 +1,10 @@
{
"Item Reorder": "Item Reordenar",
"Material Request Type": "Tipo de solicita\u00e7\u00e3o de material",
"Purchase": "Comprar",
"Re-order Level": "Re fim-Level",
"Re-order Qty": "Re-vista Qtde",
"Stock": "Estoque",
"Transfer": "Transferir",
"Warehouse": "Armaz\u00e9m"
}

View File

@@ -18,7 +18,7 @@ from __future__ import unicode_literals
import webnotes
from webnotes.utils import cint, cstr, flt
from webnotes.model.doc import addchild
from webnotes.model.wrapper import getlist
from webnotes.model.bean import getlist
from webnotes.model.code import get_obj
from webnotes import msgprint

View File

@@ -0,0 +1,44 @@
[
"% Ordered",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template",
"Material Request Items",
"IDT",
"Material Request",
"Select Terms and Conditions",
"Draft",
"Name of the entity who has requested for the Purchase Requisition",
"Select Print Heading",
"Stock",
"Status",
"Cancel Reason",
"Terms and Conditions",
"Get Terms and Conditions",
"Company",
"Requested By",
"Amended From",
"File List",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field",
"Remarks",
"Sales Order No",
"To manage multiple series please go to Setup > Manage Series",
"Items",
"Pull Sales Order Items",
"Submitted",
"Fiscal Year",
"Stopped",
"Cancelled",
"MREQ",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.",
"Letter Head",
"Amendment Date",
"The date at which current entry is made in system.",
"Transaction Date",
"Select the relevant company name if you have multiple companies",
"Series",
"The date at which current entry is corrected in the system.",
"% of materials ordered against this Purchase Requisition",
"More Info",
"One or multiple Sales Order no which generated this Purchase Requisition",
"Terms and Conditions Content",
"Print Heading"
]

View File

@@ -0,0 +1,44 @@
{
"% Ordered": "\u0623\u0645\u0631\u062a\u066a",
"% of materials ordered against this Purchase Requisition": "\u0623\u0645\u0631\u062a\u066a \u0645\u0646 \u0627\u0644\u0645\u0648\u0627\u062f \u0636\u062f \u0647\u0630\u0627 \u0637\u0644\u0628 \u0634\u0631\u0627\u0621",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template": "\u0625\u0636\u0627\u0641\u0629 \u0628\u0646\u0648\u062f \u0648\u0634\u0631\u0648\u0637 \u0644\u0644\u0637\u0644\u0628 \u0634\u0631\u0627\u0621. \u064a\u0645\u0643\u0646\u0643 \u0623\u064a\u0636\u0627 \u0628\u0625\u0639\u062f\u0627\u062f \u0627\u0644\u0634\u0631\u0648\u0637 \u0648\u0627\u0644\u0623\u062d\u0643\u0627\u0645 \u0648\u0645\u0627\u062c\u0633\u062a\u064a\u0631 \u0627\u0633\u062a\u062e\u062f\u0627\u0645 \u0627\u0644\u0642\u0627\u0644\u0628",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field": "\u0628\u0639\u062f \u0625\u0644\u063a\u0627\u0621 \u0637\u0644\u0628 \u0634\u0631\u0627\u0621\u060c \u0633\u0648\u0641 \u0645\u0631\u0628\u0639 \u062d\u0648\u0627\u0631 \u064a\u0637\u0644\u0628 \u0645\u0646\u0643 \u0633\u0628\u0628 \u0627\u0644\u0625\u0644\u063a\u0627\u0621 \u0627\u0644\u062a\u064a \u0633\u062a\u0646\u0639\u0643\u0633 \u0641\u064a \u0647\u0630\u0627 \u0627\u0644\u0645\u062c\u0627\u0644",
"Amended From": "\u0639\u062f\u0644 \u0645\u0646",
"Amendment Date": "\u0627\u0644\u062a\u0639\u062f\u064a\u0644 \u062a\u0627\u0631\u064a\u062e",
"Cancel Reason": "\u0625\u0644\u063a\u0627\u0621 \u0627\u0644\u0633\u0628\u0628",
"Cancelled": "\u0625\u0644\u063a\u0627\u0621",
"Company": "\u0634\u0631\u0643\u0629",
"Draft": "\u0645\u0633\u0648\u062f\u0629",
"File List": "\u0645\u0644\u0641 \u0642\u0627\u0626\u0645\u0629",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.": "\u0648\u0631\u0641\u0639 \u0641\u064a \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0625\u0636\u0627\u0641\u064a\u0629 \u062d\u0648\u0644 \u0637\u0644\u0628 \u0634\u0631\u0627\u0621 \u062a\u0633\u0627\u0639\u062f\u0643 \u0639\u0644\u0649 \u062a\u062d\u0644\u064a\u0644 \u0627\u0644\u0628\u064a\u0627\u0646\u0627\u062a \u0627\u0644\u062e\u0627\u0635\u0629 \u0628\u0643 \u0639\u0644\u0649 \u0646\u062d\u0648 \u0623\u0641\u0636\u0644.",
"Fiscal Year": "\u0627\u0644\u0633\u0646\u0629 \u0627\u0644\u0645\u0627\u0644\u064a\u0629",
"Get Terms and Conditions": "\u0627\u0644\u062d\u0635\u0648\u0644 \u0639\u0644\u0649 \u0627\u0644\u0634\u0631\u0648\u0637 \u0648\u0627\u0644\u0623\u062d\u0643\u0627\u0645",
"IDT": "IDT",
"Items": "\u0627\u0644\u0628\u0646\u0648\u062f",
"Letter Head": "\u0631\u0633\u0627\u0644\u0629 \u0631\u0626\u064a\u0633",
"MREQ": "MREQ",
"Material Request": "\u0637\u0644\u0628 \u0627\u0644\u0645\u0648\u0627\u062f",
"Material Request Items": "\u0627\u0644\u0639\u0646\u0627\u0635\u0631 \u0627\u0644\u0645\u0627\u062f\u064a\u0629 \u0637\u0644\u0628",
"More Info": "\u0627\u0644\u0645\u0632\u064a\u062f \u0645\u0646 \u0627\u0644\u0645\u0639\u0644\u0648\u0645\u0627\u062a",
"Name of the entity who has requested for the Purchase Requisition": "\u0627\u0633\u0645 \u0627\u0644\u0643\u064a\u0627\u0646 \u0627\u0644\u0630\u064a \u0627\u0644\u0645\u0637\u0644\u0648\u0628\u0629 \u0644\u0637\u0644\u0628 \u0634\u0631\u0627\u0621",
"One or multiple Sales Order no which generated this Purchase Requisition": "\u0648\u0627\u062d\u062f \u0623\u0648 \u0645\u062a\u0639\u062f\u062f\u0629 \u0644\u0627 \u0645\u0646 \u0623\u062c\u0644 \u0627\u0644\u0645\u0628\u064a\u0639\u0627\u062a \u0627\u0644\u062a\u064a \u0648\u0644\u062f\u062a \u0647\u0630\u0627 \u0637\u0644\u0628 \u0634\u0631\u0627\u0621",
"Print Heading": "\u0637\u0628\u0627\u0639\u0629 \u0639\u0646\u0648\u0627\u0646",
"Pull Sales Order Items": "\u0633\u062d\u0628 \u0639\u0646\u0627\u0635\u0631 \u062a\u0631\u062a\u064a\u0628 \u0627\u0644\u0645\u0628\u064a\u0639\u0627\u062a",
"Remarks": "\u062a\u0635\u0631\u064a\u062d\u0627\u062a",
"Requested By": "\u0627\u0644\u062a\u064a \u0637\u0644\u0628\u062a\u0647\u0627",
"Sales Order No": "\u062a\u0631\u062a\u064a\u0628 \u0627\u0644\u0645\u0628\u064a\u0639\u0627\u062a \u0644\u0627",
"Select Print Heading": "\u062d\u062f\u062f \u0637\u0628\u0627\u0639\u0629 \u0627\u0644\u0639\u0646\u0648\u0627\u0646",
"Select Terms and Conditions": "\u062d\u062f\u062f \u0627\u0644\u0634\u0631\u0648\u0637 \u0648\u0627\u0644\u0623\u062d\u0643\u0627\u0645",
"Select the relevant company name if you have multiple companies": "\u062d\u062f\u062f \u0627\u0633\u0645 \u0627\u0644\u0634\u0631\u0643\u0629 \u0630\u0627\u062a \u0627\u0644\u0635\u0644\u0629 \u0625\u0630\u0627 \u0643\u0627\u0646 \u0644\u062f\u064a\u0643 \u0627\u0644\u0634\u0631\u0643\u0627\u062a \u0645\u062a\u0639\u062f\u062f\u0629",
"Series": "\u0633\u0644\u0633\u0644\u0629",
"Status": "\u062d\u0627\u0644\u0629",
"Stock": "\u0627\u0644\u0623\u0648\u0631\u0627\u0642 \u0627\u0644\u0645\u0627\u0644\u064a\u0629",
"Stopped": "\u062a\u0648\u0642\u0641",
"Submitted": "\u0627\u0644\u0645\u0642\u062f\u0645\u0629",
"Terms and Conditions": "\u0627\u0644\u0634\u0631\u0648\u0637 \u0648\u0627\u0644\u0623\u062d\u0643\u0627\u0645",
"Terms and Conditions Content": "\u0627\u0644\u0634\u0631\u0648\u0637 \u0648\u0627\u0644\u0623\u062d\u0643\u0627\u0645 \u0627\u0644\u0645\u062d\u062a\u0648\u0649",
"The date at which current entry is corrected in the system.": "\u0627\u0644\u062a\u0627\u0631\u064a\u062e \u0627\u0644\u0630\u064a \u064a\u062a\u0645 \u062a\u0635\u062d\u064a\u062d \u0627\u0644\u0625\u062f\u062e\u0627\u0644 \u0627\u0644\u062d\u0627\u0644\u064a \u0641\u064a \u0627\u0644\u0646\u0638\u0627\u0645.",
"The date at which current entry is made in system.": "\u0627\u0644\u062a\u0627\u0631\u064a\u062e \u0627\u0644\u0630\u064a \u064a\u062a\u0645 \u0627\u062f\u062e\u0627\u0644\u0647\u0627 \u0641\u064a \u0627\u0644\u0646\u0638\u0627\u0645 \u0627\u0644\u062d\u0627\u0644\u064a.",
"To manage multiple series please go to Setup > Manage Series": "\u0644\u0625\u062f\u0627\u0631\u0629 \u0633\u0644\u0633\u0644\u0629 \u0645\u062a\u0639\u062f\u062f\u0629 \u064a\u0631\u062c\u0649 \u0627\u0644\u062f\u062e\u0648\u0644 \u0625\u0644\u0649 \u0625\u0639\u062f\u0627\u062f&gt; \u0625\u062f\u0627\u0631\u0629 \u0633\u0644\u0633\u0644\u0629",
"Transaction Date": "\u062a\u0627\u0631\u064a\u062e \u0627\u0644\u0645\u0639\u0627\u0645\u0644\u0629"
}

View File

@@ -0,0 +1,44 @@
{
"% Ordered": "Ordenado%",
"% of materials ordered against this Purchase Requisition": "% De los materiales ordenados en contra de esta solicitud de compra",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template": "A\u00f1adir T\u00e9rminos y Condiciones para la solicitud de compra. Tambi\u00e9n se puede preparar a un Maestro T\u00e9rminos y Condiciones y el uso de la plantilla",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field": "Despu\u00e9s de cancelar la solicitud de compra, aparecer\u00e1 un cuadro de di\u00e1logo le pedir\u00e1 motivo de la cancelaci\u00f3n, que se refleja en este campo",
"Amended From": "De modificada",
"Amendment Date": "Enmienda Fecha",
"Cancel Reason": "Cancelar Raz\u00f3n",
"Cancelled": "Cancelado",
"Company": "Empresa",
"Draft": "Borrador",
"File List": "Lista de archivos",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.": "La presentaci\u00f3n de informaci\u00f3n adicional sobre la solicitud de compra le ayudar\u00e1 a analizar mejor sus datos.",
"Fiscal Year": "A\u00f1o Fiscal",
"Get Terms and Conditions": "C\u00f3mo T\u00e9rminos y Condiciones",
"IDT": "IDT",
"Items": "Art\u00edculos",
"Letter Head": "Carta Head",
"MREQ": "MREQ",
"Material Request": "Material de Solicitud",
"Material Request Items": "Art\u00edculos de materiales Solicitar",
"More Info": "M\u00e1s informaci\u00f3n",
"Name of the entity who has requested for the Purchase Requisition": "Nombre de la persona que ha solicitado para la solicitud de compra",
"One or multiple Sales Order no which generated this Purchase Requisition": "Una o ninguna m\u00faltiples \u00f3rdenes de venta que gener\u00f3 esta solicitud de compra",
"Print Heading": "Imprimir Encabezado",
"Pull Sales Order Items": "Tire de art\u00edculos de \u00f3rdenes de venta",
"Remarks": "Observaciones",
"Requested By": "Solicitado por",
"Sales Order No": "Ventas de orden",
"Select Print Heading": "Seleccione Imprimir Encabezado",
"Select Terms and Conditions": "Seleccione T\u00e9rminos y Condiciones",
"Select the relevant company name if you have multiple companies": "Seleccione el nombre de la empresa correspondiente, si usted tiene m\u00faltiples empresas",
"Series": "Serie",
"Status": "Estado",
"Stock": "Valores",
"Stopped": "Detenido",
"Submitted": "Enviado",
"Terms and Conditions": "T\u00e9rminos y Condiciones",
"Terms and Conditions Content": "T\u00e9rminos y Condiciones Content",
"The date at which current entry is corrected in the system.": "La fecha en la que la entrada actual se corrige en el sistema.",
"The date at which current entry is made in system.": "La fecha en que se efect\u00fae la entrada actual en el sistema.",
"To manage multiple series please go to Setup > Manage Series": "Para gestionar m\u00faltiples series por favor vaya a Configuraci\u00f3n&gt; Administrar Series",
"Transaction Date": "Fecha de Transacci\u00f3n"
}

View File

@@ -0,0 +1,44 @@
{
"% Ordered": "Command\u00e9%",
"% of materials ordered against this Purchase Requisition": "% De mat\u00e9riaux prononc\u00e9e \u00e0 l&#39;encontre de cette demande d&#39;achat",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template": "Ajouter Termes et Conditions de la demande d&#39;achat. Vous pouvez \u00e9galement pr\u00e9parer un cadre et une ma\u00eetrise de l&#39;\u00e9tat et utiliser le mod\u00e8le de",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field": "Apr\u00e8s l&#39;annulation de la demande d&#39;achat, une bo\u00eete de dialogue vous demandera raison de l&#39;annulation qui sera refl\u00e9t\u00e9 dans ce domaine",
"Amended From": "De modifi\u00e9e",
"Amendment Date": "Date de la modification",
"Cancel Reason": "Annuler Raison",
"Cancelled": "Annul\u00e9",
"Company": "Entreprise",
"Draft": "Avant-projet",
"File List": "Liste des fichiers",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.": "D\u00e9p\u00f4t dans les Renseignements additionnels au sujet de la demande d&#39;achat vous aidera \u00e0 analyser vos donn\u00e9es de meilleure qualit\u00e9.",
"Fiscal Year": "Exercice",
"Get Terms and Conditions": "Obtenez Termes et Conditions",
"IDT": "IDT",
"Items": "Articles",
"Letter Head": "A en-t\u00eate",
"MREQ": "MREQ",
"Material Request": "Demande de mat\u00e9riel",
"Material Request Items": "Articles Demande de mat\u00e9riel",
"More Info": "Plus d&#39;infos",
"Name of the entity who has requested for the Purchase Requisition": "Nom de l&#39;entit\u00e9 qui a demand\u00e9 pour la demande d&#39;achat",
"One or multiple Sales Order no which generated this Purchase Requisition": "Un ou plusieurs pas de commande client qui a g\u00e9n\u00e9r\u00e9 cette demande d&#39;achat",
"Print Heading": "Imprimer Cap",
"Pull Sales Order Items": "Tirez Articles Sales Order",
"Remarks": "Remarques",
"Requested By": "Demand\u00e9 par",
"Sales Order No": "Ordonnance n \u00b0 de vente",
"Select Print Heading": "S\u00e9lectionnez Imprimer Cap",
"Select Terms and Conditions": "S\u00e9lectionnez Termes et Conditions",
"Select the relevant company name if you have multiple companies": "S\u00e9lectionnez le nom de l&#39;entreprise concern\u00e9e si vous avez de multiples entreprises",
"Series": "S\u00e9rie",
"Status": "Statut",
"Stock": "Stock",
"Stopped": "Arr\u00eat\u00e9",
"Submitted": "Soumis",
"Terms and Conditions": "Termes et Conditions",
"Terms and Conditions Content": "Termes et Conditions de contenu",
"The date at which current entry is corrected in the system.": "La date \u00e0 laquelle l&#39;entr\u00e9e courante est corrig\u00e9e dans le syst\u00e8me.",
"The date at which current entry is made in system.": "La date \u00e0 laquelle l&#39;entr\u00e9e courante est faite dans le syst\u00e8me.",
"To manage multiple series please go to Setup > Manage Series": "Pour g\u00e9rer plusieurs s\u00e9ries s&#39;il vous pla\u00eet allez dans R\u00e9glages&gt; G\u00e9rer S\u00e9rie",
"Transaction Date": "Date de la transaction"
}

View File

@@ -0,0 +1,44 @@
{
"% Ordered": "% \u0915\u093e \u0906\u0926\u0947\u0936 \u0926\u093f\u092f\u093e",
"% of materials ordered against this Purchase Requisition": "\u0938\u093e\u092e\u0917\u094d\u0930\u0940 \u0915\u0947% \u0907\u0938 \u0916\u0930\u0940\u0926 \u0905\u0927\u093f\u0917\u094d\u0930\u0939\u0923 \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u0906\u0926\u0947\u0936 \u0926\u093f\u092f\u093e \u0939\u0948",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template": "\u0916\u0930\u0940\u0926 \u0905\u0927\u093f\u0917\u094d\u0930\u0939\u0923 \u0915\u0947 \u0932\u093f\u090f \u0928\u093f\u092f\u092e \u0914\u0930 \u0936\u0930\u094d\u0924\u094b\u0902 \u0915\u094b \u091c\u094b\u0921\u093c\u0947\u0902. \u0924\u0941\u092e \u092d\u0940 \u090f\u0915 \u0928\u093f\u092f\u092e \u0914\u0930 \u0936\u0930\u094d\u0924\u0947\u0902 \u092e\u093e\u0938\u094d\u091f\u0930 \u0924\u0948\u092f\u093e\u0930 \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902 \u091f\u0947\u092e\u094d\u092a\u0932\u0947\u091f \u0915\u093e \u0909\u092a\u092f\u094b\u0917 \u0915\u0930\u0947\u0902",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field": "\u0916\u0930\u0940\u0926 \u0905\u0927\u093f\u0917\u094d\u0930\u0939\u0923 \u0930\u0926\u094d\u0926 \u0915\u0930\u0928\u0947 \u0915\u0947 \u092c\u093e\u0926, \u090f\u0915 \u0938\u0902\u0935\u093e\u0926 \u092c\u0949\u0915\u094d\u0938 \u0906\u092a \u0930\u0926\u094d\u0926 \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u0915\u093e\u0930\u0923 \u0939\u0948 \u091c\u094b \u0907\u0938 \u0915\u094d\u0937\u0947\u0924\u094d\u0930 \u092e\u0947\u0902 \u092a\u0930\u093f\u0932\u0915\u094d\u0937\u093f\u0924 \u0939\u094b\u0917\u093e \u092a\u0942\u091b\u0928\u093e \u0939\u094b\u0917\u093e",
"Amended From": "\u0938\u0947 \u0938\u0902\u0936\u094b\u0927\u093f\u0924",
"Amendment Date": "\u0938\u0902\u0936\u094b\u0927\u0928 \u0924\u093f\u0925\u093f",
"Cancel Reason": "\u0915\u093e\u0930\u0923 \u0930\u0926\u094d\u0926 \u0915\u0930\u0947\u0902",
"Cancelled": "Cancelled",
"Company": "\u0915\u0902\u092a\u0928\u0940",
"Draft": "\u092e\u0938\u094c\u0926\u093e",
"File List": "\u092b\u093c\u093e\u0907\u0932 \u0938\u0942\u091a\u0940",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.": "\u0916\u0930\u0940\u0926 \u0905\u0927\u093f\u0917\u094d\u0930\u0939\u0923 \u0915\u0947 \u092c\u093e\u0930\u0947 \u092e\u0947\u0902 \u0905\u0924\u093f\u0930\u093f\u0915\u094d\u0924 \u0938\u0942\u091a\u0928\u093e \u092e\u0947\u0902 \u092b\u093e\u0907\u0932\u093f\u0902\u0917 \u092e\u0947\u0902 \u092e\u0926\u0926 \u092e\u093f\u0932\u0947\u0917\u0940 \u0906\u092a \u0905\u092a\u0928\u0947 \u0921\u0947\u091f\u093e \u0915\u093e \u0935\u093f\u0936\u094d\u0932\u0947\u0937\u0923 \u092c\u0947\u0939\u0924\u0930.",
"Fiscal Year": "\u0935\u093f\u0924\u094d\u0924\u0940\u092f \u0935\u0930\u094d\u0937",
"Get Terms and Conditions": "\u0928\u093f\u092f\u092e \u0914\u0930 \u0936\u0930\u094d\u0924\u0947\u0902",
"IDT": "IDT",
"Items": "\u0906\u0907\u091f\u092e",
"Letter Head": "\u092a\u0924\u094d\u0930\u0936\u0940\u0930\u094d\u0937",
"MREQ": "MREQ",
"Material Request": "\u0938\u093e\u092e\u0917\u094d\u0930\u0940 \u0905\u0928\u0941\u0930\u094b\u0927",
"Material Request Items": "\u0938\u093e\u092e\u0917\u094d\u0930\u0940 \u0905\u0928\u0941\u0930\u094b\u0927 \u0906\u0907\u091f\u092e",
"More Info": "\u0905\u0927\u093f\u0915 \u091c\u093e\u0928\u0915\u093e\u0930\u0940",
"Name of the entity who has requested for the Purchase Requisition": "\u0907\u0915\u093e\u0908 \u0939\u0948 \u091c\u094b \u0916\u0930\u0940\u0926 \u0905\u0927\u093f\u0917\u094d\u0930\u0939\u0923 \u0915\u0947 \u0932\u093f\u090f \u0905\u0928\u0941\u0930\u094b\u0927 \u0915\u093f\u092f\u093e \u0939\u0948 \u0915\u0947 \u0928\u093e\u092e",
"One or multiple Sales Order no which generated this Purchase Requisition": "\u090f\u0915 \u092f\u093e \u0915\u0908 \u092c\u093f\u0915\u094d\u0930\u0940 \u0906\u0926\u0947\u0936 \u0928\u0939\u0940\u0902 \u091c\u094b \u0907\u0938 \u0916\u0930\u0940\u0926 \u0905\u0927\u093f\u0917\u094d\u0930\u0939\u0923 \u0909\u0924\u094d\u092a\u0928\u094d\u0928",
"Print Heading": "\u0936\u0940\u0930\u094d\u0937\u0915 \u092a\u094d\u0930\u093f\u0902\u091f",
"Pull Sales Order Items": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0906\u0926\u0947\u0936 \u0906\u0907\u091f\u092e \u0916\u0940\u0902\u091a\u094b",
"Remarks": "\u091f\u093f\u092a\u094d\u092a\u0923\u093f\u092f\u093e\u0901",
"Requested By": "\u0926\u094d\u0935\u093e\u0930\u093e \u0905\u0928\u0941\u0930\u094b\u0927 \u0915\u093f\u092f\u093e",
"Sales Order No": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0906\u0926\u0947\u0936 \u0928\u0939\u0940\u0902",
"Select Print Heading": "\u091a\u092f\u0928 \u0936\u0940\u0930\u094d\u0937\u0915 \u092a\u094d\u0930\u093f\u0902\u091f",
"Select Terms and Conditions": "\u0928\u093f\u092f\u092e\u094b\u0902 \u0914\u0930 \u0936\u0930\u094d\u0924\u094b\u0902 \u0915\u093e \u091a\u092f\u0928 \u0915\u0930\u0947\u0902",
"Select the relevant company name if you have multiple companies": "\u0905\u0917\u0930 \u0906\u092a \u0915\u0908 \u0915\u0902\u092a\u0928\u093f\u092f\u094b\u0902 \u092a\u094d\u0930\u093e\u0938\u0902\u0917\u093f\u0915 \u0915\u0902\u092a\u0928\u0940 \u0915\u0947 \u0928\u093e\u092e \u0915\u093e \u091a\u092f\u0928 \u0915\u0930\u0947\u0902",
"Series": "\u0915\u0908",
"Status": "\u0939\u0948\u0938\u093f\u092f\u0924",
"Stock": "\u0938\u094d\u091f\u0949\u0915",
"Stopped": "\u0930\u094b\u0915",
"Submitted": "\u092a\u0947\u0936",
"Terms and Conditions": "\u0928\u093f\u092f\u092e \u0914\u0930 \u0936\u0930\u094d\u0924\u0947\u0902",
"Terms and Conditions Content": "\u0928\u093f\u092f\u092e \u0914\u0930 \u0936\u0930\u094d\u0924\u0947\u0902 \u0938\u093e\u092e\u0917\u094d\u0930\u0940",
"The date at which current entry is corrected in the system.": "\u091c\u094b \u0924\u093e\u0930\u0940\u0916 \u0935\u0930\u094d\u0924\u092e\u093e\u0928 \u092a\u094d\u0930\u0935\u093f\u0937\u094d\u091f\u093f \u092a\u094d\u0930\u0923\u093e\u0932\u0940 \u092e\u0947\u0902 \u0938\u0939\u0940 \u0939\u0948.",
"The date at which current entry is made in system.": "\u0924\u093e\u0930\u0940\u0916, \u091c\u093f\u0938 \u092a\u0930 \u0935\u0930\u094d\u0924\u092e\u093e\u0928 \u092a\u094d\u0930\u0935\u093f\u0937\u094d\u091f\u093f \u092a\u094d\u0930\u0923\u093e\u0932\u0940 \u092e\u0947\u0902 \u0915\u093f\u092f\u093e \u091c\u093e\u0924\u093e \u0939\u0948.",
"To manage multiple series please go to Setup > Manage Series": "\u090f\u0915\u093e\u0927\u093f\u0915 \u0936\u094d\u0930\u0943\u0902\u0916\u0932\u093e \u0915\u093e \u092a\u094d\u0930\u092c\u0902\u0927\u0928 \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u0938\u0947\u091f\u0905\u092a \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u091c\u093e\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u0915\u0943\u092a\u092f\u093e \u0936\u094d\u0930\u0943\u0902\u0916\u0932\u093e \u092a\u094d\u0930\u092c\u0902\u0927\u0928",
"Transaction Date": "\u0932\u0947\u0928\u0926\u0947\u0928 \u0915\u0940 \u0924\u093e\u0930\u0940\u0916"
}

View File

@@ -0,0 +1,44 @@
{
"% Ordered": "% \u017d",
"% of materials ordered against this Purchase Requisition": "% Materijala naredio protiv ove kupnje rekvizicije",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template": "Dodaj Uvjete za kupnju rekvizicija. Tako\u0111er mo\u017eete pripremiti Uvjeti i odredbe Master i koristiti predlo\u017eak",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field": "Nakon poni\u0161tenja Kupnja rekvizicije, dijalo\u0161ki okvir \u0107e vas pitati razlog za otkaz koji \u0107e se odraziti i na tom polju",
"Amended From": "Izmijenjena Od",
"Amendment Date": "Amandman Datum",
"Cancel Reason": "Odustani razlog",
"Cancelled": "Otkazan",
"Company": "Dru\u0161tvo",
"Draft": "Skica",
"File List": "Popis datoteka",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.": "Podno\u0161enje u dodatne informacije o kupoprodaji rekvizicije \u0107e vam pomo\u0107i da analizirati podatke bolje.",
"Fiscal Year": "Fiskalna godina",
"Get Terms and Conditions": "Nabavite Uvjeti i pravila",
"IDT": "IDT",
"Items": "Proizvodi",
"Letter Head": "Pismo Head",
"MREQ": "MREQ",
"Material Request": "Materijal zahtjev",
"Material Request Items": "Materijalni Zahtjev Proizvodi",
"More Info": "Vi\u0161e informacija",
"Name of the entity who has requested for the Purchase Requisition": "Naziv subjekta koji je zatra\u017eio za kupnju rekvizicija",
"One or multiple Sales Order no which generated this Purchase Requisition": "Jedan ili vi\u0161e prodajnog naloga ne koji generira ovu Kupnja rekvizicije",
"Print Heading": "Ispis Naslov",
"Pull Sales Order Items": "Povucite Prodaja Predmeti Naru\u010divanje",
"Remarks": "Primjedbe",
"Requested By": "Tra\u017eeni Do",
"Sales Order No": "Prodajnog naloga Ne",
"Select Print Heading": "Odaberite Ispis Naslov",
"Select Terms and Conditions": "Odaberite Uvjeti i pravila",
"Select the relevant company name if you have multiple companies": "Odaberite odgovaraju\u0107i naziv tvrtke ako imate vi\u0161e tvrtki",
"Series": "Serija",
"Status": "Status",
"Stock": "Zaliha",
"Stopped": "Zaustavljen",
"Submitted": "Prijavljen",
"Terms and Conditions": "Odredbe i uvjeti",
"Terms and Conditions Content": "Uvjeti sadr\u017eaj",
"The date at which current entry is corrected in the system.": "Datum na koji teku\u0107i zapis ispravljen u sustavu.",
"The date at which current entry is made in system.": "Datum na koji teku\u0107i zapis se sastoji u sustavu.",
"To manage multiple series please go to Setup > Manage Series": "Za upravljati s vi\u0161e niz molimo idite na Postavke&gt; Upravljanje serije",
"Transaction Date": "Transakcija Datum"
}

View File

@@ -0,0 +1,44 @@
{
"% Ordered": "% Geordende",
"% of materials ordered against this Purchase Requisition": "% Van de bestelde materialen tegen deze inkoopaanvraag",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template": "Voeg Voorwaarden voor de inkoopaanvraag. U kunt ook bereiden een Algemene voorwaarden Master en gebruik maken van de sjabloon",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field": "Na het opheffen van de inkoopaanvraag, zal een dialoogvenster vraagt \u200b\u200bu reden voor de annulering die zal worden weerspiegeld in dit gebied",
"Amended From": "Gewijzigd Van",
"Amendment Date": "Wijziging Datum",
"Cancel Reason": "Annuleren Reden",
"Cancelled": "Geannuleerd",
"Company": "Vennootschap",
"Draft": "Ontwerp",
"File List": "File List",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.": "Het indienen van aanvullende informatie over de inkoopaanvraag helpt u bij het analyseren van uw gegevens beter.",
"Fiscal Year": "Boekjaar",
"Get Terms and Conditions": "Get Algemene Voorwaarden",
"IDT": "IDT",
"Items": "Artikelen",
"Letter Head": "Brief Hoofd",
"MREQ": "MREQ",
"Material Request": "Materiaal aanvragen",
"Material Request Items": "Materiaal aanvragen Items",
"More Info": "Meer info",
"Name of the entity who has requested for the Purchase Requisition": "Naam van de instantie die heeft verzocht om de inkoopaanvraag",
"One or multiple Sales Order no which generated this Purchase Requisition": "Een of meerdere Sales Bestelnr die dit inkoopaanvraag gegenereerd",
"Print Heading": "Print rubriek",
"Pull Sales Order Items": "Trek Sales Order Items",
"Remarks": "Opmerkingen",
"Requested By": "Aangevraagd door",
"Sales Order No": "Sales Order No",
"Select Print Heading": "Selecteer Print rubriek",
"Select Terms and Conditions": "Selecteer Algemene Voorwaarden",
"Select the relevant company name if you have multiple companies": "Selecteer de gewenste bedrijfsnaam als u meerdere bedrijven",
"Series": "Serie",
"Status": "Staat",
"Stock": "Voorraad",
"Stopped": "Gestopt",
"Submitted": "Ingezonden",
"Terms and Conditions": "Algemene Voorwaarden",
"Terms and Conditions Content": "Voorwaarden Inhoud",
"The date at which current entry is corrected in the system.": "De datum waarop huidige item wordt gecorrigeerd in het systeem.",
"The date at which current entry is made in system.": "De datum waarop huidige item wordt gemaakt in het systeem.",
"To manage multiple series please go to Setup > Manage Series": "Om meerdere reeksen te beheren gaat u naar Setup&gt; Beheer-serie",
"Transaction Date": "Transactie Datum"
}

View File

@@ -0,0 +1,44 @@
{
"% Ordered": "Ordenado%",
"% of materials ordered against this Purchase Requisition": "% De materiais encomendados contra esta requisi\u00e7\u00e3o de compra",
"Add Terms and Conditions for the Purchase Requisition. You can also prepare a Terms and Conditions Master and use the Template": "Adicione Termos e Condi\u00e7\u00f5es para a requisi\u00e7\u00e3o de compra. Voc\u00ea tamb\u00e9m pode preparar um Termos e Condi\u00e7\u00f5es mestre e usar o modelo",
"After cancelling the Purchase Requisition, a dialog box will ask you reason for cancellation which will be reflected in this field": "Depois de cancelar a requisi\u00e7\u00e3o de compra, uma caixa de di\u00e1logo ir\u00e1 pedir-lhe raz\u00e3o para cancelamento que ser\u00e1 refletido neste campo",
"Amended From": "Alterado De",
"Amendment Date": "Data emenda",
"Cancel Reason": "Cancelar Raz\u00e3o",
"Cancelled": "Cancelado",
"Company": "Companhia",
"Draft": "Rascunho",
"File List": "Lista de Arquivos",
"Filing in Additional Information about the Purchase Requisition will help you analyze your data better.": "Apresenta\u00e7\u00e3o de informa\u00e7\u00f5es adicionais sobre a requisi\u00e7\u00e3o de compra vai ajudar a analisar melhor seus dados.",
"Fiscal Year": "Exerc\u00edcio fiscal",
"Get Terms and Conditions": "Obter os Termos e Condi\u00e7\u00f5es",
"IDT": "IDT",
"Items": "Itens",
"Letter Head": "Cabe\u00e7a letra",
"MREQ": "Mreq",
"Material Request": "Pedido de material",
"Material Request Items": "Pedido de itens de material",
"More Info": "Mais informa\u00e7\u00f5es",
"Name of the entity who has requested for the Purchase Requisition": "Nome da entidade que solicitou para a requisi\u00e7\u00e3o de compra",
"One or multiple Sales Order no which generated this Purchase Requisition": "Um ou nenhum Ordem m\u00faltipla de vendas que gerou esta requisi\u00e7\u00e3o de compra",
"Print Heading": "Imprimir t\u00edtulo",
"Pull Sales Order Items": "Puxe itens da ordem",
"Remarks": "Observa\u00e7\u00f5es",
"Requested By": "Solicitado por",
"Sales Order No": "Vendas decreto n \u00ba",
"Select Print Heading": "Selecione Imprimir t\u00edtulo",
"Select Terms and Conditions": "Selecione Termos e Condi\u00e7\u00f5es",
"Select the relevant company name if you have multiple companies": "Selecione o nome da empresa em quest\u00e3o, se voc\u00ea tem v\u00e1rias empresas",
"Series": "S\u00e9rie",
"Status": "Estado",
"Stock": "Estoque",
"Stopped": "Parado",
"Submitted": "Enviado",
"Terms and Conditions": "Termos e Condi\u00e7\u00f5es",
"Terms and Conditions Content": "Termos e Condi\u00e7\u00f5es conte\u00fado",
"The date at which current entry is corrected in the system.": "A data em que a entrada actual \u00e9 corrigido no sistema.",
"The date at which current entry is made in system.": "A data em que a entrada actual \u00e9 feita no sistema.",
"To manage multiple series please go to Setup > Manage Series": "Para gerenciar v\u00e1rias s\u00e9ries por favor, v\u00e1 para Configura\u00e7\u00e3o&gt; Gerenciar Series",
"Transaction Date": "Data Transa\u00e7\u00e3o"
}

View File

@@ -0,0 +1,127 @@
// 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/>.
cur_frm.cscript.tname = "Material Request Item";
cur_frm.cscript.fname = "indent_details";
wn.require('app/buying/doctype/purchase_common/purchase_common.js');
wn.require('app/utilities/doctype/sms_control/sms_control.js');
erpnext.buying.MaterialRequestController = erpnext.buying.BuyingController.extend({
refresh: function(doc) {
this._super();
if(doc.docstatus == 1 && doc.status != 'Stopped'){
if(doc.material_request_type === "Purchase")
cur_frm.add_custom_button("Make Supplier Quotation", cur_frm.cscript.make_supplier_quotation);
if(doc.material_request_type === "Transfer" && doc.status === "Submitted")
cur_frm.add_custom_button("Transfer Material", cur_frm.cscript.make_stock_entry);
if(flt(doc.per_ordered, 2) < 100) {
if(doc.material_request_type === "Purchase")
cur_frm.add_custom_button('Make Purchase Order', cur_frm.cscript['Make Purchase Order']);
cur_frm.add_custom_button('Stop Material Request', cur_frm.cscript['Stop Material Request']);
}
cur_frm.add_custom_button('Send SMS', cur_frm.cscript.send_sms);
}
if(doc.docstatus == 1 && doc.status == 'Stopped')
cur_frm.add_custom_button('Unstop Material Request', cur_frm.cscript['Unstop Material Request']);
if(doc.material_request_type === "Transfer") {
cur_frm.toggle_display("sales_order_no", false);
cur_frm.fields_dict.indent_details.grid.set_column_disp("sales_order_no", false);
}
}
});
var new_cscript = new erpnext.buying.MaterialRequestController({frm: cur_frm});
// for backward compatibility: combine new and previous states
$.extend(cur_frm.cscript, new_cscript);
cur_frm.cscript.onload = function(doc, cdt, cdn) {
if (!doc.transaction_date) doc.transaction_date = dateutil.obj_to_str(new Date());
if (!doc.status) doc.status = 'Draft';
// defined in purchase_common.js
//cur_frm.cscript.update_item_details(doc, cdt, cdn);
};
cur_frm.cscript.onload_post_render = function(doc, cdt, cdn) {
// second call
if(doc.__islocal){
cur_frm.cscript.get_item_defaults(doc);
}
};
cur_frm.cscript.get_item_defaults = function(doc) {
var ch = getchildren( 'Material Request Item', doc.name, 'indent_details');
if (flt(ch.length) > 0){
$c_obj(make_doclist(doc.doctype, doc.name), 'get_item_defaults', '', function(r, rt) {refresh_field('indent_details'); });
}
};
cur_frm.cscript.transaction_date = function(doc,cdt,cdn){
if(doc.__islocal){
cur_frm.cscript.get_default_schedule_date(doc);
}
};
cur_frm.cscript.qty = function(doc, cdt, cdn) {
var d = locals[cdt][cdn];
if (flt(d.qty) < flt(d.min_order_qty))
alert("Warning: Material Requested Qty is less than Minimum Order Qty");
};
cur_frm.cscript['Stop Material Request'] = function() {
var doc = cur_frm.doc;
var check = confirm("Do you really want to STOP this Material Request?");
if (check) {
$c('runserverobj', args={'method':'update_status', 'arg': 'Stopped', 'docs': wn.model.compress(make_doclist(doc.doctype, doc.name))}, function(r,rt) {
cur_frm.refresh();
});
}
};
cur_frm.cscript['Unstop Material Request'] = function(){
var doc = cur_frm.doc;
var check = confirm("Do you really want to UNSTOP this Material Request?");
if (check) {
$c('runserverobj', args={'method':'update_status', 'arg': 'Submitted','docs': wn.model.compress(make_doclist(doc.doctype, doc.name))}, function(r,rt) {
cur_frm.refresh();
});
}
};
cur_frm.cscript['Make Purchase Order'] = function() {
cur_frm.map([["Material Request", "Purchase Order"], ["Material Request Item", "Purchase Order Item"]]);
};
cur_frm.cscript.make_supplier_quotation = function() {
cur_frm.map([["Material Request", "Supplier Quotation"], ["Material Request Item", "Supplier Quotation Item"]]);
};
cur_frm.cscript.make_stock_entry = function() {
cur_frm.map([["Material Request", "Stock Entry"], ["Material Request Item", "Stock Entry Detail"]]);
};

View File

@@ -0,0 +1,224 @@
# ERPNext - web based ERP (http://erpnext.com)
# For license information, please see license.txt
from __future__ import unicode_literals
import webnotes
from webnotes.utils import cstr, flt
from webnotes.model.bean import getlist
from webnotes.model.code import get_obj
from webnotes import msgprint
from controllers.buying_controller import BuyingController
class DocType(BuyingController):
def __init__(self, doc, doclist=[]):
self.doc = doc
self.doclist = doclist
self.tname = 'Material Request Item'
self.fname = 'indent_details'
def get_default_schedule_date(self):
get_obj(dt = 'Purchase Common').get_default_schedule_date(self)
# get available qty at warehouse
def get_bin_details(self, arg = ''):
return get_obj(dt='Purchase Common').get_bin_details(arg)
# Pull Sales Order Items
# -------------------------
def pull_so_details(self):
self.check_if_already_pulled()
if self.doc.sales_order_no:
get_obj('DocType Mapper', 'Sales Order-Material Request', with_children=1).dt_map('Sales Order', 'Material Request', self.doc.sales_order_no, self.doc, self.doclist, "[['Sales Order', 'Material Request'],['Sales Order Item', 'Material Request Item']]")
self.get_item_defaults()
else:
msgprint("Please select Sales Order whose details need to pull")
def check_if_already_pulled(self):
pass#if self.[d.sales_order_no for d in getlist(self.doclist, 'indent_details')]
# Get item's other details
#- ------------------------
def get_item_defaults(self):
self.get_default_schedule_date()
for d in getlist(self.doclist, 'indent_details'):
det = webnotes.conn.sql("select min_order_qty from tabItem where name = '%s'" % d.item_code)
d.min_order_qty = det and flt(det[0][0]) or 0
# Validate so items
# ----------------------------
def validate_qty_against_so(self):
so_items = {} # Format --> {'SO/00001': {'Item/001': 120, 'Item/002': 24}}
for d in getlist(self.doclist, 'indent_details'):
if d.sales_order_no:
if not so_items.has_key(d.sales_order_no):
so_items[d.sales_order_no] = {d.item_code: flt(d.qty)}
else:
if not so_items[d.sales_order_no].has_key(d.item_code):
so_items[d.sales_order_no][d.item_code] = flt(d.qty)
else:
so_items[d.sales_order_no][d.item_code] += flt(d.qty)
for so_no in so_items.keys():
for item in so_items[so_no].keys():
already_indented = webnotes.conn.sql("select sum(qty) from `tabMaterial Request Item` where item_code = '%s' and sales_order_no = '%s' and docstatus = 1 and parent != '%s'" % (item, so_no, self.doc.name))
already_indented = already_indented and flt(already_indented[0][0]) or 0
actual_so_qty = webnotes.conn.sql("select sum(qty) from `tabSales Order Item` where parent = '%s' and item_code = '%s' and docstatus = 1 group by parent" % (so_no, item))
actual_so_qty = actual_so_qty and flt(actual_so_qty[0][0]) or 0
if flt(so_items[so_no][item]) + already_indented > actual_so_qty:
msgprint("You can raise indent of maximum qty: %s for item: %s against sales order: %s\n Anyway, you can add more qty in new row for the same item." % (actual_so_qty - already_indented, item, so_no), raise_exception=1)
# Validate fiscal year
# ----------------------------
def validate_fiscal_year(self):
get_obj(dt = 'Purchase Common').validate_fiscal_year(self.doc.fiscal_year,self.doc.transaction_date,'Material Request Date')
# GET TERMS & CONDITIONS
#-----------------------------
def get_tc_details(self):
return get_obj('Purchase Common').get_tc_details(self)
# Validate Schedule Date
#--------------------------------
def validate_schedule_date(self):
#:::::::: validate schedule date v/s indent date ::::::::::::
for d in getlist(self.doclist, 'indent_details'):
if d.schedule_date < self.doc.transaction_date:
msgprint("Expected Schedule Date cannot be before Material Request Date")
raise Exception
# Validate
# ---------------------
def validate(self):
super(DocType, self).validate()
self.validate_schedule_date()
self.validate_fiscal_year()
if not self.doc.status:
self.doc.status = "Draft"
import utilities
utilities.validate_status(self.doc.status, ["Draft", "Submitted", "Stopped",
"Cancelled"])
# Get Purchase Common Obj
pc_obj = get_obj(dt='Purchase Common')
# Validate for items
pc_obj.validate_for_items(self)
# Validate qty against SO
self.validate_qty_against_so()
def update_bin(self, is_submit, is_stopped):
""" Update Quantity Requested for Purchase in Bin for Material Request of type 'Purchase'"""
if self.doc.material_request_type == "Purchase":
for d in getlist(self.doclist, 'indent_details'):
if webnotes.conn.get_value("Item", d.item_code, "is_stock_item") == "Yes":
if not d.warehouse:
msgprint("Please Enter Warehouse for Item %s as it is stock item"
% cstr(d.item_code), raise_exception=1)
qty =flt(d.qty)
if is_stopped:
qty = (d.qty > d.ordered_qty) and flt(flt(d.qty) - flt(d.ordered_qty)) or 0
args = {
"item_code": d.item_code,
"indented_qty": (is_submit and 1 or -1) * flt(qty),
"posting_date": self.doc.transaction_date
}
get_obj('Warehouse', d.warehouse).update_bin(args)
def on_submit(self):
purchase_controller = webnotes.get_obj("Purchase Common")
purchase_controller.is_item_table_empty(self)
webnotes.conn.set(self.doc,'status','Submitted')
self.update_bin(is_submit = 1, is_stopped = 0)
def check_modified_date(self):
mod_db = webnotes.conn.sql("select modified from `tabMaterial Request` where name = '%s'" % self.doc.name)
date_diff = webnotes.conn.sql("select TIMEDIFF('%s', '%s')" % ( mod_db[0][0],cstr(self.doc.modified)))
if date_diff and date_diff[0][0]:
msgprint(cstr(self.doc.doctype) +" => "+ cstr(self.doc.name) +" has been modified. Please Refresh. ")
raise Exception
def update_status(self, status):
self.check_modified_date()
# Step 1:=> Update Bin
self.update_bin(is_submit = (status == 'Submitted') and 1 or 0, is_stopped = 1)
# Step 2:=> Set status
webnotes.conn.set(self.doc,'status',cstr(status))
# Step 3:=> Acknowledge User
msgprint(self.doc.doctype + ": " + self.doc.name + " has been %s." % ((status == 'Submitted') and 'Unstopped' or cstr(status)) )
def on_cancel(self):
# Step 1:=> Get Purchase Common Obj
pc_obj = get_obj(dt='Purchase Common')
# Step 2:=> Check for stopped status
pc_obj.check_for_stopped_status(self.doc.doctype, self.doc.name)
# Step 3:=> Check if Purchase Order has been submitted against current Material Request
pc_obj.check_docstatus(check = 'Next', doctype = 'Purchase Order', docname = self.doc.name, detail_doctype = 'Purchase Order Item')
# Step 4:=> Update Bin
self.update_bin(is_submit = 0, is_stopped = (cstr(self.doc.status) == 'Stopped') and 1 or 0)
# Step 5:=> Set Status
webnotes.conn.set(self.doc,'status','Cancelled')
def update_completed_qty(self, mr_items=None):
if self.doc.material_request_type != "Transfer":
return
item_doclist = self.doclist.get({"parentfield": "indent_details"})
if not mr_items:
mr_items = [d.name for d in item_doclist]
per_ordered = 0.0
for d in item_doclist:
if d.name in mr_items:
d.ordered_qty = flt(webnotes.conn.sql("""select sum(transfer_qty)
from `tabStock Entry Detail` where material_request = %s
and material_request_item = %s and docstatus = 1""",
(self.doc.name, d.name))[0][0])
webnotes.conn.set_value(d.doctype, d.name, "ordered_qty", d.ordered_qty)
# note: if qty is 0, its row is still counted in len(item_doclist)
# hence adding 1 to per_ordered
if (d.ordered_qty > d.qty) or not d.qty:
per_ordered += 1.0
elif d.qty > 0:
per_ordered += flt(d.ordered_qty / flt(d.qty))
if per_ordered:
self.doc.per_ordered = flt((per_ordered / flt(len(item_doclist))) * 100.0, 2)
webnotes.conn.set_value(self.doc.doctype, self.doc.name, "per_ordered", self.doc.per_ordered)
def update_completed_qty(controller, caller_method):
if controller.doc.doctype == "Stock Entry":
material_request_map = {}
for d in controller.doclist.get({"parentfield": "mtn_details"}):
if d.material_request:
if d.material_request not in material_request_map:
material_request_map[d.material_request] = []
material_request_map[d.material_request].append(d.material_request_item)
for mr_name, mr_items in material_request_map.items():
webnotes.get_obj("Material Request", mr_name, with_children=1).update_completed_qty(mr_items)

View File

@@ -0,0 +1,429 @@
[
{
"creation": "2013-02-20 13:25:31",
"docstatus": 0,
"modified": "2013-02-21 10:59:09",
"modified_by": "Administrator",
"owner": "Administrator"
},
{
"allow_attach": 1,
"allow_print": 0,
"autoname": "naming_series:",
"doctype": "DocType",
"is_submittable": 1,
"module": "Stock",
"name": "__common__",
"read_only_onload": 1,
"search_fields": "status,transaction_date,sales_order_no"
},
{
"doctype": "DocField",
"name": "__common__",
"parent": "Material Request",
"parentfield": "fields",
"parenttype": "DocType",
"permlevel": 0
},
{
"doctype": "DocPerm",
"name": "__common__",
"parent": "Material Request",
"parentfield": "permissions",
"parenttype": "DocType",
"read": 1
},
{
"doctype": "DocType",
"name": "Material Request"
},
{
"doctype": "DocField",
"fieldname": "material_request_type",
"fieldtype": "Select",
"in_list_view": 1,
"label": "Material Request Type",
"options": "Purchase\nTransfer",
"reqd": 1
},
{
"doctype": "DocField",
"fieldname": "column_break_2",
"fieldtype": "Column Break"
},
{
"description": "To manage multiple series please go to Setup > Manage Series",
"doctype": "DocField",
"fieldname": "naming_series",
"fieldtype": "Select",
"label": "Series",
"no_copy": 1,
"oldfieldname": "naming_series",
"oldfieldtype": "Select",
"options": "MREQ-\nIDT",
"print_hide": 1,
"reqd": 1
},
{
"doctype": "DocField",
"fieldname": "items",
"fieldtype": "Section Break",
"label": "Items",
"oldfieldtype": "Section Break"
},
{
"allow_on_submit": 1,
"doctype": "DocField",
"fieldname": "indent_details",
"fieldtype": "Table",
"label": "Material Request Items",
"no_copy": 0,
"oldfieldname": "indent_details",
"oldfieldtype": "Table",
"options": "Material Request Item"
},
{
"doctype": "DocField",
"fieldname": "section_break1",
"fieldtype": "Section Break",
"options": "Simple"
},
{
"doctype": "DocField",
"fieldname": "column_break4",
"fieldtype": "Column Break",
"print_width": "50%",
"width": "50%"
},
{
"description": "One or multiple Sales Order no which generated this Material Request",
"doctype": "DocField",
"fieldname": "sales_order_no",
"fieldtype": "Link",
"label": "Sales Order No",
"no_copy": 1,
"oldfieldname": "sales_order_no",
"oldfieldtype": "Data",
"options": "Sales Order",
"print_width": "100px",
"width": "100px"
},
{
"doctype": "DocField",
"fieldname": "column_break5",
"fieldtype": "Column Break",
"print_width": "50%",
"width": "50%"
},
{
"doctype": "DocField",
"fieldname": "pull_sales_order_details",
"fieldtype": "Button",
"label": "Pull Sales Order Items",
"options": "pull_so_details"
},
{
"default": "Give additional details about the indent.",
"description": "Filing in Additional Information about the Material Request will help you analyze your data better.",
"doctype": "DocField",
"fieldname": "more_info",
"fieldtype": "Section Break",
"label": "More Info",
"oldfieldtype": "Section Break"
},
{
"doctype": "DocField",
"fieldname": "column_break1",
"fieldtype": "Column Break",
"oldfieldtype": "Column Break",
"print_width": "50%",
"width": "50%"
},
{
"description": "The date at which current entry is made in system.",
"doctype": "DocField",
"fieldname": "transaction_date",
"fieldtype": "Date",
"in_filter": 1,
"label": "Transaction Date",
"no_copy": 1,
"oldfieldname": "transaction_date",
"oldfieldtype": "Date",
"print_width": "100px",
"reqd": 1,
"search_index": 1,
"width": "100px"
},
{
"description": "Select the relevant company name if you have multiple companies",
"doctype": "DocField",
"fieldname": "company",
"fieldtype": "Link",
"in_filter": 1,
"label": "Company",
"oldfieldname": "company",
"oldfieldtype": "Link",
"options": "Company",
"print_hide": 1,
"print_width": "150px",
"reqd": 1,
"search_index": 1,
"width": "150px"
},
{
"doctype": "DocField",
"fieldname": "fiscal_year",
"fieldtype": "Select",
"in_filter": 1,
"label": "Fiscal Year",
"oldfieldname": "fiscal_year",
"oldfieldtype": "Select",
"options": "link:Fiscal Year",
"print_hide": 1,
"print_width": "150px",
"reqd": 1,
"search_index": 1,
"width": "150px"
},
{
"description": "Name of the entity who has requested for the Material Request",
"doctype": "DocField",
"fieldname": "requested_by",
"fieldtype": "Data",
"in_list_view": 0,
"label": "Requested By",
"no_copy": 1,
"oldfieldname": "requested_by",
"oldfieldtype": "Data",
"print_width": "100px",
"width": "100px"
},
{
"doctype": "DocField",
"fieldname": "column_break2",
"fieldtype": "Column Break",
"oldfieldtype": "Column Break",
"print_width": "50%",
"width": "50%"
},
{
"allow_on_submit": 1,
"doctype": "DocField",
"fieldname": "letter_head",
"fieldtype": "Select",
"label": "Letter Head",
"oldfieldname": "letter_head",
"oldfieldtype": "Select",
"options": "link:Letter Head",
"print_hide": 1
},
{
"doctype": "DocField",
"fieldname": "status",
"fieldtype": "Select",
"in_filter": 1,
"in_list_view": 1,
"label": "Status",
"no_copy": 1,
"oldfieldname": "status",
"oldfieldtype": "Select",
"options": "\nDraft\nSubmitted\nStopped\nCancelled",
"print_hide": 1,
"print_width": "100px",
"read_only": 1,
"reqd": 0,
"search_index": 1,
"width": "100px"
},
{
"description": "% of materials ordered against this Material Request",
"doctype": "DocField",
"fieldname": "per_ordered",
"fieldtype": "Percent",
"in_list_view": 1,
"label": "% Completed",
"no_copy": 1,
"oldfieldname": "per_ordered",
"oldfieldtype": "Currency",
"print_hide": 1,
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "amended_from",
"fieldtype": "Data",
"label": "Amended From",
"no_copy": 1,
"oldfieldname": "amended_from",
"oldfieldtype": "Data",
"print_hide": 1,
"print_width": "150px",
"read_only": 1,
"width": "150px"
},
{
"description": "The date at which current entry is corrected in the system.",
"doctype": "DocField",
"fieldname": "amendment_date",
"fieldtype": "Date",
"label": "Amendment Date",
"no_copy": 1,
"oldfieldname": "amendment_date",
"oldfieldtype": "Date",
"print_hide": 1,
"print_width": "100px",
"width": "100px"
},
{
"doctype": "DocField",
"fieldname": "remark",
"fieldtype": "Small Text",
"in_list_view": 0,
"label": "Remarks",
"no_copy": 1,
"oldfieldname": "remark",
"oldfieldtype": "Small Text",
"print_hide": 0,
"print_width": "150px",
"width": "150px"
},
{
"description": "Add Terms and Conditions for the Material Request. You can also prepare a Terms and Conditions Master and use the Template",
"doctype": "DocField",
"fieldname": "terms_section_break",
"fieldtype": "Section Break",
"label": "Terms and Conditions",
"oldfieldtype": "Section Break"
},
{
"doctype": "DocField",
"fieldname": "tc_name",
"fieldtype": "Link",
"label": "Select Terms and Conditions",
"oldfieldname": "tc_name",
"oldfieldtype": "Link",
"options": "Terms and Conditions",
"print_hide": 1,
"report_hide": 1
},
{
"doctype": "DocField",
"fieldname": "get_terms",
"fieldtype": "Button",
"label": "Get Terms and Conditions",
"oldfieldtype": "Button",
"options": "get_tc_details"
},
{
"doctype": "DocField",
"fieldname": "terms",
"fieldtype": "Text Editor",
"label": "Terms and Conditions Content",
"oldfieldname": "terms",
"oldfieldtype": "Text Editor"
},
{
"allow_on_submit": 1,
"doctype": "DocField",
"fieldname": "select_print_heading",
"fieldtype": "Select",
"label": "Select Print Heading",
"options": "Print Heading",
"print_hide": 1
},
{
"doctype": "DocField",
"fieldname": "file_list",
"fieldtype": "Text",
"hidden": 1,
"label": "File List",
"no_copy": 1,
"print_hide": 1
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"report": 0,
"role": "Purchase Manager",
"submit": 0,
"write": 0
},
{
"amend": 1,
"cancel": 1,
"create": 1,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "Purchase Manager",
"submit": 1,
"write": 1
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"report": 0,
"role": "Material Manager",
"submit": 0,
"write": 0
},
{
"amend": 1,
"cancel": 1,
"create": 1,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "Material Manager",
"submit": 1,
"write": 1
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"report": 0,
"role": "Material User",
"submit": 0,
"write": 0
},
{
"amend": 1,
"cancel": 1,
"create": 1,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "Material User",
"submit": 1,
"write": 1
},
{
"amend": 1,
"cancel": 1,
"create": 1,
"doctype": "DocPerm",
"permlevel": 0,
"report": 1,
"role": "Purchase User",
"submit": 1,
"write": 1
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"doctype": "DocPerm",
"permlevel": 1,
"role": "Purchase User",
"submit": 0
}
]

View File

@@ -0,0 +1,118 @@
# ERPNext - web based ERP (http://erpnext.com)
# For license information, please see license.txt
from __future__ import unicode_literals
import webnotes, unittest
class TestMaterialRequest(unittest.TestCase):
def _test_expected(self, doclist, expected_values):
for i, expected in enumerate(expected_values):
for fieldname, val in expected.items():
self.assertEquals(val, doclist[i].fields.get(fieldname))
def test_completed_qty_for_purchase(self):
# submit material request of type Purchase
mr = webnotes.bean(copy=test_records[0])
mr.insert()
mr.submit()
# check if per complete is None
self._test_expected(mr.doclist, [{"per_ordered": None}, {"ordered_qty": None}, {"ordered_qty": None}])
# map a purchase order
po = webnotes.map_doclist([["Material Request", "Purchase Order"],
["Material Request Item", "Purchase Order Item"]], mr.doc.name)
po = webnotes.bean(po)
po.doc.fields.update({
"supplier": "_Test Supplier",
"supplier_name": "_Test Supplier",
"transaction_date": mr.doc.transaction_date,
"fiscal_year": "_Test Fiscal Year 2013",
"currency": "INR",
"conversion_rate": 1.0,
"grand_total_import": 0.0
})
po.doclist[1].qty = 27.0
po.doclist[2].qty = 1.5
po.insert()
po.submit()
# check if per complete is as expected
mr.load_from_db()
self._test_expected(mr.doclist, [{"per_ordered": 50}, {"ordered_qty": 27.0}, {"ordered_qty": 1.5}])
po.cancel()
# check if per complete is as expected
mr.load_from_db()
self._test_expected(mr.doclist, [{"per_ordered": 0}, {"ordered_qty": 0}, {"ordered_qty": 0}])
def test_completed_qty_for_transfer(self):
# submit material request of type Purchase
mr = webnotes.bean(copy=test_records[0])
mr.doc.material_request_type = "Transfer"
mr.insert()
mr.submit()
# check if per complete is None
self._test_expected(mr.doclist, [{"per_ordered": None}, {"ordered_qty": None}, {"ordered_qty": None}])
# map a stock entry
se = webnotes.map_doclist([["Material Request", "Stock Entry"],
["Material Request Item", "Stock Entry Detail"]], mr.doc.name)
se = webnotes.bean(se)
se.doc.fields.update({
"posting_date": "2013-03-01",
"posting_time": "00:00"
})
se.doclist[1].fields.update({
"qty": 27.0,
"transfer_qty": 27.0,
"s_warehouse": "_Test Warehouse 1",
"incoming_rate": 1.0
})
se.doclist[2].fields.update({
"qty": 1.5,
"transfer_qty": 1.5,
"s_warehouse": "_Test Warehouse 1",
"incoming_rate": 1.0
})
se.insert()
se.submit()
# check if per complete is as expected
mr.load_from_db()
self._test_expected(mr.doclist, [{"per_ordered": 50}, {"ordered_qty": 27.0}, {"ordered_qty": 1.5}])
test_records = [
[
{
"company": "_Test Company",
"doctype": "Material Request",
"fiscal_year": "_Test Fiscal Year 2013",
"transaction_date": "2013-02-18",
"material_request_type": "Purchase"
},
{
"description": "_Test Item Home Desktop 100",
"doctype": "Material Request Item",
"item_code": "_Test Item Home Desktop 100",
"item_name": "_Test Item Home Desktop 100",
"parentfield": "indent_details",
"qty": 54.0,
"schedule_date": "2013-02-18",
"uom": "_Test UOM",
"warehouse": "_Test Warehouse"
},
{
"description": "_Test Item Home Desktop 200",
"doctype": "Material Request Item",
"item_code": "_Test Item Home Desktop 200",
"item_name": "_Test Item Home Desktop 200",
"parentfield": "indent_details",
"qty": 3.0,
"schedule_date": "2013-02-19",
"uom": "_Test UOM",
"warehouse": "_Test Warehouse"
}
]
]

View File

@@ -0,0 +1,19 @@
[
"Item Name",
"Description",
"Required Date",
"Lead Time Date",
"Brand",
"Ordered Qty",
"Sales Order No",
"Page Break",
"Stock UOM",
"Material Request Item",
"Min Order Qty",
"Item Group",
"Warehouse",
"Projected Qty",
"Quantity",
"Item Code",
"Stock"
]

View File

@@ -0,0 +1,19 @@
{
"Brand": "\u0639\u0644\u0627\u0645\u0629 \u062a\u062c\u0627\u0631\u064a\u0629",
"Description": "\u0648\u0635\u0641",
"Item Code": "\u0627\u0644\u0628\u0646\u062f \u0627\u0644\u0631\u0645\u0632",
"Item Group": "\u0627\u0644\u0628\u0646\u062f \u0627\u0644\u0645\u062c\u0645\u0648\u0639\u0629",
"Item Name": "\u0627\u0644\u0628\u0646\u062f \u0627\u0644\u0627\u0633\u0645",
"Lead Time Date": "\u062a\u0624\u062f\u064a \u062a\u0627\u0631\u064a\u062e \u0627\u0644\u0648\u0642\u062a",
"Material Request Item": "\u0637\u0644\u0628 \u0627\u0644\u0645\u0648\u0627\u062f \u0627\u0644\u0625\u063a\u0644\u0627\u0642",
"Min Order Qty": "\u062f\u0642\u064a\u0642\u0629 \u0627\u0644\u0643\u0645\u064a\u0629 \u062a\u0631\u062a\u064a\u0628",
"Ordered Qty": "\u0623\u0645\u0631\u062a \u0627\u0644\u0643\u0645\u064a\u0647",
"Page Break": "\u0627\u0644\u0635\u0641\u062d\u0629 \u0627\u0633\u062a\u0631\u0627\u062d\u0629",
"Projected Qty": "\u0627\u0644\u0643\u0645\u064a\u0629 \u0627\u0644\u0645\u062a\u0648\u0642\u0639",
"Quantity": "\u0643\u0645\u064a\u0629",
"Required Date": "\u062a\u0627\u0631\u064a\u062e \u0627\u0644\u0645\u0637\u0644\u0648\u0628\u0629",
"Sales Order No": "\u062a\u0631\u062a\u064a\u0628 \u0627\u0644\u0645\u0628\u064a\u0639\u0627\u062a \u0644\u0627",
"Stock": "\u0627\u0644\u0623\u0648\u0631\u0627\u0642 \u0627\u0644\u0645\u0627\u0644\u064a\u0629",
"Stock UOM": "\u0627\u0644\u0623\u0633\u0647\u0645 UOM",
"Warehouse": "\u0645\u0633\u062a\u0648\u062f\u0639"
}

View File

@@ -0,0 +1,19 @@
{
"Brand": "Marca",
"Description": "Descripci\u00f3n",
"Item Code": "C\u00f3digo del art\u00edculo",
"Item Group": "Grupo de art\u00edculos",
"Item Name": "Nombre del elemento",
"Lead Time Date": "Plomo Fecha Hora",
"Material Request Item": "Art\u00edculo Material Request",
"Min Order Qty": "Min. Orden Cantidad",
"Ordered Qty": "Cantidad Pedido",
"Page Break": "Salto de p\u00e1gina",
"Projected Qty": "Cantidad proyectada",
"Quantity": "Cantidad",
"Required Date": "Fecha requerida",
"Sales Order No": "Ventas de orden",
"Stock": "Valores",
"Stock UOM": "De la UOM",
"Warehouse": "Almac\u00e9n"
}

View File

@@ -0,0 +1,19 @@
{
"Brand": "Marque",
"Description": "Description",
"Item Code": "Code de l&#39;article",
"Item Group": "Groupe d&#39;\u00e9l\u00e9ments",
"Item Name": "Nom d&#39;article",
"Lead Time Date": "Plomb Date Heure",
"Material Request Item": "Article demande de mat\u00e9riel",
"Min Order Qty": "Quantit\u00e9 de commande minimale",
"Ordered Qty": "Qt\u00e9 command\u00e9e",
"Page Break": "Saut de page",
"Projected Qty": "Qt\u00e9 projet\u00e9",
"Quantity": "Quantit\u00e9",
"Required Date": "Requis Date",
"Sales Order No": "Ordonnance n \u00b0 de vente",
"Stock": "Stock",
"Stock UOM": "Stock UDM",
"Warehouse": "Entrep\u00f4t"
}

View File

@@ -0,0 +1,19 @@
{
"Brand": "\u092c\u094d\u0930\u093e\u0902\u0921",
"Description": "\u0935\u093f\u0935\u0930\u0923",
"Item Code": "\u0906\u0907\u091f\u092e \u0915\u094b\u0921",
"Item Group": "\u0906\u0907\u091f\u092e \u0938\u092e\u0942\u0939",
"Item Name": "\u092e\u0926 \u0915\u093e \u0928\u093e\u092e",
"Lead Time Date": "\u0932\u0940\u0921 \u0926\u093f\u0928\u093e\u0902\u0915 \u0914\u0930 \u0938\u092e\u092f",
"Material Request Item": "\u0938\u093e\u092e\u0917\u094d\u0930\u0940 \u0905\u0928\u0941\u0930\u094b\u0927 \u0906\u0907\u091f\u092e",
"Min Order Qty": "\u0928\u094d\u092f\u0942\u0928\u0924\u092e \u0906\u0926\u0947\u0936 \u092e\u093e\u0924\u094d\u0930\u093e",
"Ordered Qty": "\u0939\u093f\u0938\u093e\u092c \u0938\u0947 \u092e\u093e\u0924\u094d\u0930\u093e",
"Page Break": "\u092a\u0943\u0937\u094d\u0920\u093e\u0924\u0930",
"Projected Qty": "\u0905\u0928\u0941\u092e\u093e\u0928\u093f\u0924 \u092e\u093e\u0924\u094d\u0930\u093e",
"Quantity": "\u092e\u093e\u0924\u094d\u0930\u093e",
"Required Date": "\u0906\u0935\u0936\u094d\u092f\u0915 \u0924\u093f\u0925\u093f",
"Sales Order No": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0906\u0926\u0947\u0936 \u0928\u0939\u0940\u0902",
"Stock": "\u0938\u094d\u091f\u0949\u0915",
"Stock UOM": "\u0938\u094d\u091f\u0949\u0915 UOM",
"Warehouse": "\u0917\u094b\u0926\u093e\u092e"
}

View File

@@ -0,0 +1,19 @@
{
"Brand": "Marka",
"Description": "Opis",
"Item Code": "Stavka \u0160ifra",
"Item Group": "Stavka Grupa",
"Item Name": "Stavka Ime",
"Lead Time Date": "Olovo Time Date",
"Material Request Item": "Materijal Zahtjev artikla",
"Min Order Qty": "Min Red Kol",
"Ordered Qty": "\u017d Kol",
"Page Break": "Prijelom stranice",
"Projected Qty": "Predvi\u0111en Kol",
"Quantity": "Koli\u010dina",
"Required Date": "Potrebna Datum",
"Sales Order No": "Prodajnog naloga Ne",
"Stock": "Zaliha",
"Stock UOM": "Katalo\u0161ki UOM",
"Warehouse": "Skladi\u0161te"
}

View File

@@ -0,0 +1,19 @@
{
"Brand": "Merk",
"Description": "Beschrijving",
"Item Code": "Artikelcode",
"Item Group": "Item Group",
"Item Name": "Naam van het punt",
"Lead Time Date": "Lead Tijd Datum",
"Material Request Item": "Materiaal aanvragen Item",
"Min Order Qty": "Minimum Aantal",
"Ordered Qty": "Besteld Aantal",
"Page Break": "Pagina-einde",
"Projected Qty": "Verwachte Aantal",
"Quantity": "Hoeveelheid",
"Required Date": "Vereiste Datum",
"Sales Order No": "Sales Order No",
"Stock": "Voorraad",
"Stock UOM": "Stock Verpakking",
"Warehouse": "Magazijn"
}

View File

@@ -0,0 +1,19 @@
{
"Brand": "Marca",
"Description": "Descri\u00e7\u00e3o",
"Item Code": "C\u00f3digo do artigo",
"Item Group": "Grupo Item",
"Item Name": "Nome do item",
"Lead Time Date": "Chumbo Data Hora",
"Material Request Item": "Item de solicita\u00e7\u00e3o de material",
"Min Order Qty": "Min Qty Ordem",
"Ordered Qty": "Qtde ordenou",
"Page Break": "Quebra de p\u00e1gina",
"Projected Qty": "Qtde Projetada",
"Quantity": "Quantidade",
"Required Date": "Data Obrigat\u00f3rio",
"Sales Order No": "Vendas decreto n \u00ba",
"Stock": "Estoque",
"Stock UOM": "Estoque UOM",
"Warehouse": "Armaz\u00e9m"
}

View File

@@ -0,0 +1,8 @@
# For license information, please see license.txt
from __future__ import unicode_literals
import webnotes
class DocType:
def __init__(self, d, dl):
self.doc, self.doclist = d, dl

View File

@@ -0,0 +1,207 @@
[
{
"creation": "2013-02-20 13:25:31",
"docstatus": 0,
"modified": "2013-02-20 14:06:58",
"modified_by": "Administrator",
"owner": "Administrator"
},
{
"autoname": "MREQD-.#####",
"doctype": "DocType",
"istable": 1,
"module": "Stock",
"name": "__common__"
},
{
"doctype": "DocField",
"name": "__common__",
"parent": "Material Request Item",
"parentfield": "fields",
"parenttype": "DocType",
"permlevel": 0
},
{
"doctype": "DocType",
"name": "Material Request Item"
},
{
"allow_on_submit": 0,
"doctype": "DocField",
"fieldname": "schedule_date",
"fieldtype": "Date",
"label": "Required Date",
"no_copy": 1,
"oldfieldname": "schedule_date",
"oldfieldtype": "Date",
"print_hide": 0,
"reqd": 1,
"width": "100px"
},
{
"doctype": "DocField",
"fieldname": "item_code",
"fieldtype": "Link",
"in_filter": 1,
"label": "Item Code",
"oldfieldname": "item_code",
"oldfieldtype": "Link",
"options": "Item",
"reqd": 1,
"search_index": 1,
"width": "100px"
},
{
"doctype": "DocField",
"fieldname": "description",
"fieldtype": "Text",
"label": "Description",
"oldfieldname": "description",
"oldfieldtype": "Text",
"reqd": 1,
"width": "250px"
},
{
"doctype": "DocField",
"fieldname": "warehouse",
"fieldtype": "Link",
"label": "Warehouse",
"oldfieldname": "warehouse",
"oldfieldtype": "Link",
"options": "Warehouse",
"print_hide": 0,
"reqd": 0,
"width": "100px"
},
{
"default": "0.00",
"doctype": "DocField",
"fieldname": "qty",
"fieldtype": "Float",
"label": "Quantity",
"no_copy": 0,
"oldfieldname": "qty",
"oldfieldtype": "Currency",
"reqd": 1,
"width": "80px"
},
{
"doctype": "DocField",
"fieldname": "uom",
"fieldtype": "Link",
"label": "Stock UOM",
"no_copy": 0,
"oldfieldname": "uom",
"oldfieldtype": "Link",
"options": "UOM",
"read_only": 1,
"reqd": 1,
"width": "70px"
},
{
"doctype": "DocField",
"fieldname": "lead_time_date",
"fieldtype": "Date",
"label": "Lead Time Date",
"no_copy": 1,
"oldfieldname": "lead_time_date",
"oldfieldtype": "Date",
"print_hide": 1,
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "item_name",
"fieldtype": "Data",
"in_filter": 1,
"label": "Item Name",
"oldfieldname": "item_name",
"oldfieldtype": "Data",
"reqd": 1,
"search_index": 1,
"width": "100px"
},
{
"doctype": "DocField",
"fieldname": "item_group",
"fieldtype": "Link",
"in_filter": 1,
"label": "Item Group",
"no_copy": 0,
"oldfieldname": "item_group",
"oldfieldtype": "Link",
"options": "Item Group",
"print_hide": 1,
"read_only": 1,
"reqd": 0,
"search_index": 1
},
{
"doctype": "DocField",
"fieldname": "brand",
"fieldtype": "Link",
"label": "Brand",
"oldfieldname": "brand",
"oldfieldtype": "Link",
"options": "Brand",
"print_hide": 1,
"read_only": 1,
"width": "100px"
},
{
"doctype": "DocField",
"fieldname": "min_order_qty",
"fieldtype": "Float",
"label": "Min Order Qty",
"no_copy": 1,
"oldfieldname": "min_order_qty",
"oldfieldtype": "Currency",
"print_hide": 1,
"read_only": 1,
"reqd": 0,
"width": "70px"
},
{
"doctype": "DocField",
"fieldname": "projected_qty",
"fieldtype": "Float",
"label": "Projected Qty",
"no_copy": 1,
"oldfieldname": "projected_qty",
"oldfieldtype": "Currency",
"print_hide": 1,
"read_only": 1,
"width": "70px"
},
{
"doctype": "DocField",
"fieldname": "ordered_qty",
"fieldtype": "Float",
"label": "Completed Qty",
"no_copy": 1,
"oldfieldname": "ordered_qty",
"oldfieldtype": "Currency",
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "sales_order_no",
"fieldtype": "Link",
"label": "Sales Order No",
"no_copy": 1,
"options": "Sales Order",
"print_hide": 1,
"read_only": 1
},
{
"allow_on_submit": 1,
"doctype": "DocField",
"fieldname": "page_break",
"fieldtype": "Check",
"label": "Page Break",
"no_copy": 1,
"oldfieldname": "page_break",
"oldfieldtype": "Check",
"print_hide": 1
}
]

View File

@@ -17,9 +17,9 @@
from __future__ import unicode_literals
import webnotes
from webnotes.utils import cstr, flt, get_defaults
from webnotes.utils import cstr, flt
from webnotes.model.doc import addchild
from webnotes.model.wrapper import getlist
from webnotes.model.bean import getlist
from webnotes.model.code import get_obj
from webnotes import msgprint
@@ -30,7 +30,6 @@ class DocType(BuyingController):
def __init__(self, doc, doclist=[]):
self.doc = doc
self.doclist = doclist
self.defaults = get_defaults()
self.tname = 'Purchase Receipt Item'
self.fname = 'purchase_receipt_details'
self.count = 0
@@ -297,7 +296,7 @@ class DocType(BuyingController):
# 4.Update Bin
self.update_stock(is_submit = 0)
# 5.Update Purchase Requests Pending Qty and accordingly it's Status
# 5.Update Material Requests Pending Qty and accordingly it's Status
pc_obj.update_prevdoc_detail(self, is_submit = 0)
# 6. Update last purchase rate

View File

@@ -20,7 +20,7 @@ import webnotes
from webnotes.utils import flt
from webnotes.model import db_exists
from webnotes.model.doc import addchild
from webnotes.model.wrapper import copy_doclist
from webnotes.model.bean import copy_doclist
sql = webnotes.conn.sql

View File

@@ -41,7 +41,7 @@ class TestSerialNo(unittest.TestCase):
["2012-01-01", "02:00", "10006", 1200, 800],
["2012-01-01", "06:00", "10007", 1500, 900]]
for d in data:
webnotes.model_wrapper([{
webnotes.bean([{
"doctype": "Serial No",
"item_code": "Nebula 8",
"warehouse": "Default Warehouse",

View File

@@ -19,7 +19,7 @@ import webnotes
from webnotes.utils import cstr, cint, flt, comma_or
from webnotes.model.doc import Document, addchild
from webnotes.model.wrapper import getlist
from webnotes.model.bean import getlist
from webnotes.model.code import get_obj
from webnotes import msgprint, _
from stock.utils import get_incoming_rate

View File

@@ -0,0 +1,103 @@
# ERPNext - web based ERP (http://erpnext.com)
# For license information, please see license.txt
from __future__ import unicode_literals
import webnotes, unittest
class TestStockEntry(unittest.TestCase):
def test_auto_material_request(self):
webnotes.conn.sql("""delete from `tabMaterial Request Item`""")
webnotes.conn.sql("""delete from `tabMaterial Request`""")
st1 = webnotes.bean(copy=test_records[0])
st1.insert()
st1.submit()
st2 = webnotes.bean(copy=test_records[1])
st2.insert()
st2.submit()
mr_name = webnotes.conn.sql("""select parent from `tabMaterial Request Item`
where item_code='_Test Item'""")
self.assertTrue(mr_name)
test_records = [
[
{
"company": "_Test Company",
"doctype": "Stock Entry",
"posting_date": "2013-01-25",
"posting_time": "17:14:24",
"purpose": "Material Receipt"
},
{
"conversion_factor": 1.0,
"doctype": "Stock Entry Detail",
"item_code": "_Test Item",
"parentfield": "mtn_details",
"incoming_rate": 100,
"qty": 50.0,
"stock_uom": "_Test UOM",
"transfer_qty": 50.0,
"uom": "_Test UOM",
"t_warehouse": "_Test Warehouse",
},
],
[
{
"company": "_Test Company",
"doctype": "Stock Entry",
"posting_date": "2013-01-25",
"posting_time": "17:15",
"purpose": "Material Issue"
},
{
"conversion_factor": 1.0,
"doctype": "Stock Entry Detail",
"item_code": "_Test Item",
"parentfield": "mtn_details",
"incoming_rate": 100,
"qty": 40.0,
"stock_uom": "_Test UOM",
"transfer_qty": 40.0,
"uom": "_Test UOM",
"s_warehouse": "_Test Warehouse",
},
],
[
{
"company": "_Test Company",
"doctype": "Stock Entry",
"posting_date": "2013-01-25",
"posting_time": "17:14:24",
"purpose": "Material Transfer"
},
{
"conversion_factor": 1.0,
"doctype": "Stock Entry Detail",
"item_code": "_Test Item Home Desktop 100",
"parentfield": "mtn_details",
"incoming_rate": 100,
"qty": 45.0,
"stock_uom": "_Test UOM",
"transfer_qty": 45.0,
"uom": "_Test UOM",
"s_warehouse": "_Test Warehouse",
"t_warehouse": "_Test Warehouse 1",
},
{
"conversion_factor": 1.0,
"doctype": "Stock Entry Detail",
"item_code": "_Test Item Home Desktop 100",
"parentfield": "mtn_details",
"qty": 45.0,
"incoming_rate": 100,
"stock_uom": "_Test UOM",
"transfer_qty": 45.0,
"uom": "_Test UOM",
"s_warehouse": "_Test Warehouse",
"t_warehouse": "_Test Warehouse 1",
}
]
]

View File

@@ -1,8 +1,8 @@
[
{
"creation": "2013-01-14 16:33:34",
"creation": "2013-01-29 19:25:45",
"docstatus": 0,
"modified": "2013-01-29 16:27:57",
"modified": "2013-02-20 16:46:26",
"modified_by": "Administrator",
"owner": "Administrator"
},
@@ -195,5 +195,28 @@
"options": "BOM",
"print_hide": 1,
"read_only": 0
},
{
"description": "Material Request used to make this Stock Entry",
"doctype": "DocField",
"fieldname": "material_request",
"fieldtype": "Link",
"hidden": 1,
"label": "Material Request",
"no_copy": 1,
"options": "Material Request",
"print_hide": 1,
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "material_request_item",
"fieldtype": "Link",
"hidden": 1,
"label": "Material Request Item",
"no_copy": 1,
"options": "Material Request Item",
"print_hide": 1,
"read_only": 1
}
]

View File

@@ -19,7 +19,7 @@ import webnotes
from webnotes.utils import add_days, cstr, flt, nowdate, cint
from webnotes.model.doc import Document
from webnotes.model.wrapper import getlist
from webnotes.model.bean import getlist
from webnotes.model.code import get_obj
from webnotes import session, msgprint
from stock.utils import get_valid_serial_nos
@@ -221,7 +221,7 @@ class DocType:
if args.get("warehouse"):
args["warehouse_type"] = webnotes.conn.get_value('Warehouse' , args["warehouse"],
'warehouse_type')
sle = webnotes.model_wrapper([args])
sle = webnotes.bean([args])
sle.ignore_permissions = 1
sle.insert()
return sle.doc.name

View File

@@ -248,7 +248,7 @@ class DocType(DocListController):
}
args.update(opts)
# create stock ledger entry
sle_wrapper = webnotes.model_wrapper([args])
sle_wrapper = webnotes.bean([args])
sle_wrapper.ignore_permissions = 1
sle_wrapper.insert()

View File

@@ -115,7 +115,7 @@ class TestStockReconciliation(unittest.TestCase):
self.setUp()
def submit_stock_reconciliation(self, qty, rate, posting_date, posting_time):
return webnotes.model_wrapper([{
return webnotes.bean([{
"doctype": "Stock Reconciliation",
"name": "RECO-001",
"__islocal": 1,

View File

@@ -19,7 +19,7 @@ import webnotes
from webnotes.utils import cstr, flt, now
from webnotes.model import db_exists
from webnotes.model.wrapper import copy_doclist
from webnotes.model.bean import copy_doclist
from webnotes.model.code import get_obj
from webnotes import msgprint

View File

@@ -3,5 +3,10 @@ test_records = [
"doctype": "Warehouse",
"warehouse_name": "_Test Warehouse",
"warehouse_type": "_Test Warehouse Type"
}]
]
}],
[{
"doctype": "Warehouse",
"warehouse_name": "_Test Warehouse 1",
"warehouse_type": "_Test Warehouse Type"
}]
]

View File

@@ -34,7 +34,7 @@ class DocType:
warehouse = %s", (item_code, warehouse))
bin = bin and bin[0][0] or ''
if not bin:
bin_wrapper = webnotes.model_wrapper([{
bin_wrapper = webnotes.bean([{
"doctype": "Bin",
"item_code": item_code,
"warehouse": warehouse,
@@ -158,7 +158,7 @@ class DocType:
def repost_indented_qty(self, bin):
indented_qty = webnotes.conn.sql("""select sum(pr_item.qty - pr_item.ordered_qty)
from `tabPurchase Request Item` pr_item, `tabPurchase Request` pr
from `tabMaterial Request Item` pr_item, `tabMaterial Request` pr
where pr_item.item_code=%s and pr_item.warehouse=%s
and pr_item.qty > pr_item.ordered_qty and pr_item.parent=pr.name
and pr.status!='Stopped' and pr.docstatus=1"""

View File

@@ -6,6 +6,11 @@ wn.module_page["Stock"] = [
title: wn._("Documents"),
icon: "icon-copy",
items: [
{
label: wn._("Material Request"),
description: wn._("Request Material for Transfer or Purchase."),
doctype:"Material Request"
},
{
label: wn._("Stock Entry"),
description: wn._("Transfer stock from one warehouse to another."),

View File

@@ -40,7 +40,7 @@ erpnext.StockLevel = erpnext.StockGridReport.extend({
parent: $(wrapper).find('.layout-main'),
appframe: wrapper.appframe,
doctypes: ["Item", "Warehouse", "Stock Ledger Entry", "Production Order",
"Purchase Request Item", "Purchase Order Item", "Sales Order Item", "Brand"],
"Material Request Item", "Purchase Order Item", "Sales Order Item", "Brand"],
});
this.wrapper.bind("make", function() {
@@ -164,7 +164,7 @@ erpnext.StockLevel = erpnext.StockGridReport.extend({
$.each([
["Stock Ledger Entry", "actual_qty"],
["Production Order", "planned_qty"],
["Purchase Request Item", "requested_qty"],
["Material Request Item", "requested_qty"],
["Purchase Order Item", "ordered_qty"],
["Sales Order Item", "reserved_qty"]],
function(i, v) {

View File

@@ -86,7 +86,7 @@ def update_entries_after(args, verbose=1):
# update bin
if not webnotes.conn.exists({"doctype": "Bin", "item_code": args["item_code"],
"warehouse": args["warehouse"]}):
bin_wrapper = webnotes.model_wrapper([{
bin_wrapper = webnotes.bean([{
"doctype": "Bin",
"item_code": args["item_code"],
"warehouse": args["warehouse"],

View File

@@ -18,6 +18,7 @@ import webnotes
from webnotes import msgprint, _
import json
from webnotes.utils import flt, cstr
from webnotes.defaults import get_global_default
def validate_end_of_life(item_code, end_of_life=None, verbose=1):
if not end_of_life:
@@ -99,8 +100,7 @@ def get_valuation_method(item_code):
"""get valuation method from item or default"""
val_method = webnotes.conn.get_value('Item', item_code, 'valuation_method')
if not val_method:
from webnotes.utils import get_defaults
val_method = get_defaults().get('valuation_method', 'FIFO')
val_method = get_global_default('valuation_method') or "FIFO"
return val_method
def get_fifo_rate(previous_stock_queue, qty):