jufubao-base 1.0.169-beta5 → 1.0.169-beta7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. package/package.json +1 -1
  2. package/src/components/JfbBaseTfkCardBind/Api.js +49 -30
  3. package/src/components/JfbBaseTfkCardBind/Attr.js +25 -1
  4. package/src/components/JfbBaseTfkCardBind/JfbBaseTfkCardBind.vue +139 -7
  5. package/src/components/JfbBaseTfkCardBind/Mock.js +19 -9
  6. package/src/components/JfbBaseTfkCardDetail/Api.js +11 -0
  7. package/src/components/JfbBaseTfkCardDetail/Attr.js +74 -0
  8. package/src/components/JfbBaseTfkCardDetail/JfbBaseTfkCardDetail.vue +141 -8
  9. package/src/components/JfbBaseTfkCardLogin/Attr.js +182 -0
  10. package/src/components/JfbBaseTfkCardLogin/JfbBaseTfkCardLogin.vue +250 -33
  11. package/src/components/JfbBaseTfkCardLogin/Mock.js +1 -1
  12. package/src/components/JfbBaseTfkCardLogin/XdCouponItem.vue +68 -16
  13. package/src/components/JfbBaseTfkSearch/AllList.vue +231 -0
  14. package/src/components/JfbBaseTfkSearch/Api.js +11 -42
  15. package/src/components/JfbBaseTfkSearch/Attr.js +125 -2
  16. package/src/components/JfbBaseTfkSearch/ContentCinema.vue +12 -2
  17. package/src/components/JfbBaseTfkSearch/{ContentItem.vue → ContentFilm.vue} +18 -4
  18. package/src/components/JfbBaseTfkSearch/ContentProduct.vue +308 -0
  19. package/src/components/JfbBaseTfkSearch/ContentShop.vue +184 -0
  20. package/src/components/JfbBaseTfkSearch/CusAttr.js +2 -0
  21. package/src/components/JfbBaseTfkSearch/CustomList.vue +181 -28
  22. package/src/components/JfbBaseTfkSearch/JfbBaseTfkSearch.vue +132 -20
  23. package/src/components/JfbBaseTfkSearch/Mock.js +90 -11
  24. package/src/components/JfbBaseTfkSearch/SkeletonCinema.vue +1 -2
  25. package/src/components/JfbBaseTfkSearch/SkeletonProduct.vue +98 -72
  26. package/src/components/JfbBaseTfkSearch/handleKeyword.js +24 -0
  27. package/src/components/JfbBaseTfkSearch/listMixins.js +71 -0
  28. package/src/components/JfbBaseTfkSearch/search.js +270 -152
