93
|
1 |
SELECT "------------------------------------" AS " ";
|
|
2 |
SELECT "castoragedb_variant - BEGIN" AS " ";
|
|
3 |
|
|
4 |
{% for col in range(feat_tree.CaStorageDbSetting.Collections._value|length) -%}
|
|
5 |
{%- set Name = feat_tree.CaStorageDbSetting.Collections.Name._value[col] or '' -%}
|
106
|
6 |
{%- set ColShortName = feat_tree.CaStorageDbSetting.Collections.ColShortName._value[col] or '' -%}
|
|
7 |
{%- set ColTitleName = feat_tree.CaStorageDbSetting.Collections.ColTitleName._value[col] or '' -%}
|
93
|
8 |
{%- set GroupName = feat_tree.CaStorageDbSetting.Collections.GroupName._value[col] or '' -%}
|
|
9 |
{%- set Flags = feat_tree.CaStorageDbSetting.Collections.Flags._value[col] or '' -%}
|
|
10 |
{%- set LocName = feat_tree.CaStorageDbSetting.Collections.LocName._value[col] or ''-%}
|
94
|
11 |
{%- set IconFileName = feat_tree.CaStorageDbSetting.Collections.IconFileName._value[col] or '' -%}
|
|
12 |
{%- set IconSkinId = feat_tree.CaStorageDbSetting.Collections.IconSkinId._value[col] or '' -%}
|
106
|
13 |
INSERT INTO COLLECTION (COLLECTION_NAME, COL_APP_GROUP_NAME, FLAGS {% if ColTitleName -%}, COL_TITLE_NAME{%- endif %}{% if LocName -%}, COL_LOCNAME{%- endif %}{% if ColShortName -%}, COL_SHORT_NAME{%- endif %}{% if IconFileName -%}, ICON_FILENAME{%- endif %}{% if IconSkinId -%}, ICON_SKIN_ID{%- endif %})
|
|
14 |
VALUES ( '{{Name}}', '{{GroupName}}', {{Flags}} {% if ColTitleName -%}, "{{ColTitleName}}"{%- endif %}{% if LocName -%}, "{{LocName}}"{%- endif %}{% if ColShortName -%}, "{{ColShortName}}"{%- endif %}{% if IconFileName -%}, "{{IconFileName}}"{%- endif %}{% if IconSkinId -%}, "{{IconSkinId}}"{%- endif %});
|
93
|
15 |
|
|
16 |
{% endfor %}
|
|
17 |
|
|
18 |
{% for index in range(feat_tree.CaStorageDbSetting.Items._value|length) -%}
|
|
19 |
{%- set Type = feat_tree.CaStorageDbSetting.Items.Type._value[index] or '' -%}
|
|
20 |
{%- set Name = feat_tree.CaStorageDbSetting.Items.Name._value[index] or '' -%}
|
94
|
21 |
{%- set IconFileName = feat_tree.CaStorageDbSetting.Items.IconFileName._value[index] or '' -%}
|
|
22 |
{%- set IconSkinId = feat_tree.CaStorageDbSetting.Items.IconSkinId._value[index] or '' -%}
|
106
|
23 |
{%- set ShortName = feat_tree.CaStorageDbSetting.Items.ShortName._value[index] or '' -%}
|
94
|
24 |
{%- set DestinationUid = feat_tree.CaStorageDbSetting.Items.DestinationUid._value[index] or '' -%}
|
|
25 |
{%- set DestinationUrl = feat_tree.CaStorageDbSetting.Items.DestinationUrl._value[index] or '' -%}
|
|
26 |
{%- set DestinationWidgetUri = feat_tree.CaStorageDbSetting.Items.DestinationWidgetUri._value[index] or '' -%}
|
93
|
27 |
{%- set Collection = feat_tree.CaStorageDbSetting.Items.Col_Name._value[index] or '' -%}
|
94
|
28 |
{% if Type == "application" -%} INSERT INTO ITEM_TO_COLLECTION (ITEM_TYPE, ITEM_NAME, ITEM_DEST, COLLECTION_NAME)
|
|
29 |
VALUES ("{{Type}}", '{{Name}}', {{DestinationUid}}, '{{Collection}}' );{%- endif %}
|
106
|
30 |
{% if Type == "url" -%} INSERT INTO ITEM_TO_COLLECTION (ITEM_TYPE, ITEM_NAME {% if ShortName -%}, ITEM_SHORTNAME{%- endif %}, ITEM_DEST, ICON_FILENAME, ICON_SKIN_ID, COLLECTION_NAME)
|
|
31 |
VALUES ("{{Type}}", '{{Name}}' {% if ShortName -%}, "{{ShortName}}"{%- endif %}, "{{DestinationUrl}}", "{{IconFileName}}", "{{IconSkinId}}", '{{Collection}}' ); {%- endif %}
|
94
|
32 |
{% if Type == "widget" -%} INSERT INTO WIDGET_TO_COLLECTION (ITEM_TYPE, ITEM_NAME, ICON_FILENAME, ICON_SKIN_ID, URI, COLLECTION_NAME )
|
|
33 |
VALUES ("{{Type}}", '{{Name}}', "{{IconFileName}}", "{{IconSkinId}}", "{{DestinationWidgetUri}}", '{{Collection}}' ); {%- endif %}
|
93
|
34 |
{% endfor %}
|
|
35 |
|
|
36 |
SELECT "castoragedb_variant - END" AS " ";
|
|
37 |
SELECT "------------------------------------" AS " ";
|
|
38 |
|