Browse Source

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

guq 7 years ago
parent
commit
19abdabe05
59 changed files with 416 additions and 183 deletions
  1. 2 0
      applications/document/document-dto/src/main/java/com.usoftchina.saas.document.dto/VendorDTO.java
  2. 10 0
      applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/Address.java
  3. 2 0
      applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/Vendor.java
  4. 2 0
      applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/VendorList.java
  5. 4 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/controller/AddressController.java
  6. 2 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/mapper/AddressMapper.java
  7. 2 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/service/AddressService.java
  8. 5 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/service/impl/AddressServiceImpl.java
  9. 4 2
      applications/document/document-server/src/main/resources/mapper/AddressMapper.xml
  10. 16 4
      applications/document/document-server/src/main/resources/mapper/VendorMapper.xml
  11. 1 1
      applications/money/money-server/src/main/java/com/usoftchina/saas/money/service/impl/VerificationServiceImpl.java
  12. 4 1
      applications/money/money-server/src/main/resources/application.yml
  13. 28 25
      applications/money/money-server/src/main/resources/mapper/ProfitdetailMapper.xml
  14. 1 1
      applications/purchase/purchase-server/src/main/resources/application.yml
  15. 4 1
      applications/sale/sale-server/src/main/resources/application.yml
  16. 1 1
      applications/storage/storage-server/src/main/resources/application.yml
  17. 1 1
      frontend/saas-portal-web/src/components/conenter/company.vue
  18. 3 3
      frontend/saas-web/app.json
  19. 46 14
      frontend/saas-web/app/view/core/base/ImportWindow.js
  20. 0 1
      frontend/saas-web/app/view/core/dbfind/AddMultiDbfindGridPanel.js
  21. 1 1
      frontend/saas-web/app/view/core/dbfind/AddMultiDbfindTrigger.js
  22. 1 1
      frontend/saas-web/app/view/core/dbfind/DbfindTrigger.js
  23. 1 1
      frontend/saas-web/app/view/core/dbfind/MultiDbfindTrigger.js
  24. 56 0
      frontend/saas-web/app/view/core/dbfind/types/AccountDbfindTrigger.js
  25. 5 0
      frontend/saas-web/app/view/core/dbfind/types/ProductDbfindTrigger.js
  26. 5 0
      frontend/saas-web/app/view/core/dbfind/types/ProductMultiDbfindTrigger.js
  27. 7 7
      frontend/saas-web/app/view/core/form/FormPanelController.js
  28. 2 2
      frontend/saas-web/app/view/core/report/ReportPanel.js
  29. 0 1
      frontend/saas-web/app/view/core/report/ReportPanelController.js
  30. 2 2
      frontend/saas-web/app/view/document/customer/FormPanel.js
  31. 9 0
      frontend/saas-web/app/view/document/product/FormController.js
  32. 8 2
      frontend/saas-web/app/view/document/vendor/FormPanel.js
  33. 21 1
      frontend/saas-web/app/view/home/HomeModel.js
  34. 21 21
      frontend/saas-web/app/view/home/charts/KeyData.js
  35. 4 4
      frontend/saas-web/app/view/home/charts/MonthIO.js
  36. 4 4
      frontend/saas-web/app/view/home/charts/MonthPurchase.js
  37. 2 2
      frontend/saas-web/app/view/home/charts/MonthSale.js
  38. 7 7
      frontend/saas-web/app/view/home/charts/ProfitDetail.js
  39. 4 4
      frontend/saas-web/app/view/home/charts/PurchaseTrend.js
  40. 4 4
      frontend/saas-web/app/view/home/charts/SaleTrend.js
  41. 4 4
      frontend/saas-web/app/view/home/charts/StockAmount.js
  42. 2 1
      frontend/saas-web/app/view/money/payBalance/FormPanel.js
  43. 2 1
      frontend/saas-web/app/view/money/recBalance/FormPanel.js
  44. 3 3
      frontend/saas-web/app/view/money/report/TotalPayDetail.js
  45. 8 8
      frontend/saas-web/app/view/money/report/TotalRecDetail.js
  46. 7 7
      frontend/saas-web/app/view/purchase/purchaseIn/FormPanelController.js
  47. 7 7
      frontend/saas-web/app/view/purchase/purchaseOut/FormPanelController.js
  48. 33 9
      frontend/saas-web/app/view/purchase/purchaseOut/QueryPanel.js
  49. 4 9
      frontend/saas-web/app/view/purchase/purchaseOut/QueryPanelController.js
  50. 2 1
      frontend/saas-web/app/view/sale/report/SaleRec.js
  51. 1 0
      frontend/saas-web/app/view/sale/saleIn/QueryPanel.js
  52. 2 1
      frontend/saas-web/app/view/sale/saleOut/QueryPanel.js
  53. 1 1
      frontend/saas-web/app/view/stock/make/FormPanelController.js
  54. 1 2
      frontend/saas-web/app/view/stock/report/DataList.js
  55. 1 1
      frontend/saas-web/app/view/stock/report/DataListController.js
  56. 1 1
      frontend/saas-web/app/view/sys/account/DataList.js
  57. 24 7
      frontend/saas-web/overrides/exporter/Stylesheet.js
  58. 11 1
      frontend/saas-web/overrides/exporter/file/Style.js
  59. BIN
      frontend/saas-web/resources/images/auth-background.jpg

+ 2 - 0
applications/document/document-dto/src/main/java/com.usoftchina.saas.document.dto/VendorDTO.java

@@ -27,4 +27,6 @@ public class VendorDTO extends CommonBaseDTO implements Serializable{
 
     private String ve_buyername;
 
+    private String ve_address;
+
 }

+ 10 - 0
applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/Address.java

@@ -19,6 +19,16 @@ public class Address extends CommonBaseEntity implements Serializable {
 
     private String ad_address;
 
+    private Long ad_default;
+
+    public Long getAd_default() {
+        return ad_default;
+    }
+
+    public void setAd_default(Long ad_default) {
+        this.ad_default = ad_default;
+    }
+
     public String getAd_text1() {
         return ad_text1;
     }

+ 2 - 0
applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/Vendor.java

@@ -113,4 +113,6 @@ public class Vendor extends CommonBaseEntity implements Serializable{
 
     private String ve_buyername;
 
+    private String ve_address;
+
 }

+ 2 - 0
applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/VendorList.java

@@ -104,6 +104,8 @@ public class VendorList implements Serializable {
 
     private String ve_buyername;
 
+    private String ve_address;
+
     /* 从表字段 */
 
     private Integer vc_veid;

+ 4 - 0
applications/document/document-server/src/main/java/com/usoftchina/saas/document/controller/AddressController.java

@@ -33,6 +33,10 @@ public class AddressController {
         return Result.success();
     }
 
+    @GetMapping("/getDefault")
+    public Result getDefault(){
+        return Result.success(addressService.getDefault());
+    }
 
 
     @PostMapping("/batchDelete")

+ 2 - 0
applications/document/document-server/src/main/java/com/usoftchina/saas/document/mapper/AddressMapper.java

@@ -34,4 +34,6 @@ public interface AddressMapper extends CommonBaseMapper<Address> {
     int getCountFromPurchase(@Param("id") Long id, @Param("companyId") Long companyId);
 
     void setDefault(@Param("id") Long id, @Param("companyId") Long companyId);
+
+    Address getDefault(@Param("companyId") Long companyId);
 }

+ 2 - 0
applications/document/document-server/src/main/java/com/usoftchina/saas/document/service/AddressService.java

@@ -19,4 +19,6 @@ public interface AddressService extends CommonBaseService<AddressMapper, Address
     DocBaseDTO saveData(Address address);
 
     void setDefault(Long id);
+
+    Address getDefault();
 }

+ 5 - 0
applications/document/document-server/src/main/java/com/usoftchina/saas/document/service/impl/AddressServiceImpl.java

@@ -63,6 +63,11 @@ public class AddressServiceImpl extends CommonBaseServiceImpl<AddressMapper, Add
         getMapper().setDefault(id,BaseContextHolder.getCompanyId());
     }
 
