Browse Source

Merge branch 'dev' of ssh://10.10.100.21/source/saas-platform into dev

rainco 7 years ago
parent
commit
22985db3f3

+ 6 - 6
frontend/saas-web/app/util/BaseUtil.js

@@ -54,8 +54,8 @@ Ext.define('saas.util.BaseUtil', {
          * @param title: 标题
          * 
          */
-        showSuccessToast: function (content, title) {
-            Ext.toast({
+        showSuccessToast: function (content, title, configs) {
+            Ext.toast(Ext.Object.merge({
                 cls:'x-toast-success',
                 html: content,
                 title: title,
@@ -64,11 +64,11 @@ Ext.define('saas.util.BaseUtil', {
                 autoCloseDelay:3000,
                 autoClose:true,
                 maxWidth: 400
-            });
+            }, configs));
         },
 
-        showErrorToast: function (content, title) {
-            Ext.toast({
+        showErrorToast: function (content, title, configs) {
+            Ext.toast(Ext.Object.merge({
                 cls:'x-toast-error',
                 html: content,
                 title: title,
@@ -77,7 +77,7 @@ Ext.define('saas.util.BaseUtil', {
                 autoCloseDelay:3000,
                 autoClose:true,
                 maxWidth: 400
-            });
+            }, configs));
         },
 
         /**

+ 1 - 2
frontend/saas-web/app/view/document/kind/ChildForm.js

@@ -329,7 +329,7 @@ Ext.define('KitchenSink.view.binding.ChildForm', {
                                 method: 'GET',
                                 headers:{
                                     'Access-Control-Allow-Origin': '*',
-                                    "Content-Type": 'application/json;charset=UTF-8'
+                                    "Content-Type": 'application/json;charset=UTF-8',
                                 },
                                 success: function (response) {
                                     form.setLoading(false);
@@ -496,7 +496,6 @@ Ext.define('KitchenSink.view.binding.ChildForm', {
                 fieldLabel: '联系电话',
                 name: 'em_mobile',
                 allowBlank:false,
-                beforeLabelTextTpl: '',
                 maxLength: 20
             },{
                 xtype:'textfield',

+ 5 - 5
frontend/saas-web/app/view/sys/config/FormPanel.js

@@ -199,7 +199,7 @@ Ext.define('saas.view.sys.config.FormPanel', {
                                 if(data.id){
                                     var serverOptions = Ext.manifest.server;
                                     var img = myForm.down('[name=SignetPhoto]');
-                                    img.el.dom.src = serverOptions.basePath.http + '/api/file/download?path='+data.fullPath;
+                                    img.el.dom.src = serverOptions.basePath.http?serverOptions.basePath.http:serverOptions.basePath + '/api/file/download?path='+data.fullPath;
                                     var showSignetPhoto = form.down('[name=showSignetPhoto]');
                                     showSignetPhoto.show();
                                 }
@@ -325,7 +325,7 @@ Ext.define('saas.view.sys.config.FormPanel', {
                                 if(data.id){
                                     var serverOptions = Ext.manifest.server;
                                     var img = myForm.down('[name=LogoPhoto]');
-                                    img.el.dom.src = serverOptions.basePath.http + '/api/file/download?path='+data.fullPath;
+                                    img.el.dom.src = serverOptions.basePath.http?serverOptions.basePath.http:serverOptions.basePath + '/api/file/download?path='+data.fullPath;
                                     var showLogoPhoto = form.down('[name=showLogoPhoto]');
                                     showLogoPhoto.show();
                                 }
@@ -414,7 +414,7 @@ Ext.define('saas.view.sys.config.FormPanel', {
         var signet = form.down('[name=signet]').value;
         if(signet&&signet!=''){
             var img = form.down('[name=SignetPhoto]');
-            img.el.dom.src = serverOptions.basePath.http + '/api/file/download?path='+signet;
+            img.el.dom.src = serverOptions.basePath.http?serverOptions.basePath.http:serverOptions.basePath + '/api/file/download?path='+signet;
             var showSignetPhoto = form.down('[name=showSignetPhoto]');
             showSignetPhoto.show();
         }
@@ -422,7 +422,7 @@ Ext.define('saas.view.sys.config.FormPanel', {
         var logoUrl = form.down('[name=logoUrl]').value;
         if(logoUrl&&logoUrl!=''){
             var img = form.down('[name=LogoPhoto]');
-            img.el.dom.src = serverOptions.basePath.http + '/api/file/download?path='+logoUrl;
+            img.el.dom.src = serverOptions.basePath.http?serverOptions.basePath.http:serverOptions.basePath + '/api/file/download?path='+logoUrl;
             var showLogoPhoto = form.down('[name=showLogoPhoto]');
             showLogoPhoto.show();
         }
@@ -472,7 +472,7 @@ Ext.define('saas.view.sys.config.FormPanel', {
 
     downLoad:function(path){
         var serverOptions = Ext.manifest.server;
-        window.location.href = serverOptions.basePath.http + '/api/file/download?path='+path;
+        window.location.href = serverOptions.basePath.http?serverOptions.basePath.http:serverOptions.basePath + '/api/file/download?path='+path;
         //ajax 响应下载必须要创建一个form实例
         // if (!Ext.fly('ext-attach-download')) {  
 		// 	var frm = document.createElement('form');