Merge branch 'staging-fixes' into staging

This commit is contained in:
Ameya Shenoy 2018-10-08 07:27:35 +00:00
commit 8cafb5fbbb
No known key found for this signature in database
GPG Key ID: AC016A555657D0A3
6 changed files with 5 additions and 20 deletions

View File

@ -105,7 +105,9 @@ def get_healthcare_service_unit():
parent_service_unit.healthcare_service_unit_name = "All Healthcare Service Units"
parent_service_unit.is_group = 1
parent_service_unit.save(ignore_permissions = True)
service_unit.parent_healthcare_service_unit = "All Healthcare Service Units"
service_unit.parent_healthcare_service_unit = parent_service_unit.name
else:
service_unit.parent_healthcare_service_unit = service_unit_parent_name[0][0]
service_unit.save(ignore_permissions = True)
return service_unit.name
return service_unit

View File

@ -12,7 +12,7 @@ app_license = "GNU General Public License (v3)"
source_link = "https://github.com/frappe/erpnext"
develop_version = '11.x.x-develop'
staging_version = '11.0.3-beta.7'
staging_version = '11.0.3-beta.8'
error_report_email = "support@erpnext.com"

View File

@ -141,9 +141,6 @@ class JobCard(Document):
self.db_set('status', status)
def update_job_card_reference(name, fieldname, value):
frappe.db.set_value('Job Card', name, fieldname, value)
@frappe.whitelist()
def make_material_request(source_name, target_doc=None):
def update_item(obj, target, source_parent):

View File

@ -50,7 +50,7 @@ def make_tax_account(company, account_name, tax_rate):
"tax_rate": flt(tax_rate) if tax_rate else None
}).insert(ignore_permissions=True, ignore_mandatory=True)
except frappe.NameError:
frappe.message_log.pop()
if frappe.message_log: frappe.message_log.pop()
abbr = frappe.get_cached_value('Company', company, 'abbr')
account = '{0} - {1}'.format(account_name, abbr)
return frappe.get_doc('Account', account)

View File

@ -15,7 +15,6 @@ from erpnext.controllers.buying_controller import BuyingController
from erpnext.manufacturing.doctype.work_order.work_order import get_item_details
from erpnext.buying.utils import check_for_closed_status, validate_for_items
from erpnext.stock.doctype.item.item import get_item_defaults
from erpnext.manufacturing.doctype.job_card.job_card import update_job_card_reference
from six import string_types
@ -93,9 +92,6 @@ class MaterialRequest(BuyingController):
if self.material_request_type == 'Purchase':
self.validate_budget()
if self.job_card:
update_job_card_reference(self.job_card, 'material_request', self.name)
def before_save(self):
self.set_status(update=True)
@ -148,8 +144,6 @@ class MaterialRequest(BuyingController):
def on_cancel(self):
self.update_requested_qty()
self.update_requested_qty_in_production_plan()
if self.job_card:
update_job_card_reference(self.job_card, 'material_request', None)
def update_completed_qty(self, mr_items=None, update_modified=True):
if self.material_request_type == "Purchase":

View File

@ -17,7 +17,6 @@ from erpnext.stock.utils import get_bin
from erpnext.stock.doctype.serial_no.serial_no import update_serial_nos_after_submit, get_serial_nos
import json
from erpnext.manufacturing.doctype.job_card.job_card import update_job_card_reference
from six import string_types, itervalues, iteritems
@ -89,10 +88,6 @@ class StockEntry(StockController):
if self.work_order and self.purpose == "Manufacture":
self.update_so_in_serial_number()
if self.job_card:
update_job_card_reference(self.job_card, 'stock_entry', self.name)
def on_cancel(self):
if self.purchase_order and self.purpose == "Subcontract":
@ -107,9 +102,6 @@ class StockEntry(StockController):
self.make_gl_entries_on_cancel()
self.update_cost_in_project()
if self.job_card:
update_job_card_reference(self.job_card, 'stock_entry', None)
def set_job_card_data(self):
if self.job_card and not self.work_order:
data = frappe.db.get_value('Job Card',