feat: support music quality options #33

master
qier222 4 years ago
parent c042faa001
commit d5ef383999

@ -1,12 +1,18 @@
import request from "@/utils/request";
import { mapTrackPlayableStatus } from "@/utils/common";
import store from "@/store";
export function getMP3(id) {
let br =
store.state.settings?.musicQuality !== undefined
? store.state.settings.musicQuality
: 128000;
return request({
url: "/song/url",
method: "get",
params: {
id,
br,
},
});
}

@ -103,4 +103,7 @@ export default {
changeLang(state, lang) {
state.settings.lang = lang;
},
changeMusicQuality(state, value) {
state.settings.musicQuality = value;
},
};

Loading…
Cancel
Save