using System;
using System.Collections.Generic;
using DefaultNamespace.ProcessMode;
using Framework.Manager;
using MotionFramework;
using TMPro;
using UnityEngine;
using UnityEngine.UI;
using static InterfaceManager;
namespace DefaultNamespace
{
public class MaterialInspectionManager : MonoBehaviour
{
public Toggle hegezheng;
public Toggle shuomingshu;
public Toggle shiyanbaogao;
public Button close;
private bool isOne = false;
///
/// 单位
///
public TextMeshProUGUI unit;
private void Start()
{
close.onClick.AddListener(delegate
{
if (MotionEngine.GetModule().ExamName.Contains("代保管物资出库") ||
MotionEngine.GetModule().ExamName.Contains("领用出库"))
{
List list = new List();
list.Add(hegezheng.isOn.ToString());
list.Add(shuomingshu.isOn.ToString());
list.Add(shiyanbaogao.isOn.ToString());
MotionEngine.GetModule().HandleClick(list);
TutorialGuideManager.Instance.TriggerNextGuide(close.name);
}
if (MotionEngine.GetModule().ExamName.Contains("到货验收入库"))
{
if (!isOne)
{
TutorialGuideManager.Instance.HideGuide();
isOne = true;
}
}
if (MotionEngine.GetModule().ExamName.Contains("退出退役代保管入库"))
{
if (!isOne)
{
TutorialGuideManager.Instance.HideGuide();
isOne = true;
}
//else
//{
// TutorialGuideManager.Instance.TriggerNextGuide();
//}
}
if (MotionEngine.GetModule().ExamName.Contains("调拨物资入库"))
{
if (!isOne)
{
TutorialGuideManager.Instance.HideGuide();
isOne = true;
}
//else
//{
// TutorialGuideManager.Instance.TriggerNextGuide();
//}
}
if (MotionEngine.GetModule().ExamName.Contains("退料物资入库"))
{
if (!isOne)
{
TutorialGuideManager.Instance.HideGuide();
isOne = true;
}
//else
//{
// TutorialGuideManager.Instance.TriggerNextGuide();
//}
}
});
unit = FindObjectByName("TextInputQuantityReceivableMaterials");
unit.text = GameManager.Instance.unit;
}
}
}