cyy-vue-material 7.0.19 → 7.0.21

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 (38) hide show
  1. package/dist/index.js +1 -1
  2. package/package.json +34 -34
  3. package/src/App.vue +149 -149
  4. package/src/api/http.js +16 -16
  5. package/src/api/index.js +21 -21
  6. package/src/api/urlQuery.js +20 -20
  7. package/src/common/js/constant.js +5 -5
  8. package/src/common/js/index.js +1 -1
  9. package/src/components/vop-label.vue +29 -29
  10. package/src/index.dev.js +4 -4
  11. package/src/package/cyy-ArsenalActivity/components/u-cont-down.vue +316 -316
  12. package/src/package/cyy-ArsenalActivity/components/u-line-progress.vue +150 -150
  13. package/src/package/cyy-ArsenalActivity/cyy-ArsenalActivity.vue +820 -820
  14. package/src/package/cyy-ArsenalCarousel/cyy-ArsenalCarousel.vue +137 -137
  15. package/src/package/cyy-ArsenalClass/cyy-ArsenalClass.vue +564 -564
  16. package/src/package/cyy-ArsenalMyNavigation/cyy-ArsenalMyNavigation.vue +128 -125
  17. package/src/package/cyy-ArsenalMyTop/cyy-ArsenalMyTop.vue +211 -211
  18. package/src/package/cyy-ArsenalNavigation/cyy-ArsenalNavigation.vue +236 -236
  19. package/src/package/cyy-ArsenalPicture/cyy-ArsenalPicture.vue +228 -228
  20. package/src/package/cyy-ArsenalPromotion/cyy-ArsenalPromotion.vue +913 -899
  21. package/src/package/cyy-ArsenalRecommend/cyy-ArsenalRecommend.vue +56 -56
  22. package/src/package/cyy-ArsenalTop/cyy-ArsenalTop.vue +328 -328
  23. package/src/package/cyy-collocation/cyy-collocation.vue +639 -639
  24. package/src/package/cyy-goods/cyy-goods.vue +317 -317
  25. package/src/package/cyy-goodsOne/consult.vue +267 -267
  26. package/src/package/cyy-goodsOne/cyy-goodsOne.vue +217 -217
  27. package/src/package/cyy-image/cyy-image.vue +64 -64
  28. package/src/package/cyy-live/cyy-live.vue +196 -196
  29. package/src/package/cyy-new-product/cyy-new-product.vue +834 -834
  30. package/src/package/cyy-notice/cyy-notice.vue +137 -137
  31. package/src/package/cyy-search/cyy-search.vue +57 -57
  32. package/src/package/cyy-slider/cyy-slider.vue +117 -117
  33. package/src/package/cyy-title/cyy-title.vue +38 -38
  34. package/src/package/cyy-video/cyy-video.vue +49 -49
  35. package/src/package/index.js +21 -21
  36. package/src/utils/checkEnv.js +16 -16
  37. package/src/utils/fetchFactory.js +100 -100
  38. package/src/utils/index.js +2 -2
