40 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			C#
		
	
	
	
			
		
		
	
	
			40 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			C#
		
	
	
	
| /// <summary>
 | |
| ///WCF service
 | |
| ///Interface FOR TABLE t_online
 | |
| ///By wm  
 | |
| ///on 06/18/2022
 | |
| /// </summary>
 | |
| 
 | |
| using System;
 | |
| using System.Collections.Generic;
 | |
| using System.Data;
 | |
| using System.ServiceModel; 
 | |
| using System.ServiceModel.Web; 
 | |
| using DeiNiu.wms.Data.Model.Wcf;
 | |
| namespace DeiNiu.Wcf
 | |
| {
 | |
|     [ServiceContract]
 | |
|     public interface IOnline
 | |
|     {
 | |
|         //http://localhost:8080/T_ONLINE.svc/getobj?id=1
 | |
|         [OperationContract]
 | |
|         [WebInvoke(Method = "GET",RequestFormat = WebMessageFormat.Json,ResponseFormat = WebMessageFormat.Json,
 | |
|             UriTemplate = "getObj?id={id}")]
 | |
|         WcfOnline getObj(int id);
 | |
| 
 | |
|         [OperationContract]
 | |
|         [WebInvoke(Method = "GET", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json,
 | |
|           UriTemplate = "login?userId={userId}&passwd={passwd}")]
 | |
|         int validUser(string userId, string passwd);
 | |
| 
 | |
|         [OperationContract]
 | |
|         [WebInvoke(Method = "GET", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json,
 | |
|          UriTemplate = "getCatedAuths?userId={userId}&warehouse={warehouse}")]
 | |
|         Dictionary<String, List<String>> getCatedAuths(int userId, int warehouse);
 | |
| 
 | |
|         [OperationContract]
 | |
|         DataTable getDictionary();
 | |
| 
 | |
|     }
 | |
| }
 |