ionic-vhframeworks 10.0.7 → 10.0.9

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.
@@ -744,7 +744,7 @@ export declare class VhAuth {
744
744
  signInWithEmailAndPassword_AutoWeb_Developer(email: string, password: string): Promise<unknown>;
745
745
  /**
746
746
  * @example:
747
- * this.vhAuth.onAuthStateChanged_AutoWeb()
747
+ * this.vhAuth.onAuthStateChanged_AutoWeb_Designer()
748
748
  .then((rsp)=>{
749
749
  if(rsp.vcode===0){
750
750
  //Designer
@@ -768,7 +768,34 @@ export declare class VhAuth {
768
768
  * vcode === 0: Designer logged in successfully
769
769
  * vcode === 10: Developer logged in successfully
770
770
  */
771
- onAuthStateChanged_AutoWeb(): Promise<unknown>;
771
+ onAuthStateChanged_AutoWeb_Designer(): Promise<unknown>;
772
+ /**
773
+ * @example:
774
+ * this.vhAuth.onAuthStateChanged_AutoWeb_Developer()
775
+ .then((rsp)=>{
776
+ if(rsp.vcode===0){
777
+ //Designer
778
+ this.vhQueryAutoWeb.syncCollections_Desktop()
779
+ .then(()=>{
780
+ do something.....
781
+ console.log('user', user);
782
+ })
783
+ }else if(rsp.vcode===10){
784
+ //Developer
785
+ this.vhQueryAutoWeb.syncCollections_Desktop()
786
+ .then(()=>{
787
+ do something.....
788
+ console.log('user', user);
789
+ })
790
+ }
791
+ },(error:any)=>{
792
+ console.log('error', error);
793
+ })
794
+ * @return Promise => rsp ={vcode, message, data(object)} / error
795
+ * vcode === 0: Designer logged in successfully
796
+ * vcode === 10: Developer logged in successfully
797
+ */
798
+ onAuthStateChanged_AutoWeb_Developer(): Promise<unknown>;
772
799
  signUpOwner_Sales365(email: string, password: string, phoneNumber: string, info: any): Promise<unknown> | null;
773
800
  /**
774
801
  * @example:
@@ -956,6 +983,30 @@ export declare class VhAuth {
956
983
  * @return: null
957
984
  */
958
985
  signOut(): Promise<any>;
986
+ /**
987
+ * @example:
988
+ * this.vhAuth.signOut_AutoWeb_Designer()
989
+ .then((res:any)=>{
990
+ console.log('res1', res);
991
+ },(error:any)=>{
992
+ console.log('error1', error);
993
+ })
994
+ * @notice : luôn luôn trả về null
995
+ * @return: null
996
+ */
997
+ signOut_AutoWeb_Designer(): Promise<any>;
998
+ /**
999
+ * @example:
1000
+ * this.vhAuth.signOut_AutoWeb_Developer()
1001
+ .then((res:any)=>{
1002
+ console.log('res1', res);
1003
+ },(error:any)=>{
1004
+ console.log('error1', error);
1005
+ })
1006
+ * @notice : luôn luôn trả về null
1007
+ * @return: null
1008
+ */
1009
+ signOut_AutoWeb_Developer(): Promise<any>;
959
1010
  /**
960
1011
  * @example:
961
1012
  * this.vhAuth.resetPasswordbyEmail()
@@ -20727,6 +20778,54 @@ export declare class VhDevAutoWeb {
20727
20778
  static ɵfac: i0.ɵɵFactoryDeclaration<VhDevAutoWeb, never>;
20728
20779
  static ɵprov: i0.ɵɵInjectableDeclaration<VhDevAutoWeb>;
20729
20780
  }
20781
+ export declare class VhEinvoice {
20782
+ private vhAlgorithm;
20783
+ private vhMGDB_auth;
20784
+ constructor(vhAlgorithm: VhAlgorithm, vhMGDB_auth: VhMGDB_auth);
20785
+ /**
20786
+ * Hàm đăng nhập vào M-invoice để lấy token
20787
+ * @example
20788
+ * this.vhEinvoice.signin_byMinvoice(taxcode, username, password)
20789
+ .then((data)=>{
20790
+ //-----------your code here-----------
20791
+ },(error:any)=>{
20792
+ console.log('error', error)
20793
+ })
20794
+ * @param taxcode
20795
+ * @param username
20796
+ * @param password
20797
+ * @returns Promise => obj
20798
+ * {"code": "00", "message": "Thành công", "ok": true, "token": "O87316arj5......."}
20799
+ * {"code": "99", "message": "Tên đăng nhập hoặc mật khẩu không đúng", "ok": false, "error": "Tên đăng nhập hoặc mật khẩu không đúng"}
20800
+ */
20801
+ signin_byMinvoice(taxcode: string, username: string, password: string): Promise<any>;
20802
+ /**
20803
+ * Hàm lấy về danh sách các ký tự hóa đơn đẵ đăng ký với thuế
20804
+ * @example
20805
+ * this.vhEinvoice.getTypeInvoiceSeries_byMinvoice(taxcode, token, Type)
20806
+ .then(()=>{
20807
+ //-----------your code here-----------
20808
+ },(error:any)=>{
20809
+ console.log('error', error)
20810
+ })
20811
+ * @param taxcode
20812
+ * @param token
20813
+ * @param Type
20814
+ * Ý nghĩa Type:
20815
+ * 1: Hóa đơn giá trị gia tăng
20816
+ * 2: Hóa đơn bán hàng
20817
+ * 5: Tem vé thẻ
20818
+ * 6: Phiếu xuất kho (Kiêm vận chuyển nội bộ, gửi bán đại lý)
20819
+ * @returns Promise => obj
20820
+ * {"code": "00", "message": “Thành công”, "ok": true, "data": [{"id": "3a08d649-2284-2577-7b7d-91a284f25eb3", "quanlykyhieu68_id": "6252b95a-b64e-4ccf-b76b-ac812ae1efc0", "khhdon": "6C23NYY", "value": "6C23NYY", "invoiceForm": "6", "invoiceYear": 23, "number": null, "orders": null, "invoiceTypeName": "Phiếu xuất kho kiêm vận chuyển nội bộ"}]
20821
+ * {"code": "3", "message": "Token hết hạn hoặc không đúng vui lòng kiểm tra lại!", "error": "Token hết hạn hoặc không đúng vui lòng kiểm tra lại!", "ok": false}
20822
+ */
20823
+ getTypeInvoiceSeries_byMinvoice(taxcode: string, token: string, Type?: number): Promise<any>;
20824
+ createBill_noSign_byMinvoice(taxcode: string, username: string, password: string): Promise<any>;
20825
+ createBill_Sign_byMinvoice(taxcode: string, username: string, password: string): void;
20826
+ static ɵfac: i0.ɵɵFactoryDeclaration<VhEinvoice, never>;
20827
+ static ɵprov: i0.ɵɵInjectableDeclaration<VhEinvoice>;
20828
+ }
20730
20829
  export declare class VhDesignAutoWeb {
20731
20830
  private vhAlgorithm;
20732
20831
  private vhAuth;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ionic-vhframeworks",
3
- "version": "10.0.7",
3
+ "version": "10.0.9",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^12.2.0",
6
6
  "@angular/core": "^12.2.0"