|
@@ -132,7 +132,7 @@
|
|
|
<script>
|
|
|
import { getRandomNumber } from '@/utils/index';
|
|
|
import { componentList } from '../../data/bookType';
|
|
|
-import { ContentSaveCoursewareContent, ContentGetCoursewareContent } from '@/api/book';
|
|
|
+import { ContentSaveCoursewareContent, ContentGetCoursewareContent, SaveBookUnifiedAttrib } from '@/api/book';
|
|
|
import _ from 'lodash';
|
|
|
|
|
|
import PreviewEdit from './PreviewEdit.vue';
|
|
@@ -370,6 +370,15 @@ export default {
|
|
|
item.setUnifiedAttr(data);
|
|
|
});
|
|
|
this.data.unified_attrib = data;
|
|
|
+ this.saveBookUnifiedAttr(data);
|
|
|
+ },
|
|
|
+ saveBookUnifiedAttr(data) {
|
|
|
+ SaveBookUnifiedAttrib({
|
|
|
+ book_id: this.project_id,
|
|
|
+ content: JSON.stringify(data),
|
|
|
+ }).catch(() => {
|
|
|
+ this.$message.error('保存失败');
|
|
|
+ });
|
|
|
},
|
|
|
/**
|
|
|
* 保存课件内容
|