Commit d2bd5a4f authored by 王雪伟's avatar 王雪伟

幸福花园修改需求

parent 909b6dae
......@@ -19268,6 +19268,7 @@ GameObject:
m_Component:
- component: {fileID: 716226832}
- component: {fileID: 716226833}
- component: {fileID: 716226834}
m_Layer: 5
m_Name: Title
m_TagString: Untagged
......@@ -19316,11 +19317,39 @@ MonoBehaviour:
m_EditorClassIdentifier:
img_icon: {fileID: 559426349}
img_procress: {fileID: 2086066928}
img_btn: {fileID: 1000610429}
img_btn: {fileID: 243898011}
img_withdraw: {fileID: 864805491}
contentParent: {fileID: 1992052043}
item_prefab: {fileID: 4313061083253950001, guid: 68900ab454c984c2d9184c156e08f810,
type: 3}
withDrawTitleTv: {fileID: 1440887900}
--- !u!114 &716226834
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 716226831}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 858415f4656694ff98262751c2b91d1f, type: 3}
m_Name:
m_EditorClassIdentifier:
tv_cash: {fileID: 200879011}
tv_process: {fileID: 1395310243}
img_procress: {fileID: 2086066928}
img_icon: {fileID: 559426349}
labels:
- {fileID: 21300000, guid: 47ddb0399e2684cf3884c6d6bdddf958, type: 3}
- {fileID: 21300000, guid: 72f865c0b00ad4541ae1a671aae1040a, type: 3}
- {fileID: 21300000, guid: 6cc4af9c8b9064107b6ea289c5733259, type: 3}
- {fileID: 21300000, guid: 9b89a9ec88f4842b3a619c1567897a5e, type: 3}
- {fileID: 21300000, guid: 5bfbf41c22713430fbfe0c71d1e0a026, type: 3}
- {fileID: 21300000, guid: f1cc32b6fcc8b4ec7a624085380dd608, type: 3}
- {fileID: 21300000, guid: ee2dc6b0cb7974ff5b77f2fe65a97d43, type: 3}
- {fileID: 21300000, guid: 8944be0946e714260912afb0aafb3ca5, type: 3}
- {fileID: 21300000, guid: fd5ece32e702d4c87b077c6ac5feb5fd, type: 3}
- {fileID: 21300000, guid: e682ab231c8d34771a60091de4631774, type: 3}
--- !u!1 &718040249
GameObject:
m_ObjectHideFlags: 0
......@@ -27321,8 +27350,8 @@ RectTransform:
m_Father: {fileID: 1717678917}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchorMin: {x: 0.000000057908174, y: 0}
m_AnchorMax: {x: 0.97594327, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 20, y: 20}
m_Pivot: {x: 0.5, y: 0.5}
......@@ -38737,7 +38766,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 0.2627451, g: 0.49411765, b: 0.14509805, a: 1}
m_Color: {r: 0.61960787, g: 0.32156864, b: 0.047058824, a: 1}
m_RaycastTarget: 1
m_Maskable: 1
m_OnCullStateChanged:
......@@ -39623,7 +39652,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!224 &1472916196
RectTransform:
m_ObjectHideFlags: 0
......@@ -48571,9 +48600,9 @@ RectTransform:
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: -17}
m_Pivot: {x: 0, y: 1}
--- !u!114 &1795153949
MonoBehaviour:
......@@ -50533,7 +50562,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
m_IsActive: 1
--- !u!224 &1863343229
RectTransform:
m_ObjectHideFlags: 0
......@@ -53025,7 +53054,7 @@ RectTransform:
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_SizeDelta: {x: 12.6779175, y: 20}
m_Pivot: {x: 0, y: 1}
--- !u!114 &1992052045
MonoBehaviour:
......@@ -7,12 +7,13 @@ using static WithDrawBean;
public class TitleControl : MonoBehaviour
{
// public Text tvdesc,tv_cash,tv_process;
public Image img_icon, img_procress,img_btn;
// public Sprite[] labels, btnsprites;
private Animator m_Animator,btn_Animator;
// public Text tvdesc,tv_cash,tv_process;
public Image img_icon, img_procress, img_btn;
// public Sprite[] labels, btnsprites;
private Animator m_Animator, btn_Animator;
public Image img_withdraw;
public GameObject contentParent, item_prefab;
public Text withDrawTitleTv;
//获取首页第一个提现信息
private void Start()
{
......@@ -33,7 +34,8 @@ public class TitleControl : MonoBehaviour
HttpTool.Instance._Get("app/v1/wdlc/wd/first_info", null, new Action<WithDrawFirstInfoBean>((bean) =>
{
Debug.Log("首页提现信息");
setData(bean.wdlcWdDataList);
// setData(bean.wdlcWdDataList);
setNewData(bean.wdlcWdDataList);
setAnimal(bean);
}), new Action<string, string>((code, errMsg) =>
......@@ -56,11 +58,20 @@ public class TitleControl : MonoBehaviour
}
}
private void setNewData(List<WithdrawListItem> data)
{
if (data.Count > 0)
{
withDrawTitleTv.text = data[0].conditionContent;
GetComponent<HomeItem>().setItemData(data[0]);
}
}
private void setData(List<WithdrawListItem> data)
{
if (null != data)
{
int nCount = contentParent.transform.childCount;
for (int i = 0; i < nCount; i++)
{
......@@ -70,7 +81,7 @@ public class TitleControl : MonoBehaviour
if (data.Count > 3)
{
for (int i = 0; i < 3; i++)
{
GameObject game = Instantiate(item_prefab, contentParent.transform);
......@@ -86,15 +97,13 @@ public class TitleControl : MonoBehaviour
GameObject game = Instantiate(item_prefab, contentParent.transform);
game.name = "" + i;
game.GetComponent<HomeItem>().setItemData(data[i]);
}
}
}
}
}
/// <summary>
/// 点击提现
/// </summary>
......@@ -105,7 +114,7 @@ public class TitleControl : MonoBehaviour
public void clickWithDrawBg()
{
GameObject.Find("Dialog").GetComponent<DialogControl>().showPlantTreeWithDrawDialog();
}
public void clickEveryReward()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment