biz9-logic 4.8.270 → 4.8.273
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 +18 -15
- package/package.json +1 -1
package/biz9_config
CHANGED
package/index.js
CHANGED
|
@@ -218,7 +218,7 @@ class Page_Logic {
|
|
|
218
218
|
class Order_Logic {
|
|
219
219
|
static get_new = (cart) => {
|
|
220
220
|
let order = DataItem.get_new(DataType.ORDER,0,{
|
|
221
|
-
order_number:
|
|
221
|
+
order_number:FieldType.ORDER_NUMBER + Num.get_id(99999),
|
|
222
222
|
parent_data_type:cart.parent_data_type,
|
|
223
223
|
user_id:cart.user_id,
|
|
224
224
|
cart_number:cart.cart_number,
|
|
@@ -250,17 +250,19 @@ class Order_Logic {
|
|
|
250
250
|
});
|
|
251
251
|
return order;
|
|
252
252
|
};
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
253
|
+
static get_new_order_payment = (order_number,payment_method,payment_amount) => {
|
|
254
|
+
return DataItem.get_new(DataType.ORDER_PAYMENT,0,
|
|
255
|
+
{
|
|
256
|
+
order_number:order_number,
|
|
257
|
+
payment_method:payment_method,
|
|
258
|
+
payment_amount:payment_amount,
|
|
259
|
+
transaction_id:FieldType.TRANSACTION_ID + Num.get_id(99999)
|
|
260
|
+
});
|
|
259
261
|
};
|
|
260
262
|
}
|
|
261
263
|
class Cart_Logic {
|
|
262
264
|
static get_new = (parent_data_type) => {
|
|
263
|
-
return DataItem.get_new(DataType.CART,0,{cart_number:
|
|
265
|
+
return DataItem.get_new(DataType.CART,0,{cart_number:FieldType.CART_NUMBER + Num.get_id(99999),parent_data_type:parent_data_type,grand_total:0,cart_item_list:[]});
|
|
264
266
|
};
|
|
265
267
|
static get_new_cart_item = (parent_data_type,parent_id,cart_number,quanity) =>{
|
|
266
268
|
return DataItem.get_new(DataType.CART_ITEM,0,{parent_data_type:parent_data_type,parent_id:parent_id,cart_number:cart_number,quanity:quanity,cart_sub_item_list:[]});
|
|
@@ -268,9 +270,6 @@ class Cart_Logic {
|
|
|
268
270
|
static get_new_cart_sub_item = (parent_data_type,parent_id,cart_number,quanity) =>{
|
|
269
271
|
return DataItem.get_new(DataType.CART_SUB_ITEM,0,{parent_data_type:parent_data_type,parent_id:parent_id,cart_number:cart_number,quanity:quanity});
|
|
270
272
|
};
|
|
271
|
-
static get_new_cart_number = () => {
|
|
272
|
-
return FieldType.CART_NUMBER + Num.get_id(99999);
|
|
273
|
-
};
|
|
274
273
|
}
|
|
275
274
|
class Product_Logic {
|
|
276
275
|
static get_test = (title,option) =>{
|
|
@@ -814,10 +813,10 @@ class FieldType {
|
|
|
814
813
|
static PAYMENT_PLAN_TYPE_3="3 Payments";
|
|
815
814
|
static PAYMENT_PLAN_TYPE_4="4 Payments";
|
|
816
815
|
|
|
817
|
-
static
|
|
818
|
-
static
|
|
819
|
-
static
|
|
820
|
-
static
|
|
816
|
+
static PAYMENT_METHOD_STRIPE="Stripe";
|
|
817
|
+
static PAYMENT_METHOD_CASH="Cash";
|
|
818
|
+
static PAYMENT_METHOD_OTHER="Other";
|
|
819
|
+
static PAYMENT_METHOD_TEST="Test";
|
|
821
820
|
|
|
822
821
|
static APP_TYPE_MOBILE="Mobile";
|
|
823
822
|
static APP_TYPE_WEBSITE="Website";
|
|
@@ -1263,6 +1262,10 @@ class Item_Url {
|
|
|
1263
1262
|
let action_url="item/post_order";
|
|
1264
1263
|
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1265
1264
|
};
|
|
1265
|
+
static search_order = (app_id,url,params) => {
|
|
1266
|
+
let action_url="item/search_order";
|
|
1267
|
+
return get_cloud_url_main(app_id,url,action_url,params);
|
|
1268
|
+
};
|
|
1266
1269
|
static delete_order = (app_id,url,id,params) => {
|
|
1267
1270
|
let action_url="item/delete_order/"+id;
|
|
1268
1271
|
return get_cloud_url_main(app_id,url,action_url,params);
|