|
@@ -72,10 +72,13 @@ class DistAppearanceTemplate extends EloquentRepository
|
|
|
$distId = intval($distId);
|
|
|
$data = Model::where('dist_id', $distId)->where('appearance_id', $appearanceId)->where('appearance_id', $appearanceId)->where('template_code', $templateCode)->first();
|
|
|
if ($data) {
|
|
|
+ $currentContent = $content;
|
|
|
+ $previousContent = $data->content;
|
|
|
+ //保存
|
|
|
$data->content = $content;
|
|
|
$data->save();
|
|
|
//加入模版修改日志
|
|
|
- DistAppearanceTemplateLog::insertLog($appearanceId,$distId,$templateCode,$content);
|
|
|
+ DistAppearanceTemplateLog::insertLog($appearanceId,$distId,$templateCode,$currentContent,$previousContent);
|
|
|
return true;
|
|
|
}
|
|
|
return false;
|