Created
April 6, 2016 22:49
-
-
Save VirtuosiMedia/682dafb8c2f8c91c0fc2aa94089d5bd5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Unlocks a purchase bid, canceling it and rerendering the table and the resource panel. | |
* @param {HTMLObject} target The unlock button. | |
*/ | |
cancelBid: function(target){ | |
var good = target.get('data-good'); | |
var holding = jg.data.state.holding; | |
var template = jg.templates.commercial.tradeCenter(); | |
jg.calculate.trade.cancelTradeOrder(holding, good); | |
jg.templates.load.interface()['update' + jg.data.state.panel + 'Panel'](); | |
template.renderPurchaseTable(); | |
}, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment