package com.nmgs.entity;

import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import lombok.Data;

@Data
public class HttpParamDto {
    private String template_id;
    private String page;
    private JSONArray data;

    private String thing5;//消费类型
    private String time3;//消费时间
    private String character_string1;//消费积分
    private String number2;//剩余可用积分
    private String thing4;//底部提示语

    public HttpParamDto() {
    }

    public HttpParamDto(String thing5, String time3, String character_string1, String number2, String thing4) {
        this.thing5 = thing5;
        this.time3 = time3;
        this.character_string1 = character_string1;
        this.number2 = number2;
        this.thing4 = thing4;

        JSONArray ja=new JSONArray();
        JSONObject jo1=new JSONObject();
        jo1.put("name","thing5");
        jo1.put("value",thing5);
        JSONObject jo2=new JSONObject();
        jo2.put("name","character_string1");
        jo2.put("value",character_string1);
        JSONObject jo3=new JSONObject();
        jo3.put("name","number2");
        jo3.put("value",number2);
        JSONObject jo4=new JSONObject();
        jo4.put("name","time3");
        jo4.put("value",time3);
        JSONObject jo5=new JSONObject();
        jo5.put("name","thing4");
        jo5.put("value",thing4);
        ja.add(jo1);
        ja.add(jo2);
        ja.add(jo3);
        ja.add(jo4);
        ja.add(jo5);
        this.data=ja;

    }
}
