@feedmepos/mf-common 0.0.7 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
package/dist/auth.d.ts CHANGED
@@ -9,7 +9,35 @@ export interface FeedMeUser {
9
9
  displayName?: string | null;
10
10
  phoneNumber?: string | null;
11
11
  }
12
+ export declare class FeedMeAuth {
13
+ static clientId: string;
14
+ static baseUrl: string;
15
+ private static _token;
16
+ private static _currentUser;
17
+ private static root;
18
+ private static authStateChangeCallbacks;
19
+ private static bgIframe;
20
+ static setBaseUrl(url: string): void;
21
+ private static startBackground;
22
+ static initialize(options: FeedMeAuthOptions): void;
23
+ static prompt(root?: HTMLElement): void;
24
+ static onAuthStateChanged(callback: (user: FeedMeUser | null, token: string | null) => void): void;
25
+ static signOut(): void;
26
+ static unmountPrompt(): void;
27
+ static get currentUser(): {
28
+ id: string;
29
+ email?: string | null | undefined;
30
+ photoURL?: string | null | undefined;
31
+ displayName?: string | null | undefined;
32
+ phoneNumber?: string | null | undefined;
33
+ } | null;
34
+ static get token(): string | null;
35
+ }
12
36
  export declare const useAuth: import("pinia").StoreDefinition<"auth", import("pinia")._UnwrapAll<Pick<{
37
+ config: (config: {
38
+ clientId: string;
39
+ customUrl?: string;
40
+ }) => void;
13
41
  currentUser: import("vue").Ref<{
14
42
  id: string;
15
43
  email?: string | null | undefined;
@@ -20,7 +48,12 @@ export declare const useAuth: import("pinia").StoreDefinition<"auth", import("pi
20
48
  token: import("vue").Ref<string | null>;
21
49
  signOut: () => void;
22
50
  prompt: (root?: HTMLElement) => void;
51
+ onAuthStateChanged: (callback: (user: FeedMeUser | null, token: string | null) => void) => void;
23
52
  }, "currentUser" | "token">>, Pick<{
53
+ config: (config: {
54
+ clientId: string;
55
+ customUrl?: string;
56
+ }) => void;
24
57
  currentUser: import("vue").Ref<{
25
58
  id: string;
26
59
  email?: string | null | undefined;
@@ -31,7 +64,12 @@ export declare const useAuth: import("pinia").StoreDefinition<"auth", import("pi
31
64
  token: import("vue").Ref<string | null>;
32
65
  signOut: () => void;
33
66
  prompt: (root?: HTMLElement) => void;
67
+ onAuthStateChanged: (callback: (user: FeedMeUser | null, token: string | null) => void) => void;
34
68
  }, never>, Pick<{
69
+ config: (config: {
70
+ clientId: string;
71
+ customUrl?: string;
72
+ }) => void;
35
73
  currentUser: import("vue").Ref<{
36
74
  id: string;
37
75
  email?: string | null | undefined;
@@ -42,4 +80,5 @@ export declare const useAuth: import("pinia").StoreDefinition<"auth", import("pi
42
80
  token: import("vue").Ref<string | null>;
43
81
  signOut: () => void;
44
82
  prompt: (root?: HTMLElement) => void;
45
- }, "signOut" | "prompt">>;
83
+ onAuthStateChanged: (callback: (user: FeedMeUser | null, token: string | null) => void) => void;
84
+ }, "config" | "signOut" | "prompt" | "onAuthStateChanged">>;
package/dist/store.d.ts CHANGED
@@ -10,24 +10,393 @@ export interface FmpUser {
10
10
  type FmNamespace = 'prod' | 'dev';
11
11
  export declare const useCore: import("pinia").StoreDefinition<"portal-core", import("pinia")._UnwrapAll<Pick<{
12
12
  namespace: import("vue").Ref<FmNamespace>;
13
- currentCountry: import("vue").Ref<"AF" | "AX" | "AL" | "DZ" | "AS" | "AD" | "AO" | "AI" | "AQ" | "AG" | "AR" | "AM" | "AW" | "AU" | "AT" | "AZ" | "BS" | "BH" | "BD" | "BB" | "BY" | "BE" | "BZ" | "BJ" | "BM" | "BT" | "BO" | "BQ" | "BA" | "BW" | "BV" | "BR" | "IO" | "BN" | "BG" | "BF" | "BI" | "KH" | "CM" | "CA" | "CV" | "KY" | "CF" | "TD" | "CL" | "CN" | "CX" | "CC" | "CO" | "KM" | "CG" | "CD" | "CK" | "CR" | "CI" | "HR" | "CU" | "CW" | "CY" | "CZ" | "DK" | "DJ" | "DM" | "DO" | "EC" | "EG" | "SV" | "GQ" | "ER" | "EE" | "ET" | "FK" | "FO" | "FJ" | "FI" | "FR" | "GF" | "PF" | "TF" | "GA" | "GM" | "GE" | "DE" | "GH" | "GI" | "GR" | "GL" | "GD" | "GP" | "GU" | "GT" | "GG" | "GN" | "GW" | "GY" | "HT" | "HM" | "VA" | "HN" | "HK" | "HU" | "IS" | "IN" | "ID" | "IR" | "IQ" | "IE" | "IM" | "IL" | "IT" | "JM" | "JP" | "JE" | "JO" | "KZ" | "KE" | "KI" | "KR" | "KP" | "KW" | "KG" | "LA" | "LV" | "LB" | "LS" | "LR" | "LY" | "LI" | "LT" | "LU" | "MO" | "MK" | "MG" | "MW" | "MY" | "MV" | "ML" | "MT" | "MH" | "MQ" | "MR" | "MU" | "YT" | "MX" | "FM" | "MD" | "MC" | "MN" | "ME" | "MS" | "MA" | "MZ" | "MM" | "NA" | "NR" | "NP" | "NL" | "NC" | "NZ" | "NI" | "NE" | "NG" | "NU" | "NF" | "MP" | "NO" | "OM" | "PK" | "PW" | "PS" | "PA" | "PG" | "PY" | "PE" | "PH" | "PN" | "PL" | "PT" | "PR" | "QA" | "RE" | "RO" | "RU" | "RW" | "BL" | "SH" | "KN" | "LC" | "MF" | "PM" | "VC" | "WS" | "SM" | "ST" | "SA" | "SN" | "RS" | "SC" | "SL" | "SG" | "SX" | "SK" | "SI" | "SB" | "SO" | "ZA" | "GS" | "SS" | "ES" | "LK" | "SD" | "SR" | "SJ" | "SZ" | "SE" | "CH" | "SY" | "TW" | "TJ" | "TZ" | "TH" | "TL" | "TG" | "TK" | "TO" | "TT" | "TN" | "TR" | "TM" | "TC" | "TV" | "UG" | "UA" | "AE" | "GB" | "US" | "UM" | "UY" | "UZ" | "VU" | "VE" | "VN" | "VG" | "VI" | "WF" | "EH" | "YE" | "ZM" | "ZW" | undefined>;
13
+ currentCountry: import("vue").Ref<"AF" | "AX" | "AL" | "DZ" | "AS" | "AD" | "AO" | "AI" | "AQ" | "AG" | "AR" | "AM" | "AW" | "AU" | "AT" | "AZ" | "BS" | "BH" | "BD" | "BB" | "BY" | "BE" | "BZ" | "BJ" | "BM" | "BT" | "BO" | "BQ" | "BA" | "BW" | "BV" | "BR" | "IO" | "BN" | "BG" | "BF" | "BI" | "KH" | "CM" | "CA" | "CV" | "KY" | "CF" | "TD" | "CL" | "CN" | "CX" | "CC" | "CO" | "KM" | "CG" | "CD" | "CK" | "CR" | "CI" | "HR" | "CU" | "CW" | "CY" | "CZ" | "DK" | "DJ" | "DM" | "DO" | "EC" | "EG" | "SV" | "GQ" | "ER" | "EE" | "ET" | "FK" | "FO" | "FJ" | "FI" | "FR" | "GF" | "PF" | "TF" | "GA" | "GM" | "GE" | "DE" | "GH" | "GI" | "GR" | "GL" | "GD" | "GP" | "GU" | "GT" | "GG" | "GN" | "GW" | "GY" | "HT" | "HM" | "VA" | "HN" | "HK" | "HU" | "IS" | "IN" | "ID" | "IR" | "IQ" | "IE" | "IM" | "IL" | "IT" | "JM" | "JP" | "JE" | "JO" | "KZ" | "KE" | "KI" | "KR" | "KP" | "KW" | "KG" | "LA" | "LV" | "LB" | "LS" | "LR" | "LY" | "LI" | "LT" | "LU" | "MO" | "MK" | "MG" | "MW" | "MY" | "MV" | "ML" | "MT" | "MH" | "MQ" | "MR" | "MU" | "YT" | "MX" | "FM" | "MD" | "MC" | "MN" | "ME" | "MS" | "MA" | "MZ" | "MM" | "NA" | "NR" | "NP" | "NL" | "NC" | "NZ" | "NI" | "NE" | "NG" | "NU" | "NF" | "MP" | "NO" | "OM" | "PK" | "PW" | "PS" | "PA" | "PG" | "PY" | "PE" | "PH" | "PN" | "PL" | "PT" | "PR" | "QA" | "RE" | "RO" | "RU" | "RW" | "BL" | "SH" | "KN" | "LC" | "MF" | "PM" | "VC" | "WS" | "SM" | "ST" | "SA" | "SN" | "RS" | "SC" | "SL" | "SG" | "SX" | "SK" | "SI" | "SB" | "SO" | "ZA" | "GS" | "SS" | "ES" | "LK" | "SD" | "SR" | "SJ" | "SZ" | "SE" | "CH" | "SY" | "TW" | "TJ" | "TZ" | "TH" | "TL" | "TG" | "TK" | "TO" | "TT" | "TN" | "TR" | "TM" | "TC" | "TV" | "UG" | "UA" | "AE" | "GB" | "US" | "UM" | "UY" | "UZ" | "VU" | "VE" | "VN" | "VG" | "VI" | "WF" | "EH" | "YE" | "ZM" | "ZW">;
14
+ businesses: import("vue").Ref<{
15
+ internal?: boolean | null | undefined;
16
+ expiredAt?: string | null | undefined;
17
+ url?: string | null | undefined;
18
+ agentId?: string | null | undefined;
19
+ pf_agent?: {
20
+ clickupId?: string | null | undefined;
21
+ members?: {
22
+ pf_user?: {
23
+ birthday?: {
24
+ toString: () => string;
25
+ toDateString: () => string;
26
+ toTimeString: () => string;
27
+ toLocaleString: {
28
+ (): string;
29
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
30
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
31
+ };
32
+ toLocaleDateString: {
33
+ (): string;
34
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
35
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
36
+ };
37
+ toLocaleTimeString: {
38
+ (): string;
39
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
40
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
41
+ };
42
+ valueOf: () => number;
43
+ getTime: () => number;
44
+ getFullYear: () => number;
45
+ getUTCFullYear: () => number;
46
+ getMonth: () => number;
47
+ getUTCMonth: () => number;
48
+ getDate: () => number;
49
+ getUTCDate: () => number;
50
+ getDay: () => number;
51
+ getUTCDay: () => number;
52
+ getHours: () => number;
53
+ getUTCHours: () => number;
54
+ getMinutes: () => number;
55
+ getUTCMinutes: () => number;
56
+ getSeconds: () => number;
57
+ getUTCSeconds: () => number;
58
+ getMilliseconds: () => number;
59
+ getUTCMilliseconds: () => number;
60
+ getTimezoneOffset: () => number;
61
+ setTime: (time: number) => number;
62
+ setMilliseconds: (ms: number) => number;
63
+ setUTCMilliseconds: (ms: number) => number;
64
+ setSeconds: (sec: number, ms?: number | undefined) => number;
65
+ setUTCSeconds: (sec: number, ms?: number | undefined) => number;
66
+ setMinutes: (min: number, sec?: number | undefined, ms?: number | undefined) => number;
67
+ setUTCMinutes: (min: number, sec?: number | undefined, ms?: number | undefined) => number;
68
+ setHours: (hours: number, min?: number | undefined, sec?: number | undefined, ms?: number | undefined) => number;
69
+ setUTCHours: (hours: number, min?: number | undefined, sec?: number | undefined, ms?: number | undefined) => number;
70
+ setDate: (date: number) => number;
71
+ setUTCDate: (date: number) => number;
72
+ setMonth: (month: number, date?: number | undefined) => number;
73
+ setUTCMonth: (month: number, date?: number | undefined) => number;
74
+ setFullYear: (year: number, month?: number | undefined, date?: number | undefined) => number;
75
+ setUTCFullYear: (year: number, month?: number | undefined, date?: number | undefined) => number;
76
+ toUTCString: () => string;
77
+ toISOString: () => string;
78
+ toJSON: (key?: any) => string;
79
+ [Symbol.toPrimitive]: {
80
+ (hint: "default"): string;
81
+ (hint: "string"): string;
82
+ (hint: "number"): number;
83
+ (hint: string): string | number;
84
+ };
85
+ } | null | undefined;
86
+ gender?: "MALE" | "FEMALE" | null | undefined;
87
+ addresses?: {
88
+ name: string;
89
+ address: string;
90
+ coordinates: number[];
91
+ }[] | null | undefined;
92
+ email?: string | null | undefined;
93
+ photoURL?: string | null | undefined;
94
+ displayName?: string | null | undefined;
95
+ phoneNumber?: string | null | undefined;
96
+ imported?: {
97
+ source: "FEEDME" | "CITY_POS" | "STOREHUB" | "KERUYUn" | "QISOFT" | "WECHAT" | "TEABAR" | "NULL_MEMBER" | "UMAI_POS" | "QASHIER" | "XILNET" | "GENIUSPOS" | "YHOFOODIE";
98
+ raw: Record<string, any>;
99
+ } | null | undefined;
100
+ _id: string;
101
+ } | null | undefined;
102
+ userId: string;
103
+ role: "ADMIN";
104
+ }[] | null | undefined;
105
+ _id: string;
106
+ name: string;
107
+ code: string;
108
+ isReseller: boolean;
109
+ } | null | undefined;
110
+ thumbnail?: string | null | undefined;
111
+ billingInfos?: {
112
+ _id?: string | undefined;
113
+ name: string;
114
+ email: string;
115
+ address: {
116
+ coordinates?: number[] | undefined;
117
+ line2?: string | undefined;
118
+ line1: string;
119
+ state: string;
120
+ city: string;
121
+ postcode: string;
122
+ country: string;
123
+ };
124
+ companyName: string;
125
+ contact: string;
126
+ }[] | null | undefined;
127
+ _id: string;
128
+ ownerId: string;
129
+ name: string;
130
+ restaurantQuota: number;
131
+ warehouseQuota: number;
132
+ menuVersion: "v2" | "v3" | "v4";
133
+ }[]>;
14
134
  currentBusiness: import("vue").Ref<FmpBusiness | undefined>;
135
+ currentApp: import("vue").Ref<string>;
15
136
  setNamespace: (ns: FmNamespace) => void;
16
137
  changeCountry: (country: F_COUNTRY) => void;
17
- changeBusiness: (business: FmpBusiness) => void;
18
- }, "namespace" | "currentCountry" | "currentBusiness">>, Pick<{
138
+ getBusinesses: () => Promise<void>;
139
+ changeBusiness: (business: FmpBusiness | undefined) => void;
140
+ setCurrentApp: (app: string) => void;
141
+ }, "namespace" | "currentCountry" | "businesses" | "currentBusiness" | "currentApp">>, Pick<{
19
142
  namespace: import("vue").Ref<FmNamespace>;
20
- currentCountry: import("vue").Ref<"AF" | "AX" | "AL" | "DZ" | "AS" | "AD" | "AO" | "AI" | "AQ" | "AG" | "AR" | "AM" | "AW" | "AU" | "AT" | "AZ" | "BS" | "BH" | "BD" | "BB" | "BY" | "BE" | "BZ" | "BJ" | "BM" | "BT" | "BO" | "BQ" | "BA" | "BW" | "BV" | "BR" | "IO" | "BN" | "BG" | "BF" | "BI" | "KH" | "CM" | "CA" | "CV" | "KY" | "CF" | "TD" | "CL" | "CN" | "CX" | "CC" | "CO" | "KM" | "CG" | "CD" | "CK" | "CR" | "CI" | "HR" | "CU" | "CW" | "CY" | "CZ" | "DK" | "DJ" | "DM" | "DO" | "EC" | "EG" | "SV" | "GQ" | "ER" | "EE" | "ET" | "FK" | "FO" | "FJ" | "FI" | "FR" | "GF" | "PF" | "TF" | "GA" | "GM" | "GE" | "DE" | "GH" | "GI" | "GR" | "GL" | "GD" | "GP" | "GU" | "GT" | "GG" | "GN" | "GW" | "GY" | "HT" | "HM" | "VA" | "HN" | "HK" | "HU" | "IS" | "IN" | "ID" | "IR" | "IQ" | "IE" | "IM" | "IL" | "IT" | "JM" | "JP" | "JE" | "JO" | "KZ" | "KE" | "KI" | "KR" | "KP" | "KW" | "KG" | "LA" | "LV" | "LB" | "LS" | "LR" | "LY" | "LI" | "LT" | "LU" | "MO" | "MK" | "MG" | "MW" | "MY" | "MV" | "ML" | "MT" | "MH" | "MQ" | "MR" | "MU" | "YT" | "MX" | "FM" | "MD" | "MC" | "MN" | "ME" | "MS" | "MA" | "MZ" | "MM" | "NA" | "NR" | "NP" | "NL" | "NC" | "NZ" | "NI" | "NE" | "NG" | "NU" | "NF" | "MP" | "NO" | "OM" | "PK" | "PW" | "PS" | "PA" | "PG" | "PY" | "PE" | "PH" | "PN" | "PL" | "PT" | "PR" | "QA" | "RE" | "RO" | "RU" | "RW" | "BL" | "SH" | "KN" | "LC" | "MF" | "PM" | "VC" | "WS" | "SM" | "ST" | "SA" | "SN" | "RS" | "SC" | "SL" | "SG" | "SX" | "SK" | "SI" | "SB" | "SO" | "ZA" | "GS" | "SS" | "ES" | "LK" | "SD" | "SR" | "SJ" | "SZ" | "SE" | "CH" | "SY" | "TW" | "TJ" | "TZ" | "TH" | "TL" | "TG" | "TK" | "TO" | "TT" | "TN" | "TR" | "TM" | "TC" | "TV" | "UG" | "UA" | "AE" | "GB" | "US" | "UM" | "UY" | "UZ" | "VU" | "VE" | "VN" | "VG" | "VI" | "WF" | "EH" | "YE" | "ZM" | "ZW" | undefined>;
143
+ currentCountry: import("vue").Ref<"AF" | "AX" | "AL" | "DZ" | "AS" | "AD" | "AO" | "AI" | "AQ" | "AG" | "AR" | "AM" | "AW" | "AU" | "AT" | "AZ" | "BS" | "BH" | "BD" | "BB" | "BY" | "BE" | "BZ" | "BJ" | "BM" | "BT" | "BO" | "BQ" | "BA" | "BW" | "BV" | "BR" | "IO" | "BN" | "BG" | "BF" | "BI" | "KH" | "CM" | "CA" | "CV" | "KY" | "CF" | "TD" | "CL" | "CN" | "CX" | "CC" | "CO" | "KM" | "CG" | "CD" | "CK" | "CR" | "CI" | "HR" | "CU" | "CW" | "CY" | "CZ" | "DK" | "DJ" | "DM" | "DO" | "EC" | "EG" | "SV" | "GQ" | "ER" | "EE" | "ET" | "FK" | "FO" | "FJ" | "FI" | "FR" | "GF" | "PF" | "TF" | "GA" | "GM" | "GE" | "DE" | "GH" | "GI" | "GR" | "GL" | "GD" | "GP" | "GU" | "GT" | "GG" | "GN" | "GW" | "GY" | "HT" | "HM" | "VA" | "HN" | "HK" | "HU" | "IS" | "IN" | "ID" | "IR" | "IQ" | "IE" | "IM" | "IL" | "IT" | "JM" | "JP" | "JE" | "JO" | "KZ" | "KE" | "KI" | "KR" | "KP" | "KW" | "KG" | "LA" | "LV" | "LB" | "LS" | "LR" | "LY" | "LI" | "LT" | "LU" | "MO" | "MK" | "MG" | "MW" | "MY" | "MV" | "ML" | "MT" | "MH" | "MQ" | "MR" | "MU" | "YT" | "MX" | "FM" | "MD" | "MC" | "MN" | "ME" | "MS" | "MA" | "MZ" | "MM" | "NA" | "NR" | "NP" | "NL" | "NC" | "NZ" | "NI" | "NE" | "NG" | "NU" | "NF" | "MP" | "NO" | "OM" | "PK" | "PW" | "PS" | "PA" | "PG" | "PY" | "PE" | "PH" | "PN" | "PL" | "PT" | "PR" | "QA" | "RE" | "RO" | "RU" | "RW" | "BL" | "SH" | "KN" | "LC" | "MF" | "PM" | "VC" | "WS" | "SM" | "ST" | "SA" | "SN" | "RS" | "SC" | "SL" | "SG" | "SX" | "SK" | "SI" | "SB" | "SO" | "ZA" | "GS" | "SS" | "ES" | "LK" | "SD" | "SR" | "SJ" | "SZ" | "SE" | "CH" | "SY" | "TW" | "TJ" | "TZ" | "TH" | "TL" | "TG" | "TK" | "TO" | "TT" | "TN" | "TR" | "TM" | "TC" | "TV" | "UG" | "UA" | "AE" | "GB" | "US" | "UM" | "UY" | "UZ" | "VU" | "VE" | "VN" | "VG" | "VI" | "WF" | "EH" | "YE" | "ZM" | "ZW">;
144
+ businesses: import("vue").Ref<{
145
+ internal?: boolean | null | undefined;
146
+ expiredAt?: string | null | undefined;
147
+ url?: string | null | undefined;
148
+ agentId?: string | null | undefined;
149
+ pf_agent?: {
150
+ clickupId?: string | null | undefined;
151
+ members?: {
152
+ pf_user?: {
153
+ birthday?: {
154
+ toString: () => string;
155
+ toDateString: () => string;
156
+ toTimeString: () => string;
157
+ toLocaleString: {
158
+ (): string;
159
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
160
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
161
+ };
162
+ toLocaleDateString: {
163
+ (): string;
164
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
165
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
166
+ };
167
+ toLocaleTimeString: {
168
+ (): string;
169
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
170
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
171
+ };
172
+ valueOf: () => number;
173
+ getTime: () => number;
174
+ getFullYear: () => number;
175
+ getUTCFullYear: () => number;
176
+ getMonth: () => number;
177
+ getUTCMonth: () => number;
178
+ getDate: () => number;
179
+ getUTCDate: () => number;
180
+ getDay: () => number;
181
+ getUTCDay: () => number;
182
+ getHours: () => number;
183
+ getUTCHours: () => number;
184
+ getMinutes: () => number;
185
+ getUTCMinutes: () => number;
186
+ getSeconds: () => number;
187
+ getUTCSeconds: () => number;
188
+ getMilliseconds: () => number;
189
+ getUTCMilliseconds: () => number;
190
+ getTimezoneOffset: () => number;
191
+ setTime: (time: number) => number;
192
+ setMilliseconds: (ms: number) => number;
193
+ setUTCMilliseconds: (ms: number) => number;
194
+ setSeconds: (sec: number, ms?: number | undefined) => number;
195
+ setUTCSeconds: (sec: number, ms?: number | undefined) => number;
196
+ setMinutes: (min: number, sec?: number | undefined, ms?: number | undefined) => number;
197
+ setUTCMinutes: (min: number, sec?: number | undefined, ms?: number | undefined) => number;
198
+ setHours: (hours: number, min?: number | undefined, sec?: number | undefined, ms?: number | undefined) => number;
199
+ setUTCHours: (hours: number, min?: number | undefined, sec?: number | undefined, ms?: number | undefined) => number;
200
+ setDate: (date: number) => number;
201
+ setUTCDate: (date: number) => number;
202
+ setMonth: (month: number, date?: number | undefined) => number;
203
+ setUTCMonth: (month: number, date?: number | undefined) => number;
204
+ setFullYear: (year: number, month?: number | undefined, date?: number | undefined) => number;
205
+ setUTCFullYear: (year: number, month?: number | undefined, date?: number | undefined) => number;
206
+ toUTCString: () => string;
207
+ toISOString: () => string;
208
+ toJSON: (key?: any) => string;
209
+ [Symbol.toPrimitive]: {
210
+ (hint: "default"): string;
211
+ (hint: "string"): string;
212
+ (hint: "number"): number;
213
+ (hint: string): string | number;
214
+ };
215
+ } | null | undefined;
216
+ gender?: "MALE" | "FEMALE" | null | undefined;
217
+ addresses?: {
218
+ name: string;
219
+ address: string;
220
+ coordinates: number[];
221
+ }[] | null | undefined;
222
+ email?: string | null | undefined;
223
+ photoURL?: string | null | undefined;
224
+ displayName?: string | null | undefined;
225
+ phoneNumber?: string | null | undefined;
226
+ imported?: {
227
+ source: "FEEDME" | "CITY_POS" | "STOREHUB" | "KERUYUn" | "QISOFT" | "WECHAT" | "TEABAR" | "NULL_MEMBER" | "UMAI_POS" | "QASHIER" | "XILNET" | "GENIUSPOS" | "YHOFOODIE";
228
+ raw: Record<string, any>;
229
+ } | null | undefined;
230
+ _id: string;
231
+ } | null | undefined;
232
+ userId: string;
233
+ role: "ADMIN";
234
+ }[] | null | undefined;
235
+ _id: string;
236
+ name: string;
237
+ code: string;
238
+ isReseller: boolean;
239
+ } | null | undefined;
240
+ thumbnail?: string | null | undefined;
241
+ billingInfos?: {
242
+ _id?: string | undefined;
243
+ name: string;
244
+ email: string;
245
+ address: {
246
+ coordinates?: number[] | undefined;
247
+ line2?: string | undefined;
248
+ line1: string;
249
+ state: string;
250
+ city: string;
251
+ postcode: string;
252
+ country: string;
253
+ };
254
+ companyName: string;
255
+ contact: string;
256
+ }[] | null | undefined;
257
+ _id: string;
258
+ ownerId: string;
259
+ name: string;
260
+ restaurantQuota: number;
261
+ warehouseQuota: number;
262
+ menuVersion: "v2" | "v3" | "v4";
263
+ }[]>;
21
264
  currentBusiness: import("vue").Ref<FmpBusiness | undefined>;
265
+ currentApp: import("vue").Ref<string>;
22
266
  setNamespace: (ns: FmNamespace) => void;
23
267
  changeCountry: (country: F_COUNTRY) => void;
24
- changeBusiness: (business: FmpBusiness) => void;
268
+ getBusinesses: () => Promise<void>;
269
+ changeBusiness: (business: FmpBusiness | undefined) => void;
270
+ setCurrentApp: (app: string) => void;
25
271
  }, never>, Pick<{
26
272
  namespace: import("vue").Ref<FmNamespace>;
27
- currentCountry: import("vue").Ref<"AF" | "AX" | "AL" | "DZ" | "AS" | "AD" | "AO" | "AI" | "AQ" | "AG" | "AR" | "AM" | "AW" | "AU" | "AT" | "AZ" | "BS" | "BH" | "BD" | "BB" | "BY" | "BE" | "BZ" | "BJ" | "BM" | "BT" | "BO" | "BQ" | "BA" | "BW" | "BV" | "BR" | "IO" | "BN" | "BG" | "BF" | "BI" | "KH" | "CM" | "CA" | "CV" | "KY" | "CF" | "TD" | "CL" | "CN" | "CX" | "CC" | "CO" | "KM" | "CG" | "CD" | "CK" | "CR" | "CI" | "HR" | "CU" | "CW" | "CY" | "CZ" | "DK" | "DJ" | "DM" | "DO" | "EC" | "EG" | "SV" | "GQ" | "ER" | "EE" | "ET" | "FK" | "FO" | "FJ" | "FI" | "FR" | "GF" | "PF" | "TF" | "GA" | "GM" | "GE" | "DE" | "GH" | "GI" | "GR" | "GL" | "GD" | "GP" | "GU" | "GT" | "GG" | "GN" | "GW" | "GY" | "HT" | "HM" | "VA" | "HN" | "HK" | "HU" | "IS" | "IN" | "ID" | "IR" | "IQ" | "IE" | "IM" | "IL" | "IT" | "JM" | "JP" | "JE" | "JO" | "KZ" | "KE" | "KI" | "KR" | "KP" | "KW" | "KG" | "LA" | "LV" | "LB" | "LS" | "LR" | "LY" | "LI" | "LT" | "LU" | "MO" | "MK" | "MG" | "MW" | "MY" | "MV" | "ML" | "MT" | "MH" | "MQ" | "MR" | "MU" | "YT" | "MX" | "FM" | "MD" | "MC" | "MN" | "ME" | "MS" | "MA" | "MZ" | "MM" | "NA" | "NR" | "NP" | "NL" | "NC" | "NZ" | "NI" | "NE" | "NG" | "NU" | "NF" | "MP" | "NO" | "OM" | "PK" | "PW" | "PS" | "PA" | "PG" | "PY" | "PE" | "PH" | "PN" | "PL" | "PT" | "PR" | "QA" | "RE" | "RO" | "RU" | "RW" | "BL" | "SH" | "KN" | "LC" | "MF" | "PM" | "VC" | "WS" | "SM" | "ST" | "SA" | "SN" | "RS" | "SC" | "SL" | "SG" | "SX" | "SK" | "SI" | "SB" | "SO" | "ZA" | "GS" | "SS" | "ES" | "LK" | "SD" | "SR" | "SJ" | "SZ" | "SE" | "CH" | "SY" | "TW" | "TJ" | "TZ" | "TH" | "TL" | "TG" | "TK" | "TO" | "TT" | "TN" | "TR" | "TM" | "TC" | "TV" | "UG" | "UA" | "AE" | "GB" | "US" | "UM" | "UY" | "UZ" | "VU" | "VE" | "VN" | "VG" | "VI" | "WF" | "EH" | "YE" | "ZM" | "ZW" | undefined>;
273
+ currentCountry: import("vue").Ref<"AF" | "AX" | "AL" | "DZ" | "AS" | "AD" | "AO" | "AI" | "AQ" | "AG" | "AR" | "AM" | "AW" | "AU" | "AT" | "AZ" | "BS" | "BH" | "BD" | "BB" | "BY" | "BE" | "BZ" | "BJ" | "BM" | "BT" | "BO" | "BQ" | "BA" | "BW" | "BV" | "BR" | "IO" | "BN" | "BG" | "BF" | "BI" | "KH" | "CM" | "CA" | "CV" | "KY" | "CF" | "TD" | "CL" | "CN" | "CX" | "CC" | "CO" | "KM" | "CG" | "CD" | "CK" | "CR" | "CI" | "HR" | "CU" | "CW" | "CY" | "CZ" | "DK" | "DJ" | "DM" | "DO" | "EC" | "EG" | "SV" | "GQ" | "ER" | "EE" | "ET" | "FK" | "FO" | "FJ" | "FI" | "FR" | "GF" | "PF" | "TF" | "GA" | "GM" | "GE" | "DE" | "GH" | "GI" | "GR" | "GL" | "GD" | "GP" | "GU" | "GT" | "GG" | "GN" | "GW" | "GY" | "HT" | "HM" | "VA" | "HN" | "HK" | "HU" | "IS" | "IN" | "ID" | "IR" | "IQ" | "IE" | "IM" | "IL" | "IT" | "JM" | "JP" | "JE" | "JO" | "KZ" | "KE" | "KI" | "KR" | "KP" | "KW" | "KG" | "LA" | "LV" | "LB" | "LS" | "LR" | "LY" | "LI" | "LT" | "LU" | "MO" | "MK" | "MG" | "MW" | "MY" | "MV" | "ML" | "MT" | "MH" | "MQ" | "MR" | "MU" | "YT" | "MX" | "FM" | "MD" | "MC" | "MN" | "ME" | "MS" | "MA" | "MZ" | "MM" | "NA" | "NR" | "NP" | "NL" | "NC" | "NZ" | "NI" | "NE" | "NG" | "NU" | "NF" | "MP" | "NO" | "OM" | "PK" | "PW" | "PS" | "PA" | "PG" | "PY" | "PE" | "PH" | "PN" | "PL" | "PT" | "PR" | "QA" | "RE" | "RO" | "RU" | "RW" | "BL" | "SH" | "KN" | "LC" | "MF" | "PM" | "VC" | "WS" | "SM" | "ST" | "SA" | "SN" | "RS" | "SC" | "SL" | "SG" | "SX" | "SK" | "SI" | "SB" | "SO" | "ZA" | "GS" | "SS" | "ES" | "LK" | "SD" | "SR" | "SJ" | "SZ" | "SE" | "CH" | "SY" | "TW" | "TJ" | "TZ" | "TH" | "TL" | "TG" | "TK" | "TO" | "TT" | "TN" | "TR" | "TM" | "TC" | "TV" | "UG" | "UA" | "AE" | "GB" | "US" | "UM" | "UY" | "UZ" | "VU" | "VE" | "VN" | "VG" | "VI" | "WF" | "EH" | "YE" | "ZM" | "ZW">;
274
+ businesses: import("vue").Ref<{
275
+ internal?: boolean | null | undefined;
276
+ expiredAt?: string | null | undefined;
277
+ url?: string | null | undefined;
278
+ agentId?: string | null | undefined;
279
+ pf_agent?: {
280
+ clickupId?: string | null | undefined;
281
+ members?: {
282
+ pf_user?: {
283
+ birthday?: {
284
+ toString: () => string;
285
+ toDateString: () => string;
286
+ toTimeString: () => string;
287
+ toLocaleString: {
288
+ (): string;
289
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
290
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
291
+ };
292
+ toLocaleDateString: {
293
+ (): string;
294
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
295
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
296
+ };
297
+ toLocaleTimeString: {
298
+ (): string;
299
+ (locales?: string | string[] | undefined, options?: Intl.DateTimeFormatOptions | undefined): string;
300
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions | undefined): string;
301
+ };
302
+ valueOf: () => number;
303
+ getTime: () => number;
304
+ getFullYear: () => number;
305
+ getUTCFullYear: () => number;
306
+ getMonth: () => number;
307
+ getUTCMonth: () => number;
308
+ getDate: () => number;
309
+ getUTCDate: () => number;
310
+ getDay: () => number;
311
+ getUTCDay: () => number;
312
+ getHours: () => number;
313
+ getUTCHours: () => number;
314
+ getMinutes: () => number;
315
+ getUTCMinutes: () => number;
316
+ getSeconds: () => number;
317
+ getUTCSeconds: () => number;
318
+ getMilliseconds: () => number;
319
+ getUTCMilliseconds: () => number;
320
+ getTimezoneOffset: () => number;
321
+ setTime: (time: number) => number;
322
+ setMilliseconds: (ms: number) => number;
323
+ setUTCMilliseconds: (ms: number) => number;
324
+ setSeconds: (sec: number, ms?: number | undefined) => number;
325
+ setUTCSeconds: (sec: number, ms?: number | undefined) => number;
326
+ setMinutes: (min: number, sec?: number | undefined, ms?: number | undefined) => number;
327
+ setUTCMinutes: (min: number, sec?: number | undefined, ms?: number | undefined) => number;
328
+ setHours: (hours: number, min?: number | undefined, sec?: number | undefined, ms?: number | undefined) => number;
329
+ setUTCHours: (hours: number, min?: number | undefined, sec?: number | undefined, ms?: number | undefined) => number;
330
+ setDate: (date: number) => number;
331
+ setUTCDate: (date: number) => number;
332
+ setMonth: (month: number, date?: number | undefined) => number;
333
+ setUTCMonth: (month: number, date?: number | undefined) => number;
334
+ setFullYear: (year: number, month?: number | undefined, date?: number | undefined) => number;
335
+ setUTCFullYear: (year: number, month?: number | undefined, date?: number | undefined) => number;
336
+ toUTCString: () => string;
337
+ toISOString: () => string;
338
+ toJSON: (key?: any) => string;
339
+ [Symbol.toPrimitive]: {
340
+ (hint: "default"): string;
341
+ (hint: "string"): string;
342
+ (hint: "number"): number;
343
+ (hint: string): string | number;
344
+ };
345
+ } | null | undefined;
346
+ gender?: "MALE" | "FEMALE" | null | undefined;
347
+ addresses?: {
348
+ name: string;
349
+ address: string;
350
+ coordinates: number[];
351
+ }[] | null | undefined;
352
+ email?: string | null | undefined;
353
+ photoURL?: string | null | undefined;
354
+ displayName?: string | null | undefined;
355
+ phoneNumber?: string | null | undefined;
356
+ imported?: {
357
+ source: "FEEDME" | "CITY_POS" | "STOREHUB" | "KERUYUn" | "QISOFT" | "WECHAT" | "TEABAR" | "NULL_MEMBER" | "UMAI_POS" | "QASHIER" | "XILNET" | "GENIUSPOS" | "YHOFOODIE";
358
+ raw: Record<string, any>;
359
+ } | null | undefined;
360
+ _id: string;
361
+ } | null | undefined;
362
+ userId: string;
363
+ role: "ADMIN";
364
+ }[] | null | undefined;
365
+ _id: string;
366
+ name: string;
367
+ code: string;
368
+ isReseller: boolean;
369
+ } | null | undefined;
370
+ thumbnail?: string | null | undefined;
371
+ billingInfos?: {
372
+ _id?: string | undefined;
373
+ name: string;
374
+ email: string;
375
+ address: {
376
+ coordinates?: number[] | undefined;
377
+ line2?: string | undefined;
378
+ line1: string;
379
+ state: string;
380
+ city: string;
381
+ postcode: string;
382
+ country: string;
383
+ };
384
+ companyName: string;
385
+ contact: string;
386
+ }[] | null | undefined;
387
+ _id: string;
388
+ ownerId: string;
389
+ name: string;
390
+ restaurantQuota: number;
391
+ warehouseQuota: number;
392
+ menuVersion: "v2" | "v3" | "v4";
393
+ }[]>;
28
394
  currentBusiness: import("vue").Ref<FmpBusiness | undefined>;
395
+ currentApp: import("vue").Ref<string>;
29
396
  setNamespace: (ns: FmNamespace) => void;
30
397
  changeCountry: (country: F_COUNTRY) => void;
31
- changeBusiness: (business: FmpBusiness) => void;
32
- }, "setNamespace" | "changeCountry" | "changeBusiness">>;
398
+ getBusinesses: () => Promise<void>;
399
+ changeBusiness: (business: FmpBusiness | undefined) => void;
400
+ setCurrentApp: (app: string) => void;
401
+ }, "setNamespace" | "changeCountry" | "getBusinesses" | "changeBusiness" | "setCurrentApp">>;
33
402
  export {};
package/dist/style.css ADDED
@@ -0,0 +1 @@
1
+ .user-info-icon[data-v-9d3da917]{height:32px;min-height:32px;min-width:32px;width:32px}