Ejemplo n.º 1
0
        public ActionResult Update_Appointment(Int32 rowID)
        {
            var CRM_Appointment = new CRM_Appointment();
            var rs = CRM_Appointment.Update_Status(rowID, currentUser.UserName);

            return(Json(rs));
        }
Ejemplo n.º 2
0
 public ActionResult Update_Appointment(string rowID, string typeAction)
 {
     if (asset.Delete)
     {
         try
         {
             var      dbConn     = Helpers.OrmliteConnection.openConn();
             string[] separators = { "@@" };
             var      listRowID  = rowID.Split(separators, StringSplitOptions.RemoveEmptyEntries);
             foreach (var item in listRowID)
             {
                 if (typeAction == "XOA")
                 {
                     dbConn.Delete <CRM_Appointment>(s => s.RowID == int.Parse(item));
                 }
                 else if (typeAction == "XN")
                 {
                     CRM_Appointment.Update_Status(int.Parse(item), currentUser.UserName);
                 }
             }
         }
         catch (Exception ex)
         {
             return(Json(new { success = false, alert = ex.Message }));
         }
         return(Json(new { success = true }));
     }
     else
     {
         return(Json(new { success = false, alert = "You don't have permission to create record" }));
     }
 }
Ejemplo n.º 3
0
        public ActionResult Create_Appointment(CRM_Ticket_Task_Appointment request)
        {
            var CRM_Appointment = new CRM_Appointment();
            var rs = CRM_Appointment.Save(request, currentUser.UserName);

            return(Json(rs));
        }