biz9-logic 4.8.225 → 4.8.227
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.
- package/biz9_config +1 -1
- package/index.js +22 -9
- package/package.json +1 -1
- package/test.js +5 -3
package/biz9_config
CHANGED
package/index.js
CHANGED
|
@@ -191,7 +191,7 @@ class Page_Logic {
|
|
|
191
191
|
}
|
|
192
192
|
return item_list;
|
|
193
193
|
};
|
|
194
|
-
static
|
|
194
|
+
static get_section_type_list = () => {
|
|
195
195
|
return [
|
|
196
196
|
{value:'text',label:'Text'},
|
|
197
197
|
{value:'note',label:'Note'},
|
|
@@ -199,14 +199,8 @@ class Page_Logic {
|
|
|
199
199
|
{value:'list',label:'List'},
|
|
200
200
|
];
|
|
201
201
|
};
|
|
202
|
-
static
|
|
202
|
+
static get_section_property_type = (type,section_id,value_id,is_title) =>{
|
|
203
203
|
//page['section_1_value_1_type'] -- / text,note,photo,list
|
|
204
|
-
//page['section_1_value_1_text_value']
|
|
205
|
-
//page['section_1_value_1_note_value']
|
|
206
|
-
//page['section_1_value_1_photo_value']
|
|
207
|
-
//page['section_1_value_1_list_value_1']
|
|
208
|
-
//page['section_1_value_1_list_value_2']
|
|
209
|
-
//page['section_1_value_1_list_value_3']
|
|
210
204
|
let type_str = '';
|
|
211
205
|
switch(type){
|
|
212
206
|
case 'text':
|
|
@@ -222,7 +216,26 @@ class Page_Logic {
|
|
|
222
216
|
type_str = 'list';
|
|
223
217
|
break;
|
|
224
218
|
};
|
|
225
|
-
return !is_title ? 'section_'+section_id + '_value_'+value_id + "
|
|
219
|
+
return !is_title ? 'section_'+section_id + '_value_'+value_id + "_type" : 'Section '+section_id + ' Value '+value_id;
|
|
220
|
+
}
|
|
221
|
+
static get_section_property_type_value = (type,section_id,value_id) =>{
|
|
222
|
+
//page['section_1_value_1_[text,note,photo,list]_value']
|
|
223
|
+
let type_str = '';
|
|
224
|
+
switch(type){
|
|
225
|
+
case 'text':
|
|
226
|
+
type_str = 'text';
|
|
227
|
+
break;
|
|
228
|
+
case 'note':
|
|
229
|
+
type_str = 'note';
|
|
230
|
+
break;
|
|
231
|
+
case 'photo':
|
|
232
|
+
type_str = 'photo';
|
|
233
|
+
break;
|
|
234
|
+
case 'list':
|
|
235
|
+
type_str = 'list';
|
|
236
|
+
break;
|
|
237
|
+
};
|
|
238
|
+
return 'section_'+section_id + '_value_'+value_id + "_" + type_str + "_value";
|
|
226
239
|
}
|
|
227
240
|
|
|
228
241
|
static get_section_property_list = (type,section_id,value_id,row_id) =>{
|
package/package.json
CHANGED
package/test.js
CHANGED
|
@@ -32,9 +32,11 @@ describe("connect", () => {
|
|
|
32
32
|
|
|
33
33
|
function(call) {
|
|
34
34
|
console.log('PAGE-SECTION-START');
|
|
35
|
-
//console.log(Page_Logic.
|
|
36
|
-
console.log(Page_Logic.
|
|
37
|
-
console.log(Page_Logic.
|
|
35
|
+
//console.log(Page_Logic.get_page_section_type_list());
|
|
36
|
+
//console.log(Page_Logic.get_section_property_type('text',1,2,true));
|
|
37
|
+
console.log(Page_Logic.get_section_property_type_value('text',1,2,true));
|
|
38
|
+
//console.log(Page_Logic.get_section_property_list(FieldType.SECTION_PROPERTY_TYPE_LIST_VALUE,1,2,3));
|
|
39
|
+
//console.log(Page_Logic.get_section_property_list(FieldType.SECTION_PROPERTY_TYPE_LIST_FIELD,1,2,3));
|
|
38
40
|
console.log('PAGE-SECTION-END');
|
|
39
41
|
|
|
40
42
|
|