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
ab91a8e2
Commit
ab91a8e2
authored
Jul 22, 2018
by
Menethil
Browse files
修复搜索时未判断删除标记的物品
parent
7bb5f76b
Changes
3
Hide whitespace changes
Inline
Side-by-side
litemall-core/src/main/java/org/linlinjava/litemall/core/storage/StorageService.java
View file @
ab91a8e2
...
...
@@ -7,6 +7,9 @@ import java.nio.file.Path;
import
java.util.Map
;
import
java.util.stream.Stream
;
/**
* 提供存储服务类,所有存储服务均由该类对外提供
*/
public
class
StorageService
{
private
String
active
;
private
Storage
storage
;
...
...
@@ -31,8 +34,9 @@ public class StorageService {
/**
* 存储一个文件对象
* @param file SpringBoot MultipartFile文件对象
* @param keyName 文件索引名
*
* @param file SpringBoot MultipartFile文件对象
* @param keyName 文件索引名
*/
public
void
store
(
MultipartFile
file
,
String
keyName
)
{
storage
.
store
(
file
,
keyName
);
...
...
@@ -46,11 +50,11 @@ public class StorageService {
return
storage
.
load
(
keyName
);
}
public
Resource
loadAsResource
(
String
keyName
){
public
Resource
loadAsResource
(
String
keyName
)
{
return
storage
.
loadAsResource
(
keyName
);
}
public
void
delete
(
String
keyName
){
public
void
delete
(
String
keyName
)
{
storage
.
delete
(
keyName
);
}
...
...
litemall-core/src/main/java/org/linlinjava/litemall/core/storage/config/StorageAutoConfiguration.java
View file @
ab91a8e2
package
org.linlinjava.litemall.core.storage.config
;
import
org.apache.commons.collections.map.HashedMap
;
import
org.linlinjava.litemall.core.storage.*
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.context.annotation.Bean
;
...
...
litemall-db/src/main/java/org/linlinjava/litemall/db/service/LitemallGoodsService.java
View file @
ab91a8e2
...
...
@@ -79,6 +79,7 @@ public class LitemallGoodsService {
LitemallGoodsExample
.
Criteria
criteria2
=
example
.
createCriteria
();
criteria2
.
andNameLike
(
"%"
+
keyword
+
"%"
);
criteria2
.
andDeletedEqualTo
(
false
);
example
.
or
(
criteria2
);
}
criteria
.
andDeletedEqualTo
(
false
);
...
...
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