From 9ffd40a2f4f7768f29ea0c3a649052f13b0f8410 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8E=E8=82=96=E7=A3=8A?= <18851179580@163.com> Date: Thu, 22 Aug 2024 15:05:39 +0800 Subject: [PATCH 1/8] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=95=86=E5=93=81?= =?UTF-8?q?=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../custom-module/model-image/index.vue | 13 ++- .../model-image/model-image-style.vue | 27 ++--- .../common/custom-module/model-text/index.vue | 22 +++- .../model-text/model-text-style.vue | 27 ++--- .../common/product-show-config/index.vue | 2 +- .../common/url-value/url-value-dialog.vue | 2 + .../model-custom/components/index.vue | 9 +- src/components/model-custom/index.vue | 6 +- .../model-custom/model-custom-content.vue | 102 ++++++++++++++---- src/components/model-shop-list/index.vue | 11 +- .../model-shop-tabs-styles.vue | 7 +- src/layout/components/main/default/custom.ts | 2 + .../components/main/default/shop-tabs.ts | 6 +- 13 files changed, 161 insertions(+), 75 deletions(-) diff --git a/src/components/common/custom-module/model-image/index.vue b/src/components/common/custom-module/model-image/index.vue index c83a12f6..6b8c8ace 100644 --- a/src/components/common/custom-module/model-image/index.vue +++ b/src/components/common/custom-module/model-image/index.vue @@ -14,6 +14,12 @@ const props = defineProps({ }, required: true }, + sourceList: { + type: Object, + default: () => { + return {}; + } + }, isPercentage: { type: Boolean, default: false @@ -21,13 +27,14 @@ const props = defineProps({ }); // 用于页面判断显示 const form = reactive(props.value); - const img_src = computed(() => { if (!isEmpty(form.img_src[0])) { return form.img_src[0]; } else { - return { - url: form.data_source_list.url + if (!isEmpty(props.sourceList)) { + return props.sourceList[form.data_source_id]; + } else { + return ''; } } }); diff --git a/src/components/common/custom-module/model-image/model-image-style.vue b/src/components/common/custom-module/model-image/model-image-style.vue index d6dfbd33..f8529e62 100644 --- a/src/components/common/custom-module/model-image/model-image-style.vue +++ b/src/components/common/custom-module/model-image/model-image-style.vue @@ -4,19 +4,12 @@
图片设置
-
- -
- - - - - - -
-
+ +
+ + + + @@ -97,6 +90,14 @@ const border_radius_change = (radius: any) => { form.value.border_radius = Object.assign(form.value.border_radius, pick(radius, ['radius', 'radius_top_left', 'radius_top_right', 'radius_bottom_left', 'radius_bottom_right'])); }; +const img_src_change = (key: string) => { + if (key == '2') { + form.value.img_src = []; + } else { + form.value.data_source_id = ''; + } +} + watch( diy_data, (val) => { diff --git a/src/components/common/custom-module/model-text/index.vue b/src/components/common/custom-module/model-text/index.vue index bfac84d8..bae1d789 100644 --- a/src/components/common/custom-module/model-text/index.vue +++ b/src/components/common/custom-module/model-text/index.vue @@ -2,16 +2,17 @@
diff --git a/src/components/model-shop-list/index.vue b/src/components/model-shop-list/index.vue index 8465cb5a..a8c5af4a 100644 --- a/src/components/model-shop-list/index.vue +++ b/src/components/model-shop-list/index.vue @@ -15,11 +15,8 @@ -
@@ -51,8 +48,8 @@
-
已售{{ item.sales_count }}件
-
评分0
+
已售{{ item.sales_count }}件
+
@@ -399,6 +396,6 @@ const style_container = computed(() => { } .flex-img5 { width: 100%; - height: 10.4rem; + min-height: 10.4rem; } diff --git a/src/components/model-shop-tabs/model-shop-tabs-styles.vue b/src/components/model-shop-tabs/model-shop-tabs-styles.vue index 85cff34e..47b7f11f 100644 --- a/src/components/model-shop-tabs/model-shop-tabs-styles.vue +++ b/src/components/model-shop-tabs/model-shop-tabs-styles.vue @@ -34,11 +34,8 @@ - - - - - + + diff --git a/src/layout/components/main/default/custom.ts b/src/layout/components/main/default/custom.ts index f548e984..f60a9dce 100644 --- a/src/layout/components/main/default/custom.ts +++ b/src/layout/components/main/default/custom.ts @@ -5,6 +5,7 @@ interface defaultSearch { content: { height: number; data_source: string; + source_list: string[]; custom_list: string[]; }; style: { @@ -14,6 +15,7 @@ interface defaultSearch { const defaultSearch: defaultSearch = { content: { height: 390, + source_list: [], data_source:'', custom_list: [] }, diff --git a/src/layout/components/main/default/shop-tabs.ts b/src/layout/components/main/default/shop-tabs.ts index e11561db..c14225ee 100644 --- a/src/layout/components/main/default/shop-tabs.ts +++ b/src/layout/components/main/default/shop-tabs.ts @@ -37,8 +37,7 @@ interface DefaultProductList { shop_padding: paddingStyle; shop_img_radius: radiusStyle; shop_radius: radiusStyle; - content_outer_down_spacing: number; - content_outer_about_spacing: number; + content_outer_spacing: number; content_outer_width: number; content_spacing: number; shop_title_typeface: string; @@ -106,8 +105,7 @@ const defaultProductList: DefaultProductList = { radius_bottom_left: 0, radius_bottom_right: 0, }, - content_outer_down_spacing: 10, // 内容间的上下间距 - content_outer_about_spacing: 10, // 内容间的左右间距 + content_outer_spacing: 10, content_spacing: 10, content_outer_width: 104, shop_title_typeface: 'normal', From 2ed25dcad5e7ac8f57d867d30a7ea5d60ef2fba4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8E=E8=82=96=E7=A3=8A?= <18851179580@163.com> Date: Thu, 22 Aug 2024 15:26:13 +0800 Subject: [PATCH 2/8] =?UTF-8?q?=E5=95=86=E5=93=81=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E7=9A=84=E6=98=BE=E7=A4=BA=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/model-shop-list/index.vue | 40 +++++++++++++----------- 1 file changed, 21 insertions(+), 19 deletions(-) diff --git a/src/components/model-shop-list/index.vue b/src/components/model-shop-list/index.vue index a8c5af4a..fa3f4454 100644 --- a/src/components/model-shop-list/index.vue +++ b/src/components/model-shop-list/index.vue @@ -23,9 +23,7 @@
{{ item.title }}
-
{{ '满减活动' }}
-
{{ '包邮' }}
-
{{ '领劵' }}
+
{{ icon_data.name }}
@@ -37,7 +35,7 @@
{{ item.show_original_price_symbol }}{{ item.min_original_price }} @@ -67,6 +67,10 @@ const edit = (index: number) => { edit_index.value = index; } } + +const double_click = (index: number) => { + edit_index.value = index; +}