支付限额

master
sunke 5 years ago
parent a30317be91
commit 68572d10e6

@ -954,12 +954,23 @@ class ToolController extends ThinkController {
}
if ($data['limit_time_type'] == 'week') {
$data['limit_time_type'] = '每周,';
$remarkStr = '周'.$data['limit_time_type_remark'];
}
if ($data['limit_time_type'] == 'month') {
$data['limit_time_type'] = '每月,';
$remarkStr = $data['limit_time_type_remark'].'号';
}
if ($data['limit_time_type'] == 'fix') {
$data['limit_time_type'] = '特殊,';
$remarks = str_split($data['limit_time_type_remark'], 1);
$remarkStr = '';
foreach($remarks as $keyR => $remark) {
if ($keyR == 3 || $keyR == 5){
$remarkStr .= $remark. '-';
}else {
$remarkStr .= $remark;
}
}
}
if ($data['limit_type'] == 'force') {
$datas[$key]['limit_type'] = '强制模式';
@ -1000,9 +1011,10 @@ class ToolController extends ThinkController {
}
}
$datas[$key]['pay_type'] = $pay_type;
$datas[$key]['limit_rule'] = $limit_rule;
$datas[$key]['limit_time'] = $data['limit_time_type'] .$data['limit_time_type_remark'].' '.$startTimeStr.'~'.$endTimeStr;
$datas[$key]['limit_time'] = $data['limit_time_type'] .$remarkStr.' '.$startTimeStr.'~'.$endTimeStr;
}
//分页
@ -1012,7 +1024,6 @@ class ToolController extends ThinkController {
if ($page) {
$this->assign('_page', $page);
}
var_dump($payType);
if (empty($payType)) {
$this->assign('pay_type', " ");
}else {
@ -1116,7 +1127,8 @@ class ToolController extends ThinkController {
if (empty($_REQUEST['day_remark'])) {
return $this->error('每月限制时间未确定');
}else {
$data['limit_time_type_remark'] = $_REQUEST['day_remark'];
$fixStr = str_replace('-','',$_REQUEST['day_remark']);
$data['limit_time_type_remark'] = $fixStr;
}
break;
}
@ -1242,9 +1254,10 @@ class ToolController extends ThinkController {
if (empty($_REQUEST['day_remark'])) {
return $this->error('每月限制时间未确定');
}else {
$confInfo['limit_time_type_remark'] = $_REQUEST['day_remark'];
$fixStr = str_replace('-','',$_REQUEST['day_remark']);
$confInfo['limit_time_type_remark'] = $fixStr;
}
$confInfo['limit_time_type_remark'] = $_REQUEST['day_remark'];
// $confInfo['limit_time_type_remark'] = $_REQUEST['day_remark'];
break;
}
$confInfo['limit_time_type'] = $limit_time_type;
@ -1262,6 +1275,19 @@ class ToolController extends ThinkController {
$end_time = $data['end_time'];
$monthDay = $this->getMonthDay();
if ($data['limit_time_type'] == 'fix') {
$remarks = str_split($data['limit_time_type_remark'], 1);
$remarkStr = '';
foreach($remarks as $keyR => $remark) {
if ($keyR == 3 || $keyR == 5){
$remarkStr .= $remark. '-';
}else {
$remarkStr .= $remark;
}
}
$data['limit_time_type_remark'] = $remarkStr;
}
$this->assign('monthday', $monthDay);
$this->assign('startTime', $start_time);
$this->assign('endTime', $end_time);
@ -1284,7 +1310,7 @@ class ToolController extends ThinkController {
public function getMonthDay() {
$arr = [];
for ($i = 1;$i < 32; $i++ ) {
$arr[] = $i.'号';
$arr[] = $i;
}
return $arr;

@ -124,13 +124,13 @@
<label><input type="radio" name="status" value="week" onclick="changeStatus(2)"/> 每周</label>
<span class="form_select" style="margin-left:5px">
<select name="week_remark">
<option value="周一" selected>周一</option>
<option value="周二">周二</option>
<option value="周三">周三</option>
<option value="周四">周四</option>
<option value="周五">周五</option>
<option value="周六">周六</option>
<option value="周天">周天</option>
<option value="1" selected>周一</option>
<option value="2">周二</option>
<option value="3">周三</option>
<option value="4">周四</option>
<option value="5">周五</option>
<option value="6">周六</option>
<option value="7">周天</option>
</select>
</span>
@ -182,7 +182,7 @@
<span class="form_select" style="margin-left:5px">
<select name="month_remark">
<volist name="monthday" id="vo" key='k'>
<option value="{$vo}" selected>{$vo}</option>
<option value="{$vo}" selected>{$vo}</option>
</if>
</volist>
</select>

@ -185,9 +185,9 @@
<select name="month_remark">
<volist name="monthday" id="vo" key='k'>
<if condition="$vo eq $data[limit_time_type_remark]">
<option value="{$vo}" selected>{$vo}</option>
<option value="{$vo}" selected>{$vo}</option>
<else />
<option value="{$vo.paytag}">{$vo}</option>
<option value="{$vo}">{$vo}</option>
</if>
</volist>
</select>

Loading…
Cancel
Save