cursor: pointer; }
.openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line.no_match:not(.no_partner) .toggle_match {
visibility: hidden !important; }
- .openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line.no_partner .partner_name, .openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line.no_partner .line_open_balance {
- display: none !important; }
.openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line > table > tbody > tr:nth-child(1) > td table {
margin-bottom: 10px; }
.openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line table.details td:first-child {
cursor: pointer; }
.openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line .accounting_view td:nth-child(6) {
border-left: 1px solid black; }
- .openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line .accounting_view tr.initial_line > td:nth-child(5) {
- border-top: 1px solid black; }
- .openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line .accounting_view tr.initial_line > td:nth-child(6) {
- border-top: 1px solid black; }
.openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line .match .match_controls {
padding: 0 0 5px 18px; }
.openerp .oe_bank_statement_reconciliation .oe_bank_statement_reconciliation_line .match .match_controls .filter {
keyboardShortcutsHandler: function(e) {
var self = this;
- if (e.which === 13 && (e.ctrlKey || e.metaKey)) {
+ if ((e.which === 13 || e.which === 10) && (e.ctrlKey || e.metaKey)) {
$.each(self.getChildren(), function(i, o){
if (o.is_valid && o.persistAndDestroy()) {
self.lines_reconciled_with_ctrl_enter++;
lineOpenBalanceClickHandler: function() {
var self = this;
if (self.get("mode") === "create") {
+ self.addLineBeingEdited();
self.set("mode", "match");
} else {
self.set("mode", "create");
balanceChanged: function() {
var self = this;
var balance = self.get("balance");
-
+ self.$(".tbody_open_balance").empty();
// Special case hack : no identified partner
if (self.st_line.has_no_partner) {
if (Math.abs(balance).toFixed(3) === "0.000") {
self.$(".button_ok").attr("disabled", "disabled");
self.$(".button_ok").text("OK");
self.is_valid = false;
+ var debit = (balance > 0 ? self.formatCurrency(balance, self.st_line.currency_id) : "");
+ var credit = (balance < 0 ? self.formatCurrency(-1*balance, self.st_line.currency_id) : "");
+ var $line = $(QWeb.render("bank_statement_reconciliation_line_open_balance", {debit: debit, credit: credit, account_code: self.map_account_id_code[self.st_line.open_balance_account_id]}));
+ $line.find('.js_open_balance')[0].innerHTML = "Choose counterpart";
+ self.$(".tbody_open_balance").append($line);
}
return;
}
- self.$(".tbody_open_balance").empty();
if (Math.abs(balance).toFixed(3) === "0.000") {
self.$(".button_ok").addClass("oe_highlight");
self.$(".button_ok").text("OK");
self.$(".action_pane.active").removeClass("active");
- // Special case hack : if no_partner, either inactive or create
+ // Special case hack : if no_partner and mode == inactive
if (self.st_line.has_no_partner) {
if (self.get("mode") === "inactive") {
self.$(".match").slideUp(self.animation_speed);
self.$(".create").slideUp(self.animation_speed);
self.$(".toggle_match").removeClass("visible_toggle");
self.el.dataset.mode = "inactive";
- } else {
- self.initializeCreateForm();
- self.$(".match").slideUp(self.animation_speed);
- self.$(".create").slideDown(self.animation_speed);
- self.$(".toggle_match").addClass("visible_toggle");
- self.el.dataset.mode = "create";
- }
- return;
+ return;
+ }
}
if (self.get("mode") === "inactive") {