Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [e-commerce]

Electronic commerce, commonly known as e-commerce, eCommerce or e-comm, refers to the buying and selling of products or services over electronic systems such as the Internet.

5
votes
0answers
86 views

Python gRPC shopping cart service

The .proto file is as below: ...
1
vote
0answers
20 views

Simple cart update WordPress plugin

I created a plugin to update cart automatically on quantity change with some additional options. I want to focus only on the main plugin file, skipping uninstall.php and .js file which are entirely ...
1
vote
2answers
59 views

PHP subscription workflow

I've creating a working subscription workflow for my webpage, which heavily utilizes a set of functions I've created for this purpose. However, after doing some testing (functionality works fine), I'...
4
votes
0answers
37 views

Convert Amazon transaction data for import into accounting system

At the end of each billing cycle, Amazon generates a raw transaction file for my store's orders that cycle. I am converting that raw transaction file into a .csv file to be imported into my accounting ...
2
votes
1answer
65 views

Executing multiple steps to handle a purchase using currying

Is doing something like this utilizing currying in a practical sense? ...
3
votes
1answer
77 views

React code to build shopping cart

I have built a basic shopping cart simulator. All it does is add and remove items between two different basket (i.e. aisle vs basket). While working on the problem I started to think about the ...
3
votes
0answers
57 views

AJAX shopping cart with quantity +/- buttons

I'm a junior developer (couple years into it) and very new to AJAX. I'm writing an internal inventory application built on MVC and right now I'm dealing with adding and removing items to/from a cart. ...
1
vote
2answers
58 views

Note for monitoring buy/sell item list

I'm making note where you can add items that you buy or sell, any suggestions? ...
1
vote
1answer
91 views

Stripe payment form

I have a stripe payment form and when I use different forms that get hidden, I must use separate IDs for the form to appear. I have found a way to do this but looking to simplify the code if this is ...
1
vote
2answers
73 views

Reporting sums of shopping carts

I have an object (ShoppingCart) that has a list of CartItems, which contains the related ...
2
votes
0answers
419 views

MySQL database schema for e-commerce website

I'm making an e-commerce site, using MySQL for storing data. ...
2
votes
0answers
26 views

WordPress plugin for shipping calculation

I am writing a WordPress plugin that allows shipping calculation on the product page. Originally, shipping calculation is only available in the cart. To calculate shipping costs on product page, ...
3
votes
1answer
63 views

Conditionally displaying a notice about free shipping in Woocommerce

I wrote PHP code to display a Woocommerce notice - "free shipping for $40 & under" only once on shop page and once on cart page, but also in cart should not be more than 40$. The code works, but ...
5
votes
2answers
896 views

Apple receipt validator

I'm working on a solution for validating Apple receipts. Here's the repository as whole. I based it mostly on the gdx-pay-server library. In my implementation, one of the classes I want to improve is <...
8
votes
1answer
86 views

Shopping cart purchase method in service layer

The following is a class in the service layer of an ASP.NET Core web application, which currently contains a single method: PurchaseCart. The intention is that an ID is passed in to a "shopping cart" ...
2
votes
0answers
104 views

Classes for an online shopping website, using a combination of Inheritance and Composition

I am developing an online shopping website. I have a class Item, which contains all the common attributes of all products (I will explain the interfaces at the end) ...
3
votes
1answer
653 views

Credit card validator code in Python

I wrote a Python code that is validating Credit Card Numbers. Some of the advanced programmers told me my whole code is messy. How can I make my code cleaner? ...
3
votes
1answer
639 views

Shopping cart in Rails for karaoke items

This is my first cart implementation in Rails so I wanted to get some feedback on the correct method to implement it. First of all, I am storing the data directly in the session because the items in ...
4
votes
2answers
171 views

Using dependency injection for Node payment system

I would like some feedback on my code. I am currently building a payments solution in a serverless lambda project. This what I came up with (very basic code at the moment): ...
2
votes
1answer
138 views

Plugin for showing cross-sells on the single product page in WooCommerce

I made a custom plugin for showing cross-sells on the single product page in WooCommerce, however i need to know if this is secure and possibly act as an attack vector. Additionally, is there a better ...
4
votes
1answer
112 views

Simple angular app - Shopping website

In looking for a bit of feedback about an Angular app I have created. I'm new to angular I want to clean up the loose ends before I carry on and add new functionality. Below is the code snippet of ...
2
votes
1answer
413 views

Open/Closed Principle with calculating the total cost of items in a shopping cart

I came across the below example in a tutorial for the open-closed OOP principle. This example demonstrates function of calculating the total cost of items in a shopping cart. I have provided code for ...
3
votes
1answer
6k views

jQuery code to total the items in a shopping cart

I implemented a shopping cart with asp.net and jquery on my website, and here is my js code which calculates amount and total sum on client side: ...
2
votes
0answers
769 views

Simulate a simple shopping basket

I simulated a web shopping basket for a store with a single product, for two reasons: to learn to use browser events for a user to manipulate data in a page so that, in the future, I can build it ...
2
votes
1answer
316 views

Laravel controller for creating payments with Mollie

I have a controller with functions to create and finish a Mollie payment. But I've got the idea that those functions are too big and do too many things. What I understand is that a function should do ...
1
vote
1answer
558 views

Shopping cart business rules

