anchor.diff:    $('#new_transaction').bind('reset', function() {
       setTimeout(newTransaction, 1);
     });
  -  <%
  -    member_ids = Hash.new
  -    @group.members.map(&:id).each_with_index{ |m,i| member_ids[m] = i };
  -  %>
  -  var memberIds = <%=raw member_ids.to_json %>;
  -  var transactionData = <%=raw sorted_transactions.to_json %>;
  -  var duplicateTransaction = function(index) {
  -    var transaction = transactionData[index],
  -        evenSplit = transaction.amount / transaction.debits.length,
  -        autoSplit = _.all(transaction.debits, function(debit) {
  -          return evenSplit - 1 <= debit[1] && debit[1] <= evenSplit + 1
  +  var duplicateTransaction = function(transaction) {
  +    var evenSplit = transaction.amount / transaction.debits.length;
  +    var autoSplit = _.all(transaction.debits, function(debit) {
  +          return evenSplit - 1 <= debit[1] && debit[1] <= evenSplit + 1; // check if all debits are within 1 cent of even split
           });
       setDate();
       _.each(splitItems, function(item) { item.on(false) });
       _.each(transaction.debits, function(debit) {
  -      var item = splitItems[memberIds[debit[0]]],
  -          debitAmount = debit[1];
  +      var item = _.find(splitItems, function(item){ return item.userId == debit[0].toString()});
  +      var debitAmount = debit[1];
         if (debitAmount != 0) {
           item.auto(autoSplit).val(debitAmount);
         }
  
positive.code:            res = b.created_at <=> a.created_at if res == 0
             res
           end
           sorted_transactions.each_with_index do |transaction, i| %>
  		<% cache("group::#{@group.id}::transaction::#{transaction.id}") do %>
          	<tr class=t>
  	          <td>
  
negative.code:     var that = this,
          check = row.find('[type="checkbox"]'),
          text = row.find('[type="text"]');
      this.userId = row.attr("userid");
      this.check = check;
      this.text = text;
      this.focusVal = null;
  