mirror of
https://github.com/jiangrui1994/CloudSaver.git
synced 2026-01-12 08:08:46 +08:00
feat:增加跳转按钮
This commit is contained in:
@@ -56,6 +56,7 @@
|
||||
:is="userStore.displayStyle === 'table' ? ResourceTable : ResourceCard"
|
||||
v-if="resourceStore.resources.length > 0"
|
||||
@load-more="handleLoadMore"
|
||||
@jump="handleJump"
|
||||
@search-moviefor-tag="searchMovieforTag"
|
||||
@save="handleSave"
|
||||
/>
|
||||
@@ -230,6 +231,10 @@ const handleLoadMore = (channelId: string) => {
|
||||
resourceStore.searchResources("", true, channelId);
|
||||
};
|
||||
|
||||
const handleJump = (resource: ResourceItem) => {
|
||||
window.open(resource.cloudLinks[0], "_blank");
|
||||
};
|
||||
|
||||
const searchMovieforTag = (tag: string) => {
|
||||
router.push({ path: "/resource", query: { keyword: tag } });
|
||||
};
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
<ResourceCard
|
||||
:current-channel-id="currentTab"
|
||||
@save="handleSave"
|
||||
@jump="handleJump"
|
||||
@search-moviefor-tag="searchMovieforTag"
|
||||
/>
|
||||
</van-tab>
|
||||
@@ -192,6 +193,10 @@ const handleSave = async (resource: ResourceItem) => {
|
||||
}
|
||||
};
|
||||
|
||||
const handleJump = (resource: ResourceItem) => {
|
||||
window.open(resource.cloudLinks[0], "_blank");
|
||||
};
|
||||
|
||||
const handleFolderSelect = (folders: Folder[] | null) => {
|
||||
if (!currentResource.value) return;
|
||||
currentFolderPath.value = folders;
|
||||
|
||||
Reference in New Issue
Block a user