@xuda.io/account_module 1.2.1304 → 1.2.1306
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/index.mjs +7 -5
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -2563,6 +2563,7 @@ export const get_pending_share_profile_in = async function (uid, _id) {
|
|
|
2563
2563
|
|
|
2564
2564
|
export const get_account_profile_info = async function (uid, contact_profile_doc, _id) {
|
|
2565
2565
|
const ai_module = await import(`${module_path}/ai_module/index.mjs`);
|
|
2566
|
+
const app_id = await get_account_default_project_id(uid);
|
|
2566
2567
|
let doc = contact_profile_doc;
|
|
2567
2568
|
if (_id) {
|
|
2568
2569
|
doc = await db_module.get_couch_doc_native('xuda_accounts', _id);
|
|
@@ -2650,9 +2651,10 @@ export const get_account_profile_info = async function (uid, contact_profile_doc
|
|
|
2650
2651
|
};
|
|
2651
2652
|
|
|
2652
2653
|
const get_user_account_profiles = async () => {
|
|
2653
|
-
const account_profile_info = await get_active_account_profile_info(uid);
|
|
2654
|
-
|
|
2655
|
-
let
|
|
2654
|
+
// const account_profile_info = await get_active_account_profile_info(uid);
|
|
2655
|
+
|
|
2656
|
+
let selector = { docType: 'account_profile', stat: 3 };
|
|
2657
|
+
let ret = await db_module.find_app_couch_query(app_id, { selector });
|
|
2656
2658
|
|
|
2657
2659
|
return ret.docs;
|
|
2658
2660
|
};
|
|
@@ -2693,9 +2695,9 @@ export const get_account_profile_info = async function (uid, contact_profile_doc
|
|
|
2693
2695
|
|
|
2694
2696
|
export const get_account_profiles = async function (req) {
|
|
2695
2697
|
const { _id, uid, profile_name, limit, skip, bookmark, search, filter_type = 'all', profile_id } = req;
|
|
2696
|
-
|
|
2698
|
+
const app_id = await get_account_default_project_id(uid);
|
|
2697
2699
|
if (_id) {
|
|
2698
|
-
let data = await db_module.
|
|
2700
|
+
let data = await db_module.get_app_couch_doc(app_id, _id);
|
|
2699
2701
|
return data;
|
|
2700
2702
|
}
|
|
2701
2703
|
|