deprecated sales and purchase return tool

This commit is contained in:
Anand Doshi 2013-03-18 17:57:59 +05:30
parent f11e2f8f6f
commit 080f9098c0
40 changed files with 7 additions and 1091 deletions

View File

@ -63,12 +63,6 @@ wn.module_page["Accounts"] = [
"doctype": "Period Closing Voucher",
description: "Close Balance Sheet and book Profit or Loss."
},
{
"route":"Form/Sales and Purchase Return Tool/Sales and Purchase Return Tool",
"label": wn._("Sales and Purchase Return Tool"),
description: wn._("Manage sales or purchase returns"),
"doctype": "Sales and Purchase Return Tool"
},
{
"page":"voucher-import-tool",
"label": wn._("Voucher Import Tool"),

View File

@ -80,12 +80,6 @@ wn.module_page["Buying"] = [
title: wn._("Tools"),
icon: "icon-wrench",
items: [
{
"route":"Form/Sales and Purchase Return Tool/Sales and Purchase Return Tool",
"label":wn._("Purchase Returns"),
"description":wn._("Helper for managing return of goods (sales or purchase)"),
doctype: "Sales and Purchase Return Tool"
},
]
},
{

View File

@ -1,4 +1,5 @@
erpnext.updates = [
["19th March", ["Sales and Purchase Return Tool deprecated. Use Stock Entry instead."]],
["12th March", ["Updates to website module. Added more options in Style Settings and Website Settings."]],
["5th March", ["Refactored Upload Attendance Tool"]],
["4th March", ["Lead organization added in Quotation classic/spartan/modern print format"]],

View File

@ -0,0 +1,5 @@
import webnotes
def execute():
webnotes.delete_doc("DocType", "Sales and Purchase Return Item")
webnotes.delete_doc("DocType", "Sales and Purchase Return Tool")

View File

@ -213,4 +213,5 @@ patch_list = [
"execute:webnotes.reload_doc('hr', 'search_criteria', 'monthly_attendance_details')",
"patches.march_2013.p04_pos_update_stock_check",
"patches.march_2013.p05_payment_reconciliation",
"patches.march_2013.p06_remove_sales_purchase_return_tool",
]

View File

@ -1 +0,0 @@
from __future__ import unicode_literals

View File

@ -1,13 +0,0 @@
[
"Selling",
"Description",
"Sales and Purchase Return Item",
"Qty",
"Serial No",
"Rate",
"Detail Name",
"Batch No",
"Returned Qty",
"Item Code",
"UOM"
]

View File

@ -1,13 +0,0 @@
{
"Batch No": "\u0644\u0627 \u062f\u0641\u0639\u0629",
"Description": "\u0648\u0635\u0641",
"Detail Name": "\u0627\u0644\u0627\u0633\u0645",
"Item Code": "\u0627\u0644\u0628\u0646\u062f \u0627\u0644\u0631\u0645\u0632",
"Qty": "\u0627\u0644\u0643\u0645\u064a\u0629",
"Rate": "\u0645\u0639\u062f\u0644",
"Returned Qty": "\u0639\u0627\u062f \u0627\u0644\u0643\u0645\u064a\u0629",
"Sales and Purchase Return Item": "\u0645\u0628\u064a\u0639\u0627\u062a \u0648\u0634\u0631\u0627\u0621 \u0627\u0644\u0633\u0644\u0639\u0629 \u0627\u0644\u0639\u0648\u062f\u0629",
"Selling": "\u0628\u064a\u0639",
"Serial No": "\u0627\u0644\u0645\u0633\u0644\u0633\u0644 \u0644\u0627",
"UOM": "UOM"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "Batch No",
"Description": "Beschreibung",
"Detail Name": "Detail Name",
"Item Code": "Item Code",
"Qty": "Menge",
"Rate": "Rate",
"Returned Qty": "Kehrte Menge",
"Sales and Purchase Return Item": "Sales and Purchase Zur\u00fcck Artikel",
"Selling": "Verkauf",
"Serial No": "Serial In",
"UOM": "UOM"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "Lote n \u00ba",
"Description": "Descripci\u00f3n",
"Detail Name": "Detalle Nombre",
"Item Code": "C\u00f3digo del art\u00edculo",
"Qty": "Cantidad",
"Rate": "Velocidad",
"Returned Qty": "Cantidad devuelta",
"Sales and Purchase Return Item": "Venta y Compra de art\u00edculo de vuelta",
"Selling": "De venta",
"Serial No": "N\u00famero de orden",
"UOM": "UOM"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "Aucun lot",
"Description": "Description",
"Detail Name": "Nom de d\u00e9tails",
"Item Code": "Code de l'article",
"Qty": "Qt\u00e9",
"Rate": "Taux",
"Returned Qty": "Quantit\u00e9 retourn\u00e9e",
"Sales and Purchase Return Item": "Vente et achat du lot Retour",
"Selling": "Vente",
"Serial No": "N \u00b0 de s\u00e9rie",
"UOM": "Emballage"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "\u0915\u094b\u0908 \u092c\u0948\u091a",
"Description": "\u0935\u093f\u0935\u0930\u0923",
"Detail Name": "\u0935\u093f\u0938\u094d\u0924\u093e\u0930 \u0938\u0947 \u0928\u093e\u092e",
"Item Code": "\u0906\u0907\u091f\u092e \u0915\u094b\u0921",
"Qty": "\u092e\u093e\u0924\u094d\u0930\u093e",
"Rate": "\u0926\u0930",
"Returned Qty": "\u0935\u093e\u092a\u0938 \u0906 \u0917\u090f \u092e\u093e\u0924\u094d\u0930\u093e",
"Sales and Purchase Return Item": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0914\u0930 \u0916\u0930\u0940\u0926 \u0915\u0947 \u092e\u0926 \u0935\u093e\u092a\u0938\u0940",
"Selling": "\u0935\u093f\u0915\u094d\u0930\u092f",
"Serial No": "\u0928\u0939\u0940\u0902 \u0938\u0940\u0930\u093f\u092f\u0932",
"UOM": "UOM"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "Hrpa Ne",
"Description": "Opis",
"Detail Name": "Detalj Ime",
"Item Code": "Stavka \u0160ifra",
"Qty": "Kol",
"Rate": "Stopa",
"Returned Qty": "Vra\u0107eno Kol",
"Sales and Purchase Return Item": "Prodaja i kupnja Povratak Stavka",
"Selling": "Prodaja",
"Serial No": "Serijski br",
"UOM": "UOM"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "Batch nr.",
"Description": "Beschrijving",
"Detail Name": "Detail Naam",
"Item Code": "Artikelcode",
"Qty": "Aantal",
"Rate": "Tarief",
"Returned Qty": "Geretourneerde Aantal",
"Sales and Purchase Return Item": "Verkoop en Inkoop Return Item",
"Selling": "Selling",
"Serial No": "Serienummer",
"UOM": "Verpakking"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "N\u00ba do Lote",
"Description": "Descri\u00e7\u00e3o",
"Detail Name": "Nome do Detalhe",
"Item Code": "C\u00f3digo do Item",
"Qty": "Qtde.",
"Rate": "Taxa",
"Returned Qty": "Qtde. retornada",
"Sales and Purchase Return Item": "Item de retorno de compra e venda",
"Selling": "Vendas",
"Serial No": "N\u00ba de S\u00e9rie",
"UOM": "UDM"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "No lote",
"Description": "Descri\u00e7\u00e3o",
"Detail Name": "Nome detalhes",
"Item Code": "C\u00f3digo do artigo",
"Qty": "Qty",
"Rate": "Taxa",
"Returned Qty": "Qtde voltou",
"Sales and Purchase Return Item": "Vendas e item retorno de compra",
"Selling": "Vendendo",
"Serial No": "N \u00ba de S\u00e9rie",
"UOM": "UOM"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "\u0413\u0440\u0443\u043f\u043d\u043e \u041d\u0435\u043c\u0430",
"Description": "\u041e\u043f\u0438\u0441",
"Detail Name": "\u0414\u0435\u0442\u0430\u0459 \u0418\u043c\u0435",
"Item Code": "\u0428\u0438\u0444\u0440\u0430",
"Qty": "\u041a\u043e\u043b",
"Rate": "\u0421\u0442\u043e\u043f\u0430",
"Returned Qty": "\u0412\u0440\u0430\u045b\u0435\u043d\u0438 \u041a\u043e\u043b",
"Sales and Purchase Return Item": "\u041f\u0440\u043e\u0434\u0430\u0458\u0430 \u0438 \u043a\u0443\u043f\u043e\u0432\u0438\u043d\u0430 \u041f\u043e\u0432\u0440\u0430\u0442\u0430\u043a \u0430\u0443\u043a\u0446\u0438\u0458\u0438",
"Selling": "\u041f\u0440\u043e\u0434\u0430\u0458\u0430",
"Serial No": "\u0421\u0435\u0440\u0438\u0458\u0441\u043a\u0438 \u0431\u0440\u043e\u0458",
"UOM": "\u0423\u041e\u041c"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "\u0ba4\u0bc6\u0bbe\u0b95\u0bc1\u0ba4\u0bbf \u0b87\u0bb2\u0bcd\u0bb2\u0bc8",
"Description": "\u0bb5\u0bbf\u0bb3\u0b95\u0bcd\u0b95\u0bae\u0bcd",
"Detail Name": "\u0bb5\u0bbf\u0bb0\u0bbf\u0bb5\u0bbe\u0b95 \u0baa\u0bc6\u0baf\u0bb0\u0bcd",
"Item Code": "\u0b89\u0bb0\u0bc1\u0baa\u0bcd\u0baa\u0b9f\u0bbf\u0baf\u0bc8 \u0b95\u0bc7\u0bbe\u0b9f\u0bcd",
"Qty": "\u0b85\u0bb3\u0bb5\u0bc1",
"Rate": "\u0bb5\u0bbf\u0bb2\u0bc8",
"Returned Qty": "\u0ba4\u0bbf\u0bb0\u0bc1\u0bae\u0bcd\u0baa\u0bbf \u0b85\u0bb3\u0bb5\u0bc1",
"Sales and Purchase Return Item": "\u0bb5\u0bbf\u0bb1\u0bcd\u0baa\u0ba9\u0bc8 \u0bae\u0bb1\u0bcd\u0bb1\u0bc1\u0bae\u0bcd \u0b95\u0bc6\u0bbe\u0bb3\u0bcd\u0bae\u0bc1\u0ba4\u0bb2\u0bcd \u0ba4\u0bbf\u0bb0\u0bc1\u0bae\u0bcd\u0baa \u0b89\u0bb0\u0bc1\u0baa\u0bcd\u0baa\u0b9f\u0bbf",
"Selling": "\u0bb5\u0bbf\u0bb1\u0bcd\u0baa\u0ba9\u0bc8",
"Serial No": "\u0b87\u0bb2\u0bcd\u0bb2\u0bc8 \u0ba4\u0bc6\u0bbe\u0b9f\u0bb0\u0bcd",
"UOM": "\u0bae\u0bc6\u0bbe\u0bb1\u0b9f\u0bcd\u0b9f\u0bc1\u0bb5 \u0baa\u0bb2\u0bcd\u0b95\u0bb2\u0bc8\u0b95\u0bb4\u0b95\u0bae\u0bcd"
}

View File

@ -1,13 +0,0 @@
{
"Batch No": "\u0e0a\u0e38\u0e14\u0e44\u0e21\u0e48\u0e21\u0e35",
"Description": "\u0e25\u0e31\u0e01\u0e29\u0e13\u0e30",
"Detail Name": "\u0e0a\u0e37\u0e48\u0e2d\u0e23\u0e32\u0e22\u0e25\u0e30\u0e40\u0e2d\u0e35\u0e22\u0e14",
"Item Code": "\u0e23\u0e2b\u0e31\u0e2a\u0e2a\u0e34\u0e19\u0e04\u0e49\u0e32",
"Qty": "\u0e08\u0e33\u0e19\u0e27\u0e19",
"Rate": "\u0e2d\u0e31\u0e15\u0e23\u0e32",
"Returned Qty": "\u0e08\u0e33\u0e19\u0e27\u0e19\u0e01\u0e25\u0e31\u0e1a",
"Sales and Purchase Return Item": "\u0e01\u0e32\u0e23\u0e02\u0e32\u0e22\u0e41\u0e25\u0e30\u0e01\u0e32\u0e23\u0e0b\u0e37\u0e49\u0e2d\u0e2a\u0e34\u0e19\u0e04\u0e49\u0e32\u0e01\u0e25\u0e31\u0e1a",
"Selling": "\u0e02\u0e32\u0e22",
"Serial No": "\u0e2d\u0e19\u0e38\u0e01\u0e23\u0e21\u0e44\u0e21\u0e48\u0e21\u0e35",
"UOM": "UOM"
}

View File

@ -1,22 +0,0 @@
# ERPNext - web based ERP (http://erpnext.com)
# Copyright (C) 2012 Web Notes Technologies Pvt Ltd
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from __future__ import unicode_literals
import webnotes
class DocType:
def __init__(self, d, dl):
self.doc, self.doclist = d, dl

View File

@ -1,110 +0,0 @@
[
{
"creation": "2013-02-22 01:27:52",
"docstatus": 0,
"modified": "2013-03-07 07:03:30",
"modified_by": "Administrator",
"owner": "wasim@webnotestech.com"
},
{
"doctype": "DocType",
"istable": 1,
"module": "Selling",
"name": "__common__"
},
{
"doctype": "DocField",
"name": "__common__",
"parent": "Sales and Purchase Return Item",
"parentfield": "fields",
"parenttype": "DocType",
"permlevel": 0
},
{
"doctype": "DocType",
"name": "Sales and Purchase Return Item"
},
{
"doctype": "DocField",
"fieldname": "item_code",
"fieldtype": "Link",
"label": "Item Code",
"oldfieldname": "item_code",
"oldfieldtype": "Link",
"options": "Item",
"read_only": 1,
"reqd": 1
},
{
"doctype": "DocField",
"fieldname": "description",
"fieldtype": "Data",
"label": "Description",
"oldfieldname": "description",
"oldfieldtype": "Data",
"print_width": "300px",
"read_only": 1,
"width": "300px"
},
{
"doctype": "DocField",
"fieldname": "uom",
"fieldtype": "Link",
"label": "UOM",
"oldfieldname": "uom",
"oldfieldtype": "Link",
"options": "UOM",
"read_only": 1,
"search_index": 0
},
{
"doctype": "DocField",
"fieldname": "rate",
"fieldtype": "Currency",
"label": "Rate",
"oldfieldname": "rate",
"oldfieldtype": "Currency",
"options": "Company:company:default_currency",
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "qty",
"fieldtype": "Data",
"label": "Qty",
"oldfieldname": "qty",
"oldfieldtype": "Data",
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "returned_qty",
"fieldtype": "Data",
"label": "Returned Qty",
"oldfieldname": "returned_qty",
"oldfieldtype": "Data",
"reqd": 1
},
{
"doctype": "DocField",
"fieldname": "serial_no",
"fieldtype": "Small Text",
"label": "Serial No"
},
{
"doctype": "DocField",
"fieldname": "batch_no",
"fieldtype": "Data",
"label": "Batch No"
},
{
"doctype": "DocField",
"fieldname": "detail_name",
"fieldtype": "Data",
"hidden": 1,
"label": "Detail Name",
"oldfieldname": "detail_name",
"oldfieldtype": "Data",
"read_only": 1
}
]

View File

@ -120,12 +120,6 @@ wn.module_page["Selling"] = [
title: wn._("Tools"),
icon: "icon-wrench",
items: [
{
"route":"Form/Sales and Purchase Return Tool/Sales and Purchase Return Tool",
"label":wn._("Sales Returns"),
"description":wn._("Helper for managing return of goods (sales or purchase)"),
doctype: "Sales and Purchase Return Tool"
},
{
"route":"Form/SMS Center/SMS Center",
"label":wn._("SMS Center"),

View File

@ -1 +0,0 @@
from __future__ import unicode_literals

View File

@ -1,21 +0,0 @@
[
"Make Credit Note",
"Make Excise Invoice",
"Sales Return",
"Get Items",
"Delivery Note No",
"Company",
"Customer/Supplier",
"Sales and Purchase Return Tool",
"Make Debit Note",
"Cust/Supp Address",
"Sales Invoice No",
"Make Stock Entry",
"Purchase Receipt No",
"Purchase Return",
"Sales and Purchase Return Items",
"Return Date",
"Cust/Supp Name",
"Return Type",
"Stock"
]

View File

@ -1,21 +0,0 @@
{
"Company": "\u0634\u0631\u0643\u0629",
"Cust/Supp Address": "\u0627\u0644\u0632\u0628\u0648\u0646 / \u0627\u0644\u0645\u0644\u062d\u0642 \u0627\u0644\u0639\u0646\u0648\u0627\u0646",
"Cust/Supp Name": "\u0627\u0644\u0632\u0628\u0648\u0646 / \u0627\u0644\u0645\u0644\u062d\u0642 \u0627\u0633\u0645",
"Customer/Supplier": "\u0627\u0644\u0639\u0645\u064a\u0644 / \u0645\u0632\u0648\u062f",
"Delivery Note No": "\u0645\u0644\u0627\u062d\u0638\u0629 \u0644\u0627 \u062a\u0633\u0644\u064a\u0645",
"Get Items": "\u0627\u0644\u062d\u0635\u0648\u0644 \u0639\u0644\u0649 \u0627\u0644\u0639\u0646\u0627\u0635\u0631",
"Make Credit Note": "\u062c\u0639\u0644 \u0627\u0644\u0627\u0626\u062a\u0645\u0627\u0646\u064a",
"Make Debit Note": "\u0645\u0644\u0627\u062d\u0638\u0629 \u062c\u0639\u0644 \u0627\u0644\u062e\u0635\u0645",
"Make Excise Invoice": "\u062c\u0639\u0644 \u0627\u0644\u0641\u0627\u062a\u0648\u0631\u0629 \u0627\u0644\u0645\u0643\u0648\u0633",
"Make Stock Entry": "\u062c\u0639\u0644 \u0627\u0644\u062f\u062e\u0648\u0644 \u0644\u0644\u0633\u0647\u0645",
"Purchase Receipt No": "\u0644\u0627 \u0634\u0631\u0627\u0621 \u0627\u0633\u062a\u0644\u0627\u0645",
"Purchase Return": "\u0634\u0631\u0627\u0621 \u0627\u0644\u0639\u0648\u062f\u0629",
"Return Date": "\u0627\u0644\u0639\u0648\u062f\u0629 \u062a\u0627\u0631\u064a\u062e",
"Return Type": "\u0627\u0644\u0639\u0648\u062f\u0629 \u0646\u0648\u0639",
"Sales Invoice No": "\u0641\u0627\u062a\u0648\u0631\u0629 \u0645\u0628\u064a\u0639\u0627\u062a \u0644\u0627",
"Sales Return": "\u0645\u0628\u064a\u0639\u0627\u062a \u0627\u0644\u0639\u0648\u062f\u0629",
"Sales and Purchase Return Items": "\u0645\u0627\u062f\u0629 \u0639\u0627\u0626\u062f \u0627\u0644\u0645\u0628\u064a\u0639\u0627\u062a \u0648\u0627\u0644\u0645\u0634\u062a\u0631\u064a\u0627\u062a",
"Sales and Purchase Return Tool": "\u0645\u0628\u064a\u0639\u0627\u062a \u0648\u0634\u0631\u0627\u0621 \u0623\u062f\u0627\u0629 \u0627\u0644\u0639\u0648\u062f\u0629",
"Stock": "\u0627\u0644\u0623\u0648\u0631\u0627\u0642 \u0627\u0644\u0645\u0627\u0644\u064a\u0629"
}

View File

@ -1,21 +0,0 @@
{
"Company": "Firma",
"Cust/Supp Address": "Cust / Supp Adresse",
"Cust/Supp Name": "Cust / Supp Namen",
"Customer/Supplier": "Kunde / Lieferant",
"Delivery Note No": "Lieferschein Nein",
"Get Items": "Holen Artikel",
"Make Credit Note": "Machen Gutschrift",
"Make Debit Note": "Machen Lastschrift",
"Make Excise Invoice": "Machen Excise Rechnung",
"Make Stock Entry": "Machen Eintrag Stock",
"Purchase Receipt No": "Kaufbeleg",
"Purchase Return": "Kauf zur\u00fcckgeben",
"Return Date": "Zur\u00fcck Datum",
"Return Type": "R\u00fcckgabetyp",
"Sales Invoice No": "Sales Invoice In",
"Sales Return": "Umsatzrendite",
"Sales and Purchase Return Items": "Verkauf und Kauf zur\u00fccksenden Artikel",
"Sales and Purchase Return Tool": "Sales and Purchase Return-Tool",
"Stock": "Lager"
}

View File

@ -1,21 +0,0 @@
{
"Company": "Empresa",
"Cust/Supp Address": "Cust / Supp Direcci\u00f3n",
"Cust/Supp Name": "Cust / Supp Nombre",
"Customer/Supplier": "Cliente / Proveedor",
"Delivery Note No": "Entrega Nota No",
"Get Items": "Obtener elementos",
"Make Credit Note": "Hacer Nota de Cr\u00e9dito",
"Make Debit Note": "Hacer Nota de D\u00e9bito",
"Make Excise Invoice": "Hacer Factura Impuestos Especiales",
"Make Stock Entry": "Hacer de la entrada",
"Purchase Receipt No": "No recibo de compra",
"Purchase Return": "Comprar Volver",
"Return Date": "Fecha de regreso",
"Return Type": "Devuelto",
"Sales Invoice No": "Ventas factura n \u00ba",
"Sales Return": "Ventas Retorno",
"Sales and Purchase Return Items": "Ventas y comprar art\u00edculos de Retorno",
"Sales and Purchase Return Tool": "Herramienta de ventas y devoluci\u00f3n de compra",
"Stock": "Valores"
}

View File

@ -1,21 +0,0 @@
{
"Company": "Entreprise",
"Cust/Supp Address": "Cust / Supp Adresse",
"Cust/Supp Name": "Cust / Supp Nom",
"Customer/Supplier": "Client / Fournisseur",
"Delivery Note No": "Remarque Aucune livraison",
"Get Items": "Obtenir les \u00e9l\u00e9ments",
"Make Credit Note": "Assurez note de cr\u00e9dit",
"Make Debit Note": "Assurez note de d\u00e9bit",
"Make Excise Invoice": "Assurez facture d&#39;accise",
"Make Stock Entry": "Assurez Entr\u00e9e Stock",
"Purchase Receipt No": "Achetez un accus\u00e9 de r\u00e9ception",
"Purchase Return": "Achat de retour",
"Return Date": "Date de retour",
"Return Type": "Retour Type",
"Sales Invoice No": "Aucune facture de vente",
"Sales Return": "Ventes de retour",
"Sales and Purchase Return Items": "Ventes et articles de retour d&#39;achat",
"Sales and Purchase Return Tool": "Outil de vente et de retour d&#39;achat",
"Stock": "Stock"
}

View File

@ -1,21 +0,0 @@
{
"Company": "\u0915\u0902\u092a\u0928\u0940",
"Cust/Supp Address": "Cust / Supp \u092a\u0924\u093e",
"Cust/Supp Name": "Cust / Supp \u0928\u093e\u092e",
"Customer/Supplier": "\u0917\u094d\u0930\u093e\u0939\u0915 / \u0906\u092a\u0942\u0930\u094d\u0924\u093f\u0915\u0930\u094d\u0924\u093e",
"Delivery Note No": "\u0921\u093f\u0932\u093f\u0935\u0930\u0940 \u0928\u094b\u091f",
"Get Items": "\u0906\u0907\u091f\u092e \u092a\u093e\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f",
"Make Credit Note": "\u0915\u094d\u0930\u0947\u0921\u093f\u091f \u0928\u094b\u091f",
"Make Debit Note": "\u0921\u0947\u092c\u093f\u091f \u0928\u094b\u091f",
"Make Excise Invoice": "\u0909\u0924\u094d\u092a\u093e\u0926 \u0936\u0941\u0932\u094d\u0915 \u091a\u093e\u0932\u093e\u0928",
"Make Stock Entry": "\u0938\u094d\u091f\u0949\u0915 \u090f\u0902\u091f\u094d\u0930\u0940",
"Purchase Receipt No": "\u0930\u0938\u0940\u0926 \u0916\u0930\u0940\u0926 \u0928\u0939\u0940\u0902",
"Purchase Return": "\u0915\u094d\u0930\u092f \u0935\u093e\u092a\u0938\u0940",
"Return Date": "\u0924\u093f\u0925\u093f \u0932\u094c\u091f\u0947\u0902",
"Return Type": "\u092a\u094d\u0930\u0915\u093e\u0930 \u0932\u094c\u091f\u0947\u0902",
"Sales Invoice No": "\u092c\u093f\u0915\u094d\u0930\u0940 \u091a\u093e\u0932\u093e\u0928 \u0928\u0939\u0940\u0902",
"Sales Return": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0932\u094c\u091f\u0947\u0902",
"Sales and Purchase Return Items": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0914\u0930 \u0916\u0930\u0940\u0926 \u0915\u0947 \u0930\u093f\u091f\u0930\u094d\u0928 \u0906\u0907\u091f\u092e",
"Sales and Purchase Return Tool": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0914\u0930 \u0916\u0930\u0940\u0926 \u0915\u0947 \u0930\u093f\u091f\u0930\u094d\u0928 \u091f\u0942\u0932",
"Stock": "\u0938\u094d\u091f\u0949\u0915"
}

View File

@ -1,21 +0,0 @@
{
"Company": "Dru\u0161tvo",
"Cust/Supp Address": "Cust / Supp Adresa",
"Cust/Supp Name": "Cust / Supp Ime",
"Customer/Supplier": "Kupac / Dobavlja\u010d",
"Delivery Note No": "Dostava Napomena Ne",
"Get Items": "Nabavite artikle",
"Make Credit Note": "Napravite Credit Note",
"Make Debit Note": "Napravite tere\u0107enju",
"Make Excise Invoice": "Napravite tro\u0161arinama fakture",
"Make Stock Entry": "Napravite Stock Entry",
"Purchase Receipt No": "Ra\u010dun kupnje Ne",
"Purchase Return": "Kupnja Povratak",
"Return Date": "Povratak Datum",
"Return Type": "Povratak Vid",
"Sales Invoice No": "Prodaja Ra\u010dun br",
"Sales Return": "Prodaje Povratak",
"Sales and Purchase Return Items": "Prodaja i kupnja Povratak Stavke",
"Sales and Purchase Return Tool": "Prodaja i kupnja Povratak Tool",
"Stock": "Zaliha"
}

View File

@ -1,21 +0,0 @@
{
"Company": "Vennootschap",
"Cust/Supp Address": "Cust / Supp Adres",
"Cust/Supp Name": "Cust / Supp Naam",
"Customer/Supplier": "Klant / leverancier",
"Delivery Note No": "Levering aantekening",
"Get Items": "Get Items",
"Make Credit Note": "Maak Creditnota",
"Make Debit Note": "Maak debetnota",
"Make Excise Invoice": "Maak Accijnzen Factuur",
"Make Stock Entry": "Maak Stock Entry",
"Purchase Receipt No": "Aankoopbewijs Geen",
"Purchase Return": "Aankoop Return",
"Return Date": "Keer terug Datum",
"Return Type": "Terug Type",
"Sales Invoice No": "Verkoop Factuur nr.",
"Sales Return": "Verkoop Terug",
"Sales and Purchase Return Items": "Verkoop en Inkoop Return Items",
"Sales and Purchase Return Tool": "Verkoop en Inkoop Return Tool",
"Stock": "Voorraad"
}

View File

@ -1,21 +0,0 @@
{
"Company": "Empresa",
"Cust/Supp Address": "Endere\u00e7o do Cliente/Fornecedor",
"Cust/Supp Name": "Nome do Cliente/Fornecedor",
"Customer/Supplier": "Cliente / Fornecedor",
"Delivery Note No": "N\u00ba da Guia de Remessa",
"Get Items": "Obter itens",
"Make Credit Note": "Fazer Nota de Cr\u00e9dito",
"Make Debit Note": "Fazer Nota de D\u00e9bito",
"Make Excise Invoice": "Fazer fatura de imposto",
"Make Stock Entry": "Fazer lan\u00e7amento de estoque",
"Purchase Receipt No": "N\u00ba do Recibo de Compra",
"Purchase Return": "Devolu\u00e7\u00e3o de Compra",
"Return Date": "Data de retorno",
"Return Type": "Tipo de retorno",
"Sales Invoice No": "N\u00ba da Nota Fiscal de Venda",
"Sales Return": "Retorno de Vendas",
"Sales and Purchase Return Items": "Itens de retorno de compra e venda",
"Sales and Purchase Return Tool": "Ferramenta de retorno de compra e venda",
"Stock": "Estoque"
}

View File

@ -1,21 +0,0 @@
{
"Company": "Companhia",
"Cust/Supp Address": "Cust / Supp Endere\u00e7o",
"Cust/Supp Name": "Cust / Supp Nome",
"Customer/Supplier": "Cliente / Fornecedor",
"Delivery Note No": "Nota de Entrega N\u00e3o",
"Get Items": "Obter itens",
"Make Credit Note": "Fa\u00e7a Nota de Cr\u00e9dito",
"Make Debit Note": "Fa\u00e7a Nota de D\u00e9bito",
"Make Excise Invoice": "Fa\u00e7a fatura Excise",
"Make Stock Entry": "Fa\u00e7a entrada de material",
"Purchase Receipt No": "Compra recibo N\u00e3o",
"Purchase Return": "Voltar comprar",
"Return Date": "Data de regresso",
"Return Type": "Tipo de retorno",
"Sales Invoice No": "Vendas factura n",
"Sales Return": "Vendas Retorno",
"Sales and Purchase Return Items": "Vendas e itens de retorno de Compra",
"Sales and Purchase Return Tool": "Ferramenta de vendas e retorno de compra",
"Stock": "Estoque"
}

View File

@ -1,21 +0,0 @@
{
"Company": "\u041a\u043e\u043c\u043f\u0430\u043d\u0438\u0458\u0430",
"Cust/Supp Address": "\u041a\u043e\u0440\u0438\u0441\u043d\u0438\u0447\u043a\u0430 / \u0421\u0443\u043f\u043f \u0410\u0434\u0440\u0435\u0441\u0430",
"Cust/Supp Name": "\u041a\u043e\u0440\u0438\u0441\u043d\u0438\u0447\u043a\u0430 / \u0421\u0443\u043f\u043f \u0418\u043c\u0435",
"Customer/Supplier": "\u041a\u043e\u0440\u0438\u0441\u043d\u0438\u0447\u043a\u0438 / \u0414\u043e\u0431\u0430\u0432\u0459\u0430\u0447",
"Delivery Note No": "\u0418\u0441\u043f\u043e\u0440\u0443\u043a\u0430 \u041d\u0430\u043f\u043e\u043c\u0435\u043d\u0430 \u041d\u0435",
"Get Items": "\u0413\u0435\u0442 \u0441\u0442\u0430\u0432\u043a\u0435",
"Make Credit Note": "\u041d\u0430\u043f\u0440\u0430\u0432\u0438\u0442\u0435 \u041d\u043e\u0442\u0435 \u0426\u0440\u0435\u0434\u0438\u0442",
"Make Debit Note": "\u041d\u0430\u043f\u0440\u0430\u0432\u0438\u0442\u0435 \u0437\u0430\u0434\u0443\u0436\u0435\u045a\u0443",
"Make Excise Invoice": "\u041d\u0430\u043f\u0440\u0430\u0432\u0438\u0442\u0435 \u0430\u043a\u0446\u0438\u0437\u0430\u043c\u0430 \u0444\u0430\u043a\u0442\u0443\u0440\u0443",
"Make Stock Entry": "\u041d\u0430\u043f\u0440\u0430\u0432\u0438\u0442\u0435 \u0443\u043d\u043e\u0441 \u0421\u0442\u043e\u0446\u043a",
"Purchase Receipt No": "\u041a\u0443\u043f\u043e\u0432\u0438\u043d\u0430 \u041f\u0440\u0438\u0458\u0435\u043c \u041d\u0435\u043c\u0430",
"Purchase Return": "\u041a\u0443\u043f\u043e\u0432\u0438\u043d\u0430 \u0420\u0435\u0442\u0443\u0440\u043d",
"Return Date": "\u0420\u0435\u0442\u0443\u0440\u043d \u0414\u0430\u0442\u0435",
"Return Type": "\u041f\u043e\u0432\u0440\u0430\u0442\u0430\u043a \u0412\u0438\u0434",
"Sales Invoice No": "\u041f\u0440\u043e\u0434\u0430\u0458\u0430 \u0420\u0430\u0447\u0443\u043d \u041d\u0435\u043c\u0430",
"Sales Return": "\u041f\u0440\u043e\u0434\u0430\u0458\u0430 \u0420\u0435\u0442\u0443\u0440\u043d",
"Sales and Purchase Return Items": "\u041f\u0440\u043e\u0434\u0430\u0458\u0430 \u0438 \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0438 \u041f\u043e\u0432\u0440\u0430\u0442\u0430\u043a \u041a\u0443\u043f\u043e\u0432\u0438\u043d\u0430",
"Sales and Purchase Return Tool": "\u041f\u0440\u043e\u0434\u0430\u0458\u0430 \u0438 \u043a\u0443\u043f\u043e\u0432\u0438\u043d\u0430 \u0430\u043b\u0430\u0442\u0430 \u041f\u043e\u0432\u0440\u0430\u0442\u0430\u043a",
"Stock": "\u0417\u0430\u043b\u0438\u0445\u0430"
}

View File

@ -1,21 +0,0 @@
{
"Company": "\u0ba8\u0bbf\u0bb1\u0bc1\u0bb5\u0ba9\u0bae\u0bcd",
"Cust/Supp Address": "Cust / \u0b9a\u0baa\u0bcd \u0bae\u0bc1\u0b95\u0bb5\u0bb0\u0bbf",
"Cust/Supp Name": "Cust / \u0b9a\u0baa\u0bcd \u0baa\u0bc6\u0baf\u0bb0\u0bcd",
"Customer/Supplier": "\u0bb5\u0bbe\u0b9f\u0bbf\u0b95\u0bcd\u0b95\u0bc8\u0baf\u0bbe\u0bb3\u0bb0\u0bcd / \u0b9a\u0baa\u0bcd\u0bb3\u0bc8\u0baf\u0bb0\u0bcd",
"Delivery Note No": "\u0b9f\u0bc6\u0bb2\u0bbf\u0bb5\u0bb0\u0bbf \u0b95\u0bc1\u0bb1\u0bbf\u0baa\u0bcd\u0baa\u0bc1 \u0b87\u0bb2\u0bcd\u0bb2\u0bc8",
"Get Items": "\u0baa\u0bc6\u0bbe\u0bb0\u0bc1\u0b9f\u0bcd\u0b95\u0bb3\u0bcd \u0b95\u0bbf\u0b9f\u0bc8\u0b95\u0bcd\u0b95\u0bc1\u0bae\u0bcd",
"Make Credit Note": "\u0b95\u0b9f\u0ba9\u0bcd \u0b95\u0bc1\u0bb1\u0bbf\u0baa\u0bcd\u0baa\u0bc1 \u0b9a\u0bc6\u0baf\u0bcd\u0baf",
"Make Debit Note": "\u0baa\u0bb1\u0bcd\u0bb1\u0bc1 \u0b95\u0bc1\u0bb1\u0bbf\u0baa\u0bcd\u0baa\u0bc1 \u0b9a\u0bc6\u0baf\u0bcd\u0baf",
"Make Excise Invoice": "\u0bae\u0ba4\u0bc1\u0bb5\u0bb0\u0bbf \u0bb5\u0bbf\u0bb2\u0bc8\u0baa\u0bcd\u0baa\u0b9f\u0bcd\u0b9f\u0bbf\u0baf\u0bb2\u0bcd \u0bb5\u0bc8\u0b95\u0bcd\u0b95",
"Make Stock Entry": "\u0baa\u0b99\u0bcd\u0b95\u0bc1 \u0ba8\u0bc1\u0bb4\u0bc8\u0bb5\u0bc1 \u0b9a\u0bc6\u0baf\u0bcd\u0baf",
"Purchase Receipt No": "\u0b87\u0bb2\u0bcd\u0bb2\u0bc8 \u0b9a\u0bc0\u0b9f\u0bcd\u0b9f\u0bc1 \u0bb5\u0bbe\u0b99\u0bcd\u0b95",
"Purchase Return": "\u0ba4\u0bbf\u0bb0\u0bc1\u0bae\u0bcd\u0baa \u0bb5\u0bbe\u0b99\u0bcd\u0b95",
"Return Date": "\u0ba4\u0bc7\u0ba4\u0bbf \u0ba4\u0bbf\u0bb0\u0bc1\u0bae\u0bcd\u0baa\u0bbf",
"Return Type": "\u0bb5\u0b95\u0bc8 \u0ba4\u0bbf\u0bb0\u0bc1\u0bae\u0bcd\u0baa",
"Sales Invoice No": "\u0bb5\u0bbf\u0bb1\u0bcd\u0baa\u0ba9\u0bc8 \u0bb5\u0bbf\u0bb2\u0bc8\u0baa\u0bcd\u0baa\u0b9f\u0bcd\u0b9f\u0bbf\u0baf\u0bb2\u0bcd \u0b87\u0bb2\u0bcd\u0bb2\u0bc8",
"Sales Return": "\u0bb5\u0bbf\u0bb1\u0bcd\u0baa\u0ba9\u0bc8 Return",
"Sales and Purchase Return Items": "\u0bb5\u0bbf\u0bb1\u0bcd\u0baa\u0ba9\u0bc8 \u0bae\u0bb1\u0bcd\u0bb1\u0bc1\u0bae\u0bcd \u0b95\u0bc6\u0bbe\u0bb3\u0bcd\u0bae\u0bc1\u0ba4\u0bb2\u0bcd \u0ba4\u0bbf\u0bb0\u0bc1\u0bae\u0bcd\u0baa \u0b89\u0bb0\u0bc1\u0baa\u0bcd\u0baa\u0b9f\u0bbf\u0b95\u0bb3\u0bcd",
"Sales and Purchase Return Tool": "\u0bb5\u0bbf\u0bb1\u0bcd\u0baa\u0ba9\u0bc8 \u0bae\u0bb1\u0bcd\u0bb1\u0bc1\u0bae\u0bcd \u0b95\u0bc6\u0bbe\u0bb3\u0bcd\u0bae\u0bc1\u0ba4\u0bb2\u0bcd \u0ba4\u0bbf\u0bb0\u0bc1\u0bae\u0bcd\u0baa \u0b95\u0bb0\u0bc1\u0bb5\u0bbf",
"Stock": "\u0baa\u0b99\u0bcd\u0b95\u0bc1"
}

View File

@ -1,21 +0,0 @@
{
"Company": "\u0e1a\u0e23\u0e34\u0e29\u0e31\u0e17",
"Cust/Supp Address": "\u0e17\u0e35\u0e48\u0e2d\u0e22\u0e39\u0e48 cust / Supp",
"Cust/Supp Name": "\u0e0a\u0e37\u0e48\u0e2d cust / Supp",
"Customer/Supplier": "\u0e25\u0e39\u0e01\u0e04\u0e49\u0e32 / \u0e1c\u0e39\u0e49\u0e1c\u0e25\u0e34\u0e15",
"Delivery Note No": "\u0e2b\u0e21\u0e32\u0e22\u0e40\u0e2b\u0e15\u0e38\u0e08\u0e31\u0e14\u0e2a\u0e48\u0e07\u0e2a\u0e34\u0e19\u0e04\u0e49\u0e32\u0e44\u0e21\u0e48\u0e21\u0e35",
"Get Items": "\u0e23\u0e31\u0e1a\u0e2a\u0e34\u0e19\u0e04\u0e49\u0e32",
"Make Credit Note": "\u0e43\u0e2b\u0e49\u0e08\u0e14\u0e1a\u0e31\u0e19\u0e17\u0e36\u0e01\u0e40\u0e04\u0e23\u0e14\u0e34\u0e15",
"Make Debit Note": "\u0e43\u0e2b\u0e49\u0e08\u0e14\u0e1a\u0e31\u0e19\u0e17\u0e36\u0e01\u0e40\u0e14\u0e1a\u0e34\u0e15",
"Make Excise Invoice": "\u0e17\u0e33\u0e43\u0e2b\u0e49\u0e43\u0e1a\u0e41\u0e08\u0e49\u0e07\u0e2b\u0e19\u0e35\u0e49\u0e2a\u0e23\u0e23\u0e1e\u0e2a\u0e32\u0e21\u0e34\u0e15",
"Make Stock Entry": "\u0e17\u0e33\u0e23\u0e32\u0e22\u0e01\u0e32\u0e23\u0e2a\u0e34\u0e19\u0e04\u0e49\u0e32",
"Purchase Receipt No": "\u0e43\u0e1a\u0e40\u0e2a\u0e23\u0e47\u0e08\u0e23\u0e31\u0e1a\u0e40\u0e07\u0e34\u0e19\u0e0b\u0e37\u0e49\u0e2d\u0e44\u0e21\u0e48\u0e21\u0e35",
"Purchase Return": "\u0e0b\u0e37\u0e49\u0e2d\u0e01\u0e25\u0e31\u0e1a",
"Return Date": "\u0e01\u0e25\u0e31\u0e1a\u0e27\u0e31\u0e19\u0e17\u0e35\u0e48",
"Return Type": "\u0e01\u0e25\u0e31\u0e1a\u0e0a\u0e19\u0e34\u0e14",
"Sales Invoice No": "\u0e02\u0e32\u0e22\u0e43\u0e1a\u0e41\u0e08\u0e49\u0e07\u0e2b\u0e19\u0e35\u0e49\u0e44\u0e21\u0e48\u0e21\u0e35",
"Sales Return": "\u0e02\u0e32\u0e22\u0e01\u0e25\u0e31\u0e1a",
"Sales and Purchase Return Items": "\u0e01\u0e32\u0e23\u0e02\u0e32\u0e22\u0e41\u0e25\u0e30\u0e01\u0e32\u0e23\u0e0b\u0e37\u0e49\u0e2d\u0e23\u0e32\u0e22\u0e01\u0e32\u0e23\u0e22\u0e49\u0e2d\u0e19\u0e01\u0e25\u0e31\u0e1a",
"Sales and Purchase Return Tool": "\u0e01\u0e32\u0e23\u0e02\u0e32\u0e22\u0e41\u0e25\u0e30\u0e01\u0e32\u0e23\u0e0b\u0e37\u0e49\u0e2d\u0e40\u0e04\u0e23\u0e37\u0e48\u0e2d\u0e07\u0e21\u0e37\u0e2d\u0e22\u0e49\u0e2d\u0e19\u0e01\u0e25\u0e31\u0e1a",
"Stock": "\u0e04\u0e25\u0e31\u0e07\u0e2a\u0e34\u0e19\u0e04\u0e49\u0e32"
}

View File

@ -1,229 +0,0 @@
// ERPNext - web based ERP (http://erpnext.com)
// Copyright (C) 2012 Web Notes Technologies Pvt Ltd
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
cur_frm.add_fetch("delivery_note_no", "company", "company");
cur_frm.add_fetch("sales_invoice_no", "company", "company");
cur_frm.add_fetch("purchase_receipt_no", "company", "company");
// Onload
//-------------------------------
cur_frm.cscript.onload = function(doc,dt,dn){
if(!doc.return_date) set_multiple(dt,dn,{return_date:get_today()});
doc.delivery_note_no = '';
doc.purchase_receipt_no = '';
doc.sales_invoice_no = '';
doc.return_type ='';
refresh_many(['delivery_note_no', 'sales_invoice_no', 'purchase_receipt_no', 'return_type']);
}
// Link field query
//--------------------------------
cur_frm.fields_dict.delivery_note_no.get_query = function(doc) {
return 'SELECT DISTINCT `tabDelivery Note`.name FROM `tabDelivery Note` WHERE `tabDelivery Note`.docstatus = 1 AND `tabDelivery Note`.%(key)s LIKE "%s" ORDER BY `tabDelivery Note`.name desc LIMIT 50';
}
cur_frm.fields_dict.sales_invoice_no.get_query = function(doc) {
return 'SELECT DISTINCT `tabSales Invoice`.name FROM `tabSales Invoice` WHERE `tabSales Invoice`.docstatus = 1 AND `tabSales Invoice`.%(key)s LIKE "%s" ORDER BY `tabSales Invoice`.name desc LIMIT 50';
}
cur_frm.fields_dict.purchase_receipt_no.get_query = function(doc) {
return 'SELECT DISTINCT `tabPurchase Receipt`.name FROM `tabPurchase Receipt` WHERE `tabPurchase Receipt`.docstatus = 1 AND `tabPurchase Receipt`.%(key)s LIKE "%s" ORDER BY `tabPurchase Receipt`.name desc LIMIT 50';
}
// Hide/unhide based on return type
//----------------------------------
cur_frm.cscript.return_type = function(doc, cdt, cdn) {
var cp = wn.control_panel;
hide_field(['purchase_receipt_no', 'delivery_note_no', 'sales_invoice_no', 'return_details', 'get_items', 'make_excise_invoice', 'make_stock_entry', 'make_debit_note', 'make_credit_note']);
if(doc.return_type == 'Sales Return') {
unhide_field(['delivery_note_no', 'sales_invoice_no', 'get_items', 'return_details', 'make_credit_note', 'make_stock_entry']);
if(cp.country == 'India') { unhide_field(['make_excise_invoice']); }
} else if(doc.return_type == 'Purchase Return') {
unhide_field(['purchase_receipt_no', 'get_items', 'return_details', 'make_debit_note', 'make_stock_entry']);
if(cp.country == 'India') { unhide_field(['make_excise_invoice']);}
}
cur_frm.cscript.clear_fields(doc);
}
// Create item table
//-------------------------------
cur_frm.cscript.get_items = function(doc, cdt, cdn) {
flag = 0
if(doc.return_type == 'Sales Return') {
if (doc.delivery_note_no && doc.sales_invoice_no) {
msgprint("You can not enter both Delivery Note No and Sales Invoice No. Please enter any one.");
flag = 1;
} else if (!doc.delivery_note_no && !doc.sales_invoice_no) {
msgprint("Please enter Delivery Note No or Sales Invoice No to proceed");
flag = 1;
}
} else if (doc.return_type == 'Purchase Return' && !doc.purchase_receipt_no) {
msgprint("Please enter Purchase Receipt No to proceed");
flag = 1;
}
if (!flag)
$c_obj(make_doclist(doc.doctype, doc.name),'pull_item_details','', function(r, rt) {
refresh_many(['return_details', 'cust_supp', 'cust_supp_name', 'cust_supp_address']);
});
}
// Clear fields
//-------------------------------
cur_frm.cscript.clear_fields = function(doc) {
doc.purchase_receipt_no, doc.delivery_note_no, doc.sales_invoice_no = '', '', '';
var cl = getchildren('Sales and Purchase Return Item', doc.name, 'return_details')
if(cl.length) $c_obj(make_doclist(doc.doctype, doc.name),'clear_return_table','', function(r, rt) {refresh_field('return_details')});
refresh_many(['delivery_note_no', 'sales_invoice_no', 'purchase_receipt_no', 'return_details']);
}
// Make Stock Entry
//-------------------------------
cur_frm.cscript.make_stock_entry = function(doc, cdt, cdn) {
var cl = getchildren('Sales and Purchase Return Item', doc.name, 'return_details');
if (!cl.length)
msgprint("Item table can not be blank. Please click on 'Get Items'.");
else if (!cur_frm.cscript.validate_returned_qty(cl)) {
se = cur_frm.cscript.map_parent_fields(doc,cdt,cdn);
cur_frm.cscript.map_child_fields(cl, se);
loaddoc('Stock Entry', se.name);
}
}
// Validate returned qty
//---------------------------
cur_frm.cscript.validate_returned_qty = function(cl) {
flag = 0
for(var i = 0; i<cl.length; i++){
if(cl[i].returned_qty > cl[i].qty) {
msgprint("Returned Qty can not be greater than qty. Please check for item: " + cl[i].item_code);
flag = 1
}
}
return flag
}
// map parent fields of stock entry
//----------------------------------
cur_frm.cscript.map_parent_fields = function(doc, cdt, cdn) {
var se = wn.model.make_new_doc_and_get_name('Stock Entry');
se = locals['Stock Entry'][se];
se.posting_date = dateutil.obj_to_str(new Date());
se.transfer_date = dateutil.obj_to_str(new Date());
se.fiscal_year = sys_defaults.fiscal_year;
se.purpose = doc.return_type;
se.remarks = doc.return_type + ' of ' + (doc.delivery_note_no || doc.sales_invoice_no || doc.purchase_receipt_no);
if(doc.return_type == 'Sales Return'){
se.delivery_note_no = doc.delivery_note_no;
se.sales_invoice_no = doc.sales_invoice_no;
se.customer = doc.cust_supp_name;
se.customer_name = doc.cust_supp_name;
se.customer_address = doc.cust_supp_address;
}
else if(doc.return_type == 'Purchase Return'){
se.purchase_receipt_no = doc.purchase_receipt_no;
se.supplier = doc.cust_supp_name;
se.supplier_name = doc.cust_supp_name;
se.supplier_address = doc.cust_supp_address;
}
return se
}
// map child fields of stock entry
//---------------------------------
cur_frm.cscript.map_child_fields = function(cl, se) {
for(var i = 0; i<cl.length; i++){
if (cl[i].returned_qty) {
var d1 = wn.model.add_child(se, 'Stock Entry Detail', 'mtn_details');
d1.detail_name = cl[i].detail_name;
d1.item_code = cl[i].item_code;
d1.description = cl[i].description;
d1.transfer_qty = cl[i].returned_qty;
d1.qty = cl[i].returned_qty;
d1.stock_uom = cl[i].uom;
d1.uom = cl[i].uom;
d1.conversion_factor = 1;
d1.incoming_rate = cl[i].rate;
d1.serial_no = cl[i].serial_no;
d1.batch_no = cl[i].batch_no;
}
}
}
// Make excise voucher
//-------------------------------
cur_frm.cscript.make_excise_invoice = function(doc) {
var excise = wn.model.make_new_doc_and_get_name('Journal Voucher');
excise = locals['Journal Voucher'][excise];
excise.voucher_type = 'Excise Voucher';
loaddoc('Journal Voucher',excise.name);
}
// Make debit note
//------------------------------
cur_frm.cscript.make_debit_note = function(doc) {
var doclist = make_doclist(doc.doctype, doc.name);
$c('accounts.get_new_jv_details', {
doclist: JSON.stringify(doclist),
fiscal_year: sys_defaults.fiscal_year
}, function(r, rt) {
if(!r.exc) {
cur_frm.cscript.make_jv(doc, 'Debit Note', r.message);
}
});
}
// Make credit note
//------------------------------
cur_frm.cscript.make_credit_note = function(doc) {
var doclist = make_doclist(doc.doctype, doc.name);
$c('accounts.get_new_jv_details', {
doclist: JSON.stringify(doclist),
fiscal_year: sys_defaults.fiscal_year,
}, function(r, rt) {
if(!r.exc) {
cur_frm.cscript.make_jv(doc, 'Credit Note', r.message);
}
});
}
// Make JV
//--------------------------------
cur_frm.cscript.make_jv = function(doc, dr_or_cr, children) {
var jv = wn.model.make_new_doc_and_get_name('Journal Voucher');
jv = locals['Journal Voucher'][jv];
jv.voucher_type = dr_or_cr;
jv.company = sys_defaults.company;
jv.fiscal_year = sys_defaults.fiscal_year;
jv.is_opening = 'No';
jv.posting_date = doc.return_date;
// Add children
if(children) {
for(var i=0; i<children.length; i++) {
var ch = wn.model.add_child(jv, 'Journal Voucher Detail', 'entries');
$.extend(ch, children[i]);
ch.balance = flt(ch.balance);
}
}
loaddoc('Journal Voucher', jv.name);
}

View File

@ -1,71 +0,0 @@
# ERPNext - web based ERP (http://erpnext.com)
# Copyright (C) 2012 Web Notes Technologies Pvt Ltd
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from __future__ import unicode_literals
import webnotes
from webnotes.utils import flt
from webnotes.model import db_exists
from webnotes.model.doc import addchild
from webnotes.model.bean import copy_doclist
sql = webnotes.conn.sql
class DocType :
def __init__(self, doc, doclist=[]):
self.doc = doc
self.doclist = doclist
# Pull Item Details
# ---------------------------
def pull_item_details(self):
if self.doc.return_type == 'Sales Return':
if self.doc.delivery_note_no:
det = sql("select t1.name, t1.item_code, t1.description, t1.qty, t1.uom, t2.export_rate * t3.conversion_rate, t3.customer, t3.customer_name, t3.customer_address, t2.serial_no, t2.batch_no from `tabDelivery Note Packing Item` t1, `tabDelivery Note Item` t2, `tabDelivery Note` t3 where t1.parent = t3.name and t2.parent = t3.name and t1.parent_detail_docname = t2.name and t3.name = '%s' and t3.docstatus = 1" % self.doc.delivery_note_no)
elif self.doc.sales_invoice_no:
det = sql("select t1.name, t1.item_code, t1.description, t1.qty, t1.stock_uom, t1.export_rate * t2.conversion_rate, t2.customer, t2.customer_name, t2.customer_address, t1.serial_no from `tabSales Invoice Item` t1, `tabSales Invoice` t2 where t1.parent = t2.name and t2.name = '%s' and t2.docstatus = 1" % self.doc.sales_invoice_no)
elif self.doc.return_type == 'Purchase Return' and self.doc.purchase_receipt_no:
det = sql("select t1.name, t1.item_code, t1.description, t1.received_qty, t1.uom, t1.purchase_rate, t2.supplier, t2.supplier_name, t2.supplier_address, t1.serial_no, t1.batch_no from `tabPurchase Receipt Item` t1, `tabPurchase Receipt` t2 where t1.parent = t2.name and t2.name = '%s' and t2.docstatus = 1" % self.doc.purchase_receipt_no)
self.doc.cust_supp = det and det[0][6] or ''
self.doc.cust_supp_name = det and det[0][7] or ''
self.doc.cust_supp_address = det and det[0][8] or ''
self.create_item_table(det)
self.doc.save()
# Create Item Table
# -----------------------------
def create_item_table(self, det):
self.doclist = self.doc.clear_table(self.doclist, 'return_details', 1)
for i in det:
ch = addchild(self.doc, 'return_details', 'Sales and Purchase Return Item',
self.doclist)
ch.detail_name = i and i[0] or ''
ch.item_code = i and i[1] or ''
ch.description = i and i[2] or ''
ch.qty = i and flt(i[3]) or 0
ch.uom = i and i[4] or ''
ch.rate = i and flt(i[5]) or 0
ch.serial_no = i and i[9] or ''
ch.batch_no = (len(i) == 11) and i[10] or ''
ch.save()
# Clear return table
# --------------------------------
def clear_return_table(self):
self.doclist = self.doc.clear_table(self.doclist, 'return_details', 1)
self.doc.save()

View File

@ -1,191 +0,0 @@
[
{
"creation": "2013-01-10 16:34:29",
"docstatus": 0,
"modified": "2013-01-23 16:48:38",
"modified_by": "Administrator",
"owner": "wasim@webnotestech.com"
},
{
"doctype": "DocType",
"issingle": 1,
"istable": 0,
"module": "Stock",
"name": "__common__"
},
{
"doctype": "DocField",
"name": "__common__",
"parent": "Sales and Purchase Return Tool",
"parentfield": "fields",
"parenttype": "DocType",
"permlevel": 0
},
{
"create": 1,
"doctype": "DocPerm",
"name": "__common__",
"parent": "Sales and Purchase Return Tool",
"parentfield": "permissions",
"parenttype": "DocType",
"permlevel": 0,
"read": 1,
"report": 0,
"submit": 0,
"write": 1
},
{
"doctype": "DocType",
"name": "Sales and Purchase Return Tool"
},
{
"doctype": "DocField",
"fieldname": "return_date",
"fieldtype": "Date",
"label": "Return Date",
"no_copy": 1,
"oldfieldname": "return_date",
"oldfieldtype": "Date",
"reqd": 1
},
{
"doctype": "DocField",
"fieldname": "return_type",
"fieldtype": "Select",
"label": "Return Type",
"no_copy": 1,
"oldfieldname": "return_type",
"oldfieldtype": "Select",
"options": "\nSales Return\nPurchase Return",
"reqd": 1
},
{
"doctype": "DocField",
"fieldname": "delivery_note_no",
"fieldtype": "Link",
"hidden": 1,
"label": "Delivery Note No",
"no_copy": 1,
"oldfieldname": "delivery_note_no",
"oldfieldtype": "Link",
"options": "Delivery Note",
"reqd": 0
},
{
"doctype": "DocField",
"fieldname": "sales_invoice_no",
"fieldtype": "Link",
"hidden": 1,
"label": "Sales Invoice No",
"options": "Sales Invoice"
},
{
"doctype": "DocField",
"fieldname": "purchase_receipt_no",
"fieldtype": "Link",
"hidden": 1,
"label": "Purchase Receipt No",
"no_copy": 1,
"oldfieldname": "purchase_receipt_no",
"oldfieldtype": "Link",
"options": "Purchase Receipt"
},
{
"doctype": "DocField",
"fieldname": "company",
"fieldtype": "Link",
"hidden": 1,
"label": "Company",
"options": "Company",
"print_hide": 1
},
{
"doctype": "DocField",
"fieldname": "cust_supp",
"fieldtype": "Data",
"hidden": 1,
"label": "Customer/Supplier",
"print_hide": 1,
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "cust_supp_name",
"fieldtype": "Data",
"hidden": 1,
"label": "Cust/Supp Name",
"print_hide": 1,
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "cust_supp_address",
"fieldtype": "Small Text",
"hidden": 1,
"label": "Cust/Supp Address",
"print_hide": 1,
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "get_items",
"fieldtype": "Button",
"hidden": 1,
"label": "Get Items",
"oldfieldtype": "Button"
},
{
"doctype": "DocField",
"fieldname": "return_details",
"fieldtype": "Table",
"hidden": 1,
"label": "Sales and Purchase Return Items",
"no_copy": 1,
"oldfieldname": "return_details",
"oldfieldtype": "Table",
"options": "Sales and Purchase Return Item",
"read_only": 1
},
{
"doctype": "DocField",
"fieldname": "make_stock_entry",
"fieldtype": "Button",
"hidden": 1,
"label": "Make Stock Entry",
"oldfieldtype": "Button"
},
{
"doctype": "DocField",
"fieldname": "make_excise_invoice",
"fieldtype": "Button",
"hidden": 1,
"label": "Make Excise Invoice",
"oldfieldtype": "Button"
},
{
"doctype": "DocField",
"fieldname": "make_credit_note",
"fieldtype": "Button",
"hidden": 1,
"label": "Make Credit Note",
"oldfieldtype": "Button"
},
{
"doctype": "DocField",
"fieldname": "make_debit_note",
"fieldtype": "Button",
"hidden": 1,
"label": "Make Debit Note",
"oldfieldtype": "Button"
},
{
"amend": 0,
"cancel": 0,
"doctype": "DocPerm",
"role": "Material User"
},
{
"doctype": "DocPerm",
"role": "Accounts User"
}
]

View File

@ -95,12 +95,6 @@ wn.module_page["Stock"] = [
description: wn._("Change UOM for an Item."),
"doctype": "Stock UOM Replace Utility"
},
{
"route":"Form/Sales and Purchase Return Tool/Sales and Purchase Return Tool",
"label": wn._("Sales and Purchase Return Tool"),
doctype: "Sales and Purchase Return Tool",
description: wn._("Manage sales or purchase returns")
},
]
},
{