diff --git a/erpnext/accounts/doctype/journal_voucher/journal_voucher.py b/erpnext/accounts/doctype/journal_voucher/journal_voucher.py index a8854abf5e..cb2ebace26 100644 --- a/erpnext/accounts/doctype/journal_voucher/journal_voucher.py +++ b/erpnext/accounts/doctype/journal_voucher/journal_voucher.py @@ -142,7 +142,7 @@ class JournalVoucher(AccountsController): if self.cheque_date: r.append(_('Reference #{0} dated {1}').format(self.cheque_no, formatdate(self.cheque_date))) else: - msgprint(_("Please enter Reference date"), raise_exception=1) + msgprint(_("Please enter Reference date"), raise_exception=frappe.MandatoryError) for d in self.get('entries'): if d.against_invoice and d.credit: @@ -164,7 +164,7 @@ class JournalVoucher(AccountsController): if r: self.remark = ("\n").join(r) else: - frappe.msgprint(_("User Remarks is mandatory"), raise_exception=1) + frappe.msgprint(_("User Remarks is mandatory"), raise_exception=frappe.MandatoryError) def set_aging_date(self): if self.is_opening != 'Yes': diff --git a/erpnext/patches.txt b/erpnext/patches.txt index a326eca2e1..e9ba56b38f 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -65,3 +65,4 @@ erpnext.patches.v4_0.update_users_report_view_settings erpnext.patches.v4_0.set_pricing_rule_for_buying_or_selling erpnext.patches.v4_0.set_naming_series_property_setter erpnext.patches.v4_1.set_outgoing_email_footer +erpnext.patches.v4_1.fix_jv_remarks diff --git a/erpnext/patches/v4_1/fix_jv_remarks.py b/erpnext/patches/v4_1/fix_jv_remarks.py new file mode 100644 index 0000000000..3b2f342231 --- /dev/null +++ b/erpnext/patches/v4_1/fix_jv_remarks.py @@ -0,0 +1,21 @@ +# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors +# License: GNU General Public License v3. See license.txt + +from __future__ import unicode_literals +import frappe + +def execute(): + reference_date = guess_reference_date() + for name in frappe.db.sql_list("""select name from `tabJournal Voucher` + where date(creation)>=%s""", reference_date): + jv = frappe.get_doc("Journal Voucher", name) + try: + jv.create_remarks() + except frappe.MandatoryError: + pass + else: + frappe.db.set_value("Journal Voucher", jv.name, "remark", jv.remark) + +def guess_reference_date(): + return (frappe.db.get_value("Patch Log", {"patch": "erpnext.patches.v4_0.validate_v3_patch"}, "creation") + or "2014-05-06") diff --git a/erpnext/translations/ar.csv b/erpnext/translations/ar.csv index b90e7c283b..0695f9ea63 100644 --- a/erpnext/translations/ar.csv +++ b/erpnext/translations/ar.csv @@ -3212,7 +3212,7 @@ website page link,الموقع رابط الصفحة {0} must have role 'Leave Approver',{0} يجب أن يكون دور ' اترك الموافق ' {0} valid serial nos for Item {1},{0} غ المسلسل صالحة لل تفاصيل {1} {0} {1} against Bill {2} dated {3},{0} {1} ضد بيل {2} بتاريخ {3} -{0} {1} against Invoice {1},{0} {1} ضد الفاتورة {1} +{0} {1} against Invoice {2},{0} {1} ضد الفاتورة {2} {0} {1} has already been submitted,{0} {1} وقد تم بالفعل قدمت {0} {1} has been modified. Please Refresh,{0} {1} تم تعديل . يرجى تحديث {0} {1} has been modified. Please refresh,{0} {1} تم تعديل . يرجى تحديث diff --git a/erpnext/translations/de.csv b/erpnext/translations/de.csv index 7083a1f756..040c068058 100644 --- a/erpnext/translations/de.csv +++ b/erpnext/translations/de.csv @@ -3212,7 +3212,7 @@ website page link,Website-Link {0} must have role 'Leave Approver',"{0} muss Rolle "" Genehmiger Leave ' haben" {0} valid serial nos for Item {1},{0} gültige Seriennummernfür Artikel {1} {0} {1} against Bill {2} dated {3},{0} {1} gegen Bill {2} {3} vom -{0} {1} against Invoice {1},{0} {1} gegen Rechnung {1} +{0} {1} against Invoice {2},{0} {1} gegen Rechnung {2} {0} {1} has already been submitted,{0} {1} wurde bereits eingereicht {0} {1} has been modified. Please Refresh,{0} {1} wurde geändert . Bitte aktualisieren {0} {1} has been modified. Please refresh,{0} {1} wurde geändert . Bitte aktualisieren diff --git a/erpnext/translations/el.csv b/erpnext/translations/el.csv index aff9b28664..8b5bf1340b 100644 --- a/erpnext/translations/el.csv +++ b/erpnext/translations/el.csv @@ -3212,7 +3212,7 @@ website page link,Ιστοσελίδα link της σελίδας {0} must have role 'Leave Approver',{0} πρέπει να έχει ρόλο « Αφήστε Έγκρισης » {0} valid serial nos for Item {1},{0} έγκυρο σειριακό nos για τη θέση {1} {0} {1} against Bill {2} dated {3},{0} {1} εναντίον Bill {2} { 3 με ημερομηνία } -{0} {1} against Invoice {1},{0} {1} κατά Τιμολόγιο {1} +{0} {1} against Invoice {2},{0} {1} κατά Τιμολόγιο {2} {0} {1} has already been submitted,{0} {1} έχει ήδη υποβληθεί {0} {1} has been modified. Please Refresh,{0} {1} έχει τροποποιηθεί . Παρακαλούμε Ανανέωση {0} {1} has been modified. Please refresh,{0} {1} έχει τροποποιηθεί . Παρακαλούμε ανανεώστε diff --git a/erpnext/translations/es.csv b/erpnext/translations/es.csv index 5a3b28f9e7..1832310f0d 100644 --- a/erpnext/translations/es.csv +++ b/erpnext/translations/es.csv @@ -3212,7 +3212,7 @@ website page link,el vínculo web {0} must have role 'Leave Approver',{0} debe tener rol ' Dejar aprobador ' {0} valid serial nos for Item {1},{0} nn serie válidos para el elemento {1} {0} {1} against Bill {2} dated {3},{0} {1} { 2 contra Bill } {3} de fecha -{0} {1} against Invoice {1},{0} {1} contra Factura {1} +{0} {1} against Invoice {2},{0} {1} contra Factura {2} {0} {1} has already been submitted,{0} {1} ya ha sido presentado {0} {1} has been modified. Please Refresh,{0} {1} ha sido modificado. recargar {0} {1} has been modified. Please refresh,"{0} {1} ha sido modificado. Por favor, actualice" diff --git a/erpnext/translations/fr.csv b/erpnext/translations/fr.csv index 12e7e4a44d..6650486223 100644 --- a/erpnext/translations/fr.csv +++ b/erpnext/translations/fr.csv @@ -3212,7 +3212,7 @@ website page link,Lien vers page web {0} must have role 'Leave Approver',Nouveau Stock UDM est nécessaire {0} valid serial nos for Item {1},BOM {0} pour objet {1} à la ligne {2} est inactif ou non soumis {0} {1} against Bill {2} dated {3},S'il vous plaît entrer le titre ! -{0} {1} against Invoice {1},investissements +{0} {1} against Invoice {2},investissements {0} {1} has already been submitted,"S'il vous plaît entrer » est sous-traitée "" comme Oui ou Non" {0} {1} has been modified. Please Refresh,Maître de taux de change . {0} {1} has been modified. Please refresh,{0} {1} a été modifié . S'il vous plaît rafraîchir diff --git a/erpnext/translations/hi.csv b/erpnext/translations/hi.csv index cbb275dfa6..f657f663ff 100644 --- a/erpnext/translations/hi.csv +++ b/erpnext/translations/hi.csv @@ -3212,7 +3212,7 @@ website page link,वेबसाइट के पेज लिंक {0} must have role 'Leave Approver',{0} भूमिका ' लीव अनुमोदक ' होना चाहिए {0} valid serial nos for Item {1},आइटम के लिए {0} वैध धारावाहिक नग {1} {0} {1} against Bill {2} dated {3},{0} {1} विधेयक के खिलाफ {2} दिनांक {3} -{0} {1} against Invoice {1},{0} {1} चालान के खिलाफ {1} +{0} {1} against Invoice {2},{0} {1} चालान के खिलाफ {2} {0} {1} has already been submitted,{0} {1} पहले से ही प्रस्तुत किया गया है {0} {1} has been modified. Please Refresh,{0} {1} संशोधित किया गया है . ताज़ा करें {0} {1} has been modified. Please refresh,{0} {1} संशोधित किया गया है . ताज़ा करें diff --git a/erpnext/translations/hr.csv b/erpnext/translations/hr.csv index d5971606b6..7467bb5d63 100644 --- a/erpnext/translations/hr.csv +++ b/erpnext/translations/hr.csv @@ -3212,7 +3212,7 @@ website page link,web stranica vode {0} must have role 'Leave Approver',{0} mora imati ulogu ' Leave odobravatelju ' {0} valid serial nos for Item {1},{0} valjani serijski nos za Stavka {1} {0} {1} against Bill {2} dated {3},{0} {1} od {2} Billa od {3} -{0} {1} against Invoice {1},{0} {1} protiv fakture {1} +{0} {1} against Invoice {2},{0} {1} protiv fakture {2} {0} {1} has already been submitted,{0} {1} je već poslan {0} {1} has been modified. Please Refresh,{0} {1} je izmijenjen . Osvježite {0} {1} has been modified. Please refresh,{0} {1} je izmijenjen . osvježite diff --git a/erpnext/translations/it.csv b/erpnext/translations/it.csv index 49aadc8745..92d2cfc8c1 100644 --- a/erpnext/translations/it.csv +++ b/erpnext/translations/it.csv @@ -3212,7 +3212,7 @@ website page link,sito web link alla pagina {0} must have role 'Leave Approver',{0} deve avere ruolo di ' Lascia Approvatore ' {0} valid serial nos for Item {1},{0} nos seriali validi per Voce {1} {0} {1} against Bill {2} dated {3},{0} {1} contro Bill {2} del {3} -{0} {1} against Invoice {1},{0} {1} contro fattura {1} +{0} {1} against Invoice {2},{0} {1} contro fattura {2} {0} {1} has already been submitted,{0} {1} è già stata presentata {0} {1} has been modified. Please Refresh,{0} {1} è stato modificato . Si prega Aggiorna {0} {1} has been modified. Please refresh,{0} {1} è stato modificato . Si prega di aggiornare diff --git a/erpnext/translations/kn.csv b/erpnext/translations/kn.csv index 4403bc6278..4bfeb613b2 100644 --- a/erpnext/translations/kn.csv +++ b/erpnext/translations/kn.csv @@ -3212,7 +3212,7 @@ website page link,ವೆಬ್ಸೈಟ್ ಪುಟ ಲಿಂಕ್ {0} must have role 'Leave Approver',{0} ಪಾತ್ರದಲ್ಲಿ 'ಲೀವ್ ಅನುಮೋದಕ ' ಹೊಂದಿರಬೇಕು {0} valid serial nos for Item {1},ಐಟಂ {0} ಮಾನ್ಯ ಸರಣಿ ಸೂಲ {1} {0} {1} against Bill {2} dated {3},{0} {1} ಮಸೂದೆ ವಿರುದ್ಧ {2} {3} ದಿನಾಂಕ -{0} {1} against Invoice {1},{0} {1} {1} ಸರಕುಪಟ್ಟಿ ವಿರುದ್ಧ +{0} {1} against Invoice {2},{0} {1} {2} ಸರಕುಪಟ್ಟಿ ವಿರುದ್ಧ {0} {1} has already been submitted,{0} {1} ಈಗಾಗಲೇ ಸಲ್ಲಿಸಲಾಗಿದೆ {0} {1} has been modified. Please Refresh,{0} {1} ಮಾರ್ಪಡಿಸಲಾಗಿದೆ. ರಿಫ್ರೆಶ್ ಮಾಡಿ {0} {1} has been modified. Please refresh,{0} {1} ಮಾರ್ಪಡಿಸಲಾಗಿದೆ. ರಿಫ್ರೆಶ್ ಮಾಡಿ diff --git a/erpnext/translations/ko.csv b/erpnext/translations/ko.csv index 7beab13405..ea7ca81eec 100644 --- a/erpnext/translations/ko.csv +++ b/erpnext/translations/ko.csv @@ -3212,7 +3212,7 @@ website page link,pagina site-ului link-ul {0} must have role 'Leave Approver',"{0} trebuie să aibă rol de ""Leave aprobator""" {0} valid serial nos for Item {1},{0} nos serie valabile pentru postul {1} {0} {1} against Bill {2} dated {3},{0} {1} împotriva Bill {2} din {3} -{0} {1} against Invoice {1},{0} {1} împotriva Factura {1} +{0} {1} against Invoice {2},{0} {1} împotriva Factura {2} {0} {1} has already been submitted,{0} {1} a fost deja prezentat {0} {1} has been modified. Please Refresh,{0} {1} a fost modificat. Va rugam sa Refresh {0} {1} has been modified. Please refresh,{0} {1} a fost modificat. Vă rugăm să reîmprospătați diff --git a/erpnext/translations/nl.csv b/erpnext/translations/nl.csv index 5fd835773c..648b675ab5 100644 --- a/erpnext/translations/nl.csv +++ b/erpnext/translations/nl.csv @@ -3212,7 +3212,7 @@ website page link,website Paginalink {0} must have role 'Leave Approver',{0} moet rol ' Leave Approver ' hebben {0} valid serial nos for Item {1},{0} geldig serienummer nos voor post {1} {0} {1} against Bill {2} dated {3},{0} {1} tegen Bill {2} gedateerd {3} -{0} {1} against Invoice {1},{0} {1} tegen Factuur {1} +{0} {1} against Invoice {2},{0} {1} tegen Factuur {2} {0} {1} has already been submitted,{0} {1} al is ingediend {0} {1} has been modified. Please Refresh,{0} {1} is gewijzigd . Vernieuw {0} {1} has been modified. Please refresh,{0} {1} is gewijzigd . Vernieuw diff --git a/erpnext/translations/pt-BR.csv b/erpnext/translations/pt-BR.csv index 54d854015c..42195b37d6 100644 --- a/erpnext/translations/pt-BR.csv +++ b/erpnext/translations/pt-BR.csv @@ -3212,7 +3212,7 @@ website page link,link da página do site {0} must have role 'Leave Approver',{0} deve ter papel ' Leave aprovador ' {0} valid serial nos for Item {1},{0} N º s de série válido para o item {1} {0} {1} against Bill {2} dated {3},{0} {1} contra Bill {2} {3} datado -{0} {1} against Invoice {1},{0} {1} contra Invoice {1} +{0} {1} against Invoice {2},{0} {1} contra Invoice {2} {0} {1} has already been submitted,{0} {1} já foi apresentado {0} {1} has been modified. Please Refresh,{0} {1} foi modificado . Refresca {0} {1} has been modified. Please refresh,{0} {1} foi modificado . Refresca diff --git a/erpnext/translations/pt.csv b/erpnext/translations/pt.csv index a86c65a89a..fcd2637ddb 100644 --- a/erpnext/translations/pt.csv +++ b/erpnext/translations/pt.csv @@ -3212,7 +3212,7 @@ website page link,link da página site {0} must have role 'Leave Approver',{0} deve ter papel ' Leave aprovador ' {0} valid serial nos for Item {1},{0} N º s de série válido para o item {1} {0} {1} against Bill {2} dated {3},{0} {1} contra Bill {2} {3} datado -{0} {1} against Invoice {1},{0} {1} contra Invoice {1} +{0} {1} against Invoice {2},{0} {1} contra Invoice {2} {0} {1} has already been submitted,{0} {1} já foi apresentado {0} {1} has been modified. Please Refresh,{0} {1} foi modificado . Refresca {0} {1} has been modified. Please refresh,{0} {1} foi modificado . Refresca diff --git a/erpnext/translations/ro.csv b/erpnext/translations/ro.csv index 7beab13405..ea7ca81eec 100644 --- a/erpnext/translations/ro.csv +++ b/erpnext/translations/ro.csv @@ -3212,7 +3212,7 @@ website page link,pagina site-ului link-ul {0} must have role 'Leave Approver',"{0} trebuie să aibă rol de ""Leave aprobator""" {0} valid serial nos for Item {1},{0} nos serie valabile pentru postul {1} {0} {1} against Bill {2} dated {3},{0} {1} împotriva Bill {2} din {3} -{0} {1} against Invoice {1},{0} {1} împotriva Factura {1} +{0} {1} against Invoice {2},{0} {1} împotriva Factura {2} {0} {1} has already been submitted,{0} {1} a fost deja prezentat {0} {1} has been modified. Please Refresh,{0} {1} a fost modificat. Va rugam sa Refresh {0} {1} has been modified. Please refresh,{0} {1} a fost modificat. Vă rugăm să reîmprospătați diff --git a/erpnext/translations/sr.csv b/erpnext/translations/sr.csv index d2d7e25138..9752b3d6cc 100644 --- a/erpnext/translations/sr.csv +++ b/erpnext/translations/sr.csv @@ -3212,7 +3212,7 @@ website page link,веб страница веза {0} must have role 'Leave Approver',"{0} должен иметь роль "" Оставить утверждающего '" {0} valid serial nos for Item {1},{0} действительные серийные NOS для Пункт {1} {0} {1} against Bill {2} dated {3},{0} {1} против Билла {2} от {3} -{0} {1} against Invoice {1},{0} {1} против Invoice {1} +{0} {1} against Invoice {2},{0} {1} против Invoice {2} {0} {1} has already been submitted,{0} {1} уже представлен {0} {1} has been modified. Please Refresh,{0} {1} был изменен. Пожалуйста Обновить {0} {1} has been modified. Please refresh,"{0} {1} был изменен. Пожалуйста, обновите" diff --git a/erpnext/translations/ta.csv b/erpnext/translations/ta.csv index 7e7a7d8917..fe93cc3bbf 100644 --- a/erpnext/translations/ta.csv +++ b/erpnext/translations/ta.csv @@ -3212,7 +3212,7 @@ website page link,இணைய பக்கம் இணைப்பு {0} must have role 'Leave Approver',{0} பங்கு 'விடுப்பு அப்ரூவரான ' வேண்டும் {0} valid serial nos for Item {1},உருப்படி {0} செல்லுபடியாகும் தொடர் இலக்கங்கள் {1} {0} {1} against Bill {2} dated {3},{0} {1} பில் எதிராக {2} தேதியிட்ட {3} -{0} {1} against Invoice {1},{0} {1} விலைப்பட்டியல் எதிரான {1} +{0} {1} against Invoice {2},{0} {1} விலைப்பட்டியல் எதிரான {2} {0} {1} has already been submitted,{0} {1} ஏற்கனவே சமர்ப்பித்த {0} {1} has been modified. Please Refresh,{0} {1} மாற்றப்பட்டுள்ளது . புதுப்பிக்கவும் {0} {1} has been modified. Please refresh,{0} {1} மாற்றப்பட்டுள்ளது . புதுப்பிக்கவும் diff --git a/erpnext/translations/th.csv b/erpnext/translations/th.csv index 6c787821a2..fb628bc6cb 100644 --- a/erpnext/translations/th.csv +++ b/erpnext/translations/th.csv @@ -3212,7 +3212,7 @@ website page link,การเชื่อมโยงหน้าเว็บ {0} must have role 'Leave Approver',{0} ต้องมี บทบาท ' ออก อนุมัติ ' {0} valid serial nos for Item {1},{0} กัดกร่อน แบบอนุกรม ที่ถูกต้องสำหรับ รายการ {1} {0} {1} against Bill {2} dated {3},{0} {1} กับ บิล {2} ลงวันที่ {3} -{0} {1} against Invoice {1},{0} {1} กับ ใบแจ้งหนี้ {1} +{0} {1} against Invoice {2},{0} {1} กับ ใบแจ้งหนี้ {2} {0} {1} has already been submitted,{0} {1} ถูกส่งมา อยู่แล้ว {0} {1} has been modified. Please Refresh,{0} {1} ได้รับการแก้ไข กรุณา รีเฟรช {0} {1} has been modified. Please refresh,{0} {1} ได้รับการแก้ไข กรุณารีเฟรช diff --git a/erpnext/translations/zh-cn.csv b/erpnext/translations/zh-cn.csv index 40c4d4a1c0..e7b81993f7 100644 --- a/erpnext/translations/zh-cn.csv +++ b/erpnext/translations/zh-cn.csv @@ -3212,7 +3212,7 @@ website page link,网站页面的链接 {0} must have role 'Leave Approver',{0}必须有角色“请假审批” {0} valid serial nos for Item {1},{0}有效的序列号的项目{1} {0} {1} against Bill {2} dated {3},{0} {1}反对比尔{2}于{3} -{0} {1} against Invoice {1},{0} {1}对发票{1} +{0} {1} against Invoice {2},{0} {1}对发票{2} {0} {1} has already been submitted,{0} {1}已经提交 {0} {1} has been modified. Please Refresh,{0} {1}已被修改。请刷新 {0} {1} has been modified. Please refresh,{0} {1}已被修改。请刷新 diff --git a/erpnext/translations/zh-tw.csv b/erpnext/translations/zh-tw.csv index a1b5103a57..2d58a15756 100644 --- a/erpnext/translations/zh-tw.csv +++ b/erpnext/translations/zh-tw.csv @@ -3212,7 +3212,7 @@ website page link,網站頁面的鏈接 {0} must have role 'Leave Approver',{0}必須有角色“請假審批” {0} valid serial nos for Item {1},{0}有效的序列號的項目{1} {0} {1} against Bill {2} dated {3},{0} {1}反對比爾{2}於{3} -{0} {1} against Invoice {1},{0} {1}對發票{1} +{0} {1} against Invoice {2},{0} {1}對發票{2} {0} {1} has already been submitted,{0} {1}已經提交 {0} {1} has been modified. Please Refresh,{0} {1}已被修改。請刷新 {0} {1} has been modified. Please refresh,{0} {1}已被修改。請刷新