修复 模块 WeCom Key 显示和更新
This commit is contained in:
parent
7640b889f9
commit
43d02ca500
@ -34,8 +34,6 @@ public function index(Module $module): View
|
|||||||
*/
|
*/
|
||||||
public function create(): View
|
public function create(): View
|
||||||
{
|
{
|
||||||
//
|
|
||||||
|
|
||||||
return view('admin.modules.create');
|
return view('admin.modules.create');
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -74,7 +72,7 @@ private function rules(): array
|
|||||||
'name' => 'required|string|max:255',
|
'name' => 'required|string|max:255',
|
||||||
'url' => 'required|url',
|
'url' => 'required|url',
|
||||||
'status' => 'required|string|in:up,down,maintenance',
|
'status' => 'required|string|in:up,down,maintenance',
|
||||||
'wecom_key' => 'required|string|max:255',
|
'wecom_key' => 'nullable|string|max:255',
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -103,6 +101,8 @@ public function show(Module $module): View
|
|||||||
*/
|
*/
|
||||||
public function edit(Module $module): View
|
public function edit(Module $module): View
|
||||||
{
|
{
|
||||||
|
$module = $module->makeVisible('wecom_key');
|
||||||
|
|
||||||
return view('admin.modules.edit', compact('module'));
|
return view('admin.modules.edit', compact('module'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
|
|
||||||
<div class="form-group mt-1">
|
<div class="form-group mt-1">
|
||||||
<label for="name">企业微信 群机器人 WebHook Key</label>
|
<label for="name">企业微信 群机器人 WebHook Key</label>
|
||||||
<input type="text" class="form-control" id="wecom_key" name="wecom_key">
|
<input type="text" class="form-control" id="wecom_key" name="wecom_key" value="{{ $module->wecom_key }}" autocomplete="off">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group mt-1">
|
<div class="form-group mt-1">
|
||||||
|
Loading…
Reference in New Issue
Block a user