Browse Source

修复bug

dev
lenghui 7 months ago
parent
commit
e248239111
  1. 11
      vueHomilyLink/src/views/ChannelView.vue
  2. 3
      vueHomilyLink/vite.config.js

11
vueHomilyLink/src/views/ChannelView.vue

@ -48,9 +48,10 @@ function toLink(channelId) {
function changeTab(channelId, flagType) {
currentTab.value = flagType;
loadShows(channelId,flagType);
function changeTab(channelId, type) {
currentTab.value = type;
flagType.value = type;
loadShows(channelId,type);
}
// 1
@ -72,7 +73,7 @@ function submit(channelId) {
ChannelApi.subscribe(channelId,90000000).then((result)=>{
if(result.code ==200){
ElMessage.success('订阅成功!');
loadShows(channelId,null);
loadShows(channelId,flagType.value);
}else{
ElMessage.error(result.messsage);
}
@ -87,7 +88,7 @@ function unsubmit(channelId){
if(result.code ==200){
console.log("取消频道id+++++++",channelId);
ElMessage.success('取消订阅成功!');
loadShows(channelId,null);
loadShows(channelId,flagType.value);
}else{
ElMessage.error(result.messsage);
}

3
vueHomilyLink/vite.config.js

@ -2,13 +2,11 @@ import { fileURLToPath, URL } from 'node:url'
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import vueDevTools from 'vite-plugin-vue-devtools'
// https://vite.dev/config/
export default defineConfig({
plugins: [
vue(),
vueDevTools(),
],
resolve: {
alias: {
@ -20,6 +18,7 @@ export default defineConfig({
'/api': {
target: 'http://192.168.9.19:8080',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/api/, '')
}
}

Loading…
Cancel
Save