Uploading Product and Company Images in e-Business 7.4 and higher version

With the e-Business 7.4 release, the product and company image upload functionality has been automated on the e-Business application. Whenever a new product or company record is created, or an existing product or company record is updated in Aptify database, it is automatically synced with e-Business application. Users are no longer required to manually run the Image Sync Utility. The utility only needs to be run once initially to export all existing product and company images.

To run the Image Sync Utility, follow the steps given in Running Image Sync Utility document.

Prerequisite configurations for automatic image upload to e-Business 7.4 and higher

Below are the prerequisite configurations required after the image Sync utility is run for the first time. These configurations will take care of required file/folder access so that automatic image upload is successful. The cases listed below are the configuration of Aptify Web and e-Business applications with respect to the way Aptify Smart Client application is installed in different infrastructure. Refer to the prerequisites that suit your configuration.

Case 1: e-Business and Aptify Web deployed on IIS on the same server as Aptify Smart Client installation. 

For uploading a product and company image record through the Aptify Smart Client or the Aptify Web application, appropriate Read and Write access must be provided to the "images" folder of the e-Business site on IIS as mentioned below: 

  1. Staff users' Windows account with which the users have logged into the server where Aptify is installed.
  2. App Pool user's Windows account which is linked to the Application Pool that hosts the Aptify Web services.

Follow the steps below to provide the read and write access:

  1. Navigate to the images folder of the e-Business site deployed on IIS.
  2. Right-click the folder and click Properties.
  3. Once the Properties window opens, click Security tab.
  4. Click Edit button.
  5. Click Add button.
  6. Search for the staff user's or Aptify Web App Pool user's Windows account and click Check Names button.
  7. Click OK.
  8. Make sure to give appropriate Read and Write access to the selected user.
  9. Click Apply and then click OK.
  10. Again, click Apply and then click OK.

Case 2: e-Business and Aptify Web deployed on IIS on different server from Aptify Smart Client installation.

For this prerequisite, make sure that both the servers must be under the same domain. The "images" folder of the e-Business site on IIS must have network sharing enabled.

For uploading a product and company image record though the Aptify Smart Client application, provide the Read and Write access on the "images" folder to the staff user's Windows account, with which they have logged into the server where Aptify Smart Client is installed.

Whereas, for uploading a product and company image record through the Aptify Web application, provide the Read and Write access on the "images" folder to the Aptify Web App Pool user's Windows account, which is linked to the Application Pool that hosts the Aptify Web services.

Follow the steps below to provide the read and write access:

  1. Navigate to the images folder of the e-Business site deployed on IIS.
  2. Right-click on the folder and click Properties.
  3. Once the Properties window opens, click Sharing tab.
  4. Click Share button.
  5. Search for the staff user's or Aptify Web App Pool user's Windows account. You will only be able to search the account if it lies in the same domain of the server where this e-Business site is deployed.
  6. Click Add and then click Share.

Case 3: e-Business and Aptify Web deployed on Azure App Services

When Aptify e-Business and Aptify Web applications are deployed on Azure App Services, the product and company images are copied from the database and stored in a blob container. 

Follow the steps below for creation and configuration of blob storage:

  1. Create a new blob container for product images in your Azure Storage Account, for example aptify-product-images Refer to Configuring Aptify to Upload Attachments on Azure BLOB storage document for the details. While creating blob container, make sure its Anonymous access level is selected as Blob (anonymous read access for blobs only).
  2. Create a new blob container for company images in your Azure Storage Account, for example aptify-company-images Refer to Configuring Aptify to Upload Attachments on Azure BLOB storage document for the details. While creating blob container, make sure its Anonymous access level is selected as Blob (anonymous read access for blobs only).
  3. For Aptify Smart Client connected to Azure Managed Instance, modify the Aptify Shell.exe.config file to set the values of the following attributes:
    • Aptify.Framework.Attachment.AzureStorageAccount.blobConnectionString - set this attribute to the blob storage connection string.
    • Aptify.Framework.AzureStorageAccount.uploadRecordImagesToBlob - set this attribute to true
    • Aptify.Framework.AzureStorageAccount.blobProductImagesContainerName - set this attribute to the name of the blob container created in Step 1
    • Aptify.Framework.AzureStorageAccount.blobCompanyImagesContainerName - set this attribute to the name of the blob container created in Step 2
  4. For Aptify Web application connected to Azure Managed Instance, modify the AptifyServicesAPI Web.config file to set the values of the following attributes:
    • Aptify.Framework.Attachment.AzureStorageAccount.blobConnectionString - set this attribute to the blob storage connection string.
    • Aptify.Framework.AzureStorageAccount.uploadRecordImagesToBlob - set this attribute to true
    • Aptify.Framework.AzureStorageAccount.blobProductImagesContainerName -set this attribute to the name of the blob container created in Step 1
    • Aptify.Framework.AzureStorageAccount.blobCompanyImagesContainerName - set this attribute to the name of the blob container created in Step 2
  5. In the e-Business eBizUI ebConfig.json file, update the thumbnailImageURL attribute with the URL of the blob container created in Step 1.
  6. In the e-Business eBizUI ebConfig.json file, update the companyImageURL attribute with the URL of the blob container created in Step 2.

Configuring the Event Handlers

  1. Log in to Aptify Smart Client.
  2. Navigate to the Process Pipeline application.
  3. From the Event Handlers service, open the below given four event handlers.



    uploadcompanyimage1.png
    uploadcompanyimage.png

  4. By default, these event handlers are inactive. Make sure to select the Active checkbox, as shown in the above images.
  5. The ImageExtension field can be changed as per your requirement. It is set to "jpg" by default.
  6. The DestinationFolderPath needs to be set only if e-Business and Aptify Web are deployed on IIS. This is the folder where the product and company images from the database are exported into and served on the e-Business site. 
    • When e-Business and Aptify Web are deployed on the same server where Aptify Smart Client is installed, then set the path as per the local path.                                                                          For example, "C:\inetpub\wwwroot\eBizUI\images\products" and "C:\inetpub\wwwroot\eBizUI\images\company"
    • When e-Business and Aptify Web are deployed on a server different from the one where Aptify Smart Client is installed, then set the path as per the Network path of the shared "images" folder, followed by "products" or "company". 
      For example, if the Network Path is "\\MachineName\images", then the path to enter would be "\\MachineName\images\products" and "\\MachineName\images\company"
    • Make sure the destination folder exists.
    • DestinationFolderPath is to be left empty if e-Business and Aptify Web are deployed on Azure App Services.
  7. Save and close the records.
  8. Restart Aptify Smart Client.

Related Topics

Installing e-Business 7.4

Running Image Sync Utility

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.