mirror of
https://gitee.com/dromara/RuoYi-Cloud-Plus.git
synced 2026-05-13 15:12:09 +08:00
update 优化 调整模块结构 细化core模块
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
package org.dromara.common.web.core;
|
||||
|
||||
import org.dromara.common.core.domain.R;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
/**
|
||||
* web层通用数据处理
|
||||
*
|
||||
* @author Lion Li
|
||||
*/
|
||||
@Slf4j
|
||||
public class BaseController {
|
||||
|
||||
/**
|
||||
* 响应返回结果
|
||||
*
|
||||
* @param rows 影响行数
|
||||
* @return 操作结果
|
||||
*/
|
||||
protected R<Void> toAjax(int rows) {
|
||||
return rows > 0 ? R.ok() : R.fail();
|
||||
}
|
||||
|
||||
/**
|
||||
* 响应返回结果
|
||||
*
|
||||
* @param result 结果
|
||||
* @return 操作结果
|
||||
*/
|
||||
protected R<Void> toAjax(boolean result) {
|
||||
return result ? R.ok() : R.fail();
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user