question

Sebastian Hemmann avatar image
1 Like"
Sebastian Hemmann asked Matthew Gillespie commented

What happened to the Itemtype?

I´m wondering where the Itemtype in Items is gone. What is the reason for this? In FlexSim 17.1 a Label named "Type" is created. There is no easy way (like in before in the source) to add the Itemtype.

FlexSim 17.1.0
sourceitemtype
· 5
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

michael.smith avatar image michael.smith commented ·

I've been going through the v17.1 stuff myself from the whats new

  • Changed itemtype references to referencing an item's type label instead.

Looks like it's gone with the itemtype triggers all using label now.

Does this impact legacy models?

0 Likes 0 ·
Marco Baccalaro avatar image Marco Baccalaro michael.smith commented ·

On legacy models, a manual update have to be done in lists because getitemtype function cannot be used anymore on the queries. On other models I think you can leave the old style itemtype.

0 Likes 0 ·
Matthew Gillespie avatar image Matthew Gillespie ♦♦ Marco Baccalaro commented ·

getitemtype should be working in queries. This is a bug that we are fixing for 17.1.2.

0 Likes 0 ·
Matthew Gillespie avatar image Matthew Gillespie ♦♦ michael.smith commented ·

Legacy models will continue to work as is since the only changes we made are on new objects.

0 Likes 0 ·
David Seo avatar image David Seo commented ·

Recently whenever flexsim upgraded, the changed things deprecated etc make some embarrassed. I hope the example to be explained with description.

0 Likes 0 ·

1 Answer

·
Matthew Gillespie avatar image
6 Likes"
Matthew Gillespie answered

As the software has developed, and especially with the introduction of Process Flow, object labels have become increasingly important. We recognized this when we were designing the new Dot Syntax upgrades of FlexScript and made it a design goal to make label access easier and more visible. After that, the topic of how to integrate itemtype into Dot Syntax came up. During that discussion we realized that itemtype is just a pseudo label with a predefined name and a completely different way of accessing it. We also discussed this with our Training department and learned that they avoid teaching about itemtype and just teach new users to use a separate "Type" label. Thus, we determined that the best way to integrate itemtype into the new design of FlexScript was to treat it like any other label.

In 17.1 we deprecated all the itemtype commands and updated all pickoptions to use a "Type" label. New objects no longer have itemtype fields in their properties and new FlowItem Bins have no data stored on the itemtype node. New models can be built just as easily using the pickoptions, but any custom code should reference the item's "Type" label instead of using the itemtype commands.

Legacy models should continue to work as they did before. The changes we've made will only be seen on new objects added after 17.1. There is a known bug where getitemtype is not working in SQL queries, but this is an unrelated bug that we are fixing.

This change is mentioned in two different places in the 17.1 What's New, including the Backwards Compatibility Note section. We recognize that this is a big change when you consider how long itemtype has been a staple of FlexSim models, however, we feel that this is the best design decision for FlexScript. More than that, it simplifies model building for users by making everything a label. Users no longer have to learn about a special item property with special methods of getting and setting the value. They just have to be taught about labels and then they can use the "Type" label or any other label they choose.

5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.