/** * Invision Community * (c) Invision Power Services, Inc. - https://www.invisioncommunity.com * * ips.convert.menu.js - * * Author: Ryan Ashbrook */ ;( function($, _, undefined){ "use strict"; ips.controller.register('convert.admin.convert.menu', { initialize: function () { this.on( 'click', "[data-action='reConvert']", this.areYouSure ); this.on( 'click', "[data-action='remove_converted_data']", this.removeConverted ); }, areYouSure: function(e) { var self = this; e.preventDefault(); ips.ui.alert.show( { type: 'confirm', icon: 'warning', message: 'Are you sure you wish to reconvert this?', subText: 'Reconverting can cause data inconsistency. If you reconvert this step, you must also reconvert each step below it.', } ); }, removeConverted: function(e) { var self = this; e.preventDefault(); ips.ui.alert.show( { type: 'confirm', icon: 'warning', message: 'Are you sure you wish to remove all converted data for this step?', subText: 'Removing all converted data will remove all data that has been converted for this step. This action cannot be undone.', } ); } } ); }(jQuery, _)); /** * Invision Community * (c) Invision Power Services, Inc. - https://www.invisioncommunity.com * * ips.forms.reactionmapper.js - Conversion specific Reaction map form * * Author: Stuart Silvester */ ;( function($, _, undefined){ "use strict"; ips.controller.register('convert.admin.forms.reactionmapper', { initialize: function () { var id = $(this.scope).data( 'reactionid' ); this.on( document, 'click', "#elReactionMapper" + id + "_menu .ipsMenu_item", this.selectReaction ); this.setup(); }, /** * Set up the default reaction * * @returns {void} */ setup: function () { this.scope.find('a[data-default="true"]').click(); }, /** * Select Reaction * * @param {event} e Event object * @returns {void} */ selectReaction: function ( e ) { e.preventDefault(); var menuItem = $( e.target ); this.scope.find('.elMenuSelect_replace').html( menuItem.html() ); this.scope.find('input[type=hidden]').val( menuItem.data('id') ); } }); }(jQuery, _)); templates common/ips.loader.js common/ui common/utils common controllers underscore jquery mustache Debug.js app.js jquery.js jquery-migrate.js linkify.min.js linkify-jquery.min.js