GithubHelp home page GithubHelp logo

Comments (4)

harsh-ag avatar harsh-ag commented on June 24, 2024

Hi @99cm ,

I was trying to replicate your bug with latest(master) branch, although it seems to be working fine there. Can you please specify the versions of spree, rails and ruby you are using.

from spree-loyalty-points.

cgcmart avatar cgcmart commented on June 24, 2024

ruby 2.5.0
rails 5.1.5
spree 3.4.4

my rails app started 2 years ago with ruby 2.3.0, rails 4.2, spree 3.1, and installed spree-loyalty-points that I believe never working in production, mostly caused by rake cron job failure. there are 3 developers worked on issues, unfortunately, unsolved, because loyalty_points not awarded to user.

Readme:

Update Loyalty Points in the system

Loyalty Points will be awarded to the customer only after:

Admin captures the payment manually for his order
β€œTime” set in Loyalty Point configuration has elapsed after capturing the payment.

Add a Cron Job to run the following rake task to award Loyalty Points to customers who satisfy the above two conditions.

bundle exec rake spree:loyalty_points:award

irb output

irb(main):002:0> Spree::Order.with_hours_since_payment
Traceback (most recent call last):
2: from (irb):5
1: from app/models/spree/order_decorator.rb:11:in `block (2 levels) in <top (required)>'
ArgumentError (wrong number of arguments (given 0, expected 1))

irb(main):006:0> Spree::Order.with_uncredited_loyalty_points
Traceback (most recent call last):
2: from (irb):6
1: from app/models/spree/order_decorator.rb:13:in `block (2 levels) in <top (required)>'
ArgumentError (wrong number of arguments (given 0, expected 1))

Since loyalty_points not awarded, one developer wrote a configure code

config/schedule.rb
every 1.day, at: '5:05 am' do rake 'spree:loyalty_points:award' end

This effort did not work.

from spree-loyalty-points.

harsh-ag avatar harsh-ag commented on June 24, 2024

Hi @99cm,
Currently, we are not supporting this extension(spree_loyalty_points) for the versions of Spree which have introduced Store Credits because this extension creates a new payment method for Loyalty Points which is no longer needed in them. And, we can simply use store credits to create such program.

from spree-loyalty-points.

cgcmart avatar cgcmart commented on June 24, 2024

Thank you for your time to answer my question and letting me know store credit similar to loyalty points except a method of refund. I knew spree with store credit, but I paid attention to loyalty_points. I'll learn how to use store credit.

from spree-loyalty-points.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.