| | |
| | | { |
| | | return base.DeleteData(keys); |
| | | } |
| | | /// <summary> |
| | | /// ä¿®æ¹è´§ä½çç¦ç¨ç¶æ |
| | | /// </summary> |
| | | /// <param name="saveModel"></param> |
| | | /// <returns></returns> |
| | | public WebResponseContent UpdateEnableStatus(SaveModel saveModel) |
| | | { |
| | | WebResponseContent content = new WebResponseContent(); |
| | | try |
| | | { |
| | | List<Dt_LocationInfo> locationInfos = Repository.QueryData(x => saveModel.DelKeys.Contains(x.Id)); |
| | | var values = Enum.GetValues(typeof(EnableStatusEnum)); |
| | | var Index = saveModel.Extra.ObjToInt(); |
| | | var EnableStatus = (EnableStatusEnum)values.GetValue(Index); |
| | | locationInfos.ForEach(x => |
| | | { |
| | | x.EnableStatus = EnableStatus.ObjToInt(); |
| | | }); |
| | | Repository.UpdateData(locationInfos); |
| | | content.OK(); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | content.Error(ex.Message); |
| | | } |
| | | |
| | | return content; |
| | | } |
| | | public WebResponseContent LocationEnableStatus(int[] keys) |
| | | { |
| | | List<Dt_LocationInfo> locationInfos = Repository.QueryData(x => keys.Contains(x.Id)); |