AppFlowy-IO / AppFlowy-IO/appflowy-editor

[Bug] Editor Does not Display Html Email Template

オープン
#492 コメント 6 件 リアクション 0 件 担当者 0 名 GitHub で見る
p1
主要言語
Dart
スター
684
フォーク
329
PR マージ指標
30日以内にマージされた PR はありません

説明

### Bug Description

I'm having a hard time figuring out why the following HTML template is not rendered by the editor.

Initially, I thought that there was some problem in this template that was causing the issue, but I tried to render it using an [HTML Renderer](https://pub.dev/packages/flutter_widget_from_html) from the pub and it worked.

### How to Reproduce

Try to render this HTML Email template using `htmlToDocument`

```






Welcome to Odoo


${object.name}


${object.company_id.name}














Dear ${object.name},


You have been invited by ${object.create_uid.name} of ${object.company_id.name} to connect on Odoo.


Accept invitation


% set website_url = object.env['ir.config_parameter'].sudo().get_param('web.base.url')
Your Odoo domain is: ${website_url}

Your sign in email is: ${object.email}


Never heard of Odoo? It’s an all-in-one business software loved by 3+ million users. It will considerably improve your experience at work and increase your productivity.



Have a look at the Odoo Tour to discover the tool.



Enjoy Odoo!

--
The ${object.company_id.name} Team














${object.company_id.name}


${object.company_id.phone}
% if object.company_id.email
| ${object.company_id.email}
% endif
% if object.company_id.website
|
${object.company_id.website}

% endif





Powered by Odoo

```

### Same Template with Dummy Data

```






Welcome to Odoo


John Doe


Company ABC













Dear John Doe,


You have been invited by Jane Smith of Company ABC to connect on Odoo.


Accept invitation



Your Odoo domain is: https://www.example.com

Your sign in email is: johndoe@example.com


Never heard of Odoo? It’s an all-in-one business software loved by 3+ million users. It will considerably improve your experience at work and increase your productivity.



Have a look at the Odoo Tour to discover the tool.



Enjoy Odoo!

--
The Company ABC Team














Company ABC


+123-456-7890 | info@example.com

|
https://www.example.com







Powered by Odoo

```

### Expected Behavior

I expect this to render the email template, like this preview






Welcome to Odoo


${object.name}


${object.company_id.name}














Dear ${object.name},


You have been invited by ${object.create_uid.name} of ${object.company_id.name} to connect on Odoo.


Accept invitation


% set website_url = object.env['ir.config_parameter'].sudo().get_param('web.base.url')
Your Odoo domain is: ${website_url}

Your sign in email is: ${object.email}


Never heard of Odoo? It’s an all-in-one business software loved by 3+ million users. It will considerably improve your experience at work and increase your productivity.



Have a look at the Odoo Tour to discover the tool.



Enjoy Odoo!

--
The ${object.company_id.name} Team














${object.company_id.name}


${object.company_id.phone}
% if object.company_id.email
| ${object.company_id.email}
% endif
% if object.company_id.website
|
${object.company_id.website}

% endif





Powered by Odoo

### Operating System

IOS

### AppFlowy Editor Version(s)

appflowy_editor: ^1.3.0

### Screenshots

Email template rendered by [flutter_widget_from_html](https://pub.dev/packages/flutter_widget_from_html)

![CleanShot 2023-09-21 at 11 58 44](https://github.com/AppFlowy-IO/appflowy-editor/assets/37589169/138ce491-8bf2-4115-bc28-178b91c80a84)

### Additional Context

_No response_

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。