|
@@ -1,4 +1,4 @@
|
|
|
-import type { SelectOption } from 'naive-ui'
|
|
|
+import type {SelectOption} from 'naive-ui'
|
|
|
import {
|
|
|
NAlert,
|
|
|
NButton,
|
|
@@ -20,20 +20,19 @@ import {
|
|
|
useDialog,
|
|
|
useMessage
|
|
|
} from 'naive-ui'
|
|
|
-import { defineComponent, onMounted, onUnmounted, PropType, reactive, ref } from 'vue'
|
|
|
-import { musicSheetCategoriesQueryTree, musicSheetDetail, musicSheetSave } from '../../api'
|
|
|
+import {defineComponent, onMounted, PropType, reactive, ref} from 'vue'
|
|
|
+import {musicSheetCategoriesQueryTree, musicSheetDetail, musicSheetSave} from '../../api'
|
|
|
import UploadFile from '@/components/upload-file'
|
|
|
import styles from './index.module.less'
|
|
|
import deepClone from '@/utils/deep.clone'
|
|
|
import axios from 'axios'
|
|
|
-import { appKey, clientType, musicSheetSourceType, musicSheetType } from '@/utils/constant'
|
|
|
-import { getMapValueByKey, getSelectDataFromObj } from '@/utils/objectUtil'
|
|
|
-import { musicalInstrumentPage } from '@views/system-manage/subject-manage/api'
|
|
|
-import { subjectPage } from '@views/system-manage/api'
|
|
|
+import {appKey, clientType, musicSheetSourceType, musicSheetType} from '@/utils/constant'
|
|
|
+import {getMapValueByKey, getSelectDataFromObj} from '@/utils/objectUtil'
|
|
|
+import {musicalInstrumentPage} from '@views/system-manage/subject-manage/api'
|
|
|
+import {subjectPage} from '@views/system-manage/api'
|
|
|
import MusicSheetOwnerDialog from '@views/music-library/music-sheet/modal/musicSheetOwnerDialog'
|
|
|
-import { sysApplicationPage } from '@views/menu-manage/api'
|
|
|
-import { filterPointCategory } from '@views/teaching-manage/unit-test'
|
|
|
-import { api_uploadFile } from '@/plugins/uploadFile'
|
|
|
+import {sysApplicationPage} from '@views/menu-manage/api'
|
|
|
+import {filterPointCategory} from '@views/teaching-manage/unit-test'
|
|
|
import MusicCreateImg from './music-create-img'
|
|
|
|
|
|
/**
|
|
@@ -664,11 +663,6 @@ export default defineComponent({
|
|
|
const detail = props.data
|
|
|
try {
|
|
|
const { data } = await musicSheetDetail({ id: detail.id })
|
|
|
- forms.audioType = data.audioType
|
|
|
- forms.musicSheetAccompanimentList = data.musicSheetAccompanimentList
|
|
|
- data.musicSheetAccompanimentList?.forEach((next: any) => {
|
|
|
- state.musicSheetAccompanimentUrlList.push(next.audioFileUrl)
|
|
|
- })
|
|
|
forms.playMode = data.playMode
|
|
|
forms.xmlFileUrl = data.xmlFileUrl
|
|
|
forms.midiUrl = data.midiUrl
|
|
@@ -684,13 +678,10 @@ export default defineComponent({
|
|
|
forms.musicCover = data.musicCover
|
|
|
forms.remark = data.remark
|
|
|
forms.status = data.status
|
|
|
- forms.musicCategoryId = data.musicCategoryId
|
|
|
- forms.evaluationStandard = data.evaluationStandard
|
|
|
-
|
|
|
forms.musicSheetType = data.musicSheetType || 'SINGLE'
|
|
|
- forms.evaluationStandard = data.evaluationStandard
|
|
|
- forms.musicalInstrumentIdList = data.musicalInstrumentIds.split(',') || []
|
|
|
-
|
|
|
+ forms.sourceType = data.sourceType
|
|
|
+ forms.appAuditFlag = data.appAuditFlag ? 1 : 0
|
|
|
+ forms.midiFileUrl = data.midiFileUrl
|
|
|
forms.subjectIds = []
|
|
|
if (data.subjectIds) {
|
|
|
const subjectIds = data.subjectIds.split(',') || []
|
|
@@ -700,10 +691,15 @@ export default defineComponent({
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
- forms.sourceType = data.sourceType
|
|
|
- forms.musicSheetExtend = data.musicSheetExtend
|
|
|
-
|
|
|
-
|
|
|
+ forms.musicalInstrumentIdList = data.musicalInstrumentIds.split(',') || []
|
|
|
+ forms.musicCategoryId = data.musicCategoryId
|
|
|
+ data.musicSheetAccompanimentList?.forEach((next: any) => {
|
|
|
+ state.musicSheetAccompanimentUrlList.push(next.audioFileUrl)
|
|
|
+ })
|
|
|
+ forms.musicSheetAccompanimentList = data.musicSheetAccompanimentList
|
|
|
+ forms.audioType = data.audioType
|
|
|
+ forms.isPlayBeat = data.isPlayBeat
|
|
|
+ forms.isUseSystemBeat = data.isUseSystemBeat
|
|
|
// 获取渐变 和 是否多声部
|
|
|
try {
|
|
|
const extConfigJson = data.extConfigJson ? JSON.parse(data.extConfigJson) : {}
|
|
@@ -711,6 +707,9 @@ export default defineComponent({
|
|
|
forms.repeatedBeats = !!extConfigJson.repeatedBeats
|
|
|
|
|
|
} catch (error) {}
|
|
|
+ forms.evaluationStandard = data.evaluationStandard
|
|
|
+ forms.musicSheetExtend = data.musicSheetExtend
|
|
|
+
|
|
|
setOwnerName()
|
|
|
axios.get(data.xmlFileUrl).then((res: any) => {
|
|
|
if (res?.data) {
|
|
@@ -1316,7 +1315,7 @@ export default defineComponent({
|
|
|
{forms.isPlayBeat && (
|
|
|
<NFormItemGi
|
|
|
label="播放方式"
|
|
|
- path="audioType"
|
|
|
+ path="isUseSystemBeat"
|
|
|
rule={[
|
|
|
{
|
|
|
required: true,
|