Django

Code

Changeset 6016

Show
Ignore:
Timestamp:
08/25/07 18:34:42 (1 year ago)
Author:
adrian
Message:

newforms-admin: Merged to [6015]

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/branches/newforms-admin

    • Property svnmerge-integrated changed from /django/trunk:1-4345,4350-4357,4359-4365,4371-4372,4374-4377,4380-4386,4388,4390-4391,4400-4402,4404-4408,4410,4412-4419,4426-4427,4430-4432,4434,4441,4443-4444,4446-4447,4450,4452-4453,4455-4458,4476,4503,4546,4564-4569,4580-4586,4617,4630,4641-6013 to /django/trunk:1-4345,4350-4357,4359-4365,4371-4372,4374-4377,4380-4386,4388,4390-4391,4400-4402,4404-4408,4410,4412-4419,4426-4427,4430-4432,4434,4441,4443-4444,4446-4447,4450,4452-4453,4455-4458,4476,4503,4546,4564-4569,4580-4586,4617,4630,4641-6015
  • django/branches/newforms-admin/django/contrib/admin/media/js/SelectBox.js

    r450 r6016  
    77        var cache = SelectBox.cache[id]; 
    88        for (var i = 0; (node = box.options[i]); i++) { 
    9             cache.push({ value: node.value, text: node.text, displayed: 1 }); 
     9            cache.push({value: node.value, text: node.text, displayed: 1}); 
    1010        } 
    1111    }, 
     
    5151    }, 
    5252    add_to_cache: function(id, option) { 
    53         SelectBox.cache[id].push({ value: option.value, text: option.text, displayed: 1 }); 
     53        SelectBox.cache[id].push({value: option.value, text: option.text, displayed: 1}); 
    5454    }, 
    5555    cache_contains: function(id, value) { 
     
    6969        for (var i = 0; (option = from_box.options[i]); i++) { 
    7070            if (option.selected && SelectBox.cache_contains(from, option.value)) { 
    71                 SelectBox.add_to_cache(to, { value: option.value, text: option.text, displayed: 1 }); 
     71                SelectBox.add_to_cache(to, {value: option.value, text: option.text, displayed: 1}); 
    7272                SelectBox.delete_from_cache(from, option.value); 
    7373            } 
     
    8181        var option; 
    8282        for (var i = 0; (option = from_box.options[i]); i++) { 
    83             SelectBox.add_to_cache(to, { value: option.value, text: option.text, displayed: 1 }); 
    84             SelectBox.delete_from_cache(from, option.value); 
     83            if (SelectBox.cache_contains(from, option.value)) { 
     84                SelectBox.add_to_cache(to, {value: option.value, text: option.text, displayed: 1}); 
     85                SelectBox.delete_from_cache(from, option.value); 
     86            } 
    8587        } 
    8688        SelectBox.redisplay(from);