Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
Litemall
Commits
8cf5b8f7
Commit
8cf5b8f7
authored
Aug 19, 2018
by
Junling Bu
Browse files
fix[litemall-admin]: 修复商品页面和分类页面的关键字是keywords
parent
acb456aa
Changes
4
Hide whitespace changes
Inline
Side-by-side
litemall-admin/src/views/goods/list.vue
View file @
8cf5b8f7
...
@@ -28,7 +28,7 @@
...
@@ -28,7 +28,7 @@
<span>
{{
props
.
row
.
unit
}}
</span>
<span>
{{
props
.
row
.
unit
}}
</span>
</el-form-item>
</el-form-item>
<el-form-item
label=
"关键字"
>
<el-form-item
label=
"关键字"
>
<span>
{{
props
.
row
.
keyword
}}
</span>
<span>
{{
props
.
row
.
keyword
s
}}
</span>
</el-form-item>
</el-form-item>
<el-form-item
label=
"类目ID"
>
<el-form-item
label=
"类目ID"
>
<span>
{{
props
.
row
.
categoryId
}}
</span>
<span>
{{
props
.
row
.
categoryId
}}
</span>
...
...
litemall-admin/src/views/mall/category.vue
View file @
8cf5b8f7
...
@@ -33,7 +33,7 @@
...
@@ -33,7 +33,7 @@
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
align=
"center"
label=
"关键字"
prop=
"keyword"
>
<el-table-column
align=
"center"
label=
"关键字"
prop=
"keyword
s
"
>
</el-table-column>
</el-table-column>
<el-table-column
align=
"center"
min-width=
"100"
label=
"简介"
prop=
"desc"
>
<el-table-column
align=
"center"
min-width=
"100"
label=
"简介"
prop=
"desc"
>
...
@@ -70,8 +70,8 @@
...
@@ -70,8 +70,8 @@
<el-form-item
label=
"类目名称"
prop=
"name"
>
<el-form-item
label=
"类目名称"
prop=
"name"
>
<el-input
v-model=
"dataForm.name"
></el-input>
<el-input
v-model=
"dataForm.name"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"关键字"
prop=
"keyword"
>
<el-form-item
label=
"关键字"
prop=
"keyword
s
"
>
<el-input
v-model=
"dataForm.keyword"
></el-input>
<el-input
v-model=
"dataForm.keyword
s
"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"级别"
prop=
"level"
>
<el-form-item
label=
"级别"
prop=
"level"
>
<el-select
v-model=
"dataForm.level"
@
change=
"onLevelChange"
>
<el-select
v-model=
"dataForm.level"
@
change=
"onLevelChange"
>
...
@@ -171,7 +171,7 @@ export default {
...
@@ -171,7 +171,7 @@ export default {
dataForm
:
{
dataForm
:
{
id
:
undefined
,
id
:
undefined
,
name
:
''
,
name
:
''
,
keyword
:
''
,
keyword
s
:
''
,
level
:
'
L2
'
,
level
:
'
L2
'
,
pid
:
undefined
,
pid
:
undefined
,
desc
:
''
,
desc
:
''
,
...
@@ -228,7 +228,7 @@ export default {
...
@@ -228,7 +228,7 @@ export default {
this
.
dataForm
=
{
this
.
dataForm
=
{
id
:
undefined
,
id
:
undefined
,
name
:
''
,
name
:
''
,
keyword
:
''
,
keyword
s
:
''
,
level
:
'
L2
'
,
level
:
'
L2
'
,
pid
:
undefined
,
pid
:
undefined
,
desc
:
''
,
desc
:
''
,
...
@@ -320,7 +320,7 @@ export default {
...
@@ -320,7 +320,7 @@ export default {
this
.
downloadLoading
=
true
this
.
downloadLoading
=
true
import
(
'
@/vendor/Export2Excel
'
).
then
(
excel
=>
{
import
(
'
@/vendor/Export2Excel
'
).
then
(
excel
=>
{
const
tHeader
=
[
'
类目ID
'
,
'
名称
'
,
'
关键字
'
,
'
级别
'
,
'
父类目ID
'
,
'
类目图标
'
,
'
类目图片
'
,
'
简介
'
]
const
tHeader
=
[
'
类目ID
'
,
'
名称
'
,
'
关键字
'
,
'
级别
'
,
'
父类目ID
'
,
'
类目图标
'
,
'
类目图片
'
,
'
简介
'
]
const
filterVal
=
[
'
id
'
,
'
name
'
,
'
keyword
'
,
'
level
'
,
'
pid
'
,
'
iconUrl
'
,
'
picUrl
'
,
'
desc
'
]
const
filterVal
=
[
'
id
'
,
'
name
'
,
'
keyword
s
'
,
'
level
'
,
'
pid
'
,
'
iconUrl
'
,
'
picUrl
'
,
'
desc
'
]
excel
.
export_json_to_excel2
(
tHeader
,
this
.
list
,
filterVal
,
'
商品类目信息
'
)
excel
.
export_json_to_excel2
(
tHeader
,
this
.
list
,
filterVal
,
'
商品类目信息
'
)
this
.
downloadLoading
=
false
this
.
downloadLoading
=
false
})
})
...
...
litemall-admin/src/views/mall/region.vue
View file @
8cf5b8f7
...
@@ -48,7 +48,7 @@
...
@@ -48,7 +48,7 @@
import
{
listRegion
}
from
'
@/api/region
'
import
{
listRegion
}
from
'
@/api/region
'
export
default
{
export
default
{
name
:
'
Keyword
'
,
name
:
'
Region
'
,
data
()
{
data
()
{
return
{
return
{
list
:
undefined
,
list
:
undefined
,
...
...
litemall-db/src/main/java/org/linlinjava/litemall/db/service/LitemallGoodsService.java
View file @
8cf5b8f7
...
@@ -87,7 +87,7 @@ public class LitemallGoodsService {
...
@@ -87,7 +87,7 @@ public class LitemallGoodsService {
}
}
public
List
<
LitemallGoods
>
querySelective
(
Integer
catId
,
Integer
brandId
,
String
keyword
,
Boolean
isHot
,
Boolean
isNew
,
Integer
offset
,
Integer
limit
,
String
sort
,
String
order
)
{
public
List
<
LitemallGoods
>
querySelective
(
Integer
catId
,
Integer
brandId
,
String
keyword
s
,
Boolean
isHot
,
Boolean
isNew
,
Integer
offset
,
Integer
limit
,
String
sort
,
String
order
)
{
LitemallGoodsExample
example
=
new
LitemallGoodsExample
();
LitemallGoodsExample
example
=
new
LitemallGoodsExample
();
LitemallGoodsExample
.
Criteria
criteria1
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria1
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria2
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria2
=
example
.
or
();
...
@@ -108,9 +108,9 @@ public class LitemallGoodsService {
...
@@ -108,9 +108,9 @@ public class LitemallGoodsService {
criteria1
.
andIsHotEqualTo
(
isHot
);
criteria1
.
andIsHotEqualTo
(
isHot
);
criteria2
.
andIsHotEqualTo
(
isHot
);
criteria2
.
andIsHotEqualTo
(
isHot
);
}
}
if
(!
StringUtils
.
isEmpty
(
keyword
))
{
if
(!
StringUtils
.
isEmpty
(
keyword
s
))
{
criteria1
.
andKeywordsLike
(
"%"
+
keyword
+
"%"
);
criteria1
.
andKeywordsLike
(
"%"
+
keyword
s
+
"%"
);
criteria2
.
andNameLike
(
"%"
+
keyword
+
"%"
);
criteria2
.
andNameLike
(
"%"
+
keyword
s
+
"%"
);
}
}
criteria1
.
andDeletedEqualTo
(
false
);
criteria1
.
andDeletedEqualTo
(
false
);
criteria2
.
andDeletedEqualTo
(
false
);
criteria2
.
andDeletedEqualTo
(
false
);
...
@@ -126,7 +126,7 @@ public class LitemallGoodsService {
...
@@ -126,7 +126,7 @@ public class LitemallGoodsService {
return
goodsMapper
.
selectByExampleSelective
(
example
,
columns
);
return
goodsMapper
.
selectByExampleSelective
(
example
,
columns
);
}
}
public
int
countSelective
(
Integer
catId
,
Integer
brandId
,
String
keyword
,
Boolean
isHot
,
Boolean
isNew
,
Integer
offset
,
Integer
limit
,
String
sort
,
String
order
)
{
public
int
countSelective
(
Integer
catId
,
Integer
brandId
,
String
keyword
s
,
Boolean
isHot
,
Boolean
isNew
,
Integer
offset
,
Integer
limit
,
String
sort
,
String
order
)
{
LitemallGoodsExample
example
=
new
LitemallGoodsExample
();
LitemallGoodsExample
example
=
new
LitemallGoodsExample
();
LitemallGoodsExample
.
Criteria
criteria1
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria1
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria2
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria2
=
example
.
or
();
...
@@ -147,9 +147,9 @@ public class LitemallGoodsService {
...
@@ -147,9 +147,9 @@ public class LitemallGoodsService {
criteria1
.
andIsHotEqualTo
(
isHot
);
criteria1
.
andIsHotEqualTo
(
isHot
);
criteria2
.
andIsHotEqualTo
(
isHot
);
criteria2
.
andIsHotEqualTo
(
isHot
);
}
}
if
(!
StringUtils
.
isEmpty
(
keyword
))
{
if
(!
StringUtils
.
isEmpty
(
keyword
s
))
{
criteria1
.
andKeywordsLike
(
"%"
+
keyword
+
"%"
);
criteria1
.
andKeywordsLike
(
"%"
+
keyword
s
+
"%"
);
criteria2
.
andNameLike
(
"%"
+
keyword
+
"%"
);
criteria2
.
andNameLike
(
"%"
+
keyword
s
+
"%"
);
}
}
return
(
int
)
goodsMapper
.
countByExample
(
example
);
return
(
int
)
goodsMapper
.
countByExample
(
example
);
...
@@ -240,7 +240,7 @@ public class LitemallGoodsService {
...
@@ -240,7 +240,7 @@ public class LitemallGoodsService {
return
(
int
)
goodsMapper
.
countByExample
(
example
);
return
(
int
)
goodsMapper
.
countByExample
(
example
);
}
}
public
List
<
Integer
>
getCatIds
(
Integer
brandId
,
String
keyword
,
Boolean
isHot
,
Boolean
isNew
)
{
public
List
<
Integer
>
getCatIds
(
Integer
brandId
,
String
keyword
s
,
Boolean
isHot
,
Boolean
isNew
)
{
LitemallGoodsExample
example
=
new
LitemallGoodsExample
();
LitemallGoodsExample
example
=
new
LitemallGoodsExample
();
LitemallGoodsExample
.
Criteria
criteria1
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria1
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria2
=
example
.
or
();
LitemallGoodsExample
.
Criteria
criteria2
=
example
.
or
();
...
@@ -260,9 +260,9 @@ public class LitemallGoodsService {
...
@@ -260,9 +260,9 @@ public class LitemallGoodsService {
criteria1
.
andIsHotEqualTo
(
isHot
);
criteria1
.
andIsHotEqualTo
(
isHot
);
criteria2
.
andIsHotEqualTo
(
isHot
);
criteria2
.
andIsHotEqualTo
(
isHot
);
}
}
if
(!
StringUtils
.
isEmpty
(
keyword
))
{
if
(!
StringUtils
.
isEmpty
(
keyword
s
))
{
criteria1
.
andKeywordsLike
(
"%"
+
keyword
+
"%"
);
criteria1
.
andKeywordsLike
(
"%"
+
keyword
s
+
"%"
);
criteria2
.
andNameLike
(
"%"
+
keyword
+
"%"
);
criteria2
.
andNameLike
(
"%"
+
keyword
s
+
"%"
);
}
}
List
<
LitemallGoods
>
goodsList
=
goodsMapper
.
selectByExampleSelective
(
example
,
Column
.
categoryId
);
List
<
LitemallGoods
>
goodsList
=
goodsMapper
.
selectByExampleSelective
(
example
,
Column
.
categoryId
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment