feat: enhance DetailSparepart component with image upload and preview functionality
This commit is contained in:
@@ -91,7 +91,7 @@ const SparepartCardList = ({
|
||||
display: 'flex',
|
||||
flexDirection: 'column',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
justifyContent: 'flex-start',
|
||||
padding: '16px 8px',
|
||||
height: '100%',
|
||||
}}
|
||||
@@ -100,7 +100,7 @@ const SparepartCardList = ({
|
||||
<Tag
|
||||
color="blue"
|
||||
style={{
|
||||
marginBottom: '12px',
|
||||
marginBottom: '8px',
|
||||
}}
|
||||
>
|
||||
{item.sparepart_item_type}
|
||||
@@ -162,7 +162,7 @@ const SparepartCardList = ({
|
||||
{item[header]}
|
||||
</Title>
|
||||
<Text type="secondary">
|
||||
Available: {item.sparepart_stok || '0'}
|
||||
Available Stock: {item.sparepart_stok || '0'}
|
||||
</Text>
|
||||
<Divider style={{ margin: '8px 0' }} />
|
||||
|
||||
@@ -171,16 +171,16 @@ const SparepartCardList = ({
|
||||
icon={<MinusOutlined />}
|
||||
onClick={() => handleQuantityChange(item.sparepart_id, quantity - 1)}
|
||||
disabled={isLoading}
|
||||
type="text"
|
||||
style={{ width: 28, height: 28 }}
|
||||
/>
|
||||
<Text strong style={{ padding: '0 16px', fontSize: '16px' }}>{quantity}</Text>
|
||||
<Text strong style={{ padding: '0 8px', fontSize: '16px' }}>{quantity}</Text>
|
||||
<Button
|
||||
icon={<PlusOutlined />}
|
||||
onClick={() => handleQuantityChange(item.sparepart_id, quantity + 1)}
|
||||
disabled={isLoading}
|
||||
type="text"
|
||||
style={{ width: 28, height: 28 }}
|
||||
/>
|
||||
<Text type="secondary" style={{ marginLeft: '8px' }}>{item.sparepart_unit || 'pcs'}</Text>
|
||||
<Text type="secondary">{item.sparepart_unit ? ` / ${item.sparepart_unit}` : ' / pcs'}</Text>
|
||||
</Space>
|
||||
|
||||
<Button
|
||||
|
||||
Reference in New Issue
Block a user