From 298e31c92070641ee034e77202367ece4170cf5f Mon Sep 17 00:00:00 2001 From: Evan Feenstra Date: Fri, 27 Nov 2020 09:11:11 -0800 Subject: [PATCH] store escrow repayment msgs and return in list tx --- dist/src/controllers/index.js | 2 +- dist/src/controllers/index.js.map | 2 +- dist/src/controllers/messages.js | 26 +++++++++++++++++++++++++ dist/src/controllers/messages.js.map | 2 +- dist/src/controllers/payment.js | 1 + dist/src/controllers/payment.js.map | 2 +- src/controllers/index.ts | 2 +- src/controllers/messages.ts | 29 ++++++++++++++++++++++++++++ src/controllers/payment.ts | 1 + 9 files changed, 62 insertions(+), 5 deletions(-) diff --git a/dist/src/controllers/index.js b/dist/src/controllers/index.js index 7a5104c..98cf6b3 100644 --- a/dist/src/controllers/index.js +++ b/dist/src/controllers/index.js @@ -140,7 +140,7 @@ exports.ACTIONS = { [msgtypes.group_leave]: chats.receiveGroupLeave, [msgtypes.group_kick]: chats.receiveGroupKick, [msgtypes.delete]: messages.receiveDeleteMessage, - [msgtypes.repayment]: () => { }, + [msgtypes.repayment]: messages.receiveRepayment, [msgtypes.member_request]: chatTribes.receiveMemberRequest, [msgtypes.member_approve]: chatTribes.receiveMemberApprove, [msgtypes.member_reject]: chatTribes.receiveMemberReject, diff --git a/dist/src/controllers/index.js.map b/dist/src/controllers/index.js.map index 1190557..2e3762b 100644 --- a/dist/src/controllers/index.js.map +++ b/dist/src/controllers/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/controllers/index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,sCAAgC;AAChC,iCAAgC;AAChC,2CAA0C;AAC1C,+BAA8B;AAC9B,qCAAoC;AACpC,uCAAsC;AACtC,qCAAoC;AACpC,uCAAsC;AACtC,iCAAgC;AAChC,uCAAsC;AACtC,sCAAqC;AACrC,gDAA+C;AAC/C,qCAAoC;AACpC,iDAAgD;AAChD,iCAAgC;AAChC,8CAAyC;AACzC,0CAAyC;AACzC,0CAAyC;AACzC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,CAAC,KAAK,CAAC,EAAE,QAAQ,CAAC,YAAY;CACvC,CAAA"} \ No newline at end of file diff --git a/dist/src/controllers/messages.js b/dist/src/controllers/messages.js index 2f86de9..32ef626 100644 --- a/dist/src/controllers/messages.js +++ b/dist/src/controllers/messages.js @@ -294,6 +294,32 @@ exports.receiveBoost = (payload) => __awaiter(void 0, void 0, void 0, function* response: jsonUtils.messageToJson(message, chat, sender) }); }); +exports.receiveRepayment = (payload) => __awaiter(void 0, void 0, void 0, function* () { + const { owner, sender, chat, date_string, amount, network_type } = yield helpers.parseReceiveParams(payload); + console.log('=> received repayment ' + amount + ' sats'); + if (!owner || !sender || !chat) { + return console.log('=> no group chat!'); + } + var date = new Date(); + date.setMilliseconds(0); + if (date_string) + date = new Date(date_string); + const message = yield models_1.models.Message.create({ + chatId: chat.id, + type: constants_1.default.message_types.repayment, + sender: sender.id, + date: date, + amount: amount || 0, + createdAt: date, + updatedAt: date, + status: constants_1.default.statuses.received, + network_type + }); + socket.sendJson({ + type: 'repayment', + response: jsonUtils.messageToJson(message, chat, sender) + }); +}); exports.receiveDeleteMessage = (payload) => __awaiter(void 0, void 0, void 0, function* () { console.log('=> received delete message'); const { owner, sender, chat, chat_type, msg_uuid } = yield helpers.parseReceiveParams(payload); diff --git a/dist/src/controllers/messages.js.map b/dist/src/controllers/messages.js.map index ba3c439..b8b52a5 100644 --- a/dist/src/controllers/messages.js.map +++ b/dist/src/controllers/messages.js.map @@ -1 +1 @@ -{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/controllers/messages.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,sCAAgC;AAChC,yCAA8B;AAC9B,2CAAoC;AACpC,gCAAyC;AACzC,0CAAyC;AACzC,2CAA0C;AAC1C,sCAAqC;AACrC,sCAA+C;AAC/C,0CAAyC;AACzC,mDAAgD;AAChD,sCAAqC;AACrC,oCAAmC;AACnC,4CAAoC;AAEvB,QAAA,WAAW,GAAG,CAAO,GAAG,EAAE,GAAG,E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CAAA;KACF;SAAM;QACN,aAAO,CAAC,GAAG,EAAE,SAAS,CAAC,CAAA;KACvB;AACF,CAAC,CAAA,CAAA;AAEY,QAAA,aAAa,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;IACzC,eAAM,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAA;IAErD,aAAO,CAAC,GAAG,EAAE,EAAE,CAAC,CAAA;AACjB,CAAC,CAAA"} \ No newline at end of file +{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/controllers/messages.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,sCAAgC;AAChC,yCAA8B;AAC9B,2CAAoC;AACpC,gCAAyC;AACzC,0CAAyC;AACzC,2CAA0C;AAC1C,sCAAqC;AACrC,sCAA+C;AAC/C,0CAAyC;AACzC,mDAAgD;AAChD,sCAAqC;AACrC,oCAAmC;AACnC,4CAAoC;AAEvB,QAAA,WAAW,GAAG,CAAO,GAAG,EAAE,GAAG,EAAE,EAAE;IAC7C,MAAM,YAAY,GAAG,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC;IAEpC,IAAI,CAAC,YAAY,EAAE;QAClB,OAAO,sBAAc,CAAC,GAAG,EAAE,GAAG,CAAC,CAAA;KAC/B;IACD,OAAO,CAAC,GAAG,CAAC,YAAY,CAAC,CAAA;IACzB,MAAM,KAAK,GAAG,MAAM,eAAM,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,EAAE,CAAC,CAAA;IACxE,mCAAmC;IAEnC,IAAI,gBAAgB,GAAG;QACtB,IAAI,EAAE,EAAE,CAAC,cAAE,CAAC,GAAG,CAAC,EAAE,YAAY,EAAE;QAChC,CAAC,cAAE,CAAC,EAAE,CAAC,EAAE;YACR,EAAC,QAAQ,EAAE,KAAK,CAAC,EAAE,EAAC;YACpB,EAAC,QAAQ,E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AAE,CAAC,EAAE,KAAK,CAAC,EAAE;aACf;YACD,MAAM,EAAE,OAAO;SAChB;KACD,CAAC,CAAC;IACH,MAAM,IAAI,GAAG,MAAM,eAAM,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,CAAC,CAAA;IAClE,IAAG,IAAI,EAAE;QACR,MAAM,IAAI,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;QAClC,aAAO,CAAC,GAAG,EAAE,EAAE,CAAC,CAAA;QAChB,sBAAgB,CAAC,IAAI,EAAE,EAAE,EAAE,OAAO,CAAC,CAAA;QACnC,MAAM,CAAC,QAAQ,CAAC;YACf,IAAI,EAAE,WAAW;YACjB,QAAQ,EAAE,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC;SACpC,CAAC,CAAA;KACF;SAAM;QACN,aAAO,CAAC,GAAG,EAAE,SAAS,CAAC,CAAA;KACvB;AACF,CAAC,CAAA,CAAA;AAEY,QAAA,aAAa,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;IACzC,eAAM,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAA;IAErD,aAAO,CAAC,GAAG,EAAE,EAAE,CAAC,CAAA;AACjB,CAAC,CAAA"} \ No newline at end of file diff --git a/dist/src/controllers/payment.js b/dist/src/controllers/payment.js index 5d07379..7564fcf 100644 --- a/dist/src/controllers/payment.js +++ b/dist/src/controllers/payment.js @@ -172,6 +172,7 @@ exports.listPayments = (req, res) => __awaiter(void 0, void 0, void 0, function* type: { [sequelize_1.Op.or]: [ constants_1.default.message_types.message, constants_1.default.message_types.boost, + constants_1.default.message_types.repayment, ] }, amount: { [sequelize_1.Op.gt]: MIN_VAL // greater than diff --git a/dist/src/controllers/payment.js.map b/dist/src/controllers/payment.js.map index 4385531..131a89d 100644 --- a/dist/src/controllers/payment.js.map +++ b/dist/src/controllers/payment.js.map @@ -1 +1 @@ -{"version":3,"file":"payment.js","sourceRoot":"","sources":["../../../src/controllers/payment.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,sCAAgC;AAChC,gCAAyC;AACzC,0CAAyC;AACzC,2CAA0C;AAC1C,sCAAqC;AACrC,sCAA+C;AAC/C,wCAA4C;AAC5C,sCAAqC;AACrC,oCAAmC;AACnC,4CAAoC;AACpC,yCAA8B;AAC9B,iCAAuC;AAE1B,QAAA,WAAW,GAAG,CAAO,GAAG,EAAE,GAAG,EAAE,EAAE;IAC5C,MAAM,EACJ,MAAM,EACN,OAAO,EACP,UAAU,EACV,eAAe,EACf,UAAU,EACV,IAAI,EACJ,IAAI,EACJ,WAAW,EACX,UAAU,EACV,eAAe,EACf,WAAW,EACX,UAAU,GACX,GAAG,GAAG,CAAC,IAAI,CAAA;IAEZ,OAAO,CAAC,GAAG,CAAC,gBAAgB,EAAE,GAAG,CAAC,IAAI,CAAC,CAAA;IAEvC,MAAM,KAAK,GAAG,MAAM,eAAM,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,EAAC,CAAC,CAAA;IAEvE,IAAI,eAAe,IAAI,CAAC,UAAU,IAAI,CAAC,OAAO,EAAE;QAC9C,uBAAgB,CAAC,KAAK,EAAE,eAAe,EAAE,MAAM,IAAE,EAAE,EAAE,IAAI,IAAE,EAAE,EAC3D,UAAS,IAAI;YACX,aAAO,CAAC,GAAG,EAAE,IAAI,CAAC,CAAA;QACpB,CAAC,EACD,UAAS,KAAK;YACZ,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;YAChB,GAAG,CAAC,IAAI,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,CAAC;YACpC,GAAG,CAAC,GAAG,EAAE,CAAC;QACZ,CAAC,CACF,CAAA;QACD,OAAM;KACP;IAED,MAAM,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C/B,mBAAS,CAAC,aAAa,CAAC,cAAc;gCACtC,mBAAS,CAAC,aAAa,CAAC,OAAO;gCAC/B,mBAAS,CAAC,aAAa,CAAC,QAAQ;6BACjC,EAAC;wBACF,MAAM,EAAE,EAAC,CAAC,cAAE,CAAC,GAAG,CAAC,EAAE,mBAAS,CAAC,QAAQ,CAAC,MAAM,EAAC;qBAC9C;oBACD;wBACE,IAAI,EAAG,EAAC,CAAC,cAAE,CAAC,EAAE,CAAC,EAAE;gCACf,mBAAS,CAAC,aAAa,CAAC,OAAO;gCAC/B,mBAAS,CAAC,aAAa,CAAC,KAAK;6BAC9B,EAAC;wBACF,MAAM,EAAE;4BACN,CAAC,cAAE,CAAC,EAAE,CAAC,EAAE,OAAO,CAAC,eAAe;yBACjC;wBACD,YAAY,EAAE,mBAAS,CAAC,aAAa,CAAC,SAAS;wBAC/C,MAAM,EAAE,EAAC,CAAC,cAAE,CAAC,GAAG,CAAC,EAAE,mBAAS,CAAC,QAAQ,CAAC,MAAM,EAAC;qBAC9C;iBACF;aACF;YACD,KAAK,EAAE,CAAC,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;YAC9B,KAAK;YACL,MAAM;SACP,CAAC,CAAA;QACF,MAAM,GAAG,GAAG,IAAI,IAAE,EAAE,CAAA;QACpB,aAAO,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,CAAC,OAAO,CAAA,EAAE,CAAC,SAAS,CAAC,aAAa,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;KACxE;IAAC,OAAM,CAAC,EAAE;QACT,aAAO,CAAC,GAAG,EAAE,oBAAoB,CAAC,CAAA;KACnC;AACH,CAAC,CAAA,CAAC"} \ No newline at end of file +{"version":3,"file":"payment.js","sourceRoot":"","sources":["../../../src/controllers/payment.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,sCAAgC;AAChC,gCAAyC;AACzC,0CAAyC;AACzC,2CAA0C;AAC1C,sCAAqC;AACrC,sCAA+C;AAC/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9C;oBACD;wBACE,IAAI,EAAG,EAAC,CAAC,cAAE,CAAC,EAAE,CAAC,EAAE;gCACf,mBAAS,CAAC,aAAa,CAAC,OAAO;gCAC/B,mBAAS,CAAC,aAAa,CAAC,KAAK;gCAC7B,mBAAS,CAAC,aAAa,CAAC,SAAS;6BAClC,EAAC;wBACF,MAAM,EAAE;4BACN,CAAC,cAAE,CAAC,EAAE,CAAC,EAAE,OAAO,CAAC,eAAe;yBACjC;wBACD,YAAY,EAAE,mBAAS,CAAC,aAAa,CAAC,SAAS;wBAC/C,MAAM,EAAE,EAAC,CAAC,cAAE,CAAC,GAAG,CAAC,EAAE,mBAAS,CAAC,QAAQ,CAAC,MAAM,EAAC;qBAC9C;iBACF;aACF;YACD,KAAK,EAAE,CAAC,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;YAC9B,KAAK;YACL,MAAM;SACP,CAAC,CAAA;QACF,MAAM,GAAG,GAAG,IAAI,IAAE,EAAE,CAAA;QACpB,aAAO,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,CAAC,OAAO,CAAA,EAAE,CAAC,SAAS,CAAC,aAAa,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;KACxE;IAAC,OAAM,CAAC,EAAE;QACT,aAAO,CAAC,GAAG,EAAE,oBAAoB,CAAC,CAAA;KACnC;AACH,CAAC,CAAA,CAAC"} \ No newline at end of file diff --git a/src/controllers/index.ts b/src/controllers/index.ts index 94e9132..9ba1625 100644 --- a/src/controllers/index.ts +++ b/src/controllers/index.ts @@ -141,7 +141,7 @@ export const ACTIONS = { [msgtypes.group_leave]: chats.receiveGroupLeave, [msgtypes.group_kick]: chats.receiveGroupKick, [msgtypes.delete]: messages.receiveDeleteMessage, - [msgtypes.repayment]: ()=>{}, + [msgtypes.repayment]: messages.receiveRepayment, [msgtypes.member_request]: chatTribes.receiveMemberRequest, [msgtypes.member_approve]: chatTribes.receiveMemberApprove, [msgtypes.member_reject]: chatTribes.receiveMemberReject, diff --git a/src/controllers/messages.ts b/src/controllers/messages.ts index da6d332..ef8df69 100644 --- a/src/controllers/messages.ts +++ b/src/controllers/messages.ts @@ -325,6 +325,35 @@ export const receiveBoost = async (payload) => { }) } +export const receiveRepayment = async (payload) => { + const {owner, sender, chat, date_string, amount, network_type} = await helpers.parseReceiveParams(payload) + console.log('=> received repayment ' +amount+ ' sats') + if(!owner || !sender || !chat) { + return console.log('=> no group chat!') + } + + var date = new Date(); + date.setMilliseconds(0) + if(date_string) date=new Date(date_string) + + const message = await models.Message.create({ + chatId: chat.id, + type: constants.message_types.repayment, + sender: sender.id, + date: date, + amount: amount||0, + createdAt: date, + updatedAt: date, + status: constants.statuses.received, + network_type + }) + + socket.sendJson({ + type: 'repayment', + response: jsonUtils.messageToJson(message, chat, sender) + }) +} + export const receiveDeleteMessage = async (payload) => { console.log('=> received delete message') const {owner, sender, chat, chat_type, msg_uuid} = await helpers.parseReceiveParams(payload) diff --git a/src/controllers/payment.ts b/src/controllers/payment.ts index 338f6b1..ec1cd00 100644 --- a/src/controllers/payment.ts +++ b/src/controllers/payment.ts @@ -188,6 +188,7 @@ export const listPayments = async (req, res) => { type: {[Op.or]: [ constants.message_types.message, // paid bot msgs, or price_per_message msgs constants.message_types.boost, + constants.message_types.repayment, ]}, amount: { [Op.gt]: MIN_VAL // greater than