微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

eleme_union_meal first. linux系统下需要的安装包[](<a href="https://git.oschina.net/bigpigeon/eleme_union_meal#second-">https://git.oschina.net/bigpigeon/eleme_union_meal#second-</a>[](<a href="ht 饿了么联合点餐系统

程序名称:eleme_union_meal first. linux系统下需要的安装包[](<a href="https://git.oschina.net/bigpigeon/eleme_union_meal#second-">https://git.oschina.net/bigpigeon/eleme_union_meal#second-</a>[](<a href="ht

授权协议: 未知

操作系统: 跨平台

开发语言: Python

eleme_union_meal first. linux系统下需要的安装包[](<a href="https://git.oschina.net/bigpigeon/eleme_union_meal#second-">https://git.oschina.net/bigpigeon/eleme_union_meal#second-</a>[](<a href="ht 介绍

饿了么联合点餐系统,可统计每份菜多少份,并自动选出最高优惠的订单和每个人应付的钱。

什么是eleme_union_meal

eleme_union_meal是一个B/S结构的软件,它能收集用户在饿了么下的订单,计算出最优惠的价格下单

docker部署方式方式:

  1. 安装docker和docker-compose

  2. 修改server.json中的server_host

  3. 进入项目根目录docker-compose build

  4. 进入项目根目录docker-compose up

[](https://git.oschina.net/bigpigeon/eleme_union_meal#普通安装eleme-union-

meal)普通安装eleme_union_meal

first. linux系统下需要的安装包

[](https://git.oschina.net/bigpigeon/eleme_union_meal#second-

iojs需要的安装包)second. iojs需要的安装包

  • jsdom

  • redis

  • request

  • connect

[](https://git.oschina.net/bigpigeon/eleme_union_meal#third-

python需要的安装包)third. python需要的安装包

[](https://git.oschina.net/bigpigeon/eleme_union_meal#fourth-

配置Nginx)fourth. 配置Nginx

创建一个eleme_union_Nginx.conf的文件并把以下内容复制进去

server {
    listen     8888;
    server_name    eleme_union;
    location ~ \.(html|js|css)$ {
        root /home/ele.me/client;
    }
    location ^~ /api/py/ {
        proxy_pass http://127.0.0.1:9000;
    }
    location ^~ /api/js/ {
        proxy_pass http://127.0.0.1:9001;
    }
}

然后在编辑Nginx的主配置文件增加下面一段include

http {
    #...
    include /your/conf/dir/eleme_union_Nginx.conf;
}

[](https://git.oschina.net/bigpigeon/eleme_union_meal#fifth-修改server-json-

文件)fifth. 修改server.json 文件

{
    "redis":{
        "max_connections": 5,
        "host": "127.0.0.1",
        "port": 6379
    },
    "client_replace": {
        "server_host": "http://192.168.56.104:8888",
        "alipay_url": "https://qr.alipay.com/5734546795641850",
        "qrcode_tips": "付费"
    },
    "uwsgi": {
        "wsgi-file": "portal.py",
        "http-socket": "0.0.0.0:9000"
    },
    "nodejs_port": 9001
}

注意事项

  • client_replace.server_host 必须是客户端能访问到的服务器地址,不能填127.0.0.1之类的

  • uwsgi.http-socket 和 nodejs_port 必须与上面Nginx.conf中的端口对应

sixth.

运行服务

  1. 进入eleme_union_meal/server 目录

  2. 执行脚本 uwsgi –json ../server.json & iojs portal.js &

[](https://git.oschina.net/bigpigeon/eleme_union_meal#seventh-

在客户端测试)seventh. 在客户端测试

  1. 将以下js制作成书签保存到收藏夹中 javascript:(function(){var f=document.createElement('script');f.src='http://192.168.56.104:8888/import.js';document.body.appendChild(f);})();

  2. 进入某个饿了么餐厅比如 http://r.ele.me/gz-zwg 然后点击那个js书签,这时会看到网页的右下角多了一个输入框和一个买买买按钮, 在输入框中输入你的名字

  3. 选好你想买的菜单点击买买买按钮

  4. 跳转的网页中就可以看到你刚选的菜单

  5. 在大家下好单后点击该网页中的锁按钮,然后服务器就可以自动计算出最优惠订单分类,然后你只要根据分好类的订单在饿了么下单就行了

eleme_union_meal first. linux系统下需要的安装包[](<a href="https://git.oschina.net/bigpigeon/eleme_union_meal#second-">https://git.oschina.net/bigpigeon/eleme_union_meal#second-</a>[](<a href="ht 官网

https://git.oschina.net/bigpigeon/eleme_union_meal

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