Impacted versions:
10.0

Steps to reproduce:
Install `l10n_jp` and configure a company to use this chart of account in the menu `Accounting > Settings`

Current behavior:

Error is thrown:
```python
Traceback (most recent call last):
  File "/opt/odoo/src/odoo/http.py", line 638, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/opt/odoo/src/odoo/http.py", line 675, in dispatch
    result = self._call_function(**self.params)
  File "/opt/odoo/src/odoo/http.py", line 331, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/opt/odoo/src/odoo/service/model.py", line 119, in wrapper
    return f(dbname, *args, **kwargs)
  File "/opt/odoo/src/odoo/http.py", line 324, in checked_call
    result = self.endpoint(*a, **kw)
  File "/opt/odoo/src/odoo/http.py", line 933, in __call__
    return self.method(*args, **kw)
  File "/opt/odoo/src/odoo/http.py", line 504, in response_wrap
    response = f(*args, **kw)
  File "/opt/odoo/src/addons/web/controllers/main.py", line 866, in call_button
    action = self._call_kw(model, method, args, {})
  File "/opt/odoo/src/addons/web/controllers/main.py", line 854, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
  File "/opt/odoo/src/odoo/api.py", line 681, in call_kw
    return call_kw_multi(method, model, args, kwargs)
  File "/opt/odoo/src/odoo/api.py", line 672, in call_kw_multi
    result = method(recs, *args, **kwargs)
  File "/opt/odoo/src/odoo/addons/base/res/res_config.py", line 537, in execute
    getattr(self, method)()
  File "/opt/odoo/src/addons/account/models/res_config.py", line 261, in set_chart_of_accounts
    wizard.execute()
  File "/opt/odoo/src/addons/account/models/chart_template.py", line 821, in execute
    acc_template_ref, taxes_ref = self.chart_template_id._install_template(company, code_digits=self.code_digits, transfer_account_id=self.transfer_account_id)
  File "/opt/odoo/src/addons/account/models/chart_template.py", line 280, in _install_template
    tmp1, tmp2 = self._load_template(company, code_digits=code_digits, transfer_account_id=transfer_account_id, account_ref=acc_ref, taxes_ref=taxes_ref)
  File "/opt/odoo/src/addons/account/models/chart_template.py", line 336, in _load_template
    self.generate_fiscal_position(taxes_ref, account_ref, company)
  File "/opt/odoo/src/addons/account/models/chart_template.py", line 455, in generate_fiscal_position
    'position_id': new_fp
  File "/opt/odoo/src/addons/account/models/chart_template.py", line 350, in create_record_with_xmlid
    new_xml_id = str(company.id)+'_'+template_xmlid.name
TypeError: cannot concatenate 'str' and 'bool' objects
```

Expected behavior:

Chart of account is correctly configured for the desired company

Video/Screenshot link (optional):
![selection_012](https://cloud.githubusercontent.com/assets/8102312/22685563/148b11b2-ed21-11e6-97e4-1a88049eddfa.jpg)

help="Set this to False if you don't want this template to be used actively in the wizard that generate Chart of Accounts from "
            "templates, this is useful when you want to generate accounts of this template only when loading its child template.")
    currency_id = fields.Many2one('res.currency', string='Currency', required=True)
    use_anglo_saxon = fields.Boolean(string="Use Anglo-Saxon accounting", default=False)
    complete_tax_set = fields.Boolean(string='Complete Set of Taxes', default=True,
        help="This boolean helps you to choose if you want to propose to the user to encode the sale and purchase rates or choose from list "
            "of taxes. This last choice assumes that the set of tax defined on this template is complete")
    account_ids = fields.One2many('account.account.template', 'chart_template_id', string='Associated Account Templates')
    tax_template_ids = fields.One2many('account.tax.template', 'chart_template_id', string='Tax Template List',
        help='List of all the taxes that have to be installed by the wizard')
    bank_account_code_prefix = fields.Char(string='Prefix of the bank accounts', oldname="bank_account_code_char")
    cash_account_code_prefix = fields.Char(string='Prefix of the main cash accounts')
    transfer_account_id = fields.Many2one('account.account.template', string='Transfer Account', required=True,
        domain=lambda self: [('reconcile', '=', True), ('user_type_id.id', '=', self.env.ref('account.data_account_type_current_assets').id)],
        help="Intermediary account used when moving money from a liquidity account to another")
    income_currency_exchange_account_id = fields.Many2one('account.account.template',
        string="Gain Exchange Rate Account", domain=[('internal_type', '=', 'other'), ('deprecated', '=', False)])
    expense_currency_exchange_account_id = fields.Many2one('account.account.template',
        string="Loss Exchange Rate Account", domain=[('internal_type', '=', 'other'), ('deprecated', '=', False)])
    property_account_receivable_id = fields.Many2one('account.account.template', string='Receivable Account', oldname="property_account_receivable")
    property_account_payable_id = fields.Many2one('account.account.template', string='Payable Account', oldname="property_account_payable")
    property_account_expense_categ_id = fields.Many2one('account.account.template', string='Category of Expense Account', oldname="property_account_expense_categ")
    property_account_income_categ_id = fields.Many2one('account.account.template', string='Category of Income Account', oldname="property_account_income_categ")
    property_account_expense_id = fields.Many2one('account.account.template', string='Expense Account on Product Template', oldname="property_account_expense")
    property_account_income_id = fields.Many2one('account.account.template', string='Income Account on Product Template', oldname="property_account_income")
    property_stock_account_input_categ_id = fields.Many2one('account.account.template', string="Input Account for Stock Valuation", oldname="property_stock_account_input_categ")
    property_stock_account_output_categ_id = fields.Many2one('account.account.template', string="Output Account for Stock Valuation", oldname="property_stock_account_output_categ")
    property_stock_valuation_account_id = fields.Many2one('account.account.template', string="Account Template for Stock Valuation")
    @api.one
    def try_loading_for_current_company(self):