⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 e0453e405f31001d1920bb3b63de0236

📁 客户关系管理系统主要管理新老客户的一些信息并可以发现潜在客户
💻
字号:
package com.qrsx.qrsxcrm.form;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;
import org.apache.struts.action.ActionMessage;

import com.qrsx.qrsxcrm.model.Client;
import com.qrsx.qrsxcrm.model.ProductionType;

public class ClientProductionForm extends ActionForm {
	
	private String id; 						// 主键
	private String clientProductionName; 	// 客户产品名
	private String clientProductionId; 		// 客户产品编号
	private String clientId; 				// 客户名称 级联客户n-----1
	private String productionTypeId; 		// 客户产品类型 级联另一张表ProductionType
	private String price; 					// 产品价格
	private String amount; 					// 产品数量
	private Client client; 					//级联一个客户对象
	private ProductionType productionType;	//级联一个产品类型对象

	
	/**
	 * FORM表单验证
	 */
	public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
		
		ActionErrors errors = new ActionErrors();
		if((clientProductionName == null)||(clientProductionName.length()<1)){
			errors.add("clientProductionName",new ActionMessage("client.client.clientName"));
		}
		if((clientProductionId == null)||(clientProductionId.length()<1)){
			errors.add("clientProductionId",new ActionMessage("client.client.clientCode"));
		}
		if((clientId == null)||(clientId.length()<1)){
			errors.add("clientId",new ActionMessage("client.client.telephone"));
		}
		if((productionTypeId == null)||(productionTypeId.length()<1)){
			errors.add("productionTypeId",new ActionMessage("client.client.address"));
		}
		if((price == null)||(price.length()<1)){
			errors.add("price",new ActionMessage("client.client.postcard"));
		}
		if((amount == null)||(amount.length()<1)){
			errors.add("amount",new ActionMessage("client.client.clientTypeId"));
		}
		return errors;
	}
	/**
	 * @return the id
	 */
	public String getId() {
		return id;
	}

	/**
	 * @return the clientProductionName
	 */
	public String getClientProductionName() {
		return clientProductionName;
	}

	/**
	 * @return the clientProductionId
	 */
	public String getClientProductionId() {
		return clientProductionId;
	}

	/**
	 * @return the clientId
	 */
	public String getClientId() {
		return clientId;
	}

	/**
	 * @return the productionTypeId
	 */
	public String getProductionTypeId() {
		return productionTypeId;
	}

	/**
	 * @return the price
	 */
	public String getPrice() {
		return price;
	}

	/**
	 * @return the amount
	 */
	public String getAmount() {
		return amount;
	}

	/**
	 * @return the client
	 */
	public Client getClient() {
		return client;
	}

	/**
	 * @return the productionType
	 */
	public ProductionType getProductionType() {
		return productionType;
	}

	/**
	 * @param id the id to set
	 */
	public void setId(String id) {
		this.id = id;
	}

	/**
	 * @param clientProductionName the clientProductionName to set
	 */
	public void setClientProductionName(String clientProductionName) {
		this.clientProductionName = clientProductionName;
	}

	/**
	 * @param clientProductionId the clientProductionId to set
	 */
	public void setClientProductionId(String clientProductionId) {
		this.clientProductionId = clientProductionId;
	}

	/**
	 * @param clientId the clientId to set
	 */
	public void setClientId(String clientId) {
		this.clientId = clientId;
	}

	/**
	 * @param productionTypeId the productionTypeId to set
	 */
	public void setProductionTypeId(String productionTypeId) {
		this.productionTypeId = productionTypeId;
	}

	/**
	 * @param price the price to set
	 */
	public void setPrice(String price) {
		this.price = price;
	}

	/**
	 * @param amount the amount to set
	 */
	public void setAmount(String amount) {
		this.amount = amount;
	}

	/**
	 * @param client the client to set
	 */
	public void setClient(Client client) {
		this.client = client;
	}

	/**
	 * @param productionType the productionType to set
	 */
	public void setProductionType(ProductionType productionType) {
		this.productionType = productionType;
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -