Skip to content

Commit

Permalink
Added Source to htmx.ajax to allow both calls. Without, the unpkg htm…
Browse files Browse the repository at this point in the history
…x package ignores the second call.
  • Loading branch information
ringhidb committed Sep 13, 2024
1 parent 0c4007f commit 5002dc4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions netbox_floorplan/static/netbox_floorplan/floorplan/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ var record_type = document.getElementById('record_type').value;
var site_id = document.getElementById('site_id').value;
var location_id = document.getElementById('location_id').value;

htmx.ajax('GET', `/plugins/floorplan/floorplans/racks/?floorplan_id=${obj_pk}`, { target: '#rack-card', swap: 'innerHTML', trigger: 'load' })
htmx.ajax('GET', `/plugins/floorplan/floorplans/devices/?floorplan_id=${obj_pk}`, { target: '#unrack-card', swap: 'innerHTML', trigger: 'load' })
htmx.ajax('GET', `/plugins/floorplan/floorplans/racks/?floorplan_id=${obj_pk}`, { source: '#rack-card', target: '#rack-card', swap: 'innerHTML', trigger: 'load' })
htmx.ajax('GET', `/plugins/floorplan/floorplans/devices/?floorplan_id=${obj_pk}`, { source: '#unrack-card', target: '#unrack-card', swap: 'innerHTML', trigger: 'load' })

fabric.Object.prototype.set({
snapThreshold: 45,
Expand Down

0 comments on commit 5002dc4

Please sign in to comment.