fix routers

This commit is contained in:
Qiuxia Fan 2022-03-28 10:31:26 +08:00
parent 0e5e643169
commit ad15f8c074
6 changed files with 6 additions and 7 deletions

View File

@ -68,7 +68,7 @@ export const routesDashboard: Array<RouteRecordRaw> = [
},
},
{
path: "/dashboard/:layerId/:entity/:serviceId/:destServiceId/:name",
path: "/dashboard/related/:layerId/:entity/:serviceId/:destServiceId/:name",
component: () => import("@/views/dashboard/Edit.vue"),
name: "ViewServiceRelation",
meta: {

View File

@ -117,8 +117,8 @@ const selectorStore = useSelectorStore();
const dashboardStore = useDashboardStore();
const chartLoading = ref<boolean>(false);
const endpoints = ref<Endpoint[]>([]);
const pageSize = 5;
const total = 10;
const pageSize = 15;
const total = 15;
const searchText = ref<string>("");
queryEndpoints(total);

View File

@ -143,7 +143,7 @@ const dashboardStore = useDashboardStore();
const chartLoading = ref<boolean>(false);
const instances = ref<Instance[]>([]); // current instances
const searchInstances = ref<Instance[]>([]); // all instances
const pageSize = 5;
const pageSize = 15;
const searchText = ref<string>("");
queryInstance();

View File

@ -128,7 +128,7 @@ const props = defineProps({
const selectorStore = useSelectorStore();
const dashboardStore = useDashboardStore();
const chartLoading = ref<boolean>(false);
const pageSize = 5;
const pageSize = 15;
const services = ref<Service[]>([]);
const searchText = ref<string>("");
const groups = ref<any>({});

View File

@ -98,7 +98,6 @@ limitations under the License. -->
</div>
</div>
</template>
<script lang="ts" setup>
import { reactive, ref } from "vue";
import { useRoute } from "vue-router";

View File

@ -255,7 +255,7 @@ function handleLinkClick(event: any, d: Call) {
entity: `${e}Relation`,
});
dashboardStore.setEntity(p.entity);
const path = `/dashboard/${p.layer}/${e}Relation/${d.source.id}/${d.target.id}/${p.name}`;
const path = `/dashboard/related/${p.layer}/${e}Relation/${d.source.id}/${d.target.id}/${p.name}`;
const routeUrl = router.resolve({ path });
window.open(routeUrl.href, "_blank");
dashboardStore.setEntity(origin);