|
|
@@ -3200,7 +3200,7 @@ function PrinterCard({
|
|
|
// Build filament data for hover card
|
|
|
const filamentData = tray?.tray_type ? {
|
|
|
vendor: (isBambuLabSpool(tray) ? 'Bambu Lab' : 'Generic') as 'Bambu Lab' | 'Generic',
|
|
|
- profile: slotPreset?.preset_name || cloudInfo?.name || tray.tray_sub_brands || tray.tray_type,
|
|
|
+ profile: slotPreset?.preset_name || cloudInfo?.name || inventoryAssignment?.spool?.slicer_filament_name || tray.tray_sub_brands || tray.tray_type,
|
|
|
colorName: getBambuColorName(tray.tray_id_name) || hexToColorName(tray.tray_color),
|
|
|
colorHex: tray.tray_color || null,
|
|
|
kFactor: formatKValue(tray.k),
|
|
|
@@ -3367,6 +3367,18 @@ function PrinterCard({
|
|
|
extruderId: mappedExtruderId,
|
|
|
}),
|
|
|
}}
|
|
|
+ inventory={spoolmanEnabled ? undefined : {
|
|
|
+ onAssignSpool: () => setAssignSpoolModal({
|
|
|
+ printerId: printer.id,
|
|
|
+ amsId: ams.id,
|
|
|
+ trayId: slotIdx,
|
|
|
+ trayInfo: {
|
|
|
+ type: '',
|
|
|
+ color: '',
|
|
|
+ location: `${getAmsLabel(ams.id, ams.tray.length)} Slot ${slotIdx + 1}`,
|
|
|
+ },
|
|
|
+ }),
|
|
|
+ }}
|
|
|
>
|
|
|
{slotVisual}
|
|
|
</EmptySlotHoverCard>
|
|
|
@@ -3427,7 +3439,7 @@ function PrinterCard({
|
|
|
// Build filament data for hover card
|
|
|
const filamentData = tray?.tray_type ? {
|
|
|
vendor: (isBambuLabSpool(tray) ? 'Bambu Lab' : 'Generic') as 'Bambu Lab' | 'Generic',
|
|
|
- profile: slotPreset?.preset_name || cloudInfo?.name || tray.tray_sub_brands || tray.tray_type,
|
|
|
+ profile: slotPreset?.preset_name || cloudInfo?.name || htInventoryAssignment?.spool?.slicer_filament_name || tray.tray_sub_brands || tray.tray_type,
|
|
|
colorName: getBambuColorName(tray.tray_id_name) || hexToColorName(tray.tray_color),
|
|
|
colorHex: tray.tray_color || null,
|
|
|
kFactor: formatKValue(tray.k),
|
|
|
@@ -3669,6 +3681,18 @@ function PrinterCard({
|
|
|
extruderId: mappedExtruderId,
|
|
|
}),
|
|
|
}}
|
|
|
+ inventory={spoolmanEnabled ? undefined : {
|
|
|
+ onAssignSpool: () => setAssignSpoolModal({
|
|
|
+ printerId: printer.id,
|
|
|
+ amsId: ams.id,
|
|
|
+ trayId: htSlotId,
|
|
|
+ trayInfo: {
|
|
|
+ type: '',
|
|
|
+ color: '',
|
|
|
+ location: getAmsLabel(ams.id, ams.tray.length),
|
|
|
+ },
|
|
|
+ }),
|
|
|
+ }}
|
|
|
>
|
|
|
{slotVisual}
|
|
|
</EmptySlotHoverCard>
|
|
|
@@ -3755,7 +3779,7 @@ function PrinterCard({
|
|
|
|
|
|
const extFilamentData = {
|
|
|
vendor: (isBambuLabSpool(extTray) ? 'Bambu Lab' : 'Generic') as 'Bambu Lab' | 'Generic',
|
|
|
- profile: extSlotPreset?.preset_name || extCloudInfo?.name || extTray.tray_sub_brands || extTray.tray_type || 'Unknown',
|
|
|
+ profile: extSlotPreset?.preset_name || extCloudInfo?.name || extInventoryAssignment?.spool?.slicer_filament_name || extTray.tray_sub_brands || extTray.tray_type || 'Unknown',
|
|
|
colorName: getBambuColorName(extTray.tray_id_name) || hexToColorName(extTray.tray_color),
|
|
|
colorHex: extTray.tray_color || null,
|
|
|
kFactor: formatKValue(extTray.k),
|
|
|
@@ -3868,6 +3892,18 @@ function PrinterCard({
|
|
|
extruderId: isDualNozzle ? (extTrayId === 254 ? 1 : 0) : undefined,
|
|
|
}),
|
|
|
}}
|
|
|
+ inventory={spoolmanEnabled ? undefined : {
|
|
|
+ onAssignSpool: () => setAssignSpoolModal({
|
|
|
+ printerId: printer.id,
|
|
|
+ amsId: 255,
|
|
|
+ trayId: slotTrayId,
|
|
|
+ trayInfo: {
|
|
|
+ type: '',
|
|
|
+ color: '',
|
|
|
+ location: extLabel || t('printers.external'),
|
|
|
+ },
|
|
|
+ }),
|
|
|
+ }}
|
|
|
>
|
|
|
{extSlotContent}
|
|
|
</EmptySlotHoverCard>
|