ionic-vhframeworks 9.8.2 → 9.8.4
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.
|
@@ -310,6 +310,41 @@ export declare class VhAlgorithm {
|
|
|
310
310
|
* @alias: chuỗi có dấu và các ký tự đặc biệt
|
|
311
311
|
*/
|
|
312
312
|
changeAlias_withCharacter(alias: any): any;
|
|
313
|
+
/**
|
|
314
|
+
* Hàm trả về mảng gồm các phần tử là chuỗi con liên tiếp có m, m+1, m+2,... ký tự thỏa điều kiện m>-4 và m<=n
|
|
315
|
+
* let keywords = this.vhAlgorithm.getSequentialSubstrings('+84909925354, 6);
|
|
316
|
+
*/
|
|
317
|
+
getSequentialSubstrings(str: string, m: number): string[];
|
|
318
|
+
/**
|
|
319
|
+
* Hàm trả về số đt mã đã bỏ đi mã quốc gia (nếu có)
|
|
320
|
+
* console.log(removeCountryCode("+84901234567", "+84")); // "0901234567"
|
|
321
|
+
* console.log(removeCountryCode("0084901234567", "+84")); // "0901234567"
|
|
322
|
+
* console.log(removeCountryCode("84901234567", "+84")); // "0901234567"
|
|
323
|
+
* console.log(removeCountryCode("0901234567", "+84")); // "0901234567" (không đổi)
|
|
324
|
+
* @example:
|
|
325
|
+
* let phone = this.vhAlgorithm.removeCountryCode(phoneNumber, countryCode)
|
|
326
|
+
*/
|
|
327
|
+
removeCountryCode(phoneNumber: string, countryCode: string): string;
|
|
328
|
+
/**
|
|
329
|
+
* Kiểm tra 1 chuỗi str bất kỳ với tất cả các ký tự trong chuỗi đều phải là số
|
|
330
|
+
* @example:
|
|
331
|
+
* let bool = this.vhAlgorithm.isNumericString('123345083')
|
|
332
|
+
* @param str
|
|
333
|
+
* @returns true/false
|
|
334
|
+
*/
|
|
335
|
+
isNumericString(str: string): boolean;
|
|
336
|
+
/**
|
|
337
|
+
* Chuẩn hóa chuỗi str, nếu có nhiều hơn 1 khoảng trống liên tiếp thì chỉ giữ lại 1 khoảng trống, bỏ cả khoảng trống đầu và cuối chuỗi
|
|
338
|
+
* @example:
|
|
339
|
+
* str = this.vhAlgorithm.normalizeSpaces(str)
|
|
340
|
+
* @param str
|
|
341
|
+
* @returns string
|
|
342
|
+
*/
|
|
343
|
+
normalizeSpaces(str: string): string;
|
|
344
|
+
/**
|
|
345
|
+
* Hàm bỏ tất cả các ký tự trống trong chuỗi
|
|
346
|
+
*/
|
|
347
|
+
removeAllSpaces(str: string): string;
|
|
313
348
|
/**
|
|
314
349
|
* Hàm này lấy về 1 unit của sản phẩm theo ratio truyền vào
|
|
315
350
|
* @example
|
|
@@ -3639,7 +3674,7 @@ export declare class VhQueryCafe {
|
|
|
3639
3674
|
* @return Promise => object ={}
|
|
3640
3675
|
* Luu ý: chỉ có 2 trường hợp, hoặc là thêm thành công, hoặc là báo lỗi error
|
|
3641
3676
|
*/
|
|
3642
|
-
addCustomer(data:
|
|
3677
|
+
addCustomer(data: any): Promise<unknown>;
|
|
3643
3678
|
/**
|
|
3644
3679
|
* @example:
|
|
3645
3680
|
* this.vhQueryCafe.addCustomers([{name:'Khách hàng 1', address: 'HCM'},{},...])
|
|
@@ -3663,7 +3698,7 @@ export declare class VhQueryCafe {
|
|
|
3663
3698
|
* @param data
|
|
3664
3699
|
* @return Promise => bool = true or false
|
|
3665
3700
|
*/
|
|
3666
|
-
updateCustomer(_id: string,
|
|
3701
|
+
updateCustomer(_id: string, value: any): Promise<unknown>;
|
|
3667
3702
|
/**
|
|
3668
3703
|
* @example:
|
|
3669
3704
|
* this.vhQueryCafe.deleteCustomer('5fb67fda87c0f21d484cbdf3')
|
|
@@ -3726,6 +3761,21 @@ export declare class VhQueryCafe {
|
|
|
3726
3761
|
* @return Object => obj = {} or null
|
|
3727
3762
|
*/
|
|
3728
3763
|
getlocalCustomerPoints(id_customer: any): any;
|
|
3764
|
+
/**
|
|
3765
|
+
* Hàm tìm kiếm tên chủ sở hữu và số điện thoại, nghĩa là nhập 1 chuỗi tên (2 từ trở lên) hoặc chuỗi số (6 ký tự trở lên) hàm sẽ
|
|
3766
|
+
* trả về những chủ sở hữu có tên hoặc số điện thoại tương ứng với keyword tìm kiếm
|
|
3767
|
+
* @example:
|
|
3768
|
+
* this.vhQuerySales.searchKeyword_NamePhone({'customers, '925354'})
|
|
3769
|
+
.then((rsp)=>{
|
|
3770
|
+
console.log('searchKeyword_NamePhone', rsp);
|
|
3771
|
+
},(error:any)=>{
|
|
3772
|
+
console.log('error', error);
|
|
3773
|
+
})
|
|
3774
|
+
* @param name_or_phone
|
|
3775
|
+
* @param countryCode
|
|
3776
|
+
* @returns Promise = > {vcode, msg, data(array)}
|
|
3777
|
+
*/
|
|
3778
|
+
searchKeyword_NamePhone(colname: string, name_or_phone: string, countryCode?: string): Promise<unknown>;
|
|
3729
3779
|
private publishObservableEventSuppliers;
|
|
3730
3780
|
private observableLocalSuppliers;
|
|
3731
3781
|
/**
|
|
@@ -3775,7 +3825,7 @@ export declare class VhQueryCafe {
|
|
|
3775
3825
|
* @return Promise => obj = {}
|
|
3776
3826
|
* Luu ý: chỉ có 2 trường hợp, hoặc là thêm thành công, hoặc là báo lỗi error
|
|
3777
3827
|
*/
|
|
3778
|
-
addSupplier(data:
|
|
3828
|
+
addSupplier(data: any): Promise<unknown>;
|
|
3779
3829
|
/**
|
|
3780
3830
|
* @example:
|
|
3781
3831
|
* this.vhQueryCafe.addSuppliers([{name:'Nhà cung cấp 1', address: 'HCM'},{},...])
|
|
@@ -3796,10 +3846,10 @@ export declare class VhQueryCafe {
|
|
|
3796
3846
|
console.log('updateSupplier', bool);
|
|
3797
3847
|
})
|
|
3798
3848
|
* @param id_supplier
|
|
3799
|
-
* @param
|
|
3849
|
+
* @param value
|
|
3800
3850
|
* @return Promise => bool = true or false
|
|
3801
3851
|
*/
|
|
3802
|
-
updateSupplier(id_supplier: string,
|
|
3852
|
+
updateSupplier(id_supplier: string, value: any): Promise<unknown>;
|
|
3803
3853
|
/**
|
|
3804
3854
|
* @example:
|
|
3805
3855
|
* this.vhQueryCafe.deleteSupplier('5fb67fda87c0f21d484cbdf3')
|
|
@@ -13543,7 +13593,19 @@ export declare class VhQueryAutoWeb {
|
|
|
13543
13593
|
console.log('error', error)
|
|
13544
13594
|
})
|
|
13545
13595
|
*/
|
|
13546
|
-
pipeDetailPage_byCtrl_V(
|
|
13596
|
+
pipeDetailPage_byCtrl_V(id_father_node: any): Promise<unknown>;
|
|
13597
|
+
/**
|
|
13598
|
+
* Hàm này chuyển node (object hoặc block) bất kỳ sang chứa mới (object, block hoặc page) có id là id_father_node
|
|
13599
|
+
* @example:
|
|
13600
|
+
* this.vhQueryAutoWeb.pipeDetailPage_byMove(object, '5fb67fda87c0f21d484cbdf3')
|
|
13601
|
+
.then((rsp)=>{
|
|
13602
|
+
console.log('pipeDetailPage_byMove', rsp);
|
|
13603
|
+
},(error:any)=>{
|
|
13604
|
+
console.log('error', error)
|
|
13605
|
+
})
|
|
13606
|
+
* @return: Promise
|
|
13607
|
+
*/
|
|
13608
|
+
pipeDetailPage_byMove(node: any, id_father_node: string): Promise<unknown>;
|
|
13547
13609
|
/**
|
|
13548
13610
|
* @example:
|
|
13549
13611
|
* let add_code = this.vhAlgorithm.ObjectId(10);
|
|
@@ -15822,13 +15884,13 @@ export declare class VhQueryAutoWeb {
|
|
|
15822
15884
|
console.log('error', error);
|
|
15823
15885
|
})
|
|
15824
15886
|
* @param id_customers
|
|
15825
|
-
* @param
|
|
15887
|
+
* @param value
|
|
15826
15888
|
* @return Promise object => rsp ={vcode, msg, data(undefined)} / error
|
|
15827
15889
|
* @notice : hàm này chỉ add được dữ liệu sau khi khách hàng hoặc nhân viên đã đăng nhập
|
|
15828
15890
|
* vcode == 0: success
|
|
15829
15891
|
* vcode == 11: 'not logged in
|
|
15830
15892
|
*/
|
|
15831
|
-
updateCustomer(id_customers: string,
|
|
15893
|
+
updateCustomer(id_customers: string, value: any): Promise<unknown>;
|
|
15832
15894
|
/**
|
|
15833
15895
|
* @example:
|
|
15834
15896
|
* this.vhQueryAutoWeb.deleteCustomer('5fb67fda87c0f21d484cbdf3')
|
|
@@ -21646,13 +21708,21 @@ export declare class VhDesignAutoWeb {
|
|
|
21646
21708
|
})
|
|
21647
21709
|
*/
|
|
21648
21710
|
pipeDetailPage_byCtrl_C(node: any): Promise<unknown>;
|
|
21649
|
-
|
|
21711
|
+
/**
|
|
21712
|
+
* this.vhDesignAutoWeb.pipeDetailPage_byCtrl_V('5fb67fda87c0f21d484cbdf3')
|
|
21713
|
+
.then((doc)=>{
|
|
21714
|
+
console.log('pipeDetailPage_byCtrl_V', doc);
|
|
21715
|
+
},(error:any)=>{
|
|
21716
|
+
console.log('error', error)
|
|
21717
|
+
})
|
|
21718
|
+
*/
|
|
21719
|
+
pipeDetailPage_byCtrl_V(id_father_node: any): Promise<unknown>;
|
|
21650
21720
|
/**
|
|
21651
21721
|
* vhDesignAutoWeb
|
|
21652
21722
|
* @param block
|
|
21653
21723
|
* @returns
|
|
21654
21724
|
*/
|
|
21655
|
-
pasteDetailBlock_toPage_byCtrl_V
|
|
21725
|
+
private pasteDetailBlock_toPage_byCtrl_V;
|
|
21656
21726
|
/**
|
|
21657
21727
|
* Hàm này trả về 1 object (có đủ thông tin object), trong mỗi object có trường objects (có đủ thông tin từng object)
|
|
21658
21728
|
* @example
|
|
@@ -21665,8 +21735,12 @@ export declare class VhDesignAutoWeb {
|
|
|
21665
21735
|
* @param id_object
|
|
21666
21736
|
* @return Promise => page = {}
|
|
21667
21737
|
*/
|
|
21668
|
-
pasteDetailObject_toBlock_byCtrl_V
|
|
21669
|
-
pasteDetailObject_toObject_byCtrl_V
|
|
21738
|
+
private pasteDetailObject_toBlock_byCtrl_V;
|
|
21739
|
+
private pasteDetailObject_toObject_byCtrl_V;
|
|
21740
|
+
pipeDetailPage_byMove(node: any, id_father_node: string): Promise<unknown>;
|
|
21741
|
+
private moveDetailBlock_toPage;
|
|
21742
|
+
private moveDetailObject_toBlock;
|
|
21743
|
+
private moveDetailObject_toObject;
|
|
21670
21744
|
private finished_Ctrl_ZY;
|
|
21671
21745
|
pipeDetailPage_byCtrl_Z(): Promise<unknown>;
|
|
21672
21746
|
pipeDetailPage_byCtrl_Y(): Promise<unknown>;
|
|
@@ -23664,7 +23738,7 @@ export declare class VhQuerySales {
|
|
|
23664
23738
|
* @param data
|
|
23665
23739
|
* @return Promise => bool = true or false
|
|
23666
23740
|
*/
|
|
23667
|
-
updateCustomer(_id: string,
|
|
23741
|
+
updateCustomer(_id: string, value: any): Promise<unknown>;
|
|
23668
23742
|
/**
|
|
23669
23743
|
* @example:
|
|
23670
23744
|
* this.vhQuerySales.deleteCustomer('5fb67fda87c0f21d484cbdf3')
|
|
@@ -23727,6 +23801,21 @@ export declare class VhQuerySales {
|
|
|
23727
23801
|
* @return Object => obj = {} or null
|
|
23728
23802
|
*/
|
|
23729
23803
|
getlocalCustomerPoints(id_customer: any): any;
|
|
23804
|
+
/**
|
|
23805
|
+
* Hàm tìm kiếm tên chủ sở hữu và số điện thoại, nghĩa là nhập 1 chuỗi tên (2 từ trở lên) hoặc chuỗi số (6 ký tự trở lên) hàm sẽ
|
|
23806
|
+
* trả về những chủ sở hữu có tên hoặc số điện thoại tương ứng với keyword tìm kiếm
|
|
23807
|
+
* @example:
|
|
23808
|
+
* this.vhQuerySales.searchKeyword_NamePhone({'customers, '925354'})
|
|
23809
|
+
.then((rsp)=>{
|
|
23810
|
+
console.log('searchKeyword_NamePhone', rsp);
|
|
23811
|
+
},(error:any)=>{
|
|
23812
|
+
console.log('error', error);
|
|
23813
|
+
})
|
|
23814
|
+
* @param name_or_phone
|
|
23815
|
+
* @param countryCode
|
|
23816
|
+
* @returns Promise = > {vcode, msg, data(array)}
|
|
23817
|
+
*/
|
|
23818
|
+
searchKeyword_NamePhone(colname: string, name_or_phone: string, countryCode?: string): Promise<unknown>;
|
|
23730
23819
|
private publishObservableEventSuppliers;
|
|
23731
23820
|
private observableLocalSuppliers;
|
|
23732
23821
|
/**
|
|
@@ -23797,10 +23886,10 @@ export declare class VhQuerySales {
|
|
|
23797
23886
|
console.log('updateSupplier', bool);
|
|
23798
23887
|
})
|
|
23799
23888
|
* @param id_supplier
|
|
23800
|
-
* @param
|
|
23889
|
+
* @param value
|
|
23801
23890
|
* @return Promise => bool = true or false
|
|
23802
23891
|
*/
|
|
23803
|
-
updateSupplier(id_supplier: string,
|
|
23892
|
+
updateSupplier(id_supplier: string, value: any): Promise<unknown>;
|
|
23804
23893
|
/**
|
|
23805
23894
|
* @example:
|
|
23806
23895
|
* this.vhQuerySales.deleteSupplier('5fb67fda87c0f21d484cbdf3')
|