+    @Override
+    public Address getDefault(){
+        return getMapper().getDefault(BaseContextHolder.getCompanyId());
+    }
+
     /**
      * 通过主键删除
      * @param id

+ 4 - 2
applications/document/document-server/src/main/resources/mapper/AddressMapper.xml

@@ -11,6 +11,7 @@
     <result column="ad_text3" jdbcType="VARCHAR" property="ad_text3" />
     <result column="ad_text4" jdbcType="VARCHAR" property="ad_text4" />
     <result column="ad_text5" jdbcType="VARCHAR" property="ad_text5" />
+    <result column="ad_default" jdbcType="INTEGER" property="ad_default" />
   </resultMap>
   <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.usoftchina.saas.document.entities.Address">
     <result column="ad_address" jdbcType="LONGVARCHAR" property="ad_address" />
@@ -215,7 +216,8 @@
     update address set ad_default = 1 where ad_id=#{id} and companyId=#{companyId};
     update address set ad_default = 0 where ad_id!=#{id} and companyId=#{companyId};
   </update>
-
-
+  <select id="getDefault" parameterType="long" resultType="com.usoftchina.saas.document.entities.Address">
+      SELECT * FROM ADDRESS WHERE AD_DEFAULT = 1 AND COMPANYID = #{companyId}
+  </select>
 
 </mapper>

+ 16 - 4
applications/document/document-server/src/main/resources/mapper/VendorMapper.xml

@@ -31,6 +31,7 @@
         <result column="ve_beginym" property="ve_beginym" jdbcType="INTEGER" />
         <result column="ve_preamount" property="ve_preamount" jdbcType="DOUBLE" />
         <result column="ve_remark" property="ve_remark" jdbcType="VARCHAR" />
+        <result column="ve_address" property="ve_address" jdbcType="VARCHAR" />
     </resultMap>
     <resultMap id="VendorDTOResultMapper" type="com.usoftchina.saas.document.dto.VendorDTO">
         <id column="ve_id" property="id" jdbcType="INTEGER" />
@@ -40,6 +41,7 @@
         <result column="ve_type" property="ve_type" jdbcType="VARCHAR" />
         <result column="ve_status" property="ve_status" jdbcType="VARCHAR" />
         <result column="ve_remark" property="ve_remark" jdbcType="VARCHAR" />
+        <result column="ve_address" property="ve_address" jdbcType="VARCHAR" />
     </resultMap>
 
     <select id="getVendorsByCondition" resultMap="VendorDTOResultMapper">
@@ -73,6 +75,7 @@
         <result column="ve_status" property="ve_status" jdbcType="VARCHAR" />
         <result column="ve_statuscode" property="ve_statuscode" jdbcType="VARCHAR" />
         <result column="ve_leftamount" property="ve_leftamount" jdbcType="INTEGER" />
+        <result column="ve_address" property="ve_address" jdbcType="VARCHAR" />
         <result column="ve_text1" property="ve_text1" jdbcType="VARCHAR" />
         <result column="ve_text2" property="ve_text2" jdbcType="VARCHAR" />
         <result column="ve_text3" property="ve_text3" jdbcType="VARCHAR" />
@@ -112,7 +115,7 @@
         ve_promisedays, ve_taxrate, ve_nsrzh, ve_bankaccount, ve_bankcode, ve_status, ve_statuscode,
         companyId, updaterId, updateTime, ve_text1,
         ve_text2, ve_text3, ve_text4, ve_text5, ve_payamount, ve_leftamount, ve_beginym, ve_preamount,ve_remark,
-        ve_buyerid,ve_buyercode,ve_buyername
+        ve_buyerid,ve_buyercode,ve_buyername,ve_address
     </sql>
     <select id="selectByPrimaryKey" resultMap="VendorResultMapper" parameterType="java.lang.Long" >
         select
@@ -230,7 +233,10 @@
                 ve_buyercode,
             </if>
             <if test="ve_buyername!=null">
-                ve_buyername
+                ve_buyername,
+            </if>
+            <if test="ve_address!=null">
+                ve_address
             </if>
         </trim>
         <trim prefix="values (" suffix=")" suffixOverrides="," >
@@ -334,7 +340,10 @@
                 #{ve_buyercode,jdbcType=VARCHAR},
             </if>
             <if test="ve_buyername != null">
-                #{ve_buyername,jdbcType=VARCHAR}
+                #{ve_buyername,jdbcType=VARCHAR},
+            </if>
+            <if test="ve_address != null">
+                #{ve_address,jdbcType=VARCHAR}
             </if>
         </trim>
     </insert>
@@ -432,7 +441,10 @@
                 ve_buyercode = #{ve_buyercode,jdbcType=VARCHAR},
             </if>
             <if test="ve_buyername != null" >
-                ve_buyername = #{ve_buyername,jdbcType=VARCHAR}
+                ve_buyername = #{ve_buyername,jdbcType=VARCHAR},
+            </if>
+            <if test="ve_address != null">
+                ve_address = #{ve_address,jdbcType=VARCHAR}
             </if>
         </set>
         where ve_id = #{id}

+ 1 - 1
applications/money/money-server/src/main/java/com/usoftchina/saas/money/service/impl/VerificationServiceImpl.java

@@ -809,7 +809,7 @@ public class VerificationServiceImpl extends CommonBaseServiceImpl<VerificationM
 
         DocBaseDTO baseDTO = new DocBaseDTO();
         baseDTO.setId(id);
-        baseDTO.setCode(code);
+        baseDTO.setCode(nowverification.getVc_code());
         baseDTO.setName("Verification");
         //日志
         messageLogService.unAudit(baseDTO);

+ 4 - 1
applications/money/money-server/src/main/resources/application.yml

@@ -73,4 +73,7 @@ logging:
   level:
      com.usoftchina.saas.money.mapper : debug
 auth:
-  public-key: auth/pub.key
+  public-key: auth/pub.key
+ribbon:
+  ReadTimeout: 6000
+  ConnectTimeout: 6000

+ 28 - 25
applications/money/money-server/src/main/resources/mapper/ProfitdetailMapper.xml

@@ -25,11 +25,11 @@
 	a.pi_custname,
 	a.cu_type,
 	a.cu_sellername,
-	a.saamount,
-	a.netamount,
-	a.costamount,
-SUM(a.netamount - a.costamount) as profit,
-(SUM(a.netamount - a.costamount)/IFNULL(netamount,SUM(netamount - costamount))) as profitpresent
+	  IFNULL(a.saamount,0) as saamount,
+	  IFNULL(a.netamount,0) as netamount,
+	  IFNULL(a.costamount,0) as costamount,
+	  IFNULL(SUM(a.netamount - a.costamount),0) as profit,
+	  IFNULL((SUM(a.netamount - a.costamount)/IFNULL(a.netamount,SUM(a.netamount - a.costamount))),0) as profitpresent
 
 FROM
 	(
@@ -38,15 +38,15 @@ FROM
 			pi_custname,
 	        cu_type,
 			cu_sellername,
-			SUM(
-				pd_sendprice * (pd_outqty - pd_inqty)
-			) AS saamount,
-			SUM(
-				pd_netprice * (pd_outqty - pd_inqty)
-			) AS netamount,
-			SUM(
-				pd_price * (pd_outqty - pd_inqty)
-			) AS costamount
+	  SUM(
+	  IFNULL(pd_sendprice,0) * (IFNULL(pd_outqty,0) - IFNULL(pd_inqty,0))
+	  ) AS saamount,
+	  SUM(
+	  IFNULL(pd_netprice,0) * (IFNULL(pd_outqty,0) - IFNULL(pd_inqty,0))
+	  ) AS netamount,
+	  SUM(
+	  IFNULL(pd_price,0) * (IFNULL(pd_outqty,0) - IFNULL(pd_inqty,0))
+	  ) AS costamount
 		FROM
 			prodinout,
 			prodiodetail,
@@ -61,13 +61,15 @@ FROM
     </where>
 		and	pi_id = pd_piid
 		AND pi_custid = cu_id and pi_status = '已审核' and
-prodinout.companyid= prodiodetail.companyid and prodiodetail.companyid = prodinout.companyid
+prodinout.companyid= prodiodetail.companyid
 		GROUP BY
 			pi_custcode,
 			pi_custname,
 	        cu_type,
 			cu_sellername
-	) a GROUP BY
+	) a
+	  where saamount + netamount + costamount != 0
+	  GROUP BY
 			a.pi_custcode,
 			a.pi_custname,
 	        a.cu_type,
@@ -84,11 +86,11 @@ prodinout.companyid= prodiodetail.companyid and prodiodetail.companyid = prodino
 		a.pi_custname,
 		a.cu_type,
 		a.cu_sellername,
-		a.saamount,
-		a.netamount,
-		a.costamount,
-		SUM(a.netamount - a.costamount) as profit,
-		(SUM(a.netamount - a.costamount)/IFNULL(netamount,SUM(netamount - costamount))) as profitpresent
+		IFNULL(a.saamount,0) as saamount,
+		IFNULL(a.netamount,0) as netamount,
+		IFNULL(a.costamount,0) as costamount,
+		IFNULL(SUM(a.netamount - a.costamount),0) as profit,
+		IFNULL((SUM(a.netamount - a.costamount)/IFNULL(a.netamount,SUM(a.netamount - a.costamount))),0) as profitpresent
 
 		FROM
 		(
@@ -98,13 +100,13 @@ prodinout.companyid= prodiodetail.companyid and prodiodetail.companyid = prodino
 		cu_type,
 		cu_sellername,
 		SUM(
-		pd_sendprice * (pd_outqty - pd_inqty)
+		IFNULL(pd_sendprice,0) * (IFNULL(pd_outqty,0) - IFNULL(pd_inqty,0))
 		) AS saamount,
 		SUM(
-		pd_netprice * (pd_outqty - pd_inqty)
+		IFNULL(pd_netprice,0) * (IFNULL(pd_outqty,0) - IFNULL(pd_inqty,0))
 		) AS netamount,
 		SUM(
-		pd_price * (pd_outqty - pd_inqty)
+		IFNULL(pd_price,0) * (IFNULL(pd_outqty,0) - IFNULL(pd_inqty,0))
 		) AS costamount
 		FROM
 		prodinout,
@@ -126,7 +128,8 @@ prodinout.companyid= prodiodetail.companyid and prodiodetail.companyid = prodino
 		pi_custname,
 		cu_type,
 		cu_sellername
-		) a GROUP BY
+		) a
+		GROUP BY
 		a.pi_custcode,
 		a.pi_custname,
 		a.cu_type,

+ 1 - 1
applications/purchase/purchase-server/src/main/resources/application.yml

@@ -73,4 +73,4 @@ auth:
   public-key: auth/pub.key
 ribbon:
   ReadTimeout: 6000
-  ConnectTimeout: 2000
+  ConnectTimeout: 6000

+ 4 - 1
applications/sale/sale-server/src/main/resources/application.yml

@@ -68,4 +68,7 @@ mybatis:
   type-aliases-package: com.usoftchina.saas.commons.po
   mapper-locations: classpath:mapper/*.xml
 auth:
-  public-key: auth/pub.key
+  public-key: auth/pub.key
+ribbon:
+  ReadTimeout: 6000
+  ConnectTimeout: 6000

+ 1 - 1
applications/storage/storage-server/src/main/resources/application.yml

@@ -73,4 +73,4 @@ auth:
   public-key: auth/pub.key
 ribbon:
   ReadTimeout: 6000
-  ConnectTimeout: 2000
+  ConnectTimeout: 6000

+ 1 - 1
frontend/saas-portal-web/src/components/conenter/company.vue

@@ -73,7 +73,7 @@
                     </div>
                     <div>
                         <span v-if = "d.default_" class="gs-btn2 gs-btn3">默认企业</span>
-                        <span v-if="d.saas_" @click="showDefaultWin(i)" class="gs-btn2 xs">设为默认</span>
+                        <span v-else @click="showDefaultWin(i)" class="gs-btn2 xs">设为默认</span>
                     </div>
                 </div>
             </div>

+ 3 - 3
frontend/saas-web/app.json

@@ -278,8 +278,8 @@
     "builds": {
         "dev": {
             "server": {
-                "accountCenter":"http://192.168.0.181:8000",
-                "accountEnterprise":"http://192.168.0.181:8000/#/enterprise",
+                "accountCenter":"https://saas-dev.usoftchina.com:5443",
+                "accountEnterprise":"https://saas-dev.usoftchina.com:5443/#/enterprise",
                 "basePath": {
                     "https": "https://saas-api-dev.usoftchina.com:5443",
                     "http": "http://192.168.0.181:8560"
@@ -293,7 +293,7 @@
                 "accountEnterprise": "https://saas-test.usoftchina.com:5443/#/enterprise",
                 "basePath": {
                     "https": "https://saas-api-test.usoftchina.com:5443",
-                    "http": "http://192.168.0.181:8575"
+                    "http": "http://trade-test.usoftchina.com:5443"
                 },
                 "urlPattern": "^\/api\/"
             }

+ 46 - 14
frontend/saas-web/app/view/core/base/ImportWindow.js

@@ -75,6 +75,7 @@ Ext.define('saas.view.core.base.ImportWindow', {
         hidden:true,
         name:'over',
         text:'完成',
+        disabled:true,
         handler:function(b){
             var form = b.ownerCt.ownerCt;
             var id = form.importId;
@@ -96,7 +97,10 @@ Ext.define('saas.view.core.base.ImportWindow', {
                         form.setLoading(false);
                         var res = Ext.decode(response.responseText);
                         if(!res.success){
-                            saas.util.BaseUtil.showErrorToast('导入数据失败:' + res.message);
+                            var upload = form.down('[name=upload]');
+                            upload.reset();
+                            form.dockedItems.items[1].down('[name=over]').setDisabled(true);
+                            form.down('[name=messagedetail]').setHtml(res.message + '</br></br><span style="color:#ff0000">请修改后重新上传</span>');
                         }else{
                             //刷新界面
                             var g = form.ownerCt.down('grid');
@@ -106,6 +110,9 @@ Ext.define('saas.view.core.base.ImportWindow', {
                     },
                     failure: function (response, opts) {
                         form.setLoading(false);
+                        var upload = form.down('[name=upload]');
+                        upload.reset();
+                        form.dockedItems.items[1].down('[name=over]').setDisabled(true);
                         var res = Ext.decode(response.responseText);
                         saas.util.BaseUtil.showErrorToast('导入数据失败: ' + res.message);
                     }
@@ -181,7 +188,8 @@ Ext.define('saas.view.core.base.ImportWindow', {
                     collapsible: false,
                     items: [{
                         xtype : 'fieldcontainer',
-                        html: me.showDetail?me.showDetail:'请配置showDetail属性',
+                        html: '1.下载模板后打开</br>2.查看模板内说明、并修改模板内容,保存后点击下一步按钮</br>3.上传Excel文件,此时会校验文件的字段格式,有问题则需要修改错误数据后再次上传文件</br>4.校验成功后'+
+                        '点击完成按钮将数据进行数据库校验'
                     }]
                 },{
                     hidden:true,
@@ -205,14 +213,38 @@ Ext.define('saas.view.core.base.ImportWindow', {
                         }).on('change', me.onFileChange, me);
                     },
                     listeners: {
-                        afterrender:function(field,ops){
-                            // var fileEl = field.fileInputEl.dom;
-                            // fileEl.setAttribute("accept","image/*");
-                        },
                         change: function(field){
                             var form = field.ownerCt.ownerCt;
                             var myForm = field.ownerCt;
                             var fileEl = field.fileInputEl.dom;
+                            var file = fileEl.files[0];
+                            var type = file.name.substring(file.name.lastIndexOf('.'),file.name.length);
+                            if(type.indexOf('xlsx')<0||type.indexOf('xls')<0){
+                                saas.util.BaseUtil.showErrorToast('文件格式不正确,只能选择xlsx或xls格式的文件进行上传');
+                                field.reset();
+                                return;
+                            }
+
+                            //导入权限校验
+                            var hasPower = false;
+                            Ext.Ajax.request({
+                                url: 'http://192.168.253.41:8560/api/commons/'+form.ownerCt.caller+'/import',
+                                async:false,
+                                method: 'GET',
+                                success: function(response, opts) {
+                                    var data = Ext.decode(response.responseText);
+                                    if(data.success){
+                                        hasPower = true
+                                    }
+                                },
+                                failure: function(response, opts) {}
+                            }); 
+                            if(!hasPower){
+                                field.reset();
+                                saas.util.BaseUtil.showErrorToast('上传失败:没有 导入 权限');
+                                return false;
+                            }
+                            
                             var fd = new FormData();
                             fd.append('file', fileEl.files[0]);
                             fd.append('caller', myForm.ownerCt.ownerCt.caller);
@@ -235,22 +267,21 @@ Ext.define('saas.view.core.base.ImportWindow', {
                                     if(res.success){
                                         var id = res.data;
                                         if(id){
-                                            saas.util.BaseUtil.showSuccessToast('上传成功');
+                                            field.ownerCt.down('[name=messagedetail]').setHtml('文件名: ' + file.name + ' 导入格式校验成功!</br></br>请点击 <span style="color:#35baf6">完成</span> 执行数据库校验');
                                             form.importId = id;
+                                            field.ownerCt.ownerCt.dockedItems.items[1].down('[name=over]').setDisabled(false)
                                         }else{
-                                            field.setValue('');
+                                            field.reset();
                                             saas.util.BaseUtil.showErrorToast('上传失败:后台未返回信息');
                                         }
                                     }else{
-                                        field.setValue('');
-                                        field.setRawValue('');
-                                        field.value = '';
-                                        saas.util.BaseUtil.showErrorToast('上传失败: ' + res.message);
+                                        field.reset();
+                                        field.ownerCt.down('[name=messagedetail]').setHtml(res.message + '</br><span style="color:#ff0000">请修改后重新上传</span>');
                                     }
                                 },
                                 failure: function (response, opts) {
                                     form.setLoading(false);
-                                    field.setValue('');
+                                    field.reset();
                                     var res = Ext.decode(response.responseText);
                                     saas.util.BaseUtil.showErrorToast('上传失败: ' + res.message);
                                 }
@@ -265,8 +296,9 @@ Ext.define('saas.view.core.base.ImportWindow', {
                     name:'message',
                     collapsible: false,
                     items: [{
+                        name:'messagedetail',
                         xtype : 'fieldcontainer',
-                        html: '暂无',
+                        html:'暂无导入信息'
                     }]
                 }]
             }]

+ 0 - 1
frontend/saas-web/app/view/core/dbfind/AddMultiDbfindGridPanel.js

@@ -147,7 +147,6 @@ Ext.define('saas.view.core.dbfind.AddMultiDbfindGridPanel', {
                         text:'确定',
                         cls:'x-formpanel-btn-blue',
                         handler:function(b){
-                            debugger
                             var grid = me;//grid
                             var selectRecordArr = grid.selectRecordArr;
                             var dbfinds = grid.dbfinds;

+ 1 - 1
frontend/saas-web/app/view/core/dbfind/AddMultiDbfindTrigger.js

@@ -191,7 +191,7 @@ Ext.define('saas.view.core.dbfind.AddMultiDbfindTrigger', {
         //         }
         //         dbCondition.push({
         //             type: 'condition',
-        //             value: searchField + " like '%"+me.value+"%'"
+        //             value: searchField + "='"+me.value+"'"
         //         });
         //         Ext.Ajax.request({
         //             url: me.dataUrl,

+ 1 - 1
frontend/saas-web/app/view/core/dbfind/DbfindTrigger.js

@@ -209,7 +209,7 @@ Ext.define('saas.view.core.dbfind.DbfindTrigger', {
                 }
                 dbCondition.push({
                     type: 'condition',
-                    value: searchField + " like '%"+me.value+"%'"
+                    value: searchField + "='"+me.value+"'"
                 });
                 Ext.Ajax.request({
                     url: me.dataUrl,

+ 1 - 1
frontend/saas-web/app/view/core/dbfind/MultiDbfindTrigger.js

@@ -192,7 +192,7 @@ Ext.define('saas.view.core.dbfind.MultiDbfindTrigger', {
                 }
                 dbCondition.push({
                     type: 'condition',
-                    value: searchField + " like '%"+me.value+"%'"
+                    value: searchField + "='"+me.value+"'"
                 });
                 Ext.Ajax.request({
                     url: me.dataUrl,

+ 56 - 0
frontend/saas-web/app/view/core/dbfind/types/AccountDbfindTrigger.js

@@ -0,0 +1,56 @@
+/**
+ * 账户资料放大镜
+ */
+Ext.define('saas.view.core.dbfind.types.AccountDbfindTrigger', {
+    extend: 'saas.view.core.dbfind.DbfindTrigger',
+    xtype: 'accountDbfindTrigger',
+
+    //数据接口
+    dataUrl:'/api/account/account/accountRole/list',
+    addXtype: 'sys-account-datalist',
+    addTitle: '账户资料',
+    //联想设置
+    dbtpls:[{
+        field:'realname',width:150
+    }],
+    defaultCondition: "d.status=1",
+    dbSearchFields:[{
+        emptyText:'输入账户名称或真实姓名',
+        xtype : "textfield", 
+        name : "search", 
+        getCondition: function(v) {
+            return "(upper(username) like '%"+v.toUpperCase()+"%' or upper(realname) like '%"+v.toUpperCase()+"%')";
+        },
+        allowBlank : true, 
+        width:300
+    }],
+    //放大镜窗口列表
+    dbColumns:[{
+        text: "账户ID",
+        hidden: true,
+        dataIndex: "id",
+        hidden:true,
+        xtype: "numbercolumn"
+    },{
+        text: "账号名称",
+        dataIndex: "username",
+        hidden:true
+    }, {
+        text: "姓名",
+        dataIndex: "realname",
+        width: 110
+    }, {
+        text: "联系电话",
+        dataIndex: "mobile",
+        width: 110,
+    }, {
+        text: "邮箱",
+        dataIndex: "email",
+        width: 250,
+    }, {
+        text: "岗位角色",
+        dataIndex: "roleNames",
+        width: 200
+    }]
+
+});

