Skip to content

Commit

Permalink
Merge pull request #1 from NimaQu/master
Browse files Browse the repository at this point in the history
init pr
  • Loading branch information
SoDa committed Jun 18, 2018
2 parents d77eb63 + 740a637 commit d983df0
Show file tree
Hide file tree
Showing 2,201 changed files with 19,924 additions and 186,222 deletions.
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
@@ -1 +1 @@
#为了能更愉快地 debug,此文件已经作废,请各位 移步 config/config.php 进行设置
#为了能更愉快地 debug,此文件已经作废,请各位 移步 config/config.php 进行设置,但请不要删除此文件,会导致网站500
1 change: 0 additions & 1 deletion .env.example

This file was deleted.

2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Auto detect text files and perform LF normalization
* text=auto
8 changes: 8 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: Bug report
about: Bug 反馈

---

1.此项目为前端,不解决任何后端相关问题
2.提问前请先阅读 wiki,否则将会 close 并 block
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
*/.DS_Store
.DS_Store
/vendor
/config/.config.php
/.idea
storage/qqwry.md5
28 changes: 28 additions & 0 deletions .project
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>ss-panel-v3-mod_UIChanges</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>com.aptana.ide.core.unifiedBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>com.aptana.projects.webnature</nature>
</natures>
<filteredResources>
<filter>
<id>1522297588605</id>
<name></name>
<type>26</type>
<matcher>
<id>org.eclipse.ui.ide.multiFilter</id>
<arguments>1.0-name-matches-false-false-node_modules</arguments>
</matcher>
</filter>
</filteredResources>
</projectDescription>
26 changes: 0 additions & 26 deletions 404.html

This file was deleted.

7 changes: 3 additions & 4 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)
MIT License

Copyright (c) 2015 orvice
Copyright (c) 2018 NimaQu

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand All @@ -18,5 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

SOFTWARE.
101 changes: 88 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,97 @@
# 歡迎使用SS-panel-modV3再次修改版
# 欢迎使用ss panel v3 mod 再次修改版


**ss-panel-v3-mod**是一款專為shadowsocks設計的web前端面板,再次感謝ss-panel-v3mod的工作人員,修改后的功能簡介:

- **f2f當面付** :支付寶二維碼接入
- **UI** :修改了圓角、并自定義了幾個標籤模板的顯示
- **節點** :增加了等級0不可見等級1節點,增加了國家圖標顯示
**ss-panel-v3-mod**是一款专为shadowsocks设计的web前端面板,再次感谢ss-panel-v3-mod 的制作者,修改后的功能简介:

