Ejemplo n.º 1
0
	Model.prototype.modelLoad = function(event) {
		this.appEngine = new AppEngine('$UI/system/deploy/compile/compile.j');
		this.targetPath = webSocket.getRequestParameter("targetPath");
		this.nativePath = templateService.getNativePath();
		var appPath = this.targetPath.substr(this.nativePath.length + 1);
		appPath = appPath.replace(/\\/g, '/');
		var appName = appPath.split('/')[0];
		this.appEngine.loadConfig(appName);

		var self = this;
		this.appEngine.buildFinishedNotify = function(result) {
			self.buildFinished = true;
			self.buildResult = result;
			if (self.buildFinishedNotify) {
				self.buildFinishedNotify(result);
			}
			if (result.flag && result.code != "ERROR") {
				templateService.refreshFile(self.nativePath + '/' + self.appEngine.getConfig().appName);
				templateService.selectFile(self.nativePath + '/' + self.appEngine.getConfig().appName + '/www');
			}
		};
		this.openPage({
			id : "appInfo",
			url : "appInfo.w",
			fromId : "index"
		});
	};
Ejemplo n.º 2
0
		closeDialog : function(params) {
			params = params || {};
			params.pageId = params.pageId || webSocket.getRequestParameter("pageId");
			params.async = true;
			return this.callJava(templateServiceName, "closeDialog", params);
		},