Exemplo n.º 1
0
 public IHttpActionResult GetDataForPOHistory(object obj)
 {
     try
     {
         Bis.RelatePurchaseOrderFileMethod bisRelatePurchaseOrderFile = new Bis.RelatePurchaseOrderFileMethod();
         JObject JsonObject = JObject.Parse(obj.ToString());
         ViewModel.tblRelatePurchaseOrderFile get = new ViewModel.tblRelatePurchaseOrderFile();
         get.IDSupplier = JsonObject["IDSupplier"].ToString().StringToGuid();
         JArray JsonRelatePurchaseOrderFile = bisRelatePurchaseOrderFile.GetDataForPOHistory(get);
         return(Ok(JsonRelatePurchaseOrderFile));
     }
     catch
     {
         return(NotFound());
     }
 }
Exemplo n.º 2
0
 public IHttpActionResult AddRelatePurchaseOrderFile(object obj)
 {
     try
     {
         Bis.RelatePurchaseOrderFileMethod bisRelatePurchaseOrderFile = new Bis.RelatePurchaseOrderFileMethod();
         JObject JsonObject = JObject.Parse(obj.ToString());
         Guid    IDRegister = AuUser.ReturnIDUser(JsonObject["IDLogUser"].ToString().StringToGuid());
         ViewModel.tblRelatePurchaseOrderFile Add = JsonObject.ToObject <ViewModel.tblRelatePurchaseOrderFile>();
         Add.IDRegister = IDRegister;
         bool ret = bisRelatePurchaseOrderFile.AddRelatePurchaseOrderFile(Add);
         if (ret)
         {
             return(Ok(ret));
         }
         else
         {
             return(NotFound());
         }
     }
     catch
     {
         return(NotFound());
     }
 }
Exemplo n.º 3
0
 public bool AddRelatePurchaseOrderFile(ViewModel.tblRelatePurchaseOrderFile RelatePurchaseOrderFile)
 {
     return(sqlHelper.RunProcedure("sp_tblRelatePurchaseOrderFile_Insert", RelatePurchaseOrderFile, true) > 0);
 }
Exemplo n.º 4
0
 public JArray GetDataForPOHistory(ViewModel.tblRelatePurchaseOrderFile RelatePurchaseOrderFile)
 {
     return(sqlHelper.ReturnJsonData("sp_tblRelatePurchaseOrderFile_GetDataForPOHistory", RelatePurchaseOrderFile));
 }