jazzband/tablib

Extracting hidden url from hyperlink from .xlsx

IvanPrigulnov opened this issue · 1 comments

Hello, I need to parse a .xlsx file with a hyperlink hiding URL.
Screenshot from 2023-09-28 13-00-35
I can do it with the openpyxl:

hide_url = ws.cell(row, col).hyperlink.target

But django-import-export use tablib and I can't find a solution with the tablib.
Could you help with the solution?

I found the solution: changed the receipt of the variable
row_vals = [c.value if c.hyperlink is None else c.hyperlink.target for c in row]
in tablib.formats._xlsx.XLSXFormat.import_sheet and turn off the 'read_only'