当前位置:网站首页>Taiaisu M source code construction, peak store app premium consignment source code sharing
Taiaisu M source code construction, peak store app premium consignment source code sharing
2022-07-01 18:54:00 【InfoQ】
try {
Db::startTrans();
$order_blind_box_ids = [];
foreach($blind_box_items as $blind_box_item) {
$product = Mage")->find();
$blind_box_product = ModelBlindBoxProduct::with(["tag" => function ($query) {
$query->bind(["tag_img" => "image"]);
}])->where(["blind_box_id" => $blind_box_item->blind_box_id, "product_id" => $blind_box_item->product_id])->find();
$product->tag_image = $blind_box_product->tag_img;
$order_code = date("YmdHis") . substr($user_id . rand(1000000, 9999999), 0, 8);
$order_blind_box = ModelOrderBlindBox::create([
"get_order_id" => 0,
"user_id" => $user_id,
"order_code" => $order_code,
"blind_box_item_id" => $blind_box_item->id,
"product_id" => $product->product_id,
"product_name" => $product->name,
"product_image" => $product->image,
"product_price" => $product->price,
"blind_box_price" => $blind_box->price,
"user_money" => 0,
"bonus_amount" => 0,
"pay_money" => $blind_box->price,
"payment_type" => '',
"order_state" => 99,
"address" => '',
"shipping_state" => 0,
"shipping_time" => 0,
"retrieve_time" => 0,
"retrieve_amount" => 0,
"regret_number" => 0
]);
$order_blind_box_ids[] = $order_blind_box->id;
if (!$order_blind_box->isEmpty()) {
$payment_code = date("YmdHis") . substr($user_id . rand(1000000, 9999999), 0, 8);
$payment_note = " Buy blind boxes ";
ModelPaymentLog::create([
"payment_code" => $payment_code,
"user_id" => $user_id,
"order_blind_box_id"=> $order_blind_box->id,
"blind_box_item_id" => $blind_box_item->id,
"blind_box_price" => $price,
"bonus_id" => $bonus_id,
"bonus_amount" => $bonus_amount,
"pay_money" => $blind_box->price,
"note" => $payment_note,
"transaction_id" => '',边栏推荐
- About enterprise middle office planning and it architecture microservice transformation
- 信度系数低怎么办?信度系数具体怎么算?
- Mise en place d'une plate - forme générale de surveillance et d'alarme, quelles sont les conceptions nécessaires dans l'architecture?
- 隐私沙盒终于要来了
- Mysql database of easyclick
- 华为云专家详解GaussDB(for MySQL)新特性
- Find all missing numbers in the array
- 毕业季 | 华为专家亲授面试秘诀:如何拿到大厂高薪offer?
- AI 训练速度突破摩尔定律;宋舒然团队获得RSS 2022最佳论文奖
- LiveData postValue会“丢”数据
猜你喜欢

Relational database management system of easyclick

Create your own NFT collections and publish a Web3 application to show them (Introduction)

After studying 11 kinds of real-time chat software, I found that they all have these functions

用GSConv+Slim Neck改进Yolov5,将性能提升到极致!

Leetcode203 移除链表元素

Improve yolov5 with gsconv+slim neck to maximize performance!

540. Single element in ordered array / 1684 Count the number of consistent strings

研究了11种实时聊天软件,我发现都具备这些功能…

Go Technology Daily (2022-02-14) - go language slice interview real questions 8 consecutive questions

创建您自己的NFT集合并发布一个Web3应用程序来展示它们(介绍)
随机推荐
R语言使用epiDisplay包的aggregate函数将数值变量基于因子变量拆分为不同的子集,计算每个子集的汇总统计信息
Find all missing numbers in the array
12种数据量纲化处理方式
Lefse analysis
Search 2D matrix 2
R language uses the aggregate function of epidisplay package to divide numerical variables into different subsets based on factor variables, and calculate the summary statistics of each subset
Li Kou daily question - Day 32 -589 N × Preorder traversal of tree
bean的生命周期核心步骤总结
How to manage 1000 anchors by one person?
微服务大行其道的今天,Service Mesh是怎样一种存在?
1、《创建您自己的NFT集合并发布一个Web3应用程序来展示它们》什么是NFT
Leetcode-83 delete duplicate elements in the sorting linked list
How to find the optimal learning rate
Lumiprobe Lumizol RNA 提取试剂解决方案
磁盘的基本知识和基本命令
R语言ggplot2可视化:gganimate包transition_time函数创建动态散点图动画(gif)、shadow_wake函数配置动画的渐变效果(gradual falloff)拖尾效应
A wonderful time to buy and sell stocks
Mise en place d'une plate - forme générale de surveillance et d'alarme, quelles sont les conceptions nécessaires dans l'architecture?
Write an open source, convenient and fast database document query and generation tool with WPF
Leetcode203 remove linked list elements