public object search(string query) { try { return(AreaMdl.search_areas(query)); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public object lov() { try { return(AreaMdl.get_lov_areas()); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
// GET: api/Area/5 public dynamic Get(string code) { try { return(AreaMdl.get_area(code)); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public object Check(string code) { try { var result = AreaMdl.get_area(code); return(result != null ? (object)new { state = true, name = result.ARE_NAME } : new { state = false }); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public object save([FromBody] List <MS_SYS_AREA> areas) { try { foreach (var are in areas) { AreaMdl.save_area(are); } return(new { state = true, message = "Areas Successfully Created" }); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public IEnumerable <object> getAreas(ProductsRisksCoversJSON riskJson) { var riskLst = AreaMdl.get_Area_Lov(riskJson.PRD_CODE).ToList(); return(riskLst); }