Merge branch 'dev-sws' into dev

master
gongfuxiang 2024-10-08 15:11:10 +08:00
commit e9d9949812
30 changed files with 401 additions and 120 deletions

View File

@ -69,6 +69,10 @@
type: Boolean,
default: true,
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -114,6 +118,12 @@
article_carousel_list: [],
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -3,7 +3,7 @@
<view class="article-tabs ou" :style="style_container">
<componentDiyModulesTabsView :propValue="article_tabs" :propIsTop="top_up == '1'" :propTop="propTop" :propStyle="tabs_style + 'padding-bottom:24rpx;'" :propCustomNavHeight="propCustomNavHeight * 2 + 'rpx'" :propTabsBackground="tabs_background" @tabs-click="tabs_click_event"></componentDiyModulesTabsView>
<view class="oh">
<componentDiyArticleList v-if="hackReset" :propValue="article_tabs" :propIsCommonStyle="false"></componentDiyArticleList>
<componentDiyArticleList v-if="hackReset" :propkey="diy_key" :propValue="article_tabs" :propIsCommonStyle="false"></componentDiyArticleList>
</view>
</view>
</template>
@ -40,6 +40,10 @@
type: Boolean,
default: false,
},
propkey: {
type: String,
default: '',
}
},
components: {
componentDiyModulesTabsView,
@ -57,6 +61,7 @@
tabs_top: 0,
tabs_background: 'background:transparent',
custom_nav_height: 33,
diy_key: '',
};
},
watch: {
@ -79,6 +84,13 @@
this.tabs_background = 'background:transparent';
}
},
propkey(val) {
this.setData({
diy_key: val
})
//
this.init();
}
},
created() {
this.init();

View File

@ -14,6 +14,10 @@
return {};
},
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -21,6 +25,12 @@
style: '',
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -13,6 +13,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -20,6 +24,12 @@
style: '',
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -77,6 +77,10 @@
type: Boolean,
default: true,
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -107,16 +111,22 @@
slides_per_group: 1,
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.init();
},
methods: {
isEmpty,
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
const { windowWidth } = uni.getSystemInfoSync();
// 90%16
const block = (windowWidth * 0.9) / 16;

View File

@ -167,6 +167,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -190,6 +194,12 @@
home_page_url: tabbar_pages[0],
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},
@ -546,9 +556,6 @@
display: flex;
align-items: center;
&.long-name {
}
&.short-name {
height: 132rpx;
justify-content: center;

View File

@ -3,16 +3,16 @@
<view class="wh-auto ht-auto pr">
<view v-for="item in form.custom_list" :key="item.id" class="main-content" :style="{ left: get_percentage_count(item.location.x, div_width), top: get_percentage_count(item.location.y, div_height), width: get_percentage_count(item.com_data.com_width, div_width), height: get_percentage_count(item.com_data.com_height, div_height) }">
<template v-if="item.key == 'text'">
<model-text :key="item.com_data" :propValue="item.com_data" :propSourceList="form.data_source_content" @url_open="url_open"></model-text>
<model-text :key="item.com_data" :propValue="item.com_data" :propSourceList="form.data_source_content" @url_event="url_event"></model-text>
</template>
<template v-else-if="item.key == 'img'">
<model-image :key="item.com_data" :propValue="item.com_data" :propSourceList="form.data_source_content" @url_open="url_open"></model-image>
<model-image :key="item.com_data" :propValue="item.com_data" :propSourceList="form.data_source_content" @url_event="url_event"></model-image>
</template>
<template v-else-if="item.key == 'auxiliary-line'">
<model-lines :key="item.com_data" :propValue="item.com_data" :propSourceList="form.data_source_content"></model-lines>
</template>
<template v-else-if="item.key == 'icon'">
<model-icon :key="item.com_data" :propValue="item.com_data" :propSourceList="form.data_source_content" @url_open="url_open"></model-icon>
<model-icon :key="item.com_data" :propValue="item.com_data" :propSourceList="form.data_source_content" @url_event="url_event"></model-icon>
</template>
</view>
</view>
@ -43,6 +43,10 @@
return {};
},
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -61,24 +65,30 @@
};
},
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.init();
},
methods: {
percentage_count,
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.setData({
style_container: common_styles_computer(this.new_style.common_style) + 'box-sizing: border-box;', //
div_width: sys_width,
div_height: this.form.height * this.scale,
div_height: this.form.height,
});
},
url_open(link) {
app.globalData.url_event(link);
url_event(e) {
app.globalData.url_event(e);
},
},
};

