fiveapples 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +7 -0
  2. data/bin/fiveapples +7 -0
  3. data/lib/config5.ru +31 -0
  4. data/lib/fiveapples.db3 +0 -0
  5. data/lib/fiveapples.rb +46 -0
  6. data/lib/model.rb +58 -0
  7. data/lib/ui5/Component.js +41 -0
  8. data/lib/ui5/controller/BreederList.controller.js +68 -0
  9. data/lib/ui5/controller/Breeder_Create.controller.js +82 -0
  10. data/lib/ui5/controller/Breeder_Detail.controller.js +89 -0
  11. data/lib/ui5/controller/CultivarList.controller.js +46 -0
  12. data/lib/ui5/controller/Cultivar_Create.controller.js +100 -0
  13. data/lib/ui5/controller/Cultivar_Detail.controller.js +204 -0
  14. data/lib/ui5/controller/FiveApplesApp.controller.js +62 -0
  15. data/lib/ui5/controller/MCultivarList.controller.js +96 -0
  16. data/lib/ui5/controller/MenuList.controller.js +28 -0
  17. data/lib/ui5/controller/NotFound.controller.js +9 -0
  18. data/lib/ui5/controller/ParentageList.controller.js +71 -0
  19. data/lib/ui5/controller/Parentage_Create.controller.js +134 -0
  20. data/lib/ui5/controller/Parentage_Detail.controller.js +116 -0
  21. data/lib/ui5/controller/VibertBaseController.js +40 -0
  22. data/lib/ui5/i18n/i18n.properties +7 -0
  23. data/lib/ui5/index.html +33 -0
  24. data/lib/ui5/manifest.json +194 -0
  25. data/lib/ui5/model/formatter.js +1 -0
  26. data/lib/ui5/model/models.js +19 -0
  27. data/lib/ui5/view/BreederList.view.xml +50 -0
  28. data/lib/ui5/view/BreederOptio.fragment.xml +21 -0
  29. data/lib/ui5/view/Breeder_Create.view.xml +26 -0
  30. data/lib/ui5/view/Breeder_Detail.view.xml +53 -0
  31. data/lib/ui5/view/CultivarList.view.xml +58 -0
  32. data/lib/ui5/view/CultivarOptio.fragment.xml +23 -0
  33. data/lib/ui5/view/Cultivar_Create.view.xml +33 -0
  34. data/lib/ui5/view/Cultivar_Detail.view.xml +93 -0
  35. data/lib/ui5/view/FiveApplesApp.view.xml +9 -0
  36. data/lib/ui5/view/MCultivarList.view.xml +43 -0
  37. data/lib/ui5/view/MenuList.view.xml +18 -0
  38. data/lib/ui5/view/NotFound.view.xml +9 -0
  39. data/lib/ui5/view/ParentageList.view.xml +64 -0
  40. data/lib/ui5/view/Parentage_Create.view.xml +26 -0
  41. data/lib/ui5/view/Parentage_Detail.view.xml +51 -0
  42. metadata +128 -0
