[更新]修复粉丝图文编辑ID丢失的问题

This commit is contained in:
Anyon 2017-05-12 17:43:58 +08:00
parent f2bfef24e2
commit 132498c7cf

View File

@ -166,6 +166,7 @@
// 处理上一个编辑器 // 处理上一个编辑器
if ($form && $pItem && $pItem.size() > 0) { if ($form && $pItem && $pItem.size() > 0) {
var data = {}; var data = {};
data.id = $form.find('[name=id]').val();
data.title = $form.find('[name=title]').val(); data.title = $form.find('[name=title]').val();
data.local_url = $form.find('[name=local_url]').val(); data.local_url = $form.find('[name=local_url]').val();
data.content = editor.getContent() || ''; data.content = editor.getContent() || '';
@ -189,6 +190,7 @@
$item = $('.news-item.active'); $item = $('.news-item.active');
this.get = function () { this.get = function () {
var data = $item.data('item') || {}; var data = $item.data('item') || {};
data.id = data.id || 0;
data.title = data.title || ''; data.title = data.title || '';
data.local_url = data.local_url || '__PUBLIC__/static/plugs/uploader/theme/image.png'; data.local_url = data.local_url || '__PUBLIC__/static/plugs/uploader/theme/image.png';
data.content = data.content || ''; data.content = data.content || '';