更新 'src/Grid/Displayers/Actions.php'
回收站删除问题,url参数格式错误
This commit is contained in:
parent
9415f1543b
commit
3a3f883805
@ -193,6 +193,7 @@ EOT;
|
||||
$resume_checkout = "<label><input type='checkbox' class='resume_checkout' name='resume_checkout' style='width: 18px;height: 13px;position: relative;top:2px;'>{$tip}</label>";
|
||||
return $resume_checkout;
|
||||
}
|
||||
|
||||
/**
|
||||
* Render delete action.
|
||||
*
|
||||
@ -201,14 +202,14 @@ EOT;
|
||||
protected function renderDelete()
|
||||
{
|
||||
$title = '';
|
||||
$url_pams = '';
|
||||
$url_pams = [];
|
||||
if (strstr($this->getResource(), 'firm/company') && !(strstr($this->getResource(), 'firm/companyimg')) && !(strstr($this->getResource(), 'firm/companysetmeal'))) {
|
||||
$deleteConfirm = trans('admin.delete_company_confirm');
|
||||
} elseif (strstr($this->getResource(), 'personal/members')) {
|
||||
$deleteConfirm = trans('admin.delete_person_confirm');
|
||||
} elseif (strstr($this->getResource(), 'recycle/index')) {
|
||||
$scope = array_get(request()->all(), 'scope', 1);
|
||||
$url_pams='?scope='.$scope;
|
||||
$url_pams['scope'] = $scope;
|
||||
$deleteConfirm = trans('admin.delete_confirm');
|
||||
} elseif (strstr($this->getResource(), 'personal/resume')) {
|
||||
$deleteConfirm = trans('admin.delete_confirm');
|
||||
@ -216,6 +217,7 @@ EOT;
|
||||
} else {
|
||||
$deleteConfirm = trans('admin.delete_confirm');
|
||||
}
|
||||
$url_pams = empty(http_build_query($url_pams)) ? '' : '&' . http_build_query($url_pams);
|
||||
$confirm = trans('admin.confirm');
|
||||
$cancel = trans('admin.cancel');
|
||||
$script = <<<SCRIPT
|
||||
@ -239,7 +241,7 @@ function render_action_delete() {
|
||||
return new Promise(function(resolve) {
|
||||
$.ajax({
|
||||
method: 'post',
|
||||
url: '{$this->getResource()}/' + id +'$url_pams'+'?is_resume='+is_resume,
|
||||
url: '{$this->getResource()}/' + id +'?is_resume='+is_resume+'{$url_pams}',
|
||||
data: {
|
||||
_method:'delete',
|
||||
_token:LA.token,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user