--HG--
branch : dev
This commit is contained in:
Renaud Paquay
2010-10-21 14:20:42 -07:00
3 changed files with 2 additions and 21 deletions

View File

@@ -51,8 +51,8 @@ using (Html.BeginForm("Create", "Comment", new { area = "Orchard.Comments" }, Fo
<fieldset class="what">
<ol>
<li>
<label for="CommentText">@T("Comment")</label>
<textarea id="comment-text" rows="10" cols="30" name="comment-text"></textarea>
<label for="comment-text">@T("Comment")</label>
<textarea id="comment-text" rows="10" cols="30" name="CommentText"></textarea>
</li>
<li>
<input type="submit" class="button" value="@T("Submit Comment")" />

View File

@@ -20,8 +20,5 @@ namespace Orchard.Data {
IEnumerable<T> Fetch(Expression<Func<T, bool>> predicate);
IEnumerable<T> Fetch(Expression<Func<T, bool>> predicate, Action<Orderable<T>> order);
IEnumerable<T> Fetch(Expression<Func<T, bool>> predicate, Action<Orderable<T>> order, int skip, int count);
[Obsolete]
void Transaction(Action action);
}
}

View File

@@ -80,22 +80,6 @@ namespace Orchard.Data {
int count) {
return Fetch(predicate, order, skip, count).ToReadOnlyCollection();
}
void IRepository<T>.Transaction(Action action) {
Transaction(action);
}
public virtual void Transaction(Action action) {
using (var transaction = Session.BeginTransaction()) {
try {
action();
transaction.Commit();
}
catch {
transaction.Rollback();
throw;
}
}
}
#endregion