@@ -0,0 +1,33 @@
1
+ <mvc:View
2
+ xmlns="sap.m"
3
+ xmlns:f="sap.ui.layout.form"
4
+ xmlns:mvc="sap.ui.core.mvc"
5
+ controllerName="vibert.controller.Cultivar_Create" >
6
+ <Page title="Cultivar Create" >
7
+
8
+ <customHeader>
9
+ <Bar>
10
+ <contentLeft>
11
+ <Button icon="sap-icon://nav-back" press="onNavBack"/>
12
+ <Button icon="sap-icon://create" type="Accept" text="Create" press="onCreatePress"/>
13
+ </contentLeft>
14
+ </Bar>
15
+ </customHeader>
16
+ <ObjectHeader title="{ID} : {name}"/>
17
+
18
+ <f:SimpleForm id="cultivar_create_form" editable="true">
19
+ <Label text="Name"/>
20
+ <Input id="name" type="text" name="name" enabled="true" />
21
+ <Label text="Year"/>
22
+ <Input id="year" type="text" name="year" enabled="true" />
23
+ <Label text="Breeder"/>
24
+ <Input id="breeder_ID" type="Text"
25
+ width="40%"
26
+ showValueHelp="true"
27
+ valueHelpRequest="onBreederIDValueHelp"
28
+ name="breeder_ID" enabled="true" />
29
+ <Text id="breeder_ID_descr" />
30
+ </f:SimpleForm>
31
+
32
+ </Page>
33
+ </mvc:View>
@@ -0,0 +1,93 @@
1
+ <mvc:View xmlns="sap.m" xmlns:t="sap.ui.table" xmlns:l="sap.ui.layout" xmlns:f="sap.ui.layout.form" xmlns:core="sap.ui.core" xmlns:mvc="sap.ui.core.mvc" controllerName="vibert.controller.Cultivar_Detail">
2
+ <Page title="Cultivar detail">
3
+ <customHeader>
4
+ <Bar>
5
+ <contentRight>
6
+ <Button icon="sap-icon://delete" text="Delete" press="onDeletePress" />
7
+ </contentRight>
8
+ <contentLeft>
9
+ <Button icon="sap-icon://nav-back" press="onNavBack" />
10
+ <Button icon="sap-icon://save" type="Accept" press="onSave" text="Save changes" />
11
+ <Button icon="sap-icon://create" type="Accept" text="Create" press="onCreatePress" />
12
+ </contentLeft>
13
+ </Bar>
14
+ </customHeader>
15
+ <ObjectHeader title="{id} : {name}" />
16
+ <Panel expandable="true" expanded="true" headerText="Details" width="auto" class="sapUiResponsiveMargin">
17
+ <content>
18
+ <f:SimpleForm editable="true">
19
+ <Label text="Name" />
20
+ <Input id="name" type="text" name="name" enabled="true" value="{name}" />
21
+ <Label text="Year" />
22
+ <Input id="year" type="integer" name="year" enabled="true" value="{year}" />
23
+ <Label text="Breeder" />
24
+ <Input id="breeder_id" type="Text" width="40%" showValueHelp="true" valueHelpRequest="onBreederIDValueHelp" name="breeder_id" value="{breeder_id}" enabled="true" />
25
+ <Link id="breeder_id_descr" text="{breeder/first_name} {breeder/last_name}" press="handleBreederPress" />
26
+ <Button icon="sap-icon://create" type="Accept" text="Create" press="onBreederCreatePress" />
27
+ </f:SimpleForm>
28
+ </content>
29
+ </Panel>
30
+
31
+ <Panel expandable="true" expanded="true" headerText="Parents" width="auto" class="sapUiResponsiveMargin">
32
+ <content>
33
+ <t:Table id="parent_table"
34
+ rows="{path: 'parent', parameters:{expand : 'cultivar/breeder,parent/breeder'} }" rowSelectionChange="onParentSelectionChange"
35
+ selectionMode="Single" visibleRowCount="4"
36
+ visibleRowCountMode="auto" selectionBehavior="Row">
37
+ <t:columns>
38
+ <t:Column width="10%" autoResizable="true">
39
+ <Label text="Par. Type" />
40
+ <t:template>
41
+ <Text text="{path:'ptype_id'}" />
42
+ </t:template>
43
+ </t:Column>
44
+ <t:Column autoResizable="true" sortProperty="parent/name" filterProperty="parent/name">
45
+ <Label text="Parent" />
46
+ <t:template>
47
+ <Text text="{parent/name}" />
48
+ </t:template>
49
+ </t:Column>
50
+ <t:Column autoResizable="true">
51
+ <Label text="Breeder" />
52
+ <t:template>
53
+ <Text text="{parent/breeder/last_name}" />
54
+ </t:template>
55
+ </t:Column>
56
+ </t:columns>
57
+ </t:Table>
58
+ </content>
59
+ </Panel>
60
+
61
+ <Panel expandable="true" expanded="true"
62
+ headerText="Direct decendency"
63
+ width="auto" class="sapUiResponsiveMargin">
64
+ <content>
65
+ <t:Table id="child_table"
66
+ rows="{path: 'child', parameters:{expand : 'cultivar/breeder'} }"
67
+ rowSelectionChange="onChildSelectionChange"
68
+ selectionMode="Single" visibleRowCount="10" visibleRowCountMode="auto" selectionBehavior="Row">
69
+ <t:columns>
70
+ <t:Column width="10%" autoResizable="true">
71
+ <Label text="Par. Type" />
72
+ <t:template>
73
+ <Text text="{path:'ptype_id'}" />
74
+ </t:template>
75
+ </t:Column>
76
+ <t:Column autoResizable="true" sortProperty="cultivar/name" filterProperty="cultivar/name">
77
+ <Label text="Cultivar" />
78
+ <t:template>
79
+ <Text text="{cultivar/name}" />
80
+ </t:template>
81
+ </t:Column>
82
+ <t:Column autoResizable="true" sortProperty="cultivar/breeder/last_name" filterProperty="cultivar/breeder/last_name">
83
+ <Label text="Breeder" />
84
+ <t:template>
85
+ <Text text="{cultivar/breeder/last_name}" />
86
+ </t:template>
87
+ </t:Column>
88
+ </t:columns>
89
+ </t:Table>
90
+ </content>
91
+ </Panel>
92
+ </Page>
93
+ </mvc:View>
@@ -0,0 +1,9 @@
1
+ <mvc:View xmlns:mvc="sap.ui.core.mvc"
2
+ xmlns:custom="http://schemas.sap.com/sapui5/extension/sap.ui.core.CustomData/1"
3
+ xmlns="sap.m" displayBlock="true"
4
+ controllerName="vibert.controller.FiveApplesApp" >
5
+ <SplitApp id="FiveApplesApp" enableScrolling="true">
6
+ <!-- pages will be filled automatically via routing -->
7
+
8
+ </SplitApp>
9
+ </mvc:View>
@@ -0,0 +1,43 @@
1
+ <mvc:View
2
+ controllerName="vibert.controller.MCultivarList"
3
+ xmlns="sap.m"
4
+ xmlns:mvc="sap.ui.core.mvc">
5
+
6
+ <Toolbar class="sapUiMediumMarginTop" id="toolbar1">
7
+ <Button text="Create record" press="onCreatePress"/>
8
+ <Button text="Delete record" press="onDeletePress"/>
9
+ </Toolbar>
10
+ <Table id="m_cultivar_table_h" showNoData="false">
11
+ <columns>
12
+ <Column width="6%" autoResizable="true" sortProperty="ID">
13
+ <Text text="cultivar ID"/> </Column>
14
+ <Column width="10%" autoResizable="true" >
15
+ <Text text="Type"/> </Column>
16
+ <Column autoResizable="true" sortProperty="name" filterProperty="name">
17
+ <Text text="Name"/> </Column>
18
+ </columns>
19
+
20
+ </Table>
21
+ <ScrollContainer horizontal="true" vertical="true" height="100%" >
22
+ <Table id="m_cultivar_table" items="{path: '/cultivar' }">
23
+
24
+
25
+ <columns>
26
+ <Column width="6%" autoResizable="true" ></Column>
27
+ <Column width="10%" autoResizable="true" ></Column>
28
+ <Column autoResizable="true" ></Column>
29
+ </columns>
30
+
31
+ <items>
32
+ <ColumnListItem press="handlePress" type="Navigation">
33
+ <cells>
34
+ <ObjectIdentifier title="{cultivar ID}" text="{ID}" />
35
+ <Text text="{name}" />
36
+ </cells>
37
+ </ColumnListItem>
38
+ </items>
39
+
40
+ </Table>
41
+ </ScrollContainer>
42
+
43
+ </mvc:View>
@@ -0,0 +1,18 @@
1
+ <mvc:View xmlns:mvc="sap.ui.core.mvc"
2
+ xmlns:custom="http://schemas.sap.com/sapui5/extension/sap.ui.core.CustomData/1"
3
+ xmlns="sap.m" displayBlock="true"
4
+ controllerName="vibert.controller.MenuList" >
5
+
6
+ <Page id="MenuList" title="Menu" icon="sap-icon://action" >
7
+ <content>
8
+ <List id="navToList" itemPress="onListItemPress">
9
+ <items>
10
+ <StandardListItem title="List of cultivars" type="Active" custom:to="cultivarList"/>
11
+ <StandardListItem title="Parentage list" type="Active" custom:to="parentageList"/>
12
+ <StandardListItem title="List of Breeders" type="Active" custom:to="breederList"/>
13
+ </items>
14
+ </List>
15
+ </content>
16
+ </Page>
17
+
18
+ </mvc:View>
@@ -0,0 +1,9 @@
1
+ <mvc:View
2
+ controllerName="sample.controller.NotFound"
3
+ xmlns="sap.m"
4
+ xmlns:mvc="sap.ui.core.mvc">
5
+ <MessagePage
6
+ title="{i18n>NotFound}"
7
+ text="{i18n>NotFound.text}"
8
+ description="{i18n>NotFound.description}"/>
9
+ </mvc:View>
@@ -0,0 +1,64 @@
1
+ <mvc:View
2
+ controllerName="vibert.controller.ParentageList"
3
+ xmlns="sap.ui.table"
4
+ xmlns:mvc="sap.ui.core.mvc"
5
+ xmlns:u="sap.ui.unified"
6
+ xmlns:co="sap.ui.commons"
7
+ xmlns:c="sap.ui.core"
8
+ xmlns:m="sap.m">
9
+
10
+ <m:Toolbar class="sapUiMediumMarginTop" id="toolbar1">
11
+ <!--
12
+ <m:Button text="Create record" press="onCreatePress"/>
13
+ -->
14
+ <m:Button text="Delete record" press="onDeletePress"/>
15
+ </m:Toolbar>
16
+
17
+ <Table id="parentage_table"
18
+ selectionMode="Single"
19
+ rowSelectionChange = "onSelectionChange"
20
+ visibleRowCount="20"
21
+ visibleRowCountMode="auto"
22
+ selectionBehavior="Row"
23
+ rows="{
24
+ path: '/parentage',
25
+ parameters: {expand: 'cultivar,parent/breeder,par_type',
26
+ operationMode: 'Server'}
27
+ }">
28
+ <columns>
29
+ <Column autoResizable="true"
30
+ sortProperty="cultivar/name" filterProperty="cultivar/name" >
31
+ <m:Label text="Cultivar" />
32
+ <template>
33
+ <m:Text text="{cultivar/name}"/>
34
+ </template>
35
+ </Column>
36
+ <Column width="10%" autoResizable="true">
37
+ <m:Label text="Par. Type"/>
38
+ <template>
39
+ <m:Text text="{par_type/description}" />
40
+ </template>
41
+ </Column>
42
+ <Column autoResizable="true" sortProperty="parent/name" filterProperty="parent/name">
43
+ <m:Label text="Parent"/>
44
+ <template>
45
+ <m:Text text="{parent/name}"/>
46
+ </template>
47
+ </Column>
48
+ <Column autoResizable="true" >
49
+ <m:Label text="Breeder"/>
50
+ <template>
51
+ <m:Text text="{parent/breeder/last_name}" />
52
+ </template>
53
+ </Column>
54
+ </columns>
55
+ </Table>
56
+
57
+
58
+ </mvc:View>
59
+
60
+
61
+
62
+
63
+
64
+
@@ -0,0 +1,26 @@
1
+ <mvc:View xmlns="sap.m" xmlns:f="sap.ui.layout.form" xmlns:core="sap.ui.core" xmlns:mvc="sap.ui.core.mvc" controllerName="vibert.controller.Parentage_Create">
2
+ <Page title="Create Parentage">
3
+ <customHeader>
4
+ <Bar>
5
+ <contentLeft>
6
+ <Button icon="sap-icon://nav-back" press="onNavBack" />
7
+ <Button icon="sap-icon://save" type="Accept" press="onCreate" text="Create" />
8
+ </contentLeft>
9
+ </Bar>
10
+ </customHeader>
11
+ <ObjectHeader title="Create parentage for cultivar id {cultivar_id} : " />
12
+ <f:SimpleForm id="parens_create_form" editable="true">
13
+ <Label text="Cultivar id" />
14
+ <Input id="cultivar_id" type="Text" width="40%" showValueHelp="true" valueHelpRequest="onIDValueHelp" name="cultivar_id" enabled="true" />
15
+ <Text id="cultivar_ID_descr" />
16
+ <Label text="Parent type" />
17
+ <ComboBox id="ptype_id" showSecondaryValues="true" width="40%" enabled="true" items="{path: 'myPtModel>/d' }">
18
+ <core:ListItem key="{myPtModel>id}" text="{myPtModel>id}" additionalText="{myPtModel>description}" />
19
+ </ComboBox>
20
+ <Text id="ptype_id_descr" />
21
+ <Label text="Parent id" />
22
+ <Input id="parent_id" type="Text" name="parent_id" width="40%" showValueHelp="true" valueHelpRequest="onIDValueHelp" enabled="true" />
23
+ <Text id="parent_ID_descr" />
24
+ </f:SimpleForm>
25
+ </Page>
26
+ </mvc:View>
@@ -0,0 +1,51 @@
1
+ <mvc:View
2
+ xmlns="sap.m"
3
+ xmlns:f="sap.ui.layout.form"
4
+ xmlns:core="sap.ui.core"
5
+ xmlns:mvc="sap.ui.core.mvc"
6
+ controllerName="vibert.controller.Parentage_Detail" >
7
+ <Page title="Parentage detail " showNavButton="true" navButtonPress="onNavBack" >
8
+
9
+
10
+ <ObjectHeader title="{cultivar_id} : {ptype_id} : {parent_id}"/>
11
+
12
+ <f:SimpleForm editable="true">
13
+
14
+
15
+ <Label text="Cultivar id"/>
16
+
17
+ <Input id="cultivar_id" type="Text"
18
+ width="40%"
19
+ showValueHelp="true"
20
+ valueHelpRequest="onIDValueHelp"
21
+ name="cultivar_id" enabled="false" value="{cultivar_id}" />
22
+ <Text id="cultivar_id_descr" text="{cultivar/name}"/>
23
+
24
+
25
+
26
+ <Label text="Parent type"/>
27
+
28
+ <ComboBox id="ptype_id_combo"
29
+ showSecondaryValues= "true"
30
+ width="40%"
31
+ enabled="false"
32
+ value="{ptype_id}"
33
+ items="{path: 'myPtModel>/d' }" >
34
+ <core:ListItem key="{myPtModel>id}" text="{myPtModel>id}"
35
+ additionalText = "{myPtModel>description}"/>
36
+ </ComboBox>
37
+
38
+
39
+ <Text text="{path:'ptype_id' , formatter: '.parentageTypeDescription'}" />
40
+
41
+ <Label text="Parent id"/>
42
+ <Input id="parent_id" type="Text" name="parent_id"
43
+ width="40%"
44
+ showValueHelp="true"
45
+ valueHelpRequest="onIDValueHelp"
46
+ enabled="false" value="{parent_id}" />
47
+ <Text id="parent_id_descr" text="{parent/name}"/>
48
+ </f:SimpleForm>
49
+
50
+ </Page>
51
+ </mvc:View>
metadata ADDED
@@ -0,0 +1,128 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: fiveapples
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - D.M.
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2019-12-22 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: safrano
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '0.3'
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 0.3.2
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: '0.3'
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: 0.3.2
33
+ - !ruby/object:Gem::Dependency
34
+ name: thin
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '1.7'
40
+ - - ">="
41
+ - !ruby/object:Gem::Version
42
+ version: 1.7.0
43
+ type: :runtime
44
+ prerelease: false
45
+ version_requirements: !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - "~>"
48
+ - !ruby/object:Gem::Version
49
+ version: '1.7'
50
+ - - ">="
51
+ - !ruby/object:Gem::Version
52
+ version: 1.7.0
53
+ description: Fiveapples is a fully opensource standalone OData + openui5 demo app
54
+ email: dm@0data.dev
55
+ executables:
56
+ - fiveapples
57
+ extensions: []
58
+ extra_rdoc_files: []
59
+ files:
60
+ - bin/fiveapples
61
+ - lib/config5.ru
62
+ - lib/fiveapples.db3
63
+ - lib/fiveapples.rb
64
+ - lib/model.rb
65
+ - lib/ui5/Component.js
66
+ - lib/ui5/controller/BreederList.controller.js
67
+ - lib/ui5/controller/Breeder_Create.controller.js
68
+ - lib/ui5/controller/Breeder_Detail.controller.js
69
+ - lib/ui5/controller/CultivarList.controller.js
70
+ - lib/ui5/controller/Cultivar_Create.controller.js
71
+ - lib/ui5/controller/Cultivar_Detail.controller.js
72
+ - lib/ui5/controller/FiveApplesApp.controller.js
73
+ - lib/ui5/controller/MCultivarList.controller.js
74
+ - lib/ui5/controller/MenuList.controller.js
75
+ - lib/ui5/controller/NotFound.controller.js
76
+ - lib/ui5/controller/ParentageList.controller.js
77
+ - lib/ui5/controller/Parentage_Create.controller.js
78
+ - lib/ui5/controller/Parentage_Detail.controller.js
79
+ - lib/ui5/controller/VibertBaseController.js
80
+ - lib/ui5/i18n/i18n.properties
81
+ - lib/ui5/index.html
82
+ - lib/ui5/manifest.json
83
+ - lib/ui5/model/formatter.js
84
+ - lib/ui5/model/models.js
85
+ - lib/ui5/view/BreederList.view.xml
86
+ - lib/ui5/view/BreederOptio.fragment.xml
87
+ - lib/ui5/view/Breeder_Create.view.xml
88
+ - lib/ui5/view/Breeder_Detail.view.xml
89
+ - lib/ui5/view/CultivarList.view.xml
90
+ - lib/ui5/view/CultivarOptio.fragment.xml
91
+ - lib/ui5/view/Cultivar_Create.view.xml
92
+ - lib/ui5/view/Cultivar_Detail.view.xml
93
+ - lib/ui5/view/FiveApplesApp.view.xml
94
+ - lib/ui5/view/MCultivarList.view.xml
95
+ - lib/ui5/view/MenuList.view.xml
96
+ - lib/ui5/view/NotFound.view.xml
97
+ - lib/ui5/view/ParentageList.view.xml
98
+ - lib/ui5/view/Parentage_Create.view.xml
99
+ - lib/ui5/view/Parentage_Detail.view.xml
100
+ homepage: https://gitlab.com/dm0da/fiveapples
101
+ licenses:
102
+ - MIT
103
+ metadata:
104
+ bug_tracker_uri: https://gitlab.com/dm0da/fiveapples/issues
105
+ changelog_uri: https://gitlab.com/dm0da/fiveapples/blob/master/CHANGELOG
106
+ source_code_uri: https://gitlab.com/dm0da/fiveapples/tree/master
107
+ wiki_uri: https://gitlab.com/dm0da/fiveapples/wikis/home
108
+ post_install_message:
109
+ rdoc_options: []
110
+ require_paths:
111
+ - lib
112
+ required_ruby_version: !ruby/object:Gem::Requirement
113
+ requirements:
114
+ - - ">="
115
+ - !ruby/object:Gem::Version
116
+ version: 2.4.0
117
+ required_rubygems_version: !ruby/object:Gem::Requirement
118
+ requirements:
119
+ - - ">="
120
+ - !ruby/object:Gem::Version
121
+ version: '0'
122
+ requirements: []
123
+ rubyforge_project:
124
+ rubygems_version: 2.7.6.2
125
+ signing_key:
126
+ specification_version: 4
127
+ summary: Fiveapples is a fully opensource standalone OData + openui5 demo app.
128
+ test_files: []