|
|
@@ -304,30 +304,25 @@ class Lave extends Api
|
|
|
// var_dump($last);
|
|
|
// var_dump($date);
|
|
|
// var_dump($now_date);
|
|
|
- @file_put_contents("quanju.txt", "789456135415-\r\n", 8);
|
|
|
- @file_put_contents("quanju.txt", $date."159-\r\n", 8);
|
|
|
- @file_put_contents("quanju.txt", $now_date."753-\r\n", 8);
|
|
|
+
|
|
|
if ($date != $now_date) { //先确定月份不同
|
|
|
- @file_put_contents("quanju.txt", "123-\r\n", 8);
|
|
|
- @file_put_contents("quanju.txt", $today."123456-\r\n", 8);
|
|
|
- @file_put_contents("quanju.txt", $day."789-\r\n", 8);
|
|
|
+
|
|
|
if ($today == $day||$today==$last) { //再确定是不是签约那天或者是当月的最后一天
|
|
|
// var_dump(123);
|
|
|
- @file_put_contents("quanju.txt", json_encode($v)."测试申请扣款-\r\n", 8);
|
|
|
$cid=$v['cid'];
|
|
|
// if ($this->querySign($cid,$v['uid'],$v['plan_id'],$v['contract_code'])){
|
|
|
- $arr['mch_id'] =Company::where('id', $cid)->value('pay_weixin_mchid');
|
|
|
- $arr['out_trade_no']=LaveMonthModel::getNewOrderId();
|
|
|
- $arr['total_fee'] = $v['price'];
|
|
|
+// $arr['mch_id'] =Company::where('id', $cid)->value('pay_weixin_mchid');
|
|
|
+// $arr['total_fee'] = $v['price'];
|
|
|
// $arr['trade_type'] = 'PAP';
|
|
|
- $arr['contract_id'] = Company::where('id', $cid)->value('contract_id');
|
|
|
+// $arr['contract_id'] = Company::where('id', $cid)->value('contract_id');
|
|
|
// $rs = WechatService::paymentOrder($openid, $orderInfo['order_id'], $orderInfo['amount'], "lave", $orderInfo['order_name'], '', 'JSAPI', [], $cid);
|
|
|
|
|
|
$where1['cid']=$cid;
|
|
|
$where1['user_id']=$v['uid'];
|
|
|
$where1['order_name']=$v['order_name'];
|
|
|
+ $where1['order_id']=LaveMonthModel::getNewOrderId();;
|
|
|
// $where1['category_id']=$v['category_id'];
|
|
|
- $where1['amount']=$arr['total_fee'];
|
|
|
+ $where1['amount']=$v['price'];
|
|
|
$where1['name']=$v['contract_display_account'];
|
|
|
$where1['contact']='';
|
|
|
$where1['tel']=$v['tel'];
|