View File

@ -81,6 +81,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -112,16 +116,22 @@
};
},
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.init();
},
methods: {
isEmpty,
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
const density = 4;
this.setData({
outer_spacing: this.new_style.image_spacing * 2 + 'rpx',

View File

@ -13,30 +13,30 @@
<template v-if="diy_data.length > 0">
<view v-for="(item, index) in diy_data" :key="index" :style="'margin-top:' + (['float-window'].includes(item.key) ? '0rpx' : -(item.com_data.style.common_style.floating_up * 2 || 0) + 'rpx;z-index:1;')">
<!-- 基础组件 -->
<componentDiySearch v-if="item.key == 'search'" :propValue="item.com_data"></componentDiySearch>
<componentDiyCarousel v-else-if="item.key == 'carousel'" :propValue="item.com_data"></componentDiyCarousel>
<componentDiyNavGroup v-else-if="item.key == 'nav-group'" :propValue="item.com_data"></componentDiyNavGroup>
<componentDiyUserInfo v-else-if="item.key == 'user-info'" :propValue="item.com_data"></componentDiyUserInfo>
<componentDiyNotice v-else-if="item.key == 'notice'" :propValue="item.com_data"></componentDiyNotice>
<componentDiyVideo v-else-if="item.key == 'video'" :propValue="item.com_data"></componentDiyVideo>
<componentDiyArticleList v-else-if="item.key == 'article-list'" :propValue="item.com_data"></componentDiyArticleList>
<componentDiyArticleTabs v-else-if="item.key == 'article-tabs'" :propValue="item.com_data" :propTop="(!is_immersion_model ? temp_sticky_top : 0) + tabs_height" :propScrollTop="scroll_top" :propCustomNavHeight="!is_immersion_model && is_header_top ? 33 : 0"></componentDiyArticleTabs>
<componentDiyGoodsTabs v-else-if="item.key == 'goods-tabs'" :propValue="item.com_data" :propTop="(!is_immersion_model ? temp_sticky_top : 0) + tabs_height" :propScrollTop="scroll_top" :propCustomNavHeight="!is_immersion_model && is_header_top ? 33 : 0"></componentDiyGoodsTabs>
<componentDiyGoodsList v-else-if="item.key == 'goods-list'" :propValue="item.com_data"></componentDiyGoodsList>
<componentDiyDataMagic v-else-if="item.key == 'data-magic'" :propValue="item.com_data"></componentDiyDataMagic>
<componentDiyCustom v-else-if="item.key == 'custom'" :propValue="item.com_data"></componentDiyCustom>
<componentDiyImgMagic v-else-if="item.key == 'img-magic'" :propValue="item.com_data"></componentDiyImgMagic>
<componentDiyHotZone v-else-if="item.key == 'hot-zone'" :propValue="item.com_data"></componentDiyHotZone>
<componentDiySeckill v-else-if="item.key == 'seckill'" :propValue="item.com_data"></componentDiySeckill>
<componentDiySearch v-if="item.key == 'search'" :propkey="diy_key" :propValue="item.com_data"></componentDiySearch>
<componentDiyCarousel v-else-if="item.key == 'carousel'" :propkey="diy_key" :propValue="item.com_data"></componentDiyCarousel>
<componentDiyNavGroup v-else-if="item.key == 'nav-group'" :propkey="diy_key" :propValue="item.com_data"></componentDiyNavGroup>
<componentDiyUserInfo v-else-if="item.key == 'user-info'" :propkey="diy_key" :propValue="item.com_data"></componentDiyUserInfo>
<componentDiyNotice v-else-if="item.key == 'notice'" :propkey="diy_key" :propValue="item.com_data"></componentDiyNotice>
<componentDiyVideo v-else-if="item.key == 'video'" :propkey="diy_key" :propValue="item.com_data"></componentDiyVideo>
<componentDiyArticleList v-else-if="item.key == 'article-list'" :propkey="diy_key" :propValue="item.com_data"></componentDiyArticleList>
<componentDiyArticleTabs v-else-if="item.key == 'article-tabs'" :propkey="diy_key" :propValue="item.com_data" :propTop="(!is_immersion_model ? temp_sticky_top : 0) + tabs_height" :propScrollTop="scroll_top" :propCustomNavHeight="!is_immersion_model && is_header_top ? 33 : 0"></componentDiyArticleTabs>
<componentDiyGoodsTabs v-else-if="item.key == 'goods-tabs'" :propkey="diy_key" :propValue="item.com_data" :propTop="(!is_immersion_model ? temp_sticky_top : 0) + tabs_height" :propScrollTop="scroll_top" :propCustomNavHeight="!is_immersion_model && is_header_top ? 33 : 0"></componentDiyGoodsTabs>
<componentDiyGoodsList v-else-if="item.key == 'goods-list'" :propkey="diy_key" :propValue="item.com_data"></componentDiyGoodsList>
<componentDiyDataMagic v-else-if="item.key == 'data-magic'" :propkey="diy_key" :propValue="item.com_data"></componentDiyDataMagic>
<componentDiyCustom v-else-if="item.key == 'custom'" :propkey="diy_key" :propValue="item.com_data"></componentDiyCustom>
<componentDiyImgMagic v-else-if="item.key == 'img-magic'" :propkey="diy_key" :propValue="item.com_data"></componentDiyImgMagic>
<componentDiyHotZone v-else-if="item.key == 'hot-zone'" :propkey="diy_key" :propValue="item.com_data"></componentDiyHotZone>
<componentDiySeckill v-else-if="item.key == 'seckill'" :propkey="diy_key" :propValue="item.com_data"></componentDiySeckill>
<!-- 插件 -->
<componentDiyCoupon v-else-if="item.key == 'coupon'" :propValue="item.com_data"></componentDiyCoupon>
<componentDiyCoupon v-else-if="item.key == 'coupon'" :propkey="diy_key" :propValue="item.com_data"></componentDiyCoupon>
<!-- 工具组件 -->
<componentDiyFloatWindow v-else-if="item.key == 'float-window'" :propValue="item.com_data"></componentDiyFloatWindow>
<componentDiyTitle v-else-if="item.key == 'title'" :propValue="item.com_data"></componentDiyTitle>
<componentDiyAuxiliaryLine v-else-if="item.key == 'row-line'" :propValue="item.com_data"></componentDiyAuxiliaryLine>
<componentDiyRichText v-else-if="item.key == 'rich-text'" :propValue="item.com_data"></componentDiyRichText>
<componentDiyAuxiliaryBlank v-else-if="item.key == 'auxiliary-blank'" :propValue="item.com_data"></componentDiyAuxiliaryBlank>
<componentDiyFloatWindow v-else-if="item.key == 'float-window'" :propkey="diy_key" :propValue="item.com_data"></componentDiyFloatWindow>
<componentDiyTitle v-else-if="item.key == 'title'" :propkey="diy_key" :propValue="item.com_data"></componentDiyTitle>
<componentDiyAuxiliaryLine v-else-if="item.key == 'row-line'" :propkey="diy_key" :propValue="item.com_data"></componentDiyAuxiliaryLine>
<componentDiyRichText v-else-if="item.key == 'rich-text'" :propkey="diy_key" :propValue="item.com_data"></componentDiyRichText>
<componentDiyAuxiliaryBlank v-else-if="item.key == 'auxiliary-blank'" :propkey="diy_key" :propValue="item.com_data"></componentDiyAuxiliaryBlank>
</view>
</template>
@ -116,6 +116,10 @@
type: [String, Number],
default: '',
},
propkey: {
type: String,
default: '',
}
},
components: {
componentDiyHeader,
@ -208,8 +212,18 @@
hack_reset: false,
//
footer_height_value: 0,
diy_key: '',
};
},
watch: {
propkey(val) {
this.setData({
diy_key: val
})
//
this.init();
}
},
created() {
//
this.init_config();

View File

@ -27,6 +27,10 @@
return {};
},
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -38,15 +42,21 @@
color: '',
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.init();
},
methods: {
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
const { float_style, float_style_color, display_location, offset_number_percentage } = this.propValue.style;
const { windowWidth, windowHeight } = uni.getSystemInfoSync();

View File

@ -43,6 +43,10 @@
type: Number,
default: 0,
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -73,6 +77,10 @@
propFooterActiveIndex(value, old_value) {
this.init();
},
propkey(val) {
//
this.init();
}
},
//
created: function () {

View File

@ -187,6 +187,10 @@
type: Boolean,
default: true,
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -225,6 +229,15 @@
return gradient_handle(this.new_style.shop_button_color, '180deg');
},
},
watch: {
propkey(val) {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,

View File

@ -2,7 +2,7 @@
<view class="goods-tabs ou" :style="style_container">
<componentDiyModulesTabsView :propValue="goods_tabs" :propIsTop="top_up == '1'" :propTop="propTop" :propStyle="tabs_style + 'padding-bottom:24rpx;'" :propCustomNavHeight="propCustomNavHeight * 2 + 'rpx'" :propTabsBackground="tabs_background" @tabs-click="tabs_click_event"></componentDiyModulesTabsView>
<view class="oh">
<componentGoodsList v-if="hackReset" :propValue="goods_tabs" :propIsCommonStyle="false"></componentGoodsList>
<componentGoodsList v-if="hackReset" :propkey="diy_key" :propValue="goods_tabs" :propIsCommonStyle="false"></componentGoodsList>
</view>
</view>
</template>
@ -45,6 +45,10 @@
type: Boolean,
default: false,
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -56,6 +60,7 @@
tabs_top: 0,
tabs_background: 'background:transparent',
custom_nav_height: 33,
diy_key: '',
};
},
watch: {
@ -78,6 +83,13 @@
this.tabs_background = 'background:transparent';
}
},
propkey(val) {
//
this.setData({
diy_key: val
})
this.init();
}
},
created() {
this.init();

View File

@ -2,23 +2,25 @@
<view v-if="(propValue || null) !== null" class="header-container">
<view class="wh-auto header-z-3" :style="roll_style + position">
<view :style="top_content_style">
<view class="header-content flex-row align-c">
<view class="model-top flex-1">
<view class="header-content flex-row align-s">
<view class="model-top flex-1 mt-1">
<view class="roll pr z-i">
<view class="model-head pr flex-row align-c" :style="header_style">
<view class="flex-row align-c jc-sb gap-16 wh-auto">
<view v-if="['1', '2', '3'].includes(form.content.theme)" class="flex-1 flex-row align-c jc-c ht-auto gap-16 padding-left-main" :style="text_style + 'justify-content:' + form.content.indicator_location || 'center'">
<template v-if="['2', '3'].includes(form.content.theme)">
<view class="logo-outer-style">
<imageEmpty :propImageSrc="form.content.logo[0]" propImgFit="heightFix" propErrorStyle="width:40rpx;height:40rpx;"></imageEmpty>
</view>
</template>
<view v-if="['1', '2'].includes(form.content.theme)">{{ form.content.title }}</view>
<template v-if="['3', '5'].includes(form.content.theme)">
<view class="flex-1">
<componentDiySearch :propValue="form" :propIsPageSettings="true" :propIsClick="is_click" @search_tap="search_tap"></componentDiySearch>
</view>
</template>
<view class="model-head-content flex-row align-c jc-sb gap-16 wh-auto pr">
<view v-if="['1', '2', '3'].includes(form.content.theme)" class="flex-1">
<view class="flex-row align-c jc-c ht-auto gap-16 padding-left-main" :class="position_class" :style="text_style + 'justify-content:' + form.content.indicator_location || 'center'">
<template v-if="['2', '3'].includes(form.content.theme)">
<view class="logo-outer-style">
<imageEmpty :propImageSrc="form.content.logo[0]" propImgFit="heightFix" propErrorStyle="width:40rpx;height:40rpx;"></imageEmpty>
</view>
</template>
<view v-if="['1', '2'].includes(form.content.theme)">{{ form.content.title }}</view>
<template v-if="['3', '5'].includes(form.content.theme)">
<view class="flex-1">
<componentDiySearch :propValue="form" :propIsPageSettings="true" :propIsClick="is_click" @search_tap="search_tap"></componentDiySearch>
</view>
</template>
</view>
</view>
<view v-else-if="['4', '5'].includes(form.content.theme)" class="flex-1 flex-row align-c h gap-10 padding-left-main">
<view class="flex-row align-c gap-2" @tap="go_map_event">
@ -42,7 +44,7 @@
</view>
</view>
</view>
<hotWordList v-if="is_click" :propValue="form.content.hot_word_list" :prophotWordsColor="form.style.hot_words_color" :propIsPageSettings="true" @search_hot_close="search_hot_close"></hotWordList>
<hotWordList v-if="is_click && form.content.hot_word_list.length > 0" :propValue="form.content.hot_word_list" :prophotWordsColor="form.style.hot_words_color" :propIsPageSettings="true" @search_hot_close="search_hot_close"></hotWordList>
</view>
<block v-if="!is_immersion_model">
<view v-if="!is_positon_realative" class="nav-seat" :style="top_content_style">
@ -81,6 +83,10 @@
type: Number,
default: 0,
},
propkey: {
type: String,
default: '',
}
},
components: {
componentDiySearch,
@ -138,6 +144,11 @@
}
}
},
propkey(val) {
if ((this.propValue || null) !== null) {
this.init();
}
}
},
created() {
if ((this.propValue || null) !== null) {
@ -172,7 +183,8 @@
position: new_style.up_slide_display == '1' ? 'position:fixed;' : 'position:relative;',
is_positon_realative: new_style.up_slide_display == '1' ? false : true,
roll_style: new_roll_style,
text_style: `font-weight:${new_style.header_background_title_typeface}; font-size: ${new_style.header_background_title_size * 2}rpx; color: ${new_style.header_background_title_color};`,
text_style: `font-weight:${new_style.header_background_title_typeface}; font-size: ${new_style.header_background_title_size * 2}rpx; color: ${new_style.header_background_title_color};right:-${custom.width + 10}px;`,
position_class: new_content.indicator_location == 'center' ? `indicator-center` : '',
header_style: menuButtonInfo,
header_background_type: header_background_type,
is_immersion_model: header_background_type !== 'color_image' && immersive_style == '1',
@ -206,6 +218,9 @@
is_click: false,
});
},
user_back_choice_location(e) {
console.log('选择位置', e);
},
url_event(e) {
app.globalData.url_event(e);
},
@ -236,23 +251,36 @@
}
}
.model-head {
height: 66rpx;
overflow: hidden;
.model-head-content {
height: 66rpx;
top: -6rpx;
}
}
.model-head-icon {
position: absolute;
right: 0;
bottom: 0;
height: 64rpx;
height: 66rpx;
.function-icon {
height: 64rpx;
height: 66rpx;
}
}
.logo-outer-style {
height: 64rpx;
height: 66rpx;
.logo-style {
height: 64rpx;
width: 64rpx;
height: 66rpx;
width: 66rpx;
}
}
}
.indicator-center {
position: absolute;
left: 0;
right: 0;
text-align: center;
top: 0;
padding-left: 0;
}
</style>

View File

@ -17,6 +17,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -35,6 +39,12 @@
h_scale2: 1,
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -38,6 +38,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -53,10 +57,14 @@
container_size: '',
};
},
created() {
this.$nextTick(() => {
watch: {
propkey(val) {
//
this.init();
});
}
},
created() {
this.init();
},
methods: {
init() {

View File

@ -1,10 +1,10 @@
<template>
<view class="img-outer pr oh flex-row" :style="com_style" @tap="url_open(form.icon_link)">
<iconfont :name="'icon-' + form.icon_class" :color="form.icon_color" :size="form.icon_size"></iconfont>
<view class="img-outer pr oh flex-row align-c wh-auto ht-auto" :style="com_style" :data-value="form.icon_link.page" @tap="url_event">
<iconfont :name="'icon-' + form.icon_class" :color="form.icon_color" :size="form.icon_size * 2 + 'rpx'"></iconfont>
</view>
</template>
<script>
import { radius_computer, padding_computer, isEmpty } from '@/common/js/common/common.js';
import { radius_computer, padding_computer, gradient_handle } from '@/common/js/common/common.js';
export default {
props: {
@ -16,7 +16,7 @@
required: true,
},
propSourceList: {
type: Object,
type: [ Object, Array ],
default: () => {
return {};
},
@ -41,7 +41,7 @@
});
},
get_com_style() {
let style = `background-color: ${ this.form.com_bg }; ${ radius_computer(this.form.bg_radius) };transform: rotate(${this.form.icon_rotate}deg);${ padding_computer(this.form.icon_padding) };`;
let style = `${ gradient_handle(this.form.color_list, this.form.direction) } ${ radius_computer(this.form.bg_radius) };transform: rotate(${this.form.icon_rotate}deg);${ padding_computer(this.form.icon_padding) };`;
if (this.form.border_show == '1') {
style += `border: ${this.form.border_size * 2 }rpx ${this.form.border_style} ${this.form.border_color};box-sizing: border-box;`;
}
@ -54,8 +54,8 @@
}
return style;
},
url_open(link) {
this.$emit('url_open', link)
url_event(e) {
this.$emit('url_event', e)
},
},
};

