public virtual void RemoveCustomField(CustomFieldTypeId customFieldId) { if (customFieldTypeIdList == null) { customFieldTypeIdList = new List <CustomFieldTypeId>(); } customFieldTypeIdList.Remove(customFieldId); }
public CustomFieldType UpdateCustomFieldType(CustomFieldTypeId id, string name, string dictionaryName, long minValue, long maxValue, int entityId, string typeId) { try { using (var scope = new TransactionScope()) { var customFieldType = customFieldRep.GetById(id); customFieldType.Update(name, dictionaryName, minValue, maxValue, Enumeration.FromValue <EntityTypeEnum>(entityId.ToString()), typeId); scope.Complete(); return(customFieldType); } } catch (Exception exp) { var res = customFieldRep.TryConvertException(exp); if (res == null) { throw; } throw res; } }
public CustomFieldType GetById(CustomFieldTypeId customFieldTypeId) { return(rep.FindByKey(customFieldTypeId)); }