Merge branch 'wanfang' into dev

# Conflicts:
#	frontend/views/car/info-track.php
dev
曾超新 5 years ago
commit 299b3d625b
  1. 69
      common/models/CarT.php
  2. 2
      common/models/OrderT.php
  3. 8
      frontend/controllers/BusinessOrderController.php
  4. 186
      frontend/controllers/CarController.php
  5. 2
      frontend/controllers/CommonController.php
  6. 5331
      frontend/controllers/DatabaseController.php
  7. 1033
      frontend/controllers/FinanceController.php
  8. 4
      frontend/controllers/FixCarController.php
  9. 2
      frontend/controllers/GiftController.php
  10. 1669
      frontend/controllers/InsurerController.php
  11. 9
      frontend/controllers/MarketingStrategyController.php
  12. 28
      frontend/controllers/PhoneController.php
  13. 253
      frontend/views/car/info-track.php
  14. 4
      frontend/views/car/info.php
  15. 9
      frontend/views/database/a-index.php
  16. 4
      frontend/views/finance/car-update-frame.php
  17. 74
      frontend/views/finance/sel-user-dlg.php
  18. 584
      frontend/views/finance/ticheng-jisuan.php

@ -186,65 +186,6 @@ class CarT extends \common\models\Base
} }
// public function getLocation()
// {
// $name = '';
// switch($this->location) {
// case 1:
// $name = 'A库';
// break;
// case 2:
// $carb=CarBT::findOne(['id'=>$this->id]);
// if($carb->back==1){
// $name = 'B库(新保处理无效库)';
// }else{
// $name = 'B库';
// }
// break;
// case 3:
// $name = 'C库';
// break;
// case 4:
// $name = 'D库';
// $card=CarDT::findOne(['id'=>$this->id]);
// if($card->back==1){
// $name = 'D库(续保处理无效库)';
// }else{
// $name = 'D库';
// }
// break;
// case 5:
// $name = '无效库';
// break;
// case 6:
// $name = 'E库';
// break;
// case 7:
// $name = 'F库';
// break;
// case 8:
// $name = 'F1新保四大公司无效库';
// break;
// case 9:
// $name = 'F2新保其他小公司无效库';
// break;
// case 10:
// $name = 'F3新保正常无效库';
// break;
// case 11:
// $name = 'F4续保四大公司无效库';
// break;
// case 12:
// $name = 'F5续保其他小公司无效库';
// break;
// case 13:
// $name = 'F6续保正常无效库';
// break;
// default:
// $name = '';
// }
// return $name;
// }
public function getLocation() public function getLocation()
{ {
$name = ''; $name = '';
@ -334,4 +275,14 @@ class CarT extends \common\models\Base
return $this->hasOne(CarFT::className(),['id'=>'id']); return $this->hasOne(CarFT::className(),['id'=>'id']);
return null; return null;
} }
public function getOp1()
{
return $this->hasOne(UserT::className(),['id'=>'op1_id']);
}
public function getOp2()
{
return $this->hasOne(UserT::className(),['id'=>'op2_id']);
}
} }

