@xuda.io/account_module 1.2.1221 → 1.2.1223
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 +4 -1
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -2467,7 +2467,6 @@ export const get_account_ai_usage = async function (req, job_id, headers) {
|
|
|
2467
2467
|
let total_usage = 0;
|
|
2468
2468
|
let profile = {};
|
|
2469
2469
|
|
|
2470
|
-
debugger;
|
|
2471
2470
|
for (const row of ai_usage.rows) {
|
|
2472
2471
|
const year = row.key[0];
|
|
2473
2472
|
const month = row.key[1];
|
|
@@ -2705,6 +2704,10 @@ export const get_account_profile_info = async function (uid, contact_profile_doc
|
|
|
2705
2704
|
|
|
2706
2705
|
doc.card_background = `linear-gradient(145deg, #242480 0%, #060619 100%)`;
|
|
2707
2706
|
// doc.border = get_contact_border(doc);
|
|
2707
|
+
debugger;
|
|
2708
|
+
const usage_ret = await account_module.get_account_ai_usage({ uid });
|
|
2709
|
+
obj.USER_DATA.max_credits = usage_ret.data.credits.total;
|
|
2710
|
+
obj.USER_DATA.used_credits = usage_ret.data.usage.total;
|
|
2708
2711
|
|
|
2709
2712
|
return doc;
|
|
2710
2713
|
};
|