Remove htmlentities, use html-to-text
This commit is contained in:
parent
5f07b85975
commit
ad7051f2e0
|
@ -60,6 +60,7 @@
|
|||
"draft-js": "^0.10.0",
|
||||
"draft-js-export-html": "^0.5.2",
|
||||
"history": "^3.0.0",
|
||||
"html-to-text": "^4.0.0",
|
||||
"jquery": "^2.1.4",
|
||||
"keycode": "^2.1.4",
|
||||
"localStorage": "^1.0.3",
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import React from 'react';
|
||||
import _ from 'lodash';
|
||||
import htmlToText from 'html-to-text';
|
||||
|
||||
import i18n from 'lib-app/i18n';
|
||||
import Icon from 'core-components/icon';
|
||||
|
@ -19,7 +20,7 @@ class TicketInfo extends React.Component {
|
|||
</span>
|
||||
</div>
|
||||
<div className="ticket-info__description">
|
||||
{this.props.ticket.content}
|
||||
{htmlToText.fromString(this.props.ticket.content)}
|
||||
</div>
|
||||
|
||||
<div className="ticket-info__author">
|
||||
|
@ -90,4 +91,4 @@ class TicketInfo extends React.Component {
|
|||
}
|
||||
}
|
||||
|
||||
export default TicketInfo;
|
||||
export default TicketInfo;
|
||||
|
|
|
@ -33,7 +33,7 @@ class AddDepartmentController extends Controller {
|
|||
}
|
||||
|
||||
public function handler() {
|
||||
$name = htmlentities(Controller::request('name'));
|
||||
$name = Controller::request('name');
|
||||
|
||||
$departmentInstance = new Department();
|
||||
|
||||
|
|
|
@ -85,8 +85,8 @@ class CreateController extends Controller {
|
|||
}
|
||||
|
||||
public function handler() {
|
||||
$this->title = htmlentities(Controller::request('title'));
|
||||
$this->content = htmlentities(Controller::request('content', true));
|
||||
$this->title = Controller::request('title');
|
||||
$this->content = Controller::request('content', true);
|
||||
$this->departmentId = Controller::request('departmentId');
|
||||
$this->language = Controller::request('language');
|
||||
$this->email = Controller::request('email');
|
||||
|
|
Loading…
Reference in New Issue