how to implement real time notification like facebook in nopcommerce - facebook

In nopcommerce , i want to create real time notification that when a customer reserved a order,after paying and click the button,order's details be sent to admin panel as a notification.i know i should use SignalR but i really very new in SignalR. how to implement SignalR between two layers means Nop.Web and Nop.Admin?
can anybody help me and suggest me any references?
how to create a modal notification like facebook in nopcommerce or Asp.Net MVC?

Related

Building a simple web form that connects to Recurly's API to allow a subscriber to change their subscription plan

I am trying to build a simple web form that would ideally sit on a WordPress page to allow the subscribers on our platform to change or update their subscriptions, without having to ask our support team (currently they can only cancel, but we want to offer them the option to upgrade).
We use Recurly to manage our billing, and their support team said:
'You would essentially want to build a form that will input values into the Subscription Update API request, that would then be sent to Recurly to make the changes on your customer account.'
They also shared the following document: https://dev.recurly.com/docs/update-subscription
I have limited experience of working with APIs and am also aware that because this form deals with sensitive information (the user ID of a subscriber in this case), I don't want to inadvertently jeopardise the accounts of the subscribers that choose to do this.
Any help would be much appreciated. I have tried searching for a solution but am unsure how to word my request effectively.
It sounds like using the Recurly Hosted UI might be your best bet. Instead of having to build a a web form you can just redirect your customer to the Recurly Hosted UI on a button click. You can retrieve and redirect the url using the Recurly API on your Wordpress site using some simple PHP and then that allows the customer to view invoices, change their plan (if you allow), and change CC information.

Implementing stripe connect directly from within an iOS app

There is a post re: implementing stripe connect from a couple of years ago.
How to use Stripe Connect in an iOS app
I have built an app where only User A needs to register and login while User B can choose from a list of User As and i am trying to set up the app so User B can pay directly to a User A.
While the basic version of stripe is relatively easy to implement Stripe connect is giving me a bit of grief.
Specifically there is an example called Rocket Rider on github (which is meant to.mimic uber, etc.) made by stripe but in this example the "Pilot" had to register via a website.
I'd like it all to happen from within my app. I've read the docs a few.times now and still a touch uncertain.
Is the post from a few years ago still relevant? Is the only way to have the registration done via the app to use a webview?
In the stripe docs there is a section https://stripe.com/docs/mobile/ios/standard
Which essentially goes through the implementation for iOS. But I wasn't sure if these docs only refer to payment that as the developer I would receive if say I was selling a product to users.
Again, in my app there is a list of User As and each User A would register ideally within the app and then User B can choose who to pay. I wasn't sure if the "Standard" doc above also refers to this scenario.
Thanks
Been looking into the same thing today (March 2019) and have a few answers for you
The current state of the Stripe Cocoa Pod does not have anything that has to do with connect accounts. That will not help you in any way with creating connect accounts.
All is not lost. If you must stay in-app, you may create what is called a Custom Account--This means that you are responsible for the UI, User Validation, and Communication. Your users will not be able to use the Lovely Express Dashboard either....but you can stay in app.
As you alluded to, you are still able to use Safari to open Stripe Express and have your app handle the deep linking once the experience is complete. While this is an annoyance, there are some serious perks to having the Express experience. You don't have to deal anything bank account related because the Express Dashboard will handle it for you and Stripe will handle all verification communication. (Outside app).
TLDR: You can do it completely in app using Custom Accounts......but you'll be on your own!

How would you implement a Newsletter form in Ember?

I'm new in Ember and right now I'm developping a website that uses Django+TastyPie+Ember. It wasn't until receantly that I had to deal with data getting back to the server, and I feel that I still don't see the full picture here.
Without having user accounts yet, I was wondering what was the "recommended" way of implement a form to to register to a newsletter, where someone introduces their email and it's saved, for instance, into the database.

How do I add PayPal to my web app and expose additional functionality once payment has been made?

I am building a simple web app that will allow users to sign up and then use the web application. I want to add a payment mechanism after sign up but before the web app functionality can be used.
For example:
User arrives at site and signs up
PayPal payment options offered on page (payment for one-time use OR payment for unlimited annual use)
After payment is successfully made, user profile in DB updated to "PAID" status
Rest of page exposed with access to web app functionality
I would be OK if after step 3 a new page was loaded with the web app functionality, but the same page exposing the functionality (e.g. showing a div) would be a better UI in my opinion.
I have never integrated PayPal with a web app (PayPal buttons don't count!) and curious to know how to set this up given my web app is sporting a vanilla LAMP architecture.
Any help or pointers to guides or sample code would be greatly appreciated. Just as useful would be any pitfalls to watch out for as I go about this exercise.
Thanks.
PayPal offers a notification mechanism just for the purpose such as yours. The asynchronous IPN mechanism and synchronous PDT mechanism. IPN is better suited for backend tasks (in your case DB update. However, since you need to offer additional features to your user after payment is done PDT is probably better as it is real time
You have easy snippets for all main programming languages on www.x.com,
IPN:
https://merchant.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/library_code_ipn_code_samples
PDT:
https://merchant.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/library_code_ipn_code_samples
If you are really going to implement this, read about differences between IPN and PDT, they pass around same messages but the risks associated are different. Which one you need always depends on the context.
Any simple ajax tutorial will help you with this. The only thing you need to do is something like this:
premium.php
<?php
$query="SELECT 'user' FROM table ETC ETC ETC"; //the query to test if paid
$RESULT = MYSQL_QUERY( bla bla bla, $query);
if $RESULT ... = true
{
echo "<div> THE PREMIUM CONTENT</div>";
else
echo "<div> please pay to see the content </div>";
}
?>
Just call premium.php in the ajax code. Hope it helps.

Invoking Mail App on the iPhone

The application I'm writing calls a web service that sends an email to the user. After the call to the web service is complete, I would like to bring up the Mail application so the user can read the email. I know I can use mailto:, but then a new email is created for the user to compose. Is there a way to invoke the Mail application so that it starts up at the Mailboxes view, allowing the user to navigate to their inbox?
Thanks.
You can't do it. There is no functionality in the SDK to bring up another application outside of URL associations. The best you can hope for in the short term is that they create a way for you to embed an email panel into your application.