biz9-logic 4.8.242 → 4.8.245
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 +76 -245
- package/package.json +1 -1
- package/test.js +10 -7
package/biz9_config
CHANGED
package/index.js
CHANGED
|
@@ -146,32 +146,6 @@ class Stat_Logic {
|
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
|
-
class Template_Logic {
|
|
150
|
-
static get_test = (title,option) =>{
|
|
151
|
-
if(!Str.check_is_null(title) && Obj.check_is_empty(option)){
|
|
152
|
-
option = title;
|
|
153
|
-
title = "Test " + Num.get_id();
|
|
154
|
-
}
|
|
155
|
-
option = Field_Logic.get_option(DataType.TEMPLATE,option?option:{});
|
|
156
|
-
let template = DataItem.get_new(DataType.TEMPLATE,0,Field_Logic.get_test(title,option));
|
|
157
|
-
if(option.get_item){
|
|
158
|
-
let title_list = ['Header','Body','Footer','Navigation']
|
|
159
|
-
//template.items = Sub_Item_Logic.get_test_list(template,template,option);
|
|
160
|
-
template.items = [];
|
|
161
|
-
for(let a = 0; a<title_list.length;a++){
|
|
162
|
-
let item = Sub_Item_Logic.get_test(title_list[a],template,template,option);
|
|
163
|
-
item.items = Sub_Item_Logic.get_test_section_list(item,template,option);
|
|
164
|
-
item = Sub_Item_Logic.bind_parent_child_list(item,item.items);
|
|
165
|
-
template.items.push(item);
|
|
166
|
-
//template.items.push(Sub_Item_Logic.get_test(title_list[a],template,template,option));
|
|
167
|
-
}
|
|
168
|
-
if(option.get_item_bind){
|
|
169
|
-
template = Sub_Item_Logic.bind_parent_child_list(template,template.items);
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
return template;
|
|
173
|
-
};
|
|
174
|
-
}
|
|
175
149
|
class Page_Logic {
|
|
176
150
|
static get_test = (title,option) =>{
|
|
177
151
|
[title,option] = Field_Logic.get_option_title(title,option);
|
|
@@ -474,6 +448,14 @@ class Content_Logic {
|
|
|
474
448
|
return [category_list,content_list]
|
|
475
449
|
};
|
|
476
450
|
}
|
|
451
|
+
class Template_Logic {
|
|
452
|
+
static get_test = (title,option) =>{
|
|
453
|
+
[title,option] = Field_Logic.get_option_title(title,option);
|
|
454
|
+
option = Field_Logic.get_option(DataType.TEMPLATE,option?option:{});
|
|
455
|
+
let template = DataItem.get_new(DataType.TEMPLATE,0,Field_Logic.get_test(title,option));
|
|
456
|
+
return template;
|
|
457
|
+
};
|
|
458
|
+
}
|
|
477
459
|
class Blog_Post_Logic {
|
|
478
460
|
static get_test = (title,option) =>{
|
|
479
461
|
[title,option] = Field_Logic.get_option_title(title,option);
|
|
@@ -515,6 +497,25 @@ class Blog_Post_Logic {
|
|
|
515
497
|
return [category_list,blog_post_list]
|
|
516
498
|
};
|
|
517
499
|
}
|
|
500
|
+
class Gallery_Logic {
|
|
501
|
+
static get_test = (title,option) =>{
|
|
502
|
+
[title,option] = Field_Logic.get_option_title(title,option);
|
|
503
|
+
option = Field_Logic.get_option(DataType.GALLERY,option?option:{});
|
|
504
|
+
let gallery = DataItem.get_new(DataType.GALLERY,0,Field_Logic.get_test(title,option));
|
|
505
|
+
if(!option.get_blank){
|
|
506
|
+
gallery.date = String(String(Num.get_id(2030)) + "-" + String(Num.get_id(13)) + "-" + String(Num.get_id(30))).trim();
|
|
507
|
+
gallery.time = String(Num.get_id(24)) + ":" + String(Num.get_id(59));
|
|
508
|
+
gallery.website = "Website "+String(Num.get_id());
|
|
509
|
+
}else{
|
|
510
|
+
gallery.website = "";
|
|
511
|
+
}
|
|
512
|
+
if(option.get_item){
|
|
513
|
+
gallery.items = Sub_Item_Logic.get_test_list(gallery,gallery,option);
|
|
514
|
+
}
|
|
515
|
+
return gallery;
|
|
516
|
+
};
|
|
517
|
+
};
|
|
518
|
+
|
|
518
519
|
class Event_Logic {
|
|
519
520
|
static get_test = (title,option) =>{
|
|
520
521
|
[title,option] = Field_Logic.get_option_title(title,option);
|
|
@@ -585,12 +586,10 @@ class Field_Logic {
|
|
|
585
586
|
if(option.get_blank == true){
|
|
586
587
|
option.category_title = "";
|
|
587
588
|
item = {
|
|
588
|
-
title:
|
|
589
|
-
title_url:
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
date_create:"",
|
|
593
|
-
date_save:""
|
|
589
|
+
title:title,
|
|
590
|
+
title_url:title,
|
|
591
|
+
title_url:Str.get_title_url(title),
|
|
592
|
+
setting_visible:"1",
|
|
594
593
|
}
|
|
595
594
|
}else{
|
|
596
595
|
item = {
|
|
@@ -779,7 +778,6 @@ class Field_Logic {
|
|
|
779
778
|
|
|
780
779
|
option.user_count = req.query.user_count ? req.query.user_count : 9;
|
|
781
780
|
option.get_admin = req.query.get_admin ? req.query.get_admin : false;
|
|
782
|
-
option.get_business = req.query.get_business ? req.query.get_business : false;
|
|
783
781
|
option.get_template = req.query.get_template ? req.query.get_template : false;
|
|
784
782
|
option.get_page = req.query.get_page ? req.query.get_page : false;
|
|
785
783
|
|
|
@@ -827,7 +825,6 @@ class FieldType {
|
|
|
827
825
|
/*
|
|
828
826
|
static KEY_ADMIN="key_admin";
|
|
829
827
|
static KEY_APP_ID="key_app_id";
|
|
830
|
-
static KEY_BUSINESS="key_business";
|
|
831
828
|
static KEY_TEMPLATE="key_template";
|
|
832
829
|
static KEY_CART="key_cart";
|
|
833
830
|
static KEY_ORDER="key_order";
|
|
@@ -887,33 +884,29 @@ class PageType {
|
|
|
887
884
|
static HOME='home';
|
|
888
885
|
static ABOUT='about';
|
|
889
886
|
static CONTACT='contact';
|
|
887
|
+
static FAQ='faq';
|
|
888
|
+
static SEARCH='search';
|
|
890
889
|
|
|
891
890
|
static BLOG_POST='blog_post';
|
|
892
|
-
static BLOG_POST_BROWSE='blog_post_browse';
|
|
893
891
|
static BLOG_POST_DETAIL='blog_post_detail';
|
|
894
892
|
|
|
893
|
+
|
|
895
894
|
static CATEGORY='category';
|
|
896
|
-
static CATEGORY_BROWSE='category_browse';
|
|
897
895
|
static CATEGORY_DETAIL='category_detail';
|
|
898
896
|
|
|
899
897
|
static EVENT='event';
|
|
900
|
-
static EVENT_BROWSE='event_browse';
|
|
901
898
|
static EVENT_DETAIL='event_detail';
|
|
902
899
|
|
|
903
900
|
static GALLERY='gallery';
|
|
904
|
-
static GALLERY_BROWSE='gallery_browse';
|
|
905
901
|
static GALLERY_DETAIL='gallery_detail';
|
|
906
902
|
|
|
907
903
|
static SERVICE='service';
|
|
908
|
-
static SERVICE_BROWSE='service_browse';
|
|
909
904
|
static SERVICE_DETAIL='service_detail';
|
|
910
905
|
|
|
911
906
|
static PRODUCT='product';
|
|
912
|
-
static PRODUCT_BROWSE='product_browse';
|
|
913
907
|
static PRODUCT_DETAIL='product_detail';
|
|
914
908
|
|
|
915
909
|
static PROJECT='project';
|
|
916
|
-
static PROJECT_BROWSE='project_browse';
|
|
917
910
|
static PROJECT_DETAIL='project_detail';
|
|
918
911
|
|
|
919
912
|
static SECTION_1='section_1';
|
|
@@ -971,7 +964,6 @@ class DataType {
|
|
|
971
964
|
static ACTIVITY='activity_biz';
|
|
972
965
|
static APP='app_biz';
|
|
973
966
|
static BLANK='blank_biz';
|
|
974
|
-
static BUSINESS='business_biz';
|
|
975
967
|
static BLOG_POST='blog_post_biz';
|
|
976
968
|
static CART_ITEM="cart_item_biz";
|
|
977
969
|
static CATEGORY='category_biz';
|
|
@@ -1055,8 +1047,6 @@ class DataType {
|
|
|
1055
1047
|
return 'content';
|
|
1056
1048
|
case DataType.ITEM:
|
|
1057
1049
|
return 'item';
|
|
1058
|
-
case DataType.BUSINESS:
|
|
1059
|
-
return 'business';
|
|
1060
1050
|
case DataType.CUSTOM_FIELD:
|
|
1061
1051
|
return 'custom_field';
|
|
1062
1052
|
}
|
|
@@ -1271,73 +1261,6 @@ class Admin_Logic {
|
|
|
1271
1261
|
return admin.address_1 + " "+ admin.address_2 + " " + admin.city + " " + admin.state + " " + admin.zip;
|
|
1272
1262
|
}
|
|
1273
1263
|
}
|
|
1274
|
-
class Business_Logic {
|
|
1275
|
-
static get_new = (title,option) =>{
|
|
1276
|
-
[title,option] = Field_Logic.get_option_title(title,option);
|
|
1277
|
-
return DataItem.get_new_full_item(
|
|
1278
|
-
DataItem.get_new(DataType.BUSINESS,0),
|
|
1279
|
-
DataItem.get_new(DataType.BUSINESS,0),
|
|
1280
|
-
DataItem.get_new(DataType.BUSINESS,0),{
|
|
1281
|
-
title:title,
|
|
1282
|
-
email:"",
|
|
1283
|
-
phone:"",
|
|
1284
|
-
address_1:"",
|
|
1285
|
-
address_2:"",
|
|
1286
|
-
city:"",
|
|
1287
|
-
state:"",
|
|
1288
|
-
zip:"",
|
|
1289
|
-
website:"",
|
|
1290
|
-
youtube:"",
|
|
1291
|
-
instagram:"",
|
|
1292
|
-
facebook:"",
|
|
1293
|
-
twitter:""
|
|
1294
|
-
});
|
|
1295
|
-
};
|
|
1296
|
-
static get_test = (title,option) =>{
|
|
1297
|
-
[title,option] = Field_Logic.get_option_title(title,option);
|
|
1298
|
-
option = Field_Logic.get_option(DataType.BUSINESS,option?option:{});
|
|
1299
|
-
let item = DataItem.get_new(DataType.BUSINESS,0);
|
|
1300
|
-
let city_list = ["Miami","Atlanta","Chicago","Seattle","New York City"];
|
|
1301
|
-
let state_list = ["Georgia","New York","Illinois","Washington","Flordia"];
|
|
1302
|
-
let business = DataItem.get_new(DataType.BUSINESS,0,Field_Logic.get_test(title,option));
|
|
1303
|
-
if(!option.get_blank){
|
|
1304
|
-
business.email="ceo@business"+Num.get_id()+".com";
|
|
1305
|
-
business.phone=Num.get_id(parseInt(777+100)) + "-" + Num.get_id(parseInt(777+100)) + "-"+Num.get_id(parseInt(7777+1000));
|
|
1306
|
-
business.address_1=Num.get_id(99)+" Main St.";
|
|
1307
|
-
business.address_2="PO "+Num.get_id(99);
|
|
1308
|
-
business.city=city_list[Num.get_id(city_list.length-1)];
|
|
1309
|
-
business.state=state_list[Num.get_id(state_list.length-1)];
|
|
1310
|
-
business.zip=Num.get_id(parseInt(77777+1000));
|
|
1311
|
-
business.website="website_" + Num.get_id(9999);
|
|
1312
|
-
business.youtube="youtube_"+Num.get_id(9999);
|
|
1313
|
-
business.instagram="instagram_"+Num.get_id(9999);
|
|
1314
|
-
business.facebook="facebook_"+Num.get_id(9999);
|
|
1315
|
-
business.twitter="twitter_"+Num.get_id(9999);
|
|
1316
|
-
}else{
|
|
1317
|
-
business.email="";
|
|
1318
|
-
business.phone="";
|
|
1319
|
-
business.address_1="";
|
|
1320
|
-
business.address_2="";
|
|
1321
|
-
business.city="";
|
|
1322
|
-
business.state="";
|
|
1323
|
-
business.zip="";
|
|
1324
|
-
business.website="";
|
|
1325
|
-
business.youtube="";
|
|
1326
|
-
business.instagram="";
|
|
1327
|
-
business.facebook="";
|
|
1328
|
-
business.twitter="";
|
|
1329
|
-
}
|
|
1330
|
-
return business;
|
|
1331
|
-
};
|
|
1332
|
-
static get_full_address(business){
|
|
1333
|
-
business.address_1 = (business.address_1) ? business.address_1 : "";
|
|
1334
|
-
business.address_2 = (business.address_2) ? business.address_2 : "";
|
|
1335
|
-
business.city = (business.city) ? business.city : "";
|
|
1336
|
-
business.state = (business.state) ? business.state : "";
|
|
1337
|
-
business.zip = (business.zip) ? business.zip : "";
|
|
1338
|
-
return business.address_1 + " "+ business.address_2 + " " + business.city + " " + business.state + " " + business.zip;
|
|
1339
|
-
}
|
|
1340
|
-
}
|
|
1341
1264
|
class DataItem {
|
|
1342
1265
|
static get_new = (data_type,id,option) => {
|
|
1343
1266
|
return get_new_item_main(data_type,id,option?option:{});
|
|
@@ -1346,23 +1269,13 @@ class DataItem {
|
|
|
1346
1269
|
return get_new_full_item_main(item,parent_item,top_item,option?option:{});
|
|
1347
1270
|
};
|
|
1348
1271
|
}
|
|
1349
|
-
class
|
|
1350
|
-
static
|
|
1351
|
-
let action_url="
|
|
1272
|
+
class Dashboard_Url {
|
|
1273
|
+
static user_home = (app_id,url,params) => {
|
|
1274
|
+
let action_url="dashboard/user_home";
|
|
1352
1275
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1353
1276
|
};
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
static get = (app_id,url,key,params) => {
|
|
1357
|
-
let action_url="blank/get/"+key;
|
|
1358
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1359
|
-
};
|
|
1360
|
-
static browse = (app_id,url,params) => {
|
|
1361
|
-
let action_url="blank/browse";
|
|
1362
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1363
|
-
};
|
|
1364
|
-
static category = (app_id,url,category,params) => {
|
|
1365
|
-
let action_url="blank/category/"+category;
|
|
1277
|
+
static app_home = (app_id,url,params) => {
|
|
1278
|
+
let action_url="dashboard/app_home";
|
|
1366
1279
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1367
1280
|
};
|
|
1368
1281
|
}
|
|
@@ -1371,39 +1284,11 @@ class Blog_Post_Url {
|
|
|
1371
1284
|
let action_url="blog_post/get/"+key;
|
|
1372
1285
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1373
1286
|
};
|
|
1374
|
-
static browse = (app_id,url,params) => {
|
|
1375
|
-
let action_url="blog_post/browse";
|
|
1376
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1377
|
-
};
|
|
1378
|
-
static category = (app_id,url,category,params) => {
|
|
1379
|
-
let action_url="blog_post/category/"+category;
|
|
1380
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1381
|
-
};
|
|
1382
1287
|
static search = (app_id,url,params) => {
|
|
1383
1288
|
let action_url="blog_post/search";
|
|
1384
1289
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1385
1290
|
};
|
|
1386
1291
|
}
|
|
1387
|
-
class Custom_Field_Url {
|
|
1388
|
-
static get = (app_id,url,data_type,key,params) => {
|
|
1389
|
-
let action_url="custom_field/get/"+data_type+"/"+key;
|
|
1390
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1391
|
-
};
|
|
1392
|
-
static browse = (app_id,url,params) => {
|
|
1393
|
-
let action_url="custom_field/browse";
|
|
1394
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1395
|
-
};
|
|
1396
|
-
}
|
|
1397
|
-
class FAQ_Url {
|
|
1398
|
-
static get = (app_id,url,key,params) => {
|
|
1399
|
-
let action_url="faq/"+key;
|
|
1400
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1401
|
-
};
|
|
1402
|
-
static category = (app_id,url,title_url,params) => {
|
|
1403
|
-
let action_url="faq/category/"+title_url;
|
|
1404
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1405
|
-
};
|
|
1406
|
-
}
|
|
1407
1292
|
class Cart_Url {
|
|
1408
1293
|
static post = (app_id,url,parent_data_type,params) => {
|
|
1409
1294
|
let action_url="cart/post/"+parent_data_type;
|
|
@@ -1437,42 +1322,16 @@ class Product_Url {
|
|
|
1437
1322
|
let action_url="product/get/"+key;
|
|
1438
1323
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1439
1324
|
};
|
|
1440
|
-
static browse = (app_id,url,params) => {
|
|
1441
|
-
let action_url="product/browse";
|
|
1442
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1443
|
-
};
|
|
1444
|
-
static category = (app_id,url,category,params) => {
|
|
1445
|
-
let action_url="product/category/"+category;
|
|
1446
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1447
|
-
};
|
|
1448
1325
|
static search = (app_id,url,params) => {
|
|
1449
1326
|
let action_url="product/search";
|
|
1450
1327
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1451
1328
|
};
|
|
1452
1329
|
}
|
|
1453
|
-
class Review_Url {
|
|
1454
|
-
static get = (app_id,url,parent_data_type,page_current,page_size,params) => {
|
|
1455
|
-
let action_url="review/get/"+parent_data_type+"/"+page_current+"/"+page_size;
|
|
1456
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1457
|
-
};
|
|
1458
|
-
static post = (app_id,url,parent_data_type,parent_id,params) => {
|
|
1459
|
-
let action_url="review/post/"+parent_data_type+"/"+parent_id;
|
|
1460
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1461
|
-
};
|
|
1462
|
-
}
|
|
1463
1330
|
class Event_Url {
|
|
1464
1331
|
static get = (app_id,url,key,params) => {
|
|
1465
1332
|
let action_url="event/get/"+key;
|
|
1466
1333
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1467
1334
|
};
|
|
1468
|
-
static browse = (app_id,url,params) => {
|
|
1469
|
-
let action_url="event/browse";
|
|
1470
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1471
|
-
};
|
|
1472
|
-
static category = (app_id,url,category,params) => {
|
|
1473
|
-
let action_url="event/category/"+category;
|
|
1474
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1475
|
-
};
|
|
1476
1335
|
static search = (app_id,url,params) => {
|
|
1477
1336
|
let action_url="event/search";
|
|
1478
1337
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
@@ -1483,54 +1342,16 @@ class Service_Url {
|
|
|
1483
1342
|
let action_url="service/get/"+key;
|
|
1484
1343
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1485
1344
|
};
|
|
1486
|
-
static browse = (app_id,url,params) => {
|
|
1487
|
-
let action_url="service/browse";
|
|
1488
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1489
|
-
};
|
|
1490
|
-
static category = (app_id,url,category,params) => {
|
|
1491
|
-
let action_url="service/category/"+category;
|
|
1492
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1493
|
-
};
|
|
1494
1345
|
static search = (app_id,url,params) => {
|
|
1495
1346
|
let action_url="service/search";
|
|
1496
1347
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1497
1348
|
};
|
|
1498
1349
|
}
|
|
1499
|
-
class Content_Url {
|
|
1500
|
-
static portfolio = (app_id,url,params) => {
|
|
1501
|
-
let action_url="content/portfolio";
|
|
1502
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1503
|
-
};
|
|
1504
|
-
static get = (app_id,url,key,params) => {
|
|
1505
|
-
let action_url="content/get/"+key;
|
|
1506
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1507
|
-
};
|
|
1508
|
-
static browse = (app_id,url,params) => {
|
|
1509
|
-
let action_url="content/browse";
|
|
1510
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1511
|
-
};
|
|
1512
|
-
static category = (app_id,url,category,params) => {
|
|
1513
|
-
let action_url="content/category/"+category;
|
|
1514
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1515
|
-
};
|
|
1516
|
-
static search = (app_id,url,params) => {
|
|
1517
|
-
let action_url="content/search";
|
|
1518
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1519
|
-
};
|
|
1520
|
-
}
|
|
1521
1350
|
class Gallery_Url {
|
|
1522
1351
|
static get = (app_id,url,key,params) => {
|
|
1523
1352
|
let action_url="gallery/get/"+key;
|
|
1524
1353
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1525
1354
|
};
|
|
1526
|
-
static browse = (app_id,url,params) => {
|
|
1527
|
-
let action_url="gallery/browse";
|
|
1528
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1529
|
-
};
|
|
1530
|
-
static category = (app_id,url,category,params) => {
|
|
1531
|
-
let action_url="gallery/category/"+category;
|
|
1532
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1533
|
-
};
|
|
1534
1355
|
static search = (app_id,url,params) => {
|
|
1535
1356
|
let action_url="gallery/search";
|
|
1536
1357
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
@@ -1554,25 +1375,33 @@ class User_Url {
|
|
|
1554
1375
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1555
1376
|
};
|
|
1556
1377
|
}
|
|
1557
|
-
class
|
|
1558
|
-
static
|
|
1559
|
-
let action_url="
|
|
1378
|
+
class Item_Url {
|
|
1379
|
+
static post_cms = (app_id,url,data_type,id,params) => {
|
|
1380
|
+
let action_url = "item/post_cms/"+data_type+"/"+id;
|
|
1560
1381
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1561
1382
|
};
|
|
1562
|
-
static
|
|
1563
|
-
let action_url="
|
|
1383
|
+
static review = (app_id,url,parent_data_type,page_current,page_size,params) => {
|
|
1384
|
+
let action_url="item/review/"+parent_data_type+"/"+page_current+"/"+page_size;
|
|
1564
1385
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1565
1386
|
};
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
static post_cms = (app_id,url,data_type,id,params) => {
|
|
1569
|
-
let action_url = "item/post_cms/"+data_type+"/"+id;
|
|
1387
|
+
static post_review = (app_id,url,parent_data_type,parent_id,params) => {
|
|
1388
|
+
let action_url="item/post_review/"+parent_data_type+"/"+parent_id;
|
|
1570
1389
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1571
1390
|
};
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1391
|
+
static content = (app_id,url,key,params) => {
|
|
1392
|
+
let action_url="item/content/"+key;
|
|
1393
|
+
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1394
|
+
};
|
|
1395
|
+
static custom_field = (app_id,url,data_type,key,params) => {
|
|
1396
|
+
let action_url="item/custom_field/"+data_type+"/"+key;
|
|
1397
|
+
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1398
|
+
};
|
|
1399
|
+
static favorite = (app_id,url,parent_data_type,page_current,page_size,params) => {
|
|
1400
|
+
let action_url="item/favorite/"+parent_data_type+"/"+page_current+"/"+page_size;
|
|
1401
|
+
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1402
|
+
};
|
|
1403
|
+
static post_favorite = (app_id,url,parent_data_type,parent_id,params) => {
|
|
1404
|
+
let action_url="item/post_favorite"+parent_data_type+"/"+parent_id;
|
|
1576
1405
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1577
1406
|
};
|
|
1578
1407
|
}
|
|
@@ -1581,10 +1410,6 @@ class Category_Url {
|
|
|
1581
1410
|
let action_url="category/get/"+key;
|
|
1582
1411
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1583
1412
|
};
|
|
1584
|
-
static browse = (app_id,url,params) => {
|
|
1585
|
-
let action_url="category/browse";
|
|
1586
|
-
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1587
|
-
};
|
|
1588
1413
|
static search = (app_id,url,params) => {
|
|
1589
1414
|
let action_url="category/search";
|
|
1590
1415
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
@@ -1596,7 +1421,19 @@ class Page_Url {
|
|
|
1596
1421
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1597
1422
|
};
|
|
1598
1423
|
static home = (app_id,url,params) => {
|
|
1599
|
-
let action_url=
|
|
1424
|
+
let action_url="page/home";
|
|
1425
|
+
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1426
|
+
};
|
|
1427
|
+
static about = (app_id,url,params) => {
|
|
1428
|
+
let action_url="page/about";
|
|
1429
|
+
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1430
|
+
};
|
|
1431
|
+
static contact = (app_id,url,params) => {
|
|
1432
|
+
let action_url="page/contact";
|
|
1433
|
+
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1434
|
+
};
|
|
1435
|
+
static faq = (app_id,url,key,params) => {
|
|
1436
|
+
let action_url="page/faq/"+key;
|
|
1600
1437
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1601
1438
|
};
|
|
1602
1439
|
static post_value_field = (app_id,url,type,page_id,value_id,params) => {
|
|
@@ -2149,19 +1986,15 @@ class App_Logic {
|
|
|
2149
1986
|
module.exports = {
|
|
2150
1987
|
App_Logic,
|
|
2151
1988
|
Admin_Logic,
|
|
2152
|
-
Business_Url,
|
|
2153
|
-
Business_Logic,
|
|
2154
1989
|
Blank_Logic,
|
|
2155
|
-
Blank_Url,
|
|
2156
1990
|
Blog_Post_Logic,
|
|
2157
1991
|
Blog_Post_Url,
|
|
1992
|
+
Dashboard_Url,
|
|
2158
1993
|
Cart_Logic,
|
|
2159
1994
|
Cart_Url,
|
|
2160
1995
|
Category_Logic,
|
|
2161
1996
|
Category_Url,
|
|
2162
|
-
Content_Url,
|
|
2163
1997
|
Content_Logic,
|
|
2164
|
-
Custom_Field_Url,
|
|
2165
1998
|
CMS,
|
|
2166
1999
|
DataItem,
|
|
2167
2000
|
DataType,
|
|
@@ -2169,9 +2002,8 @@ module.exports = {
|
|
|
2169
2002
|
Field_Logic,
|
|
2170
2003
|
FieldType,
|
|
2171
2004
|
Faq_Logic,
|
|
2172
|
-
Faq_Url,
|
|
2173
2005
|
Favorite_Logic,
|
|
2174
|
-
|
|
2006
|
+
Gallery_Logic,
|
|
2175
2007
|
Gallery_Url,
|
|
2176
2008
|
Item_Logic,
|
|
2177
2009
|
Item_Url,
|
|
@@ -2183,7 +2015,6 @@ module.exports = {
|
|
|
2183
2015
|
PageType,
|
|
2184
2016
|
Product_Logic,
|
|
2185
2017
|
Review_Logic,
|
|
2186
|
-
Review_Url,
|
|
2187
2018
|
Order_Logic,
|
|
2188
2019
|
Order_Url,
|
|
2189
2020
|
Service_Logic,
|
|
@@ -2194,8 +2025,8 @@ module.exports = {
|
|
|
2194
2025
|
Storage,
|
|
2195
2026
|
Schedule,
|
|
2196
2027
|
Stock,
|
|
2197
|
-
TemplateType,
|
|
2198
2028
|
Template_Logic,
|
|
2029
|
+
TemplateType,
|
|
2199
2030
|
Url,
|
|
2200
2031
|
User_Url,
|
|
2201
2032
|
User_Logic,
|
package/package.json
CHANGED
package/test.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const path = require('path');
|
|
2
2
|
const series = require('async-series');
|
|
3
|
-
const {DataItem,DataType,Url,Obj,BiZ_Url,Cat,Stock,Schedule,Storage,Business,Product,Service,Event,Template,Page,Category,Review,Blog_Post,Faq_Logic,Category_Url,Blank_Url,Blank_Logic,Item_Logic,Service_Logic,Template_Logic,Page_Logic,Product_Logic,Event_Logic,Blog_Post_Logic,Content_Logic,Category_Logic,Team_Logic,Business_Logic,PageType,Sub_Item_Logic,Page_Url,Review_Logic,User_Logic,Field_Logic,Order_Logic,Cart_Logic,Faq_Url,App_Logic,FieldType,Product_Url} = require('./index');
|
|
3
|
+
const {DataItem,DataType,Url,Obj,BiZ_Url,Cat,Stock,Schedule,Storage,Business,Product,Service,Event,Template,Page,Category,Review,Blog_Post,Faq_Logic,Category_Url,Blank_Url,Blank_Logic,Item_Logic,Service_Logic,Template_Logic,Page_Logic,Product_Logic,Event_Logic,Blog_Post_Logic,Content_Logic,Category_Logic,Team_Logic,Business_Logic,PageType,Sub_Item_Logic,Page_Url,Review_Logic,User_Logic,Field_Logic,Order_Logic,Cart_Logic,Faq_Url,App_Logic,FieldType,Product_Url,Gallery_Logic} = require('./index');
|
|
4
4
|
const {Log,Num} = require('biz9-utility');
|
|
5
5
|
const {Scriptz}= require('biz9-scriptz');
|
|
6
6
|
|
|
@@ -31,15 +31,18 @@ describe("connect", () => {
|
|
|
31
31
|
series([
|
|
32
32
|
|
|
33
33
|
function(call) {
|
|
34
|
-
|
|
35
|
-
let
|
|
36
|
-
|
|
34
|
+
console.log('ITEM-START');
|
|
35
|
+
let gallery = Gallery_Logic.get_test('Gallery 1',{get_blank:true});
|
|
36
|
+
console.log(gallery);
|
|
37
|
+
console.log('ITEM-END');
|
|
38
|
+
//let page = Page_Logic.get_test();
|
|
39
|
+
//page[Page_Logic.get_page_value_field_title(FieldType.PAGE_VALUE_FIELD_TYPE_TEXT,1)] = 'apple';
|
|
37
40
|
//page[Page_Logic.get_page_value_field_title('list',1,1)] = 'cool';
|
|
38
41
|
//page[Page_Logic.get_page_value_field_title('list',1,2)] = 'apple';
|
|
39
42
|
//page[Page_Logic.get_page_value_field_title('list',1,3)] = 'sauce';
|
|
40
|
-
Log.w('page',page);
|
|
41
|
-
Log.w('text_1_value',Page_Logic.get_page_value_field_value(FieldType.PAGE_VALUE_FIELD_TYPE_TEXT,page,1));
|
|
42
|
-
//Log.w('list_1_value',Page_Logic.get_page_value_field_value(FieldType.
|
|
43
|
+
//Log.w('page',page);
|
|
44
|
+
//Log.w('text_1_value',Page_Logic.get_page_value_field_value(FieldType.PAGE_VALUE_FIELD_TYPE_TEXT,page,1));
|
|
45
|
+
//Log.w('list_1_value',Page_Logic.get_page_value_field_value(FieldType.PAGE_VALUE_FIELD_TYPE_LIST,page,1));
|
|
43
46
|
|
|
44
47
|
|
|
45
48
|
//console.log(Page_Logic.get_page_value_field_title('text',1));
|