处理keyword的bug
This commit is contained in:
+2
-14
@@ -77,7 +77,6 @@ public class SysDictController {
|
|||||||
private static final String DEL_SUCCESS = "删除成功!";
|
private static final String DEL_SUCCESS = "删除成功!";
|
||||||
|
|
||||||
@GetMapping("/page")
|
@GetMapping("/page")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
@ApiOperation(value = "字典控制器-分页列表查询", notes = "字典控制器-分页列表查询")
|
@ApiOperation(value = "字典控制器-分页列表查询", notes = "字典控制器-分页列表查询")
|
||||||
public Results<IPage<SysDict>> queryPageList(SysDict sysDict, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
public Results<IPage<SysDict>> queryPageList(SysDict sysDict, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) {
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) {
|
||||||
@@ -104,7 +103,6 @@ public class SysDictController {
|
|||||||
*/
|
*/
|
||||||
@ApiOperation(value = "字典控制器-树形字典数据", notes = "字典控制器-树形字典数据")
|
@ApiOperation(value = "字典控制器-树形字典数据", notes = "字典控制器-树形字典数据")
|
||||||
@GetMapping("/treeList")
|
@GetMapping("/treeList")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<SysDictTree>> treeList(SysDict sysDict, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
public Results<List<SysDictTree>> treeList(SysDict sysDict, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) {
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) {
|
||||||
Results<List<SysDictTree>> result = new Results<>();
|
Results<List<SysDictTree>> result = new Results<>();
|
||||||
@@ -132,7 +130,6 @@ public class SysDictController {
|
|||||||
*/
|
*/
|
||||||
@ApiOperation(value = "字典控制器-获取全部字典数据", notes = "字典控制器-获取全部字典数据")
|
@ApiOperation(value = "字典控制器-获取全部字典数据", notes = "字典控制器-获取全部字典数据")
|
||||||
@GetMapping("/queryAllDictItems")
|
@GetMapping("/queryAllDictItems")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<Map<String, List<DictModel>>> queryAllDictItems(HttpServletRequest request) {
|
public Results<Map<String, List<DictModel>>> queryAllDictItems(HttpServletRequest request) {
|
||||||
Map<String, List<DictModel>> res ;
|
Map<String, List<DictModel>> res ;
|
||||||
res = sysDictService.queryAllDictItems();
|
res = sysDictService.queryAllDictItems();
|
||||||
@@ -146,7 +143,6 @@ public class SysDictController {
|
|||||||
*/
|
*/
|
||||||
@ApiOperation(value = "字典控制器-通过字典code和字典值key获取字典数据", notes = "字典控制器-通过字典code和字典值key获取字典数据")
|
@ApiOperation(value = "字典控制器-通过字典code和字典值key获取字典数据", notes = "字典控制器-通过字典code和字典值key获取字典数据")
|
||||||
@GetMapping("/getDictText/{dictCode}/{key}")
|
@GetMapping("/getDictText/{dictCode}/{key}")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<String> getDictText(@PathVariable("dictCode") String dictCode, @PathVariable("key") String key) {
|
public Results<String> getDictText(@PathVariable("dictCode") String dictCode, @PathVariable("key") String key) {
|
||||||
log.info(" dictCode : "+ dictCode);
|
log.info(" dictCode : "+ dictCode);
|
||||||
Results<String> result = new Results<>();
|
Results<String> result = new Results<>();
|
||||||
@@ -169,7 +165,6 @@ public class SysDictController {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping("/getDictItems/{dictCode}")
|
@GetMapping("/getDictItems/{dictCode}")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<DictModel>> getDictItems(@PathVariable String dictCode, @RequestParam(value = "sign",required = false) String sign, HttpServletRequest request) {
|
public Results<List<DictModel>> getDictItems(@PathVariable String dictCode, @RequestParam(value = "sign",required = false) String sign, HttpServletRequest request) {
|
||||||
log.info(" dictCode : "+ dictCode);
|
log.info(" dictCode : "+ dictCode);
|
||||||
Results<List<DictModel>> result = new Results<>();
|
Results<List<DictModel>> result = new Results<>();
|
||||||
@@ -196,9 +191,8 @@ public class SysDictController {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping("/loadDict/{dictCode}")
|
@GetMapping("/loadDict/{dictCode}")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<DictModel>> loadDict(@PathVariable String dictCode,
|
public Results<List<DictModel>> loadDict(@PathVariable String dictCode,
|
||||||
@RequestParam(name="keyword") String keyword,
|
@RequestParam(name="keyword",required = false) String keyword,
|
||||||
@RequestParam(value = "sign",required = false) String sign,
|
@RequestParam(value = "sign",required = false) String sign,
|
||||||
@RequestParam(value = "pageSize", required = false) Integer pageSize) {
|
@RequestParam(value = "pageSize", required = false) Integer pageSize) {
|
||||||
log.info(" 加载字典表数据,加载关键字: "+ keyword);
|
log.info(" 加载字典表数据,加载关键字: "+ keyword);
|
||||||
@@ -227,10 +221,9 @@ public class SysDictController {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping("/loadDictOrderByValue/{dictCode}")
|
@GetMapping("/loadDictOrderByValue/{dictCode}")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<DictModel>> loadDictOrderByValue(
|
public Results<List<DictModel>> loadDictOrderByValue(
|
||||||
@PathVariable String dictCode,
|
@PathVariable String dictCode,
|
||||||
@RequestParam(name = "keyword") String keyword,
|
@RequestParam(name = "keyword",required = false) String keyword,
|
||||||
@RequestParam(value = "sign", required = false) String sign,
|
@RequestParam(value = "sign", required = false) String sign,
|
||||||
@RequestParam(value = "pageSize", required = false) Integer pageSize) {
|
@RequestParam(value = "pageSize", required = false) Integer pageSize) {
|
||||||
// 首次查询查出来用户选中的值,并且不分页
|
// 首次查询查出来用户选中的值,并且不分页
|
||||||
@@ -270,7 +263,6 @@ public class SysDictController {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping("/loadDictItem/{dictCode}")
|
@GetMapping("/loadDictItem/{dictCode}")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<String>> loadDictItem(@PathVariable String dictCode, @RequestParam(name="key") String keys, @RequestParam(value = "sign",required = false) String sign, @RequestParam(value = "delNotExist",required = false,defaultValue = "true") boolean delNotExist, HttpServletRequest request) {
|
public Results<List<String>> loadDictItem(@PathVariable String dictCode, @RequestParam(name="key") String keys, @RequestParam(value = "sign",required = false) String sign, @RequestParam(value = "delNotExist",required = false,defaultValue = "true") boolean delNotExist, HttpServletRequest request) {
|
||||||
Results<List<String>> result = new Results<>();
|
Results<List<String>> result = new Results<>();
|
||||||
try {
|
try {
|
||||||
@@ -301,7 +293,6 @@ public class SysDictController {
|
|||||||
*/
|
*/
|
||||||
@ApiOperation(value = "字典控制器-根据表名—显示字段-存储字段 pid 加载树形数据", notes = "字典控制器-根据表名—显示字段-存储字段 pid 加载树形数据")
|
@ApiOperation(value = "字典控制器-根据表名—显示字段-存储字段 pid 加载树形数据", notes = "字典控制器-根据表名—显示字段-存储字段 pid 加载树形数据")
|
||||||
@GetMapping("/loadTreeData")
|
@GetMapping("/loadTreeData")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<TreeSelectModel>> loadTreeData(@RequestParam(name="pid") String pid, @RequestParam(name="pidField") String pidField,
|
public Results<List<TreeSelectModel>> loadTreeData(@RequestParam(name="pid") String pid, @RequestParam(name="pidField") String pidField,
|
||||||
@RequestParam(name="tableName") String tbname,
|
@RequestParam(name="tableName") String tbname,
|
||||||
@RequestParam(name="text") String text,
|
@RequestParam(name="text") String text,
|
||||||
@@ -324,7 +315,6 @@ public class SysDictController {
|
|||||||
*/
|
*/
|
||||||
@ApiOperation(value = "字典控制器-根据表名—显示字段-存储字段 加载树形数据", notes = "字典控制器-根据表名—显示字段-存储字段 加载树形数据")
|
@ApiOperation(value = "字典控制器-根据表名—显示字段-存储字段 加载树形数据", notes = "字典控制器-根据表名—显示字段-存储字段 加载树形数据")
|
||||||
@GetMapping("/queryAllTreeData")
|
@GetMapping("/queryAllTreeData")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<TreeSelectModel>> queryAllTreeData(@RequestParam(name="pidField") String pidField,
|
public Results<List<TreeSelectModel>> queryAllTreeData(@RequestParam(name="pidField") String pidField,
|
||||||
@RequestParam(name="tableName") String tbname,
|
@RequestParam(name="tableName") String tbname,
|
||||||
@RequestParam(name="text") String text,
|
@RequestParam(name="text") String text,
|
||||||
@@ -433,7 +423,6 @@ public class SysDictController {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/refleshCache")
|
@RequestMapping(value = "/refleshCache")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<SysDict> refleshCache() {
|
public Results<SysDict> refleshCache() {
|
||||||
Results<SysDict> result = new Results<>();
|
Results<SysDict> result = new Results<>();
|
||||||
sysDictService.refreshCache();
|
sysDictService.refreshCache();
|
||||||
@@ -553,7 +542,6 @@ public class SysDictController {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping(value = "/deleteList")
|
@GetMapping(value = "/deleteList")
|
||||||
@RequiresPermissions("dict:list")
|
|
||||||
public Results<List<SysDict>> deleteList() {
|
public Results<List<SysDict>> deleteList() {
|
||||||
List<SysDict> list = this.sysDictService.queryDeleteList();
|
List<SysDict> list = this.sysDictService.queryDeleteList();
|
||||||
return Results.OK(list);
|
return Results.OK(list);
|
||||||
|
|||||||
-1
@@ -51,7 +51,6 @@ public class SysDictItemController {
|
|||||||
* @param req
|
* @param req
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("sys:dict:list")
|
|
||||||
@GetMapping("/page")
|
@GetMapping("/page")
|
||||||
public Results<IPage<SysDictItem>> queryPageList(SysDictItem sysDictItem, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
public Results<IPage<SysDictItem>> queryPageList(SysDictItem sysDictItem, @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) {
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize, HttpServletRequest req) {
|
||||||
|
|||||||
+1
-1
@@ -473,7 +473,7 @@ public class LoginServiceImpl implements ILoginService {
|
|||||||
String privateKeyBase64 = rsa.getPrivateKeyBase64();
|
String privateKeyBase64 = rsa.getPrivateKeyBase64();
|
||||||
String publicKeyBase64 = rsa.getPublicKeyBase64();
|
String publicKeyBase64 = rsa.getPublicKeyBase64();
|
||||||
//存到redis key为公钥 value为私钥,3分钟
|
//存到redis key为公钥 value为私钥,3分钟
|
||||||
redisUtil.set(publicKeyBase64, privateKeyBase64, 10L);
|
redisUtil.set(publicKeyBase64, privateKeyBase64, 180L);
|
||||||
Results<String> result = new Results<>();
|
Results<String> result = new Results<>();
|
||||||
result.setResult(publicKeyBase64);
|
result.setResult(publicKeyBase64);
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
@@ -184,16 +184,20 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// 异步一开始也加载一点数据
|
if (!this.dict) {
|
||||||
this.loading = true
|
console.error('搜索组件未配置字典项')
|
||||||
getAction(`/sys/dict/loadDict/${this.dict}`, { pageSize: this.pageSize, keyword: '' }).then(res => {
|
} else {
|
||||||
this.loading = false
|
// 异步一开始也加载一点数据
|
||||||
if (res.success) {
|
this.loading = true
|
||||||
this.options = res.result
|
getAction(`/sys/dict/loadDict/${this.dict}`, { pageSize: this.pageSize, keyword: '' }).then(res => {
|
||||||
} else {
|
this.loading = false
|
||||||
this.$message.warning(res.message)
|
if (res.success) {
|
||||||
}
|
this.options = res.result
|
||||||
})
|
} else {
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
filterOption (input, option) {
|
filterOption (input, option) {
|
||||||
|
|||||||
@@ -175,6 +175,7 @@ export default {
|
|||||||
},
|
},
|
||||||
// 异步加载树节点
|
// 异步加载树节点
|
||||||
asyncLoadTreeData (treeNode) {
|
asyncLoadTreeData (treeNode) {
|
||||||
|
debugger
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
if (treeNode.$vnode.children) {
|
if (treeNode.$vnode.children) {
|
||||||
resolve()
|
resolve()
|
||||||
|
|||||||
Reference in New Issue
Block a user