|
@@ -152,7 +152,6 @@
|
|
themeClass: 'block',
|
|
themeClass: 'block',
|
|
show:false,
|
|
show:false,
|
|
userIdentity:'',
|
|
userIdentity:'',
|
|
- identity:2,
|
|
|
|
searchKeyType:1,
|
|
searchKeyType:1,
|
|
isShowClose:false, //是否显示清空输入框图标
|
|
isShowClose:false, //是否显示清空输入框图标
|
|
isSearchHistory:false,//是都显示搜索历史
|
|
isSearchHistory:false,//是都显示搜索历史
|
|
@@ -183,15 +182,12 @@
|
|
},
|
|
},
|
|
onLoad(option) {
|
|
onLoad(option) {
|
|
console.log(option)
|
|
console.log(option)
|
|
|
|
+
|
|
this.$api.getStorage().then((resolve) =>{
|
|
this.$api.getStorage().then((resolve) =>{
|
|
this.userID = resolve.userID ? resolve.userID : 0;
|
|
this.userID = resolve.userID ? resolve.userID : 0;
|
|
this.shopId = resolve.shopID ? resolve.shopID : 0;
|
|
this.shopId = resolve.shopID ? resolve.shopID : 0;
|
|
- this.userIdentity = resolve.userIdentity ? resolve.userIdentity : '';
|
|
|
|
- if(this.userIdentity == 1){
|
|
|
|
- this.listQuery.identity = 1
|
|
|
|
- }else{
|
|
|
|
- this.listQuery.identity = 2
|
|
|
|
- }
|
|
|
|
|
|
+ this.userIdentity = resolve.userIdentity;
|
|
|
|
+ this.listQuery.identity = this.identity;
|
|
if(option.keyWord){
|
|
if(option.keyWord){
|
|
this.listQuery.keyword = option.keyWord
|
|
this.listQuery.keyword = option.keyWord
|
|
this.setSearchHistoryAdd()
|
|
this.setSearchHistoryAdd()
|
|
@@ -209,7 +205,7 @@
|
|
},
|
|
},
|
|
},
|
|
},
|
|
computed: {
|
|
computed: {
|
|
- ...mapState(['hasLogin','userInfo'])
|
|
|
|
|
|
+ ...mapState(['hasLogin','userInfo','identity'])
|
|
},
|
|
},
|
|
methods:{
|
|
methods:{
|
|
initGetSerachRecord(){//查询搜索历史记录
|
|
initGetSerachRecord(){//查询搜索历史记录
|
|
@@ -221,7 +217,7 @@
|
|
},
|
|
},
|
|
subMitSearch() {//搜索
|
|
subMitSearch() {//搜索
|
|
if (this.listQuery.keyword == '') {
|
|
if (this.listQuery.keyword == '') {
|
|
- this.$util.msg('请输入商品关键词',2000);
|
|
|
|
|
|
+ this.$util.msg('请输入搜索关键词',2000);
|
|
}else{
|
|
}else{
|
|
switch(this.searchKeyType){
|
|
switch(this.searchKeyType){
|
|
case 1:
|
|
case 1:
|
|
@@ -708,6 +704,7 @@
|
|
padding:0 16rpx;
|
|
padding:0 16rpx;
|
|
font-size: $font-size-20;
|
|
font-size: $font-size-20;
|
|
margin-left: 15rpx;
|
|
margin-left: 15rpx;
|
|
|
|
+ margin-top:15px;
|
|
border: 1px solid #E15616;
|
|
border: 1px solid #E15616;
|
|
float: right;
|
|
float: right;
|
|
}
|
|
}
|