-
Notifications
You must be signed in to change notification settings - Fork 374
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Github Commit: —--------------- -Implement refrral program -Implement ewallet -Implement image library -Implement shareathon queue in content studio module -fixed some content studio bugs
- Loading branch information
1 parent
be4f025
commit c220dd5
Showing
226 changed files
with
5,803 additions
and
1,906 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,8 @@ | ||
#:E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard\Socioboard.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard\Socioboard.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.Facebook\Socioboard.Facebook.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard\Socioboard.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.Pinterest\Socioboard.Pinterest.xproj | ||
#:E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\SociobordRssDataServices\SociobordRssDataServices.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\SociobordRssDataServices\SociobordRssDataServices.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Domain.Socioboard\Domain.Socioboard.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\SociobordRssDataServices\SociobordRssDataServices.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.Facebook\Socioboard.Facebook.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\SociobordRssDataServices\SociobordRssDataServices.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.Instagram\Socioboard.Instagram.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\SociobordRssDataServices\SociobordRssDataServices.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.LinkedIn\Socioboard.LinkedIn.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\SociobordRssDataServices\SociobordRssDataServices.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.Twitter\Socioboard.Twitter.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\SociobordRssDataServices\SociobordRssDataServices.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.Google\Socioboard.Google.xproj | ||
E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Socioboard.Facebook\Socioboard.Facebook.xproj|E:\D DRIVE\socioboardgithub\githubUpdated\Socioboard-Core-3.0\src\Domain.Socioboard\Domain.Socioboard.xproj |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Threading.Tasks; | ||
using Microsoft.AspNetCore.Mvc; | ||
using Microsoft.AspNetCore.Hosting; | ||
using Microsoft.Extensions.Logging; | ||
using Api.Socioboard.Model; | ||
using Microsoft.AspNetCore.Cors; | ||
using System.Xml; | ||
using System.Text.RegularExpressions; | ||
using Socioboard.Twitter.App.Core; | ||
using MongoDB.Driver; | ||
using Domain.Socioboard.Models; | ||
|
||
// For more information on enabling Web API for empty projects, visit http://go.microsoft.com/fwlink/?LinkID=397860 | ||
|
||
namespace Api.Socioboard.Controllers | ||
{ | ||
[EnableCors("AllowAll")] | ||
[Route("api/[controller]")] | ||
public class EwalletController : Controller | ||
{ | ||
public EwalletController(ILogger<EwalletController> logger, Microsoft.Extensions.Options.IOptions<Helper.AppSettings> settings, IHostingEnvironment env) | ||
{ | ||
_logger = logger; | ||
_appSettings = settings.Value; | ||
_redisCache = new Helper.Cache(_appSettings.RedisConfiguration); | ||
_env = env; | ||
} | ||
private readonly ILogger _logger; | ||
private Helper.AppSettings _appSettings; | ||
private Helper.Cache _redisCache; | ||
private readonly IHostingEnvironment _env; | ||
|
||
//Ads verfication | ||
|
||
[HttpGet("GetEwalletTransactions")] | ||
public IActionResult GetEwalletTransactions(long userid) | ||
{ | ||
try | ||
{ | ||
DatabaseRepository dbr = new DatabaseRepository(_logger, _env); | ||
List<Ewallet> lsturl = dbr.Find<Ewallet>(t => t.UserId == userid).ToList(); | ||
if (lsturl != null) | ||
{ | ||
return Ok(lsturl); | ||
} | ||
else | ||
{ | ||
return NotFound(); | ||
} | ||
} | ||
catch(Exception ex) | ||
{ | ||
return NotFound(); | ||
} | ||
|
||
|
||
} | ||
|
||
[HttpGet("UserBalance")] | ||
public IActionResult UserBalance(long userid) | ||
{ | ||
try | ||
{ | ||
DatabaseRepository dbr = new DatabaseRepository(_logger, _env); | ||
double AddMoney = dbr.Find<Ewallet>(t => t.UserId == userid && t.TransactionStatus == "Money Added").Sum(t => t.Amount); | ||
double withdrawMoney = dbr.Find<Ewallet>(t => t.UserId == userid && t.TransactionStatus == "Money withdraw").Sum(t => t.Amount); | ||
double Balance = AddMoney - withdrawMoney; | ||
return Ok(Balance); | ||
} | ||
catch(Exception ex) | ||
{ | ||
return BadRequest(); | ||
} | ||
|
||
|
||
} | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.