|
@ -7,7 +7,7 @@ import logging |
|
|
_logger = logging.getLogger(__name__) |
|
|
_logger = logging.getLogger(__name__) |
|
|
|
|
|
|
|
|
try: |
|
|
try: |
|
|
from openpyxl.styles import colors, PatternFill, Alignment, Font |
|
|
|
|
|
|
|
|
from openpyxl.styles import PatternFill, Alignment, Font |
|
|
except ImportError: |
|
|
except ImportError: |
|
|
_logger.debug( |
|
|
_logger.debug( |
|
|
'Cannot import "openpyxl". Please make sure it is installed.') |
|
|
'Cannot import "openpyxl". Please make sure it is installed.') |
|
@ -24,7 +24,7 @@ class XLSXStyles(models.AbstractModel): |
|
|
'font': { |
|
|
'font': { |
|
|
'bold': Font(name="Arial", size=10, bold=True), |
|
|
'bold': Font(name="Arial", size=10, bold=True), |
|
|
'bold_red': Font(name="Arial", size=10, |
|
|
'bold_red': Font(name="Arial", size=10, |
|
|
color=colors.RED, bold=True), |
|
|
|
|
|
|
|
|
color="FF0000", bold=True), |
|
|
}, |
|
|
}, |
|
|
'fill': { |
|
|
'fill': { |
|
|
'red': PatternFill("solid", fgColor="FF0000"), |
|
|
'red': PatternFill("solid", fgColor="FF0000"), |
|
|