package com.tarena.oss.web.forms;

import java.util.Date;

import org.apache.struts.action.ActionForm;

import com.tarena.oss.userservice.pojo.UserService;
import com.tarena.oss.userservice.pojo.UserServiceCondDTO;
import com.tarena.oss.userservice.service.UserServiceMgmtService;

public class UserServicesForm extends ActionForm{
	private UserService us = new UserService();
	private Integer id;
	private Integer userid;
	private String loginname;
	private String loginpassword;
	private String labip;
	private int status;
	private Integer priceid;
	private Date enrolldate;
	private Date closedate;
	
	private UserServiceMgmtService service;
	public void setService(UserServiceMgmtService service) {
		this.service = service;
	}
	
	
	public Date getClosedate() {
		return us.getClosedate();
	}
	public void setClosedate(Date closedate) {
		us.setClosedate(closedate);
	}
	public Date getEnrolldate() {
		return us.getEnrolldate();
	}
	public void setEnrolldate(Date enrolldate) {
		us.setEnrolldate(enrolldate);
	}
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getLabip() {
		return us.getLabip();
	}
	public void setLabip(String labip) {
		us.setLabip(labip);
	}
	public String getLoginname() {
		return us.getLoginname();
	}
	public void setLoginname(String loginname) {
		us.setLoginname(loginname);
	}
	public String getLoginpassword() {
		return us.getLoginpassword();
	}
	public void setLoginpassword(String loginpassword) {
		us.setLoginpassword(loginpassword);
	}
	
	public int getStatus() {
		return us.getStatus();
	}
	public void setStatus(int status) {
		us.setStatus(status);
	}
	public UserService getUs() {
		return us;
	}
	public void setUs(UserService us) {
		this.us = us;
	}
	
	public Integer getPriceid() {
		return us.getPricing().getId();
	}
	public void setPriceid(Integer priceid) {
		this.priceid = priceid;
		service.findUserService(priceid);
	}
	public Integer getUserid() {
		return us.getUser().getId();
	}
	public void setUserid(Integer userid) {
		this.userid = userid;
		service.findUserService(userid);
		
	}

	public UserServicesForm() {
	}
	
	public String toString() {
		return "UserServicesForm:["+id+", "+userid+", "+loginname+", "+loginpassword+", "+labip+", "+status+", "+priceid+"]";
//		return "UserServicesForm:["+id+", "+", "+loginname+", "+loginpassword+", "+labip+", "+status+", "+"]";
	}
	
	
	
}
