|
|
@@ -49,7 +49,7 @@ def read_csv_content(fcontent, ignore_encoding=False): |
|
|
|
raise_exception=True) |
|
|
|
|
|
|
|
try: |
|
|
|
reader = csv.reader(fcontent.encode("utf-8").splitlines()) |
|
|
|
reader = csv.reader(fcontent.encode("utf-8").splitlines(True)) |
|
|
|
# decode everything |
|
|
|
rows = [[unicode(val, "utf-8").strip() for val in row] for row in reader] |
|
|
|
return rows |
|
|
@@ -91,7 +91,6 @@ class UnicodeWriter: |
|
|
|
|
|
|
|
def check_record(d, parenttype=None, doctype_dl=None): |
|
|
|
"""check for mandatory, select options, dates. these should ideally be in doclist""" |
|
|
|
|
|
|
|
from webnotes.utils.dateutils import parse_date |
|
|
|
if parenttype and not d.get('parent'): |
|
|
|
webnotes.msgprint(_("Parent is required."), raise_exception=1) |
|
|
|