package market.Lms.FixedAssets.impl;

import java.text.SimpleDateFormat;
import java.util.Date;

import market.Com.pb.PbMethod;
import market.Lms.FixedAssets.mapper.LmsFixedAssetsCancleLineMapper;
import market.Lms.FixedAssets.service.LmsFixedAssetsCancleLineService;
import market.Lms.FixedAssets.vo.LmsFixedAssetsCancleLine;

import com.hnshituo.basic.service.impl.BaseServiceImpl;
import com.hnshituo.basic.spring.remoting.annotation.RemoteService;

@RemoteService(path="LmsFixedAssetsCancleLine")
public class LmsFixedAssetsCancleLineServiceImpl extends BaseServiceImpl<LmsFixedAssetsCancleLine,Object> implements LmsFixedAssetsCancleLineService{
	//新增
	public String doAdd(LmsFixedAssetsCancleLine line){
		String id = new SimpleDateFormat("yyyyMMddHHmmssSSS").format(new Date())+PbMethod.RandomCreate(3);
		line.setId(id);
		this.getMapper(LmsFixedAssetsCancleLineMapper.class).insert(line);
		return id;
	}

	//删除
	public void doDelete(LmsFixedAssetsCancleLine line){
		this.getMapper(LmsFixedAssetsCancleLineMapper.class).delete(line.getId());
	}

	//修改
	public void doUpdate(LmsFixedAssetsCancleLine line){
		this.getMapper(LmsFixedAssetsCancleLineMapper.class).update(line);
	}

	//查询
	public LmsFixedAssetsCancleLine doQuery(String lineNo){
		LmsFixedAssetsCancleLine line = new LmsFixedAssetsCancleLine();
		line = this.getMapper(LmsFixedAssetsCancleLineMapper.class).findById(lineNo);
		return line;
	}
}