View File

@ -1,5 +1,5 @@
<template>
<view class="img-outer pr wh-auto ht-auto" :style="border_style" @tap="url_open(form.link)">
<view class="img-outer pr wh-auto ht-auto" :style="border_style" :data-value="form.link.page" @tap="url_event">
<imageEmpty :propImageSrc="img" :propStyle="image_style" propErrorStyle="width: 60rpx;height: 60rpx;"></imageEmpty>
</view>
</template>
@ -19,7 +19,7 @@
required: true,
},
propSourceList: {
type: Object,
type: [ Object, Array ],
default: () => {
return {};
},
@ -68,8 +68,8 @@
}
return style;
},
url_open(link) {
this.$emit('url_open', link);
url_event(e) {
this.$emit('url_event', e);
},
},
};

View File

@ -1,5 +1,5 @@
<template>
<view class="img-outer re oh" :style="com_style" @tap="url_open(form.text_link)">
<view class="img-outer re oh" :style="com_style" :data-value="form.text_link.page" @tap="url_event">
<view :style="text_style" class="break">
<template v-if="form.is_rich_text == '1'">
<view class="rich-text-content" :innerHTML="text_title"></view>
@ -11,7 +11,7 @@
</view>
</template>
<script>
import { radius_computer, padding_computer, isEmpty } from '@/common/js/common/common.js';
import { radius_computer, padding_computer, isEmpty, gradient_handle } from '@/common/js/common/common.js';
export default {
props: {
@ -23,7 +23,7 @@
required: true,
},
propSourceList: {
type: Object,
type: [ Object, Array ],
default: () => {
return {};
},
@ -70,7 +70,7 @@
return style;
},
get_com_style() {
let style = `background-color: ${this.form.com_bg}; ${radius_computer(this.form.bg_radius)}`;
let style = `${ gradient_handle(this.form.color_list, this.form.direction) } ${radius_computer(this.form.bg_radius)}`;
if (this.form.border_show == '1') {
style += `border: ${this.form.border_size * 2}rpx ${this.form.border_style} ${this.form.border_color};`;
}
@ -80,8 +80,8 @@
}
return style;
},
url_open(link) {
this.$emit('url_open', link)
url_event(e) {
this.$emit('url_event', e)
},
},
};

