Availability Group Examples



Load all availability groups.
<mvt:item name="ry_toolbelt" param="availgroup|Load_All|g.count" />
<mvt:if expr="g.count GT 0">
  <mvt:foreach iterator="availgroup" array="availgroups">
    &mvt:availgroup:id;, &mvt:availgroup:name; <br>
  </mvt:foreach>
</mvt:if>
 
Load a availability group by name.
<mvt:item name="ry_toolbelt" param="availgroup|Load_Name|g.found|avgp_name_exprsn" />
<mvt:if expr="found">
    &mvt:availgroup:id;, &mvt:availgroup:name; <br>
</mvt:if>
 
Load a comma separated list of availability group names.
<mvt:item name="ry_toolbelt" param="availgroup|Load_Name|g.found|avgp_name_list" />
<mvt:if expr="g.found">
  <mvt:foreach iterator="availgroup" array="availgroups">
    &mvt:availgroup:id;, &mvt:availgroup:name; <br>
  </mvt:foreach>
</mvt:if>
 
Determine all availability groups a logged in customer is assigned to. Internally uses g.basket:cust_id
<mvt:item name="ry_toolbelt" param="availgroup|Customer_Groups|g.count" />
<mvt:if expr="g.count GT 0">
  <mvt:foreach iterator="availgroup" array="availgroups">
    &mvt:availgroup:id;, &mvt:availgroup:name; <br>
  </mvt:foreach>
</mvt:if>
 
Determine if a customer is in a availability group.
<mvt:item name="ry_toolbelt" param="availgroup|Customer_Find|g.found|avgp_name_exprsn" />
<mvt:if expr="g.found">
    &mvt:availgroup:id;, &mvt:availgroup:name; <br>
</mvt:if>
 
Add a Customer to an availability group. Returns a 1 if successful or 0.
<mvt:item name="ry_toolbelt" param="availgroup|Customer_Insert|g.result|avgp_name_exprsn" />
<mvt:if expr="g.result">
  Customer inserted into price group.
</mvt:if>
 
Delete a customer from an availability group. Returns a 1 if successful or 0.
<mvt:item name="ry_toolbelt" param="availgroup|Customer_Delete|g.result|avgp_name_exprsn" />
<mvt:if expr="g.result">
  Customer deleted from price group.
</mvt:if>
 
Determine all availability groups a product is in.
<mvt:item name="ry_toolbelt" param="availgroup|Product_Groups|g.count|product_code_exprsn" />
<mvt:if expr="g.count GT 0">
  <mvt:foreach iterator="availgroup" array="availgroups">
    &mvt:availgroup:id;, &mvt:availgroup:name; <br>
  </mvt:foreach>
</mvt:if>
 
Determine if a product is in an availability group. Returns a 1 if found or 0
<mvt:item name="ry_toolbelt" param="availgroup|Product_Find|g.found|avgp_name_exprsn|product_code_exprsn" />
<mvt:if expr="g.found">
  Product is in the group.
</mvt:if>
 
Add a product to an availability group. Returns a 1 if successful or 0.
<mvt:item name="ry_toolbelt" param="availgroup|Product_Insert|g.result|avgp_name_exprsn|product_code_exprsn" />
<mvt:if expr="g.result">
  Product added to the group.
</mvt:if>
 
Delete a product from an availability group. Returns a 1 if successful or 0.
<mvt:item name="ry_toolbelt" param="availgroup|Product_Delete|g.result|avgp_name_exprsn|product_code_exprsn" />
<mvt:if expr="g.result">
  Product deleted from the group.
</mvt:if>
 
Determine all availability groups a category is in.
<mvt:item name="ry_toolbelt" param="availgroup|Category_Groups|g.count|category_code_exprsn" />
<mvt:if expr="g.count GT 0">
  <mvt:foreach iterator="availgroup" array="availgroups">
    &mvt:availgroup:id;, &mvt:availgroup:name; <br>
  </mvt:foreach>
</mvt:if>
 
Determine if a category is in an availability group. Returns a 1 if found or 0
<mvt:item name="ry_toolbelt" param="availgroup|Category_Find|g.found|avgp_name_exprsn|category_code_exprsn" />
<mvt:if expr="g.found">
  Category is in the group.
</mvt:if>
 
Add a category to an availability group. Returns a 1 if successful or 0.
<mvt:item name="ry_toolbelt" param="availgroup|Category_Insert|g.result|avgp_name_exprsn|category_code_exprsn" />
<mvt:if expr="g.result">
  Category added to the group.
</mvt:if>
 
Delete a category from an availability group. Returns a 1 if successful or 0.
<mvt:item name="ry_toolbelt" param="availgroup|Category_Delete|g.result|avgp_name_exprsn|category_code_exprsn" />
<mvt:if expr="g.result">
  Category deleted from the group.
</mvt:if>