package cn.pluss.platform.dto;

import cn.pluss.platform.entity.MemberOrder;
import cn.pluss.platform.entity.MerchantMenber;
import cn.pluss.platform.entity.MerchantMenberRecharge;
import io.swagger.annotations.ApiModelProperty;

/**
 * @author yuchen
 * 
 * @Description 
 */
public class MemberOrderDTO {
	
	@ApiModelProperty(value="商家code")
	private String merchantCode;
	
	@ApiModelProperty(value="商家名称")
	private String merchantName;
	
	@ApiModelProperty(value="门店Id")
	private String storeId;
	
	@ApiModelProperty(value="门店名称")
	private String storeName;
	
	@ApiModelProperty(value="订单编号")
	private String orderNumber;
	
	@ApiModelProperty(value="会员code")
	private String memberCode;
	
	@ApiModelProperty(value="昵称")
	private String nickName;
	
	@ApiModelProperty(value="订单金额")
	private String orderFee;
	
	@ApiModelProperty(value="赠送金额")
	private String giveMoney;
	
	@ApiModelProperty(value="收款人code")
	private String staffCode;
	
	@ApiModelProperty(value="收款人姓名")
	private String staffName;
	
	@ApiModelProperty(value="0 支付宝微信 通道  1乐刷")
	private String aisle;
	
	@ApiModelProperty(value="条码")
	private String authCode;
	
	
	public String getAuthCode() {
		return authCode;
	}
	public void setAuthCode(String authCode) {
		this.authCode = authCode;
	}
	public String getMerchantCode() {
		return merchantCode;
	}
	public void setMerchantCode(String merchantCode) {
		this.merchantCode = merchantCode;
	}
	public String getMerchantName() {
		return merchantName;
	}
	public void setMerchantName(String merchantName) {
		this.merchantName = merchantName;
	}
	public String getStoreId() {
		return storeId;
	}
	public void setStoreId(String storeId) {
		this.storeId = storeId;
	}
	public String getStoreName() {
		return storeName;
	}
	public void setStoreName(String storeName) {
		this.storeName = storeName;
	}
	public String getOrderNumber() {
		return orderNumber;
	}
	public void setOrderNumber(String orderNumber) {
		this.orderNumber = orderNumber;
	}
	public String getMemberCode() {
		return memberCode;
	}
	public void setMemberCode(String memberCode) {
		this.memberCode = memberCode;
	}
	public String getNickName() {
		return nickName;
	}
	public void setNickName(String nickName) {
		this.nickName = nickName;
	}
	public String getOrderFee() {
		return orderFee;
	}
	public void setOrderFee(String orderFee) {
		this.orderFee = orderFee;
	}
	public String getStaffCode() {
		return staffCode;
	}
	public void setStaffCode(String staffCode) {
		this.staffCode = staffCode;
	}
	public String getStaffName() {
		return staffName;
	}
	public void setStaffName(String staffName) {
		this.staffName = staffName;
	}
	public String getAisle() {
		return aisle;
	}
	public void setAisle(String aisle) {
		this.aisle = aisle;
	}
	
	public String getGiveMoney() {
		return giveMoney;
	}
	public void setGiveMoney(String giveMoney) {
		this.giveMoney = giveMoney;
	}
	public MemberOrder convertMemberOrder() {
		MemberOrder memberOrder=new MemberOrder();
		memberOrder.setOrderNumber(orderNumber);
		memberOrder.setMerchantCode(merchantCode);
		memberOrder.setMerchantName(merchantName);
		memberOrder.setStoreId(storeId);
		memberOrder.setStoreName(storeName);
		memberOrder.setMemberCode(memberCode);
		memberOrder.setNickName(nickName);
		memberOrder.setOrderType("1");
		memberOrder.setOrderFee(orderFee);
		memberOrder.setRechargeType("0");
		memberOrder.setStaffCode(staffCode);
		memberOrder.setStaffName(staffName);
		return memberOrder;
	}
	
	public MerchantMenberRecharge convertMerchantMenberRecharge(MerchantMenber menber) {
		MerchantMenberRecharge merchantMenberRecharge=new MerchantMenberRecharge();
		if(null!=giveMoney&&!"".equals(giveMoney)) {
			merchantMenberRecharge.setGiveMoney(Double.valueOf(giveMoney));
		}
		merchantMenberRecharge.setLogo(menber.getLogo());
		merchantMenberRecharge.setMemberCode(memberCode);
		merchantMenberRecharge.setMerchantCode(merchantCode);
		merchantMenberRecharge.setMerchantName(merchantName);
		merchantMenberRecharge.setNickName(nickName);
		merchantMenberRecharge.setOrderNumber(orderNumber);
		merchantMenberRecharge.setPhone(menber.getPhone());
		merchantMenberRecharge.setRechargeMoney(Double.valueOf(orderFee));
		merchantMenberRecharge.setStoreId(storeId);
		merchantMenberRecharge.setStoreName(storeName);
		return merchantMenberRecharge;
	}

}

