Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
azpanel committed Sep 24, 2023
1 parent 40b84a7 commit 048b9fd
Show file tree
Hide file tree
Showing 11 changed files with 211 additions and 338 deletions.
59 changes: 0 additions & 59 deletions database/migrations/20220323132130_custom_website.php

This file was deleted.

77 changes: 0 additions & 77 deletions database/migrations/20220703060235_verification_code_switch.php

This file was deleted.

This file was deleted.

68 changes: 0 additions & 68 deletions database/migrations/20220729025434_add_hcaptcha.php

This file was deleted.

49 changes: 0 additions & 49 deletions database/migrations/20230505065119_version.php

This file was deleted.

47 changes: 47 additions & 0 deletions database/seeds/AddHcaptchaItem.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
<?php

use think\migration\Seeder;

class AddHcaptchaItem extends Seeder
{
/**
* Run Method.
*
* Write your database seeder using this method.
*
* More information on writing seeders is available here:
* http://docs.phinx.org/en/latest/seeding.html
*/
public function run(): void
{
$data = [
[
'id' => null,
'item' => 'captcha_provider',
'value' => 'think-captcha',
'class' => 'verification_code',
'default_value' => 'think-captcha',
'type' => 'string',
],
[
'id' => null,
'item' => 'hcaptcha_site_key',
'value' => '',
'class' => 'verification_code',
'default_value' => '',
'type' => 'string',
],
[
'id' => null,
'item' => 'hcaptcha_secret',
'value' => '',
'class' => 'verification_code',
'default_value' => '',
'type' => 'string',
]
];

$conn = $this->table('config');
$conn->insert($data)->saveData();
}
}
39 changes: 39 additions & 0 deletions database/seeds/CustomWebsiteItem.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?php

use think\migration\Seeder;

class CustomWebsiteItem extends Seeder
{
/**
* Run Method.
*
* Write your database seeder using this method.
*
* More information on writing seeders is available here:
* http://docs.phinx.org/en/latest/seeding.html
*/
public function run(): void
{
$data = [
[
'id' => null,
'item' => 'custom_text',
'value' => '<a href="https://github.com/azpanel/azpanel">staff</a>',
'class' => 'custom',
'default_value' => '<a href="https://github.com/azpanel/azpanel">staff</a>',
'type' => 'string',
],
[
'id' => null,
'item' => 'custom_script',
'value' => '<script></script>',
'class' => 'custom',
'default_value' => '<script></script>',
'type' => 'string',
]
];

$conn = $this->table('config');
$conn->insert($data)->saveData();
}
}
Loading

0 comments on commit 048b9fd

Please sign in to comment.