biz9-logic 4.0.36 → 4.0.38
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 +15 -3
- package/package.json +1 -1
- package/test.js +4 -4
package/biz9_config
CHANGED
package/index.js
CHANGED
|
@@ -80,7 +80,16 @@ class Product{
|
|
|
80
80
|
}
|
|
81
81
|
return product;
|
|
82
82
|
};
|
|
83
|
-
|
|
83
|
+
static get_test_list=(option)=>{
|
|
84
|
+
if(!option){
|
|
85
|
+
option={product_count:10};
|
|
86
|
+
}
|
|
87
|
+
let item_list=[];
|
|
88
|
+
for(let a=0;a<option.product_count;a++){
|
|
89
|
+
item_list.push(Product.get_test(option));
|
|
90
|
+
}
|
|
91
|
+
return item_list;
|
|
92
|
+
};
|
|
84
93
|
static get_test_list_by_category = (option) =>{
|
|
85
94
|
let product_list = [];
|
|
86
95
|
let category_count = 9;
|
|
@@ -108,6 +117,7 @@ class Product{
|
|
|
108
117
|
}
|
|
109
118
|
return [category_list,product_list]
|
|
110
119
|
};
|
|
120
|
+
|
|
111
121
|
}
|
|
112
122
|
class Service{
|
|
113
123
|
static get_test = (option) =>{
|
|
@@ -250,7 +260,7 @@ class Field{
|
|
|
250
260
|
title="";
|
|
251
261
|
}
|
|
252
262
|
if(!option){
|
|
253
|
-
option={get_value:true,value_count:
|
|
263
|
+
option={get_value:true,value_count:10};
|
|
254
264
|
}
|
|
255
265
|
let item = {
|
|
256
266
|
date_create:new moment().toISOString(),
|
|
@@ -264,8 +274,10 @@ class Field{
|
|
|
264
274
|
}
|
|
265
275
|
if(option.get_value){
|
|
266
276
|
if(!option.value_count){
|
|
267
|
-
option.value_count =
|
|
277
|
+
option.value_count = 10;
|
|
268
278
|
}
|
|
279
|
+
console.log('rrr');
|
|
280
|
+
console.log(option.value_count);
|
|
269
281
|
for(let b = 1;b<parseInt(option.value_count);b++){
|
|
270
282
|
item['value_'+String(b)] = 'value ' + String(b);
|
|
271
283
|
}
|
package/package.json
CHANGED
package/test.js
CHANGED
|
@@ -38,11 +38,11 @@ describe("connect", () => {
|
|
|
38
38
|
/* --CONFIG--END */
|
|
39
39
|
|
|
40
40
|
/* --PAGE--START */
|
|
41
|
-
|
|
41
|
+
let page = Page.get_test({item_count:2,page_count:2,get_value:true,get_item:true,value_count:50})
|
|
42
|
+
Log.w("Page",page);
|
|
42
43
|
/*
|
|
43
44
|
let page = Page.get_test({item_count:9,page_count:19,get_item:true,get_value:true})
|
|
44
45
|
//let page = Page.get_test()
|
|
45
|
-
Log.w("Page",page);
|
|
46
46
|
Log.w("Page_section_1",page.section_1);
|
|
47
47
|
Log.w("Page_section_1_section_1_section_1",page.section_1.section_1.section_1);
|
|
48
48
|
*/
|
|
@@ -75,9 +75,9 @@ describe("connect", () => {
|
|
|
75
75
|
/* --PRODUCT--END */
|
|
76
76
|
|
|
77
77
|
/* --EVENT--START */
|
|
78
|
-
let event_list=Event.get_test_list({category_count:5,event_count:9,get_value:false,get_item:false});
|
|
78
|
+
//let event_list=Event.get_test_list({category_count:5,event_count:9,get_value:false,get_item:false});
|
|
79
79
|
//let [category_list,event_list]=Event.get_test_list_by_category({category_count:5,event_count:9});
|
|
80
|
-
Log.w('event_list',event_list);
|
|
80
|
+
//Log.w('event_list',event_list);
|
|
81
81
|
//Log.w('category_list',category_list);
|
|
82
82
|
/* --EVENT--END */
|
|
83
83
|
|