foodsoft/app/views/stockit/destroy.js.erb

14 lines
361 B
Text
Raw Permalink Normal View History

$('div.container-fluid').prepend('<%= j(render(
:partial => 'shared/alert_success',
:locals => {
:alert_message => t('.notice', :name => @stock_article.name)
}
)) %>');
// Publish database changes.
// See publish/subscribe design pattern in /doc.
$(document).trigger({
type: 'StockArticle#destroy',
stock_article_id: <%= @stock_article.id %>
});