@ -367,7 +367,7 @@ class OrderT extends \common\models\Base
public function getUsers() public function getUsers()
{ {
return $this->hasMany(OrderUserT::class,['order_id'=>'id']); return $this->hasMany(OrderUserT::className(),['order_id'=>'id']);
} }
/** /**

@ -208,7 +208,7 @@ class BusinessOrderController extends FixCarBaseController
if ('' !== $car_no) $query = $query->andWhere(['like', 'car_no', $car_no]); if ('' !== $car_no) $query = $query->andWhere(['like', 'car_no', $car_no]);
if ($status >= 0) $query = $query->andWhere('status = \'' . $status.'\''); if ($status >= 0) $query = $query->andWhere('status = \'' . $status.'\'');
if ('' !== $id_man) $query = $query->andWhere(['like', 'id_man', $id_man]); if ('' !== $id_man) $query = $query->andWhere(['like', 'id_man', $id_man]);
if ('' !== $id_phone) $query = $query->andWhere(['like', 'id_phone', $id_phone]); if ('' !== $id_phone) $query = $query->andWhere(['like', 'id_man_phone', $id_phone]);
if ('' !== $link_man) $query = $query->andWhere(['like', 'link_man', $link_man]); if ('' !== $link_man) $query = $query->andWhere(['like', 'link_man', $link_man]);
if ('' !== $link_phone) $query = $query->andWhere(['like', 'link_phone', $link_phone]); if ('' !== $link_phone) $query = $query->andWhere(['like', 'link_phone', $link_phone]);
if ('' !== $start_time && '' !== $end_time) $query = $query->andWhere('created_at >= \'' . $start_time . '\' AND created_at <=\'' . $end_time . '\''); if ('' !== $start_time && '' !== $end_time) $query = $query->andWhere('created_at >= \'' . $start_time . '\' AND created_at <=\'' . $end_time . '\'');
@ -245,7 +245,7 @@ class BusinessOrderController extends FixCarBaseController
if ('' !== $car_no) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.car_no', $car_no]); if ('' !== $car_no) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.car_no', $car_no]);
if ('' !== $status) $query = $query->joinWith('fix')->andWhere('fix_car_t.status = ' . $status); if ('' !== $status) $query = $query->joinWith('fix')->andWhere('fix_car_t.status = ' . $status);
if ('' !== $id_man) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.id_man', $id_man]); if ('' !== $id_man) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.id_man', $id_man]);
if ('' !== $id_phone) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.id_phone', $id_phone]); if ('' !== $id_phone) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.id_man_phone', $id_phone]);
if ('' !== $link_man) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.link_man', $link_man]); if ('' !== $link_man) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.link_man', $link_man]);
if ('' !== $link_phone) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.link_phone', $link_phone]); if ('' !== $link_phone) $query = $query->joinWith('fix')->andWhere(['like', 'fix_car_t.link_phone', $link_phone]);
if ('' !== $start_time && '' !== $end_time) $query = $query->joinWith('fix')->andWhere('fix_car_t.created_at >= \'' . $start_time . '\' AND fix_car_t.created_at <=\'' . $end_time . '\''); if ('' !== $start_time && '' !== $end_time) $query = $query->joinWith('fix')->andWhere('fix_car_t.created_at >= \'' . $start_time . '\' AND fix_car_t.created_at <=\'' . $end_time . '\'');
@ -385,9 +385,9 @@ class BusinessOrderController extends FixCarBaseController
$info->engine_no = $car_info->engine_no; $info->engine_no = $car_info->engine_no;
$info->car_frame_no = $car_info->car_frame_no; $info->car_frame_no = $car_info->car_frame_no;
$info->id_man = $car_info->id_man; $info->id_man = $car_info->id_man;
$info->id_phone = $car_info->phone; $info->id_man_phone = $car_info->car_man_phone;
$info->link_man = $car_info->car_man; $info->link_man = $car_info->car_man;
$info->link_phone = $car_info->phone; $info->link_man_phone = $car_info->car_man_phone;
$info->company = $car_info->company; $info->company = $car_info->company;
$info->brand_id = $car_info->brand_id; $info->brand_id = $car_info->brand_id;
$info->series_id = $car_info->series_id; $info->series_id = $car_info->series_id;

@ -151,171 +151,6 @@ class CarController extends BaseController
$objWriter = \PHPExcel_IOFactory::createWriter($objectPHPExcel, 'Excel5'); $objWriter = \PHPExcel_IOFactory::createWriter($objectPHPExcel, 'Excel5');
$objWriter->save('php://output'); $objWriter->save('php://output');
} }
//查找平移数据问题
public function actionPingyi()
{
//SELECT * FROM `car_log_t` WHERE `remark` = '从3005(饶丽云) 平移车辆给 3011(柳明芳·)' and `op_time` <'1541548800' and `op_man` ='0002(魏媛)' and `op_time` >'1533081600' ORDER BY `op_time` asc
// ['like', 'name', 'tester']
// ['remark'=>'从3005(饶丽云) 平移车辆给 3011(柳明芳·)'])
$datas=CarLogT::find()->where(['like', 'remark', '平移车辆'])
->andWhere(['<', 'op_time', '1541548800'])
->andWhere(['>', 'op_time', '1533081600'])
->andWhere(['op_man' =>'0002(魏媛)']);
// ->limit(29);
//
$bnum=0;
$enum=0;
$enum1=0;
$enum9=0;
// echo '<pre>';
foreach($datas->each(29) as $b_info) {
//// print_r($b_info->car_id);
// print_r($b_info->remark);
// echo '<br>';
$car= CarT::findOne(['id'=>$b_info->car_id]);
//开始头字母
$bestr=substr($b_info->remark,3,1);
$bestr4=substr($b_info->remark,3,4);
// var_dump($bestr4);
// die;
//分配的工号
$endstr=substr($b_info->remark,35);
// echo '<br>';
// var_dump($bestr);
// echo '<br>';
// var_dump($endstr);
// echo '<br>';
if($bestr==3){
continue;
// $car->op_user3=$endstr;
// $this->addLog($car->id,'补全平移数据问题',1);
$bnum++;
}elseif($bestr==1){
continue;
// $car->op_user1=$endstr;
// $this->addLog($car->id,'补全平移数据问题',1);
$enum++;
}elseif($bestr==2){
// if($bestr4==2057){
// $car->op_user1=$endstr;
// }else{
// continue;
// }
continue;
$enum1++;
}elseif($bestr==9){
// continue;
$car->op_user3=$endstr;
$this->addLog($car->id,'补全平移数据问题',1);
$enum9++;
}else{
continue;
}
//
$car->save();
//// print_r($car);
//
}
var_dump($bnum);
echo '<br>';
var_dump($enum);
echo '<br>';
var_dump($enum1);
echo '<br>';
var_dump($enum9);
// echo $datas->createCommand()->rawSql;
// $datas->all();
// var_dump($datas) ;
// $$datas->all();
// var_dump($datas);
return $this->renderPartial('index');
}
//查找重复的数据
public function actionChongf()
{
//select car_no,count(*) as count from car_t group by car_no having count>1
$num=0;
$cnum=0;
$xnum=0;
$query=CarT::find()->select('car_no,count(*) count,id,location,hiddenes')->groupBy('car_no')->having(['>' ,'count',1])
->where('location=3');
// aa($query);
$data=$query->all();
foreach($data as $vs){
$carlogNum=CarLogT::find()->where(['car_id'=>$vs->id])
// ->andWhere(['remark'=> '从F库分配到C库'])
->andWhere(['or', 'remark="从A库分配到C库"', 'remark="从B库分配到C库"', 'remark="从E库分配到C库"', 'remark="从F库分配到C库"', 'remark="从无效库分配到C库"'])
->count();
if($carlogNum==1){
// dd($info);
$dear= CarT::findOne(['id'=>$vs->id]);
$dear->hiddenes=1;
// $sa=$info->id();
if($dear->save()){
$num++;
}
// echo $info->car_no;
}else{
// $xnum++;
continue;
//
}
}
// foreach($query->each(10) as $info) {
//// $carlogNum=CarLogT::find()->where(['car_id'=>$info->id])->count();
//// if($carlogNum>=1){
//// continue;
//// }else{
//// $num++;
//// }
//
//// if($info->location==3){
//// $cnum++;
//// }else{
//// continue;
//// }
//// ['or', 'id=1', 'id=2']
// $carlogNum=CarLogT::find()->where(['car_id'=>$info->id])
//// ->andWhere(['remark'=> '从F库分配到C库'])
// ->andWhere(['or', 'remark="从A库分配到C库"', 'remark="从B库分配到C库"', 'remark="从E库分配到C库"', 'remark="从F库分配到C库"', 'remark="从无效库分配到C库"'])
// ->count();
// if($carlogNum==1){
//// dd($info);
// $info->hiddenes=1;
//// $sa=$info->save();
// if($info->save()){
// $num++;
// }
//// echo $info->car_no;
//
// }else{
//// $xnum++;
// continue;
////
// }
//
//
//
//
//
// }
// $data= $query->count();
//
// aa($query);
// var_dump($data);
echo $num;
echo '<br>';
// echo $xnum;
// echo $cnum;
}
public function actionJsonData() public function actionJsonData()
{ {
Yii::$app->response->format = Response::FORMAT_JSON; Yii::$app->response->format = Response::FORMAT_JSON;
@ -701,14 +536,6 @@ class CarController extends BaseController
$insurer_company2_items = InsurerCompany2T::find()->all(); $insurer_company2_items = InsurerCompany2T::find()->all();
$pay_type_items = PayTypeT::find()->all(); $pay_type_items = PayTypeT::find()->all();
$car_use_items = CarUseT::find()->all(); $car_use_items = CarUseT::find()->all();
$car_type_items = CarTypeT::find()->all();
$brand_items = BrandT::find()->all();
$series_items = SeriesT::find()
->where('brand_id='.intval($car_info->brand_id))
->all();
$displacement_items = DisplacementT::find()
->where('series_id='.intval($car_info->series_id))
->all();
$direction_items = DirectionT::find() $direction_items = DirectionT::find()
->all(); ->all();
$range_items = RangeT::find() $range_items = RangeT::find()
@ -748,10 +575,6 @@ class CarController extends BaseController
'list' => $list, 'list' => $list,
'pay_type_items' => $pay_type_items, 'pay_type_items' => $pay_type_items,
'car_use_items' => $car_use_items, 'car_use_items' => $car_use_items,
'car_type_items' => $car_type_items,
'brand_items' => $brand_items,
'series_items' => $series_items,
'displacement_items' => $displacement_items,
'direction_items' => $direction_items, 'direction_items' => $direction_items,
'range_items' => $range_items, 'range_items' => $range_items,
'city_items' => $city_items, 'city_items' => $city_items,
@ -4175,9 +3998,8 @@ class CarController extends BaseController
$MessageContent = str_replace("\f","",$MessageContent); $MessageContent = str_replace("\f","",$MessageContent);
$MessageContent = str_replace("\t","",$MessageContent); $MessageContent = str_replace("\t","",$MessageContent);
//$url = 'https://sms.yunpian.com/v2/sms/single_send.json'; $url = 'http://user.banmacar.com/api/sms/single-send';
$url = 'https://www.banmacar.com/api/single-send'; $params['token'] = 'ff7dc73536475c11981a1c52531f2ff7';
$params['token'] = '84c5722fd1455582c53b7195ccef44c2';
$params['mobile'] = $UserNumber; $params['mobile'] = $UserNumber;
$params['content'] = $MessageContent; $params['content'] = $MessageContent;
$post_url = http_build_query($params); $post_url = http_build_query($params);
@ -4188,8 +4010,8 @@ class CarController extends BaseController
$obj = json_decode($msg,true); $obj = json_decode($msg,true);
$result = array(); $result = array();
// $result['success'] = true; // $result['success'] = true;
if($obj['success']) { if($obj['code'] == 200) {
$result['msg'] = $obj['msg']; $result['msg'] = $obj['data'];
}else{ }else{
$result['msg'] = $obj['msg']; $result['msg'] = $obj['msg'];
} }

@ -365,6 +365,8 @@ class CommonController extends \yii\web\Controller
} }
public function actionUpload(){ public function actionUpload(){
set_time_limit(0);
ini_set('memory_limit', '3072M');
Yii::$app->response->format = Response::FORMAT_JSON; Yii::$app->response->format = Response::FORMAT_JSON;
$request = Yii::$app->request; $request = Yii::$app->request;
$data = array(); $data = array();

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

@ -198,7 +198,7 @@ class FixCarController extends BaseController
$info->engine_no = $car_info->engine_no; $info->engine_no = $car_info->engine_no;
$info->car_frame_no = $car_info->car_frame_no; $info->car_frame_no = $car_info->car_frame_no;
$info->id_man = $car_info->id_man; $info->id_man = $car_info->id_man;
$info->id_phone = $car_info->phone; $info->id_man_phone = $car_info->phone;
$info->link_man = $car_info->car_man; $info->link_man = $car_info->car_man;
$info->link_phone = $car_info->phone; $info->link_phone = $car_info->phone;
$info->company = $car_info->company; $info->company = $car_info->company;
@ -398,7 +398,7 @@ class FixCarController extends BaseController
$row->displacement_id = $displacement_id; $row->displacement_id = $displacement_id;
$row->car_year = $car_year; $row->car_year = $car_year;
$row->id_man = $id_man; $row->id_man = $id_man;
$row->id_phone = $id_phone; $row->id_man_phone = $id_phone;
$row->link_man = $link_man; $row->link_man = $link_man;
$row->link_phone = $link_phone; $row->link_phone = $link_phone;
$row->company = $company; $row->company = $company;

@ -998,7 +998,7 @@ class GiftController extends \yii\web\Controller
$query = $query->andWhere('gift_ticket_t_use.type_id='.$type_id); $query = $query->andWhere('gift_ticket_t_use.type_id='.$type_id);
} }
// echo $query->createCommand()->rawSql; // echo $query->createCommand()->rawSql;exit;
$total = $query->count(); $total = $query->count();
$items = $query->offset($offset)->limit($limit)->all(); $items = $query->offset($offset)->limit($limit)->all();
$data = []; $data = [];

File diff suppressed because it is too large Load Diff

@ -4,6 +4,7 @@
namespace frontend\controllers; namespace frontend\controllers;
use common\models\CarT;
use common\models\GiftT; use common\models\GiftT;
use common\models\OrderGiftT; use common\models\OrderGiftT;
use common\models\UserT; use common\models\UserT;
@ -462,11 +463,17 @@ class MarketingStrategyController extends UserBaseController
$result['success'] = false; $result['success'] = false;
$result['msg'] = '没有合适的策略'; $result['msg'] = '没有合适的策略';
$car_id = $request->post('car_id');
$total1_clear = $request->post('total1_clear', 0); $total1_clear = $request->post('total1_clear', 0);
$car_no = $request->post('car_no'); $car_no = $request->post('car_no');
$car_use_id = $request->post('car_use_id', 0); $car_use_id = $request->post('car_use_id', 0);
$company2_id = $request->post('company2_id', 0); $company2_id = $request->post('company2_id', 0);
$car_info = CarT::findOne($car_id);
if(!$car_info) {
$result['msg'] = '车辆信息不存在';
return $result;
}
//获取自己的所有策略 //获取自己的所有策略
$items = ZhongjiUserT::find() $items = ZhongjiUserT::find()
->where(['user_id'=>$this->my->id]) ->where(['user_id'=>$this->my->id])
@ -519,7 +526,7 @@ class MarketingStrategyController extends UserBaseController
if($item->type_ids != '') { if($item->type_ids != '') {
$type_ids = explode(',',$item->type_ids); $type_ids = explode(',',$item->type_ids);
$tmp_type_id = 1; $tmp_type_id = 1;
if($car_no->xubao_num > 0) if($car_info->is_xubao > 0)
$tmp_type_id = 2; $tmp_type_id = 2;
if(in_array($tmp_type_id, $type_ids)) { if(in_array($tmp_type_id, $type_ids)) {
$flag = true; $flag = true;

@ -286,7 +286,6 @@ class PhoneController extends \yii\web\Controller
//$b = new GiftCreateImageErrorT(); //$b = new GiftCreateImageErrorT();
$network_phone = NetworkPhoneT::findOne(['recorder_id'=>$recorder_id]); $network_phone = NetworkPhoneT::findOne(['recorder_id'=>$recorder_id]);
if(!$network_phone){ if(!$network_phone){
$network_phone = new NetworkPhoneT(); $network_phone = new NetworkPhoneT();
$assign = NetworkPhoneAssignT::findOne(['phone'=>$caller,'is_phone'=>1]); $assign = NetworkPhoneAssignT::findOne(['phone'=>$caller,'is_phone'=>1]);
if(!$assign){ if(!$assign){
@ -372,33 +371,6 @@ class PhoneController extends \yii\web\Controller
} }
return json_encode(['code' => 0,'message' => "成功"]); return json_encode(['code' => 0,'message' => "成功"]);
$phone_items = NetworkPhoneT::find()->where('release_time>="'.$begin_time.'"')
->andWhere('release_time<="'.$end_time.'"')
->andWhere('call_result="ANSWERED"')
->andWhere('record_file_url is null or record_file_url = ""')
->andWhere('record_file_url_real is not null or record_file_url_real <> ""')
->all();
foreach ($phone_items as $item) {
if ($item->record_file_url == '') {
$url = '';
if ($item->record_file_url_real != '') {
$url = $this->phoneMp3($item->record_file_url_real);
}
if ($url != '') {
$item->record_file_url = $url;
$item->save(false);
}
}
}
return json_encode(['code' => 0,'message' => "成功"]);
} }
function phoneMp3Bak($url) { function phoneMp3Bak($url) {

@ -0,0 +1,253 @@
<?php
use \common\libs\MyLib;
?>
<?php $this->beginBlock('header_css'); ?>
<link href="/assets/css/plugins/bootstrap-table/bootstrap-table.min.css" rel="stylesheet">
<style>
label.control-label {
width: 70px;
}
.form-inline .form-control {
width: 180px;
}
</style>
<?php $this->endBlock(); ?>
<div class="wrapper wrapper-content animated fadeInRight">
<div class="ibox float-e-margins">
<div class="ibox-title">
<h5>车辆信息</h5>
</div>
<div class="ibox-content">
<table class="table table-bordered">
<tr>
<th class="bg-warning">车牌号</th>
<td><?=$car_info->car_no?></td>
<th class="bg-warning" nowrap>初登日期</th>
<td><?=$car_info->register_date?></td>
<th class="bg-warning" nowrap>座位数</th>
<td><?=$car_info->seats?></td>
<th class="bg-warning" nowrap>新车购置价</th>
<td><?=$car_info->purchase_price?></td>
</tr>
<tr>
<th class="bg-warning">车型</th>
<td><?=$car_info->factory_model?></td>
<th class="bg-warning" nowrap>发动机号</th>
<td><?=$car_info->engine_no?></td>
<th class="bg-warning" nowrap>车架号</th>
<td><?=$car_info->car_frame_no?></td>
<th class="bg-warning" nowrap>车辆使用性质</th>
<td><?=$car_info->carUse->name?></td>
</tr>
<tr>
<th class="bg-warning">车主</th>
<td><?=$car_info->car_man?></td>
<th class="bg-warning">证件类型</th>
<td><?=$car_info->car_man_type?></td>
<th class="bg-warning">证件号码</th>
<td><?=$car_info->car_man_number?></td>
<th class="bg-warning">联系电话</th>
<td><?=$car_info->car_man_phone?></td>
</tr>
<tr>
<th class="bg-warning" nowrap>商业起保日期</th>
<td><?=$car_info->insurer1_date?></td>
<th class="bg-warning" nowrap>交强起保日期</th>
<td><?=$car_info->insurer2_date?></td>
<th class="bg-warning">保险公司</th>
<td><?=$car_info->company?></td>
<th class="bg-warning"></th>
<td></td>
</tr>
</table>
</div>
</div>
<div class="ibox float-e-margins">
<div class="ibox-title">
<h5>预约信息</h5>
<div class="ibox-tools">
<a class="btn btn-primary btn-xs edit-btn" data-id="0" href="javascript:void(0);" onclick="$('#appointmentTable').bootstrapTable('refresh');">
<i class="fa fa-refresh"></i> 刷新
</a>
</div>
</div>
<div class="ibox-content">
<table id="appointmentTable">
<thead>
<tr>
<th data-field="pdate">预约日期</th>
<th data-field="ptime">预约时间</th>
<th data-field="remark">预约备注</th>
<th data-field="user">业务员</th>
<th data-field="updated_at">操作时间</th>
</tr>
</thead>
</table>
</div>
</div>
<div class="ibox float-e-margins">
<div class="ibox-title">
<h5>保单信息</h5>
<div class="ibox-tools">
<a class="btn btn-primary btn-xs edit-btn" data-id="0" href="javascript:void(0);" onclick="$('#orderTable').bootstrapTable('refresh');">
<i class="fa fa-refresh"></i> 刷新
</a>
</div>
</div>
<div class="ibox-content">
<table id="orderTable">
<thead>
<tr>
<th data-field="id">ID</th>
<th data-field="id_man">被保险人</th>
<th data-field="insurer1_begin_date">商业起保日期</th>
<th data-field="insurer2_begin_date">交强起保日期</th>
<th data-field="print_date">出单日期</th>
<th data-field="total_all">共计签单</th>
<th data-field="username">业务员</th>
<th data-field="status">状态</th>
<th data-formatter="orderFormatter">操作</th>
</tr>
</thead>
</table>
</div>
</div>
<div class="ibox float-e-margins">
<div class="ibox-title">
<h5>礼券信息</h5>
<div class="ibox-tools">
<a class="btn btn-primary btn-xs edit-btn" data-id="0" href="javascript:void(0);" onclick="$('#giftTable').bootstrapTable('refresh');">
<i class="fa fa-refresh"></i> 刷新
</a>
</div>
</div>
<div class="ibox-content">
<table id="giftTable">
<thead>
<tr>
<th width="50" data-field="id">ID</th>
<th data-field="code">礼券编号</th>
<th data-field="name">礼品</th>
<th data-field="car_no">车牌号</th>
<th data-field="car_frame_no">车架号</th>
<th data-field="input_date">发放日期</th>
<th data-field="end_date">有效期日期</th>
<th data-field="submit_user">提单人</th>
<th data-field="use_date">使用日期1</th>
<th data-field="status">状态</th>
<th data-field="username">操作员</th>
</tr>
</thead>
</table>
</div>
</div>
<div class="ibox float-e-margins">
<div class="ibox-title">
<h5>操作记录</h5>
<div class="ibox-tools">
<a class="btn btn-primary btn-xs edit-btn" data-id="0" href="javascript:void(0);" onclick="$('#logTable').bootstrapTable('refresh');">
<i class="fa fa-refresh"></i> 刷新
</a>
</div>
</div>
<div class="ibox-content">
<table id="logTable">
<thead>
<tr>
<th data-field="op_man">操作者</th>
<th data-field="op_time">操作时间</th>
<th data-field="remark">操作内容</th>
</tr>
</thead>
</table>
</div>
</div>
</div>
<?php $this->beginBlock('footer_js'); ?>
<script src="/assets/js/plugins/bootstrap-table/bootstrap-table.min.js"></script>
<script src="/assets/js/plugins/bootstrap-table/bootstrap-table-mobile.min.js"></script>
<script src="/assets/js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script>
<script type="text/javascript" language="javascript">
var o = {};
function orderFormatter(value, row, index) {
var opStr = [];
opStr.push('<a href="javascript:void(0);" onclick="viewOrder(' + row.id + ')">');
opStr.push('<i class="fa fa-file-o" title="详情"></i>');
opStr.push('</a>');
return opStr.join(' ');
}
function viewOrder(id) {
window.open('/insurer/info?id=' + id);
}
function searchGifts() {
$('#giftTable').bootstrapTable('destroy');
$('#giftTable').bootstrapTable({
url: "/gift/ticket-use-json",
pagination: true,
sidePagination: 'server',
queryParams: function(params) {
o['car_id'] = '<?=$car_info->id?>';
o['limit'] = params['limit'];
o['offset'] = params['offset'];
return o;
}
});
return false;
}
function searchOrders() {
$('#orderTable').bootstrapTable('destroy');
$('#orderTable').bootstrapTable({
url: "/car/order-history-json",
pagination: true,
sidePagination: 'server',
multipleSelectRow: true,
queryParams: function(params) {
o['car_id'] = '<?=$car_info->id?>';
o['limit'] = params['limit'];
o['offset'] = params['offset'];
return o;
}
});
}
function searchOps() {
$('#logTable').bootstrapTable('destroy');
$('#logTable').bootstrapTable({
url: "/car/history-json",
pagination: true,
sidePagination: 'server',
multipleSelectRow: true,
queryParams: function(params) {
o['car_id'] = '<?=$car_info->id?>';
o['limit'] = params['limit'];
o['offset'] = params['offset'];
return o;
}
});
}
function searchAppointments() {
$('#appointmentTable').bootstrapTable('destroy');
$('#appointmentTable').bootstrapTable({
url: "/appointment/history-json",
pagination: true,
sidePagination: 'server',
multipleSelectRow: true,
queryParams: function(params) {
o['car_id'] = '<?=$car_info->id?>';
o['limit'] = params['limit'];
o['offset'] = params['offset'];
return o;
}
});
}
$(function () {
searchAppointments();
searchOps();
searchOrders();
searchGifts();
});
</script>
<?php $this->endBlock('footer_js'); ?>

@ -50,8 +50,8 @@ use \common\libs\MyLib;
</div> </div>
<label class="col-sm-1 control-label">联系电话</label> <label class="col-sm-1 control-label">联系电话</label>
<div class="col-sm-3"> <div class="col-sm-3">
<label class="form-control-static"><?=$car_info->phone?></label> <label class="form-control-static"><?=$car_info->car_man_phone?></label>
<a class="btn btn-primary btn-bitbucket" onclick="sendMsg('ATD','<?=$car_info->phone?>')"> <a class="btn btn-primary btn-bitbucket" onclick="sendMsg('ATD','<?=$car_info->car_man_phone?>')">
<i class="fa fa-phone"></i> <i class="fa fa-phone"></i>
</a> </a>
<a class="btn btn-danger btn-bitbucket" onclick="sendMsg('ATH')"> <a class="btn btn-danger btn-bitbucket" onclick="sendMsg('ATH')">

@ -60,6 +60,15 @@ use \common\libs\MyLib;
<input type="text" class="input-sm form-control" id="insurer1_end" name="insurer1_end" value="" autocomplete="off" /> <input type="text" class="input-sm form-control" id="insurer1_end" name="insurer1_end" value="" autocomplete="off" />
</div> </div>
</div> </div>
<div class="form-group" style="margin-bottom: 8px;">
<label for="engine_no">使用性质</label>
<select name="car_use_id" id="car_use_id" class="form-control">
<option value="0">全部</option>
<?php foreach($car_use_items as $item) {
echo '<option value="'.$item->id.'">'.$item->name.'</option>';
} ?>
</select>
</div>
<div class="form-group" style="margin-bottom: 8px;"> <div class="form-group" style="margin-bottom: 8px;">
<label for="b_lib">范围</label> <label for="b_lib">范围</label>
<div class="checkbox checkbox-inline"> <div class="checkbox checkbox-inline">

@ -68,8 +68,12 @@ use \common\libs\MyLib;
btn: ['确认','取消'], //按钮 btn: ['确认','取消'], //按钮
shade: false //不显示遮罩 shade: false //不显示遮罩
}, function(){ }, function(){
var index = parent.layer.load(1, {
shade: [0.1,'#fff'] //0.1透明度的白色背景
});
var params = $("#theFrm").serialize(); var params = $("#theFrm").serialize();
$.post('/finance/car-update-frame-info',params,function(obj){ $.post('/finance/car-update-frame-info',params,function(obj){
parent.layer.close(index);
parent.layer.msg(obj.msg); parent.layer.msg(obj.msg);
if(obj.success) { if(obj.success) {
window.location.reload(); window.location.reload();

@ -0,0 +1,74 @@
<?php
use \common\libs\MyLib;
?>
<?php $this->beginBlock('header_css'); ?>
<?php $this->endBlock(); ?>
<div class="wrapper wrapper-content animated fadeInRight">
<div class="ibox float-e-margins">
<div class="ibox-content">
<form role="form" class="form-inline" id="searchFrm">
<div class="form-group">
<label for="username">搜索工号</label>
<input type="text" id="username" name="username" class="form-control" autocomplete="off">
</div>
<div class="form-group">
<label for="group_id">级别</label>
<select name="group_id" id="group_id" class="form-control">
<option value="0">全部</option>
<?php
foreach($group_items as $item) {
echo '<option value="'.$item->id.'"';
if($item->id == $group_id)
echo ' selected ';
echo '>'.$item->name.'</option>';
}
?>
</select>
</div>
<button type="button" onclick="search()" class="form-control">搜索</button>
</form>
<hr>
<form role="form" id="theFrm" class="form-horizontal">
<div class="form-group">
<div class="col-sm-12" id="users"></div>
</div>
<button type="button" class="col-sm-offset-2 btn btn-primary btn-save">添加</button>
</form>
</div>
</div>
</div>
<?php $this->beginBlock('footer_js'); ?>
<script type="text/javascript" language="javascript">
function search() {
var params = $('#searchFrm').serialize();
$('#users').html('');
$.get('/finance/sel-user-search?' + params, function(obj) {
if(obj.success) {
obj.users.forEach(function(item, index) {
var html = '<div class="checkbox checkbox-inline">';
html += '<input type="checkbox" id="user_' + item.id + '" name="ids[]" value="' + item.username + '">';
html += '<label for="user_' + item.id + '"> ' + item.name + ' </label>';
html += '</div>';
$('#users').html( $('#users').html() + html);
});
}
},'json');
}
$(function () {
search();
//提交按钮
$(".btn-save").click(function(){
var str = [];
$('input:checkbox:checked').each(function(index, item) {
str.push($(item).val());
});
parent.$('#<?=$id_name?>').val(str.join(','));
layer_close();
});
})
</script>
<?php $this->endBlock('footer_js'); ?>

@ -1,369 +1,239 @@
<?php <?php
use \common\libs\MyLib; use \common\libs\MyLib;
use common\models\OrderGiftT;
?> ?>
<?php $this->beginBlock('header_css'); ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table"> <link href="/assets/css/plugins/bootstrap-table/bootstrap-table.min.css" rel="stylesheet">
<form id="searchForm"> <?php $this->endBlock(); ?>
<tr>
<td class="td_bg"> <div class="wrapper wrapper-content animated fadeInRight">
<!--新增搜索项--> <div class="ibox float-e-margins">
<!--完成程度--> <div class="ibox-title">
业务员:<input name="user_names" id="user_names" user_ids="" type="text" style="width:60%;" value="<?=$user_names?>"> <h5>车险提成管理</h5>
<br>模糊<input name="select_user" id="select_user" type="text" style="width:100px;" value=""> <div class="ibox-tools">
<input type="checkbox" id="all" value="1">全选&nbsp;&nbsp; <a class="btn btn-primary btn-xs edit-btn" data-id="0" href="javascript:void(0);" onclick="$('#listTable').bootstrapTable('refresh');">
<input type="checkbox" id="no_num" value="1">非数字&nbsp;&nbsp; <i class="fa fa-refresh"></i> 刷新
<input type="button" class="act_btn" id="add-user" name="add-user" value="+工号"> </a>
<input type="checkbox" id="is_fan" value="1" <?=$is_fan==1?'checked':''?>>取反&nbsp;&nbsp; </div>
</div>
<br> <div class="ibox-content">
<form role="form" id="searchFrm" class="form-inline" onsubmit="return search();">
车牌类型:<select name="car_no_type"> <div class="form-group" style="margin-bottom: 8px;">
<option value="0" >所有类型</option> <label for="car_no">业务员</label>
<option value="1" <?= $car_no_type == 1 ? 'selected': ''?>>京牌</option> <div class="input-group">
<option value="2" <?= $car_no_type == 2 ? 'selected': ''?>>非京牌</option> <input type="text" id="user_names" name="user_names" class="form-control">
<option value="3" <?= $car_no_type == 3 ? 'selected': ''?>>特殊车辆</option> <a class="input-group-addon" onclick="selUserDlg('user_names')">+</a>
</select> </div>
</div>
险种类型:<select name="insurer_type"> <div class="form-group" style="margin-bottom: 8px;">
<option value="1" <?= $insurer_type == 1 ? 'selected': ''?>>商业</option> <label for="engine_no">车牌类型</label>
<option value="2" <?= $insurer_type == 2 ? 'selected': ''?>>商业+交强</option> <select name="car_no_type" class="form-control">
</select> <option value="0" >所有类型</option>
<option value="1">京牌</option>
保险公司:<select name="company_id"> <option value="2">非京牌</option>
<option value="0">所有公司</option> </select>
<?php </div>
foreach($company_items as $item) { <div class="form-group" style="margin-bottom: 8px;">
echo '<option value="'.$item->id.'"'; <label for="engine_no">保险公司</label>
if($item->id == $company_id) <select name="company_id" class="form-control">
echo ' selected '; <option value="0">全部</option>
echo '>'.$item->name.'</option>'; <?php
} foreach($company_items as $item) {
?> echo '<option value="'.$item->id.'">'.$item->name.'</option>';
</select> }
车牌号:<input name="car_no" type="text" value="<?=$car_no?>"> ?>
<!--日期--> </select>
出单日期: </div>
<input type="Text" class="Wdate" name="begin_date" onclick="WdatePicker()" value="<?= $begin_date ?>" autocomplete="off" /> <div class="form-group" style="margin-bottom: 8px;">
-- <label for="engine_no">险种类型</label>
<input type="Text" class="Wdate" name="end_date" onclick="WdatePicker()" value="<?= $end_date ?>" autocomplete="off"/> <select name="insurer_type" class="form-control">
&nbsp;&nbsp;<br>商业净保费: <option value="1">商业</option>
<input type="Text" class="" name="begin_totalclear" " value="<?= $begin_totalclear ?>" /> <option value="2">商业+交强</option>
-- </select>
<input type="Text" class="" name="end_totalclear" " value="<?= $end_totalclear?>" /> </div>
级别:<select name="group_id"> <div class="form-group" style="margin-bottom: 8px;">
<option value="0">全部</option> <label for="engine_no">车牌号</label>
<?php <input type="text" id="car_no" name="car_no" class="form-control">
foreach($group_items as $item) { </div>
echo '<option value="'.$item->id.'"'; <div class="form-group" style="margin-bottom: 8px;">
if($item->id == $group_id) <label for="datepicker1">出单日期</label>
echo ' selected '; <div class="input-group input-daterange" id="datepicker1">
echo '>'.$item->name.'</option>'; <input type="text" class="input-sm form-control" id="begin_date" name="begin_date" value="" autocomplete="off" />
} <span class="input-group-addon"></span>
?> <input type="text" class="input-sm form-control" id="end_date" name="end_date" value="" autocomplete="off" />
</select> </div>
</div>
<input type="button" class="act_btn" id="search-btn" name="search-btn" value="搜索"> <div class="form-group" style="margin-bottom: 8px;">
<input type="button" class="act_btn" id="output-btn" name="output-btn" value="导出"> <label for="engine_no">商业净保费</label>
<div class="input-group">
</td> <input type="text" id="begin_totalclear" name="begin_totalclear" class="form-control">
</tr> <div class="input-group-addon">-</div>
<input type="text" id="end_totalclear" name="end_totalclear" class="form-control">
</table> </div>
</div>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table"> <div class="form-group" style="margin-bottom: 8px;">
<label for="engine_no">级别</label>
<tr> <select name="group_id" class="form-control">
<td class="td_bg"> <option value="0">全部</option>
基本提成比例:<input name="yeji_rate" type="text" value="<?=$yeji_rate?>">% <?php
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; foreach($group_items as $item) {
团队长组: echo '<option value="'.$item->id.'">'.$item->name.'</option>';
<select name="dz_group"> }
<option value="0">请选择</option> ?>
<option value="1" <?php if($dz_group == 1){echo 'selected';}?>>团队长组1</option> </select>
<option value="2" <?php if($dz_group == 2){echo 'selected';}?>>团队长组2</option> </div>
<option value="3" <?php if($dz_group == 3){echo 'selected';}?>>团队长组3</option> <button type="submit" class="btn btn-primary mb-8">搜索</button>
<option value="4" <?php if($dz_group == 4){echo 'selected';}?>>团队长组4</option> <button type="button" class="btn btn-primary mb-8">导出</button>
<option value="5" <?php if($dz_group == 5){echo 'selected';}?>>团队长组5</option> <hr>
</select> <div class="form-group" style="margin-bottom: 8px;">
团队长提成比例:<input name="dz_rate" type="text" value="<?=$dz_rate?>">% <label for="engine_no">基本提成比例</label>
&nbsp;&nbsp; <input type="text" id="yeji_rate" name="yeji_rate" class="form-control">
团队长:<input name="dz_names" id="dz_names" type="text" style="width:30%;" value="<?=$dz_names?>"> </div>
<input type="button" class="act_btn" id="add-dz" name="add-dz" value="+工号"> <div class="form-group" style="margin-bottom: 8px;">
<label for="engine_no">团队长组</label>
</td> <select name="dz_group" class="form-control">
</tr> <option value="0">请选择</option>
<option value="1">团队长组1</option>
<tr> <option value="2">团队长组2</option>
<td class="td_bg"> <option value="3">团队长组3</option>
<!--新增搜索项--> <option value="4">团队长组4</option>
<!--完成程度--> <option value="5">团队长组5</option>
</select>
核保提成:<input name="hebao_ticheng" type="text" value="<?=$hebao_ticheng?>">&nbsp;&nbsp; </div>
正本提成:<input name="zhengben_ticheng" type="text" value="<?=$zhengben_ticheng?>">&nbsp;&nbsp; <div class="form-group" style="margin-bottom: 8px;">
送单提成:<input name="songdan_ticheng" type="text" value="<?=$songdan_ticheng?>">&nbsp;&nbsp; <label for="engine_no">团队长提成比例</label>
原新保提成比例:<input name="first_xinbao_rate" type="text" value="<?=$first_xinbao_rate?>">% <input type="text" id="dz_rate" name="dz_rate" class="form-control">
</div>
<div class="form-group" style="margin-bottom: 8px;">
<input type="button" class="act_btn" id="jisuan-btn" name="jisuan-btn" value="计算"> <label for="engine_no">团队长</label>
<!-- <input type="button" class="act_btn" id="output-btn" name="output-btn" value="导出">--> <div class="input-group">
</td> <input type="text" id="dz_names" name="dz_names" class="form-control">
</tr> <a class="input-group-addon" onclick="selUserDlg('dz_names')">+</a>
</form> </div>
</table> </div>
<div class="form-group" style="margin-bottom: 8px;">
<table width="98%" border="0" align="center" cellpadding="2" cellspacing="1" class="table"> <label for="engine_no">核保提成</label>
<tr> <input type="text" id="hebao_ticheng" name="hebao_ticheng" class="form-control">
<td width="24" align="center" class="bg_tr">序号</td> </div>
<td align="center" class="bg_tr">车牌号</td> <div class="form-group" style="margin-bottom: 8px;">
<td align="center" class="bg_tr">被保险人</td> <label for="engine_no">正本提成</label>
<td align="center" class="bg_tr">保险公司</td> <input type="text" id="zhengben_ticheng" name="zhengben_ticheng" class="form-control">
<td align="center" class="bg_tr">保单号</td> </div>
<td align="center" class="bg_tr">出单日期</td> <div class="form-group" style="margin-bottom: 8px;">
<td align="center" class="bg_tr">商业净保费</td> <label for="engine_no">送单提成</label>
<td align="center" class="bg_tr">手续费比例</td> <input type="text" id="songdan_ticheng" name="songdan_ticheng" class="form-control">
<td align="center" class="bg_tr">基本提成比例</td> </div>
<td align="center" class="bg_tr">基本提成</td> <div class="form-group" style="margin-bottom: 8px;">
<td align="center" class="bg_tr">加点提成比例</td> <label for="engine_no">原新保提成比例</label>
<td align="center" class="bg_tr">加点提成</td> <input type="text" id="first_xinbao_rate" name="first_xinbao_rate" class="form-control">
<td align="center" class="bg_tr">自费礼品</td> </div>
<td align="center" class="bg_tr">自费礼券</td> <button type="button" class="btn btn-primary mb-8 calc-btn">计算</button>
<td align="center" class="bg_tr">自费减免金额</td> <hr>
<td align="center" class="bg_tr">提成</td> </form>
<td align="center" class="bg_tr">业务员</td> <div class="row">
<td align="center" class="bg_tr">原新保提成</td> <div class="col-md-12">
<td align="center" class="bg_tr">原新保业务员</td> <table id="listTable">
<td align="center" class="bg_tr">核保提成</td> <thead>
<td align="center" class="bg_tr">核保业务员</td> <tr>
<td align="center" class="bg_tr">正本提成</td> <th data-field="state" data-checkbox="true"></th>
<td align="center" class="bg_tr">正本业务员</td> <th width="50" data-field="id">ID</th>
<td align="center" class="bg_tr">送单提成</td> <th data-field="car_no">车牌号</th>
<td align="center" class="bg_tr">送单人</td> <th data-field="id_man">被保险人</th>
<td align="center" class="bg_tr">团队长组1提成</td> <th data-field="company_name">保险公司</th>
<td align="center" class="bg_tr">团队长组1</td> <th data-field="insurer_no">保单号</th>
<td align="center" class="bg_tr">团队长组2提成</td> <th data-field="print_date">出单日期</th>
<td align="center" class="bg_tr">团队长组2</td> <th data-field="total_clear">商业净保费</th>
<td align="center" class="bg_tr">团队长组3提成</td> <th data-field="total_rate">手续费比例</th>
<td align="center" class="bg_tr">团队长组3</td> <th data-field="yeji_rate">基本提成比例</th>
<td align="center" class="bg_tr">团队长组4提成</td> <th data-field="yeji_ticheng">基本提成</th>
<td align="center" class="bg_tr">团队长组4</td> <th data-field="ticheng_zong_rate">加点提成比例</th>
<td align="center" class="bg_tr">团队长组5提成</td> <th data-field="ticheng_money">加点提成</th>
<td align="center" class="bg_tr">团队长组5</td> <th data-field="gift1_price">自费礼品</th>
</tr> <th data-field="gift2_price">自费礼券</th>
<?php <th data-field="yuangong_money">自费减免金额</th>
foreach($items as $index => $item) { <th data-field="yewu_ticheng">提成</th>
$start_index = $index; <th data-field="op_user">业务员</th>
<th data-field="first_xinbao_ticheng">原新保提成</th>
// $users=$item->user->group; <th data-field="op_user1">原新保业务员</th>
// $username=$item->user; <th data-field="hebao_ticheng">核保提成</th>
// $uname=$username['name']; <th data-field="op1_user">核保业务员</th>
// $nams=$users['name']; <th data-field="zhengben_ticheng">正本提成</th>
<th data-field="op2_user">正本业务员</th>
$total_real = $item->total * $item->total_rate/100; <th data-field="dz_ticheng1">团队长组1提成</th>
$total_clear_real = $item->total_clear * $item->total_rate/100; <th data-field="dz_names1">团队长组1</th>
$total_dis = round($total_clear_real - $item->r_total,2); <th data-field="dz_ticheng2">团队长组2提成</th>
<th data-field="dz_names2">团队长组2</th>
$order_caiwu_info = $item->orderCaiwu; <th data-field="dz_ticheng3">团队长组3提成</th>
$order_info = $item->order; <th data-field="dz_names3">团队长组3</th>
$car_info = $order_info->car; <th data-field="dz_ticheng4">团队长组4提成</th>
<th data-field="dz_names4">团队长组4</th>
$is_xinbao = $car_info->op_user3 == ''?1:0; <th data-field="dz_ticheng5">团队长组5提成</th>
<th data-field="dz_names5">团队长组5</th>
?> </tr>
<tr style="height:24px;" onMouseOver="overColor(this)" onMouseOut="outColor(this)"> </thead>
<td align="center" class="td_bg" nowrap><?=$start_index+1?></td> </table>
<td align="center" class="td_bg" nowrap><?=$item->car_no?></td> </div>
<td align="center" class="td_bg" nowrap><?=$item->id_man?></td> </div>
<td align="center" class="td_bg" nowrap><?=$order_info && $order_info->company ? $order_info->company->name:''?></td> </div>
<td align="center" class="td_bg" nowrap><?=$item->insurer_no?></td> </div>
<td align="center" class="td_bg" nowrap><?=$order_info ? $order_info->print_date : ''?></td> </div>
<td align="center" class="td_bg" nowrap><?=$item->total_clear?></td>
<td align="center" class="td_bg" nowrap><?=$item->total_rate?></td> <?php $this->beginBlock('footer_js'); ?>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->yeji_rate:''?></td> <script src="/assets/js/plugins/bootstrap-table/bootstrap-table.min.js"></script>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->yeji_ticheng:''?></td> <script src="/assets/js/plugins/bootstrap-table/bootstrap-table-mobile.min.js"></script>
<td align="center" class="td_bg" nowrap><?=$order_info?$order_info->ticheng_zong_rate:''?></td> <script src="/assets/js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script>
<td align="center" class="td_bg" nowrap><?=$order_info?$order_info->ticheng_money:''?></td> <script>
var o = {};
<td align="center" class="td_bg" nowrap><?=$order_info?$order_info->getGiftPrice(1,1):''?></td>
<td align="center" class="td_bg" nowrap><?=$order_info?$order_info->getGiftPrice(1,2):''?></td> function selUserDlg(name) {
<td align="center" class="td_bg" nowrap><?=$order_info?$order_info->yuangong_money:''?></td> title = '选择用户';
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->yewu_ticheng:''?></td> layer_show(title, '/finance/sel-user-dlg?name='+name);
<?php if($is_xinbao ==1):?>
<td align="center" class="td_bg" nowrap><?=$car_info?$car_info->op_user1:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->first_xinbao_ticheng:''?></td>
<td align="center" class="td_bg" nowrap></td>
<?php else:?>
<td align="center" class="td_bg" nowrap><?=$car_info?$car_info->op_user3:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->first_xinbao_ticheng:''?></td>
<td align="center" class="td_bg" nowrap><?=$car_info?$car_info->op_user1:''?></td>
<?php endif;?>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->hebao_ticheng:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_info->op1?$order_info->op1->getShowName():''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->zhengben_ticheng:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_info->op2?$order_info->op2->getShowName():''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->songdan_ticheng:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_info->sendLog?$order_info->sendLog->user->getShowName():''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_ticheng1:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_names1:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_ticheng2:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_names2:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_ticheng3:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_names3:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_ticheng4:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_names4:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_ticheng5:''?></td>
<td align="center" class="td_bg" nowrap><?=$order_caiwu_info?$order_caiwu_info->dz_names5:''?></td>
</tr>
<?php
} }
?>
<tr>
<td align="center" class="td_bg" nowrap>合计</td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap>总合计保费</td>
<td align="center" class="td_bg" nowrap><?=number_format($total1_clear_all+$total2_clear_all,2)?></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap><?=number_format($total1_clear_all,2)?></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap><?=number_format($yeji_ticheng_all,2)?></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap><?=number_format($ticheng_money_all,2)?></td>
<td align="center" class="td_bg" nowrap><?=number_format($lipin_all,2)?></td>
<td align="center" class="td_bg" nowrap><?=number_format($liquan_all,2)?></td>
<td align="center" class="td_bg" nowrap><?=number_format($yuangong_money_all,2)?></td>
<td align="center" class="td_bg" nowrap><?=number_format($yewu_ticheng_all,2)?></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
<td align="center" class="td_bg" nowrap></td>
</tr>
<tr >
<td height="25" colspan="18" align="center" class="td_bg"><?=$page_info?></td>
</tr>
</table>
<link href="/css/fSelect.css" rel="stylesheet" type="text/css"> function refreshList() {
<script type="text/javascript" language="javascript" src="/js/jquery-1.8.3.js"></script> $('#listTable').bootstrapTable('refresh');
<script type="text/javascript" language="javascript" src="/js/datepicker/WdatePicker.js"></script>
<script type="text/javascript" language="javascript" src="/js/fileupload/js/vendor/jquery.ui.widget.js"></script>
<script type="text/javascript" language="javascript" src="/js/fileupload/js/jquery.iframe-transport.js"></script>
<script type="text/javascript" language="javascript" src="/js/fileupload/js/jquery.fileupload.js"></script>
<link rel="stylesheet" href="../Myfile/css/font.css?v=20190611">
<link rel="stylesheet" href="../Myfile/css/xadmin.css?v=20190605">
<link rel="stylesheet" href="../Myfile/css/theme274.min.css?v=20190605">
<script type="text/javascript" language="javascript" src="/js/jquery-1.8.3.js"></script>
<script src="../Myfile/lib/layui/layui.js?v=20190611" charset="utf-8"></script>
<script type="text/javascript" src="../Myfile/js/xadmin.js?v=20190612"></script>
<script type="text/javascript" language="javascript" src="/js/ajax.js?v=2019"></script><script type="text/javascript" language="javascript" src="/js/func.js"></script>
<script src="/gg_bd_ad_720x90.js" type="text/javascript"></script>
<script src="/follow.js" type="text/javascript"></script>
<script src="/js/fSelect.js"></script>
<script type="text/javascript" language="javascript" src="/js/artDialog/artDialog.js?skin=default"></script>
<script type="text/javascript" language="javascript" src="/js/artDialog/plugins/iframeTools.source.js"></script>
<script type="text/javascript" language="javascript">
function edit(id) {
var params = $('#searchForm').serialize();
window.location.href = '/finance/receipt-info?id=' + id + '&back_params=' + encodeURIComponent(params);
} }
function search() {
$(function () { o = {};
var params = $("#searchFrm").serializeArray();
//搜索 $.each(params, function(index) {
$("#search-btn").click(function(){ o[this['name']] = this['value'];
$('#page').val(0);
var params = $('#searchForm').serialize() + '&user_ids=' + $('.user_names').val() + '&is_fan=' + $('#is_fan:checked').val();
window.location.href = "/finance/ticheng-jisuan?" + params;
}); });
$("#output-btn").click(function () { $('#listTable').bootstrapTable('destroy');
$('#page').val(0); $('#listTable').bootstrapTable({
var params = $('#searchForm').serialize(); url: "/finance/ticheng-jisuan-json",
//window.location.href = "/finance/receipt-output?" + params; pagination: true,
var url = "/finance/receipt-ticheng-output"; sidePagination: 'server',
multipleSelectRow: true,
$.get(url, params, function (obj) { queryParams: function(params) {
alert(obj.msg); o['offset'] = params['offset'];
if (obj.success) { o['limit'] = params['limit'];
window.location.href = obj.files[0].src; return o;
} }
}, 'json');
});
$("#jisuan-btn").click(function(){
var last_url = '/finance/jisuan-save';
var params = $("#searchForm").serialize() + '&user_ids=' + $('.user_names').val() + '&is_fan=' + $('#is_fan:checked').val();
$.get(last_url,params,function(obj){
alert(obj.msg);
if(obj.success){
window.location.href = "/finance/ticheng-jisuan?" + params;
}
},'json');
}); });
return false;
}
//提交维修明细 $(function() {
$('#add-user').click(function(){ search();
var params = $("#searchForm").serialize(); $('.input-daterange').datepicker({
art.dialog.open('/finance/add-user?' + '&select_user=' + $('#select_user').val() + '&all=' + $('#all:checked').val() + '&no_num=' + $('#no_num:checked').val(), keyboardNavigation: false,
{title: '增加工号', width: 1000, height: 350, forceParse: false,
close: function () { autoclose: true
var user_names = art.dialog.data('user_names'); // 读取子窗口返回的数据
if( typeof user_names != 'undefined') {
var a = $('#user_names').val();
if (a != '') {
a = a + ',';
}
$('#user_names').val(a + user_names);
}
}
});
}); });
$('.calc-btn').click(function(){
//提交维修明细 var index = parent.layer.load(1, {
$('#add-dz').click(function(){ shade: [0.1,'#fff'] //0.1透明度的白色背景
var params = $("#searchForm").serialize(); });
art.dialog.open('/finance/add-user?'+ 'user_names=' + $('#dz_names').val() , var params = $("#searchFrm").serialize();
{title: '增加工号', width: 1000, height: 350, $.post('/finance/ticheng-jisuan-save', params, function(obj) {
close: function () { parent.layer.close(index);
var user_names = art.dialog.data('user_names'); // 读取子窗口返回的数据 parent.layer.msg(obj.msg);
$('#dz_names').val(user_names); if(obj.success) {
refreshList();
} }
}); }, 'json');
}); });
});
</script>
<?php $this->endBlock(); ?>
})
</script>

Loading…
Cancel
Save