42 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			C#
		
	
	
	
		
		
			
		
	
	
			42 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			C#
		
	
	
	
|  | using System; | |||
|  | using System.Collections.Generic; | |||
|  | using System.Linq; | |||
|  | using System.Runtime.Serialization; | |||
|  | using System.ServiceModel; | |||
|  | using System.Text; | |||
|  | using System.Data; | |||
|  | using System.Web.Script.Services; | |||
|  | using System.ServiceModel.Web; | |||
|  | 
 | |||
|  | namespace DeiNiu.Wcf | |||
|  | { | |||
|  |     // 注意: 使用“重构”菜单上的“重命名”命令,可以同时更改代码和配置文件中的接口名“ISetup”。 | |||
|  |     [ServiceContract] | |||
|  |     public interface IPortal | |||
|  |     {  | |||
|  |         | |||
|  |         [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] | |||
|  |         void updateUserTheme(int userId, string theme); | |||
|  | 
 | |||
|  |         [OperationContract] | |||
|  |         List<String> getSpecialAuths(int userId, int warehouse); | |||
|  |         [OperationContract] | |||
|  |         [WebInvoke(Method = "GET", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json, | |||
|  |           UriTemplate = "login?userId={userId}&passwd={passwd}")] | |||
|  |          int validUser(string userId, string passwd); | |||
|  |   | |||
|  |          [OperationContract] | |||
|  |          bool haveSpecialAuth(string userId, string passwd, string spAuth); | |||
|  | 
 | |||
|  |          [OperationContract] | |||
|  |          List<String> getWareHouses(string mgrAddress); | |||
|  |         // [OperationContract] | |||
|  |        //  List<String> getWareHouseMgrs(); | |||
|  |     } | |||
|  | } |