View File

@ -43,6 +43,10 @@
return {};
},
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -58,17 +62,21 @@
nav_content_list: [],
};
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
watch: {
propkey(val) {
//
this.init();
}
},
mounted() {
this.init();
},
methods: {
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.setData({
style_container: common_styles_computer(this.new_style.common_style), //
img_style: radius_computer(this.new_style), //

View File

@ -63,6 +63,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -94,6 +98,12 @@
notice_list: [],
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -13,6 +13,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -20,6 +24,12 @@
content: '',
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -54,7 +54,7 @@
</view>
</template>
</view>
<hotWordList v-if="is_click && !propIsPageSettings" :propValue="form.hot_word_list" :prophotWordsColor="new_style.hot_words_color" @search_hot_close="search_hot_close"></hotWordList>
<hotWordList v-if="is_click && !propIsPageSettings && form.content.hot_word_list.length > 0" :propValue="form.hot_word_list" :prophotWordsColor="new_style.hot_words_color" @search_hot_close="search_hot_close"></hotWordList>
</view>
</template>
@ -80,6 +80,10 @@
propIsClick: {
type: Boolean,
default: false,
},
propkey: {
type: String,
default: '',
}
},
data() {
@ -103,18 +107,22 @@
});
},
immediate: true
},
propkey(val) {
//
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.init();
},
methods: {
isEmpty,
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
const { search_button_radius, common_style } = this.new_style;
this.setData({
style: this.get_style(), //
@ -180,9 +188,11 @@
})
},
search_icon_tap() {
if (!isEmpty(this.form.icon_src)) {
app.globalData.url_open(this.form.icon_src.page);
if (isEmpty(this.form.icon_src)) {
this.search_tap();
return;
}
app.globalData.url_open(this.form.icon_src.page);
},
url_event() {
if (!isEmpty(this.search_content)) {

View File

@ -178,6 +178,10 @@
return {};
},
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -230,11 +234,13 @@
return gradient_handle(this.new_style.shop_button_color, '180deg');
},
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
this.init();
},
beforeDestroy() {
@ -246,6 +252,10 @@
methods: {
isEmpty,
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
const data = this.form.data;
let new_list = [];
if (data && !isEmpty(data.current)) {

View File

@ -35,6 +35,10 @@
type: Boolean,
default: false,
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -64,6 +68,10 @@
propTabsIsTop(value, old_value) {
this.init();
},
propkey(val) {
//
this.init();
}
},
methods: {
init() {

View File

@ -45,6 +45,10 @@
type: String,
default: '',
},
propkey: {
type: String,
default: '',
}
},
components: {
componentDiyModulesTabsView,
@ -82,6 +86,10 @@
this.get_tabs_height();
});
},
propkey(val) {
//
this.init();
}
},
methods: {
init() {

View File

@ -7,18 +7,23 @@
<image :src="form.img_src[0].url" class="title-img" mode="heightFix"></image>
</template>
<template v-else-if="!isEmpty(form.icon_class)">
<iconfont :name="'icon-' + form.icon_class" :size="new_style.icon_size * 2 + 'rpx'" :color="new_style.icon_color"></iconfont>
<iconfont :name="'icon-' + form.icon_class" :size="new_style.icon_size * 2 + 'rpx'"
:color="new_style.icon_color"></iconfont>
</template>
<view class="pr-15 nowrap" :style="title_style">{{ form.title || '标题' }}</view>
</view>
<view class="flex-row gap-10 align-c right-0 pa">
<template v-if="form.keyword_show == '1'">
<view v-for="item in keyword_list" :key="item.id" :style="keyword_style" :data-value="item.link.page" @tap="url_event">
<view v-for="item in keyword_list" :key="item.id" :style="keyword_style"
:data-value="item.link.page" @tap="url_event">
{{ item.title }}
</view>
</template>
<view v-if="form.right_show == '1'" class="nowrap flex-row align-c" :style="right_style" :data-value="form.right_link.page" @tap="url_event">{{ form.right_title }}
<iconfont name="icon-arrow-right" :color="new_style.right_color" :size="new_style.right_size * 2 + 'rpx'"></iconfont>
<view v-if="form.right_show == '1'" class="nowrap flex-row align-c" :style="right_style"
:data-value="form.right_link.page" @tap="url_event">{{ form.right_title }}
<iconfont name="icon-arrow-right" :color="new_style.right_color"
:size="new_style.right_size * 2 + 'rpx'">
</iconfont>
</view>
</view>
</view>
@ -38,6 +43,10 @@ export default {
return {};
},
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -52,18 +61,22 @@ export default {
right_size: '',
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
console.log(this.propValue);
this.init();
},
methods: {
isEmpty,
init() {
this.setData({
form: this.propValue.content,
new_style: this.propValue.style,
});
//
this.setData({
title_center: this.form.is_title_center == '1' ? 'jc-c' : '',

View File

@ -38,6 +38,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -77,6 +81,12 @@
},
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -15,6 +15,10 @@
type: Object,
default: () => ({}),
},
propkey: {
type: String,
default: '',
}
},
data() {
return {
@ -24,6 +28,12 @@
video: '',
};
},
watch: {
propkey(val) {
//
this.init();
}
},
created() {
this.init();
},

View File

@ -4,7 +4,7 @@
<!-- diy模式 -->
<block v-if="data_mode == 3">
<block v-if="data_list !== null">
<componentDiy :propValue="data_list.config" :propDataId="data_list.id">
<componentDiy :propValue="data_list.config" :propDataId="data_list.id" :propkey="diy_key">
<template slot="diy-bottom">
<!-- 结尾 -->
<component-bottom-line :propStatus="data_bottom_line_status"></component-bottom-line>
@ -402,6 +402,7 @@
plugins_binding_data: null,
//
plugins_magic_data: null,
diy_key: '',
};
},
@ -437,10 +438,8 @@
onShow() {
//
app.globalData.page_event_onshow_handle();
//
this.init();
//
this.init_config();
@ -578,6 +577,9 @@
//
this.init_result_common_handle();
this.setData({
diy_key: Math.random(),
});
},
fail: () => {
//