@@ -0,0 +1,231 @@
1
+ <template>
2
+ <view class="search_all_list" >
3
+ <view class="module_item" v-for="parent in list" :key="parent.setting_id"
4
+ :style="{
5
+ padding:contMarginComp,
6
+ }"
7
+ >
8
+ <view class="module_title">{{ parent.name }}</view>
9
+ <view class="module_cont">
10
+ <view v-for="(item, i) in parent.items" :key="i">
11
+ <content-cinema v-if="parent.type === 'cinema'"
12
+ style="width: 100%; height: 100%"
13
+ :item="item"
14
+ :out-spacing="$parentVm.outSpacing"
15
+ :color="{SEAT:$parentVm.mainColor,CODE:$parentVm.subMainColor,SELL:$parentVm.successColor}"
16
+ :border-radius="$parentVm.imgRradius"
17
+ @on-schedule="(cinema)=>{$parentVm.handleSchedule(cinema,parent)}"
18
+ @on-cashier-detail="(cinema)=>{$parentVm.handleCashierDetail(cinema,parent)}"
19
+ @on-code-detail="(cinema)=>{$parentVm.handleCodeDetail(cinema,parent)}"
20
+ ></content-cinema>
21
+
22
+ <content-film v-if="parent.type === 'film'"
23
+ style="width: 100%; height: 100%"
24
+ :item="item"
25
+ :out-spacing="$parentVm.outSpacing"
26
+ :color="$parentVm.mainColor"
27
+ :border-radius="$parentVm.imgRradius"
28
+ @on-film-detail="(film_id)=>{$parentVm.handleFilmDetail(film_id, parent)}"
29
+ @on-buy="(film_id)=>{$parentVm.handleBuy(film_id, parent)}"
30
+ ></content-film>
31
+
32
+ <content-shop v-if="parent.type === 'shop'"
33
+ style="width: 100%; height: 100%"
34
+ :item="item"
35
+ :out-spacing="$parentVm.outSpacing"
36
+ :color="$parentVm.mainColor"
37
+ :border-radius="$parentVm.imgRradius"
38
+ :is-echange="'Y' || $parentVm.isShowExchange"
39
+ @on-shop-jhd="(shop)=>{$parentVm.handleShopJhd(shop,parent)}"
40
+ @on-shop-detail="(shop)=>{$parentVm.handleShopDetail(shop,parent)}"
41
+ ></content-shop>
42
+
43
+ <content-product v-if="parent.type === 'product'"
44
+ style="width: 100%; height: 100%"
45
+ :item="item"
46
+ :product-config="$parentVm.productConfig"
47
+ :out-spacing="$parentVm.outSpacing"
48
+ :color="$parentVm.mainColor"
49
+ :border-radius="$parentVm.imgRradius"
50
+ :cell="1"
51
+ @on-product-detail="(product)=>{$parentVm.handleProductDetail(product,parent)}"
52
+ ></content-product>
53
+ </view>
54
+ </view>
55
+ <view class="module_more">
56
+ <view>查看全部{{ parent.name }} >></view>
57
+ </view>
58
+ </view>
59
+ </view>
60
+ </template>
61
+
62
+ <script>
63
+ import ContentCinema from "./ContentCinema.vue"
64
+ import ContentFilm from "./ContentFilm.vue"
65
+ import ContentShop from "./ContentShop.vue"
66
+ import ContentProduct from "./ContentProduct.vue"
67
+ export default{
68
+ name: "SearchAllList",
69
+ components: {
70
+ ContentCinema,
71
+ ContentFilm,
72
+ ContentShop,
73
+ ContentProduct
74
+ },
75
+ props: {
76
+
77
+ },
78
+ computed: {
79
+ contMarginComp(){
80
+ let str = `${this.$parentVm.checkValue(this.$parentVm.contMargin.top, 20)}rpx`;
81
+ str = `${str} ${this.$parentVm.checkValue(this.$parentVm.contMargin.right, 20)}rpx`;
82
+ str = `${str} ${this.$parentVm.checkValue(this.$parentVm.contMargin.bottom, 20)}rpx`;
83
+ str = `${str} ${this.$parentVm.checkValue(this.$parentVm.contMargin.left, 20)}rpx`;
84
+ return str
85
+ },
86
+ },
87
+ data(){
88
+ return {
89
+ $parentVm:null,
90
+ parentStatus: false,
91
+
92
+ list: [
93
+ {
94
+ "type": "product",
95
+ "name": "蛋糕",
96
+ "detail_redirect_data": "{\"dir\":\"wtxsaas\",\"host\":\"sandbox-website-05.jufubao.cn\",\"path\":\"\\/main\\/order\\/detail\",\"appType\":\"h5\",\"site_id\":\"17928cc37788be02\",\"site_url\":\"https:\\/\\/sandbox-website-05.jufubao.cn\\/wtxsaas\\/main\\/order\\/detail\",\"frontPath\":\"\\/wtxsaas\\/main\\/order\\/detail\",\"fixed_business_code\":\"\"}",
97
+ "detail1_redirect_data": "",
98
+ "more_redirect_data": "",
99
+ "sort": 0,
100
+ "setting_id": 1,
101
+ "next_page_token": "a:2:{i:0;d:1705.0785;i:1;s:8:\"60030143\";}",
102
+ "items": [
103
+ {
104
+ "brand_id": 100003,
105
+ "brand_name": "品牌jls0519",
106
+ "list_title": "3",
107
+ "market_price": 2000,
108
+ "market_tags": [],
109
+ "product_id": 60030143,
110
+ "product_name": "仅快递实物商品(北京廊坊支持配送)",
111
+ "product_type": "good",
112
+ "promo_price": 0,
113
+ "sale_num": 8,
114
+ "sale_price": 3000,
115
+ "status": "ok",
116
+ "thumb": "/uploads/20231215/b2ce0235129aa592044f96343f25c338.jpeg"
117
+ }
118
+ ]
119
+ },
120
+ {
121
+ "type": "shop",
122
+ "name": "蛋糕",
123
+ "detail_redirect_data": "",
124
+ "detail1_redirect_data": "",
125
+ "more_redirect_data": "",
126
+ "sort": 1,
127
+ "setting_id": 5,
128
+ "next_page_token": "a:1:{i:0;d:4.4;}",
129
+ "items": [
130
+ {
131
+ "brand_id": 0,
132
+ "brand_name": "",
133
+ "shop_icon": "https://dimg04.uat.qa.nt.ctripcorp.com/images/1lo4a12000007fyeg8D96.gif",
134
+ "distance": 4,
135
+ "business_status": "5",
136
+ "full_address": "北京北京北京市东城区景山前街4号",
137
+ "phone": "",
138
+ "consume_mode": [
139
+ "TRAVEL"
140
+ ],
141
+ "consume_mode_name": "",
142
+ "shop_id": 1052782,
143
+ "resource_shop_id": 8000302,
144
+ "resource_shop_name": "故宫-测试1-攻略修改",
145
+ "shop_tags": {},
146
+ "stars": 2
147
+ }
148
+ ]
149
+ },
150
+ {
151
+ "type": "cinema",
152
+ "name": "影院",
153
+ "detail_redirect_data": "{\"dir\":\"apply06\",\"host\":\"sandbox-website-05.jufubao.cn\",\"path\":\"\\/main\\/movie\\/suhedule\",\"appType\":\"h5\",\"site_id\":\"17928cc37788be02\",\"site_url\":\"https:\\/\\/sandbox-website-05.jufubao.cn\\/apply06\\/main\\/movie\\/suhedule\",\"frontPath\":\"\\/apply06\\/main\\/movie\\/suhedule\",\"fixed_business_code\":\"\"}",
154
+ "detail1_redirect_data": "{\"dir\":\"apply06\",\"host\":\"sandbox-website-05.jufubao.cn\",\"path\":\"\\/main\\/movie\\/cdetailnew\",\"appType\":\"h5\",\"site_id\":\"17928cc37788be02\",\"site_url\":\"https:\\/\\/sandbox-website-05.jufubao.cn\\/apply06\\/main\\/movie\\/cdetailnew\",\"frontPath\":\"\\/apply06\\/main\\/movie\\/cdetailnew\",\"fixed_business_code\":\"\"}",
155
+ "more_redirect_data": "",
156
+ "sort": 3,
157
+ "setting_id": 10,
158
+ "next_page_token": 1,
159
+ "items": [
160
+ {
161
+ "address": "朝阳区安慧里三区10号 (北辰购物中心对面)",
162
+ "brand_id": 0,
163
+ "brand_name": "",
164
+ "cinema_id": 6771413,
165
+ "cinema_name": "北京剧院",
166
+ "cinema_type": [
167
+ "SEAT"
168
+ ],
169
+ "cinema_type_name": [
170
+ "在线选座"
171
+ ],
172
+ "distance": "",
173
+ "is_open": "Y",
174
+ "shop_icon": ""
175
+ }
176
+ ]
177
+ }
178
+ ],
179
+ }
180
+ },
181
+ created(){
182
+ this.getParentMV();
183
+ this.getList();
184
+ },
185
+ methods: {
186
+ getParentMV(){
187
+ this.$emit('on-parent-vm', ($vm)=>{
188
+ this.$parentVm = $vm;
189
+ this.parentStatus = true;
190
+ })
191
+ },
192
+ getList(){
193
+ this.$xdShowLoading({});
194
+ this.$emit('on-list', {
195
+ params: {},
196
+ cb:(list)=>{
197
+ this.list = list;
198
+ this.$xdHideLoading();
199
+ }
200
+ })
201
+ }
202
+ }
203
+ }
204
+ </script>
205
+
206
+ <style lang="less" scoped>
207
+ .search_all_list{
208
+ .module_item{
209
+ background-color: #FFFFFF;
210
+ margin-bottom: 20rpx;
211
+ }
212
+ .module_title{
213
+ height: 88rpx;
214
+ line-height: 88rpx;
215
+ border-bottom: 1px solid #EEEEEE;
216
+ font-size: 28rpx;
217
+ color: #333333;
218
+ }
219
+ .module_cont{
220
+ padding: 20rpx 0;
221
+ }
222
+ .module_more{
223
+ display: flex;
224
+ justify-content: center;
225
+ align-items: center;
226
+ height: 80rpx;
227
+ font-size: 26rpx;
228
+ color: #999999;
229
+ }
230
+ }
231
+ </style>
@@ -7,50 +7,19 @@
7
7
  module.exports = [
8
8
  {
9
9
  //设置方法名字当别忘记加上【模块名字】:Tfk
10
- mapFnName: 'getTfkByIdFilmSquate',
11
- title: '获取电影广场列表',
12
- path: '/api/account/film/list-film-square',
10
+ mapFnName: 'getTfkSearchList',
11
+ title: '获取s搜索列表',
12
+ path: '/mall/v1/search',
13
13
  isRule: false,
14
14
  params: {
15
- last_key: ['当前页', 'Number', '必选'],
16
- page_size: ['每页数量', 'Number', '必选'],
17
- },
18
- isConsole: true,
19
- disabled: true,
20
- },
21
- {
22
- //设置方法名字当别忘记加上【模块名字】:Tfk
23
- mapFnName: 'updateTfkFilmPaiqiDate',
24
- title: '更新排期',
25
- path: '/api/account/film/paiqi-date',
26
- isRule: false,
27
- params: {
28
- film_id: ['电影id', 'Number', '必选'],
29
- cinema_id: ['影院id', 'Number', '必选'],
30
- },
31
- isConsole: true,
32
- disabled: true,
33
- },
34
- {
35
- //设置方法名字当别忘记加上【模块名字】:Tfk
36
- mapFnName: 'removeTfkFilmAddress',
37
- title: '删除我的配送地址',
38
- path: '/api/account/film/paiqi-date',
39
- isRule: false,
40
- params: {
41
- film_id: ['电影id', 'Number', '必选'],
42
- },
43
- isConsole: true,
44
- disabled: true,
45
- },
46
- {
47
- //设置方法名字当别忘记加上【模块名字】:Tfk
48
- mapFnName: 'addTfkFilmcart',
49
- title: '添加购物车',
50
- path: '/api/account/film/paiqi-date',
51
- isRule: false,
52
- params: {
53
- film_id: ['电影id', 'Number', '必选'],
15
+ keyword: ['模糊搜索关键字', 'Number', '必选'],
16
+ namespace: ['业务线', 'Number', '必选'],
17
+ city_code: ['城市编码', 'Number', '必选'],
18
+ latitude: ['纬度', 'Number', '必选'],
19
+ longitude: ['经度', 'Number', '必选'],
20
+ search_range: ['搜索范围', 'Number', '必选'],
21
+ page_size: ['每页条数', 'Number', '必选'],
22
+ page_token: ['当前页码', 'Number', '必选'],
54
23
  },
55
24
  isConsole: true,
56
25
  disabled: true,
@@ -33,9 +33,132 @@ export default {
33
33
  inline: false,
34
34
  className: 'input60',
35
35
  },
36
-
37
36
  //todo
38
-
37
+ {
38
+ label: '菜单配置',
39
+ ele: "title",
40
+ groupKey:'style',
41
+ size: "small",
42
+ },
43
+ {
44
+ label: "菜单外边距",
45
+ ele: "xd-margin-padding",
46
+ valueKey: 'menuMargin',
47
+ value: data['menuMargin'] || {
48
+ top: 0,
49
+ right: 0,
50
+ bottom: 0,
51
+ left: 0,
52
+ },
53
+ groupKey:'style',
54
+ setting: {
55
+ type: 'padding',
56
+ },
57
+ placeholder: '请设置边距',
58
+ inline: false,
59
+ notice: '设置内边距,<span style="color: red">单位:像素</span>。',
60
+ },
61
+ {
62
+ label: "菜单内边距",
63
+ ele: "xd-margin-padding",
64
+ valueKey: 'menuPadding',
65
+ value: data['menuPadding'] || {
66
+ top: 0,
67
+ right: 0,
68
+ bottom: 0,
69
+ left: 0,
70
+ },
71
+ groupKey:'style',
72
+ setting: {
73
+ type: 'padding',
74
+ },
75
+ placeholder: '请设置内边距',
76
+ inline: false,
77
+ notice: '设置内边距,<span style="color: red">单位:像素</span>。',
78
+ },
79
+ {
80
+ label: "菜单背景色",
81
+ ele: "xd-color",
82
+ valueKey: 'menuBgColor',
83
+ value: data['menuBgColor'] || '#FFFFFF',
84
+ groupKey:'style',
85
+ placeholder: '请选择菜单背景色',
86
+ },
87
+ {
88
+ label: "菜单字体设置",
89
+ ele: "xd-text-and-bgc",
90
+ groupKey:'style',
91
+ valueKey: 'menuTabColor',
92
+ value: data['menuTabColor'] || null,
93
+ setting: {
94
+ fontSize: true, //字体大小选择
95
+ color: true, //文字颜色选项
96
+ bgColor: true, //背景选项
97
+ weight: true, //文字粗细
98
+ },
99
+ handleCustom({action, data}) {
100
+ XdBus.getParentApi('getOptionsSettingList')({setting_id: 'edtix_style_font_size'})
101
+ .then(res => {
102
+ data.cb(res.list)
103
+ })
104
+ .catch(error => {
105
+ console.error(error);
106
+ data.cb([])
107
+ });
108
+ },
109
+ },
110
+ {
111
+ label: "菜单间距设置:",
112
+ groupKey:'style',
113
+ ele: 'el-input',
114
+ valueKey: 'menuItemMargin',
115
+ value: data.menuItemMargin || 40,
116
+ type: "number",
117
+ className: "input40",
118
+ placeholder: '请输入菜单间距',
119
+ inline: false,
120
+ notice: '设置菜单间距,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">40</span>像素',
121
+ },
122
+ {
123
+ label: "菜单底部横线粗细:",
124
+ ele: "el-input",
125
+ valueKey: "menuBorderWidth",
126
+ value: data.menuBorderWidth || 1,
127
+ groupKey: "style",
128
+ type: "number",
129
+ },
130
+ {
131
+ label: '菜单单项内边距设置:',
132
+ groupKey:'style',
133
+ ele: 'xd-margin-padding',
134
+ valueKey: 'menuItemPadding',
135
+ value: data.menuItemPadding || null,
136
+ setting: {
137
+ type: 'padding',
138
+ },
139
+ placeholder: '请设置边距',
140
+ inline: false,
141
+ notice: '设置内边距,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">20</span>像素',
142
+ },
143
+ {
144
+ label: "搜索范围",
145
+ ele: "xd-search-setting-options",
146
+ valueKey: 'searchScope',
147
+ value: data['searchScope'] || [],
148
+ groupKey:'content',
149
+ placeholder: '请选择内容圆角设置',
150
+ multiple: false,
151
+ className: 'input80',
152
+ handleCustom({ action, data }) {
153
+ XdBus.getParentApi('getSearchSettingOptions')()
154
+ .then(res => {
155
+ data.cb(res.list)
156
+ })
157
+ .catch(error => {
158
+ console.error(error);
159
+ });
160
+ },
161
+ },
39
162
 
40
163
  //列表相关属性
41
164
  ...CusAttr(data),
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <view class="content" @click="handleCinemaDetail">
3
- <view class="title">{{item['cinema_name']}}</view>
3
+ <view class="title" v-html="cusName"></view>
4
4
  <view class="address">{{item['address']}}</view>
5
5
  <view class="bottom">
6
6
  <view class="distance">
@@ -28,6 +28,7 @@
28
28
  <script>
29
29
  import XdButton from "@/components/XdButton/XdButton.vue";
30
30
  import XdFontIcon from "@/components/XdFontIcon/XdFontIcon.vue";
31
+ import handleKeyword from "./handleKeyword";
31
32
 
32
33
  export default {
33
34
  name:'ContentCinema',
@@ -36,6 +37,10 @@
36
37
  XdFontIcon
37
38
  },
38
39
  props:{
40
+ keyword:{
41
+ type:String,
42
+ default: '',
43
+ },
39
44
  item:Object,
40
45
  color: {
41
46
  type: Object,
@@ -43,6 +48,11 @@
43
48
  },
44
49
 
45
50
  },
51
+ computed:{
52
+ cusName(){
53
+ return handleKeyword(this, this.item['cinema_name'], this.keyword)
54
+ },
55
+ },
46
56
  data(){
47
57
  return {
48
58
 
@@ -99,7 +109,7 @@
99
109
  <style scoped lang="less">
100
110
  .content {
101
111
  .title {
102
- font-size: 32rpx;
112
+ font-size: 30rpx;
103
113
  line-height: 40rpx;
104
114
  margin-bottom: 20rpx;
105
115
  color: #333;
@@ -4,10 +4,10 @@
4
4
  class="image"
5
5
  :style="{marginRight: outSpacing + 'rpx',borderRadius:borderRadius+'rpx'}"
6
6
  >
7
- <image :src="item['poster']" :alt="item['show_name']"></image>
7
+ <image :src="imageUrl" :alt="item['show_name']"></image>
8
8
  </view>
9
9
  <view class="middle">
10
- <view class="name">{{item['show_name']}}</view>
10
+ <view class="name" v-html="name"></view>
11
11
  <view class="other">类型:{{item['type']}}</view>
12
12
  <view class="other">导演:{{item['director']}}</view>
13
13
  <view class="other">主演:{{item['leading_role']}}</view>
@@ -55,6 +55,8 @@
55
55
 
56
56
  <script>
57
57
  import XdButton from "@/components/XdButton/XdButton.vue";
58
+ import getServiceUrl from "@/common/getServiceUrl";
59
+ import handleKeyword from "./handleKeyword";
58
60
 
59
61
  export default {
60
62
  name:'ContentItem',
@@ -62,6 +64,10 @@
62
64
  XdButton
63
65
  },
64
66
  props:{
67
+ keyword:{
68
+ type:String,
69
+ default:''
70
+ },
65
71
  item:Object,
66
72
  outSpacing: {
67
73
  type: Number|String,
@@ -81,6 +87,14 @@
81
87
  }
82
88
 
83
89
  },
90
+ computed:{
91
+ imageUrl(){
92
+ return getServiceUrl(this.item['poster'])
93
+ },
94
+ name(){
95
+ return handleKeyword(this, this.item.show_name, this.keyword);
96
+ }
97
+ },
84
98
  created() {
85
99
 
86
100
  },
@@ -117,8 +131,8 @@
117
131
  .middle {
118
132
  flex: 1;
119
133
  & .name {
120
- font-size: 36rpx;
121
- font-weight: 600;
134
+ font-size: 30rpx;
135
+ font-weight: 500;
122
136
  margin-bottom: 20rpx;
123
137
  .uni-max-cut(2, 90);
124
138
  line-height: 45rpx;