qj-common 4.1.13 → 4.1.15

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "qj-common",
3
- "version": "4.1.13",
3
+ "version": "4.1.15",
4
4
  "description": "common files && template for qj-paas",
5
5
  "scripts": {
6
6
  "gulp": "gulp css"
@@ -1,4 +1,12 @@
1
1
  import request from '#/utils/request'
2
+ // 楼层
3
+ export function queryConttitleReDomainByCode(data) {
4
+ return request({
5
+ url: '/web/cms/conttitleBusiness/queryConttitleReDomainByCode.json',
6
+ method: 'get',
7
+ params: data
8
+ })
9
+ }
2
10
  //查询接口管理分类
3
11
  export function listApiManage(appmanageType) {
4
12
  return request({
@@ -4,9 +4,9 @@
4
4
  <div v-for="item in menuList" :key="item.conttitleId">
5
5
  <p>{{ item.conttitleName }}</p>
6
6
  <p
7
- v-for="item2 in item.childList"
8
- :key="item2.contlistId"
9
- @click="cutPage(item2.contlistName, item2.contlistId)"
7
+ v-for="item2 in item.cmsContlistReDomainList"
8
+ :key="item2.contlistId"
9
+ @click="cutPage(item2.contlistName, item2.contlistId)"
10
10
  >
11
11
  {{ item2.contlistName }}
12
12
  </p>
@@ -16,13 +16,12 @@
16
16
  </template>
17
17
 
18
18
  <script>
19
- import { queryConttitlePageForSc, queryContlistPageForSc } from '#/api/apimanage.js'
19
+ import { queryConttitleReDomainByCode } from '#/api/apimanage.js'
20
20
  export default {
21
21
  data() {
22
22
  return {
23
23
  menuList: [],
24
24
  active: "",
25
- hrefurl: process.env.API_ROOT,
26
25
  };
27
26
  },
28
27
  created() {
@@ -30,35 +29,24 @@ export default {
30
29
  },
31
30
  methods: {
32
31
  cutPage(contlistName, contlistId) {
33
- location.href=`/paas/b2b-cli-pc-ayd/index.html#/helpindex?contlistName=${contlistName}&contlistId=${contlistId}`
34
- // this.$router.push({
35
- // path: "/helpindex",
36
- // query: {
37
- // contlistName: contlistName,
38
- // contlistId: contlistId,
39
- // },
40
- // });
32
+ location.href = this.hrefurl + `/paas/b2b-cli-pc-ayd/index.html#/helpindex?contlistName=${contlistName}&contlistId=${contlistId}`;
41
33
  },
42
34
  getLeftFloor() {
43
- let tginfoMenuCode = "helpcenter";
44
- let dataState = 2;
45
- queryConttitlePageForSc({ tginfoMenuCode, dataState }).then((res) => {
46
- this.menuList = res.list;
47
- if (res.list) {
48
- this.menuList.forEach((item) => {
49
- let params = {
50
- conttitleCode: item.conttitleCode,
51
- dataState: 2,
52
- conttitleType: "doc",
53
- };
54
- queryContlistPageForSc(params).then((res2) => {
55
- item.childList = res2.list;
56
- this.$forceUpdate();
57
- });
58
- return item;
59
- });
60
- }
61
- });
35
+ let footMenuList = localStorage.getItem('footMenuList');
36
+ if (footMenuList) {
37
+ this.menuList = JSON.parse(footMenuList);
38
+ } else {
39
+ let tginfoMenuCode = "helpcenter";
40
+ let dataState = 2;
41
+ queryConttitleReDomainByCode({
42
+ tginfoMenuCode: "helpcenter"
43
+ }).then((res) => {
44
+ if (res) {
45
+ this.menuList = res;
46
+ localStorage.setItem('footMenuList', JSON.stringify(this.menuList));
47
+ }
48
+ })
49
+ }
62
50
  },
63
51
  },
64
52
  };
@@ -67,6 +55,7 @@ export default {
67
55
  <style lang="scss" scoped>
68
56
  .footerC {
69
57
  background-color: #56423d;
58
+
70
59
  .container {
71
60
  box-sizing: border-box;
72
61
  width: 1200px;
@@ -75,6 +64,7 @@ export default {
75
64
  padding: 50px 0;
76
65
  display: flex;
77
66
  justify-content: space-between;
67
+
78
68
  div {
79
69
  p {
80
70
  cursor: pointer;
@@ -82,8 +72,9 @@ export default {
82
72
  margin-bottom: 14px;
83
73
  font-size: 14px;
84
74
  }
75
+
85
76
  p:nth-child(1) {
86
- cursor: none;
77
+ cursor: pointer;
87
78
  color: #e6e4e4;
88
79
  margin-bottom: 24px;
89
80
  font-size: 16px;
@@ -1,181 +1,176 @@
1
1
  <template>
2
- <div class="container">
3
- <div class="bac">
4
- <div class="logo" @click="goHome">
5
- <img :src="hrefurl+logo" alt="" srcset=""/>
6
- </div>
7
- <div class="search">
8
- <div class="searchTatol">
9
- <!-- <div class="searchC"></div> -->
10
- <input v-model="searchValue" placeholder="请输入关键字进行搜索" @keyup.enter="search(searchValue)"/>
11
- <div class="search_logo" @click.passive.stop="search(searchValue)">
12
- <i class="el-icon-search t-24" style="color:white;"></i>
13
- </div>
14
- </div>
15
- <div style="display:flex;color:#666666;font-size:14px">
16
- <p>热门词搜索:</p>
17
- <p v-for="(item, index) in searchWord[0]?searchWord[0].cmsContlistReDomainList:''"
18
- :key="index" style="margin-right:10px;cursor:pointer"
19
- @click.passive.stop="searchs(item)">{{ item.contlistName }}</p>
20
- </div>
21
- </div>
22
- <div class="shopCart" @click="linkToShoppingCar()">
23
- <img
24
- alt=""
25
- src="http://b2bopt-dev2021122100000001.qjclouds.com//paas/shop/2021122100000001/2022-02-17/3eeb28fbd145464b92a3710b5f714c56.png"
26
- style="width:23px;height:23px"/>
27
- <p>我的购物车</p>
28
- </div>
29
- </div>
30
- </div>
2
+ <div class="container">
3
+ <div class="bac">
4
+ <div class="logo" @click="goHome">
5
+ <img :src="logo" alt="" srcset="" />
6
+ </div>
7
+ <div class="search">
8
+ <div class="searchTatol">
9
+ <!-- <div class="searchC"></div> -->
10
+ <input v-model="searchValue" placeholder="请输入关键字进行搜索" @keyup.enter="search(searchValue)" />
11
+ <div class="search_logo" @click.passive.stop="search(searchValue)">
12
+ <i class="el-icon-search t-24" style="color:white;"></i>
13
+ </div>
14
+ </div>
15
+ <div style="display:flex;color:#666666;font-size:14px">
16
+ <p>热门词搜索:</p>
17
+ <p v-for="(item, index) in searchWord[0]?searchWord[0].cmsContlistReDomainList:''" :key="index"
18
+ style="margin-right:10px;cursor:pointer" @click.passive.stop="searchs(item)">
19
+ {{ item.contlistName }}</p>
20
+ </div>
21
+ </div>
22
+ <div class="shopCart" @click="linkToShoppingCar()">
23
+ <img alt=""
24
+ src="http://b2bopt-dev2021122100000001.qjclouds.com//paas/shop/2021122100000001/2022-02-17/3eeb28fbd145464b92a3710b5f714c56.png"
25
+ style="width:23px;height:23px" />
26
+ <p>我的购物车</p>
27
+ </div>
28
+ </div>
29
+ </div>
31
30
  </template>
32
31
 
33
32
  <script>
34
- import {queryConttitleReDomainByCode} from '@/api/shopFbu.js'
35
-
36
- export default {
37
- data() {
38
- return {
39
- searchValue: '',
40
- searchWord: [],
41
- logo: '',
42
- hrefurl: process.env.API_ROOT,
43
- }
44
- },
45
- created() {
46
- this.logo = JSON.parse(sessionStorage.getItem('proappEnvLayout')).proappEnvLogo || '';
47
- let index1 = sessionStorage.getItem('index1');
48
- this.searchWord = [];
49
- if (index1) {
50
- index1 = JSON.parse(index1);
51
- index1.forEach((item) => {
52
- if (item.conttitleName == '热门搜索词') {
53
- this.searchWord.push(item)
54
- }
55
- })
56
- } else {
57
- queryConttitleReDomainByCode({tginfoMenuCode: 'index1'}).then((res) => {
58
- if (res) {
59
- res.forEach((item) => {
60
- if (item.conttitleName == '热门搜索词') {
61
- this.searchWord.push(item)
62
- }
63
- })
64
- }
65
- })
66
- }
67
- },
68
- methods: {
69
- search(code) {
70
- if (this.$route.query.hasOwnProperty('searchParam') && this.$route.path == '/searchResult') {
71
- this.$store.commit('SET_SEARCH_PARAM', code);
72
- } else {
73
- this.$router.push({
74
- path: '/searchResult',
75
- query: {
76
- searchParam: code
77
- }
78
- })
79
- }
80
- },
81
- searchs(item) {
82
- window.location = item.contlistUrl
83
- },
84
- goHome() {
85
- this.$router.push({
86
- path: '/islandStore'
87
- })
88
- },
89
- linkToShoppingCar() {
90
- this.$router.push({
91
- path: '/car'
92
- })
93
- },
94
- }
95
- }
33
+ import {
34
+ queryConttitleReDomainByCode
35
+ } from '#/api/apimanage.js'
36
+
37
+ export default {
38
+ data() {
39
+ return {
40
+ searchValue: '',
41
+ searchWord: [],
42
+ logo: '',
43
+ hrefurl: process.env.API_ROOT,
44
+ }
45
+ },
46
+ created() {
47
+ let proappEnvLayout = sessionStorage.getItem('proappEnvLayout') ? JSON.parse(sessionStorage.getItem('proappEnvLayout')) : null;
48
+ this.logo =proappEnvLayout ?'http://' + proappEnvLayout.proappEnvDomain + proappEnvLayout.proappEnvLogo : "http://opttest.lbaby1998.com/paas/shop/2021122100000001/2022-07-05/c4b2eeb72f834547920be58450fb07be.png";
49
+ let index1 = sessionStorage.getItem('index1');
50
+ this.searchWord = [];
51
+ if (index1) {
52
+ index1 = JSON.parse(index1);
53
+ index1.forEach((item) => {
54
+ if (item.conttitleName == '热门搜索词') {
55
+ this.searchWord.push(item)
56
+ }
57
+ })
58
+ } else {
59
+ queryConttitleReDomainByCode({
60
+ tginfoMenuCode: 'index1'
61
+ }).then((res) => {
62
+ if (res) {
63
+ res.forEach((item) => {
64
+ if (item.conttitleName == '热门搜索词') {
65
+ this.searchWord.push(item)
66
+ }
67
+ })
68
+ }
69
+ })
70
+ }
71
+ },
72
+ methods: {
73
+ search(code) {
74
+ if (this.$route.query.hasOwnProperty('searchParam') && this.$route.path == '/searchResult') {
75
+ this.$store.commit('SET_SEARCH_PARAM', code);
76
+ } else {
77
+ location.href = '/paas/b2b-cli-pc-ayd/index.html#/searchResult?searchParam=' + code
78
+ }
79
+ },
80
+ searchs(item) {
81
+ window.location = item.contlistUrl
82
+ },
83
+ goHome() {
84
+ location.href = this.hrefurl + `/paas/b2b-cli-pc-ayd/index.html#/islandStore`;
85
+ },
86
+ linkToShoppingCar() {
87
+ location.href = this.hrefurl + `/paas/b2b-cli-pc-ayd/index.html#/car`;
88
+ },
89
+ }
90
+ }
96
91
  </script>
97
92
 
98
93
  <style lang="scss" scoped>
99
- .container {
100
- background-color: #fff;
101
-
102
- .bac {
103
- width: 1200px;
104
- margin: 0 auto;
105
- height: 132px;
106
- display: flex;
107
- justify-content: space-between;
108
-
109
- .logo {
110
- width: 90px;
111
-
112
- img {
113
- width: 90px;
114
- cursor: pointer;
115
- }
116
- }
117
-
118
- .search {
119
- margin-top: 26px;
120
-
121
- .searchTatol {
122
- display: flex;
123
-
124
- input {
125
- text-indent: 16px;
126
- border: 1px solid #ed2f17;
127
- height: 42px;
128
- width: 510px;
129
- margin-bottom: 10px;
130
- }
131
-
132
- input::-webkit-input-placeholder {
133
- /*WebKit browsers*/
134
- color: #ccc;
135
- }
136
-
137
- input::-moz-input-placeholder {
138
- /*Mozilla Firefox*/
139
- color: #ccc;
140
- }
141
-
142
- input::-ms-input-placeholder {
143
- /*Internet Explorer*/
144
- color: #ccc;
145
- }
146
-
147
- .search_logo {
148
- cursor: pointer;
149
- background-color: #ed2f17;
150
- width: 80px;
151
- height: 44px;
152
- text-align: center;
153
- line-height: 50px;
154
-
155
- img {
156
- width: 23px;
157
- }
158
- }
159
- }
160
- }
161
-
162
- .shopCart {
163
- cursor: pointer;
164
- margin-top: 26px;
165
- display: flex;
166
- align-items: center;
167
- justify-content: center;
168
- color: #ed2f17;
169
- height: 42px;
170
- width: 180px;
171
- // background-color: red;
172
- border: 1px solid #ed2f17;
173
-
174
- p {
175
- font-size: 14px;
176
- margin-left: 10px;
177
- }
178
- }
179
- }
180
- }
94
+ .container {
95
+ background-color: #fff;
96
+
97
+ .bac {
98
+ width: 1200px;
99
+ margin: 0 auto;
100
+ height: 132px;
101
+ display: flex;
102
+ justify-content: space-between;
103
+
104
+ .logo {
105
+ width: 90px;
106
+
107
+ img {
108
+ width: 90px;
109
+ cursor: pointer;
110
+ }
111
+ }
112
+
113
+ .search {
114
+ margin-top: 26px;
115
+
116
+ .searchTatol {
117
+ display: flex;
118
+
119
+ input {
120
+ text-indent: 16px;
121
+ border: 1px solid #ed2f17;
122
+ height: 42px;
123
+ width: 510px;
124
+ margin-bottom: 10px;
125
+ }
126
+
127
+ input::-webkit-input-placeholder {
128
+ /*WebKit browsers*/
129
+ color: #ccc;
130
+ }
131
+
132
+ input::-moz-input-placeholder {
133
+ /*Mozilla Firefox*/
134
+ color: #ccc;
135
+ }
136
+
137
+ input::-ms-input-placeholder {
138
+ /*Internet Explorer*/
139
+ color: #ccc;
140
+ }
141
+
142
+ .search_logo {
143
+ cursor: pointer;
144
+ background-color: #ed2f17;
145
+ width: 80px;
146
+ height: 44px;
147
+ text-align: center;
148
+ line-height: 50px;
149
+
150
+ img {
151
+ width: 23px;
152
+ }
153
+ }
154
+ }
155
+ }
156
+
157
+ .shopCart {
158
+ cursor: pointer;
159
+ margin-top: 26px;
160
+ display: flex;
161
+ align-items: center;
162
+ justify-content: center;
163
+ color: #ed2f17;
164
+ height: 42px;
165
+ width: 180px;
166
+ // background-color: red;
167
+ border: 1px solid #ed2f17;
168
+
169
+ p {
170
+ font-size: 14px;
171
+ margin-left: 10px;
172
+ }
173
+ }
174
+ }
175
+ }
181
176
  </style>