"_customerOrProspect": "Would you like to create a new Customer or a new Prospect?",
"_deleteLine?": "Are you sure you want to delete this line?",
"_exitPageWarning": "You are about to leave the xTuple application.",
+ "_installExtensionWarning": "Extensions are very powerful and potentially have full access to your " +
+ "data. You should only install an extension from a source you trust.",
"_insufficientPrivileges": "You have insufficient privileges to perform this action.",
"_manualFreight": "Manually editing the freight will disable automatic freight recalculations.",
"_mustSave": "You must save your changes before proceeding.",
);
};
+ if (!this.$.extensionName.getValue()) {
+ this.doNotify({
+ type: XM.Model.WARNING,
+ message: "_attributeIsRequired".loc().replace("{attr}", "_extensionName".loc())
+ });
+ return;
+ }
+
this.doNotify({
type: XM.Model.QUESTION,
- message: "_confirmAction".loc(),
+ message: "_installExtensionWarning".loc() + "_confirmAction".loc(),
callback: callback
});
}
extensionName = req.query.extensionName,
username = req.session.passport.user.id,
user = new SYS.User(),
+ validateInput = function (callback) {
+ if (!extensionName) {
+ callback("Error: empty extension name");
+ return;
+ }
+ callback();
+ },
validateUser = function (callback) {
user.fetch({
id: username,
};
async.series([
+ validateInput,
validateUser,
npmLoad,
npmInstall,