-------------------
- **支付系统集成**:集成 支付宝当面付 黛米付 易付通 码支付等多种支付系统,使用方法见项目[wiki](https://github.com/NimaQu/ss-panel-v3-mod_Uim/wiki/)
- **UI** :修改为 ~~援交~~ 圆角、并自定义了几个图标的显示,节点列表等級0可见等級1节点但无法看见节点详情,增加了国家图标显示
- **商店**:商品增加同时连接设备数,用户限速属性
- 从肥羊那里****来的:新用户注册现金奖励|高等级节点体验|设备数量限制
- **优化**:css和js等置入本地提升加载速度
- 增加**v2Ray** 功能,详情请看 [wiki](https://github.com/NimaQu/ss-panel-v3-mod_Uim/wiki/V2Ray-%E5%AF%B9%E6%8E%A5%E6%95%99%E7%A8%8B)

模板在線查看:www.qianbx.com
telegram交流群:https://t.me/joinchat/GQehSEV7LEU1Z6E8aQ4z3w

-------------------
telegtam 频道 :https://t.me/sspanel_Uim 管理模式参考91yun管理

使用tips:
演示站: [demo.nimaqu.com](https://demo.nimaqu.com) 账号/密码:admin mukey=NimaQu

1、替換您自己的.config.php文件
**原作者** [galaxychuck](https://github.com/galaxychuck)

2、修改默認的站點名稱,包括主題文件
[支持开发者请点我](https://github.com/NimaQu/ss-panel-v3-mod_UIM#%E5%85%B3%E4%BA%8E%E6%8D%90%E8%B5%A0)

3、如果您有任何問題,概不接受任何質疑、Wiki製作、Issuse...等等
本面板在[宝塔面板5.6.0](www.bt.cn),宝塔安装版 nginx1.12,php 7.1 ,mysql 5.7 上全部功能测试通过

## 搭建教程

感谢LALA制作教程:https://lala.im/2398.html

GitHub Wiki : https://github.com/NimaQu/ss-panel-v3-mod_Uim/wiki/%E5%89%8D%E7%AB%AF%E5%AE%89%E8%A3%85

Wiki已经启用,欢迎为此面板维护wiki

#### 鸣谢

##### [galaxychuck](https://github.com/galaxychuck)

- 面板**原作者**

##### [dumplin](https://github.com/dumplin233)

- 码支付对接 + 码支付当面付二合一
- 为面板加入 AFF 链接功能
- 商品增加限速和限制 ip 属性
- 多端口订阅
- 解决用户列表加载缓慢历史遗留问题

##### [RinSAMA](https://github.com/mxihan)

- 整理分类 config.php
- 美观性调整
- 客服系统优化

##### [miku](https://github.com/xcxnig)

- 美观和性能优化

##### [Tony Zou](https://github.com/ZJY2003)

- 为公告增加群发邮件功能
- 节点负载情况显示&用户账户过期在首页弹窗提醒
- 增加返利列表

[**indexyz**](https://github.com/Indexyz)

- 为面板增加 v2Ray 功能

[**NeverBehave**](https://github.com/NeverBehave)

- 添加 Telegram OAuth

##### 还有所有被引用过代码的同学,以及所有提交过issue的同学。

#### 关于捐赠

您对我们的帮助将是支持我们做下去的动力,只需您在购买部分产品或向他人推荐产品时从我们的返利链接购买,这就是对我们很大的支持了。~~没有钱了,肯定要做啊,不做没有钱用啊,打工是不可能打工的,这辈子不可能打工的~~

##### dumplin

- [码支付-微信收款功能开通](https://codepay.fateqq.com/i/39756)


##### NimaQu


- [魔方云 - 低成本极速高效 专属您的私有云](https://www.cubecloud.net/aff.php?aff=796)


##### galaxychuck

- [黛米付-支付接入](https://www.daimiyun.cn/register.php?aff=624)
- [冲上云霄云主机](http://console.soar-clouds.com/aff.php?aff=94)


##### Miku


- [qazCloud | 高速云端数据传输服务](https://www.qaz.cloud)
28 changes: 16 additions & 12 deletions app/Command/Job.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public static function backup()
system('mysqldump --user='.Config::get('db_username').' --password='.Config::get('db_password').' --host='.$db_address_array[0].' '.(isset($db_address_array[1])?'-P '.$db_address_array[1]:'').' '.Config::get('db_database').' announcement auto blockip bought code coupon disconnect_ip link login_ip payback radius_ban shop speedtest ss_invite_code ss_node ss_password_reset ticket unblockip user user_token email_verify detect_list relay paylist> /tmp/ssmodbackup/mod.sql', $ret);


system('mysqldump --opt --user='.Config::get('db_username').' --password='.Config::get('db_password').' --host='.$db_address_array[0].' '.(isset($db_address_array[1])?'-P '.$db_address_array[1]:'').' -d '.Config::get('db_database').' alive_ip ss_node_info ss_node_online_log user_traffic_log detect_log telegram_session >> /tmp/ssmodbackup/mod.sql', $ret);
system('mysqldump --opt --user='.Config::get('db_username').' --password='.Config::get('db_password').' --host='.$db_address_array[0].' '.(isset($db_address_array[1])?'-P '.$db_address_array[1]:'').' -d '.Config::get('db_database').' alive_ip ss_node_info ss_node_online_log user_traffic_log detect_log telegram_session yft_order_info >> /tmp/ssmodbackup/mod.sql', $ret);

if (Config::get('enable_radius')=='true') {
$db_address_array = explode(':', Config::get('radius_db_host'));
Expand Down Expand Up @@ -142,6 +142,7 @@ public static function DailyJob()
DetectLog::where("datetime", "<", time()-86400*3)->delete();
Speedtest::where("datetime", "<", time()-86400*3)->delete();
EmailVerify::where("expire_in", "<", time()-86400*3)->delete();
system("rm ".BASE_PATH."/storage/*.png", $ret);
Telegram::Send("姐姐姐姐,数据库被清理了,感觉身体被掏空了呢~");

//auto reset
Expand Down Expand Up @@ -220,7 +221,7 @@ public static function DailyJob()

#https://github.com/shuax/QQWryUpdate/blob/master/update.php

$copywrite = file_get_contents("https://github.com/esdeathlove/qqwry-download/raw/master/copywrite.rar");
$copywrite = file_get_contents("http://update.cz88.net/ip/copywrite.rar");

$adminUser = User::where("is_admin", "=", "1")->get();

Expand All @@ -229,7 +230,7 @@ public static function DailyJob()

if ($newmd5 != $oldmd5) {
file_put_contents(BASE_PATH."/storage/qqwry.md5", $newmd5);
$qqwry = file_get_contents("https://github.com/esdeathlove/qqwry-download/raw/master/qqwry.rar");
$qqwry = file_get_contents("http://update.cz88.net/ip/qqwry.rar");
if ($qqwry != "") {
$key = unpack("V6", $copywrite)[6];
for ($i=0; $i<0x200; $i++) {
Expand Down Expand Up @@ -263,13 +264,14 @@ public static function DailyJob()
}

Job::updatedownload();

}
// 定时任务开启的情况下,每天自动检测有没有最新版的后端,github源来自Miku
public static function updatedownload()
{
system('cd '.BASE_PATH."/public/ssr-download/ && git pull https://github.com/xcxnig/ssr-download.git");
}

public static function updatedownload()
{
system('cd '.BASE_PATH."/public/ssr-download/ && git pull", $ret);
echo $ret;
}

public static function CheckJob()
{
Expand Down Expand Up @@ -438,7 +440,7 @@ public static function CheckJob()

$adminUser = User::where("is_admin", "=", "1")->get();

$latest_content = file_get_contents("https://github.com/esdeathlove/ss-panel-v3-mod/raw/new_master/bootstrap.php");
$latest_content = file_get_contents("https://raw.githubusercontent.com/NimaQu/ss-panel-v3-mod_uim/master/bootstrap.php");
$newmd5 = md5($latest_content);
$oldmd5 = md5(file_get_contents(BASE_PATH."/bootstrap.php"));

Expand All @@ -453,7 +455,7 @@ public static function CheckJob()
echo "Send mail to user: ".$user->id;
$subject = Config::get('appName')."-系统提示";
$to = $user->email;
$text = "管理员您好,系统发现有了新版本,您可以到 <a href=\"https://github.com/esdeathlove/ss-panel-v3-mod/wiki/%E6%9B%B4%E6%96%B0%E6%97%A5%E5%BF%97\">https://github.com/esdeathlove/ss-panel-v3-mod/wiki/%E6%9B%B4%E6%96%B0%E6%97%A5%E5%BF%97</a> 按照步骤进行升级。" ;
$text = "管理员您好,系统发现有了新版本,您可以到 <a href=\"https://github.com/NimaQu/ss-panel-v3-mod_Uim/wiki/%E5%8D%87%E7%B4%9A%E7%89%88%E6%9C%AC\">https://github.com/NimaQu/ss-panel-v3-mod_Uim/wiki/%E5%8D%87%E7%B4%9A%E7%89%88%E6%9C%AC</a> 按照步骤进行升级。" ;
try {
Mail::send($to, $subject, 'news/warn.tpl', [
"user" => $user,"text" => $text
Expand Down Expand Up @@ -699,7 +701,8 @@ function ($query) use ($node) {



if ((int)Config::get('enable_auto_clean_uncheck_days')!=0 && max($user->last_check_in_time, strtotime($user->reg_date)) + ((int)Config::get('enable_auto_clean_uncheck_days')*86400) < time() && $user->class == 0) {
if ((int)Config::get('enable_auto_clean_uncheck_days')!=0 && max($user->last_check_in_time, strtotime($user->reg_date)) + ((int)Config::get('enable_auto_clean_uncheck_days')*86400) < time() && $user->class == 0 && $user->money <= (int)Config::get('auto_clean_min_money')) {

if (Config::get('enable_auto_clean_uncheck')=='true') {
$subject = Config::get('appName')."-您的用户账户已经被删除了";
$to = $user->email;
Expand Down Expand Up @@ -727,7 +730,8 @@ function ($query) use ($node) {
}


if ((int)Config::get('enable_auto_clean_unused_days')!=0 && max($user->t, strtotime($user->reg_date)) + ((int)Config::get('enable_auto_clean_unused_days')*86400) < time() && $user->class == 0) {
if ((int)Config::get('enable_auto_clean_unused_days')!=0 && max($user->t, strtotime($user->reg_date)) + ((int)Config::get('enable_auto_clean_unused_days')*86400) < time() && $user->class == 0 && $user->money <= (int)Config::get('auto_clean_min_money')) {

if (Config::get('enable_auto_clean_unused')=='true') {
$subject = Config::get('appName')."-您的用户账户已经被删除了";
$to = $user->email;
Expand Down
Loading

0 comments on commit d983df0

Please sign in to comment.