Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import Relay from 'react-relay/classic';
class UpdateContactMutation extends Relay.Mutation {
getMutation() {
return Relay.QL`mutation updateContact {
updateContact
}`;
}
static fragments = {
contact: () => Relay.QL`fragment on Contact { id,location,web,phone }`,
};
getVariables() {
return {
id: this.props.id,
location: this.props.location,
web: this.props.web,
phone: this.props.phone,
import Relay from 'react-relay/classic';
class CreateTagMutation extends Relay.Mutation {
getMutation() {
return Relay.QL`mutation createTag {
createTag
}`;
}
getFatQuery() {
switch (this.props.parent_type) {
case 'source':
return Relay.QL`fragment on CreateTagPayload { tagEdge, source { log, tags, log_count } }`;
case 'project_media':
return Relay.QL`fragment on CreateTagPayload { tagEdge, project_media { last_status, last_status_obj,log, tags, log_count, project_id } }`;
case 'project_source':
return Relay.QL`fragment on CreateTagPayload { tagEdge, project_source { source { log, tags, log_count } } }`;
default:
return '';
import Relay from 'react-relay/classic';
class TeamPipelineUpdate extends Relay.Mutation {
static fragments = {
teamPipeline: () => Relay.QL`
fragment on TeamPipeline {
id
}
`
}
getMutation() {
return Relay.QL`
mutation {
teamPipelineUpdate
}
`;
}
import Relay from 'react-relay/classic';
class CreateFlagMutation extends Relay.Mutation {
getMutation() {
return Relay.QL`mutation createFlag {
createFlag
}`;
}
getFatQuery() {
switch (this.props.parent_type) {
case 'source':
return Relay.QL`fragment on CreateFlagPayload { flagEdge, source { log, log_count } }`;
case 'project_media':
return Relay.QL`fragment on CreateFlagPayload { flagEdge, project_media { last_status, last_status_obj, log, log_count } }`;
default:
return '';
}
}
import Relay from 'react-relay/classic';
import optimisticProjectMedia from './optimisticProjectMedia';
class UpdateProjectMediaMutation extends Relay.Mutation {
getMutation() {
return Relay.QL`mutation updateProjectMedia {
updateProjectMedia
}`;
}
getFatQuery() {
if (this.props.metadata) {
return Relay.QL`
fragment on UpdateProjectMediaPayload {
project_media {
id,
overridden,
metadata,
}
}
}
this.reset();
}
commitUpdate(mutation, callbacks) {
return this.update(callbacks);
}
applyUpdate(mutation, callbacks) {
return this.update(callbacks);
}
}
module.exports = {
QL: Relay.QL,
Mutation: Relay.Mutation,
Route: Relay.Route,
RootContainer: ({ renderFetched }) => renderFetched({}),
createContainer: component => component,
Store: new MockStore(),
};
import Relay from 'react-relay/classic';
class DeleteTeamBotInstallationMutation extends Relay.Mutation {
getMutation() {
return Relay.QL`mutation destroyTeamBotInstallation {
destroyTeamBotInstallation
}`;
}
getVariables() {
return { id: this.props.id };
}
getFatQuery() {
return Relay.QL`fragment on DestroyTeamBotInstallationPayload {
deletedId
team { id }
team_bot: bot_user {
id
import Relay from 'react-relay/classic';
class PipelineScheduleCreate extends Relay.Mutation {
static fragments = {
pipeline: () => Relay.QL`
fragment on Pipeline {
id
}
`
}
getMutation() {
return Relay.QL`
mutation {
pipelineScheduleCreate
}
`;
}
import Relay from 'react-relay/classic';
export default class OrganizationMemberUpdate extends Relay.Mutation {
static fragments = {
organizationMember: () => Relay.QL`
fragment on OrganizationMember {
id
}
`
}
getMutation() {
return Relay.QL`
mutation {
organizationMemberUpdate
}
`;
}
import Relay from 'react-relay/classic';
class CreateMemebusterMutation extends Relay.Mutation {
getMutation() {
return Relay.QL`mutation {
createDynamicAnnotationMemebuster
}`;
}
getFatQuery() {
return Relay.QL`fragment on CreateDynamicAnnotationMemebusterPayload {
dynamicEdge,
project_media {
annotations(first: 1, annotation_type: "memebuster")
}
}`;
}
getFiles() {