fix: 删除 4 个已清理 Modal 的残留 import/ref/template(ScheduleList + RequestForm)
This commit is contained in:
@@ -331,13 +331,6 @@
|
||||
<Icon name="music" :size="40" class="text-zinc-500 opacity-20" />
|
||||
</div>
|
||||
<p class="text-zinc-400 font-medium mb-8">需要登录网易云音乐账号才能管理歌单</p>
|
||||
<button
|
||||
class="px-10 py-4 rounded-2xl bg-blue-600 hover:bg-blue-500 text-white font-black transition-all active:scale-95 shadow-xl shadow-blue-900/20"
|
||||
type="button"
|
||||
@click="openLoginFromPlaylist"
|
||||
>
|
||||
立即登录
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div v-else class="space-y-8">
|
||||
@@ -578,15 +571,6 @@
|
||||
@confirm="handleConfirmAction"
|
||||
/>
|
||||
</Teleport>
|
||||
|
||||
<Teleport to="body">
|
||||
<NeteaseLoginModal
|
||||
v-if="showLoginModal"
|
||||
:show="showLoginModal"
|
||||
@close="showLoginModal = false"
|
||||
@login-success="handleLoginSuccess"
|
||||
/>
|
||||
</Teleport>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
@@ -600,7 +584,6 @@ import ConfirmDialog from '~/components/UI/ConfirmDialog.vue'
|
||||
import CustomSelect from '~/components/UI/Common/CustomSelect.vue'
|
||||
import { convertToHttps } from '~/utils/url'
|
||||
import { getMusicUrl as resolveMusicUrl } from '~/utils/musicUrl'
|
||||
import NeteaseLoginModal from './NeteaseLoginModal.vue'
|
||||
const props = defineProps({
|
||||
schedules: {
|
||||
type: Array,
|
||||
@@ -646,7 +629,6 @@ const playlistActionLoading = ref(false)
|
||||
const selectedSongIds = ref([])
|
||||
const newPlaylistName = ref('')
|
||||
const newPlaylistPrivacy = ref(false)
|
||||
const showLoginModal = ref(false)
|
||||
|
||||
const confirmDialog = ref({
|
||||
show: false,
|
||||
@@ -1094,10 +1076,8 @@ const handleLoginSuccess = (data) => {
|
||||
if (typeof window !== 'undefined') {
|
||||
localStorage.setItem('netease_cookie', data.cookie)
|
||||
localStorage.setItem('netease_user', JSON.stringify(data.user))
|
||||
// 更新全局网易云登录状态,通知其他组件(如AudioPlayer)
|
||||
updateGlobalNeteaseStatus()
|
||||
}
|
||||
showLoginModal.value = false
|
||||
if (showPlaylistModal.value) {
|
||||
reloadPlaylists()
|
||||
}
|
||||
@@ -1105,7 +1085,6 @@ const handleLoginSuccess = (data) => {
|
||||
|
||||
const handleAddToPlaylistClick = () => {
|
||||
if (!isNeteaseLoggedIn.value) {
|
||||
showLoginModal.value = true
|
||||
return
|
||||
}
|
||||
if (!neteaseSongs.value.length) {
|
||||
@@ -1123,10 +1102,6 @@ const closePlaylistModal = () => {
|
||||
showPlaylistModal.value = false
|
||||
}
|
||||
|
||||
const openLoginFromPlaylist = () => {
|
||||
showLoginModal.value = true
|
||||
}
|
||||
|
||||
const reloadPlaylists = async () => {
|
||||
if (!isNeteaseLoggedIn.value || !neteaseCookie.value || !neteaseUser.value) return
|
||||
const uid = neteaseUser.value.userId || neteaseUser.value.id
|
||||
|
||||
Reference in New Issue
Block a user