Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jio
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Hardik Juneja
jio
Commits
a7ce25bd
Commit
a7ce25bd
authored
Jan 18, 2013
by
Tristan Cavelier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix indent in putAttachmentCommand.js
parent
df49c0f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
45 additions
and
45 deletions
+45
-45
src/jio/commands/putAttachmentCommand.js
src/jio/commands/putAttachmentCommand.js
+45
-45
No files found.
src/jio/commands/putAttachmentCommand.js
View file @
a7ce25bd
/*jslint indent: 2, maxlen: 80, sloppy: true */
/*jslint indent: 2, maxlen: 80, sloppy: true */
/*global command: true */
/*global command: true */
var
putAttachmentCommand
=
function
(
spec
,
my
)
{
var
putAttachmentCommand
=
function
(
spec
,
my
)
{
var
that
=
command
(
spec
,
my
);
var
that
=
command
(
spec
,
my
);
spec
=
spec
||
{};
spec
=
spec
||
{};
my
=
my
||
{};
my
=
my
||
{};
// Attributes //
// Attributes //
// Methods //
// Methods //
that
.
getLabel
=
function
()
{
that
.
getLabel
=
function
()
{
return
'
putAttachment
'
;
return
'
putAttachment
'
;
};
};
that
.
executeOn
=
function
(
storage
)
{
that
.
executeOn
=
function
(
storage
)
{
storage
.
putAttachment
(
that
);
storage
.
putAttachment
(
that
);
};
};
that
.
validateState
=
function
()
{
that
.
validateState
=
function
()
{
if
(
!
(
typeof
that
.
getDocId
()
===
"
string
"
&&
that
.
getDocId
()
!==
if
(
!
(
typeof
that
.
getDocId
()
===
"
string
"
&&
that
.
getDocId
()
!==
""
))
{
""
))
{
that
.
error
({
that
.
error
({
"
status
"
:
20
,
"
status
"
:
20
,
"
statusText
"
:
"
Document Id Required
"
,
"
statusText
"
:
"
Document Id Required
"
,
"
error
"
:
"
document_id_required
"
,
"
error
"
:
"
document_id_required
"
,
"
message
"
:
"
The document id is not provided
"
,
"
message
"
:
"
The document id is not provided
"
,
"
reason
"
:
"
Document id is undefined
"
"
reason
"
:
"
Document id is undefined
"
});
});
return
false
;
return
false
;
}
}
if
(
typeof
that
.
getAttachmentId
()
!==
"
string
"
)
{
if
(
typeof
that
.
getAttachmentId
()
!==
"
string
"
)
{
that
.
error
({
that
.
error
({
"
status
"
:
22
,
"
status
"
:
22
,
"
statusText
"
:
"
Attachment Id Required
"
,
"
statusText
"
:
"
Attachment Id Required
"
,
"
error
"
:
"
attachment_id_required
"
,
"
error
"
:
"
attachment_id_required
"
,
"
message
"
:
"
The attachment id must be set
"
,
"
message
"
:
"
The attachment id must be set
"
,
"
reason
"
:
"
Attachment id not set
"
"
reason
"
:
"
Attachment id not set
"
});
});
return
false
;
return
false
;
}
}
if
(
that
.
getAttachmentId
()
===
""
)
{
if
(
that
.
getAttachmentId
()
===
""
)
{
that
.
error
({
that
.
error
({
"
status
"
:
23
,
"
status
"
:
23
,
"
statusText
"
:
"
Invalid Attachment Id
"
,
"
statusText
"
:
"
Invalid Attachment Id
"
,
"
error
"
:
"
invalid_attachment_id
"
,
"
error
"
:
"
invalid_attachment_id
"
,
"
message
"
:
"
The attachment id must not be an empty string
"
,
"
message
"
:
"
The attachment id must not be an empty string
"
,
"
reason
"
:
"
Attachment id is empty
"
"
reason
"
:
"
Attachment id is empty
"
});
});
}
}
return
true
;
return
true
;
};
};
return
that
;
return
that
;
};
};
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment