24 lines
No EOL
623 B
Text
24 lines
No EOL
623 B
Text
checkIfLoggedIn(this.href(req.action));
|
|
|
|
var deny = this.isEditDenied(session.user);
|
|
if (deny) {
|
|
res.message = deny;
|
|
res.redirect(this.site.images.href());
|
|
}
|
|
|
|
if (req.data.submit == "cancel" || req.data.cancel)
|
|
res.redirect(this.site.images.href());
|
|
else if (req.data.submit == "save" || req.data.save) {
|
|
var result = this.evalImg(req.data,session.user);
|
|
res.message = result.message;
|
|
if (!result.error)
|
|
res.redirect(path.imagemgr.href());
|
|
}
|
|
|
|
res.data.action = this.href(req.action);
|
|
|
|
res.data.title = this.site.title;
|
|
|
|
res.data.body = this.renderSkinAsString("edit");
|
|
|
|
path.site.renderSkin("page"); |