Example #1
0
        public ActionResult GroupUpdate(GroupEditViewModel model)
        {
            string table = "CrmGroup";
            string strwhere = "GroupId=" + model.GroupId;
            GroupDto groupDto = GroupBll.GetOneGroupDto(table,strwhere);

            groupDto.GroupName = model.GroupName;
            groupDto.GroupInfo = model.GroupInfo;

            GroupBll.UpdateGroupDto(groupDto);

            return RedirectToAction("GroupIndex");
        }
Example #2
0
        public ActionResult GroupEdit(int GroupId)
        {
            string table = "CrmGroup";
            string strwhere="GroupId="+GroupId;
            GroupDto groupDto = GroupBll.GetOneGroupDto(table, strwhere);

            GroupEditViewModel model = new GroupEditViewModel();

            model.GroupName = groupDto.GroupName;
            model.GroupInfo = groupDto.GroupInfo;
            model.GroupId = groupDto.GroupId;

            return View(model);
        }