// GET: api/Account/ public dynamic Get(string code) { try { return(AccountPeriodMdl.get_accountperiod(code)); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public object Check(string code) { try { var result = AccountPeriodMdl.get_accountperiod(code); return(result != null ? (object)new { state = true, name = result.ACP_PERIOD_FROM } : new { state = false }); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }