作者 郭鑫

111

... ... @@ -49,6 +49,9 @@ class IndexController extends CommonController
$final['banner'] = Db::name('Banner')->where($where_banner)
->field("pic")
->order("score desc,create_time desc")->select()->toArray();
foreach ($final['banner'] as $bannerk=>$bannerv){
$final['banner'][$bannerk]['pic'] = cmf_get_image_url($bannerv['pic']);
}
// 2.交易流程
$where_process['status'] = 1;
$where_process['type'] = $request->param('type');
... ... @@ -63,6 +66,14 @@ class IndexController extends CommonController
// 4. 合作企业
$where_coo['status'] = 1;
$final['coop'] = Db::name('Cooperation')->where($where_coo)->order("score desc , create_time desc")->field('pic,jump')->select()->toArray();
foreach ($final['coop'] as $coopk=>$coopv){
if(empty($member['pic'])){
$pic = "../themes/simpleboot3/public/assets/images/house.jpg";
}else{
$pic = $coopv['pic'];
}
$final['coop'][$coopk]['pic'] = cmf_get_image_url($pic);
}
// 5. 文章
$where_cate['c.delete_time'] = 0;
$where_cate['c.status'] = 1;
... ... @@ -124,48 +135,48 @@ class IndexController extends CommonController
$this->apiResponse('1','成功',$final);
}
public function a(){
// 推荐人处理
if(!empty($getParam['parent_id'])){
$where_parentAdd['id'] = $getParam['parent_id'];
$where_parentAdd['type'] = 2;
$where_reward['type'] = 2;
$where_reward['status'] = 1;
$reward = Db::name('Reward')->where($where_reward)->order('create_time')->field('number')->find();
if($reward){
$add_agencyScore = $user->where($where_parentAdd)->setInc('reputation',$reward['number']);
if(!$add_agencyScore){
$this->apiResponse('0','推荐奖励增加失败');
}else{
// 推荐记录表
$add_log['type'] = 2;
$add_log['number'] = $reward['number'];
$add_log['referee'] = $getParam['parent_id'];
$add_log['recommen'] = $uid;
$add_log['create_time'] = time();
$add_log['update_time'] = time();
$log = Db::name('RewardLog')->insertGetId($add_log);
if(!$log){
Db::rollback();
}
// 信誉记录表
$add_startlog['detail'] = "推荐".$getParam['parent'].'注册';
$add_startlog['star'] = $reward['number'];
$add_startlog['type'] = 3;
$add_startlog['create_time'] = time();
$add_startlog['update_time'] = time();
$startLog = Db::name('StartDetail')->insertGetId($add_startlog);
if(!$startLog){
Db::rollback();
}
}
}else{
Db::rollback();
$this->apiResponse('0','推荐奖励获取失败');
}
}
// end
}
// public function a(){
// // 推荐人处理
// if(!empty($getParam['parent_id'])){
// $where_parentAdd['id'] = $getParam['parent_id'];
// $where_parentAdd['type'] = 2;
// $where_reward['type'] = 2;
// $where_reward['status'] = 1;
// $reward = Db::name('Reward')->where($where_reward)->order('create_time')->field('number')->find();
// if($reward){
// $add_agencyScore = $user->where($where_parentAdd)->setInc('reputation',$reward['number']);
// if(!$add_agencyScore){
// $this->apiResponse('0','推荐奖励增加失败');
// }else{
//// 推荐记录表
// $add_log['type'] = 2;
// $add_log['number'] = $reward['number'];
// $add_log['referee'] = $getParam['parent_id'];
// $add_log['recommen'] = $uid;
// $add_log['create_time'] = time();
// $add_log['update_time'] = time();
// $log = Db::name('RewardLog')->insertGetId($add_log);
// if(!$log){
// Db::rollback();
// }
//// 信誉记录表
// $add_startlog['detail'] = "推荐".$getParam['parent'].'注册';
// $add_startlog['star'] = $reward['number'];
// $add_startlog['type'] = 3;
// $add_startlog['create_time'] = time();
// $add_startlog['update_time'] = time();
// $startLog = Db::name('StartDetail')->insertGetId($add_startlog);
// if(!$startLog){
// Db::rollback();
// }
// }
// }else{
// Db::rollback();
// $this->apiResponse('0','推荐奖励获取失败');
// }
// }
//// end
// }
}
... ...
... ... @@ -134,6 +134,10 @@ class IntermediaryController extends CommonController
$member = Db::name('Member')->where($where_member)->field('name,id,start,reputation,company,store,quarters,tel,city,pic,money,get_money,referee_tel')->find();
if(!$member){
$this->apiResponse('0','用户信息错误');
}else{
if(empty($member['pic'])){
$member['pic'] = "../themes/simpleboot3/public/assets/images/pic.png";
}
}
// 查询签到信息
$member['pic'] = cmf_get_image_url($member['pic']);
... ...
... ... @@ -23,7 +23,7 @@ use think\Url;
use SmsDemo;
//use think\Route;
/**
* @title 30分钟后发布
* @title 订单修改
* @description 接口说明
* @group 接口分组
*/
... ... @@ -37,7 +37,27 @@ class ThirdsendController extends HomeBaseController
$this->postModel = $postModel;
}
// 查询中介报价
/**
* API返回信息格式函数 ;0失败,1成功,-1需要登录
* @param string $code
* @param string $message
* @param array $data
*/
public function apiResponse($code = '0', $message = '',$data = array(),$nums =0){
header('Access-Control-Allow-Origin: *');
header('Content-Type:application/json; charset=utf-8');
$result = array(
'code'=>$code,
'message'=>$message,
'data'=>$data,
'nums'=>''.$nums
);
die(json_encode($result,JSON_UNESCAPED_UNICODE));
}
// 查询中介报价(暂未用)
// $need_id 需求id
public function Offer($user_id,$need_id){
$where_agency['status'] = 2;
... ... @@ -75,6 +95,478 @@ class ThirdsendController extends HomeBaseController
}
}
public function isLogin($token){
$where_member['token'] = $token;
// $where_member['status'] = 1;
$member = Db::name('Member')->where($where_member)->field('id,status')->find();
if($member){
if($member['status'] == 9){
$this->apiResponse('0','您已被拉入黑名单');
}else{
return $member;
}
}else{
$this->apiResponse('-1','请重新登录');
}
}
/**
* @title 30分钟后发布(sure)(时间为0时调用)
* @description 接口说明
* @author 开发者
* @url /api/portal/Thirdsend/thirdChange
* @method POST
* @param name:token type:int require:1 default: other: desc:token
* @param name:need_id type:int require:1 default: other: desc:需求id
*/
// 30分钟后发布(sure)(时间为0时调用)
// need_id 需求id
public function thirdChange(){
Db::startTrans();
$data = $this->request->param();
$this->isLogin($data['token']);
if(empty($data['need_id'])){
$this->apiResponse('0','需求id不能为空');
}
$where_need['status'] = 2;
$where_need['id'] = $data['need_id'];
$userNeedList = Db::name('UserNeed')->where($where_need)->field('id,pay_time')->find();
$time = time();
if($time < $userNeedList['pay_time']+1800){
$this->apiResponse('0','未到发布时间');
}else{
$where_save['id'] = $data['need_id'];
$save['status'] = 3;
$save['update_time'] = time();
$fianl_save = Db::name('UserNeed')->where($where_save)->update($save);
if($fianl_save){
Db::commit();
$where_return['id'] = $data['need_id'];
$return = Db::name('UserNeed')->where($where_return)->find();
$this->apiResponse('1','成功',$return);
}else{
Db::rollback();
$this->apiResponse('0','失败');
}
}
}
/**
* @title 规定时间结束报价(sure)(时间为0时调用)
* @description 接口说明
* @author 开发者
* @url /api/portal/Thirdsend/timeOver
* @method POST
* @param name:token type:int require:1 default: other: desc:token
* @param name:need_id type:int require:1 default: other: desc:需求id
*/
// 规定时间结束报价(sure)(时间为0时调用)
// need_id 需求id
public function timeOver()
{
Db::startTrans();
$data = $this->request->param();
$this->isLogin($data['token']);
if(empty($data['need_id'])){
$this->apiResponse('0','需求id不能为空');
}
// 查询用户发布需求信息
$where_need['status'] = 3;
$where_need['id'] = $data['need_id'];
$userNeedList = Db::name('UserNeed')->where($where_need)->field('id,quotation_time,create_time,pay_time,user_id,pay_money')->find();
if(!$userNeedList){
$this->apiResponse('0','需求状态不正确');
}
$time = time();
// 查询相应报价
$final_time = $userNeedList['pay_time'] + $userNeedList['quotation_time'] * 86400;
// 判断时间是否正确
if ($time >= $final_time) {
// $us_middleid = $uNeedv['id'];
$where_agency['a.status'] = 2;
$where_agency['a.pay_time'] = array('lt', time());
$where_agency['a.need_id'] = $userNeedList['id'];
$where_agency['m.type'] = 2;
$where_agency['m.status'] = 1;
$agency_list = Db::name('Agency')->alias('a')
->where($where_agency)
->join("hp_Member m", 'm.id = a.agency_id')
->field('a.*,m.company')
->select()->toArray();
// 查询品牌企业
$where_brand['status'] = 1;
$band_list = Db::name('Brand')->where($where_brand)->column('name');
$agen_arr = array();
if ($agency_list) {
// 删除十万以内报价
foreach ($agency_list as $tenk=>$tenv){
$ten_money = $tenv['housing_price'] * 10000 + $tenv['assessment_tax'] + $tenv['security_tax'] + $tenv['else_tax'] + $tenv['service_charge'];
if($ten_money > 1000000){
$is_trueMoney[] = $tenv;
}
}
// 判断是否超过三个报价人
if (count($is_trueMoney) >= 3) {
// 查询三人中是否有品牌中介
// 循环匹配品牌企业
foreach ($is_trueMoney as $agencyk => $agencyv) {
foreach ($band_list as $brak => $brav) {
// 判断是否在品牌企业中
if (strstr($brav, $agencyv['company']) !== false) {
// 存在
$agen_money = $agencyv['housing_price'] * 10000 + $agencyv['assessment_tax'] + $agencyv['security_tax'] + $agencyv['else_tax'] + $agencyv['service_charge'];
if (empty($agen_arr)) {
$agen_arr[0]['money'] = $agen_money;
$agen_arr[0]['id'] = $agencyv['id'];
} else {
// 判断大小
if ($agen_money < $agen_arr[0]['money']) {
$agen_arr[0]['money'] = $agen_money;
$agen_arr[0]['id'] = $agencyv['id'];
}
}
}
}
// 取出前三报价
$money = $agencyv['housing_price'] * 10000 + $agencyv['assessment_tax'] + $agencyv['security_tax'] + $agencyv['else_tax'] + $agencyv['service_charge'];
$money_list[$agencyv['id']] = $money;
}
asort($money_list);
$k = 0;
foreach ($money_list as $mok => $mov) {
$else_changeList[] = $mok;
if ($k < 3) {
$fin_list[$k]['id'] = $mok;
$fin_list[$k]['money'] = $mov;
$fin_arr[] = $mok;
}
$k += 1;
}
if($agen_arr){
if(!in_array($agen_arr[0]['id'],$fin_arr)){
// 品牌中介不在取出三个最低价中
$middle_agen[0] = $agen_arr[0]['id'];
$get_list = array_merge($fin_arr,$middle_agen);
}else{
$get_list = $fin_arr;
}
}
foreach ($else_changeList as $getk=>$getv){
if(in_array($getv,$get_list)){
$change_final['id'] = $getv;
$change_final['status'] = 4;
}else{
$change_final['id'] = $getv;
$change_final['status'] = 3;
}
$agencyModel = new AgencyModel();
$fianl_AgsaveFirst = $agencyModel->isUpdate(true)->save($change_final);
if(!$fianl_AgsaveFirst){
Db::rollback();
}
}
// 报价成功,更改状态
$userSave_statusFirst['id'] = $userNeedList['need_id'];
$userSave_statusFirst['status'] = 5;
$userSave_statusFirst['choose_time'] = time();
$userNeedModel = new UserNeedModel();
$fianl_Ussave = $userNeedModel->isUpdate(true)->save($userSave_statusFirst);
if(!$fianl_Ussave){
Db::rollback();
}
} else {
// 报价小于3人,更改订单状态,报价失败
foreach ($agency_list as $changeka=>$changeva){
$change_final['id'] = $changeva['id'];
$change_final['status'] = 7;
$agencyModel = new AgencyModel();
$fianl_AgsaveNext = $agencyModel->isUpdate(true)->save($change_final);
if(!$fianl_AgsaveNext){
Db::rollback();
}
// 退回中介保证金
$add_a['user_id'] = $changeva['agency_id'];
$add_a['title'] = '报价人数不足';
$add_a['type'] = 1;
$add_a['reason'] = 1;
$add_a['money'] = $changeva['deposit'];
$add_a['create_time'] = time();
$add_a['update_time'] = time();
$amoney_id = Db::name('AmoenyDetail')->insertGetId($add_a);
if (!$amoney_id) {
Db::rollback();
}
// 用户表增加金额
$where_member['type'] = 2;
$where_member['id'] = $changeva['agency_id'];
$add_money = Db::name('Member')->where($where_member)->setInc('money',$changeva['deposit']);
if (!$add_money) {
Db::rollback();
}
}
$userSave_status['id'] = $userNeedList['id'];
$userSave_status['status'] = 4;
$userNeedModel = new UserNeedModel();
$fianl_Ussave = $userNeedModel->isUpdate(true)->save($userSave_status);
if(!$fianl_Ussave){
Db::rollback();
}
// 退回保证金
// 用户
// 加用户金额明细表
$add_del['need_id'] = $userNeedList['id'];
$add_del['user_id'] = $userNeedList['user_id'];
$add_del['title'] = '报价人数不足';
$add_del['reason'] = 1;
$add_del['type'] = 1;
$add_del['money'] = $userNeedList['pay_money'];
$add_del['create_time'] = time();
$add_del['update_time'] = time();
$umoney_id = Db::name('UmoenyDetail')->insertGetId($add_del);
if (!$umoney_id) {
Db::rollback();
}
$where_memberNext['type'] = 1;
$where_memberNext['id'] = $userNeedList['user_id'];
$add_moneyNext = Db::name('Member')->where($where_memberNext)->setInc('money',$userNeedList['pay_money']);
if (!$add_moneyNext) {
Db::rollback();
}
}
} else {
// 没有报价
$userSave_status['id'] = $userNeedList['id'];
$userSave_status['status'] = 4;
$userNeedModel = new UserNeedModel();
$fianl_Ussave = $userNeedModel->isUpdate(true)->save($userSave_status);
if(!$fianl_Ussave){
Db::rollback();
}
// 退回保证金
// 用户
// 加用户金额明细表
$add_del['need_id'] = $userNeedList['id'];
$add_del['user_id'] = $userNeedList['user_id'];
$add_del['title'] = '报价人数不足';
$add_del['type'] = 1;
$add_del['money'] = $userNeedList['pay_money'];
$add_del['create_time'] = time();
$add_del['update_time'] = time();
$umoney_id = Db::name('UmoenyDetail')->insertGetId($add_del);
if (!$umoney_id) {
Db::rollback();
$this->apiResponse('0','金额明细添加失败');
}
$where_memberNext['type'] = 1;
$where_memberNext['id'] = $userNeedList['user_id'];
$add_moneyNext = Db::name('Member')->where($where_memberNext)->setInc('money',$userNeedList['pay_money']);
if (!$add_moneyNext) {
Db::rollback();
}
}
// 插入数据库
// 用户需求表
// 中介报价表
Db::commit();
$where_return['id'] = $data['need_id'];
$return = Db::name('UserNeed')->where($where_return)->find();
$this->apiResponse('1','成功',$return);
}else{
$this->apiResponse('0','时间不正确');
}
// }
}
/**
* @title 三天用户选择(sure)(时间为0时调用)
* @description 接口说明
* @author 开发者
* @url /api/portal/Thirdsend/choose
* @method POST
* @param name:token type:int require:1 default: other: desc:token
* @param name:need_id type:int require:1 default: other: desc:需求id
*/
// 三天用户选择(sure)(时间为0时调用)
// need_id 需求id
public function choose(){
Db::startTrans();
$data = $this->request->param();
$this->isLogin($data['token']);
if(empty($data['need_id'])){
$this->apiResponse('0','需求id不能为空');
}
// 查询用户发布需求信息
$where_need['status'] = 5;
$where_need['id'] = $data['need_id'];
$userNeedList = Db::name('UserNeed')->where($where_need)->field('id,choose_time,user_id,pay_money,choose_time')->find();
if($userNeedList){
// foreach ($userNeedList as $needk=>$needv) {
if (time() >= ($userNeedList['choose_time'] + 259200)) {
$where_agency['need_id'] = $userNeedList['id'];
$where_agency['status'] = 4;
$agency_list = Db::name('Agency')->where($where_agency)->select()->toArray();
if ($agency_list) {
$where_agencyUpdate['need_id'] = $userNeedList['id'];
$where_agencyUpdate['status'] = 4;
$agency_save['status'] = 8;
$agency_save['update_time'] = time();
$agency_result = Db::name('Agency')->where($where_agencyUpdate)->update($agency_save);
if (!$agency_result) {
Db::rollback();
}
}
$where_needUpdate['id'] = $userNeedList['id'];
$needUpdate['status'] = 6;
$need_result = Db::name('UserNeed')->where($where_needUpdate)->update($needUpdate);
if (!$need_result) {
Db::rollback();
} else {
// 加用户金额明细表
$add_del['need_id'] = $userNeedList['id'];
$add_del['user_id'] = $userNeedList['user_id'];
$add_del['title'] = '未选择中介';
$add_del['type'] = 2;
$add_del['money'] = $userNeedList['pay_money'];
$add_del['create_time'] = time();
$add_del['update_time'] = time();
$umoney_id = Db::name('UmoenyDetail')->insertGetId($add_del);
if (!$umoney_id) {
Db::rollback();
}
// 中介金额明细表
foreach ($agency_list as $agenk=>$agenv){
$add_a['ag_id'] = $agenv['id'];
$add_a['user_id'] = $agenv['agency_id'];
$add_a['title'] = '用户未选择中介';
$add_a['type'] = 1;
$add_a['money'] = $agenv['deposit'];
$add_a['create_time'] = time();
$add_a['update_time'] = time();
$amoney_id = Db::name('AmoenyDetail')->insertGetId($add_a);
if (!$amoney_id) {
Db::rollback();
}
$where_member['type'] = 2;
$where_member['id'] = $agenv['agency_id'];
$add_money = Db::name('Member')->where($where_member)->setInc('money',$agenv['deposit']);
if (!$add_money) {
Db::rollback();
}
}
}
}
// }
Db::commit();
$where_return['id'] = $data['need_id'];
$return = Db::name('UserNeed')->where($where_return)->find();
$this->apiResponse('1','成功',$return);
}else{
$this->apiResponse('0','需求错误');
}
}
/**
* @title 三天中介确认(时间为0时调用)
* @description 接口说明
* @author 开发者
* @url /api/portal/Thirdsend/threeChoose
* @method POST
* @param name:token type:int require:1 default: other: desc:token
* @param name:need_id type:int require:1 default: other: desc:需求id
*/
// 三天中介确认(时间为0时调用)
// need_id 需求id
public function threeChoose(){
Db::startTrans();
$data = $this->request->param();
$this->isLogin($data['token']);
if(empty($data['need_id'])){
$this->apiResponse('0','需求id不能为空');
}
$where_need['status'] = 7;
$where_need['id'] = $data['need_id'];
$need_list = Db::name('UserNeed')->where($where_need)->field('id,choose_time')->find();
if($need_list){
// foreach ($need_list as $needk=>$needv){
if(time() >= ($need_list['choose_time']+259200)){
$where_agency['status'] = 5;
$where_agency['need_id'] = $need_list['id'];
$agency = Db::name('Agency')->where($where_agency)->find();
// 修改中介报价状态
if($agency){
$where_changeAgency['id'] = $agency['id'];
$changeAgency['status'] = 10;
$changeAgency['update_time'] = time();
$update_a = Db::name('Agency')->where($where_changeAgency)->update($changeAgency);
if(!$update_a){
Db::rollback();
}
}
// 增加中介保证金变化
$add_a['ag_id'] = $agency['id'];
$add_a['user_id'] = $agency['agency_id'];
$add_a['title'] = '中介未确认';
$add_a['type'] = 2;
$add_a['money'] = $agency['deposit'];
$add_a['create_time'] = time();
$add_a['update_time'] = time();
$amoney_id = Db::name('AmoenyDetail')->insertGetId($add_a);
if (!$amoney_id) {
Db::rollback();
}
// 修改用户需求状态
$where_needChange['id'] = $need_list['id'];
$update_need['status'] = 8;
$update_need['update_time'] = time();
$change_needFinal = Db::name('UserNeed')->where($where_needChange)->update($update_need);
if (!$change_needFinal) {
Db::rollback();
}
// 增加用户保证金,余额
$add_del['need_id'] = $need_list['id'];
$add_del['user_id'] = $need_list['user_id'];
$add_del['title'] = '中介未确认';
$add_del['type'] = 1;
$add_del['money'] = $need_list['pay_money'];
$add_del['create_time'] = time();
$add_del['update_time'] = time();
$umoney_id = Db::name('UmoenyDetail')->insertGetId($add_del);
if (!$umoney_id) {
Db::rollback();
}
$where_member['type'] = 1;
$where_member['id'] = $need_list['user_id'];
$add_money = Db::name('Member')->where($where_member)->setInc('money',$need_list['pay_money']);
if (!$add_money) {
Db::rollback();
}
}
// }
Db::commit();
$where_return['id'] = $data['need_id'];
$return = Db::name('UserNeed')->where($where_return)->find();
$this->apiResponse('1','成功',$return);
}else{
$this->apiResponse('0','需求错误');
}
}
// 30分钟后发布(sure)(分钟执行)
... ...
... ... @@ -1291,17 +1291,11 @@ class UserController extends CommonController
}else{
$this->apiResponse('0','投诉失败');
}
}else{
$this->apiResponse('0','当前状态不支持投诉');
}
$final['user'] = $member;
}
/**
... ... @@ -1398,7 +1392,6 @@ class UserController extends CommonController
}
// 短网址
function shot($url){
$jump = "http://suo.im/api.php?url=".$url;
... ... @@ -1407,4 +1400,7 @@ class UserController extends CommonController
}
}
... ...
<?php
// +----------------------------------------------------------------------
// | ThinkCMF [ WE CAN DO IT MORE SIMPLE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013-2018 http://www.thinkcmf.com All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Powerless < wzxaini9@gmail.com>
// +----------------------------------------------------------------------
namespace app\portal\controller;
use cmf\controller\AdminBaseController;
use think\Db;
use think\Loader;
use think\Request;
class ComplaintController extends AdminBaseController
{
// 提现申请
public function index(){
$data = $this->request->param();
if($data){
$startTime = empty($data['start_time']) ? 0 : strtotime($data['start_time']);
$endTime = empty($data['end_time']) ? 0 : strtotime($data['end_time']);
if ($startTime && $endTime) {
$where_money['d.create_time'] = array('between',"$startTime,$endTime");
$this->assign('start_time', $data['start_time']);
$this->assign('end_time', $data['end_time']);
}else{
if($startTime){
$where_money['d.create_time'] = array('egt',$startTime);
$this->assign('start_time', $data['start_time']);
}
if($endTime){
$where_money['d.create_time'] = array('elt',$endTime);
$this->assign('end_time', $data['end_time']);
}
}
if(!empty($data['name'])){
$where_money['name'] = array('like','%'.$data['name'].'%');
$this->assign('name', $data['name']);
}
if(!empty($data['tel'])){
$where_money['tel'] = array('like','%'.$data['tel'].'%');
$this->assign('tel', $data['tel']);
}
}
$where_money['c.status'] = array('neq',9);
$money_list = Db::name('Complaint')->alias('c')
->join("Member m",'m.id = c.user_id')
->where($where_money)
->field("m.name,m.tel,c.*")
->paginate();
$page = $money_list->render();
$this->assign('page',$page);
$this->assign('lists',$money_list);
return $this->fetch('getdetail');
}
// 同意投诉
public function agree(){
$data = $this->request->param();
$where_money['id'] = $data['id'];
$where_money['status'] = array('neq',9);
$money = Db::name('Complaint')->where($where_money)->find();
if($money){
$save['status'] = 2;
$save['update_time'] = time();
$update = Db::name('Complaint')->where($where_money)->update($save);
if($update){
$this->success('成功');
}else{
$this->error('失败');
}
}else{
$this->error('投诉状态不正确');
}
}
// 拒绝投诉
public function refuse(){
$data = $this->request->param();
$where_money['id'] = $data['id'];
$where_money['status'] = array('neq',9);
$money = Db::name('Complaint')->where($where_money)->find();
if($money){
$save['status'] = 3;
$save['update_time'] = time();
$update = Db::name('Complaint')->where($where_money)->update($save);
if($update){
$this->success('成功');
}else{
$this->error('失败');
}
}else{
$this->error('订单状态不正确');
}
}
/**
* 后台删除第三方用户绑定
* @adminMenu(
* 'name' => '删除第三方用户绑定',
* 'parent' => 'index',
* 'display'=> false,
* 'hasView'=> false,
* 'order' => 10000,
* 'icon' => '',
* 'remark' => '删除第三方用户绑定',
* 'param' => ''
* )
*/
public function delete()
{
$id = input('param.id', 0, 'intval');
if (empty($id)) {
$this->error('非法数据!');
}
Db::name("third_party_user")->where("id", $id)->delete();
$this->success("删除成功!", "admin_oauth/index");
}
}
\ No newline at end of file
... ...
... ... @@ -323,10 +323,49 @@ class AdminOauthController extends AdminBaseController
// 同意提现
public function agree(){
$data = $this->request->param();
$where_money['id'] = $data['id'];
$where_money['user_id'] = $data['uid'];
$where_money['order_type'] = 6;
$where_money['type'] = 3;
$where_money['status'] = array('neq',9);
$money = Db::name('MoneyDetail')->where($where_money)->find();
if($money){
$save['status'] = 3;
$save['update_time'] = time();
$update = Db::name('MoneyDetail')->where($where_money)->update($save);
if($update){
$this->success('成功');
}else{
$this->error('失败');
}
}else{
$this->error('订单状态不正确');
}
}
// 拒绝提现
public function refuse(){
$data = $this->request->param();
$where_money['id'] = $data['id'];
$where_money['user_id'] = $data['uid'];
$where_money['order_type'] = 6;
$where_money['type'] = 3;
$where_money['status'] = array('neq',9);
$money = Db::name('MoneyDetail')->where($where_money)->find();
if($money){
$save['status'] = 4;
$save['update_time'] = time();
$update = Db::name('MoneyDetail')->where($where_money)->update($save);
if($update){
$this->success('成功');
}else{
$this->error('失败');
}
}else{
$this->error('订单状态不正确');
}
}
// 提现
... ... @@ -399,6 +438,80 @@ class AdminOauthController extends AdminBaseController
// 渲染模板输出
return $this->fetch();
}
// 中介详细信息
public function agencyDetail(){
$data = $this->request->param();
if(empty($data['id'])){
$this->error("用户id不能为空");
}else{
$where_member['id'] = $data['id'];
$member = Db::name('Member')->where($where_member)->find();
if($member){
$quarters = explode('+',$member['quarters']);
$member['quarters'] = implode(' ; ',$quarters);
}
$this->assign('list',$member);
return $this->fetch();
}
}
// 修改中介信息
public function changeAgency(){
$data = $this->request->param();
if($data){
// 验证
$validate = Loader::validate('Member');
if (!$validate->scene('change')->check($data)) {
// return json(array('code' => 0, 'msg' => $validate->getError()));
$this->error($validate->getError());
}
// 更新数据
$where_update['id'] = $data['id'];
$save = $data;
$save['login_time'] = strtotime($save['login_time']);
$save['last_login_time'] = strtotime($save['last_login_time']);
$save['create_time'] = strtotime($save['create_time']);
$member_change = Db::name('Member')->where($where_update)->update($save);
if($member_change){
$this->success('修改成功',url('intermediary'));
}else{
$this->error('修改失败');
}
}
}
// 中介评价
public function comment(){
$data = $this->request->param();
$where_comment['intermediary_id'] = $data['id'];
$where_comment['status'] = 1;
$comment_list = Db::name('Comment')->where($where_comment)->select();
$this->assign('uid',$data['id']);
$this->assign('lists',$comment_list);
return $this->fetch();
}
// 删除中介评价
public function agencyDel(){
$data = $this->request->param();
$where_com['id'] = $data['id'];
$where_com['status'] = array('neq',9);
$complaint = Db::name('Comment')->where($where_com)->find();
if($complaint){
$save['status'] = 9;
$save['update_time'] = time();
$update = Db::name('Comment')->where($where_com)->update($save);
if($update){
$this->success('删除成功');
}else{
$this->error('删除失败');
}
}else{
$this->error('评论状态错误');
}
}
/**
* 后台删除第三方用户绑定
* @adminMenu(
... ... @@ -421,6 +534,7 @@ class AdminOauthController extends AdminBaseController
Db::name("third_party_user")->where("id", $id)->delete();
$this->success("删除成功!", "admin_oauth/index");
}
// 加入黑名单
public function del(Request $request)
{
... ... @@ -439,7 +553,6 @@ class AdminOauthController extends AdminBaseController
}
}
// 黑名单列表
public function black(Request $request)
{
... ...
<?php
// +----------------------------------------------------------------------
// | ThinkCMF [ WE CAN DO IT MORE SIMPLE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013-2018 http://www.thinkcmf.com All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Powerless < wzxaini9@gmail.com>
// +----------------------------------------------------------------------
namespace app\user\controller;
use cmf\controller\AdminBaseController;
use think\Db;
use think\Loader;
use think\Request;
class GetmoneyController extends AdminBaseController
{
// 提现申请
public function index(){
$data = $this->request->param();
if($data){
$startTime = empty($data['start_time']) ? 0 : strtotime($data['start_time']);
$endTime = empty($data['end_time']) ? 0 : strtotime($data['end_time']);
if ($startTime && $endTime) {
$where_money['d.create_time'] = array('between',"$startTime,$endTime");
$this->assign('start_time', $data['start_time']);
$this->assign('end_time', $data['end_time']);
}else{
if($startTime){
$where_money['d.create_time'] = array('egt',$startTime);
$this->assign('start_time', $data['start_time']);
}
if($endTime){
$where_money['d.create_time'] = array('elt',$endTime);
$this->assign('end_time', $data['end_time']);
}
}
if(!empty($data['name'])){
$where_money['name'] = array('like','%'.$data['name'].'%');
$this->assign('name', $data['name']);
}
if(!empty($data['tel'])){
$where_money['tel'] = array('like','%'.$data['tel'].'%');
$this->assign('tel', $data['tel']);
}
}
// $where_money['user_id'] = $data['id'];
$where_money['d.order_type'] = 6;
$where_money['d.type'] = 3;
$where_money['d.status'] = array('neq',9);
$money_list = Db::name('MoneyDetail')->alias('d')
->join("Member m",'m.id = d.user_id')
->where($where_money)
->field("m.name,m.tel,m.type,d.money,d.status,d.id,d.create_time")
->select();
// $this->assign('uid',$data['id']);
$this->assign('lists',$money_list);
return $this->fetch('getdetail');
}
// 同意提现
public function agree(){
$data = $this->request->param();
$where_money['id'] = $data['id'];
// $where_money['user_id'] = $data['uid'];
$where_money['order_type'] = 6;
$where_money['type'] = 3;
$where_money['status'] = array('neq',9);
$money = Db::name('MoneyDetail')->where($where_money)->find();
if($money){
$save['status'] = 3;
$save['update_time'] = time();
$update = Db::name('MoneyDetail')->where($where_money)->update($save);
if($update){
$this->success('成功');
}else{
$this->error('失败');
}
}else{
$this->error('订单状态不正确');
}
}
// 拒绝提现
public function refuse(){
$data = $this->request->param();
$where_money['id'] = $data['id'];
// $where_money['user_id'] = $data['uid'];
$where_money['order_type'] = 6;
$where_money['type'] = 3;
$where_money['status'] = array('neq',9);
$money = Db::name('MoneyDetail')->where($where_money)->find();
if($money){
$save['status'] = 4;
$save['update_time'] = time();
$update = Db::name('MoneyDetail')->where($where_money)->update($save);
if($update){
$this->success('成功');
}else{
$this->error('失败');
}
}else{
$this->error('订单状态不正确');
}
}
// 提现
public function getmoney(){
$data = $this->request->param();
$where_member['id'] = $data['id'];
$member = Db::name('Member')->where($where_member)->field('id,name,tel')->find();
if($member){
$where_money['user_id'] = $member['id'];
$where_money['user_type'] = 1;
$where_money['order_type'] = 6;
$detail = Db::name('MoneyDetail')->where($where_money)->select()->toArray();
$this->assign('lists',$detail);
}else{
$this->error('用户信息获取失败');
}
}
/**
* 后台删除第三方用户绑定
* @adminMenu(
* 'name' => '删除第三方用户绑定',
* 'parent' => 'index',
* 'display'=> false,
* 'hasView'=> false,
* 'order' => 10000,
* 'icon' => '',
* 'remark' => '删除第三方用户绑定',
* 'param' => ''
* )
*/
public function delete()
{
$id = input('param.id', 0, 'intval');
if (empty($id)) {
$this->error('非法数据!');
}
Db::name("third_party_user")->where("id", $id)->delete();
$this->success("删除成功!", "admin_oauth/index");
}
}
\ No newline at end of file
... ...
... ... @@ -157,6 +157,7 @@ return array (
'PORTAL_BRAND_INDEX' => '品牌中介列表',
'PORTAL_CODE_DEFAULT' => '短信验证码管理',
'PORTAL_CODE_INDEX' => '短信验证码列表',
'PORTAL_COMPLAINT_INDEX' => '投诉管理',
'PORTAL_COOPERATION_DEFAULT' => '首页内容管理',
'PORTAL_COOPERATION_INDEX' => '合作企业列表',
'PORTAL_NEED_USER' => '需求管理',
... ... @@ -185,4 +186,5 @@ return array (
'USER_ADMINUSERACTION_EDITPOST' => '编辑用户操作提交',
'USER_ADMINUSERACTION_INDEX' => '用户操作管理',
'USER_ADMINUSERACTION_SYNC' => '同步用户操作',
'USER_GETMONEY_INDEX' => '提现管理',
);
\ No newline at end of file
... ...
<include file="public@header"/>
<link rel="stylesheet" href="__STATIC__/install/css/mdialog.css">
<style>
.popup,.popdown{
width: 250px;
height: 100px;
background-color: rgba(0,0,0,0.5);
position: fixed;
top: 50%;
transform: translateY(-50px);
left: 0;
right: 0;
margin: 0 auto;
border-radius: 5px;
color: #ffffff;
}
.popup p,.popdown p{
text-align: center;
margin-top: 20px;
}
.popup span,.popdown span{
text-align: center;
line-height: 30px;
cursor: pointer;
}
.popup .queding,.popdown .sure{
display: inline-block;
width: 80px;
height: 30px;
background-color: #1E9FFF;
border-radius: 3px;
}
.popup span:hover,.popdown span:hover{
opacity: 0.8;
}
.popup .quxiao,.popdown .re{
display: inline-block;
width: 80px;
height: 30px;
ckground-color: #9cb945 ;
color: #333333;
border-radius: 3px;
background-color:#fff;
margin-left: 35px;
}
.btn_list{
margin: 0 auto;
width: 200px;
}
</style>
</head>
<body>
<div class="wrap">
<ul class="nav nav-tabs">
<li class="active"><a>投诉管理</a></li>
</ul>
<form class="well form-inline margin-top-20" method="post" action="{:url('Complaint/index')}">
时间:
<input type="text" class="form-control js-bootstrap-datetime" name="start_time"
value="{$start_time|default=''}"
style="width: 140px;" autocomplete="off"> -
<input type="text" class="form-control js-bootstrap-datetime" name="end_time"
value="{$end_time|default=''}"
style="width: 140px;" autocomplete="off"> &nbsp; &nbsp;
用户名:
<input type="text" class="form-control" name="name" style="width: 200px;"
value="{$name|default=''}" placeholder="请输入姓名">
手机号:
<input type="text" class="form-control" name="tel" style="width: 200px;"
value="{$tel|default=''}" placeholder="请输入手机号">
<input type="submit" class="btn btn-primary" value="搜索"/>
<a class="btn btn-danger" href="{:url('Complaint/index')}">清空</a>
<!--<span class="btn btn-default" onclick="window.history.back(-1)" >返回</span>-->
</form>
<form method="post" class="js-ajax-form margin-top-20">
<table class="table table-hover table-bordered">
<thead>
<tr>
<th>ID</th>
<th>用户id</th>
<th>用户名</th>
<th>手机号</th>
<th>需求id</th>
<th>中介报价id</th>
<th>中介id</th>
<th>投诉内容</th>
<th>投诉时间</th>
<th>状态</th>
<th>操作</th>
</tr>
</thead>
<tbody>
<foreach name="lists" item="vo">
<tr>
<td>{$vo.id}</td>
<td>{$vo.user_id}</td>
<td>{$vo.name}</td>
<td>{$vo.tel}</td>
<td>{$vo.need_id}</td>
<td>{$vo.intermediary_id}</td>
<td>{$vo.agency_id}</td>
<td>{$vo.content}</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>
<eq name="vo.status" value="2">
<span index="{$vo.id}" style="color: #858585">已同意</span>
</eq>
<eq name="vo.status" value="3">
<span index="{$vo.id}" style="color: #858585">已拒绝</span>
</eq>
<eq name="vo.status" value="1">
<span index="{$vo.id}" style="color: #858585">未处理</span>
</eq>
</td>
<td>
<eq name="vo.status" value="2">
<span style="color: #00AA00; cursor: pointer; " index="{$vo.id}">已同意</span>
</eq>
<eq name="vo.status" value="3">
<span style="color: #ff0000; cursor: pointer; " index="{$vo.id}">已拒绝</span>
</eq>
<eq name="vo.status" value="1">
<span class="agree" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">同意</span>
<span class="refuse" style="color: #ff0000; text-decoration:underline; cursor: pointer; " index="{$vo.id}">拒绝</span>
</eq>
</td>
</tr>
</foreach>
</tbody>
</table>
<ul class="pagination">{$page|default=''}</ul>
</form>
<div class="popup" style="display: none;">
<p>确认同意投诉</p>
<div class="btn_list">
<span class="queding">接受</span>
<span class="quxiao">取消</span>
</div>
</div>
<div class="popdown" style="display: none;">
<p>确认拒绝投诉</p>
<div class="btn_list">
<span class="sure">确认</span>
<span class="re">取消</span>
</div>
</div>
</div>
<script src="__STATIC__/js/admin.js"></script>
<script src="__STATIC__/js/layer/layer.js"></script>
<script type="text/javascript" src="__STATIC__/js/zepto.min.js"></script>
<script type="text/javascript" src="__STATIC__/js/mdialog.js"></script>
<script type="">
$('.agree').click(function () {
var id = $(this).attr('index');
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
$.ajax({
type:"POST",
url:"{:url('Complaint/agree')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popup').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popup').css('display','none');
}
})
})
})
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 拒绝申请
$('.refuse').click(function () {
var id = $(this).attr('index');
$('.popdown').css('display','block');
// 删除
$('.sure').click(function () {
$.ajax({
type:"POST",
url:"{:url('Complaint/refuse')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popdown').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popdown').css('display','none');
}
})
})
})
$('.re').click(function () {
$('.popdown').css('display','none');
})
</script>
</body>
</html>
\ No newline at end of file
... ...
<include file="public@header"/>
<link rel="stylesheet" href="__STATIC__/install/css/mdialog.css">
<style>
.popup{
width: 250px;
height: 100px;
background-color: rgba(0,0,0,0.5);
position: fixed;
top: 50%;
transform: translateY(-50px);
left: 0;
right: 0;
margin: 0 auto;
border-radius: 5px;
color: #ffffff;
}
.popup p{
text-align: center;
margin-top: 20px;
}
.popup span{
text-align: center;
line-height: 30px;
cursor: pointer;
}
.popup .queding{
display: inline-block;
width: 80px;
height: 30px;
background-color: #1E9FFF;
border-radius: 3px;
}
.popup span:hover{
opacity: 0.8;
}
.popup .quxiao{
display: inline-block;
width: 80px;
height: 30px;
ckground-color: #9cb945 ;
color: #333333;
border-radius: 3px;
background-color:#fff;
margin-left: 35px;
}
.btn_list{
margin: 0 auto;
width: 200px;
}
</style>
</head>
<body>
<div class="wrap">
<ul class="nav nav-tabs">
<li class="active"><a>收入</a></li>
<li class=""><a href="{:url('AdminOauth/money',array('id'=>$uid))}">支出</a></li>
</ul>
<form class="well form-inline margin-top-20" method="post" action="{:url('AdminOauth/inmoney')}">
<input type="hidden" name="id" value="{$uid}">
时间:
<input type="text" class="form-control js-bootstrap-datetime" name="start_time"
value="{$start_time|default=''}"
style="width: 140px;" autocomplete="off"> -
<input type="text" class="form-control js-bootstrap-datetime" name="end_time"
value="{$end_time|default=''}"
style="width: 140px;" autocomplete="off"> &nbsp; &nbsp;
收入详情:
<input type="text" class="form-control" name="title" style="width: 200px;"
value="{$title|default=''}" placeholder="请输入收入详情">
收入金额:
<input type="text" class="form-control" name="money" style="width: 200px;"
value="{$money|default=''}" placeholder="请输入收入金额">
<input type="submit" class="btn btn-primary" value="搜索"/>
<a class="btn btn-danger" href="{:url('AdminOauth/inmoney',array('id'=>$uid))}">清空</a>
</form>
<div class="well form-inline margin-top-20">
<div >用户信息</div>
<div>
<span>用户id:{$user.id}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>用户名:{$user.name}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>手机号:{$user.tel}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span class="btn btn-default" onclick="window.history.back(-1)" >返回</span>
</div>
</div>
<form method="post" class="js-ajax-form margin-top-20">
<table class="table table-hover table-bordered">
<thead>
<tr>
<th>ID</th>
<th>收入详情</th>
<th>收入金额</th>
<th>状态</th>
<th>支出时间</th>
<!--<th align="center" style="cursor: pointer; text-align: center;">查看</th>-->
<th align="center" style="cursor: pointer;">操作</th>
</tr>
</thead>
<tbody>
<foreach name="lists" item="vo">
<tr>
<td>{$vo.id}</td>
<td>{$vo.title}</td>
<td>{$vo.money}</td>
<td>
<eq name="vo.status" value="1">
正常
</eq>
</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>
<span class="look" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">查看订单</span>
<span class="black" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">删除</span>
</td>
</tr>
</foreach>
</tbody>
</table>
</form>
<div class="popup" style="display: none;">
<p>确认删除该信息</p>
<div class="btn_list">
<span class="queding">确认</span>
<span class="quxiao">取消</span>
</div>
</div>
</div>
<script src="__STATIC__/js/admin.js"></script>
<script src="__STATIC__/js/layer/layer.js"></script>
<script type="text/javascript" src="__STATIC__/js/zepto.min.js"></script>
<script type="text/javascript" src="__STATIC__/js/mdialog.js"></script>
<script type="">
$('.black').click(function () {
var id = $(this).attr('index');
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
$.ajax({
type:"POST",
url:"{:url('AdminOauth/moneyDel')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popup').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popup').css('display','none');
}
})
})
})
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 查看用户详细信息
$('.detail').click(function () {
var url1 = "{:url('user/AdminOauth/userDetail')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看收支明细
// 查看提现申请
// 查看邀请人
</script>
</body>
</html>
\ No newline at end of file
... ...
<include file="public@header"/>
<link rel="stylesheet" href="__STATIC__/install/css/mdialog.css">
<style>
.popup{
width: 250px;
height: 100px;
background-color: rgba(0,0,0,0.5);
position: fixed;
top: 50%;
transform: translateY(-50px);
left: 0;
right: 0;
margin: 0 auto;
border-radius: 5px;
color: #ffffff;
}
.popup p{
text-align: center;
margin-top: 20px;
}
.popup span{
text-align: center;
line-height: 30px;
cursor: pointer;
}
.popup .queding{
display: inline-block;
width: 80px;
height: 30px;
background-color: #1E9FFF;
border-radius: 3px;
}
.popup span:hover{
opacity: 0.8;
}
.popup .quxiao{
display: inline-block;
width: 80px;
height: 30px;
ckground-color: #9cb945 ;
color: #333333;
border-radius: 3px;
background-color:#fff;
margin-left: 35px;
}
.btn_list{
margin: 0 auto;
width: 200px;
}
</style>
</head>
<body>
<div class="wrap">
<ul class="nav nav-tabs">
<li class=""><a href="{:url('AdminOauth/inmoney',array('id'=>$uid))}">收入</a></li>
<li class="active"><a>支出</a></li>
</ul>
<form class="well form-inline margin-top-20" method="post" action="{:url('AdminOauth/money')}">
<input type="hidden" name="id" value="{$uid}">
时间:
<input type="text" class="form-control js-bootstrap-datetime" name="start_time"
value="{$start_time|default=''}"
style="width: 140px;" autocomplete="off"> -
<input type="text" class="form-control js-bootstrap-datetime" name="end_time"
value="{$end_time|default=''}"
style="width: 140px;" autocomplete="off"> &nbsp; &nbsp;
支出详情:
<input type="text" class="form-control" name="title" style="width: 200px;"
value="{$title|default=''}" placeholder="请输入支出详情">
支出金额:
<input type="text" class="form-control" name="money" style="width: 200px;"
value="{$money|default=''}" placeholder="请输入支出金额">
<input type="submit" class="btn btn-primary" value="搜索"/>
<a class="btn btn-danger" href="{:url('AdminOauth/money',array('id'=>$uid))}">清空</a>
</form>
<div class="well form-inline margin-top-20">
<div >用户信息</div>
<div>
<span>用户id:{$user.id}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>用户名:{$user.name}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>手机号:{$user.tel}</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<span class="btn btn-default" onclick="window.history.back(-1)" >返回</span>
</div>
</div>
<form method="post" class="js-ajax-form margin-top-20">
<table class="table table-hover table-bordered">
<thead>
<tr>
<th>ID</th>
<th>支出详情</th>
<th>支出金额</th>
<th>状态</th>
<th>支出时间</th>
<!--<th align="center" style="cursor: pointer; text-align: center;">查看</th>-->
<th align="center" style="cursor: pointer;">操作</th>
</tr>
</thead>
<tbody>
<foreach name="lists" item="vo">
<tr>
<td>{$vo.id}</td>
<td>{$vo.title}</td>
<td>{$vo.money}</td>
<td>
<eq name="vo.status" value="1">
正常
</eq>
</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>
<neq name="vo.order_id" value="0">
<span class="order" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.order_id}">查看订单</span>
</neq>
<span class="del" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">删除</span>
</td>
</tr>
</foreach>
</tbody>
</table>
</form>
<div class="popup" style="display: none;">
<p>确认删除该信息</p>
<div class="btn_list">
<span class="queding">确认</span>
<span class="quxiao">取消</span>
</div>
</div>
</div>
<script src="__STATIC__/js/admin.js"></script>
<script src="__STATIC__/js/layer/layer.js"></script>
<script type="text/javascript" src="__STATIC__/js/zepto.min.js"></script>
<script type="text/javascript" src="__STATIC__/js/mdialog.js"></script>
<script type="">
$('.del').click(function () {
var id = $(this).attr('index');
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
$.ajax({
type:"POST",
url:"{:url('AdminOauth/moneyDel')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popup').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popup').css('display','none');
}
})
})
})
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 查看用户详细信息
$('.detail').click(function () {
var url1 = "{:url('user/AdminOauth/userDetail')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看订单
$('.order').click(function () {
var url1 = "{:url('user/AdminOauth/findOrder')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/order_id/'+url2+'.html';
window.location.href = url
})
// 查看提现申请
// 查看邀请人
</script>
</body>
</html>
\ No newline at end of file
... ...
<include file="public@header"/>
<style type="text/css">
.pic-list li {
margin-bottom: 5px;
}
</style>
</head>
<body>
<div class="wrap js-check-wrap">
<ul class="nav nav-tabs">
<!--<li><a href="{:url('Bank/index')}">银行列表</a></li>-->
<!--<li class="active"><a href="{:url('Bank/add')}">添加银行</a></li>-->
</ul>
<form action="{:url('AdminOauth/changeAgency')}" method="post" class="form-horizontal js-ajax-form margin-top-20" enctype="multipart/form-data" >
<div class="row">
<div class="col-md-9">
<table class="table table-bordered">
<input class="form-control" type="hidden" name="id"
value="{$list['id']}"/>
<tr>
<th width="15%">真实姓名</th>
<td><input class="form-control" type="text" name="name" readonly="readonly"
value="{$list['name']}" />
</td>
</tr>
<tr>
<th width="15%">手机号</th>
<td><input class="form-control" type="text" name="tel" value="{$list['tel']}" />
</td>
</tr>
<tr>
<th width="15%">余额</th>
<td><input class="form-control" type="text" name="money" value="{$list['money']}" />
</td>
</tr>
<tr>
<th width="15%">当前提现金额</th>
<td><input class="form-control" type="text" name="get_money" value="{$list['get_money']}" />
</td>
</tr>
<tr>
<th width="15%">城市</th>
<td><input class="form-control" type="text" name="city" value="{$list['city']}" />
</td>
</tr>
<tr>
<th width="15%">所属公司</th>
<td><input class="form-control" type="text" name="company" value="{$list['company']}" />
</td>
</tr>
<tr>
<th width="15%">门店</th>
<td><input class="form-control" type="text" name="store" value="{$list['store']}" />
</td>
</tr>
<tr>
<th width="15%">服务小区</th>
<td><input class="form-control" type="text" name="quarters" value="{$list['quarters']}" />
</td>
</tr>
<tr>
<th width="15%">推荐人手机号</th>
<td><input class="form-control" type="text" name="referee_tel" value="{$list['referee_tel']}" />
</td>
</tr>
<tr>
<th width="15%">推荐人id</th>
<td><input class="form-control" type="text" name="referee_id" value="{$list['referee_id']}" />
</td>
</tr>
<tr>
<th width="15%">短网址</th>
<td><input class="form-control" type="text" name="link" value="{$list['link']}" />
</td>
</tr>
<tr>
<th width="15%">最后登录ip</th>
<td><input class="form-control" type="text" name="last_login_ip" value="{$list['last_login_ip']}" />
</td>
</tr>
<tr>
<th width="15%">注册时ip</th>
<td><input class="form-control" type="text" name="create_ip" value="{$list['create_ip']}" />
</td>
</tr>
<tr>
<th width="15%">首次登录时间</th>
<td><input class="form-control" type="text" name="login_time" value="{$list['login_time']|date='Y-m-d H:i:s',###}" />
</td>
</tr>
<tr>
<th width="15%">最后登录时间</th>
<td><input class="form-control" type="text" name="last_login_time" value="{$list['last_login_time']|date='Y-m-d H:i:s',###}" />
</td>
</tr>
<tr>
<th width="18%">注册时间</th>
<td><input class="form-control" type="text" name="create_time" value="{$list['create_time']|date='Y-m-d H:i:s',###}" />
</td>
</tr>
<tr>
<th>状态</th>
<td>
<select name="status">
<option name="status" value="1" <eq name="list.status" value="1">selected</eq>>&nbsp;&nbsp;正常&nbsp;&nbsp;</option>
<option name="status" value="8" <eq name="list.status" value="8">selected</eq>>&nbsp;&nbsp;拉黑&nbsp;&nbsp;</option>
</select>
<!--<input class="form-control" type="text" name="status" value="{$list['status']}" />-->
</td>
</tr>
</table>
<div class="form-group">
<div class="col-sm-offset-2 col-sm-10">
<button type="submit" class="btn btn-primary js-ajax-submit">{:lang('SAVE')}</button>
<a class="btn btn-default" href="{:url('AdminOauth/intermediary')}">{:lang('BACK')}</a>
</div>
</div>
</div>
</div>
</form>
</div>
<script type="text/javascript" src="__STATIC__/js/admin.js"></script>
<script type="text/javascript">
//编辑器路径定义
var editorURL = GV.WEB_ROOT;
</script>
<script type="text/javascript" src="__STATIC__/js/ueditor/ueditor.config.js"></script>
<script type="text/javascript" src="__STATIC__/js/ueditor/ueditor.all.min.js"></script>
<script type="text/javascript">
$(function () {
editorcontent = new baidu.editor.ui.Editor();
editorcontent.render('content');
try {
editorcontent.sync();
} catch (err) {
}
$('.btn-cancel-thumbnail').click(function () {
$('#thumbnail-preview').attr('src', '__TMPL__/public/assets/images/default-thumbnail.png');
$('#thumbnail').val('');
});
});
</script>
</body>
</html>
... ...
<include file="public@header"/>
<link rel="stylesheet" href="__STATIC__/install/css/mdialog.css">
<style>
.popup{
.popup,.popdown{
width: 250px;
height: 100px;
background-color: rgba(0,0,0,0.5);
... ... @@ -14,26 +14,26 @@
border-radius: 5px;
color: #ffffff;
}
.popup p{
.popup p,.popdown p{
text-align: center;
margin-top: 20px;
}
.popup span{
.popup span,.popdown span{
text-align: center;
line-height: 30px;
cursor: pointer;
}
.popup .queding{
.popup .queding,.popdown .sure{
display: inline-block;
width: 80px;
height: 30px;
background-color: #1E9FFF;
border-radius: 3px;
}
.popup span:hover{
.popup span:hover,.popdown span:hover{
opacity: 0.8;
}
.popup .quxiao{
.popup .quxiao,.popdown .re{
display: inline-block;
width: 80px;
height: 30px;
... ... @@ -91,8 +91,16 @@
</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>
<eq name="vo.status" value="3">
<span style="color: #00AA00; cursor: pointer; " index="{$vo.id}">提现通过</span>
</eq>
<eq name="vo.status" value="4">
<span style="color: #ff0000; cursor: pointer; " index="{$vo.id}">未通过</span>
</eq>
<eq name="vo.status" value="5">
<span class="agree" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">同意</span>
<span class="refuse" style="color: #ff0000; text-decoration:underline; cursor: pointer; " index="{$vo.id}">拒绝</span>
</eq>
</td>
</tr>
</foreach>
... ... @@ -101,12 +109,19 @@
</form>
<div class="popup" style="display: none;">
<p>确认拉黑该用户</p>
<p>确认同意申请</p>
<div class="btn_list">
<span class="queding">确认</span>
<span class="quxiao">取消</span>
</div>
</div>
<div class="popdown" style="display: none;">
<p>确认拒绝申请</p>
<div class="btn_list">
<span class="sure">确认</span>
<span class="re">取消</span>
</div>
</div>
</div>
<script src="__STATIC__/js/admin.js"></script>
... ... @@ -116,6 +131,7 @@
<script type="">
$('.agree').click(function () {
var id = $(this).attr('index');
var uid = "{$uid}";
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
... ... @@ -124,6 +140,7 @@
url:"{:url('AdminOauth/agree')}",
data:{
"id":id,
"uid":uid,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
... ... @@ -139,6 +156,34 @@
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 拒绝申请
$('.refuse').click(function () {
var id = $(this).attr('index');
var uid = "{$uid}";
$('.popdown').css('display','block');
// 删除
$('.sure').click(function () {
$.ajax({
type:"POST",
url:"{:url('AdminOauth/refuse')}",
data:{
"id":id,
"uid":uid,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popdown').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popdown').css('display','none');
}
})
})
})
$('.re').click(function () {
$('.popdown').css('display','none');
})
</script>
</body>
... ...
... ... @@ -52,16 +52,16 @@
<body>
<div class="wrap">
<ul class="nav nav-tabs">
<li class="active"><a>{:lang('USER_OAUTHADMIN_INDEX')}</a></li>
<li class="active"><a>用户管理</a></li>
</ul>
<form class="well form-inline margin-top-20" method="post" action="{:url('AdminOauth/intermediary')}">
<form class="well form-inline margin-top-20" method="post" action="{:url('AdminOauth/user')}">
时间:
<input type="text" class="form-control js-bootstrap-datetime" name="start_time"
value="{$start_time|default=''}"
style="width: 140px;" autocomplete="off"> -
<input type="text" class="form-control js-bootstrap-datetime" name="end_time"
value="{$end_time|default=''}"
style="width: 140px;" autocomplete="off">
style="width: 140px;" autocomplete="off"> &nbsp; &nbsp;
姓名:
<input type="text" class="form-control" name="name" style="width: 200px;"
value="{$name|default=''}" placeholder="请输入姓名">
... ... @@ -69,8 +69,10 @@
<input type="text" class="form-control" name="tel" style="width: 200px;"
value="{$tel|default=''}" placeholder="请输入手机号">
<input type="submit" class="btn btn-primary" value="搜索"/>
<a class="btn btn-danger" href="{:url('AdminOauth/intermediary')}">清空</a>
<a class="btn btn-danger" href="{:url('AdminOauth/user')}">清空</a>
</form>
<form method="post" class="js-ajax-form margin-top-20">
<table class="table table-hover table-bordered">
<thead>
... ... @@ -78,16 +80,13 @@
<th>ID</th>
<th>姓名</th>
<th>手机号</th>
<th>城市</th>
<th>所属公司</th>
<th>门店</th>
<th>服务小区</th>
<th>余额</th>
<th>推荐人</th>
<th>推荐人id</th>
<th>创建时间</th>
<th>更新时间</th>
<th>注册时间</th>
<th>状态</th>
<th align="center">操作</th>
<th align="center" style="cursor: pointer; text-align: center;">查看</th>
<th align="center" style="cursor: pointer;">操作</th>
</tr>
</thead>
<tbody>
... ... @@ -96,10 +95,7 @@
<td>{$vo.id}</td>
<td>{$vo.name}</td>
<td>{$vo.tel}</td>
<td>{$vo.city}</td>
<td>{$vo.company}</td>
<td>{$vo.store}</td>
<td>{$vo.quarters}</td>
<th>{$vo.money}</th>
<td>
<empty name="vo.referee_name">
暂无
... ... @@ -107,14 +103,13 @@
{$vo.referee_name}
</td>
<td>
<empty name="vo.referee_name">
<empty name="vo.referee_id">
暂无
</empty>
{$vo.referee_id}
</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>{:date('Y-m-d H:i:s',$vo['update_time'])}</td>
<td>
<eq name="vo.status" value="1">
正常
... ... @@ -127,14 +122,22 @@
</eq>
</td>
<td>
<span class="detail" style="color: #0FD149; text-decoration:underline; cursor: pointer; " index="{$vo.id}" >详细信息</span>
<span class="money" style="color: #9B399C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">收支明细</span>
<span class="getMoneyDetail" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">提现申请</span>
<span class="referee" style="color: #BFB61D; text-decoration:underline; cursor: pointer; " index="{$vo.id}">邀请人</span>
<span class="comment" style="color: #5EB3D7; text-decoration:underline; cursor: pointer; " index="{$vo.id}">查看评论</span>
<span class="comment" style="color: #5EB3D7; text-decoration:underline; cursor: pointer; " index="{$vo.id}">查看信誉分</span>
</td>
<td>
<eq name="vo.status" value="1">
<span class="black" style="color: #18BC9C; text-decoration:underline;" index="{$vo.id}">拉黑</span>
<span class="black" style="color: #AC4555; text-decoration:underline; cursor: pointer; " index="{$vo.id}">拉黑</span>
</eq>
<eq name="vo.status" value="8">
<span style="color:#aaaaaa;" index="{$vo.id}">已拉黑</span>
<span style="color:#aaaaaa; cursor: pointer; " index="{$vo.id}">已拉黑</span>
</eq>
<eq name="vo.status" value="9">
<span style="color:#aaaaaa;" index="{$vo.id}">已删除</span>
<span style="color:#aaaaaa; cursor: pointer; " index="{$vo.id}">已删除</span>
</eq>
</td>
</tr>
... ... @@ -158,7 +161,7 @@
<script type="text/javascript" src="__STATIC__/js/mdialog.js"></script>
<script type="">
$('.black').click(function () {
var id = $('.black').attr('index');
var id = $(this).attr('index');
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
... ... @@ -182,6 +185,47 @@
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 查看用户详细信息
$('.detail').click(function () {
var url1 = "{:url('user/AdminOauth/agencyDetail')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看收支明细
$('.money').click(function () {
var url1 = "{:url('user/AdminOauth/money')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看提现申请
$('.getMoneyDetail').click(function () {
var url1 = "{:url('user/AdminOauth/getMoneyDetail')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看邀请人
$('.referee').click(function () {
var url1 = "{:url('user/AdminOauth/referee')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看评论
$('.comment').click(function () {
var url1 = "{:url('user/AdminOauth/comment')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
</script>
</body>
</html>
\ No newline at end of file
... ...
<include file="public@header"/>
<link rel="stylesheet" href="__STATIC__/install/css/mdialog.css">
<style>
.popup,.popdown{
width: 250px;
height: 100px;
background-color: rgba(0,0,0,0.5);
position: fixed;
top: 50%;
transform: translateY(-50px);
left: 0;
right: 0;
margin: 0 auto;
border-radius: 5px;
color: #ffffff;
}
.popup p,.popdown p{
text-align: center;
margin-top: 20px;
}
.popup span,.popdown span{
text-align: center;
line-height: 30px;
cursor: pointer;
}
.popup .queding,.popdown .sure{
display: inline-block;
width: 80px;
height: 30px;
background-color: #1E9FFF;
border-radius: 3px;
}
.popup span:hover,.popdown span:hover{
opacity: 0.8;
}
.popup .quxiao,.popdown .re{
display: inline-block;
width: 80px;
height: 30px;
ckground-color: #9cb945 ;
color: #333333;
border-radius: 3px;
background-color:#fff;
margin-left: 35px;
}
.btn_list{
margin: 0 auto;
width: 200px;
}
</style>
</head>
<body>
<div class="wrap">
<ul class="nav nav-tabs">
<li class="active"><a>提现管理</a></li>
</ul>
<form class="well form-inline margin-top-20" method="post" action="{:url('Getmoney/index')}">
时间:
<input type="text" class="form-control js-bootstrap-datetime" name="start_time"
value="{$start_time|default=''}"
style="width: 140px;" autocomplete="off"> -
<input type="text" class="form-control js-bootstrap-datetime" name="end_time"
value="{$end_time|default=''}"
style="width: 140px;" autocomplete="off"> &nbsp; &nbsp;
姓名:
<input type="text" class="form-control" name="name" style="width: 200px;"
value="{$name|default=''}" placeholder="请输入姓名">
手机号:
<input type="text" class="form-control" name="tel" style="width: 200px;"
value="{$tel|default=''}" placeholder="请输入手机号">
<input type="submit" class="btn btn-primary" value="搜索"/>
<a class="btn btn-danger" href="{:url('Getmoney/index')}">清空</a>
<!--<span class="btn btn-default" onclick="window.history.back(-1)" >返回</span>-->
</form>
<form method="post" class="js-ajax-form margin-top-20">
<table class="table table-hover table-bordered">
<thead>
<tr>
<th>ID</th>
<th>用户名</th>
<th>手机号</th>
<th>身份</th>
<th>提现金额</th>
<th>状态</th>
<th>提现时间</th>
<th>操作</th>
</tr>
</thead>
<tbody>
<foreach name="lists" item="vo">
<tr>
<td>{$vo.id}</td>
<td>{$vo.name}</td>
<td>{$vo.tel}</td>
<td>
<eq name="vo.type" value="1">
用户
</eq>
<eq name="vo.type" value="2">
中介
</eq>
</td>
<td>{$vo.money}</td>
<td>
<eq name="vo.status" value="5">待审核</eq>
<eq name="vo.status" value="3">提现通过</eq>
<eq name="vo.status" value="4">提现拒绝</eq>
</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>
<eq name="vo.status" value="3">
<span style="color: #00AA00; cursor: pointer; " index="{$vo.id}">提现通过</span>
</eq>
<eq name="vo.status" value="4">
<span style="color: #ff0000; cursor: pointer; " index="{$vo.id}">未通过</span>
</eq>
<eq name="vo.status" value="5">
<span class="agree" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">同意</span>
<span class="refuse" style="color: #ff0000; text-decoration:underline; cursor: pointer; " index="{$vo.id}">拒绝</span>
</eq>
</td>
</tr>
</foreach>
</tbody>
</table>
</form>
<div class="popup" style="display: none;">
<p>确认同意申请</p>
<div class="btn_list">
<span class="queding">确认</span>
<span class="quxiao">取消</span>
</div>
</div>
<div class="popdown" style="display: none;">
<p>确认拒绝申请</p>
<div class="btn_list">
<span class="sure">确认</span>
<span class="re">取消</span>
</div>
</div>
</div>
<script src="__STATIC__/js/admin.js"></script>
<script src="__STATIC__/js/layer/layer.js"></script>
<script type="text/javascript" src="__STATIC__/js/zepto.min.js"></script>
<script type="text/javascript" src="__STATIC__/js/mdialog.js"></script>
<script type="">
$('.agree').click(function () {
var id = $(this).attr('index');
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
$.ajax({
type:"POST",
url:"{:url('Getmoney/agree')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popup').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popup').css('display','none');
}
})
})
})
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 拒绝申请
$('.refuse').click(function () {
var id = $(this).attr('index');
$('.popdown').css('display','block');
// 删除
$('.sure').click(function () {
$.ajax({
type:"POST",
url:"{:url('Getmoney/refuse')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popdown').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popdown').css('display','none');
}
})
})
})
$('.re').click(function () {
$('.popdown').css('display','none');
})
</script>
</body>
</html>
\ No newline at end of file
... ...
<include file="public@header"/>
<link rel="stylesheet" href="__STATIC__/install/css/mdialog.css">
<style>
.popup{
width: 250px;
height: 100px;
background-color: rgba(0,0,0,0.5);
position: fixed;
top: 50%;
transform: translateY(-50px);
left: 0;
right: 0;
margin: 0 auto;
border-radius: 5px;
color: #ffffff;
}
.popup p{
text-align: center;
margin-top: 20px;
}
.popup span{
text-align: center;
line-height: 30px;
cursor: pointer;
}
.popup .queding{
display: inline-block;
width: 80px;
height: 30px;
background-color: #1E9FFF;
border-radius: 3px;
}
.popup span:hover{
opacity: 0.8;
}
.popup .quxiao{
display: inline-block;
width: 80px;
height: 30px;
ckground-color: #9cb945 ;
color: #333333;
border-radius: 3px;
background-color:#fff;
margin-left: 35px;
}
.btn_list{
margin: 0 auto;
width: 200px;
}
</style>
</head>
<body>
<div class="wrap">
<ul class="nav nav-tabs">
<li class="active"><a>收入</a></li>
<li class=""><a href="{:url('AdminOauth/money',array('id'=>$uid))}">支出</a></li>
</ul>
<form class="well form-inline margin-top-20" method="post" action="{:url('AdminOauth/inmoney')}">
<input type="hidden" name="id" value="{$uid}">
时间:
<input type="text" class="form-control js-bootstrap-datetime" name="start_time"
value="{$start_time|default=''}"
style="width: 140px;" autocomplete="off"> -
<input type="text" class="form-control js-bootstrap-datetime" name="end_time"
value="{$end_time|default=''}"
style="width: 140px;" autocomplete="off"> &nbsp; &nbsp;
收入详情:
<input type="text" class="form-control" name="title" style="width: 200px;"
value="{$title|default=''}" placeholder="请输入收入详情">
收入金额:
<input type="text" class="form-control" name="money" style="width: 200px;"
value="{$money|default=''}" placeholder="请输入收入金额">
<input type="submit" class="btn btn-primary" value="搜索"/>
<a class="btn btn-danger" href="{:url('AdminOauth/inmoney',array('id'=>$uid))}">清空</a>
</form>
<div class="well form-inline margin-top-20">
<div >用户信息</div>
<div>
<span>用户id:{$user.id}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>用户名:{$user.name}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>手机号:{$user.tel}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span class="btn btn-default" onclick="window.history.back(-1)" >返回</span>
</div>
</div>
<form method="post" class="js-ajax-form margin-top-20">
<table class="table table-hover table-bordered">
<thead>
<tr>
<th>ID</th>
<th>收入详情</th>
<th>收入金额</th>
<th>状态</th>
<th>支出时间</th>
<!--<th align="center" style="cursor: pointer; text-align: center;">查看</th>-->
<th align="center" style="cursor: pointer;">操作</th>
</tr>
</thead>
<tbody>
<foreach name="lists" item="vo">
<tr>
<td>{$vo.id}</td>
<td>{$vo.title}</td>
<td>{$vo.money}</td>
<td>
<eq name="vo.status" value="1">
正常
</eq>
</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>
<span class="look" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">查看订单</span>
<span class="black" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">删除</span>
</td>
</tr>
</foreach>
</tbody>
</table>
</form>
<div class="popup" style="display: none;">
<p>确认删除该信息</p>
<div class="btn_list">
<span class="queding">确认</span>
<span class="quxiao">取消</span>
</div>
</div>
</div>
<script src="__STATIC__/js/admin.js"></script>
<script src="__STATIC__/js/layer/layer.js"></script>
<script type="text/javascript" src="__STATIC__/js/zepto.min.js"></script>
<script type="text/javascript" src="__STATIC__/js/mdialog.js"></script>
<script type="">
$('.black').click(function () {
var id = $(this).attr('index');
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
$.ajax({
type:"POST",
url:"{:url('AdminOauth/moneyDel')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popup').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popup').css('display','none');
}
})
})
})
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 查看用户详细信息
$('.detail').click(function () {
var url1 = "{:url('user/AdminOauth/userDetail')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看收支明细
// 查看提现申请
// 查看邀请人
</script>
</body>
</html>
\ No newline at end of file
... ...
<include file="public@header"/>
<link rel="stylesheet" href="__STATIC__/install/css/mdialog.css">
<style>
.popup{
width: 250px;
height: 100px;
background-color: rgba(0,0,0,0.5);
position: fixed;
top: 50%;
transform: translateY(-50px);
left: 0;
right: 0;
margin: 0 auto;
border-radius: 5px;
color: #ffffff;
}
.popup p{
text-align: center;
margin-top: 20px;
}
.popup span{
text-align: center;
line-height: 30px;
cursor: pointer;
}
.popup .queding{
display: inline-block;
width: 80px;
height: 30px;
background-color: #1E9FFF;
border-radius: 3px;
}
.popup span:hover{
opacity: 0.8;
}
.popup .quxiao{
display: inline-block;
width: 80px;
height: 30px;
ckground-color: #9cb945 ;
color: #333333;
border-radius: 3px;
background-color:#fff;
margin-left: 35px;
}
.btn_list{
margin: 0 auto;
width: 200px;
}
</style>
</head>
<body>
<div class="wrap">
<ul class="nav nav-tabs">
<li class=""><a href="{:url('AdminOauth/inmoney',array('id'=>$uid))}">收入</a></li>
<li class="active"><a>支出</a></li>
</ul>
<form class="well form-inline margin-top-20" method="post" action="{:url('AdminOauth/money')}">
<input type="hidden" name="id" value="{$uid}">
时间:
<input type="text" class="form-control js-bootstrap-datetime" name="start_time"
value="{$start_time|default=''}"
style="width: 140px;" autocomplete="off"> -
<input type="text" class="form-control js-bootstrap-datetime" name="end_time"
value="{$end_time|default=''}"
style="width: 140px;" autocomplete="off"> &nbsp; &nbsp;
支出详情:
<input type="text" class="form-control" name="title" style="width: 200px;"
value="{$title|default=''}" placeholder="请输入支出详情">
支出金额:
<input type="text" class="form-control" name="money" style="width: 200px;"
value="{$money|default=''}" placeholder="请输入支出金额">
<input type="submit" class="btn btn-primary" value="搜索"/>
<a class="btn btn-danger" href="{:url('AdminOauth/money',array('id'=>$uid))}">清空</a>
</form>
<div class="well form-inline margin-top-20">
<div >用户信息</div>
<div>
<span>用户id:{$user.id}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>用户名:{$user.name}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span>手机号:{$user.tel}</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<span class="btn btn-default" onclick="window.history.back(-1)" >返回</span>
</div>
</div>
<form method="post" class="js-ajax-form margin-top-20">
<table class="table table-hover table-bordered">
<thead>
<tr>
<th>ID</th>
<th>支出详情</th>
<th>支出金额</th>
<th>状态</th>
<th>支出时间</th>
<!--<th align="center" style="cursor: pointer; text-align: center;">查看</th>-->
<th align="center" style="cursor: pointer;">操作</th>
</tr>
</thead>
<tbody>
<foreach name="lists" item="vo">
<tr>
<td>{$vo.id}</td>
<td>{$vo.title}</td>
<td>{$vo.money}</td>
<td>
<eq name="vo.status" value="1">
正常
</eq>
</td>
<td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
<td>
<neq name="vo.order_id" value="0">
<span class="order" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.order_id}">查看订单</span>
</neq>
<span class="del" style="color: #18BC9C; text-decoration:underline; cursor: pointer; " index="{$vo.id}">删除</span>
</td>
</tr>
</foreach>
</tbody>
</table>
</form>
<div class="popup" style="display: none;">
<p>确认删除该信息</p>
<div class="btn_list">
<span class="queding">确认</span>
<span class="quxiao">取消</span>
</div>
</div>
</div>
<script src="__STATIC__/js/admin.js"></script>
<script src="__STATIC__/js/layer/layer.js"></script>
<script type="text/javascript" src="__STATIC__/js/zepto.min.js"></script>
<script type="text/javascript" src="__STATIC__/js/mdialog.js"></script>
<script type="">
$('.del').click(function () {
var id = $(this).attr('index');
$('.popup').css('display','block');
// 删除
$('.queding').click(function () {
$.ajax({
type:"POST",
url:"{:url('AdminOauth/moneyDel')}",
data:{
"id":id,
},
success:function (data) {
new TipBox({type:'success',str:'操作成功',hasBtn:true});
$('.popup').css('display','none');
},
error:function () {
new TipBox({type:'error',str:'对不起,出错了!',hasBtn:true});
$('.popup').css('display','none');
}
})
})
})
$('.quxiao').click(function () {
$('.popup').css('display','none');
})
// 查看用户详细信息
$('.detail').click(function () {
var url1 = "{:url('user/AdminOauth/userDetail')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/id/'+url2+'.html';
window.location.href = url
})
// 查看订单
$('.order').click(function () {
var url1 = "{:url('user/AdminOauth/findOrder')}";
var url2 = $(this).attr('index');
var url3 = url1.split('.');
var url = url3[0]+'/order_id/'+url2+'.html';
window.location.href = url
})
// 查看提现申请
// 查看邀请人
</script>
</body>
</html>
\ No newline at end of file
... ...
... ... @@ -1280,3 +1280,5 @@
2018-07-24 16:19:20 response: '<form id=\'alipaysubmit\' name=\'alipaysubmit\' action=\'https://openapi.alipay.com/gateway.do?charset=UTF-8\' method=\'POST\'><input type=\'hidden\' name=\'biz_content\' value=\'{"product_code":"FAST_INSTANT_TRADE_PAY","body":"","subject":"需求保证金支付","total_amount":"0.01","out_trade_no":"2018072199481015"}\'/><input type=\'hidden\' name=\'app_id\' value=\'2018062560425105\'/><input type=\'hidden\' name=\'version\' value=\'1.0\'/><input type=\'hidden\' name=\'format\' value=\'json\'/><input type=\'hidden\' name=\'sign_type\' value=\'RSA2\'/><input type=\'hidden\' name=\'method\' value=\'alipay.trade.page.pay\'/><input type=\'hidden\' name=\'timestamp\' value=\'2018-07-24 16:19:20\'/><input type=\'hidden\' name=\'alipay_sdk\' value=\'alipay-sdk-php-20161101\'/><input type=\'hidden\' name=\'notify_url\' value=\'http://houseprice.w.bronet.cn/api/portal/Alipay/notify_url\'/><input type=\'hidden\' name=\'return_url\' value=\'http://houseprice.w.bronet.cn/api/portal/Alipay/return_url\'/><input type=\'hidden\' name=\'charset\' value=\'UTF-8\'/><input type=\'hidden\' name=\'sign\' value=\'QNTf+UwxVvV/IHI5pXHBQgooMftGLNyVw+d2TlB+Njr91hFYX5/eiAcu9szghr6p74pf7PaM9qzU/3YK0cfwI4DHQ9n7cBweDbLit9PLpAnrn5ANxtb591e7E/kZkojcj4xPQN6lMgR/20wFdB55m1n5FYd+Ok3/F6G/CDNxkdnTKHLsmLofD4D1qT9pnN+Nrs1VPByn124InkkVrUk7RS9ThjDDy3QFpKOUFPN8w7hmeDSC5dZccJ31vRZzO5pVU/Ygy9kkgTP00zWNqW4c9j3DLRK8ttNmGgRrcomqSd1OgsKmLVBC6pYyHxwfZ0EK3iIw+ztuXwao0ZonMxwc9g==\'/><input type=\'submit\' value=\'ok\' style=\'display:none;\'\'></form><script>document.forms[\'alipaysubmit\'].submit();</script>'
2018-07-24 16:19:28 {"product_code":"FAST_INSTANT_TRADE_PAY","body":"","subject":"需求保证金支付","total_amount":"0.01","out_trade_no":"2018072199481015"}
2018-07-24 16:19:28 response: '<form id=\'alipaysubmit\' name=\'alipaysubmit\' action=\'https://openapi.alipay.com/gateway.do?charset=UTF-8\' method=\'POST\'><input type=\'hidden\' name=\'biz_content\' value=\'{"product_code":"FAST_INSTANT_TRADE_PAY","body":"","subject":"需求保证金支付","total_amount":"0.01","out_trade_no":"2018072199481015"}\'/><input type=\'hidden\' name=\'app_id\' value=\'2018062560425105\'/><input type=\'hidden\' name=\'version\' value=\'1.0\'/><input type=\'hidden\' name=\'format\' value=\'json\'/><input type=\'hidden\' name=\'sign_type\' value=\'RSA2\'/><input type=\'hidden\' name=\'method\' value=\'alipay.trade.page.pay\'/><input type=\'hidden\' name=\'timestamp\' value=\'2018-07-24 16:19:28\'/><input type=\'hidden\' name=\'alipay_sdk\' value=\'alipay-sdk-php-20161101\'/><input type=\'hidden\' name=\'notify_url\' value=\'http://houseprice.w.bronet.cn/api/portal/Alipay/notify_url\'/><input type=\'hidden\' name=\'return_url\' value=\'http://houseprice.w.bronet.cn/api/portal/Alipay/return_url\'/><input type=\'hidden\' name=\'charset\' value=\'UTF-8\'/><input type=\'hidden\' name=\'sign\' value=\'wM7VQXlL8ov5HFZ4BLFkc0uZ3V9wFl1+zuHqa3r3tTCwi7BRMDc6qv1NuA7mCz+hH/5krUrdcxo1Sx+U8WTIFctFYUZymo73u7MwxaqavqEF9h1+eZpQ8hMUCgAont3glbYQwZZE7hbQObnQFxtr1Ox56mbF7SyyOQ6srtoptIQo3r4XOrucJSxmxazqEBZSjP3Wb7YUPr7zFUIF3hgRxhhkEDB7+XD8kK1w2i/5LSKdR8TkEAf6jN3RL05rR49vd11OSS3lPYreANgSvtRaXGiyOye7R1hXN/oZgYws9jFw9Eu4YyNw/aqRkI+p11LUZAPhWUoRB3/5ehNJFh6LKg==\'/><input type=\'submit\' value=\'ok\' style=\'display:none;\'\'></form><script>document.forms[\'alipaysubmit\'].submit();</script>'
2018-07-25 15:41:51 {"product_code":"FAST_INSTANT_TRADE_PAY","body":"","subject":"需求保证金支付","total_amount":"0.01","out_trade_no":"2018072556535456"}
2018-07-25 15:41:51 response: '<form id=\'alipaysubmit\' name=\'alipaysubmit\' action=\'https://openapi.alipay.com/gateway.do?charset=UTF-8\' method=\'POST\'><input type=\'hidden\' name=\'biz_content\' value=\'{"product_code":"FAST_INSTANT_TRADE_PAY","body":"","subject":"需求保证金支付","total_amount":"0.01","out_trade_no":"2018072556535456"}\'/><input type=\'hidden\' name=\'app_id\' value=\'2018062560425105\'/><input type=\'hidden\' name=\'version\' value=\'1.0\'/><input type=\'hidden\' name=\'format\' value=\'json\'/><input type=\'hidden\' name=\'sign_type\' value=\'RSA2\'/><input type=\'hidden\' name=\'method\' value=\'alipay.trade.page.pay\'/><input type=\'hidden\' name=\'timestamp\' value=\'2018-07-25 15:41:51\'/><input type=\'hidden\' name=\'alipay_sdk\' value=\'alipay-sdk-php-20161101\'/><input type=\'hidden\' name=\'notify_url\' value=\'http://houseprice.w.bronet.cn/api/portal/Alipay/notify_url\'/><input type=\'hidden\' name=\'return_url\' value=\'http://houseprice.w.bronet.cn/api/portal/Alipay/return_url\'/><input type=\'hidden\' name=\'charset\' value=\'UTF-8\'/><input type=\'hidden\' name=\'sign\' value=\'ASt3s4pu9rBbcNefAqZJlYPA19fo1+EthrchZ3cwUHdOku2j1j0pDOTxC14qlVKGFoRqXwuwROoadTLiT0YYEFPgWOuCk3Am3dR3T6rA150tJwHGAzJzP/VqDnsGe14U+jYOIut/SE96sAIg2OpZeoM5npIhx4Qhf906L9qecYzrM9QDuAqaNue9UzOVHioeeibsw5CxjxBIc5WcXH+BgYdByhcGVoqYoWJPgMTp+Es1VDq/kDchzqjYSRHRg6hFbDpinJEnVQwjBPEW0TZg82p2n8lZUO7HG4qI6ynXKm5KVNMecbm6YyhJTT8gBOxk0YOjAadkbA/leX1QSq/rFQ==\'/><input type=\'submit\' value=\'ok\' style=\'display:none;\'\'></form><script>document.forms[\'alipaysubmit\'].submit();</script>'
... ...
... ... @@ -18,6 +18,7 @@ class Doc
'api\\portal\\controller\\IntermediaryController',
'app\\portal\\controller\\CommonController',
'api\\portal\\controller\\OrderController',
'api\\portal\\controller\\ThirdsendController',
],
'filter_method'=>['_empty'],
'return_format' => [
... ...