-
Notifications
You must be signed in to change notification settings - Fork 611
/
Entry.php
60 lines (57 loc) · 1.78 KB
/
Entry.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<?php
/**
* @link https://craftcms.com/
* @copyright Copyright (c) Pixel & Tonic, Inc.
* @license https://craftcms.github.io/license/
*/
namespace craft\gql\arguments\mutations;
use craft\gql\base\ElementMutationArguments;
use craft\gql\types\DateTime;
use GraphQL\Type\Definition\Type;
/**
* Class Entry
*
* @author Pixel & Tonic, Inc. <support@pixelandtonic.com>
* @since 3.5.0
*/
class Entry extends ElementMutationArguments
{
/**
* @inheritdoc
*/
public static function getArguments(): array
{
return array_merge(parent::getArguments(), [
'authorId' => [
'name' => 'authorId',
'type' => Type::id(),
'description' => 'The entry author’s ID.',
],
'authorIds' => [
'name' => 'authorIds',
'type' => Type::listOf(Type::id()),
'description' => 'The entry authors’ IDs.',
],
'postDate' => [
'name' => 'postDate',
'type' => DateTime::getType(),
'description' => 'When should the entry be posted.',
],
'expiryDate' => [
'name' => 'expiryDate',
'type' => DateTime::getType(),
'description' => 'When should the entry expire.',
],
'slug' => [
'name' => 'slug',
'type' => Type::string(),
'description' => 'Narrows the query results based on the elements’ slugs.',
],
'siteId' => [
'name' => 'siteId',
'type' => Type::int(),
'description' => 'Determines which site the elements should be saved to. Defaults to the primary site.',
],
]);
}
}