mirror of
https://gitlab.com/Hukuta47/cartrix.git
synced 2026-12-05 20:40:55 +00:00
37 lines
2.0 KiB
C#
37 lines
2.0 KiB
C#
using System.Net;
|
|
|
|
namespace CartriX.Shared.Classes
|
|
{
|
|
public class ApiRoutes
|
|
{
|
|
static string baseUrl = "http://192.168.140.13:5000/api";
|
|
static public class Report
|
|
{
|
|
public static string ListCausesForReplace => $"{baseUrl}/{nameof(Report)}/{nameof(ListCausesForReplace)}";
|
|
public static string CreateRequestForReplace => $"{baseUrl}/{nameof(Report)}/{nameof(CreateRequestForReplace)}";
|
|
}
|
|
public static class Network
|
|
{
|
|
public static string Available => $"{baseUrl}/{nameof(Network)}/{nameof(Available)}";
|
|
public static string GetSNMPData(string IpAddressOrHostname, string OID) => $"{baseUrl}/{nameof(Network)}/{nameof(GetSNMPData)}?{nameof(IpAddressOrHostname)}={IpAddressOrHostname}&{nameof(OID)}={OID}";
|
|
public static string Ping(string IpAddressOrHostname) => $"{baseUrl}/{nameof(Network)}/{nameof(Ping)}?{nameof(IpAddressOrHostname)}={IpAddressOrHostname}";
|
|
}
|
|
public static class Cartridge
|
|
{
|
|
public static string GetForPrinter(int PrinterId) => $"{baseUrl}/{nameof(Cartridge)}/{nameof(GetForPrinter)}?{nameof(PrinterId)}={PrinterId}";
|
|
public static string Item(int Id) => $"{baseUrl}/{nameof(Cartridge)}/{nameof(Item)}?{nameof(Id)}={Id}";
|
|
public static string GetArticlesList => $"{baseUrl}/{nameof(Cartridge)}/{nameof(GetArticlesList)}";
|
|
}
|
|
public static class Printer
|
|
{
|
|
public static string Item(int Id) => $"{baseUrl}/{nameof(Printer)}/{nameof(Item)}?{nameof(Id)}={Id}";
|
|
public static string AddPrinter => $"{baseUrl}/{nameof(Printer)}/{nameof(AddPrinter)}";
|
|
public static string ListConnectionType => $"{baseUrl}/{nameof(Printer)}/{nameof(ListConnectionType)}";
|
|
public static string ListPrintType => $"{baseUrl}/{nameof(Printer)}/{nameof(ListPrintType)}";
|
|
}
|
|
public static class Location
|
|
{
|
|
public static string List => $"{baseUrl}/{nameof(Location)}/{nameof(List)}";
|
|
}
|
|
}
|
|
} |