All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.tmsps.ne4weixin.bean.message.template.TemplateMessage Maven / Gradle / Ivy

There is a newer version: 3.2.2.3
Show newest version
package com.tmsps.ne4weixin.bean.message.template;

import java.util.Map;

/**
 * 发送模板消息
 * @author    hanjiefei
 * @date      2019-10-18
 * @version   V1.0
 * @Copyright 2019 nuoyun All rights reserved.
 */
public class TemplateMessage {

	/**
	 * 必填 是 接收者openid
	 */
	private String touser;
	
	/**
	 * 必填 是 模板ID
	 */
	private String template_id;
	
	/**
	 * 必填 否 模板跳转链接(海外帐号没有跳转能力)
	 */
	private String url;
	
	/**
	 * 必填 否 跳小程序所需数据,不需跳小程序可不用传该数据
	 */
	private String miniprogram;
	/**
	 * 必填 是 所需跳转到的小程序appid(该小程序appid必须与发模板消息的公众号是绑定关联关系,暂不支持小游戏)
	 */
	private String appid;
	
	/**
	 * 必填 否 所需跳转到小程序的具体页面路径,支持带参数,(示例index?foo=bar),要求该小程序已发布,暂不支持小游戏
	 */
	private String pagepath;
	
	/**
	 * 必填 否 模板内容字体颜色,不填默认为黑色
	 */
	private String color;
	
	/**
	 * 必填 是 模板数据
	 */
	private Map data;
	
	public TemplateMessage(String touser,String template_id) {
		this.touser = touser;
		this.template_id = template_id;
	}

	public TemplateMessage(String touser, String template_id, Map data) {
		super();
		this.touser = touser;
		this.template_id = template_id;
		this.data = data;
	}

	public String getTouser() {
		return touser;
	}

	public void setTouser(String touser) {
		this.touser = touser;
	}

	public String getTemplate_id() {
		return template_id;
	}

	public void setTemplate_id(String template_id) {
		this.template_id = template_id;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public String getMiniprogram() {
		return miniprogram;
	}

	public void setMiniprogram(String miniprogram) {
		this.miniprogram = miniprogram;
	}

	public String getAppid() {
		return appid;
	}

	public void setAppid(String appid) {
		this.appid = appid;
	}

	public String getPagepath() {
		return pagepath;
	}

	public void setPagepath(String pagepath) {
		this.pagepath = pagepath;
	}

	public String getColor() {
		return color;
	}

	public void setColor(String color) {
		this.color = color;
	}

	public Map getData() {
		return data;
	}

	public void setData(Map data) {
		this.data = data;
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy