电影票美团饿了么外卖劵分销CPS吃喝玩乐休闲娱乐小程序开发

外卖CPS红包小程序源码分享

外卖cps带分销返利源码

饿了么红包、美团优惠券开发(外卖cps,三级裂变源码)

源代码地址

http://y.mybei.cn

搭建步骤

截图

在这里插入图片描述

步骤


const Base = require(’./base.js’);
const moment = require(‘moment’);
const fs = require(‘fs’);
const path = require(“path”);
const qiniu = require(‘qiniu’);
module.exports = class extends Base {
/**
* index action
* @return {Promise} []
*/
async indexAction() {
const page = this.get(‘page’) || 1;
const size = this.get(‘size’);
const name = this.get(‘name’) || ‘’;
const model = this.model(‘goods’);
const data = await model.where({
name: [‘like’, %${name}%],
is_delete: 0
}).order([‘sort_order asc’]).page(page, size).countSelect();
// let newData = data;
for (const item of data.data) {
const info = await this.model(‘category’).where({
id: item.category_id
}).find();
item.category_name = info.name;
if (item.is_on_sale == 1) {
item.is_on_sale = true;
} else {
item.is_on_sale = false;
}
if (item.is_index == 1) {
item.is_index = true;
} else {
item.is_index = false;
}
let product = await this.model(‘product’).where({
goods_id: item.id,
is_delete: 0
}).select();
for (const ele of product) {
let spec = await this.model(‘goods_specification’).where({
id: ele.goods_specification_ids,
is_delete: 0
}).find();
ele.value = spec.value;
ele.is_on_sale = ele.is_on_sale ? “1” : “0”;
}
item.product = product;
}
return this.success(data);
}
async getExpressDataAction() {
let kd = [];
let cate = [];
const kdData = await this.model(‘freight_template’).where({
is_delete: 0
}).select();
for (const item of kdData) {
kd.push({
value: item.id,
label: item.name
})
}
const cateData = await this.model(‘category’).where({
parent_id: 0
}).select();
for (const item of cateData) {
cate.push({
value: item.id,
label: item.name
})
}
let infoData = {
kd: kd,
cate: cate
};
return this.success(infoData);
}
async copygoodsAction() {
const goodsId = this.post(‘id’);
let data = await this.model(‘goods’).where({
id: goodsId
}).find();
delete data.id;
data.is_on_sale = 0;
let insertId = await this.model(‘goods’).add(data);
let goodsGallery = await this.model(‘goods_gallery’).where({
goods_id: goodsId,
is_delete:0,
}).select();
for (const item of goodsGallery) {
let gallery = {
img_url: item.img_url,
sort_order: item.sort_order,
goods_id: insertId
}
await this.model(‘goods_gallery’).add(gallery);
}
return this.success(insertId);
}
async updateStock(goods_sn, goods_number) {
think.logger.info(‘存在,现在就更新’);
await this.model(‘product’).where({
goods_sn: goods_sn
}).update({
goods_number: goods_number
});
}
async updateGoodsNumberAction() {
let all_goods = await this.model(‘goods’).where({
is_delete: 0,
is_on_sale: 1
}).select();
for (const item of all_goods) {
let goodsSum = await this.model(‘product’).where({
goods_id: item.id
}).sum(‘goods_number’);
await this.model(‘goods’).where({
id: item.id
}).update({
goods_number: goodsSum
});
await think.timeout(2000);
}
return this.success();
}
async onsaleAction() {
const page = this.get(‘page’) || 1;
const size = this.get(‘size’);
const model = this.model(‘goods’);
const data = await model.where({
is_delete: 0,
is_on_sale: 1
}).order([‘sort_order asc’]).page(page, size).countSelect();
for (const item of data.data) {
const info = await this.model(‘category’).where({
id: item.category_id
}).find();
item.category_name = info.name;
// if (info.parent_id != 0) {
// const parentInfo = aw

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
### 回答1: 同城外卖系统源码、同城O2O配送外卖小程序外卖APP和仿美团饿了么骑手导航配送平台都是用于创建和管理外卖订单、配送和导航的软件。 同城外卖系统源码是一个提供外卖订餐服务的平台,使用者可以在平台上浏览餐厅菜单、下单、付款和选择配送方式。该源码可以供开发人员根据自己的需求进行二次开发,定制自己的外卖订餐系统。 同城O2O配送外卖小程序是一种基于微信或其他社交媒体平台的小程序,用户可以通过搜索附近的餐厅、浏览菜单、下单和支付,餐厅可以收到订单并安排配送。该小程序具有便捷、快速和实时的特点,方便用户下单和餐厅配送管理。 外卖APP是一款专门用于订购外卖的手机应用程序,用户可以通过该APP在手机上浏览餐厅菜单、下单、支付和选择配送方式。该APP通常有用户评价、促销优惠等功能,为用户提供更便捷的外卖服务体验。 仿美团饿了么骑手导航配送平台是一个提供骑手导航和配送管理的软件平台。骑手可以通过该平台接收订单、查看订单详情、导航到目的地以及完成配送。该平台可以根据订单的优先级和距离进行最优的分配,提高配送效率和服务质量。 总之,同城外卖系统源码、同城O2O配送外卖小程序外卖APP和仿美团饿了么骑手导航配送平台都是为了提供便捷的外卖订购和配送服务,满足用户和商家的需求。不同的系统和平台有不同的特点和功能,可以根据个人或商家的需求选择合适的解决方案。 ### 回答2: 同城外卖系统源码是一种提供给餐饮行业的解决方案,能够帮助餐厅与消费者之间实现线上点餐、配送服务的平台。它包括同城o2o配送外卖小程序外卖app,可以模仿美团饿了么等知名平台的骑手导航配送平台。 同城外卖系统源码由前端和后台两部分组成。前端部分是同城o2o配送外卖小程序外卖app,它们提供给消费者一个方便快捷的线上点餐平台,消费者可以通过这些平台选择菜品、下单支付并实时查看订单和配送进度。同时,这些平台也为餐厅提供了一个展示自己菜品并接受订单的渠道。 后台部分是同城外卖系统的核心,它连接了餐厅、骑手和消费者,实现了订单管理、配送管理、骑手管理等功能。通过后台管理系统,餐厅可以接受并管理订单、查看菜品销售情况,骑手可以接受配送任务并进行导航定位,消费者则可以实时查看订单状态和配送进度。 同城外卖系统源码的优势在于它提供了一整套完善的解决方案,不仅包括前端的小程序和app开发,还有后台系统的搭建和管理。这样的系统源码可以有效减少开发成本和周期,帮助餐厅快速上线线上外卖服务。同时,系统的界面和功能可以仿照美团饿了么等成功平台,提供给用户一种熟悉、便捷的体验。 综上所述,同城外卖系统源码包括同城o2o配送外卖小程序外卖app,可以通过仿美团饿了么的骑手导航配送平台实现餐厅与消费者之间的线上点餐和配送服务。这种系统源码具有成本低、周期短、界面友好等优势,是餐饮行业实现线上外卖服务的一个可行解决方案。 ### 回答3: 同城外卖系统源码是为了满足现代社会外卖配送需求而开发的一种技术解决方案。该系统源码适用于开发同城o2o配送外卖小程序外卖app,功能类似于美团饿了么等外卖平台,可以提供用户下单、商家接单、骑手接单、订单配送等功能。 该系统源码基于互联网和移动端技术开发,具备可扩展性和稳定性。通过前端界面和后端逻辑的配合,用户可以通过小程序或app浏览并选择附近的餐馆、菜品,进行下单和支付。商家可以接收订单、处理订单,并与骑手进行配送沟通。骑手可以接收配送任务,并通过导航系统进行准确的配送。 这个系统源码可以帮助餐馆和外卖平台开发出高效、便捷的配送系统,提升用户体验和订单处理效率。同时,它也可以提供一种创业机会,帮助个人或企业开发自己的同城外卖平台。 总结而言,同城外卖系统源码是一种满足现代社会外卖配送需求的技术解决方案。通过开发同城o2o配送外卖小程序外卖app,可以构建类似于美团饿了么等外卖平台的功能,并为用户、商家和骑手提供便捷的下单、接单和配送服务。这个系统源码具备可扩展性和稳定性,适合个人创业或企业开发自己的同城外卖平台。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值