fiveapples 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e5c8b82774d97634ad34096945c4db9d90e5fa06b43fc622619fd56d7de02acc
4
- data.tar.gz: f5d88705c3de7f55293c7d3d507fc88b6ca29786697c44c3d9a82a8ae233bab8
3
+ metadata.gz: 05df5643157a04c97182a2a9eac30c3242ef7f8d6d6c885e03623474f5199c3c
4
+ data.tar.gz: 5a48a02e003a73be836a4a937596d0f9d11952de9f9e508cb9cbf60c152dd081
5
5
  SHA512:
6
- metadata.gz: 31d0d03aaf35690924d17233cf73f5b16bcf246718defe6dfa976e9e6edb4ed1114efb514f6b81a0216fa288caae51b21e3170a4e570482cab1e8ca4699dffd7
7
- data.tar.gz: fbd042412deabbd141d07279ad72d216f8091e7cd7afb4303f9acb666913756014b955c4cfc7e85c042848f12de5d5621dc474708d6418bb5969e969e3841940
6
+ metadata.gz: c86fef213d70285c8a9d57353f4139f43cbd11f6deaf1710cf70038e79e37ba22f373cfc7b8a6f08eb31b9b7ee420da90270226161208eac12ab0e713c67f092
7
+ data.tar.gz: cfcd6121376e7713487e1d01c106db1e011c635ecafe40ebb95d6417ceec6566d87133cf6022d2e3aaaa8458f3a1c928d25b68d7d8c7e0c8f68a1664b05d6fbd
@@ -53,7 +53,7 @@ function (Controller, MessageToast, ODataModel, Dialog, ResourceModel) {
53
53
  },
54
54
  onSelectionChange: function (evt) {
55
55
  var oTable = this.getView().byId("breeder_table");
56
- var iIndex = oTable.getSelectedIndex();
56
+ var iIndex = oTable.getSelectedIndex();
57
57
 
58
58
  var oCtxt = oTable.getContextByIndex(iIndex);
59
59
  var sToPageId = oCtxt.getProperty("id") ;
@@ -84,6 +84,7 @@ sap.ui.define([
84
84
  var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
85
85
  oRouter.navTo("breederList", true);
86
86
  }
87
- }
87
+ },
88
+
88
89
  });
89
90
  });
@@ -20,26 +20,15 @@ function (Controller, MessageToast, ODataModel, ResourceModel) {
20
20
 
21
21
  onSelectionChange: function (evt) {
22
22
  var oTable = this.getView().byId("cultivar_table");
23
- var iIndex = oTable.getSelectedIndex();
23
+ var iIndex = oTable.getSelectedIndex();
24
24
 
25
25
  var oCtxt = oTable.getContextByIndex(iIndex);
26
26
  var sToPageId = oCtxt.getProperty("id") ;
27
27
 
28
28
  var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
29
- // MessageToast.show(" navTo cultivar_detail -->"+sToPageId);
30
29
  oRouter.navTo( "cultivar_detail", {id: sToPageId} );
31
30
  },
32
- //onDisplayPress: function (evt) {
33
- //var oTable = this.getView().byId("cultivar_table");
34
- //var iIndex = oTable.getSelectedIndex();
35
-
36
- //var oCtxt = oTable.getContextByIndex(iIndex);
37
- //var sToPageId = oCtxt.getProperty("ID") ;
38
-
39
- //var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
40
- //// MessageToast.show(" navTo cultivar_detail -->"+sToPageId);
41
- //oRouter.navTo( "cultivar_detail", {ID: sToPageId} );
42
- //}
31
+
43
32
  });
44
33
  });
45
34
 
