Barcode template management - Intergraph Smart Materials - Version 5.0 SP1 (5.0.1) - Help - Hexagon PPM

Intergraph Smart Materials MobileScan Help (5.0 SP1)

Language
English
Product
Intergraph Smart Materials
Subproduct
MobileScan
Search by Category
Help
Smart Materials Mobile Scan Version
5.0

You can customize the barcodes generated using the Barcode Manager based on your requirements. MobileScan setup comes with the following default files:

  • Default template - default.html

  • Default Cascading Style Sheet (CSS) - templateStyles.CSS

    Location: \\<MobileScan base folder>\Web\www\barcode-manager\css

To edit or create a template, you must have MOBILE_TEMPLATE privilege assigned to your role.

  1. Select Manage Barcode Templates from the Barcode Manager drop down list.

    Barcode Manager Utility Screen 5.0

    Barcode Manager Template - List - 4.5

  2. Select a template and click Barcode Manager - Save Default Template - 4.5, to change the default template,

    • For the changes to be reflected in the database, you must save the selection before you leave the screen.

    • The default template is always preselected while printing barcodes. Based on your requirement, you can change the template from the Templates list.

  3. Click Barcode Manager New Template to create a template.

  4. Type the name in the Name box.

  5. Type the required code in the Template Box.

    BC Template

    You can write your own code or use the following sample code:

    <li className="col-xs-6">

    <h1 className="barcode">*{props.barcode}*</h1>

    <p>{props.project}</p>

    <p>{props.commodityCode}</p>

    <p className="ellipsis">{props.description}</p>

    <p>

    <svg viewBox={props.qrCodeSize}>

    <path d={props.qrCodePath}></path>

    </svg>

    </p>

    </li>

    • Any parameter that is passed to the RestAPI must match the regular expression {props.xxxxx} where xxxxx denotes properties that are listed in the barcode.csv file.

    • You can customize style, width, font sizes and so on and reference the styles from the barcode template. For example:

      1. In templateStyles.CSS, if you define a style, listItemStyle:

        #listItemStyle {

        width: 75mm;

        font-size: 9pt;

        text-align: left;

        margin-left: 0px;

        padding-left: 0px;

        }

      2. <span id="spanStyle">

      3. <li id="listItemStyle">

        You can reference the style in the barcode template as: <div id="divAlign">

    • You must edit all the existing templates to ensure that code matches the regular expression {props.xxxxx} where xxxxx denotes properties that are listed in the barcode.csv file. Templates that do not match the regular expression will not be displayed in the list of templates when you print the barcodes.

  6. Click Save.