Commit 1473ed1f authored by Ahmed Awan's avatar Ahmed Awan
Browse files

add username filter to published visualizations grid

parent f62c8ff4
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -18,10 +18,12 @@ library.add(faPlus);

interface Props {
    activeList?: "my" | "shared" | "published";
    username?: string;
}

withDefaults(defineProps<Props>(), {
const props = withDefaults(defineProps<Props>(), {
    activeList: "my",
    username: undefined,
});
</script>

@@ -59,6 +61,6 @@ withDefaults(defineProps<Props>(), {
        </BNav>
        <GridList v-if="activeList === 'my'" :grid-config="visualizationsGridConfig" embedded />
        <GridList v-else-if="activeList === 'shared'" :grid-config="visualizationsSharedGridConfig" embedded />
        <GridList v-else :grid-config="visualizationsPublishedGridConfig" embedded />
        <GridList v-else :grid-config="visualizationsPublishedGridConfig" embedded :username-search="props.username" />
    </div>
</template>
+1 −0
Original line number Diff line number Diff line
@@ -103,6 +103,7 @@ const validFilters: Record<string, ValidFilter<string | boolean | undefined>> =
        handler: contains("tag", "tag", expandNameTag),
        menuItem: true,
    },
    user: { placeholder: "user", type: String, handler: contains("username"), menuItem: true },
};

/**
+3 −2
Original line number Diff line number Diff line
@@ -662,9 +662,10 @@ export function getRouter(Galaxy) {
                    {
                        path: "visualizations/list_published",
                        component: GridVisualization,
                        props: {
                        props: (route) => ({
                            activeList: "published",
                        },
                            username: route.query["f-username"],
                        }),
                    },
                    {
                        path: "visualizations/list_shared",