[IMP]IMproved code for publish as per main branch.

bzr revid: bth@tinyerp.com-20130927060207-ssj30gad3xuchqsb
This commit is contained in:
bth-openerp 2013-09-27 11:32:07 +05:30
parent 5d1c7b9c81
commit 06fb56ec8b
2 changed files with 4 additions and 4 deletions

View File

@ -1,8 +1,8 @@
$(function () {
$(document).on('click', '.js_publish', function (e) {
var id = $(this).data('id');
$(document).on('click', '.js_publish_management .js_publish_btn', function (e) {
var $data = $(this).parents(".js_publish_management:first");
var loadpublish = function () {
return openerp.jsonRpc('/recruitment/published', 'call', {'id': id});
return openerp.jsonRpc('/recruitment/published', 'call', {'id': $data.data('id')});
}
var i = 0;
$(this).ajaxComplete(function(el, xhr, settings) {

View File

@ -80,7 +80,7 @@
<button type="submit" class="btn btn-default" name="unsubscribe">Unsubscribe</button>
</form>
</div>
<t t-call="website.publish"><t t-set="object" t-value="job"/></t>
<t t-call="website.publish_management"><t t-set="object" t-value="job"/></t>
</div>
</div>
<div class="oe_structure" style="clear:both;">