Tz2/Assets/Zion/Scripts/ERP/库存物资查询报表/InventoryStockQueryReportMa...

52 lines
1.6 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System;
using System.Collections.Generic;
using DefaultNamespace;
using DefaultNamespace.ProcessMode;
using Framework.Manager;
using Framework.Utils;
using MotionFramework;
using TMPro;
using UnityEngine;
using UnityEngine.Events;
using UnityEngine.UI;
namespace Zion.Scripts.ERP.
{
public class InventoryStockQueryReportManager : MonoBehaviour
{
public TMP_InputField factoryInputField;
public TMP_InputField cityInputField;
public Button queryButton;
public Button saveButton;
public GameObject queryPanel;
private void Start()
{
queryButton.onClick.AddListener(OnQueryButtonClicked);
saveButton.onClick.AddListener(OnSaveButtonClicked);
}
private void OnSaveButtonClicked()
{
// string path = Application.streamingAssetsPath + "/Excel/库存积压表.XLSX";
// Debug.Log(path);
// FileUtils.OpenFile(path);
MotionEngine.GetModule<ProcessManager>().HandleClick("导出表格");
FileComponent.DownloadSingleFile( "附件1库存积压表");
}
private void OnQueryButtonClicked()
{
List<string> list = new List<string>();
list.Add(factoryInputField.text);
list.Add(cityInputField.text);
if (MotionEngine.GetModule<ProcessManager>().HandleClick(list))
{
queryPanel.SetActive(true);
TutorialGuideManager.Instance.TriggerNextGuide(queryButton.name);
}
}
}
}