using LHDN.CRM.BC.Common;
using LHDN.CRM.Web.Controllers;
using System.Web.Mvc;
using LHDN.CRM.Web.Filters;
using LHDN.CRM.Models.ViewModels;

namespace LHDN.CRM.Web.Areas.TaxPayer.Controllers
{
    public class SearchController : BaseController
    {
        // GET: TaxPayer/Search
        [CRMAuthorize(Roles = Constant.Authentication.TaxPayer.SearchTPProfile)]
        public ActionResult Index()
        {
            ViewBag.TableType = (int)Constant.TableType.TaxPayer;

            AddAntiforgeryToken();
            return View();
        }

        [HttpPost]
        public ActionResult Listing(ActSearchTPViewModel model)
        {
            ViewBag.TableType = (int)Constant.TableType.TaxPayer;
            ViewBag.IDNo = model.IDNo;
            ViewBag.LinkfromDashboard = true;

            AddAntiforgeryToken();
            return View("Index");
        }
    }
}