@@ -1,196 +1,196 @@
1
- <template>
2
- <div>
3
- <div v-if="!props.live" :style="noDataStyle">请选择直播</div>
4
- <div
5
- class="liveBox"
6
- :style="{
7
- marginTop: `${props.marginTop}px`,
8
- marginBottom: `${props.marginBottom}px`,
9
- }"
10
- @click="handleToLive()"
11
- v-else
12
- >
13
- <div class="liveTitlePo">
14
- {{ liveTitle }}
15
- </div>
16
- <div class="live">
17
- <div class="liveCover">
18
- <img :src="liveCover" />
19
- <div class="liveState">
20
- {{ liveState }}
21
- </div>
22
- </div>
23
- </div>
24
- <!-- <div class="liveIntroduction">
25
- <div class="liveTitle">{{ liveTitle }}</div>
26
- </div> -->
27
- </div>
28
- </div>
29
- </template>
30
-
31
- <script>
32
- import { isLc } from "../../utils/index.js";
33
- import { queryInfuencerAndChild } from "../../api/index.js";
34
- import { fetchPost } from "../../api/http.js";
35
- export default {
36
- props: {
37
- props: {
38
- live: Array,
39
- title: String,
40
- cover: String,
41
- marginTop: Number,
42
- marginBottom: Number,
43
- },
44
- },
45
- data() {
46
- return {
47
- noDataStyle: {
48
- width: "100%",
49
- height: "180px",
50
- lineHeight: "180px",
51
- fontSize: "30px",
52
- backgroundColor: "#ccc",
53
- color: "#aaa",
54
- textAlign: "center",
55
- },
56
- liveDataState: 0,
57
- };
58
- },
59
- mounted() {
60
- this.init();
61
- },
62
- computed: {
63
- liveTitle() {
64
- if (this.props.title && this.props.title !== "") {
65
- return this.props.title;
66
- } else {
67
- return this.props.live.infuencerName;
68
- }
69
- },
70
- liveCover() {
71
- if (this.props.cover && this.props.cover !== "") {
72
- return this.props.cover;
73
- } else {
74
- return this.props.live.infuencerUrl1;
75
- }
76
- },
77
- liveState() {
78
- let dataState = this.liveDataState;
79
- let TextDescription = "";
80
- switch (dataState) {
81
- case 0:
82
- TextDescription = "初始化";
83
- break;
84
- case 1:
85
- TextDescription = "上传直播间";
86
- break;
87
- case 101:
88
- TextDescription = "直播中";
89
- break;
90
- case 102:
91
- TextDescription = "未开始";
92
- break;
93
- case 103:
94
- TextDescription = "已结束";
95
- break;
96
- case 104:
97
- TextDescription = "禁播";
98
- break;
99
- case 105:
100
- TextDescription = "暂停";
101
- break;
102
- case 106:
103
- TextDescription = "异常";
104
- break;
105
- case 107:
106
- TextDescription = "已过期";
107
- break;
108
- }
109
- return TextDescription;
110
- },
111
- },
112
- methods: {
113
- async init() {
114
- if (isLc) {
115
- const url =
116
- queryInfuencerAndChild +
117
- `?infuencerCode=${this.props.live.infuencerCode}`;
118
- const { list } = await fetchPost(url);
119
- if (list.length === 0) {
120
- this.liveDataState = list[0].dataState;
121
- }
122
- } else {
123
- let that = this;
124
- that.http
125
- .post(queryInfuencerAndChild, {
126
- infuencerCode: this.props.live.infuencerCode,
127
- })
128
- .then((res) => {
129
- this.liveDataState = res.list[0].dataState;
130
- });
131
- }
132
- },
133
- handleToLive() {
134
- if (isLc) {
135
- return;
136
- }
137
- let roomId = this.props.live.infuencerEcode;
138
- wx.navigateTo({
139
- url: `plugin-private://wx2b03c6e691cd7370/pages/live-player-plugin?room_id=${roomId}`,
140
- });
141
- },
142
- },
143
- };
144
- </script>
145
-
146
- <style lang="less" scoped>
147
- .liveBox {
148
- padding: 14px 5px;
149
- box-shadow: 0px 5px 10px 0px rgba(0, 0, 0, 0.1);
150
- border-radius: 14px;
151
- .live {
152
- display: flex;
153
- .liveCover {
154
- position: relative;
155
- width: 100%;
156
- img {
157
- width: 100%;
158
- }
159
- .liveState {
160
- position: absolute;
161
- left: 0;
162
- top: 0;
163
- color: white;
164
- background-color: red;
165
- padding: 0.25em 0.5em;
166
- font-size: 12px;
167
- }
168
- }
169
- .liveIntroduction {
170
- margin-left: 10px;
171
- display: flex;
172
- flex-direction: column;
173
- justify-content: space-between;
174
- width: 190px;
175
- .liveTitle {
176
- display: -webkit-box;
177
- -webkit-line-clamp: 2;
178
- -webkit-box-orient: vertical;
179
- overflow: hidden;
180
- text-overflow: ellipsis;
181
- font-size: 14px;
182
- }
183
- .anchorName {
184
- display: -webkit-box;
185
- -webkit-line-clamp: 1;
186
- -webkit-box-orient: vertical;
187
- overflow: hidden;
188
- text-overflow: ellipsis;
189
- }
190
- }
191
- }
192
- }
193
- .liveTitlePo {
194
- margin-bottom: 8px;
195
- }
196
- </style>
1
+ <template>
2
+ <div>
3
+ <div v-if="!props.live" :style="noDataStyle">请选择直播</div>
4
+ <div
5
+ class="liveBox"
6
+ :style="{
7
+ marginTop: `${props.marginTop}px`,
8
+ marginBottom: `${props.marginBottom}px`,
9
+ }"
10
+ @click="handleToLive()"
11
+ v-else
12
+ >
13
+ <div class="liveTitlePo">
14
+ {{ liveTitle }}
15
+ </div>
16
+ <div class="live">
17
+ <div class="liveCover">
18
+ <img :src="liveCover" />
19
+ <div class="liveState">
20
+ {{ liveState }}
21
+ </div>
22
+ </div>
23
+ </div>
24
+ <!-- <div class="liveIntroduction">
25
+ <div class="liveTitle">{{ liveTitle }}</div>
26
+ </div> -->
27
+ </div>
28
+ </div>
29
+ </template>
30
+
31
+ <script>
32
+ import { isLc } from "../../utils/index.js";
33
+ import { queryInfuencerAndChild } from "../../api/index.js";
34
+ import { fetchPost } from "../../api/http.js";
35
+ export default {
36
+ props: {
37
+ props: {
38
+ live: Array,
39
+ title: String,
40
+ cover: String,
41
+ marginTop: Number,
42
+ marginBottom: Number,
43
+ },
44
+ },
45
+ data() {
46
+ return {
47
+ noDataStyle: {
48
+ width: "100%",
49
+ height: "180px",
50
+ lineHeight: "180px",
51
+ fontSize: "30px",
52
+ backgroundColor: "#ccc",
53
+ color: "#aaa",
54
+ textAlign: "center",
55
+ },
56
+ liveDataState: 0,
57
+ };
58
+ },
59
+ mounted() {
60
+ this.init();
61
+ },
62
+ computed: {
63
+ liveTitle() {
64
+ if (this.props.title && this.props.title !== "") {
65
+ return this.props.title;
66
+ } else {
67
+ return this.props.live.infuencerName;
68
+ }
69
+ },
70
+ liveCover() {
71
+ if (this.props.cover && this.props.cover !== "") {
72
+ return this.props.cover;
73
+ } else {
74
+ return this.props.live.infuencerUrl1;
75
+ }
76
+ },
77
+ liveState() {
78
+ let dataState = this.liveDataState;
79
+ let TextDescription = "";
80
+ switch (dataState) {
81
+ case 0:
82
+ TextDescription = "初始化";
83
+ break;
84
+ case 1:
85
+ TextDescription = "上传直播间";
86
+ break;
87
+ case 101:
88
+ TextDescription = "直播中";
89
+ break;
90
+ case 102:
91
+ TextDescription = "未开始";
92
+ break;
93
+ case 103:
94
+ TextDescription = "已结束";
95
+ break;
96
+ case 104:
97
+ TextDescription = "禁播";
98
+ break;
99
+ case 105:
100
+ TextDescription = "暂停";
101
+ break;
102
+ case 106:
103
+ TextDescription = "异常";
104
+ break;
105
+ case 107:
106
+ TextDescription = "已过期";
107
+ break;
108
+ }
109
+ return TextDescription;
110
+ },
111
+ },
112
+ methods: {
113
+ async init() {
114
+ if (isLc) {
115
+ const url =
116
+ queryInfuencerAndChild +
117
+ `?infuencerCode=${this.props.live.infuencerCode}`;
118
+ const { list } = await fetchPost(url);
119
+ if (list.length === 0) {
120
+ this.liveDataState = list[0].dataState;
121
+ }
122
+ } else {
123
+ let that = this;
124
+ that.http
125
+ .post(queryInfuencerAndChild, {
126
+ infuencerCode: this.props.live.infuencerCode,
127
+ })
128
+ .then((res) => {
129
+ this.liveDataState = res.list[0].dataState;
130
+ });
131
+ }
132
+ },
133
+ handleToLive() {
134
+ if (isLc) {
135
+ return;
136
+ }
137
+ let roomId = this.props.live.infuencerEcode;
138
+ wx.navigateTo({
139
+ url: `plugin-private://wx2b03c6e691cd7370/pages/live-player-plugin?room_id=${roomId}`,
140
+ });
141
+ },
142
+ },
143
+ };
144
+ </script>
145
+
146
+ <style lang="less" scoped>
147
+ .liveBox {
148
+ padding: 14px 5px;
149
+ box-shadow: 0px 5px 10px 0px rgba(0, 0, 0, 0.1);
150
+ border-radius: 14px;
151
+ .live {
152
+ display: flex;
153
+ .liveCover {
154
+ position: relative;
155
+ width: 100%;
156
+ img {
157
+ width: 100%;
158
+ }
159
+ .liveState {
160
+ position: absolute;
161
+ left: 0;
162
+ top: 0;
163
+ color: white;
164
+ background-color: red;
165
+ padding: 0.25em 0.5em;
166
+ font-size: 12px;
167
+ }
168
+ }
169
+ .liveIntroduction {
170
+ margin-left: 10px;
171
+ display: flex;
172
+ flex-direction: column;
173
+ justify-content: space-between;
174
+ width: 190px;
175
+ .liveTitle {
176
+ display: -webkit-box;
177
+ -webkit-line-clamp: 2;
178
+ -webkit-box-orient: vertical;
179
+ overflow: hidden;
180
+ text-overflow: ellipsis;
181
+ font-size: 14px;
182
+ }
183
+ .anchorName {
184
+ display: -webkit-box;
185
+ -webkit-line-clamp: 1;
186
+ -webkit-box-orient: vertical;
187
+ overflow: hidden;
188
+ text-overflow: ellipsis;
189
+ }
190
+ }
191
+ }
192
+ }
193
+ .liveTitlePo {
194
+ margin-bottom: 8px;
195
+ }
196
+ </style>