﻿<?xml version="1.0" encoding="utf-16"?>
<Template xmlns:jiwa="http://www.jiwa.com.au/xml/schemas">
  <RecID xmlns="JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.XML">6a2ce7f7-c672-4c98-8bce-ee845c62bdb6</RecID>
  <Name xmlns="JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.XML">Product Metadata</Name>
  <IsEnabled xmlns="JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.XML">false</IsEnabled>
  <Code xmlns="JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.XML">Imports JiwaFinancials.Jiwa
Imports Microsoft.VisualBasic
Imports System.Windows.Forms
Imports System.Data.SqlClient
Imports System.Drawing
Imports System.Data

Public Class TemplateAttributeHandler
    Inherits System.MarshalByRefObject
    Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryTemplateAttribute

    Public Sub FormatCell(ByVal Attribute As JiwaInventory.Configuration.AttributeGroupTemplate.Attribute, ByVal GridObject As JiwaFinancials.Jiwa.JiwaApplication.Controls.JiwaGrid, ByVal Col As Integer, ByVal Row As Integer) Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryTemplateAttribute.FormatCell

    End Sub

    Public Sub ReadData(ByVal Attribute As JiwaInventory.Configuration.AttributeGroupTemplate.Attribute, ByVal GridObject As JiwaFinancials.Jiwa.JiwaApplication.Controls.JiwaGrid, ByRef Value As String, ByRef DisplayValue As String) Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryTemplateAttribute.ReadData
        ' Example of how to resolve an inventory id to a part no.
        'If Attribute.Name = "Inventory" AndAlso Value IsNot Nothing AndAlso Value.Trim.Length &gt; 0 Then
        '    Dim inventoryItem As JiwaApplication.Entities.Inventory.Inventory = Attribute.Manager.EntityFactory.CreateEntity(Of JiwaApplication.Entities.Inventory.Inventory)()
        '    inventoryItem.ReadRecord(Value)
        '    DisplayValue = inventoryItem.PartNo
        'End If
    End Sub

    Public Sub ButtonClicked(ByVal Attribute As JiwaInventory.Configuration.AttributeGroupTemplate.Attribute, ByVal GridObject As JiwaFinancials.Jiwa.JiwaApplication.Controls.JiwaGrid, ByRef Value As String, ByRef DisplayValue As String) Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryTemplateAttribute.ButtonClicked
        ' Example of how to search for an inventory item
        'If Attribute.Name = "Inventory"  Then
        '   Dim inventoryItem As JiwaApplication.Entities.Inventory.Inventory = GridObject.Manager.EntityFactory.CreateEntity(Of JiwaApplication.Entities.Inventory.Inventory)()
        '   inventoryItem.Search(GridObject.FindForm, "")
        '   Value = inventoryItem.InventoryID 
        '   DisplayValue = inventoryItem.PartNo 
        'End If
    End Sub
End Class

Public Class AttributeHandler
    Inherits System.MarshalByRefObject
    Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryAttribute

    Public Sub FormatCell(ByVal Attribute As JiwaInventory.AttributeValue, ByVal GridObject As JiwaFinancials.Jiwa.JiwaApplication.Controls.JiwaGrid, ByVal Col As Integer, ByVal Row As Integer) Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryAttribute.FormatCell

    End Sub

    Public Sub ReadData(ByVal Attribute As JiwaInventory.AttributeValue, ByVal GridObject As JiwaFinancials.Jiwa.JiwaApplication.Controls.JiwaGrid, ByRef Value As String, ByRef DisplayValue As String) Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryAttribute.ReadData
        ' Example of how to resolve an inventory id to a part no.
        'If Attribute.TemplateAttribute.Name = "Inventory" AndAlso Value IsNot Nothing AndAlso Value.Trim.Length &gt; 0 Then
        '    Dim inventoryItem As JiwaApplication.Entities.Inventory.Inventory = Attribute.Manager.EntityFactory.CreateEntity(Of JiwaApplication.Entities.Inventory.Inventory)()
        '    inventoryItem.ReadRecord(Value)
        '    DisplayValue = inventoryItem.PartNo
        'End If
    End Sub

    Public Sub ButtonClicked(ByVal Attribute As JiwaInventory.AttributeValue, ByVal GridObject As JiwaFinancials.Jiwa.JiwaApplication.Controls.JiwaGrid, ByRef Value As String, ByRef DisplayValue As String) Implements JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.IJiwaInventoryAttribute.ButtonClicked
        ' Example of how to search for an inventory item
        'If Attribute.TemplateAttribute.Name = "Inventory" Then
        '   Dim inventoryItem As JiwaApplication.Entities.Inventory.Inventory = Attribute.Manager.EntityFactory.CreateEntity(Of JiwaApplication.Entities.Inventory.Inventory)()
        '   inventoryItem.Search(GridObject.FindForm, "")
        '   Value = inventoryItem.InventoryID 
        '   DisplayValue = inventoryItem.PartNo 
        'End If
    End Sub
