com.seal.system.service.impl.SysOrderServiceImpl Maven / Gradle / Ivy
package com.seal.system.service.impl;
import com.seal.common.annotation.DataSource;
import com.seal.common.enums.DataSourceType;
import com.seal.system.domain.SysOrder;
import com.seal.system.mapper.SysOrderMapper;
import com.seal.system.service.ISysOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* 订单Service业务层处理
*
* @author silianpan
*/
@Service
public class SysOrderServiceImpl implements ISysOrderService {
@Autowired
private SysOrderMapper myShardingMapper;
/**
* 查询订单
*
* @param orderId 订单编号
* @return 订单信息
*/
@Override
@DataSource(DataSourceType.SHARDING)
public SysOrder selectSysOrderById(Long orderId) {
return myShardingMapper.selectSysOrderById(orderId);
}
/**
* 查询订单列表
*
* @param sysOrder 订单信息
* @return 订单列表
*/
@Override
@DataSource(DataSourceType.SHARDING)
public List selectSysOrderList(SysOrder sysOrder) {
return myShardingMapper.selectSysOrderList(sysOrder);
}
/**
* 新增订单
*
* @param sysOrder 订单
* @return 结果
*/
@Override
@DataSource(DataSourceType.SHARDING)
public int insertSysOrder(SysOrder sysOrder) {
return myShardingMapper.insertSysOrder(sysOrder);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy