public object search(string query) { try { return(LocationMdl.search_locations(query)); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public object lov() { try { return(LocationMdl.get_lov_location()); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
// GET: api/Location/ public dynamic Get(string code) { try { return(LocationMdl.get_location(code)); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public object Check(string code) { try { var result = LocationMdl.get_location(code); return(result != null ? (object)new { state = true, name = result.LOC_NAME } : new { state = false }); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public object save([FromBody] List <MS_SYS_LOCATION> locations) { try { foreach (var cty in locations) { LocationMdl.save_location(cty); } return(new { state = true, message = "Locations Successfully Created" }); } catch (Exception e) { return(new { state = false, message = "Server Error", exception = e }); } }
public IEnumerable <object> getLocations(ProductsRisksCoversJSON riskJson) { var riskLst = LocationMdl.get_Location_Lov(riskJson.PRD_CODE).ToList(); return(riskLst); }