+ 5 - 0
frontend/saas-web/app/view/core/dbfind/types/ProductDbfindTrigger.js

@@ -95,5 +95,10 @@ Ext.define('saas.view.core.dbfind.types.ProductDbfindTrigger', {
         dataIndex: "pr_saleprice",
         xtype: 'numbercolumn',
         hidden:true
+    }, {
+        text: "成本单价",
+        dataIndex: "po_avprice",
+        xtype: 'numbercolumn',
+        hidden:true
     }]
 });

+ 5 - 0
frontend/saas-web/app/view/core/dbfind/types/ProductMultiDbfindTrigger.js

@@ -102,6 +102,11 @@ Ext.define('saas.view.core.dbfind.types.ProductMultiDbfindTrigger', {
         dataIndex: "pr_saleprice",
         xtype: 'numbercolumn',
         hidden:true
+    }, {
+        text: "成本单价",
+        dataIndex: "po_avprice",
+        xtype: 'numbercolumn',
+        hidden:true
     }]
 
 });

+ 7 - 7
frontend/saas-web/app/view/core/form/FormPanelController.js

@@ -62,13 +62,13 @@ Ext.define('saas.view.core.form.FormPanelController', {
         // 单据状态为录入状态(未审核)
         main[form._statusCodeField] = auditTexts.unAuditCode;
         main[form._statusField] = auditTexts.unAuditText;
-        //录入人,录入日期,审核人,审核日期清空
-        main['creatorId'] = undefined;
-        main['creatorName'] = undefined;
-        main['createTime'] = undefined;
-        main['updaterId'] = undefined;
-        main['updaterName'] = undefined;
-        main['updateTime'] = undefined;
+        //重设录入人,录入日期,审核人,审核日期
+        main['creatorId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['creatorName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['createTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
+        main['updaterId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['updaterName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['updateTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
         main[form._auditmanField] = undefined;
         main[form._auditdateField] = undefined;
 

+ 2 - 2
frontend/saas-web/app/view/core/report/ReportPanel.js

@@ -81,13 +81,13 @@ Ext.define('saas.view.core.report.ReportPanel', {
                                 items: [{
                                     text: 'Excel xlsx',
                                     cfg: {
-                                        type: 'excel07',
+                                        type: 'excel',
                                         ext: 'xlsx'
                                     }
                                 }, {
                                     text: 'Excel xlsx (包含分组合计)',
                                     cfg: {
-                                        type: 'excel07',
+                                        type: 'excel',
                                         ext: 'xlsx',
                                         includeGroups: true,
                                         includeSummary: true

+ 0 - 1
frontend/saas-web/app/view/core/report/ReportPanelController.js

@@ -38,7 +38,6 @@ Ext.define('saas.view.core.report.ReportPanelController', {
             if(btn.cfg.isPrint){
                 me.printHtml(grid.getDocumentData(cfg));
             }else  {
-                debugger;
                 grid.saveDocumentAs(cfg);
             }
             grid.store.exportPageSize = null;

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

@@ -38,7 +38,7 @@ Ext.define('saas.view.document.customer.FormPanel', {
         xtype: 'textfield',
         name: 'cu_shortname',
         fieldLabel: '客户简称',
-        allowBlank: true,
+        allowBlank: false,
         columnWidth: 0.25
     },{
         xtype: 'textfield',
@@ -185,7 +185,7 @@ Ext.define('saas.view.document.customer.FormPanel', {
         allowBlank : true, 
         columnWidth : 0.25
     },{
-        xtype:'textfield',
+        xtype:'hidden',
         name : "cu_uu", 
         fieldLabel : "客户UU", 
         allowBlank : true, 

+ 9 - 0
frontend/saas-web/app/view/document/product/FormController.js

@@ -65,6 +65,15 @@ Ext.define('saas.view.document.product.FormController', {
         // 单据状态为录入状态(未审核)
         main[form._statusCodeField] = auditTexts.unAuditCode;
         main[form._statusField] = auditTexts.unAuditText;
+        //重设录入人,录入日期,审核人,审核日期
+        main['creatorId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['creatorName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['createTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
+        main['updaterId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['updaterName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['updateTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
+        main[form._auditmanField] = undefined;
+        main[form._auditdateField] = undefined;
 
         for(var k in main) {
             // 主表日期改为当前日期

+ 8 - 2
frontend/saas-web/app/view/document/vendor/FormPanel.js

@@ -38,7 +38,7 @@ Ext.define('saas.view.document.vendor.FormPanel', {
         xtype: 'textfield',
         name: 've_shortname',
         fieldLabel: '供应商简称',
-        allowBlank: true,
+        allowBlank: false,
         columnWidth: 0.25
     },{
         xtype: 'textfield',
@@ -165,7 +165,7 @@ Ext.define('saas.view.document.vendor.FormPanel', {
         allowBlank : true, 
         columnWidth : 0.25
     },{
-        xtype:'textfield',
+        xtype:'hidden',
         name : "ve_uu", 
         fieldLabel : "供应商UU", 
         allowBlank : true, 
@@ -210,6 +210,12 @@ Ext.define('saas.view.document.vendor.FormPanel', {
         name : "ve_buyerid", 
         fieldLabel : "采购员ID",
         defaultValue:saas.util.BaseUtil.getCurrentUser().id
+    },{
+        xtype : "textfield", 
+        name : "ve_address", 
+        fieldLabel : "地址", 
+        allowBlank : true, 
+        columnWidth : 1
     },{
         fieldLabel : "备注", 
         xtype:'textfield',

+ 21 - 1
frontend/saas-web/app/view/home/HomeModel.js

@@ -82,7 +82,17 @@ Ext.define('saas.view.home.HomeModel', {
                     var p = Ext.getCmp('infocard');
                         p && p.setLoading(false);
                     var sum = Ext.util.Format.number(s.sum('y'), '0.00') || 0;
-                    Ext.getCmp('home').getViewModel().set('month_sale_amount', sum)
+                    Ext.getCmp('home').getViewModel().set('month_sale_amount', sum);
+
+                    s.each(function(r) {
+                        var z = r.get('z'),
+                        x = r.get('x');
+                        if(!z) {
+                            r.set('z', x.length > 3 ? (x.substr(0,3) + '...') : x);
+                        }else {
+                            r.set('z', z.length > 3 ? (z.substr(0,3) + '...') : z);
+                        }
+                    });
                 }
             }
         },
@@ -349,6 +359,16 @@ Ext.define('saas.view.home.HomeModel', {
                 load: function(s, d) {
                     var p = Ext.getCmp('profit_detail');
                         p && p.setLoading(false);
+
+                    s.each(function(r) {
+                        var z = r.get('z'),
+                        x = r.get('x');
+                        if(!z) {
+                            r.set('z', x.length > 3 ? (x.substr(0,3) + '...') : x);
+                        }else {
+                            r.set('z', z.length > 3 ? (z.substr(0,3) + '...') : z);
+                        }
+                    });
                 }
             } 
         },

+ 21 - 21
frontend/saas-web/app/view/home/charts/KeyData.js

@@ -105,27 +105,27 @@ Ext.define('saas.view.home.charts.KeyData', {
                 itemclick: function(th, record, item, index, e, eOpts) {
                     saas.util.BaseUtil.openTab(record.get('viewType'), record.get('title'), record.get('id'));
                 },
-                itemmouseenter: function(th, record, item, index, e, eOpts) {
-                    var tip = th.tip;
-                    if(!tip) {
-                        var tip = Ext.create('Ext.tip.ToolTip', {
-                            target: th.el,
-                            minWidth: 100,
-                            title: record.get('label'),
-                            html: record.get('value'),
-                            showOnTap: true,
-                            trackMouse: true
-                        });
-                        th.tip = tip;
-                        tip.showAt(e.getXY());
-                    }
-                },
-                itemmouseleave: function(th, record, item, index, e, eOpts) {
-                    var tip = th.tip;
-                    if(tip) {
-                        th.tip = Ext.destroy(th.tip);
-                    }
-                }
+                // itemmouseenter: function(th, record, item, index, e, eOpts) {
+                //     var tip = th.tip;
+                //     if(!tip) {
+                //         var tip = Ext.create('Ext.tip.ToolTip', {
+                //             target: th.el,
+                //             minWidth: 100,
+                //             title: record.get('label'),
+                //             html: record.get('value'),
+                //             showOnTap: true,
+                //             trackMouse: true
+                //         });
+                //         th.tip = tip;
+                //         tip.showAt(e.getXY());
+                //     }
+                // },
+                // itemmouseleave: function(th, record, item, index, e, eOpts) {
+                //     var tip = th.tip;
+                //     if(tip) {
+                //         th.tip = Ext.destroy(th.tip);
+                //     }
+                // }
             }
         });
 

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

@@ -51,10 +51,10 @@ Ext.define('saas.view.home.charts.MonthIO', {
                     },
                     grid: {
                         even: {
-                            stroke: '#F7F8FA'
+                            stroke: '#E2E7ED'
                         },
                         odd: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         }
                     },
                     style: {
@@ -70,7 +70,7 @@ Ext.define('saas.view.home.charts.MonthIO', {
                         fillStyle: '#485465'
                     },
                     style: {
-                        fill: '#F7F8FA',
+                        fill: '#E2E7ED',
                         strokeStyle: 'transparent'
                     },
                 }],
@@ -102,6 +102,6 @@ Ext.define('saas.view.home.charts.MonthIO', {
         var fieldIndex = Ext.Array.indexOf(item.series.getYField(), item.field),
         type = item.series.getTitle()[fieldIndex];
 
-        tooltip.setHtml(type + record.get('x') + record.get(item.field));
+        tooltip.setHtml(type + record.get('x') + ': ' + Ext.util.Format.number(record.get(item.field), '0,000.00') + '万元');
     },
 });

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

@@ -30,7 +30,7 @@ Ext.define('saas.view.home.charts.MonthPurchase', {
                         fillStyle: '#485465',
                     },
                     style: {
-                        fill: '#F7F8FA',
+                        fill: '#E2E7ED',
                         strokeStyle: 'transparent'
                     },
                     renderer: me.onCategoryLabelRender
@@ -41,10 +41,10 @@ Ext.define('saas.view.home.charts.MonthPurchase', {
                     adjustByMajorUnit: true,
                     grid: {
                         even: {
-                            stroke: '#F7F8FA'
+                            stroke: '#E2E7ED'
                         },
                         odd: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         }
                     },
                     label: {
@@ -85,7 +85,7 @@ Ext.define('saas.view.home.charts.MonthPurchase', {
     },
 
     onBarTipRender: function (tooltip, record, item) {
-        tooltip.setHtml(record.get('x') + ': ' + record.get('y') + '万元');
+        tooltip.setHtml(record.get('x') + ': ' + Ext.util.Format.number(record.get('y'), '0,000.00') + '万元');
     },
 
 });

+ 2 - 2
frontend/saas-web/app/view/home/charts/MonthSale.js

@@ -64,7 +64,7 @@ Ext.define('saas.view.home.charts.MonthSale', {
                     angleField: 'y',
                     donut: 55,
                     label: {
-                        field: 'x',
+                        field: 'z',
                         display: 'inside',
                         renderer: me.onLabelRender,
                         color: '#fff',
@@ -102,6 +102,6 @@ Ext.define('saas.view.home.charts.MonthSale', {
     },
 
     onSeriesTooltipRender: function (tooltip, record, item) {
-        tooltip.setHtml(record.get('x') + ': ' + record.get('y'));
+        tooltip.setHtml(record.get('x') + ': ' + Ext.util.Format.number(record.get('y'), '0,000.00'));
     }
 });

+ 7 - 7
frontend/saas-web/app/view/home/charts/ProfitDetail.js

@@ -23,14 +23,14 @@ Ext.define('saas.view.home.charts.ProfitDetail', {
                 },
                 axes: [{
                     type: 'category',
-                    fields: ['x'],
+                    fields: ['z'],
                     position: 'bottom',
                     label: {
                         fontSize: '12px',
                         fillStyle: '#485465',
                     },
                     style: {
-                        fill: '#F7F8FA',
+                        fill: '#E2E7ED',
                         strokeStyle: 'transparent'
                     },
                     renderer: me.onCategoryLabelRender
@@ -41,10 +41,10 @@ Ext.define('saas.view.home.charts.ProfitDetail', {
                     adjustByMajorUnit: true,
                     grid: {
                         even: {
-                            stroke: '#F7F8FA'
+                            stroke: '#E2E7ED'
                         },
                         odd: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         }
                     },
                     label: {
@@ -60,7 +60,7 @@ Ext.define('saas.view.home.charts.ProfitDetail', {
                 }],
                 series: [{
                     type: 'bar',
-                    xField: 'x',
+                    xField: 'z',
                     yField: ['y'],
                     bind: {
                         style: {
@@ -81,11 +81,11 @@ Ext.define('saas.view.home.charts.ProfitDetail', {
     },
 
     onCategoryLabelRender: function(axis, label, layoutContent, lastLabel) {
-        return label.substr(0,2) + '...';
+        return label;
     },
 
     onBarTipRender: function (tooltip, record, item) {
-        tooltip.setHtml(record.get('x') + ': ' + record.get('y') + '万元');
+        tooltip.setHtml(record.get('x') + ': ' + Ext.util.Format.number(record.get('y'), '0,000.00') + '万元');
     },
 
 });

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

@@ -34,7 +34,7 @@ Ext.define('saas.view.home.charts.PurchaseTrend', {
                         fillStyle: '#485465'
                     },
                     style: {
-                        fill: '#F7F8FA',
+                        fill: '#E2E7ED',
                         strokeStyle: 'transparent'
                     },
                     renderer: me.categoryRender
@@ -44,10 +44,10 @@ Ext.define('saas.view.home.charts.PurchaseTrend', {
                     position: 'left',
                     grid: {
                         even: {
-                            stroke: '#F7F8FA'
+                            stroke: '#E2E7ED'
                         },
                         odd: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         }
                     },
                     label: {
@@ -88,7 +88,7 @@ Ext.define('saas.view.home.charts.PurchaseTrend', {
     },
 
     onBarTipRender: function (tooltip, record, item) {
-        tooltip.setHtml(record.get('x') + '月: ' + record.get('y') + '万元');
+        tooltip.setHtml(record.get('x') + '月: ' + Ext.util.Format.number(record.get('y'), '0,000.00') + '万元');
     },
 
     categoryRender: function(axis, label, layoutContext, lastLabel) {

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

@@ -40,7 +40,7 @@ Ext.define('saas.view.home.charts.SaleTrend', {
                         fillStyle: '#485465',
                     },
                     style: {
-                        fill: '#F7F8FA',
+                        fill: '#E2E7ED',
                         strokeStyle: 'transparent'
                     },
                     renderer: me.categoryRender
@@ -50,10 +50,10 @@ Ext.define('saas.view.home.charts.SaleTrend', {
                     position: 'left',
                     grid: {
                         even: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         },
                         odd: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         }
                     },
                     label: {
@@ -173,7 +173,7 @@ Ext.define('saas.view.home.charts.SaleTrend', {
     },
 
     onSeriesTooltipRender: function (tooltip, record, item) {
-        tooltip.setHtml(record.get('x') + '月: ' + record.get(item.series.getYField()) + '万元');
+        tooltip.setHtml(record.get('x') + '月: ' + Ext.util.Format.number(record.get(item.series.getYField()), '0,000.00') + '万元');
     },
 
     categoryRender: function(axis, label, layoutContext, lastLabel) {

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

@@ -34,7 +34,7 @@ Ext.define('saas.view.home.charts.StockAmount', {
                         fillStyle: '#485465'
                     },
                     style: {
-                        fill: '#F7F8FA',
+                        fill: '#E2E7ED',
                         strokeStyle: 'transparent'
                     },
                     renderer: me.categoryRender
@@ -44,10 +44,10 @@ Ext.define('saas.view.home.charts.StockAmount', {
                     position: 'left',
                     grid: {
                         even: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         },
                         odd: {
-                            stroke: '#F7F8FA',
+                            stroke: '#E2E7ED',
                         }
                     },
                     label: {
@@ -82,7 +82,7 @@ Ext.define('saas.view.home.charts.StockAmount', {
     },
 
     onBarTipRender: function (tooltip, record, item) {
-        tooltip.setHtml(record.get('x') + '月: ' + record.get('y') + '万元');
+        tooltip.setHtml(record.get('x') + '月: ' + Ext.util.Format.number(record.get('y'), '0,000.00') + '万元');
     },
 
     categoryRender: function(axis, label, layoutContext, lastLabel) {

+ 2 - 1
frontend/saas-web/app/view/money/payBalance/FormPanel.js

@@ -63,7 +63,8 @@ Ext.define('saas.view.money.payBalance.FormPanel', {
     },{
         xtype: 'textfield',
         name: 'pb_manname',
-        fieldLabel: '付款人'
+        fieldLabel: '付款人',
+        defaultValue: saas.util.BaseUtil.getCurrentUser().realname
     }, {
         xtype: 'hidden',
         name: 'pb_pdamount',

+ 2 - 1
frontend/saas-web/app/view/money/recBalance/FormPanel.js

@@ -70,7 +70,8 @@ Ext.define('saas.view.money.recBalance.FormPanel', {
     }, {
         xtype: "textfield",
         name: "rb_manname",
-        fieldLabel: "收款人"
+        fieldLabel: "收款人",
+        defaultValue: saas.util.BaseUtil.getCurrentUser().realname
     }, {
         xtype: "numberfield",
         name: "rb_discounts",

+ 3 - 3
frontend/saas-web/app/view/money/report/TotalPayDetail.js

@@ -36,17 +36,17 @@ Ext.define('saas.view.money.report.TotalPayDetail', {
     reportColumns: [{
         text: '供应商编号',
         dataIndex: 'vm_vendcode',
-        width: 200
+        width: 190
     }, {
         text: '供应商名称',
         dataIndex: 'vm_vendname',
-        width: 200,
+        width: 210,
     }, {
         text: '期初预付',
         xtype: 'numbercolumn',
         exportFormat: 'Amount',
         dataIndex: 'vm_beginpreamount',
-        width: 150,
+        width: 110,
         renderer: function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');

+ 8 - 8
frontend/saas-web/app/view/money/report/TotalRecDetail.js

@@ -36,17 +36,17 @@ Ext.define('saas.view.money.report.TotalRecDetail', {
     reportColumns: [{
         text: '客户编号',
         dataIndex: 'cm_custcode',
-        width: 200
+        width: 190
     }, {
         text: '客户名称',
         dataIndex: 'cm_custname',
-        width: 200,
+        width: 210,
     }, {
         text: '期初预收',
         dataIndex: 'cm_beginpreamount',
         exportFormat: 'Amount',
         xtype: 'numbercolumn',
-        width: 150,
+        width: 110,
         renderer: function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
@@ -58,7 +58,7 @@ Ext.define('saas.view.money.report.TotalRecDetail', {
         dataIndex: 'cm_beginamount',
         exportFormat: 'Amount',
         xtype: 'numbercolumn',
-        width: 150,
+        width: 110,
         renderer: function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
@@ -70,7 +70,7 @@ Ext.define('saas.view.money.report.TotalRecDetail', {
         xtype: 'numbercolumn',
         exportFormat: 'Amount',
         dataIndex: 'cm_nowamount',
-        width: 150,
+        width: 110,
         renderer: function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
@@ -82,7 +82,7 @@ Ext.define('saas.view.money.report.TotalRecDetail', {
         xtype: 'numbercolumn',
         exportFormat: 'Amount',
         dataIndex: 'cm_nowpayamount',
-        width: 150,
+        width: 110,
         renderer: function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
@@ -94,7 +94,7 @@ Ext.define('saas.view.money.report.TotalRecDetail', {
         xtype: 'numbercolumn',
         exportFormat: 'Amount',
         dataIndex: 'cm_endpreamount',
-        width: 150,
+        width: 110,
         renderer: function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
@@ -106,7 +106,7 @@ Ext.define('saas.view.money.report.TotalRecDetail', {
         dataIndex: 'cm_endamount',
         exportFormat: 'Amount',
         xtype: 'numbercolumn',
-        width: 150,
+        width: 110,
         renderer : function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');

+ 7 - 7
frontend/saas-web/app/view/purchase/purchaseIn/FormPanelController.js

@@ -110,13 +110,13 @@ Ext.define('saas.view.purchase.purchaseIn.FormPanelController', {
         // 单据状态为录入状态(未审核)
         main[form._statusCodeField] = auditTexts.unAuditCode;
         main[form._statusField] = auditTexts.unAuditText;
-        //录入人,录入日期,审核人,审核日期清空
-        main['creatorId'] = undefined;
-        main['creatorName'] = undefined;
-        main['createTime'] = undefined;
-        main['updaterId'] = undefined;
-        main['updaterName'] = undefined;
-        main['updateTime'] = undefined;
+        //重设录入人,录入日期,审核人,审核日期
+        main['creatorId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['creatorName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['createTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
+        main['updaterId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['updaterName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['updateTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
         main[form._auditmanField] = undefined;
         main[form._auditdateField] = undefined;
 

+ 7 - 7
frontend/saas-web/app/view/purchase/purchaseOut/FormPanelController.js

@@ -114,13 +114,13 @@ Ext.define('saas.view.purchase.purchaseOut.FormPanelController', {
         // 单据状态为录入状态(未审核)
         main[form._statusCodeField] = auditTexts.unAuditCode;
         main[form._statusField] = auditTexts.unAuditText;
-        //录入人,录入日期,审核人,审核日期清空
-        main['creatorId'] = undefined;
-        main['creatorName'] = undefined;
-        main['createTime'] = undefined;
-        main['updaterId'] = undefined;
-        main['updaterName'] = undefined;
-        main['updateTime'] = undefined;
+        //重设录入人,录入日期,审核人,审核日期
+        main['creatorId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['creatorName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['createTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
+        main['updaterId'] = saas.util.BaseUtil.getCurrentUser().id;
+        main['updaterName'] = saas.util.BaseUtil.getCurrentUser().realname;
+        main['updateTime'] = Ext.Date.format(new Date(), 'Y-m-d H:i:s');
         main[form._auditmanField] = undefined;
         main[form._auditdateField] = undefined;
 

+ 33 - 9
frontend/saas-web/app/view/purchase/purchaseOut/QueryPanel.js

@@ -25,7 +25,14 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
         name: 'pr_detail',
         fieldLabel: '物料',
         emptyText:'输入物料编号或名称',
-        showDetail: true
+        showDetail: true,
+        getCondition: function(value) {
+            if(!value) {
+                return '1=1';
+            }else {
+                return ' pr_detail = \'' + value + '\' ';
+            }
+        }
     }, {
         xtype: 'combobox',
         name: 'pi_statuscode',
@@ -66,14 +73,21 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
         name: 'pd_whname',
         fieldLabel: '仓库',
         emptyText:'请输入仓库编号或名称',
-        showDetail: true
+        showDetail: true,
+        getCondition: function(value) {
+            if(!value) {
+                return '1=1';
+            }else {
+                return 'prodiodetail.pd_whname like\'%' + value + '%\'';
+            }
+        }
     }, {
         xtype: 'textfield',
         name: 'pi_iocode',
         fieldLabel: '关联验收单号',
         emptyText: '输入单号',
     }, {
-        xtype: 'employeeDbfindTrigger',
+        xtype: 'accountDbfindTrigger',
         name: 'creatorName',
         fieldLabel: '录入人',
         emptyText:'请输入人员编号或名称',
@@ -85,7 +99,7 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
             }
         }
     }, {
-        xtype: 'employeeDbfindTrigger',
+        xtype: 'accountDbfindTrigger',
         name: 'pi_auditman',
         fieldLabel: '审核人',
         emptyText:'请输入人员编号或名称'
@@ -177,7 +191,7 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
             },{
                 text: '供应商名称',
                 dataIndex: 'pi_vendname',
-                width: 150
+                width: 250
             },{
                 text: '审核状态',
                 align: 'center',
@@ -186,15 +200,25 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
             },{
                 text: '序号',
                 dataIndex: 'pd_pdno',
-                width: 80
+                width: 80, 
+                renderer : function(v) {
+                    return Ext.util.Format.number(v, '0');
+                }
             },{
-                text: '相关单号',
-                dataIndex: 'pd_ordercode',
+                text: '关联验收单号',
+                dataIndex: 'pi_iocode',
+                width: 150
+            },{
+                text: '关联验收序号号',
+                dataIndex: 'iodetno',
                 width: 150
             },{
                 text: '物料编号',
                 dataIndex: 'pd_prodcode',
-                width: 150
+                width: 150, 
+                renderer : function(v) {
+                    return Ext.util.Format.number(v, '0');
+                }
             },{
                 text: '物料名称',
                 dataIndex: 'pr_detail',

+ 4 - 9
frontend/saas-web/app/view/purchase/purchaseOut/QueryPanelController.js

@@ -28,24 +28,19 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanelController', {
                     }) ;   
 
                 }
-            },'employeeDbfindTrigger[name=creatorName]':{
+            },'accountDbfindTrigger[name=creatorName]':{
                 beforerender:function(f){
                     Ext.apply(f,{
                         dbfinds:[{
-                            from:'em_code',to:'em_code'
-                        },{
-                            from:'em_name',to:'creatorName'
+                            from:'realname',to:'creatorName'
                         }],
                     }) ;   
 
                 }
-            },'employeeDbfindTrigger[name=pi_auditman]':{
+            },'accountDbfindTrigger[name=pi_auditman]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dbfinds:[{
-                            from:'em_code',to:'em_code'
-                        },{
-                            from:'em_name',to:'pi_auditman',
+                        dbfinds:[{ from:'realname',to:'pi_auditman',
                         }],
                     }) ;   
 

+ 2 - 1
frontend/saas-web/app/view/sale/report/SaleRec.js

@@ -8,7 +8,7 @@ Ext.define('saas.view.sale.report.SaleRec', {
     viewName: 'sale-report-salerec',
 
     groupField: 'rb_custcode',
-    groupHeaderTpl: '客户名称: {[values.rows[0].data.rd_custname]}',
+    groupHeaderTpl: '客户名称: {[values.rows[0].data.rb_custname]}',
     listUrl: '/api/sale/report/saleRec',
     defaultCondition: null,
     reportTitle: '销售收款报表',
@@ -99,6 +99,7 @@ Ext.define('saas.view.sale.report.SaleRec', {
     }, {
         text: '回款比例%',
         dataIndex: 'rb_backrate',
+        exportFormat: 'Number2',
         xtype: 'numbercolumn',
         renderer : function(v) {
             var arr = (v + '.').split('.');

+ 1 - 0
frontend/saas-web/app/view/sale/saleIn/QueryPanel.js

@@ -65,6 +65,7 @@ Ext.define('saas.view.sale.saleIn.QueryPanel', {
         name: 'pd_whname',
         fieldLabel: '仓库',
         emptyText: '输入仓库编号或名称',
+        showDetail: true
     }, {
         xtype: 'textfield',
         name: 'pi_iocode',

+ 2 - 1
frontend/saas-web/app/view/sale/saleOut/QueryPanel.js

@@ -64,7 +64,8 @@ Ext.define('saas.view.sale.saleout.QueryPanel', {
         xtype: 'warehouseDbfindTrigger',
         name: 'pd_whname',
         emptyText:'请输入物料编号或名称',
-        fieldLabel: '仓库'
+        fieldLabel: '仓库',
+        showDetail: true
     }, {
         xtype: 'textfield',
         name: 'pi_sacode',

+ 1 - 1
frontend/saas-web/app/view/stock/make/FormPanelController.js

@@ -61,7 +61,7 @@ Ext.define('saas.view.stock.make.FormPanelController', {
                             from: 'pr_unit',
                             to: 'pr_unit'
                         }, {
-                            from: 'pr_purcprice',
+                            from: 'po_avprice',
                             to: 'mm_price'
                         }],
                     });

+ 1 - 2
frontend/saas-web/app/view/stock/report/DataList.js

@@ -9,7 +9,6 @@ Ext.define('saas.view.stock.report.DataList', {
 
     groupField: null,
     listUrl: '/api/document/product/ReserveCost',
-    // listUrl: 'http://192.168.253.41:8560/api/document/product/ReserveCost',
     defaultCondition: null,
     reportTitle: '物料库存数量金额表',
     QueryWidth: 0.65,
@@ -91,7 +90,6 @@ Ext.define('saas.view.stock.report.DataList', {
         text: "单价",
         xtype: 'numbercolumn',
         exportFormat: 'Price',
-        hidden: true,
         toggle: true,
         align: 'end',
         dataIndex: "rc_price",
@@ -107,6 +105,7 @@ Ext.define('saas.view.stock.report.DataList', {
         xtype: 'numbercolumn',
         dataIndex: "rc_amount",
         exportFormat: 'Amount',
+        toggle: true,
         width: 120,
         renderer: function (v) {
             var arr = (v + '.').split('.');

+ 1 - 1
frontend/saas-web/app/view/stock/report/DataListController.js

@@ -34,7 +34,7 @@ Ext.define('saas.view.stock.report.DataListController', {
         
         form.updateLayout();
         toggleColumns.map(function(c) {
-            c.setHidden(!newValue);
+            c.setHidden(c.isVisible());
         });
         store.load();
     }

+ 1 - 1
frontend/saas-web/app/view/sys/account/DataList.js

@@ -248,7 +248,7 @@ Ext.define('saas.view.sys.account.DataList', {
             gridBodyBox = grid.body.dom.getBoundingClientRect(),
             gridBodyBoxHeight = gridBodyBox.height;
 
-            var pageSize = Math.floor(gridBodyBoxHeight / 32);
+            var pageSize = Math.floor(gridBodyBoxHeight / 35);
 
             store.setPageSize(pageSize);
         },

+ 24 - 7
frontend/saas-web/overrides/exporter/Stylesheet.js

@@ -10,15 +10,31 @@ Ext.define('saas.override.exporter.Stylesheet', {
         'Currency': '"$"#,##0.00',
         'Euro Currency': '"€"#,##0.00',
         /**  new  */
-        'Integer': function(v) {
+        'Number0': function(v) {
             return Ext.util.Format.number(v, '0');
         },
-        'Total':function(v) {
-            var arr = (v + '.').split('.');
-            var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
-            var format = '0,000.' + xr.join('');
-            return Ext.util.Format.number(v, format);
+        'Number1': function(v) {
+            return Ext.util.Format.number(v, '0.0');
+        },
+        'Number2': function(v) {
+            return Ext.util.Format.number(v, '0.00');
+        },
+        'Number3': function(v) {
+            return Ext.util.Format.number(v, '0.000');
+        },
+        'Number4': function(v) {
+            return Ext.util.Format.number(v, '0.0000');
+        },
+        'Integer': function(v) {
+            return Ext.util.Format.number(v, '0');
         },
+        // 'Total':function(v) {
+        //     var arr = (v + '.').split('.');
+        //     var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
+        //     var format = '0,000.' + xr.join('');
+        //     return Ext.util.Format.number(v, format);
+        // },
+        'Total': '#,##0.00',
         'Amount': function(v) {
             var arr = (v + '.').split('.');
             var xr = (new Array(arr[1].length > 2 ? 2 : arr[1].length)).fill('0');
@@ -37,6 +53,7 @@ Ext.define('saas.override.exporter.Stylesheet', {
             var format = '0,000.' + xr.join('');
             return Ext.util.Format.number(v, format);
         },
-    }
+        // 'Price': '#,##0.00',
+    },
 
 });

+ 11 - 1
frontend/saas-web/overrides/exporter/file/Style.js

@@ -11,7 +11,17 @@ Ext.define('saas.override.exporter.file.Style', {
             return ret;
         }
 
-        if(f === 'Integer') { // new
+        if(f === 'Number0') {
+            return Ext.util.Format.number(v, '0');
+        }else if(f === 'Number1') {
+            return Ext.util.Format.number(v, '0.0');
+        }else if(f === 'Number2') {
+            return Ext.util.Format.number(v, '0.00');
+        }else if(f === 'Number3') {
+            return Ext.util.Format.number(v, '0.000');
+        }else if(f === 'Number4') {
+            return Ext.util.Format.number(v, '0.0000');
+        }else if(f === 'Integer') { // new
             return Ext.util.Format.number(v, '0');
         }else if(f === 'Total') {
             var arr = (v + '.').split('.');

BIN
frontend/saas-web/resources/images/auth-background.jpg