Refactor Dashboard Component Styles for Consistency and Readability
- Updated various dashboard components to ensure consistent styling, including setting height to 100% for better layout management. - Reformatted import statements for improved readability. - Adjusted master filter formatting in ObjectTable components for enhanced clarity and consistency across the codebase. - Improved overall code structure for better maintainability and visual alignment.
This commit is contained in:
parent
d9f3bb185f
commit
89fc70a8ea
@ -27,7 +27,10 @@ import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import OrderItemIcon from '../../../Icons/OrderItemIcon.jsx'
|
||||
import ShipmentIcon from '../../../Icons/ShipmentIcon.jsx'
|
||||
|
||||
@ -91,7 +94,7 @@ const InvoiceInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -100,6 +103,7 @@ const InvoiceInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -257,7 +261,9 @@ const InvoiceInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='payment'
|
||||
masterFilter={{ invoice: getModelByName('invoice').prefix + ':' + invoiceId }}
|
||||
masterFilter={{
|
||||
invoice: getModelByName('invoice').prefix + ':' + invoiceId
|
||||
}}
|
||||
visibleColumns={{ invoice: false }}
|
||||
/>
|
||||
)}
|
||||
@ -274,7 +280,7 @@ const InvoiceInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={invoiceId} type='invoice' />
|
||||
<NotesPanel _id={invoiceId} type='invoice' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -291,10 +297,7 @@ const InvoiceInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('invoice').prefix +
|
||||
':' +
|
||||
invoiceId
|
||||
parent: getModelByName('invoice').prefix + ':' + invoiceId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -93,7 +93,7 @@ const PaymentPolicyInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -84,7 +84,7 @@ const PaymentInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -93,6 +93,7 @@ const PaymentInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -209,7 +210,7 @@ const PaymentInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={paymentId} type='payment' />
|
||||
<NotesPanel _id={paymentId} type='payment' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
|
||||
@ -77,7 +77,7 @@ const TaxRecordInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -85,14 +85,14 @@ const TaxRecordInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='taxRecord'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={taxRecordId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -193,7 +193,7 @@ const TaxRecordInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={taxRecordId} type='taxRecord' />
|
||||
<NotesPanel _id={taxRecordId} type='taxRecord' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -212,10 +212,8 @@ const TaxRecordInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('taxRecord').prefix +
|
||||
':' +
|
||||
taxRecordId
|
||||
parent:
|
||||
getModelByName('taxRecord').prefix + ':' + taxRecordId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -87,14 +87,14 @@ const FilamentStockInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='filamentStock'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={filamentStockId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -197,7 +197,12 @@ const FilamentStockInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='stockEvent'
|
||||
masterFilter={{ parent: getModelByName('filamentStock').prefix + ':' + filamentStockId }}
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('filamentStock').prefix +
|
||||
':' +
|
||||
filamentStockId
|
||||
}}
|
||||
visibleColumns={{ parent: false }}
|
||||
/>
|
||||
)}
|
||||
@ -232,7 +237,7 @@ const FilamentStockInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={filamentStockId} type='filamentStock' />
|
||||
<NotesPanel _id={filamentStockId} type='filamentStock' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -251,10 +256,10 @@ const FilamentStockInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('filamentStock').prefix +
|
||||
':' +
|
||||
filamentStockId
|
||||
parent:
|
||||
getModelByName('filamentStock').prefix +
|
||||
':' +
|
||||
filamentStockId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -78,7 +78,7 @@ const OrderItemInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -88,6 +88,7 @@ const OrderItemInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -96,7 +97,7 @@ const OrderItemInfo = () => {
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='orderItem'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={orderItemId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -204,7 +205,7 @@ const OrderItemInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={orderItemId} type='orderItem' />
|
||||
<NotesPanel _id={orderItemId} type='orderItem' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -223,10 +224,8 @@ const OrderItemInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('orderItem').prefix +
|
||||
':' +
|
||||
orderItemId
|
||||
parent:
|
||||
getModelByName('orderItem').prefix + ':' + orderItemId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -93,6 +93,7 @@ const PartStockInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -101,7 +102,7 @@ const PartStockInfo = () => {
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='partStock'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={partStockId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -214,7 +215,10 @@ const PartStockInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='stockEvent'
|
||||
masterFilter={{ parent: getModelByName('partStock').prefix + ':' + partStockId }}
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('partStock').prefix + ':' + partStockId
|
||||
}}
|
||||
visibleColumns={{ parent: false }}
|
||||
/>
|
||||
)}
|
||||
@ -251,7 +255,7 @@ const PartStockInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={partStockId} type='partStock' />
|
||||
<NotesPanel _id={partStockId} type='partStock' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -271,10 +275,8 @@ const PartStockInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('partStock').prefix +
|
||||
':' +
|
||||
partStockId
|
||||
parent:
|
||||
getModelByName('partStock').prefix + ':' + partStockId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -109,6 +109,7 @@ const ProductStockInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
|
||||
@ -102,7 +102,7 @@ const PurchaseOrderInfo = () => {
|
||||
orderItemsTableRef?.current?.handleUpdate?.()
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -111,6 +111,7 @@ const PurchaseOrderInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -230,7 +231,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='orderItem'
|
||||
masterFilter={{
|
||||
order: getModelByName('purchaseOrder').prefix + ':' + purchaseOrderId,
|
||||
order:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId,
|
||||
orderType: 'purchaseOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -249,7 +253,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='shipment'
|
||||
masterFilter={{
|
||||
order: getModelByName('purchaseOrder').prefix + ':' + purchaseOrderId,
|
||||
order:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId,
|
||||
orderType: 'purchaseOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -271,7 +278,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='invoice'
|
||||
masterFilter={{
|
||||
order: getModelByName('purchaseOrder').prefix + ':' + purchaseOrderId,
|
||||
order:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId,
|
||||
orderType: 'purchaseOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -293,7 +303,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='stockEvent'
|
||||
masterFilter={{
|
||||
owner: getModelByName('purchaseOrder').prefix + ':' + purchaseOrderId
|
||||
owner:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId
|
||||
}}
|
||||
/>
|
||||
)}
|
||||
@ -314,7 +327,7 @@ const PurchaseOrderInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={purchaseOrderId} type='purchaseOrder' />
|
||||
<NotesPanel _id={purchaseOrderId} type='purchaseOrder' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -331,10 +344,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId
|
||||
parent:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -121,6 +121,7 @@ const PurchaseOrderInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -129,7 +130,7 @@ const PurchaseOrderInfo = () => {
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='purchaseOrder'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={purchaseOrderId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -233,7 +234,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='orderItem'
|
||||
masterFilter={{
|
||||
order: getModelByName('purchaseOrder').prefix + ':' + purchaseOrderId,
|
||||
order:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId,
|
||||
orderType: 'purchaseOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -252,7 +256,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='shipment'
|
||||
masterFilter={{
|
||||
order: getModelByName('purchaseOrder').prefix + ':' + purchaseOrderId,
|
||||
order:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId,
|
||||
orderType: 'purchaseOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -275,7 +282,7 @@ const PurchaseOrderInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={purchaseOrderId} type='purchaseOrder' />
|
||||
<NotesPanel _id={purchaseOrderId} type='purchaseOrder' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -294,10 +301,10 @@ const PurchaseOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId
|
||||
parent:
|
||||
getModelByName('purchaseOrder').prefix +
|
||||
':' +
|
||||
purchaseOrderId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -96,6 +96,7 @@ const ShipmentInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
|
||||
@ -26,7 +26,10 @@ import ObjectTable from '../../common/ObjectTable.jsx'
|
||||
import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
|
||||
const log = loglevel.getLogger('StockAuditInfo')
|
||||
@ -92,6 +95,7 @@ const StockAuditInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -180,7 +184,9 @@ const StockAuditInfo = () => {
|
||||
title='Stock Audit Information'
|
||||
icon={<InfoCircleIcon />}
|
||||
active={collapseState.info}
|
||||
onToggle={(expanded) => updateCollapseState('info', expanded)}
|
||||
onToggle={(expanded) =>
|
||||
updateCollapseState('info', expanded)
|
||||
}
|
||||
collapseKey='info'
|
||||
>
|
||||
<ObjectInfo
|
||||
@ -262,9 +268,7 @@ const StockAuditInfo = () => {
|
||||
title='Audit Logs'
|
||||
icon={<AuditLogIcon />}
|
||||
active={collapseState.auditLogs}
|
||||
onToggle={(expanded) =>
|
||||
updateCollapseState('auditLogs', expanded)
|
||||
}
|
||||
onToggle={(expanded) => updateCollapseState('auditLogs', expanded)}
|
||||
collapseKey='auditLogs'
|
||||
>
|
||||
{objectFormState.loading ? (
|
||||
@ -274,9 +278,7 @@ const StockAuditInfo = () => {
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('stockAudit').prefix +
|
||||
':' +
|
||||
stockAuditId
|
||||
getModelByName('stockAudit').prefix + ':' + stockAuditId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -98,6 +98,7 @@ const StockLocationInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -106,7 +107,7 @@ const StockLocationInfo = () => {
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='stockLocation'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={stockLocationId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -329,7 +330,7 @@ const StockLocationInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={stockLocationId} type='stockLocation' />
|
||||
<NotesPanel _id={stockLocationId} type='stockLocation' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -349,10 +350,10 @@ const StockLocationInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('stockLocation').prefix +
|
||||
':' +
|
||||
stockLocationId
|
||||
parent:
|
||||
getModelByName('stockLocation').prefix +
|
||||
':' +
|
||||
stockLocationId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -8,7 +8,10 @@ import InfoCollapse from '../../common/InfoCollapse.jsx'
|
||||
import ObjectInfo from '../../common/ObjectInfo.jsx'
|
||||
import ObjectProperty from '../../common/ObjectProperty.jsx'
|
||||
import ViewButton from '../../common/ViewButton.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import InfoCircleIcon from '../../../Icons/InfoCircleIcon.jsx'
|
||||
import NoteIcon from '../../../Icons/NoteIcon.jsx'
|
||||
import AuditLogIcon from '../../../Icons/AuditLogIcon.jsx'
|
||||
@ -89,7 +92,7 @@ const StockTransferInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current.handleUpdate()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -98,6 +101,7 @@ const StockTransferInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -263,7 +267,7 @@ const StockTransferInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={stockTransferId} type='stockTransfer' />
|
||||
<NotesPanel _id={stockTransferId} type='stockTransfer' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -281,10 +285,10 @@ const StockTransferInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('stockTransfer').prefix +
|
||||
':' +
|
||||
stockTransferId
|
||||
parent:
|
||||
getModelByName('stockTransfer').prefix +
|
||||
':' +
|
||||
stockTransferId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -87,7 +87,7 @@ const AppPasswordInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
@ -196,10 +196,8 @@ const AppPasswordInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('appPassword').prefix +
|
||||
':' +
|
||||
appPasswordId
|
||||
parent:
|
||||
getModelByName('appPassword').prefix + ':' + appPasswordId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -25,7 +25,10 @@ import ObjectTable from '../../common/ObjectTable.jsx'
|
||||
import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
|
||||
const log = loglevel.getLogger('CourierServiceInfo')
|
||||
@ -82,7 +85,7 @@ const CourierServiceInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -90,14 +93,14 @@ const CourierServiceInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='courierService'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={courierServiceId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -222,7 +225,7 @@ const CourierServiceInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={courierServiceId} type='courierService' />
|
||||
<NotesPanel _id={courierServiceId} type='courierService' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -241,10 +244,10 @@ const CourierServiceInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('courierService').prefix +
|
||||
':' +
|
||||
courierServiceId
|
||||
parent:
|
||||
getModelByName('courierService').prefix +
|
||||
':' +
|
||||
courierServiceId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -75,7 +75,7 @@ const CourierInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -83,14 +83,14 @@ const CourierInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='courier'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={courierId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -193,7 +193,9 @@ const CourierInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='courierService'
|
||||
masterFilter={{ courier: getModelByName('courier').prefix + ':' + courierId }}
|
||||
masterFilter={{
|
||||
courier: getModelByName('courier').prefix + ':' + courierId
|
||||
}}
|
||||
visibleColumns={{
|
||||
courier: false
|
||||
}}
|
||||
@ -212,7 +214,7 @@ const CourierInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={courierId} type='courier' />
|
||||
<NotesPanel _id={courierId} type='courier' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -231,10 +233,7 @@ const CourierInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('courier').prefix +
|
||||
':' +
|
||||
courierId
|
||||
parent: getModelByName('courier').prefix + ':' + courierId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -87,14 +87,14 @@ const DocumentJobInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='documentJob'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={documentJobId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -196,7 +196,7 @@ const DocumentJobInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={documentJobId} type='documentJob' />
|
||||
<NotesPanel _id={documentJobId} type='documentJob' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -215,10 +215,8 @@ const DocumentJobInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('documentJob').prefix +
|
||||
':' +
|
||||
documentJobId
|
||||
parent:
|
||||
getModelByName('documentJob').prefix + ':' + documentJobId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -91,6 +91,7 @@ const DocumentPrinterInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
|
||||
@ -87,14 +87,14 @@ const DocumentSizeInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='documentSize'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={documentSizeId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -197,7 +197,7 @@ const DocumentSizeInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={documentSizeId} type='documentSize' />
|
||||
<NotesPanel _id={documentSizeId} type='documentSize' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -216,10 +216,10 @@ const DocumentSizeInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('documentSize').prefix +
|
||||
':' +
|
||||
documentSizeId
|
||||
parent:
|
||||
getModelByName('documentSize').prefix +
|
||||
':' +
|
||||
documentSizeId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -97,6 +97,7 @@ const DocumentTemplateInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
|
||||
@ -88,7 +88,7 @@ const EmailAccountInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -23,7 +23,10 @@ import ObjectTable from '../../common/ObjectTable.jsx'
|
||||
import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import { getModelByName, getModelProperty } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelByName,
|
||||
getModelProperty
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
import TemplatePreview from '../../common/TemplatePreview.jsx'
|
||||
|
||||
@ -74,7 +77,7 @@ const EmailMessageInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -25,7 +25,10 @@ import ObjectTable from '../../common/ObjectTable.jsx'
|
||||
import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import { getModelByName, getModelProperty } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelByName,
|
||||
getModelProperty
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
|
||||
const log = loglevel.getLogger('EmailTemplateInfo')
|
||||
@ -92,7 +95,7 @@ const EmailTemplateInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -74,7 +74,7 @@ const FilamentSkuInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -82,14 +82,14 @@ const FilamentSkuInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='filamentSku'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={filamentSkuId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -190,7 +190,7 @@ const FilamentSkuInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={filamentSkuId} type='filamentSku' />
|
||||
<NotesPanel _id={filamentSkuId} type='filamentSku' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -209,10 +209,8 @@ const FilamentSkuInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('filamentSku').prefix +
|
||||
':' +
|
||||
filamentSkuId
|
||||
parent:
|
||||
getModelByName('filamentSku').prefix + ':' + filamentSkuId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -92,7 +92,7 @@ const FilamentInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -101,6 +101,7 @@ const FilamentInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -220,7 +221,9 @@ const FilamentInfo = () => {
|
||||
<ObjectTable
|
||||
ref={filamentSkusTableRef}
|
||||
type='filamentSku'
|
||||
masterFilter={{ filament: getModelByName('filament').prefix + ':' + filamentId }}
|
||||
masterFilter={{
|
||||
filament: getModelByName('filament').prefix + ':' + filamentId
|
||||
}}
|
||||
visibleColumns={{ filament: false }}
|
||||
/>
|
||||
)}
|
||||
@ -238,7 +241,9 @@ const FilamentInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='filamentStock'
|
||||
masterFilter={{ filament: getModelByName('filament').prefix + ':' + filamentId }}
|
||||
masterFilter={{
|
||||
filament: getModelByName('filament').prefix + ':' + filamentId
|
||||
}}
|
||||
visibleColumns={{
|
||||
filament: false,
|
||||
startingWeight: false
|
||||
@ -259,7 +264,7 @@ const FilamentInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={filamentId} type='filament' />
|
||||
<NotesPanel _id={filamentId} type='filament' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -277,10 +282,7 @@ const FilamentInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('filament').prefix +
|
||||
':' +
|
||||
filamentId
|
||||
parent: getModelByName('filament').prefix + ':' + filamentId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -98,7 +98,7 @@ const FileInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -87,7 +87,7 @@ const HostInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current.handleUpdate()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -96,6 +96,7 @@ const HostInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -213,7 +214,9 @@ const HostInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='printer'
|
||||
masterFilter={{ host: getModelByName('host').prefix + ':' + hostId }}
|
||||
masterFilter={{
|
||||
host: getModelByName('host').prefix + ':' + hostId
|
||||
}}
|
||||
visibleColumns={{
|
||||
host: false
|
||||
}}
|
||||
@ -234,7 +237,9 @@ const HostInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='documentPrinter'
|
||||
masterFilter={{ host: getModelByName('host').prefix + ':' + hostId }}
|
||||
masterFilter={{
|
||||
host: getModelByName('host').prefix + ':' + hostId
|
||||
}}
|
||||
visibleColumns={{
|
||||
host: false
|
||||
}}
|
||||
@ -254,7 +259,7 @@ const HostInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={hostId} type='host' />
|
||||
<NotesPanel _id={hostId} type='host' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -272,10 +277,7 @@ const HostInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('host').prefix +
|
||||
':' +
|
||||
hostId
|
||||
parent: getModelByName('host').prefix + ':' + hostId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -77,7 +77,7 @@ const MaterialInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -85,14 +85,14 @@ const MaterialInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='material'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={materialId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -193,7 +193,7 @@ const MaterialInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={materialId} type='material' />
|
||||
<NotesPanel _id={materialId} type='material' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -212,10 +212,7 @@ const MaterialInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('material').prefix +
|
||||
':' +
|
||||
materialId
|
||||
parent: getModelByName('material').prefix + ':' + materialId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -77,14 +77,14 @@ const NoteTypeInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='noteType'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={noteTypeId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -188,10 +188,7 @@ const NoteTypeInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('noteType').prefix +
|
||||
':' +
|
||||
noteTypeId
|
||||
parent: getModelByName('noteType').prefix + ':' + noteTypeId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -27,7 +27,10 @@ import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
|
||||
const log = loglevel.getLogger('NoteInfo')
|
||||
log.setLevel(config.logLevel)
|
||||
@ -83,7 +86,7 @@ const NoteInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -91,14 +94,14 @@ const NoteInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='note'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={noteId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -226,7 +229,7 @@ const NoteInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={noteId} type='note' />
|
||||
<NotesPanel _id={noteId} type='note' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -245,10 +248,7 @@ const NoteInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('note').prefix +
|
||||
':' +
|
||||
noteId
|
||||
parent: getModelByName('note').prefix + ':' + noteId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -69,7 +69,7 @@ const PartSkuInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -77,14 +77,14 @@ const PartSkuInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='partSku'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={partSkuId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -185,7 +185,7 @@ const PartSkuInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={partSkuId} type='partSku' />
|
||||
<NotesPanel _id={partSkuId} type='partSku' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -204,10 +204,7 @@ const PartSkuInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('partSku').prefix +
|
||||
':' +
|
||||
partSkuId
|
||||
parent: getModelByName('partSku').prefix + ':' + partSkuId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -88,7 +88,7 @@ const PartInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
@ -197,7 +197,9 @@ const PartInfo = () => {
|
||||
<ObjectTable
|
||||
ref={partSkusTableRef}
|
||||
type='partSku'
|
||||
masterFilter={{ part: getModelByName('part').prefix + ':' + partId }}
|
||||
masterFilter={{
|
||||
part: getModelByName('part').prefix + ':' + partId
|
||||
}}
|
||||
visibleColumns={{ part: false }}
|
||||
/>
|
||||
)}
|
||||
@ -215,7 +217,7 @@ const PartInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={partId} type='part' />
|
||||
<NotesPanel _id={partId} type='part' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -232,10 +234,7 @@ const PartInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('part').prefix +
|
||||
':' +
|
||||
partId
|
||||
parent: getModelByName('part').prefix + ':' + partId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -80,7 +80,7 @@ const PermissionSettingInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -88,14 +88,14 @@ const PermissionSettingInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='permissionSetting'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={permissionSettingId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -227,10 +227,10 @@ const PermissionSettingInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel
|
||||
_id={permissionSettingId}
|
||||
type='permissionSetting'
|
||||
/>
|
||||
<NotesPanel
|
||||
_id={permissionSettingId}
|
||||
type='permissionSetting'
|
||||
/>
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
|
||||
@ -23,7 +23,10 @@ import ObjectTable from '../../common/ObjectTable.jsx'
|
||||
import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
|
||||
const ProductCategoryInfo = () => {
|
||||
@ -77,7 +80,7 @@ const ProductCategoryInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -85,14 +88,14 @@ const ProductCategoryInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='productCategory'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={productCategoryId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -217,7 +220,7 @@ const ProductCategoryInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={productCategoryId} type='productCategory' />
|
||||
<NotesPanel _id={productCategoryId} type='productCategory' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -236,10 +239,10 @@ const ProductCategoryInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('productCategory').prefix +
|
||||
':' +
|
||||
productCategoryId
|
||||
parent:
|
||||
getModelByName('productCategory').prefix +
|
||||
':' +
|
||||
productCategoryId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -23,7 +23,10 @@ import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
import ObjectProperty from '../../common/ObjectProperty.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import PartIcon from '../../../Icons/PartIcon.jsx'
|
||||
|
||||
const ProductSkuInfo = () => {
|
||||
@ -75,7 +78,7 @@ const ProductSkuInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -83,14 +86,14 @@ const ProductSkuInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='productSku'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={productSkuId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -217,7 +220,7 @@ const ProductSkuInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={productSkuId} type='productSku' />
|
||||
<NotesPanel _id={productSkuId} type='productSku' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -236,10 +239,8 @@ const ProductSkuInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('productSku').prefix +
|
||||
':' +
|
||||
productSkuId
|
||||
parent:
|
||||
getModelByName('productSku').prefix + ':' + productSkuId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -88,7 +88,7 @@ const ProductInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
@ -200,7 +200,10 @@ const ProductInfo = () => {
|
||||
<ObjectTable
|
||||
ref={productSkusTableRef}
|
||||
type='productSku'
|
||||
masterFilter={{ product: getModelByName('product').prefix + ':' + productId }}
|
||||
masterFilter={{
|
||||
product:
|
||||
getModelByName('product').prefix + ':' + productId
|
||||
}}
|
||||
visibleColumns={{ product: false }}
|
||||
/>
|
||||
)}
|
||||
@ -222,7 +225,7 @@ const ProductInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={productId} type='product' />
|
||||
<NotesPanel _id={productId} type='product' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -239,10 +242,7 @@ const ProductInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('product').prefix +
|
||||
':' +
|
||||
productId
|
||||
parent: getModelByName('product').prefix + ':' + productId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -22,7 +22,10 @@ import ObjectTable from '../../common/ObjectTable.jsx'
|
||||
import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
|
||||
const StockAuditLevelInfo = () => {
|
||||
@ -82,7 +85,7 @@ const StockAuditLevelInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
@ -232,9 +235,7 @@ const StockAuditLevelInfo = () => {
|
||||
title='Audit Logs'
|
||||
icon={<AuditLogIcon />}
|
||||
active={collapseState.auditLogs}
|
||||
onToggle={(expanded) =>
|
||||
updateCollapseState('auditLogs', expanded)
|
||||
}
|
||||
onToggle={(expanded) => updateCollapseState('auditLogs', expanded)}
|
||||
collapseKey='auditLogs'
|
||||
>
|
||||
{objectFormState.loading ? (
|
||||
|
||||
@ -25,7 +25,10 @@ import ObjectTable from '../../common/ObjectTable.jsx'
|
||||
import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
|
||||
const log = loglevel.getLogger('TaxRateInfo')
|
||||
@ -77,7 +80,7 @@ const TaxRateInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -85,14 +88,14 @@ const TaxRateInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='taxRate'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={taxRateId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -217,7 +220,7 @@ const TaxRateInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={taxRateId} type='taxRate' />
|
||||
<NotesPanel _id={taxRateId} type='taxRate' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -236,10 +239,7 @@ const TaxRateInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('taxRate').prefix +
|
||||
':' +
|
||||
taxRateId
|
||||
parent: getModelByName('taxRate').prefix + ':' + taxRateId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -80,14 +80,14 @@ const UserGroupInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
@ -243,7 +243,7 @@ const UserGroupInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={userGroupId} type='userGroup' />
|
||||
<NotesPanel _id={userGroupId} type='userGroup' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
|
||||
@ -86,7 +86,7 @@ const UserInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
@ -264,7 +264,7 @@ const UserInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={userId} type='user' />
|
||||
<NotesPanel _id={userId} type='user' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
|
||||
@ -74,7 +74,7 @@ const VendorInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -82,14 +82,14 @@ const VendorInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='vendor'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={vendorId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -190,7 +190,7 @@ const VendorInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={vendorId} type='vendor' />
|
||||
<NotesPanel _id={vendorId} type='vendor' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -209,10 +209,7 @@ const VendorInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('vendor').prefix +
|
||||
':' +
|
||||
vendorId
|
||||
parent: getModelByName('vendor').prefix + ':' + vendorId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -111,14 +111,14 @@ const FilamentProfileInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify='space-between'>
|
||||
<Space size='small'>
|
||||
@ -529,7 +529,7 @@ const FilamentProfileInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={filamentProfileId} type='filamentProfile' />
|
||||
<NotesPanel _id={filamentProfileId} type='filamentProfile' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -547,10 +547,10 @@ const FilamentProfileInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('filamentProfile').prefix +
|
||||
':' +
|
||||
filamentProfileId
|
||||
parent:
|
||||
getModelByName('filamentProfile').prefix +
|
||||
':' +
|
||||
filamentProfileId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -25,7 +25,10 @@ import InfoCollapsePlaceholder from '../../common/InfoCollapsePlaceholder.jsx'
|
||||
import InfoActionButtons from '../../common/InfoActionButtons.jsx'
|
||||
import UserNotifierToggle from '../../common/UserNotifierToggle.jsx'
|
||||
import ScrollBox from '../../common/ScrollBox.jsx'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels.js'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels.js'
|
||||
import PartIcon from '../../../Icons/PartIcon.jsx'
|
||||
|
||||
const log = loglevel.getLogger('GCodeFileInfo')
|
||||
@ -91,6 +94,7 @@ const GCodeFileInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -99,7 +103,7 @@ const GCodeFileInfo = () => {
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='gcodeFile'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={gcodeFileId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -230,7 +234,7 @@ const GCodeFileInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={gcodeFileId} type='gcodeFile' />
|
||||
<NotesPanel _id={gcodeFileId} type='gcodeFile' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -250,10 +254,8 @@ const GCodeFileInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('gcodeFile').prefix +
|
||||
':' +
|
||||
gcodeFileId
|
||||
parent:
|
||||
getModelByName('gcodeFile').prefix + ':' + gcodeFileId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -97,6 +97,7 @@ const JobInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -224,7 +225,7 @@ const JobInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={jobId} type='job' />
|
||||
<NotesPanel _id={jobId} type='job' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -242,10 +243,7 @@ const JobInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('job').prefix +
|
||||
':' +
|
||||
jobId
|
||||
parent: getModelByName('job').prefix + ':' + jobId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -27,7 +27,10 @@ import UserNotifierToggle from '../../common/UserNotifierToggle'
|
||||
import ViewButton from '../../common/ViewButton'
|
||||
import useCollapseState from '../../hooks/useCollapseState'
|
||||
import ObjectProperty from '../../common/ObjectProperty'
|
||||
import { getModelProperty, getModelByName } from '../../../../database/ObjectModels'
|
||||
import {
|
||||
getModelProperty,
|
||||
getModelByName
|
||||
} from '../../../../database/ObjectModels'
|
||||
import GCodeFileIcon from '../../../Icons/GCodeFileIcon'
|
||||
import SettingsIcon from '../../../Icons/SettingsIcon'
|
||||
import ExclamationOctagonIcon from '../../../Icons/ExclamationOctagonIcon'
|
||||
@ -89,14 +92,14 @@ const PrinterProfileInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify='space-between'>
|
||||
<Space size='small'>
|
||||
@ -380,7 +383,7 @@ const PrinterProfileInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={printerProfileId} type='printerProfile' />
|
||||
<NotesPanel _id={printerProfileId} type='printerProfile' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -398,10 +401,10 @@ const PrinterProfileInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('printerProfile').prefix +
|
||||
':' +
|
||||
printerProfileId
|
||||
parent:
|
||||
getModelByName('printerProfile').prefix +
|
||||
':' +
|
||||
printerProfileId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -98,6 +98,7 @@ const PrinterInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -223,7 +224,9 @@ const PrinterInfo = () => {
|
||||
<ObjectTable
|
||||
ref={profilesTableRef}
|
||||
type='printerProfile'
|
||||
masterFilter={{ printer: getModelByName('printer').prefix + ':' + printerId }}
|
||||
masterFilter={{
|
||||
printer: getModelByName('printer').prefix + ':' + printerId
|
||||
}}
|
||||
visibleColumns={{
|
||||
printer: false,
|
||||
'printer._id': false
|
||||
@ -244,7 +247,7 @@ const PrinterInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={printerId} type='printer' />
|
||||
<NotesPanel _id={printerId} type='printer' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -262,10 +265,7 @@ const PrinterInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('printer').prefix +
|
||||
':' +
|
||||
printerId
|
||||
parent: getModelByName('printer').prefix + ':' + printerId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -77,14 +77,14 @@ const SubJobInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='subJob'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={subJobId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -183,7 +183,9 @@ const SubJobInfo = () => {
|
||||
) : (
|
||||
<ObjectTable
|
||||
type='stockEvent'
|
||||
masterFilter={{ owner: getModelByName('subJob').prefix + ':' + subJobId }}
|
||||
masterFilter={{
|
||||
owner: getModelByName('subJob').prefix + ':' + subJobId
|
||||
}}
|
||||
visibleColumns={{
|
||||
owner: false,
|
||||
'owner.type': false
|
||||
@ -203,7 +205,7 @@ const SubJobInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={subJobId} type='subJob' />
|
||||
<NotesPanel _id={subJobId} type='subJob' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -222,10 +224,7 @@ const SubJobInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('subJob').prefix +
|
||||
':' +
|
||||
subJobId
|
||||
parent: getModelByName('subJob').prefix + ':' + subJobId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -74,7 +74,7 @@ const ClientInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -82,14 +82,14 @@ const ClientInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
<Space size='small'>
|
||||
<ObjectActions
|
||||
type='client'
|
||||
pageName='info'
|
||||
pageName='info'
|
||||
id={clientId}
|
||||
disabled={objectFormState.loading}
|
||||
objectData={objectFormState.objectData}
|
||||
@ -190,7 +190,7 @@ const ClientInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={clientId} type='client' />
|
||||
<NotesPanel _id={clientId} type='client' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -209,10 +209,7 @@ const ClientInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('client').prefix +
|
||||
':' +
|
||||
clientId
|
||||
parent: getModelByName('client').prefix + ':' + clientId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
@ -93,7 +93,7 @@ const FulfillmentPolicyInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -96,14 +96,14 @@ const ListingVarientInfo = () => {
|
||||
finishEdit: () => {
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
@ -256,7 +256,7 @@ const ListingVarientInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={listingVarientId} type='listingVarient' />
|
||||
<NotesPanel _id={listingVarientId} type='listingVarient' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
|
||||
@ -101,7 +101,7 @@ const ListingInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -162,7 +162,7 @@ const MarketplaceInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -93,7 +93,7 @@ const ReturnPolicyInfo = () => {
|
||||
<Flex
|
||||
gap='large'
|
||||
vertical='true'
|
||||
style={{ maxHeight: '100%', minHeight: 0 }}
|
||||
style={{ maxHeight: '100%', height: '100%', minHeight: 0 }}
|
||||
>
|
||||
<Flex justify={'space-between'}>
|
||||
<Space size='small'>
|
||||
|
||||
@ -100,7 +100,7 @@ const SalesOrderInfo = () => {
|
||||
orderItemsTableRef?.current?.handleUpdate?.()
|
||||
objectFormRef?.current?.handleUpdate?.()
|
||||
return true
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
@ -109,6 +109,7 @@ const SalesOrderInfo = () => {
|
||||
vertical='true'
|
||||
style={{
|
||||
maxHeight: '100%',
|
||||
height: '100%',
|
||||
minHeight: 0
|
||||
}}
|
||||
>
|
||||
@ -228,7 +229,10 @@ const SalesOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='orderItem'
|
||||
masterFilter={{
|
||||
order: getModelByName('salesOrder').prefix + ':' + salesOrderId,
|
||||
order:
|
||||
getModelByName('salesOrder').prefix +
|
||||
':' +
|
||||
salesOrderId,
|
||||
orderType: 'salesOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -247,7 +251,10 @@ const SalesOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='shipment'
|
||||
masterFilter={{
|
||||
order: getModelByName('salesOrder').prefix + ':' + salesOrderId,
|
||||
order:
|
||||
getModelByName('salesOrder').prefix +
|
||||
':' +
|
||||
salesOrderId,
|
||||
orderType: 'salesOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -269,7 +276,10 @@ const SalesOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='invoice'
|
||||
masterFilter={{
|
||||
order: getModelByName('salesOrder').prefix + ':' + salesOrderId,
|
||||
order:
|
||||
getModelByName('salesOrder').prefix +
|
||||
':' +
|
||||
salesOrderId,
|
||||
orderType: 'salesOrder'
|
||||
}}
|
||||
visibleColumns={{ order: false }}
|
||||
@ -291,7 +301,10 @@ const SalesOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='stockEvent'
|
||||
masterFilter={{
|
||||
owner: getModelByName('salesOrder').prefix + ':' + salesOrderId
|
||||
owner:
|
||||
getModelByName('salesOrder').prefix +
|
||||
':' +
|
||||
salesOrderId
|
||||
}}
|
||||
/>
|
||||
)}
|
||||
@ -312,7 +325,7 @@ const SalesOrderInfo = () => {
|
||||
indicator={<LoadingOutlined />}
|
||||
>
|
||||
<Card>
|
||||
<NotesPanel _id={salesOrderId} type='salesOrder' />
|
||||
<NotesPanel _id={salesOrderId} type='salesOrder' />
|
||||
</Card>
|
||||
</Spin>
|
||||
</InfoCollapse>
|
||||
@ -329,10 +342,8 @@ const SalesOrderInfo = () => {
|
||||
<ObjectTable
|
||||
type='auditLog'
|
||||
masterFilter={{
|
||||
parent:
|
||||
getModelByName('salesOrder').prefix +
|
||||
':' +
|
||||
salesOrderId
|
||||
parent:
|
||||
getModelByName('salesOrder').prefix + ':' + salesOrderId
|
||||
}}
|
||||
visibleColumns={{ _id: false, parent: false }}
|
||||
/>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user