A purchase order has an order ID, a customer ID, total price and line items. Line items can be a product or membership type. Business rules: If the purchase order contains a membership, it has to be ...
4
votes
3answers
105 views

Removal of jQuery from script to auto-apply coupons from a link

We are using a small extension that auto-applies coupons from a link. The extension had pop-up JS based on jQuery: ...
5
votes
1answer
12k views

Shopping cart in pure JavaScript

I need help in making this shopping cart adhere to the W3C rules. This is already 100% functioning. I just need help in making this code as clean and as short as possible. I want it in pure ...
1
vote
2answers
411 views

Manually mapping complex objects using Windows Service & Shopify

I'm looking for guidance/review on an approach that I've taken. Structure Windows Service Shopify Module (API) Official Shopify API The Scenario Our Windows Service connects to the Shopify Module ...
6
votes
2answers
873 views

Selenium-based link checker for a shopping site

I just started learning Python and I wrote my first useful script for work. I did a bunch of the basic tutorials and really enjoyed learning Python so far. I am looking for any advice on how to make ...
6
votes
3answers
6k views

Shopping Cart design interview task

I was interviewed for one position and had the following task. The goal is to design system according step 1, then adapt it to additional requirements in step 2. Step 1: Shopping cart You are ...
4
votes
1answer
417 views

TDD Django - Shopping Cart

I'm new in Python TDD and I would like to ask you about some feedback for Django unit testing. ...
2
votes
1answer
76 views

Changes quantities that are displayed in a shopping cart page

I'm fairly new to PHP and am following e-commerce tutorials. When exploring a way to resolve a problem I had with a PHP code block, I came upon a post another person had with the same code block. The ...
6
votes
1answer
570 views

Shopping basket with discounts and tax

I am writing a simple application that prints out the details of a receipt containing items purchased by a customer. The receipt should list the number of items, the name, the final price (including ...
4
votes
1answer
138 views

pyvdp - Python library for Visa Developer Program

I'm coming from PHP and recently started developing in Python. As a part of my self-study course, I developed a small library for access to Visa Developer Program APIs and published it on Github. It ...
1
vote
1answer
27 views

Class for Stripe transactions

I just wonder whether it is a common approach to hit the third-party API and fetch values within the initialize method? Ex. ...
5
votes
2answers
6k views

Shopping cart with discounts

I want to create a shopping cart project with discounts for products. For instance, if you buy 2 books, you can get 10% off Parker pens. I created a shopping cart example, but without exception ...
3
votes
1answer
124 views

Sales tax calculator with branching based on postal address

A problem I come across very often is what to do with branching classes. The class below is one example of a class that can turn ugly very fast. The requirements of the class is that if the address ...
2
votes
1answer
159 views

Shopping basket script in object-oriented PHP

I have made a shopping basket script that allows the user to add and remove items from the basket, and edit quantity of items that are in the basket. I am new to OOP, and I would like to get your ...
7
votes
1answer
140 views

Card payment strategies

In my project, I have 3 payment mode. Via Manually Entered , Card Swipe, and cash. I have 2 fragments named RecordCardManuallyFragment and ...
3
votes
1answer
2k views

Shopping cart program in Java with a text menu

I wrote this program to implement a shopping cart. It supports adding/removing items to the cart, viewing the current order, and completing the checkout process. ...
2
votes
2answers
4k views

AngularJS shopping cart using local storage

Two weeks ago I started writing some Javascript and AngularJS code for a customer. As a proud newby I must also be aware of the dangers on the big bad Internet. In particular vulnerabilities such as ...
1
vote
0answers
175 views

Persistent shopping cart that allows users to do CRUD operations as well as perform a checkout

I have never dealt much with jQuery or JavaScript. The following code is something I wrote and while it is functional, I am pretty sure it is a complete mess and it could use some improvements for ...
1
vote
1answer
97 views

Recording a customer's shopping cart as an order 2.0

Some days ago, I put up a question here for review about the best way to handle JDBC transactions in the context of an e-commerce Java web application. After a kind suggestion from user @gardenhead, ...
2
votes
2answers
241 views

Recording a customer's shopping cart as an order

I have come up with the following method to post a transaction to a database, in the context of an e-commerce Java web application. The transaction consists in submitting a new order alongside its ...
0
votes
1answer
65 views

Funds transfer authorization

I have the working code but it is pretty dirty. The goal is to input a number in an application. If it satisfies the min/max logic then jump to the authorization part. Afterwards we can confirm it or ...
2
votes
0answers
56 views

Byzantine payment processing code

I've been working on a large Ruby on Rails application for several years. We inherited it and refactored and upgraded it, but there are some sections that have not been touched in at least 5 years (...
1
vote
1answer
1k views

ISO8583 encoding data fields

I just want to confirm that my ISO8583 format is correct. Example: For the data field 35, the length of the data is 36, so I put 36 before the 4842. Then all the data is inserted in a string (...
6
votes
1answer
4k views

Shopping Cart with React JS

I've just created my first set of related classes in React and would like to get feedback from more experienced React developers. I've used ES and completely vanilla React. The application is a ...
6
votes
3answers
9k views

Python OOP shopping cart

I completed the following task: You need to create the foundations of an e-commerce engine for a B2C (business-to-consumer) retailer. You need to have a class for a customer called User, a class ...