using System.Collections; using System.Collections.Generic; using LitJson; using UnityEngine; using UnityEngine.UI; public class JieKouRiZhiItem : MonoBehaviour { public Text call_name; public Text call_date; public Text source; public Text input; public Text output; public Text result; public Text receive_date; public void init(JsonData data) { call_name.text = data["call_name"].ToString(); call_date.text = data["call_date"].ToString(); source.text = data["source"].ToString(); input.text = data["input"].ToString(); output.text = data["output"].ToString(); result.text = data["result"].ToString(); receive_date.text = data["receive_date"].ToString(); call_name.GetComponent().SetLayoutVertical(); call_name.transform.parent.GetComponent().SetLayoutVertical(); input.GetComponent().SetLayoutVertical(); input.transform.parent.GetComponent().SetLayoutVertical(); output.GetComponent().SetLayoutVertical(); output.transform.parent.GetComponent().SetLayoutVertical(); } }