@@ -21,19 +21,17 @@ sap.ui.define([
21
21
  var oEntry = {};
22
22
 
23
23
  oEntry.name = this.byId('name').getValue();
24
- oEntry.common_name = this.byId('common_name').getValue();
25
24
  oEntry.year = this.byId('year').getValue();
26
- oEntry.breeder_ID = this.byId('breeder_ID').getValue();
25
+ oEntry.breeder_id = this.byId('breeder_id').getValue();
27
26
  var _that = this;
28
27
 
29
28
  function onSuccessHandler(data){
30
29
  oModel.refresh();
31
30
  _that.byId('name').setValue("");
32
- _that.byId('common_name').setValue("");
33
31
  _that.byId('year').setValue("");
34
- _that.byId('breeder_ID').setValue("");
32
+ _that.byId('breeder_id').setValue("");
35
33
  MessageToast.show("Create success");
36
- _that._oRouter.navTo( "cultivar_detail", {ID: data.ID} );
34
+ _that._oRouter.navTo( "cultivar_detail", {id: data.id} );
37
35
  }
38
36
  function onErrorHandler(){
39
37
  MessageToast.show("Create failed"); }
@@ -58,7 +56,7 @@ sap.ui.define([
58
56
  inputId : "",
59
57
  inputDescrId: "",
60
58
 
61
- onBreederIDValueHelp : function (oEvent) {
59
+ onBreederIdValueHelp : function (oEvent) {
62
60
 
63
61
  this.inputId = oEvent.getSource().getId();
64
62
  this.inputDescrId = this.inputId + "_descr";
@@ -1,10 +1,11 @@
1
1
  sap.ui.define([
2
2
  'jquery.sap.global',
3
- "sap/ui/core/mvc/Controller",
3
+ "sap/ui/core/mvc/Controller",
4
4
  "sap/m/MessageToast",
5
+ "sap/m/MessageBox",
5
6
  "sap/ui/commons/Dialog",
6
7
  "sap/ui/core/routing/History"
7
- ], function (jQuery, Controller, MessageToast, Dialog, History) {
8
+ ], function (jQuery, Controller, MessageToast, MessageBox, Dialog, History) {
8
9
  "use strict";
9
10
  return Controller.extend("vibert.controller.Cultivar_Detail", {
10
11
  onInit: function () {
@@ -19,8 +20,6 @@ sap.ui.define([
19
20
  this._sObjectPath = sObjectPath;
20
21
 
21
22
  var oView = this.getView();
22
- // var oModel = sap.ui.getCore().getModel();
23
- // oView.setModel(oModel);
24
23
  oView.bindElement({ path: sObjectPath});
25
24
  var oModel = oView.getModel();
26
25
 
@@ -49,7 +48,6 @@ sap.ui.define([
49
48
  text: "Confirm",
50
49
  press:function(){
51
50
  var mParms = {};
52
- // mParms.merge = true;
53
51
 
54
52
  mParms.success = function(data, response){
55
53
 
@@ -106,9 +104,9 @@ sap.ui.define([
106
104
 
107
105
  },
108
106
  handleBreederPress : function () {
109
- var sBreeder_ID = this.byId('breeder_ID').getValue();
107
+ var sBreeder_id = this.byId('breeder_id').getValue();
110
108
  var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
111
- oRouter.navTo( "breeder_detail", {ID: sBreeder_ID } );
109
+ oRouter.navTo( "breeder_detail", {id: sBreeder_id } );
112
110
  },
113
111
 
114
112
  onCheck: function() {
@@ -143,17 +141,7 @@ sap.ui.define([
143
141
  oRouter.navTo( "cultivar_detail", {id: sToPageParID } );
144
142
 
145
143
  },
146
-
147
- onFiliiSelectionChange : function () {
148
- var oTable = this.byId("child_table");
149
- var iIndex = oTable.getSelectedIndex();
150
-
151
- var oCtxt = oTable.getContextByIndex(iIndex);
152
- var sToPageParID = oCtxt.getProperty("cultivar_id") ;
153
- var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
154
- oRouter.navTo( "cultivar_detail", {id: sToPageParID} );
155
-
156
- }, // Warning: alot of dupl. code with the "cultivar create" controlller
144
+ // Warning: alot of dupl. code with the "cultivar create" controlller
157
145
  inputId : "",
158
146
  inputDescrId: "",
159
147
  onBreederCreatePress: function (evt) {
@@ -162,7 +150,7 @@ sap.ui.define([
162
150
  oRouter.navTo( "breeder_create" );
163
151
 
164
152
  },
165
- onBreederIDValueHelp : function (oEvent) {
153
+ onBreederIdValueHelp : function (oEvent) {
166
154
 
167
155
  this.inputId = oEvent.getSource().getId();
168
156
  this.inputDescrId = this.inputId + "_descr";
@@ -198,7 +186,31 @@ sap.ui.define([
198
186
  }
199
187
  evt.getSource().getBinding("items").filter([]);
200
188
 
201
- }
189
+ },
190
+ handleUploadComplete: function() {
191
+ sap.m.MessageToast.show("File Uploaded");
192
+ // var oFilerefresh = this.getView().byId("itemlist");
193
+ // oFilerefresh.getModel("Data").refresh(true);
194
+ // sap.m.MessageToast.show("File refreshed");
195
+
196
+ },
197
+ handleUploadPress: function() {
198
+ var oFileUploader = this.getView().byId("fileUploader");
199
+ if (oFileUploader.getValue() === "") {
200
+ MessageToast.show("Please Choose any File");
201
+ }
202
+ oFileUploader.addHeaderParameter(new sap.ui.unified.FileUploaderParameter({
203
+ name: "SLUG",
204
+ value: oFileUploader.getValue()
205
+ }));
206
+ oFileUploader.setSendXHR(true);
207
+
208
+ oFileUploader.upload();
209
+
210
+
211
+
212
+ }
213
+
202
214
 
203
215
  });
204
216
  });
@@ -0,0 +1,28 @@
1
+ sap.ui.define([
2
+ 'jquery.sap.global',
3
+ 'sap/m/MessageToast',
4
+ 'sap/ui/core/Fragment',
5
+ 'sap/ui/core/mvc/Controller',
6
+ 'sap/ui/model/Filter',
7
+ 'sap/ui/model/odata/ODataModel'
8
+ ], function(jQuery, MessageToast, Fragment, Controller, Filter, ODataModel) {
9
+ "use strict";
10
+
11
+ var CController = Controller.extend("vibert.controller.MenuList", {
12
+
13
+ onListItemPress: function(oEvent) {
14
+ // also possible:
15
+ // var oRouter = this.getOwnerComponent().getRouterFor(this);
16
+ var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
17
+ var oItem = oEvent.getSource();
18
+ var sToPageId = oEvent.getParameter("listItem").getCustomData()[0].getValue();
19
+ oRouter.navTo( sToPageId );
20
+ }
21
+ }
22
+ );
23
+
24
+
25
+
26
+ return CController;
27
+
28
+ });
@@ -15,14 +15,14 @@ sap.ui.define([
15
15
  },
16
16
  _onDetailMatched : function (oEvent) {
17
17
  var oObject = oEvent.getParameter("arguments");
18
- var sCultivarID = oObject.cultivar_ID ;
18
+ var sCultivarID = oObject.cultivar_id ;
19
19
  var sObjPath = "/cultivar(" + sCultivarID + ")" ;
20
20
  var sAttribPath = "/cultivar(" + sCultivarID + ")/name" ;
21
21
 
22
22
  var oView = this.getView();
23
23
 
24
24
  var oModel = this.getView().getModel();
25
- var oRIDtxt = this.byId("cultivar_ID_descr");
25
+ var oRIDtxt = this.byId("cultivar_id_descr");
26
26
 
27
27
  function onSuccessHandler(){
28
28
  var sRtxt = oModel.getProperty(sAttribPath);
@@ -33,7 +33,7 @@ sap.ui.define([
33
33
 
34
34
  oModel.read(sObjPath, {success: onSuccessHandler, error: onErrorHandler } );
35
35
 
36
- var oRID = this.byId("cultivar_ID");
36
+ var oRID = this.byId("cultivar_id");
37
37
  oRID.setValue(sCultivarID);
38
38
  //
39
39
  // twoway bindingmode has to be set from start on creation of the Model,
@@ -43,10 +43,7 @@ sap.ui.define([
43
43
  },
44
44
  _onBindingChange : function (oEvent) {
45
45
  var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
46
- // No data for the binding
47
- //if (!this.getView().getBindingContext()) {
48
- // oRouter.navTo("notFound");
49
- //}
46
+
50
47
  },
51
48
  onCreate: function() {
52
49
 
@@ -58,15 +55,15 @@ sap.ui.define([
58
55
  var oEntry = {};
59
56
 
60
57
  var _that = this;
61
- oEntry.cultivar_ID = this.byId('cultivar_ID').getValue();
62
- oEntry.ptype_ID = this.byId('ptype_ID').getValue();
63
- oEntry.parent_ID = this.byId('parent_ID').getValue();
58
+ oEntry.cultivar_id = this.byId('cultivar_id').getValue();
59
+ oEntry.ptype_id = this.byId('ptype_id').getValue();
60
+ oEntry.parent_id = this.byId('parent_id').getValue();
64
61
 
65
62
  function onSuccessHandler(){
66
63
  oModel.refresh();
67
- _that.byId('cultivar_ID').setValue("");
68
- _that.byId('ptype_ID').setValue("");
69
- _that.byId('parent_ID').setValue("");
64
+ _that.byId('cultivar_id').setValue("");
65
+ _that.byId('ptype_id').setValue("");
66
+ _that.byId('parent_id').setValue("");
70
67
  MessageToast.show("Create success");
71
68
  _that.onNavBack();
72
69
 
@@ -93,7 +90,7 @@ sap.ui.define([
93
90
  inputId : "",
94
91
  inputDescrId: "",
95
92
 
96
- onIDValueHelp : function (oEvent) {
93
+ onIdValueHelp : function (oEvent) {
97
94
 
98
95
  this.inputId = oEvent.getSource().getId();
99
96
  this.inputDescrId = this.inputId + "_descr";
@@ -29,10 +29,7 @@ sap.ui.define([
29
29
  },
30
30
  _onBindingChange : function (oEvent) {
31
31
  var oRouter = sap.ui.core.UIComponent.getRouterFor(this);
32
- // No data for the binding
33
- //if (!this.getView().getBindingContext()) {
34
- // oRouter.navTo("notFound");
35
- //}
32
+
36
33
  },
37
34
  onSave: function() {
38
35
  var oView = this.getView();
@@ -40,8 +37,6 @@ sap.ui.define([
40
37
  var sPath = this._sObjectPath;
41
38
  var mParms = {};
42
39
 
43
- // oModel.updateBindings();
44
-
45
40
  var oData = oModel.getData(sPath);
46
41
  function onSuccessHandler(){
47
42
  oModel.refresh();
@@ -75,7 +70,7 @@ sap.ui.define([
75
70
  inputId : "",
76
71
  inputDescrId: "",
77
72
 
78
- onIDValueHelp : function (oEvent) {
73
+ onIdValueHelp : function (oEvent) {
79
74
 
80
75
  this.inputId = oEvent.getSource().getId();
81
76
  this.inputDescrId = this.inputId + "_descr";
@@ -21,7 +21,7 @@ function (Controller, MessageToast, ODataModel, Dialog, ResourceModel) {
21
21
  this.getView().setModel(ojModel, "myPtModel");
22
22
  var a = ojModel.getProperty("/d/results");
23
23
  for (var i = 0; i < a.length; i++) {
24
- this.parenstypusDescriptioMap[a[i].ID]= a[i].descriptio;
24
+ this.parenstypusDescriptioMap[a[i].id]= a[i].descriptio;
25
25
  }
26
26
  // merge lookup map to be used later
27
27
  ojModel.setData({"map":this.parenstypusDescriptioMap},true);
@@ -17,7 +17,7 @@
17
17
  selectionMode="Single"
18
18
  rowSelectionChange = "onSelectionChange"
19
19
  visibleRowCount="20"
20
- visibleRowCountMode="auto"
20
+ visibleRowCountMode="Auto"
21
21
  selectionBehavior="Row"
22
22
  rows="{
23
23
  path: '/breeder',
@@ -4,21 +4,25 @@
4
4
  xmlns:f="sap.ui.layout.form"
5
5
  xmlns:mvc="sap.ui.core.mvc"
6
6
  controllerName="vibert.controller.Breeder_Create" >
7
- <Page title="Create Breeder record" showNavButton="true"
8
- navButtonPress="onNavBack" >
7
+ <Page title="Create Breeder record" showNavButton="false" >
9
8
 
10
- <headerContent>
11
- <Button icon="sap-icon://create" type="Accept" press="onCreate" text="Create"/>
12
- </headerContent>
9
+ <customHeader>
10
+ <Bar>
11
+ <contentLeft>
12
+ <Button icon="sap-icon://nav-back" press="onNavBack"/>
13
+ <Button icon="sap-icon://create" type="Accept" text="Create" press="onCreate"/>
14
+ </contentLeft>
15
+ </Bar>
16
+ </customHeader>
13
17
 
14
18
 
15
19
  <ObjectHeader title="{id}"/>
16
20
 
17
21
  <f:SimpleForm id="breeder_create_form" editable="true">
18
22
  <Label text="First name"/>
19
- <Input id="first_name" type="text" name="first_name" enabled="true" />
23
+ <Input id="first_name" type="Text" name="first_name" enabled="true" />
20
24
  <Label text="Last name"/>
21
- <Input id="last_name" type="text" name="last_name" enabled="true" />
25
+ <Input id="last_name" type="Text" name="last_name" enabled="true" />
22
26
  </f:SimpleForm>
23
27
 
24
28
 
@@ -13,9 +13,9 @@
13
13
  <content>
14
14
  <f:SimpleForm editable="true">
15
15
  <Label text="First name" />
16
- <Input id="first_name" type="text" name="first_name" enabled="true" value="{first_name}" />
16
+ <Input id="first_name" type="Text" name="first_name" enabled="true" value="{first_name}" />
17
17
  <Label text="Last name" />
18
- <Input id="last_name" type="text" name="last_name" enabled="true" value="{last_name}" />
18
+ <Input id="last_name" type="Text" name="last_name" enabled="true" value="{last_name}" />
19
19
  </f:SimpleForm>
20
20
  </content>
21
21
  </Panel>
@@ -23,7 +23,7 @@
23
23
  <content>
24
24
  <t:Table id="breeder_cultivar_table" selectionMode="Single"
25
25
  rowSelectionChange="onCultivarSelectionChange"
26
- visibleRowCount="8" visibleRowCountMode="auto"
26
+ visibleRowCount="8" visibleRowCountMode="Auto"
27
27
  rows="{path: 'cultivar' }"
28
28
  selectionBehavior="Row">
29
29
  <t:columns>
@@ -16,15 +16,14 @@
16
16
  selectionMode="Single"
17
17
  rowSelectionChange = "onSelectionChange"
18
18
  visibleRowCount="20"
19
- visibleRowCountMode="auto"
19
+ visibleRowCountMode="Auto"
20
20
  selectionBehavior="Row"
21
21
  rows="{
22
- path: '/cultivar',
23
- parameters: {expand: 'breeder',
24
- operationMode: 'Server'}
22
+ path: '/cultivar',
23
+ parameters: {expand: 'breeder', operationMode: 'Server'}
25
24
  }">
26
25
  <columns>
27
- <Column width="6%" autoResizable="true" sortProperty="ID">
26
+ <Column width="6%" autoResizable="true" sortProperty="id">
28
27
  <m:Label text="Cultivar"/>
29
28
  <template>
30
29
  <m:Text text="{id}"/>
@@ -13,20 +13,20 @@
13
13
  </contentLeft>
14
14
  </Bar>
15
15
  </customHeader>
16
- <ObjectHeader title="{ID} : {name}"/>
16
+ <ObjectHeader title="{id} : {name}"/>
17
17
 
18
18
  <f:SimpleForm id="cultivar_create_form" editable="true">
19
19
  <Label text="Name"/>
20
- <Input id="name" type="text" name="name" enabled="true" />
20
+ <Input id="name" type="Text" name="name" enabled="true" />
21
21
  <Label text="Year"/>
22
- <Input id="year" type="text" name="year" enabled="true" />
22
+ <Input id="year" type="Number" name="year" enabled="true" />
23
23
  <Label text="Breeder"/>
24
- <Input id="breeder_ID" type="Text"
24
+ <Input id="breeder_id" type="Text"
25
25
  width="40%"
26
26
  showValueHelp="true"
27
- valueHelpRequest="onBreederIDValueHelp"
28
- name="breeder_ID" enabled="true" />
29
- <Text id="breeder_ID_descr" />
27
+ valueHelpRequest="onBreederIdValueHelp"
28
+ name="breeder_id" enabled="true" />
29
+ <Text id="breeder_id_descr" />
30
30
  </f:SimpleForm>
31
31
 
32
32
  </Page>
@@ -1,4 +1,4 @@
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">
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" xmlns:u="sap.ui.unified" controllerName="vibert.controller.Cultivar_Detail">
2
2
  <Page title="Cultivar detail">
3
3
  <customHeader>
4
4
  <Bar>
@@ -9,6 +9,14 @@
9
9
  <Button icon="sap-icon://nav-back" press="onNavBack" />
10
10
  <Button icon="sap-icon://save" type="Accept" press="onSave" text="Save changes" />
11
11
  <Button icon="sap-icon://create" type="Accept" text="Create" press="onCreatePress" />
12
+ <!-- Teaser
13
+ <Button icon="sap-icon://attachment" type="Accept" text="Upload" press="handleUploadPress" />
14
+ <u:FileUploader id="fileUploader" useMultipart="false" name="myFileUpload"
15
+ uploadUrl="http://localhost:9494/odata" width="400px"
16
+ tooltip="Upload your file to the local server"
17
+ uploadComplete="handleUploadComplete"/>
18
+ -->
19
+
12
20
  </contentLeft>
13
21
  </Bar>
14
22
  </customHeader>
@@ -17,11 +25,11 @@
17
25
  <content>
18
26
  <f:SimpleForm editable="true">
19
27
  <Label text="Name" />
20
- <Input id="name" type="text" name="name" enabled="true" value="{name}" />
28
+ <Input id="name" type="Text" name="name" enabled="true" value="{name}" />
21
29
  <Label text="Year" />
22
- <Input id="year" type="integer" name="year" enabled="true" value="{year}" />
30
+ <Input id="year" type="Number" name="year" enabled="true" value="{year}" />
23
31
  <Label text="Breeder" />
24
- <Input id="breeder_id" type="Text" width="40%" showValueHelp="true" valueHelpRequest="onBreederIDValueHelp" name="breeder_id" value="{breeder_id}" enabled="true" />
32
+ <Input id="breeder_id" type="Text" width="40%" showValueHelp="true" valueHelpRequest="onBreederIdValueHelp" name="breeder_id" value="{breeder_id}" enabled="true" />
25
33
  <Link id="breeder_id_descr" text="{breeder/first_name} {breeder/last_name}" press="handleBreederPress" />
26
34
  <Button icon="sap-icon://create" type="Accept" text="Create" press="onBreederCreatePress" />
27
35
  </f:SimpleForm>
@@ -33,7 +41,7 @@
33
41
  <t:Table id="parent_table"
34
42
  rows="{path: 'parent', parameters:{expand : 'cultivar/breeder,parent/breeder'} }" rowSelectionChange="onParentSelectionChange"
35
43
  selectionMode="Single" visibleRowCount="4"
36
- visibleRowCountMode="auto" selectionBehavior="Row">
44
+ visibleRowCountMode="Auto" selectionBehavior="Row">
37
45
  <t:columns>
38
46
  <t:Column width="10%" autoResizable="true">
39
47
  <Label text="Par. Type" />
@@ -65,7 +73,7 @@
65
73
  <t:Table id="child_table"
66
74
  rows="{path: 'child', parameters:{expand : 'cultivar/breeder'} }"
67
75
  rowSelectionChange="onChildSelectionChange"
68
- selectionMode="Single" visibleRowCount="10" visibleRowCountMode="auto" selectionBehavior="Row">
76
+ selectionMode="Single" visibleRowCount="10" visibleRowCountMode="Auto" selectionBehavior="Row">
69
77
  <t:columns>
70
78
  <t:Column width="10%" autoResizable="true">
71
79
  <Label text="Par. Type" />
@@ -2,7 +2,7 @@
2
2
  xmlns:custom="http://schemas.sap.com/sapui5/extension/sap.ui.core.CustomData/1"
3
3
  xmlns="sap.m" displayBlock="true"
4
4
  controllerName="vibert.controller.FiveApplesApp" >
5
- <SplitApp id="FiveApplesApp" enableScrolling="true">
5
+ <SplitApp id="FiveApplesApp">
6
6
  <!-- pages will be filled automatically via routing -->
7
7
 
8
8
  </SplitApp>
@@ -9,7 +9,7 @@
9
9
  </Toolbar>
10
10
  <Table id="m_cultivar_table_h" showNoData="false">
11
11
  <columns>
12
- <Column width="6%" autoResizable="true" sortProperty="ID">
12
+ <Column width="6%" autoResizable="true" sortProperty="id">
13
13
  <Text text="cultivar ID"/> </Column>
14
14
  <Column width="10%" autoResizable="true" >
15
15
  <Text text="Type"/> </Column>
@@ -31,7 +31,7 @@
31
31
  <items>
32
32
  <ColumnListItem press="handlePress" type="Navigation">
33
33
  <cells>
34
- <ObjectIdentifier title="{cultivar ID}" text="{ID}" />
34
+ <ObjectIdentifier title="{cultivar ID}" text="{id}" />
35
35
  <Text text="{name}" />
36
36
  </cells>
37
37
  </ColumnListItem>
@@ -18,7 +18,7 @@
18
18
  selectionMode="Single"
19
19
  rowSelectionChange = "onSelectionChange"
20
20
  visibleRowCount="20"
21
- visibleRowCountMode="auto"
21
+ visibleRowCountMode="Auto"
22
22
  selectionBehavior="Row"
23
23
  rows="{
24
24
  path: '/parentage',
@@ -11,16 +11,32 @@
11
11
  <ObjectHeader title="Create parentage for cultivar id {cultivar_id} : " />
12
12
  <f:SimpleForm id="parens_create_form" editable="true">
13
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" />
14
+ <Input id="cultivar_id" type="Text" width="40%" showValueHelp="true"
15
+ valueHelpRequest="onIdValueHelp" name="cultivar_id" enabled="true" />
16
+ <Text id="cultivar_id_descr" />
16
17
  <Label text="Parent type" />
18
+
19
+ <ComboBox id="ptype_id_combo"
20
+ showSecondaryValues= "true"
21
+ width="40%"
22
+ enabled="false"
23
+ value="{ptype_id}"
24
+ items="{path: 'par_type' }" >
25
+ <core:ListItem key="{id}" text="{id}"
26
+ additionalText = "{description}"/>
27
+ </ComboBox>
28
+ <Text text="{path:'par_type/description'}" />
29
+
30
+ <!--
17
31
  <ComboBox id="ptype_id" showSecondaryValues="true" width="40%" enabled="true" items="{path: 'myPtModel>/d' }">
18
32
  <core:ListItem key="{myPtModel>id}" text="{myPtModel>id}" additionalText="{myPtModel>description}" />
19
33
  </ComboBox>
20
34
  <Text id="ptype_id_descr" />
35
+ -->
21
36
  <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" />
37
+ <Input id="parent_id" type="Text" name="parent_id" width="40%"
38
+ showValueHelp="true" valueHelpRequest="onIdValueHelp" enabled="true" />
39
+ <Text id="parent_id_descr" />
24
40
  </f:SimpleForm>
25
41
  </Page>
26
42
  </mvc:View>
@@ -17,7 +17,7 @@
17
17
  <Input id="cultivar_id" type="Text"
18
18
  width="40%"
19
19
  showValueHelp="true"
20
- valueHelpRequest="onIDValueHelp"
20
+ valueHelpRequest="onIdValueHelp"
21
21
  name="cultivar_id" enabled="false" value="{cultivar_id}" />
22
22
  <Text id="cultivar_id_descr" text="{cultivar/name}"/>
23
23
 
@@ -30,19 +30,18 @@
30
30
  width="40%"
31
31
  enabled="false"
32
32
  value="{ptype_id}"
33
- items="{path: 'myPtModel>/d' }" >
34
- <core:ListItem key="{myPtModel>id}" text="{myPtModel>id}"
35
- additionalText = "{myPtModel>description}"/>
33
+ items="{path: 'par_type' }" >
34
+ <core:ListItem key="{id}" text="{id}" additionalText = "{description}"/>
36
35
  </ComboBox>
37
36
 
38
37
 
39
- <Text text="{path:'ptype_id' , formatter: '.parentageTypeDescription'}" />
38
+ <Text text="{path:'par_type/description'}" />
40
39
 
41
40
  <Label text="Parent id"/>
42
41
  <Input id="parent_id" type="Text" name="parent_id"
43
42
  width="40%"
44
43
  showValueHelp="true"
45
- valueHelpRequest="onIDValueHelp"
44
+ valueHelpRequest="onIdValueHelp"
46
45
  enabled="false" value="{parent_id}" />
47
46
  <Text id="parent_id_descr" text="{parent/name}"/>
48
47
  </f:SimpleForm>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fiveapples
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - D.M.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-23 00:00:00.000000000 Z
11
+ date: 2020-01-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: safrano
@@ -92,6 +92,7 @@ files:
92
92
  - lib/ui5/controller/FiveApplesApp.controller.js
93
93
  - lib/ui5/controller/MCultivarList.controller.js
94
94
  - lib/ui5/controller/MenuList.controller.js
95
+ - lib/ui5/controller/MenuList.controller.js~
95
96
  - lib/ui5/controller/NotFound.controller.js
96
97
  - lib/ui5/controller/ParentageList.controller.js
97
98
  - lib/ui5/controller/Parentage_Create.controller.js