0đź‘Ť
âś…
managed to skip the rendering. I’m able to access the primary key via the “inital” attribute when I’m iterating all the devices:
{{ device.modbus_devices.initial.ixModbusDevice }}
👤john
1đź‘Ť
Because it’s an AutoField. Your can’t set those; they are automatically assigned by the database, hence the name. Therefore there’s no point in showing then on the form.
👤Daniel Roseman
0đź‘Ť
Try change the return
to :
return render(
request,
'app/create_bacnet.html',
{
'title':'Create BACnetDevice',
'tag':'create_bacnet',
'devices': devices
}
)
render() is the same as a call to render_to_response() with a
context_instance argument that forces the use of a RequestContext.
👤Paulo Pessoa
- Django removes #anchor in urls
- Puppet Dependency file failing in local Vagrant Environmnet
- Restrict each user to only vote once (Polls, django, python)
Source:stackexchange.com