<s> from __future__ import unicode_literals <EOL> from django . db import models , migrations <EOL> def migrate_interface_fields ( apps , schema_editor ) : <EOL> """<STR_LIT>""" <EOL> Interface = apps . get_model ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> Interface_temp = apps . get_model ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> for ifc in Interface . objects . iterator ( ) : <EOL> ifc_tmp = Interface_temp . objects . create ( <EOL> id = ifc . resource_ptr_id , <EOL> name = ifc . name , <EOL> description = ifc . description , <EOL> device_id = ifc . device_id , <EOL> parent_id = ifc . parent_id , <EOL> type = ifc . type , <EOL> speed = ifc . speed , <EOL> mac_address = ifc . mac_address , <EOL> site = ifc . site , <EOL> _attributes_cache = ifc . _attributes , <EOL> ) <EOL> class Migration ( migrations . Migration ) : <EOL> dependencies = [ <EOL> ( '<STR_LIT>' , '<STR_LIT>' ) , <EOL> ] <EOL> operations = [ <EOL> migrations . RunPython ( migrate_interface_fields ) , <EOL> ] </s>
