zhuth 7 jaren geleden
bovenliggende
commit
c8c7d32900

+ 1 - 0
frontend/saas-web/app/util/FormUtil.js

@@ -203,6 +203,7 @@ Ext.define('saas.util.FormUtil', {
                         }
                     }
                     form.initFormData(o);
+                    form.fireEvent('load', form, o);
                 }
             })
             .catch(function(response) {

+ 6 - 1
frontend/saas-web/app/view/document/customer/BasePanel.js

@@ -132,7 +132,12 @@ Ext.define('saas.view.document.customer.BasePanel', {
             text : "税率", 
             dataIndex : "cu_taxrate", 
             xtype: 'numbercolumn'
-        },{
+        }, {
+            text: '应收款余额',
+            dataIndex: 'cu_leftamount',
+            width: 120,
+            xtype: 'numbercolumn'
+        }, {
             text : "承付天数", 
             xtype: 'numbercolumn',
             dataIndex : "cu_promisedays", 

+ 0 - 1
frontend/saas-web/app/view/document/customer/FormPanel.js

@@ -193,7 +193,6 @@ Ext.define('saas.view.document.customer.FormPanel', {
         ignore:true,
         columnWidth : 0.25,
         decimalPrecision: 8,
-        minValue:0,
         renderer : function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length)).fill('0');

+ 12 - 1
frontend/saas-web/app/view/document/product/FormModel.js

@@ -12,7 +12,18 @@ Ext.define('saas.view.document.product.FormModel', {
             get:function(value){
                 return value;
             }
-        }/* ,
+        },
+        qcsz_change: {
+            bind: '{qcsz}',
+            get: function(v) {
+                var form = this.getView(),
+                detailGrid = form.down('detailGridField');
+
+                detailGrid.setHidden(!v);
+            }
+        },
+        
+        /* ,
         pd_num_change: {
             bind: '{pd_num}',
             get: function(v) {

+ 19 - 1
frontend/saas-web/app/view/document/product/FormPanel.js

@@ -198,12 +198,22 @@ Ext.define('saas.view.document.product.FormPanel', {
         xtype : "datefield", 
         name : "updateTime", 
         fieldLabel : "更新时间"
-    },{
+    }, {
+        xtype: 'numberfield',
+        fieldLabel: 'L/T',
+        name: 'pr_leadtime'
+    }, {
+        xtype: 'checkbox',
+        fieldLabel: '期初设置',
+        name: 'qcsz',
+        ignore: true,
+    }, {
         xtype : "detailGridField", 
         storeModel:'saas.model.document.ProductDetail',
         detnoColumn: 'pd_detno',
         showCount: false,
         allowEmpty:true,
+        hidden: true,
         deleteDetailUrl:'/api/document/product/deleteDetail/',
         columns : [{
             text : "ID", 
@@ -361,5 +371,13 @@ Ext.define('saas.view.document.product.FormPanel', {
         unAuditText: '已开启',
         auditBtnText: '禁用',
         unAuditBtnText: '启用',
+    },
+    listeners: {
+        load: function(form, data) {
+            var viewModel = form.getViewModel();
+            var store = viewModel.get('detail0').detailStore;
+
+            viewModel.set('qcsz', store.getCount() > 0);
+        }
     }
 });

+ 0 - 1
frontend/saas-web/app/view/document/vendor/FormPanel.js

@@ -180,7 +180,6 @@ Ext.define('saas.view.document.vendor.FormPanel', {
         ignore:true,
         columnWidth : 0.25,
         decimalPrecision: 8,
-        minValue:0,
         renderer : function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length)).fill('0');

+ 4 - 0
frontend/saas-web/app/view/home/charts/PurchaseTrend.js

@@ -28,6 +28,10 @@ Ext.define('saas.view.home.charts.PurchaseTrend', {
                     store: '{purchase_trend}',
                 },
                 axes: [{
+                    title: {
+                        text: '月',
+                        fontSize: 14,
+                    },
                     type: 'category',
                     fields: ['x'],
                     position: 'bottom',

+ 4 - 5
frontend/saas-web/app/view/home/charts/SaleTrend.js

@@ -34,14 +34,13 @@ Ext.define('saas.view.home.charts.SaleTrend', {
 
                 // },
                 axes: [{
+                    title: {
+                        text: '月',
+                        fontSize: 14,
+                    },
                     type: 'category',
                     fields: ['x'],
                     position: 'bottom',
-                    label: {
-                        rotate: {
-                            degrees: -25
-                        }
-                    },
                     style: {
                         fill: '#E7EBEF',
                         strokeStyle: 'transparent'

+ 4 - 0
frontend/saas-web/app/view/home/charts/StockAmount.js

@@ -28,6 +28,10 @@ Ext.define('saas.view.home.charts.StockAmount', {
                     store: '{stock_amount}',
                 },
                 axes: [{
+                    title: {
+                        text: '月',
+                        fontSize: 14,
+                    },
                     type: 'category',
                     fields: ['x'],
                     position: 'bottom',