End Class

</Code>
  <LastSavedDateTime xmlns="JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.XML">2023-02-14T02:24:46.943</LastSavedDateTime>
  <Attributes xmlns="JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.XML">
    <Attribute>
      <RecID>052465b3-cf67-492c-89e1-dc125a297f75</RecID>
      <Name>field1</Name>
      <AttributeType>e_TemplateAttributeCellTypeText</AttributeType>
      <ComboText />
      <DefaultValue />
      <ItemNo>1</ItemNo>
      <LastSavedDateTime>2023-02-14T02:24:46.947</LastSavedDateTime>
    </Attribute>
    <Attribute>
      <RecID>e04bc485-1230-470c-866b-11e48c354e76</RecID>
      <Name>field2</Name>
      <AttributeType>e_TemplateAttributeCellTypeText</AttributeType>
      <ComboText />
      <DefaultValue />
      <ItemNo>2</ItemNo>
      <LastSavedDateTime>2023-02-14T02:24:46.947</LastSavedDateTime>
    </Attribute>
    <Attribute>
      <RecID>b4b6dcde-d362-4324-a2d5-e425616c88bf</RecID>
      <Name>field3</Name>
      <AttributeType>e_TemplateAttributeCellTypeText</AttributeType>
      <ComboText />
      <DefaultValue />
      <ItemNo>3</ItemNo>
      <LastSavedDateTime>2023-02-14T02:24:46.947</LastSavedDateTime>
    </Attribute>
    <Attribute>
      <RecID>9e3dbb5c-ee3b-447a-b122-c97d62a9363d</RecID>
      <Name>field4</Name>
      <AttributeType>e_TemplateAttributeCellTypeText</AttributeType>
      <ComboText />
      <DefaultValue />
      <ItemNo>4</ItemNo>
      <LastSavedDateTime>2023-02-14T02:24:46.947</LastSavedDateTime>
    </Attribute>
  </Attributes>
  <References xmlns="JiwaFinancials.Jiwa.JiwaInventory.Configuration.AttributeGroupTemplate.XML">
    <Reference>
      <RecID>654bb43d-b248-4b70-9124-6a773ee617b7</RecID>
      <AssemblyFullName>mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>a66fd70e-b8ea-4a66-898b-f64d960c8c78</RecID>
      <AssemblyFullName>Microsoft.VisualBasic, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>691c7383-ec72-4c12-8f38-d0c1827c045f</RecID>
      <AssemblyFullName>System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>8c168cf5-a6ce-4e96-a358-67e70dd89f1e</RecID>
      <AssemblyFullName>JiwaApplication, Version=7.2.1.0, Culture=neutral, PublicKeyToken=e30ce81e37f29c8c</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>c3bc51c0-c26f-429c-9e21-5a9157f4216c</RecID>
      <AssemblyFullName>System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>e721540c-ee42-4598-83d5-51e3ed9a75c8</RecID>
      <AssemblyFullName>FarPoint.Win, Version=8.35.20151.0, Culture=neutral, PublicKeyToken=327c3516b1b18457</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>6f392b70-2914-4244-b285-09c516e4f8de</RecID>
      <AssemblyFullName>JiwaLib, Version=7.2.1.0, Culture=neutral, PublicKeyToken=e30ce81e37f29c8c</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>fa49f270-50b5-417a-9a7a-355990d717df</RecID>
      <AssemblyFullName>System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>081804c9-6724-419d-8477-a4e6566668f4</RecID>
      <AssemblyFullName>JiwaODBC, Version=7.2.1.0, Culture=neutral, PublicKeyToken=e30ce81e37f29c8c</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>fea416b7-1f9a-4d1c-a97f-0314e2c7f3fb</RecID>
      <AssemblyFullName>System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>929c0529-924c-46a2-b5a6-056c45f685a1</RecID>
      <AssemblyFullName>FarPoint.Win.Spread, Version=8.35.20151.0, Culture=neutral, PublicKeyToken=327c3516b1b18457</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>91842112-f8e9-4ebb-98a6-04166d87ef7f</RecID>
      <AssemblyFullName>Microsoft.VisualBasic.Compatibility, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>f54da5e6-84fd-40fe-a3ea-4c55ef39f8b7</RecID>
      <AssemblyFullName>JiwaInventoryUI, Version=7.2.1.0, Culture=neutral, PublicKeyToken=e30ce81e37f29c8c</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>e067293f-6404-4b10-bec7-ae8be601360f</RecID>
      <AssemblyFullName>JiwaInventory, Version=7.2.1.0, Culture=neutral, PublicKeyToken=e30ce81e37f29c8c</AssemblyFullName>
    </Reference>
    <Reference>
      <RecID>4150c96b-2563-4293-bbf1-43ee11880c5a</RecID>
      <AssemblyFullName>JiwaServiceModel, Version=7.2.1.0, Culture=neutral, PublicKeyToken=e30ce81e37f29c8c</AssemblyFullName>
    </Reference>
  </References>
</Template>