package ${packageName}.admin.api.${moduleName};


import ${packageName}.data.domain.${moduleName}.${ClassName};
import com.iotechn.unimall.core.annotation.HttpMethod;
import com.iotechn.unimall.core.annotation.HttpOpenApi;
import com.iotechn.unimall.core.annotation.HttpParam;
import com.iotechn.unimall.core.annotation.HttpParamType;
import com.iotechn.unimall.core.annotation.param.NotNull;
import com.iotechn.unimall.core.exception.ServiceException;
import com.iotechn.unimall.data.model.Page;
import java.util.Date;

/**
 * ${functionName}Service接口
 * 
 * @author ${author}
 * @date ${datetime}
 */
@HttpOpenApi(group = "admin.${moduleName}.${className}", description = "${functionName}")
public interface I${ClassName}Service{
	@HttpMethod(description = "新增",   permissionName = "${functionName}管理")
	public Boolean add(@NotNull @HttpParam(name = "${className}", type = HttpParamType.COMMON, description = "${functionName}") ${ClassName} ${className})throws ServiceException;

	@HttpMethod(description = "列表", permissionName = "${functionName}管理")
	public Page<${ClassName}> list(
	#foreach ($column in $columns)
		#if($column.isQuery==1)
		@HttpParam(name = "$column.javaField", type = HttpParamType.COMMON, description = "$column.columnComment") $column.javaType $column.javaField,
		#end
	#end
		@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
		@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)
		throws ServiceException;

	@HttpMethod(description = "删除",permissionName = "${functionName}管理")
	public Boolean delete(@NotNull @HttpParam(name = "${pkColumn.javaField}", type = HttpParamType.COMMON, description = "${pkColumn.columnComment}")String ${pkColumn.javaField})throws ServiceException;

	@HttpMethod(description = "修改",  permissionName = "${functionName}管理")
	public Boolean update(@NotNull @HttpParam(name = "${className}", type = HttpParamType.COMMON, description = "${functionName}") ${ClassName} ${className})throws ServiceException;

	@HttpMethod(description = "查询", permissionName = "${functionName}管理")
	public ${ClassName} get(@NotNull @HttpParam(name = "${pkColumn.javaField}", type = HttpParamType.COMMON, description = "${pkColumn.columnComment}")${pkColumn.javaType} ${pkColumn.javaField})throws ServiceException;
	
	@HttpMethod(description = "导出excl表",  permissionName = "${functionName}管理")
	public String export(
	#foreach ($column in $columns)
		#if($column.isQuery==1)
		@HttpParam(name = "$column.javaField", type = HttpParamType.COMMON, description = "$column.columnComment") $column.javaType $column.javaField,
		#end
	#end 
	@HttpParam(name = "page", type = HttpParamType.COMMON, description = "页码", valueDef = "1") Integer page,
	@HttpParam(name = "limit", type = HttpParamType.COMMON, description = "页码长度", valueDef = "20") Integer limit)throws ServiceException;
	
}
