94 lines
		
	
	
		
			2.6 KiB
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			94 lines
		
	
	
		
			2.6 KiB
		
	
	
	
		
			C#
		
	
	
	
	
	
using APT.BaseData.Domain.Entities;
 | 
						|
using APT.BaseData.Domain.IServices;
 | 
						|
using APT.Infrastructure.Core;
 | 
						|
using Microsoft.AspNetCore.Mvc;
 | 
						|
using System;
 | 
						|
using System.Collections.Generic;
 | 
						|
using APT.Utility;namespace APT.PF.WebApiControllers.Api.PF
 | 
						|
{
 | 
						|
	[Route("api/PF/Label")]
 | 
						|
    [APT.Infrastructure.Api.RootOrg]
 | 
						|
    public class LabelController : AuthorizeApiController<T_PF_LABEL>
 | 
						|
	{
 | 
						|
        private IPFLabelService LabelService { get; set; }
 | 
						|
        public LabelController(IPFLabelService LabelService)
 | 
						|
        {
 | 
						|
            this.LabelService = LabelService;
 | 
						|
        }
 | 
						|
   
 | 
						|
       
 | 
						|
        /// <summary>
 | 
						|
        /// 
 | 
						|
        /// </summary>
 | 
						|
        /// <param name="cid"></param>
 | 
						|
        /// <param name="tableName"></param>
 | 
						|
        /// <param name="language"></param>
 | 
						|
        /// <returns></returns>
 | 
						|
        [HttpGet, Route("List")]
 | 
						|
        public JsonActionResult<List<T_PF_LABEL>> List(Guid? orgId, string language)
 | 
						|
        {
 | 
						|
            return SafeExecute(() =>
 | 
						|
            {
 | 
						|
				return new List<T_PF_LABEL>();
 | 
						|
            });
 | 
						|
        }
 | 
						|
 | 
						|
        /// <summary>
 | 
						|
        /// 更新信息
 | 
						|
        /// </summary>
 | 
						|
        /// <param name="label"></param>
 | 
						|
        /// <returns></returns>
 | 
						|
        [HttpPost, Route("Update")]
 | 
						|
        public JsonActionResult<bool> Update([FromBody]T_PF_LABEL label)
 | 
						|
        {
 | 
						|
            return SafeExecute(() =>
 | 
						|
            {
 | 
						|
                return this.UpdateEntity<T_PF_LABEL>(label);
 | 
						|
            });
 | 
						|
        }
 | 
						|
 | 
						|
        /// <summary>
 | 
						|
        /// 删除信息
 | 
						|
        /// </summary>
 | 
						|
        /// <param name="id"></param>
 | 
						|
        /// <returns></returns>
 | 
						|
        [HttpGet, Route("Delete")]
 | 
						|
        public JsonActionResult<bool> Delete(string id)
 | 
						|
        {
 | 
						|
            return SafeExecute(() =>
 | 
						|
            {
 | 
						|
                return this.DeleteEntity<T_PF_LABEL>(id);
 | 
						|
            });
 | 
						|
        }
 | 
						|
 | 
						|
        /// <summary>
 | 
						|
        /// 批量删除
 | 
						|
        /// </summary>
 | 
						|
        /// <param name="id"></param>
 | 
						|
        /// <returns></returns>
 | 
						|
        [HttpGet, Route("BatchDelete")]
 | 
						|
        public JsonActionResult<bool> BatchDelete(string ids)
 | 
						|
        {
 | 
						|
			return WitBatchDelete(ids);
 | 
						|
        }
 | 
						|
 | 
						|
        [HttpGet, Route("Get")]
 | 
						|
        public JsonActionResult<T_PF_LABEL> Get(string id)
 | 
						|
        {
 | 
						|
            return SafeExecute(() =>
 | 
						|
            {
 | 
						|
                return this.GetEntity<T_PF_LABEL>(id);
 | 
						|
            });
 | 
						|
        }
 | 
						|
        //[HttpGet, Route("Get")]
 | 
						|
        //public JsonActionResult<T_PF_LABEL> GetLabel(Guid? orgId, string tableName, string languge, string field)
 | 
						|
        //{
 | 
						|
        //    return SafeExecute(() =>
 | 
						|
        //    {
 | 
						|
        //        return new T_PF_LABEL();
 | 
						|
        //    });
 | 
						|
        //}
 | 
						|
 | 
						|
    }
 | 
						|
}
 |