@@ -55,6 +58,7 @@ const {} = toRefs(data);
width: var(--commodity-width,100%);
> img{
width: 100%;
+ cursor: pointer;
height: var(--commodity-height,auto);
margin-bottom: var(--commodity-marginBottom,1rem);
}
@@ -79,5 +83,8 @@ const {} = toRefs(data);
}
}
}
+ .btn{
+ cursor: pointer;
+ }
}
\ No newline at end of file
diff --git a/src/router/index.ts b/src/router/index.ts
index be8cbea..212aab6 100644
--- a/src/router/index.ts
+++ b/src/router/index.ts
@@ -27,6 +27,12 @@ const router = createRouter({
path: '/digitalItem',
name: 'digitalItem',
component: () => import('../views/digitalItem/index.vue'),
+ meta: { cache: true }
+ },
+ {
+ path: '/digitalItem/:id',
+ name: 'digitalItemDetail',
+ component: () => import('../views/digitalDetail/index.vue'),
},
{
path: '/settings',
diff --git a/src/views/brand/index.vue b/src/views/brand/index.vue
index 9e2999d..b96b418 100644
--- a/src/views/brand/index.vue
+++ b/src/views/brand/index.vue
@@ -2,13 +2,18 @@
import { ref, onMounted, onUnmounted, reactive, toRefs } from "vue";
import CommodityList from "./commodity-list.vue";
import MerchantInfo from "./merchant-info.vue";
+import { useRouter } from "vue-router";
//const props = defineProps({
//})
//const emit = defineEmits([
//])
+const router = useRouter()
let data = reactive({
})
const addShopping = (item) => {}
+const openDetail = (item) => {
+ router.push({name: 'digitalDetail', params: {id: item.id}})
+}
onMounted(()=>{
})
onUnmounted(()=>{
@@ -26,7 +31,7 @@ const {} = toRefs(data);
-
+
diff --git a/src/views/digitalDetail/index.vue b/src/views/digitalDetail/index.vue
new file mode 100644
index 0000000..d1776aa
--- /dev/null
+++ b/src/views/digitalDetail/index.vue
@@ -0,0 +1,319 @@
+
+
+
\ No newline at end of file
diff --git a/src/views/digitalItem/commodity-list.vue b/src/views/digitalItem/commodity-list.vue
index 9c99b70..199ec6a 100644
--- a/src/views/digitalItem/commodity-list.vue
+++ b/src/views/digitalItem/commodity-list.vue
@@ -4,7 +4,8 @@ import img from "@/assets/images/collectionStory/Rectangle.png";
//const props = defineProps({
//})
const emit = defineEmits([
- 'addShopping'
+ 'addShopping',
+ 'openDetail'
])
let data = reactive({
})
@@ -47,6 +48,9 @@ const type = ref('All')
const addShopping = (item) => {
emit('addShopping', item)
}
+const openDetail = (item) => {
+ emit('openDetail', item)
+}
onMounted(()=>{
})
onUnmounted(()=>{
@@ -58,7 +62,7 @@ const {} = toRefs(data);
diff --git a/src/views/digitalItem/index.vue b/src/views/digitalItem/index.vue
index dcfb1cd..897cbc5 100644
--- a/src/views/digitalItem/index.vue
+++ b/src/views/digitalItem/index.vue
@@ -1,14 +1,31 @@