ソースを参照

[minor] Handle string with no html tag in xlsxutils (#3332)

version-14
Faris Ansari 8年前
committed by Nabin Hait
コミット
f16854559d
1個のファイルの変更6行の追加0行の削除
  1. +6
    -0
      frappe/utils/xlsxutils.py

+ 6
- 0
frappe/utils/xlsxutils.py ファイルの表示

@@ -37,6 +37,12 @@ def make_xlsx(data, sheet_name):




def handle_html(data): def handle_html(data):
# return if no html tags found
if '<' not in data:
return data
if '>' not in data:
return data

from html2text import unescape, HTML2Text from html2text import unescape, HTML2Text


h = HTML2Text() h = HTML2Text()


読み込み中…
キャンセル
保存