biz9-logic 4.8.47 → 4.8.52
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 +16 -3
- package/package.json +1 -1
- package/test.js +8 -4
package/biz9_config
CHANGED
package/index.js
CHANGED
|
@@ -85,13 +85,14 @@ class Team_Logic {
|
|
|
85
85
|
}
|
|
86
86
|
return team;
|
|
87
87
|
};
|
|
88
|
-
static get_test_member = (title,
|
|
88
|
+
static get_test_member = (team,title,option) =>{
|
|
89
|
+
[title,option] = Field_Logic.get_option_title(title,option);
|
|
89
90
|
option = Field_Logic.get_option(DataType.TEAM,option?option:{});
|
|
90
91
|
let team_member = DataItem.get_new_full_item(
|
|
91
92
|
DataItem.get_new(DataType.ITEM,0),
|
|
92
93
|
DataItem.get_new(DataType.TEAM,team.id),
|
|
93
|
-
DataItem.get_new(DataType.TEAM,team.id)
|
|
94
|
-
|
|
94
|
+
DataItem.get_new(DataType.TEAM,team.id),
|
|
95
|
+
Field_Logic.get_test(title,option));
|
|
95
96
|
team_member.first_name = "First Name "+ Number.get_id();
|
|
96
97
|
team_member.last_name = "Last Name "+ Number.get_id();
|
|
97
98
|
team_member.position = "Position "+ Number.get_id();
|
|
@@ -385,6 +386,17 @@ class Field_Logic {
|
|
|
385
386
|
if(option.get_value){
|
|
386
387
|
item = Field_Logic.get_value_list(item,option);
|
|
387
388
|
}
|
|
389
|
+
if(option.fields){
|
|
390
|
+
for(let a = 0; a<option.fields.length;a++){
|
|
391
|
+
if(!option.get_blank == true){
|
|
392
|
+
item[option.fields[a]] = Str.get_title(option.fields[a]) +"_" + Number.get_id();
|
|
393
|
+
}else{
|
|
394
|
+
item[option.fields[a]] = "";
|
|
395
|
+
|
|
396
|
+
}
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
Log.w('rrr',item);
|
|
388
400
|
return item;
|
|
389
401
|
}
|
|
390
402
|
static get_value_list(item,option){
|
|
@@ -449,6 +461,7 @@ class Field_Logic {
|
|
|
449
461
|
option.item_count = option.item_count ? option.item_count : 9;
|
|
450
462
|
option.category_count = option.category_count ? option.category_count : 9;
|
|
451
463
|
option.category_title = option.category_title ? option.category_title : "";
|
|
464
|
+
option.fields = option.fields ? option.fields : [];
|
|
452
465
|
if(option.data_type==DataType.PAGE){
|
|
453
466
|
option.page_count = option.page_count ? option.page_count : 9;
|
|
454
467
|
option.section_count = option.section_count ? option.section_count : 9;
|
package/package.json
CHANGED
package/test.js
CHANGED
|
@@ -67,8 +67,12 @@ describe("connect", () => {
|
|
|
67
67
|
|
|
68
68
|
/* --TEAM--START */
|
|
69
69
|
//let team = Team_Logic.get_test()
|
|
70
|
-
|
|
70
|
+
let team = Team_Logic.get_test({get_value:false,get_member:true})
|
|
71
|
+
//let team_member = Team_Logic.get_test_member(team,{get_value:true,get_blank:false,fields:['hometown','member_since', 'speaks','last_project','avg_response_time']});
|
|
72
|
+
//let team_member = Blog_Post_Logic.get_test({get_value:true,get_blank:false,fields:['hometown','member_since', 'speaks','last_project','avg_response_time']});
|
|
73
|
+
let team_member = Team_Logic.get_test_member(Team_Logic.get_test(),{fields:["hometown_aa","member_since_bb"], get_value:true});
|
|
71
74
|
//Log.w("team",team);
|
|
75
|
+
Log.w("team_member",team_member);
|
|
72
76
|
//let team_list = Team_Logic.get_test_list();
|
|
73
77
|
//let [team_list,team_list]=Team_Logic.get_test_list_by_team();
|
|
74
78
|
//Log.w('team_list',team_list);
|
|
@@ -255,13 +259,13 @@ describe("connect", () => {
|
|
|
255
259
|
/* --FAQ--START */
|
|
256
260
|
//Log.w("FAQ",Faq_Logic.get_test());
|
|
257
261
|
//Log.w("FAQ List",Faq_Logic.get_test_list(Faq_Logic.get_test()));
|
|
258
|
-
let faq = Faq_Logic.get_test();
|
|
262
|
+
//let faq = Faq_Logic.get_test();
|
|
259
263
|
//let faq = Faq_Logic.get_test('cool 1');
|
|
260
264
|
//let faq = Faq_Logic.get_test('cool 1',{count:33});
|
|
261
265
|
//let faq = Business_Logic.get_test('ser 1',{question_count:33});
|
|
262
|
-
let faq_list = Faq_Logic.get_faq_question_list(faq);
|
|
266
|
+
//let faq_list = Faq_Logic.get_faq_question_list(faq);
|
|
263
267
|
//let faq_list = Faq_Logic.get_question_list();
|
|
264
|
-
Log.w('faq_list',faq_list);
|
|
268
|
+
//Log.w('faq_list',faq_list);
|
|
265
269
|
//Log.w('faq',faq);
|
|
266
270
|
/*
|
|
267
271
|
let review_list = Review.get_test_list({review_count:3,get_item:true})
|