package com.goafanti.admin.service.impl;

import org.springframework.stereotype.Service;

import com.goafanti.admin.service.AttachmentService;
import com.goafanti.common.model.Attachment;
@Service
public class AttachmentServiceImpl implements AttachmentService {
	

	@Override
	public Attachment insert(Attachment f) {
//		aftFileMapper.insert(f);
		return f;
	}

	@Override
	public Attachment selectAftFileBySign(String sign) {
//		return aftFileMapper.selectAftFileBySign(sign);
		return null;
	}

	@Override
	public Attachment selectByReceivbles(String sign) {
		if (sign.equals("receivbles_template")) {
			Attachment a=new Attachment();
			a.setFileName("模板.xls");
			a.setFilePath("/tmp/receivbles_template.xls");
			return a;
		}else if (sign.equals("user_channel")) {
			Attachment a=new Attachment();
			a.setFileName("模板.xls");
			a.setFilePath("/tmp/user_channel.xls");
			return a;
		}
		return null;
	}
}
