|
- using BPA.Helper;
- using BPA.Message;
- using BPASmartClient.DosingSystem.Model.Dto;
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
-
- namespace BPASmartClient.DosingSystem.Service
- {
- public class APIServer : IAPIServer
- {
-
-
- /// <summary>
- /// 设置业务插件状态
- /// </summary>
- /// <param name="state"></param>
- /// <returns></returns>
- public APIResult<bool> PlugInstatusSet(bool state)
- {
- var data = new { state = state };
- var res = APIHelper.GetInstance.PostRequest($"{ApiRoute.SetStatus}{state}", data.ToJson());
- return new FromT<bool>(res).Result;
- }
-
- public APIResult<List<WorkOrderPusht>> GetWorkOrder(string workOrderId)
- {
- var data = new { workOrderId = workOrderId, startTime = "", endTime = "" };
- var res = APIHelper.GetInstance.PostRequest(ApiRoute.WorkOrderData, data.ToJson());
- return new FromT<List<WorkOrderPusht>>(res).Result;
- }
- }
- }
|