Browse Source

Merge remote-tracking branch 'origin/dev' into dev

heqinwei 7 years ago
parent
commit
ec4fbf922e
21 changed files with 113 additions and 86 deletions
  1. 4 1
      applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/ProdInOutService.java
  2. 36 29
      applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/impl/ProdInOutServiceImpl.java
  3. 2 2
      applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/impl/PurchaseServiceImpl.java
  4. 2 0
      applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/po/report/SalerecView.java
  5. 3 0
      applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/ProdInOutService.java
  6. 19 10
      applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/impl/ProdInOutServiceImpl.java
  7. 7 3
      applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/impl/SaleServiceImpl.java
  8. 1 0
      applications/sale/sale-server/src/main/resources/mapper/SalerecViewMapper.xml
  9. 1 0
      applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/po/report/ProdiodetailView.java
  10. 3 2
      applications/storage/storage-server/src/main/java/com/usoftchina/saas/storage/service/impl/ProdInOutServiceImpl.java
  11. 1 0
      applications/storage/storage-server/src/main/resources/mapper/ProdInOutReportMapper.xml
  12. 1 1
      base-servers/mail/mail-api/src/main/java/com/usoftchina/saas/mail/MailBuilder.java
  13. 4 0
      base-servers/mail/mail-server/pom.xml
  14. 1 1
      base-servers/mail/mail-server/src/main/java/com/usoftchina/saas/mail/MailApplication.java
  15. 2 0
      frontend/saas-web/app/view/core/form/FormPanel.js
  16. 9 9
      frontend/saas-web/app/view/document/customer/BasePanel.js
  17. 2 2
      frontend/saas-web/app/view/document/product/BasePanel.js
  18. 7 7
      frontend/saas-web/app/view/document/vendor/BasePanel.js
  19. 2 17
      frontend/saas-web/app/view/main/Main.js
  20. 2 2
      frontend/saas-web/app/view/stock/make/FormPanel.js
  21. 4 0
      frontend/saas-web/overrides/i18n.js

+ 4 - 1
applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/ProdInOutService.java

@@ -6,6 +6,7 @@ import com.usoftchina.saas.base.service.CommonBaseService;
 import com.usoftchina.saas.commons.dto.BatchDealBaseDTO;
 import com.usoftchina.saas.commons.dto.DocBaseDTO;
 import com.usoftchina.saas.commons.dto.ListReqDTO;
+import com.usoftchina.saas.commons.po.BillCodeSeq;
 import com.usoftchina.saas.page.PageRequest;
 import com.usoftchina.saas.purchase.dto.ProdInOutFormDTO;
 import com.usoftchina.saas.purchase.mapper.ProdInOutMapper;
@@ -77,7 +78,9 @@ public interface ProdInOutService extends CommonBaseService<ProdInOutMapper, Pro
 
     void calcProdInout(Long pi_id, String pi_class);
 
-    String pushMaxnubmer(ProdInOut prodInOut);
+    //String pushMaxnubmer(DocBaseDTO baseDTO);
+
+    String getMaxnumber(BillCodeSeq bill);
 
     void getDefaultWarehouseByProduct(Long pi_id);
 }

+ 36 - 29
applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/impl/ProdInOutServiceImpl.java

@@ -30,6 +30,7 @@ import com.usoftchina.saas.purchase.service.ProdInOutService;
 import com.usoftchina.saas.utils.BeanMapper;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Propagation;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.StringUtils;
 
@@ -112,7 +113,7 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
     }
 
     @Override
-    @Transactional
+    @Transactional(propagation = Propagation.REQUIRED)
     public DocBaseDTO saveFormData(ProdInOutFormDTO formdata) {
         if (null == formdata || null == formdata.getMain()){
             throw new BizException(500, "数据为空,请填写后再保存");
@@ -120,8 +121,7 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         //公司ID
         Long companyId = BaseContextHolder.getCompanyId();
         //人员Id
-        Map<String,Object>  emp= employeeApi.getEmployeeByAccount();
-        Long userId = Long.valueOf(String.valueOf(emp.get("em_id")));
+        Long userId = BaseContextHolder.getUserId();
 
         //获取主表信息
         ProdInOutDTO main = formdata.getMain();
@@ -137,14 +137,17 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         ProdInOut prodInOut = BeanMapper.map(main,ProdInOut.class);
         prodInOut.setCompanyId(companyId);
         prodInOut.setPi_recordmanid(userId.intValue());
-        prodInOut.setPi_recordman(emp.get("em_name").toString());
+//        prodInOut.setPi_recordman(emp.get("em_name").toString());
         prodInOut.setCreatorId(userId);
         prodInOut.setCreateTime(new Date());
         prodInOut.setPi_date(new Date());
         prodInOut.setPi_puid(main.getPi_puid());
         prodInOut.setPi_pucode(main.getPi_pucode());
+        baseDTO.setCode(pi_inoutno);
+        baseDTO.setId(pi_id);
+        baseDTO.setName(pi_class);
         //编号获取
-        pi_inoutno = pushMaxnubmer(prodInOut);
+        pi_inoutno = pushMaxnubmer(baseDTO);
         prodInOut.setPi_inoutno(pi_inoutno);
 
         //判断更新与保存动作
@@ -225,6 +228,7 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         singleDelete(id);
     }
 
+    @Transactional(propagation = Propagation.REQUIRED)
     private void singleDelete(Long id) {
 
             ProdInOut prodInOut = checkAndReturnOrder(id);;
@@ -241,13 +245,12 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
 
 
     @Override
-    @Transactional
     public DocBaseDTO audit(ProdInOutFormDTO formData) {
         Long id = null;
         DocBaseDTO baseDTO = new DocBaseDTO();
         if (null != formData) {
             id = formData.getMain().getId();
-            if (StringUtils.isEmpty(id)) {
+            if (StringUtils.isEmpty(id) ||"0".equals(String.valueOf(id))) {
                 baseDTO = saveFormData(formData);
                 id = baseDTO.getId();
             }
@@ -257,6 +260,7 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         return baseDTO;
     }
 
+    @Transactional(propagation = Propagation.REQUIRED)
     private void singleAudit(ProdInOutDTO prodInOutDTO) {
         String pi_class= prodInOutDTO.getPi_class();
         String pi_inoutno = prodInOutDTO.getPi_inoutno();
@@ -428,7 +432,7 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         //插入验退单主表
         ProdInOut targetPi = new ProdInOut();
         //生成单号
-        String piInoutno = maxnumberService.getMaxnumber(BillCodeSeq.PURCHASEOUT.getCaller(),true).getData();
+        String piInoutno = getMaxnumber(BillCodeSeq.PURCHASEOUT);
         targetPi.setPi_inoutno(piInoutno);
         targetPi.setPi_class(BillCodeSeq.PURCHASEOUT.getName());
         targetPi.setPi_date(new Date());
@@ -546,7 +550,6 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         return docBaseDTO;
     }
 
-
     @Override
     public DocBaseDTO open(long id) {
         return singleOpen(id);
@@ -575,26 +578,6 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         return baseDTO;
     }
 
-
-    public String pushMaxnubmer(ProdInOut prodInOut) {
-        String pi_inoutno = prodInOut.getPi_inoutno();
-        String pi_class = prodInOut.getPi_class();
-        Long id = prodInOut.getId();
-        if (null == pi_inoutno) {
-            throw new BizException(BizExceptionCode.NULL_CODE);
-        }
-        Long companyId = BaseContextHolder.getCompanyId();
-        Integer count = "0".equals(String.valueOf(id)) ? getMapper().validateCodeWhenInsert(pi_inoutno, companyId) :
-                getMapper().validateCodeWhenUpdate(pi_inoutno, id, companyId);
-        String caller ="";
-        if("采购验收单".equals(pi_class)){
-            caller = BillCodeSeq.PURCHASEIN.getCaller();
-        }else if("采购验退单".equals(pi_class)) {
-            caller = BillCodeSeq.PURCHASEOUT.getCaller();
-        }
-        return maxnumberService.pushMaxnubmer(count, pi_inoutno, caller).getData();
-    }
-
     @Override
     @Transactional
     public void getDefaultWarehouseByProduct(Long pi_id) {
@@ -613,5 +596,29 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         return prodInOut;
     }
 
+    @Override
+    public String getMaxnumber(BillCodeSeq bill) {
+        String code = maxnumberService.getMaxnumber(bill.getCaller(), false).getData();
+        DocBaseDTO base = new DocBaseDTO(0l, code, bill.getName());
+        return pushMaxnubmer(base);
+    }
 
+    public synchronized String pushMaxnubmer(DocBaseDTO baseDTO) {
+        String pi_inoutno = baseDTO.getCode();
+        String pi_class = baseDTO.getName();
+        Long id = baseDTO.getId();
+        if (null == pi_inoutno) {
+            throw new BizException(BizExceptionCode.NULL_CODE);
+        }
+        Long companyId = BaseContextHolder.getCompanyId();
+        Integer count = "0".equals(String.valueOf(id)) ? getMapper().validateCodeWhenInsert(pi_inoutno, companyId) :
+                getMapper().validateCodeWhenUpdate(pi_inoutno, id, companyId);
+        String caller ="";
+        if("采购验收单".equals(pi_class)){
+            caller = BillCodeSeq.PURCHASEIN.getCaller();
+        }else if("采购验退单".equals(pi_class)) {
+            caller = BillCodeSeq.PURCHASEOUT.getCaller();
+        }
+        return maxnumberService.pushMaxnubmer(count, pi_inoutno, caller).getData();
+    }
 }

+ 2 - 2
applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/impl/PurchaseServiceImpl.java

@@ -416,7 +416,7 @@ public class PurchaseServiceImpl extends CommonBaseServiceImpl<PurchaseMapper, P
         //插入验收单主表
         ProdInOut prodInOut = new ProdInOut();
         //生成单号
-        String piInoutno =maxnumberService.getMaxnumber(BillCodeSeq.PURCHASEIN.getCaller(),true).getData();
+        String piInoutno = prodInOutService.getMaxnumber(BillCodeSeq.PURCHASEIN);
         prodInOut.setPi_inoutno(piInoutno);
         prodInOut.setPi_class("采购验收单");
         prodInOut.setPi_date(new Date());
@@ -561,7 +561,7 @@ public class PurchaseServiceImpl extends CommonBaseServiceImpl<PurchaseMapper, P
     * @Author: guq
     * @Date: 2018/10/19
     */
-    private String pushMaxnubmer(String code, Long id) {
+    private synchronized String pushMaxnubmer(String code, Long id) {
         if (null == code) {
             throw new BizException(BizExceptionCode.NULL_CODE);
         }

+ 2 - 0
applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/po/report/SalerecView.java

@@ -34,5 +34,7 @@ public class SalerecView {
 
     private String rb_remark;
 
+    private Double rbd_amount;
+
     private Integer companyid;
 }

+ 3 - 0
applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/ProdInOutService.java

@@ -7,6 +7,7 @@ import com.usoftchina.saas.commons.dto.BatchDealBaseDTO;
 import com.usoftchina.saas.commons.dto.DocBaseDTO;
 import com.usoftchina.saas.commons.dto.DocSavedDTO;
 import com.usoftchina.saas.commons.dto.ListReqDTO;
+import com.usoftchina.saas.commons.po.BillCodeSeq;
 import com.usoftchina.saas.page.PageRequest;
 
 import com.usoftchina.saas.sale.dto.ProdInOutFormDTO;
@@ -119,4 +120,6 @@ public interface ProdInOutService extends CommonBaseService<ProdInOutMapper, Pro
      * @param id
      */
     DocBaseDTO turnProdin(Long id);
+
+    String getMaxnumber(BillCodeSeq bill);
 }

+ 19 - 10
applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/impl/ProdInOutServiceImpl.java

@@ -99,8 +99,11 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         if(prodInOut.getPi_date() == null){
             prodInOut.setPi_date(new Date());
         }
+        baseDTO.setName(pi_class);
+        baseDTO.setId(pi_id);
+        baseDTO.setCode(pi_inoutno);
         //编号获取
-        pi_inoutno = pushMaxnubmer(prodInOut);
+        pi_inoutno = pushMaxnubmer(baseDTO);
         prodInOut.setPi_inoutno(pi_inoutno);
         prodInOut.setPi_class(main.getPi_class());
         prodInOut.setPi_said(main.getPi_said());
@@ -405,10 +408,10 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         //插入销售退货单主表
         ProdInOut targetPi = new ProdInOut();
         //生成单号
-        String piInoutno  =
-                maxnumberService.getMaxnumber(BillCodeSeq.SALEIN.getCaller(),true).getData();
+       /* String piInoutno  =
+                maxnumberService.getMaxnumber(BillCodeSeq.SALEIN.getCaller(),true).getData();*/
                // BillCodeSeq.SALEIN.getCaller()+Math.abs(Math.random()*100);
-
+        String piInoutno = getMaxnumber(BillCodeSeq.SALEIN);
         //设置公司id
         targetPi.setCompanyId(sourcePi.getCompanyId());
         targetPi.setCreateTime(new Date());
@@ -563,10 +566,10 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
      * @Author: guq
      * @Date: 2018/10/19
      */
-    private String pushMaxnubmer(ProdInOut prodInOut) {
-        String code = prodInOut.getPi_inoutno();
-        Long id = prodInOut.getId();
-        String pi_class = prodInOut.getPi_class();
+    private synchronized String pushMaxnubmer(DocBaseDTO baseDTO) {
+        String code = baseDTO.getCode();
+        Long id = baseDTO.getId();
+        String pi_class = baseDTO.getName();
         if (null == code) {
             throw new BizException(BizExceptionCode.NULL_CODE);
         }
@@ -578,8 +581,14 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         }else {//销售退货单
             caller = BillCodeSeq.SALEIN.getCaller();
         }
-        return //code;
-                maxnumberService.pushMaxnubmer(count, code, caller).getData();
+        return maxnumberService.pushMaxnubmer(count, code, caller).getData();
+    }
+
+    @Override
+    public String getMaxnumber(BillCodeSeq bill) {
+        String code = maxnumberService.getMaxnumber(bill.getCaller(), false).getData();
+        DocBaseDTO base = new DocBaseDTO(0l, code, bill.getName());
+        return pushMaxnubmer(base);
     }
 
     /**

+ 7 - 3
applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/impl/SaleServiceImpl.java

@@ -21,6 +21,7 @@ import com.usoftchina.saas.sale.mapper.*;
 import com.usoftchina.saas.sale.po.Sale;
 import com.usoftchina.saas.sale.po.SaleDetail;
 import com.usoftchina.saas.sale.po.SaleList;
+import com.usoftchina.saas.sale.service.ProdInOutService;
 import com.usoftchina.saas.sale.service.SaleService;
 import com.usoftchina.saas.storage.po.ProdIODetail;
 import com.usoftchina.saas.storage.po.ProdInOut;
@@ -53,6 +54,8 @@ public class SaleServiceImpl implements SaleService{
     private ProdInOutMapper prodInOutMapper;
     @Autowired
     private ProdIODetailMapper prodIODetailMapper;
+    @Autowired
+    private ProdInOutService prodInOutService;
 
     @Override
     public PageInfo<SaleList> getListData(PageRequest page, ListReqDTO req) {
@@ -429,8 +432,9 @@ public class SaleServiceImpl implements SaleService{
         //插入验收单主表
         ProdInOut prodInOut = new ProdInOut();
         //生成单号
-        String pi_inoutno = maxnumberService.getMaxnumber(BillCodeSeq.SALEOUT.getCaller(),
-                true).getData();
+       /* String pi_inoutno = maxnumberService.getMaxnumber(BillCodeSeq.SALEOUT.getCaller(),
+                true).getData();*/
+        String pi_inoutno = prodInOutService.getMaxnumber(BillCodeSeq.SALEOUT);
         prodInOut.setPi_inoutno(pi_inoutno);
         prodInOut.setPi_class(BillCodeSeq.SALEOUT.getName());
         prodInOut.setPi_date(new Date());
@@ -553,7 +557,7 @@ public class SaleServiceImpl implements SaleService{
      * @Author: guq
      * @Date: 2018/10/19
      */
-    private String pushMaxnubmer(String code, Long id) {
+    private synchronized String pushMaxnubmer(String code, Long id) {
         if (null == code) {
             throw new BizException(BizExceptionCode.NULL_CODE);
         }

+ 1 - 0
applications/sale/sale-server/src/main/resources/mapper/SalerecViewMapper.xml

@@ -15,6 +15,7 @@
     <result column="rb_backrate" property="rb_backrate" jdbcType="DOUBLE" />
     <result column="rb_remark" property="rb_remark" jdbcType="VARCHAR" />
     <result column="companyid" property="companyid" jdbcType="INTEGER" />
+    <result column="rbd_amount" property="rbd_amount" jdbcType="DOUBLE" />
   </resultMap>
   <select id="selectByCondition" resultMap="BaseResultMap">
     select  *  from Salerec_View

+ 1 - 0
applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/po/report/ProdiodetailView.java

@@ -13,6 +13,7 @@ import java.util.Date;
 public class ProdiodetailView implements Serializable{
 
     private String pi_inoutno;
+    private String pd_ordercode;
     private String pi_class;
     private String bizcode;
     private String bizname;

+ 3 - 2
applications/storage/storage-server/src/main/java/com/usoftchina/saas/storage/service/impl/ProdInOutServiceImpl.java

@@ -29,6 +29,7 @@ import com.usoftchina.saas.storage.service.ProdInOutService;
 import com.usoftchina.saas.utils.BeanMapper;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Propagation;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.StringUtils;
 
@@ -102,7 +103,7 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
     }
 
     @Override
-    @Transactional
+    @Transactional(propagation = Propagation.REQUIRED)
     public DocBaseDTO saveFormData(ProdInOutFormDTO formdata) {
         if (null == formdata || null == formdata.getMain()){
             throw new BizException(500, "数据为空,请填写后再保存");
@@ -217,7 +218,6 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
 
 
     @Override
-    @Transactional
     public DocBaseDTO audit(ProdInOutFormDTO formData) {
         Long id = null;
         DocBaseDTO baseDTO = new DocBaseDTO();
@@ -233,6 +233,7 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
         return baseDTO;
     }
 
+    @Transactional(propagation = Propagation.REQUIRED)
     private void singleAudit(ProdInOutDTO prodInOutDTO) {
         String pi_class= prodInOutDTO.getPi_class();
         String pi_inoutno = prodInOutDTO.getPi_inoutno();

+ 1 - 0
applications/storage/storage-server/src/main/resources/mapper/ProdInOutReportMapper.xml

@@ -4,6 +4,7 @@
 
   <resultMap id="ProdiodetailMap" type="com.usoftchina.saas.storage.po.report.ProdiodetailView">
     <result column="pi_inoutno" jdbcType="VARCHAR" property="pi_inoutno" />
+    <result column="pd_ordercode" jdbcType="VARCHAR" property="pd_ordercode" />
     <result column="pi_class" jdbcType="VARCHAR" property="pi_class" />
     <result column="bizcode" jdbcType="VARCHAR" property="bizcode" />
     <result column="bizname" jdbcType="VARCHAR" property="bizname" />

+ 1 - 1
base-servers/mail/mail-api/src/main/java/com/usoftchina/saas/mail/MailBuilder.java

@@ -185,7 +185,7 @@ public abstract class MailBuilder {
 
         @Override
         protected Result send(MailApi api) {
-            return api.sendTemplate(new TemplateMailMessage(templateId, to, cc, bcc, metadata));
+            return api.sendTemplate(new TemplateMailMessage(templateId, from, to, cc, bcc, metadata));
         }
     }
 }

+ 4 - 0
base-servers/mail/mail-server/pom.xml

@@ -56,6 +56,10 @@
             <groupId>org.freemarker</groupId>
             <artifactId>freemarker</artifactId>
         </dependency>
+        <dependency>
+            <groupId>net.logstash.logback</groupId>
+            <artifactId>logstash-logback-encoder</artifactId>
+        </dependency>
     </dependencies>
 
     <build>

+ 1 - 1
base-servers/mail/mail-server/src/main/java/com/usoftchina/saas/mail/MailApplication.java

@@ -14,7 +14,7 @@ import org.springframework.transaction.annotation.EnableTransactionManagement;
 @SpringBootApplication
 @EnableEurekaClient
 @EnableAuthClient
-@MapperScan
+@MapperScan("com.usoftchina.saas.mail.mapper")
 @EnableTransactionManagement
 public class MailApplication {
     public static void main(String[] args) {

+ 2 - 0
frontend/saas-web/app/view/core/form/FormPanel.js

@@ -198,6 +198,8 @@ Ext.define('saas.view.core.form.FormPanel', {
         viewModel.set(codeField, '');
         viewModel.set('createTime', Ext.Date.format(new Date(), 'Y-m-d H:i:s'));
         viewModel.set('updateTime', Ext.Date.format(new Date(), 'Y-m-d H:i:s'));
+        viewModel.set('creatorId', getCurrentUse().id);
+        viewModel.set('creator', getCurrentUse().realname);
 
         if (statusCodeField) {
             var o = {};

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

@@ -9,30 +9,30 @@ Ext.define('saas.view.document.customer.BasePanel', {
         xtype : "textfield", 
         name : "cu_code", 
         emptyText : "客户编号", 
-        columnWidth : 0.25,
+        width:90,
     },{
         xtype : "textfield", 
         name : "cu_name", 
         emptyText : "客户名称", 
-        columnWidth : 0.25
+        width:90,
     },{
         editable:false,
         hiddenBtn:true,
         xtype : "remotecombo", 
         storeUrl:'/api/document/customerkind/getCombo',
         name : "cu_type", 
-        emptyText : "请选择客户类型", 
-        columnWidth : 0.25
+        emptyText : "客户类型", 
+        width:120,
     },{
         xtype : "textfield", 
         name : "cu_sellername", 
         emptyText : "业务员", 
-        columnWidth : 0.25,
+        width:120,
     },{
         xtype : "textfield", 
         name : "cu_promisedays", 
         emptyText : "承付天数", 
-        columnWidth : 0.25,
+        width:120,
         getCondition: function(value) {
             if(value.indexOf("=")>=0||value.indexOf("<")>=0||value.indexOf(">")>=0){
                 return ' cu_promisedays ' + value;
@@ -46,7 +46,7 @@ Ext.define('saas.view.document.customer.BasePanel', {
         xtype : "textfield", 
         name : "cu_credit", 
         emptyText : "额度", 
-        columnWidth : 0.25,
+        width:70,
         dataIndex : "cu_credit",
         getCondition: function(value) {
             if(value.indexOf("=")>=0||value.indexOf("<")>=0||value.indexOf(">")>=0){
@@ -60,12 +60,12 @@ Ext.define('saas.view.document.customer.BasePanel', {
     },{
         xtype: 'combobox',
         name: 'cu_statuscode',
-        fieldLabel: '状态',
         queryMode: 'local',
         displayField: 'cu_status',
         valueField: 'cu_statuscode',
-        emptyText :'全部',
+        emptyText :'状态',
         editable:false,
+        width:100,
         store: Ext.create('Ext.data.ArrayStore', {
         fields: ['cu_statuscode', 'cu_status'],
         data: [

+ 2 - 2
frontend/saas-web/app/view/document/product/BasePanel.js

@@ -41,11 +41,11 @@ Ext.define('saas.view.document.product.BasePanel', {
     }, {
         xtype: 'combobox',
         name: 'pr_statuscode',
-        fieldLabel: '状态',
         queryMode: 'local',
         displayField: 'pr_status',
         valueField: 'pr_statuscode',
-        emptyText :'全部',
+        emptyText :'状态',
+        width:100,
         editable:false,
         store: Ext.create('Ext.data.ArrayStore', {
         fields: ['pr_statuscode', 'pr_status'],

+ 7 - 7
frontend/saas-web/app/view/document/vendor/BasePanel.js

@@ -8,24 +8,24 @@ Ext.define('saas.view.document.vendor.BasePanel', {
         xtype : "dbfindtrigger", 
         name : "ve_code", 
         emptyText : "供应商编号", 
-        columnWidth : 0.25,
+        width:140,
     },{
         xtype : "textfield", 
         name : "ve_name", 
         emptyText : "供应商名称", 
-        columnWidth : 0.25,
+        width:140,
     },{
         xtype : "remotecombo", 
         storeUrl:'/api/document/vendorkind/getCombo',
         name : "ve_type", 
-        emptyText : "请选择供应商类型", 
-        columnWidth : 0.25,
+        emptyText : "供应商类型", 
+        width:140,
         hiddenBtn:true
     },{
         xtype : "textfield", 
         name : "ve_promisedays", 
         emptyText : "承付天数", 
-        columnWidth : 0.25,
+        width:120,
         getCondition: function(value) {
             if(value.indexOf("=")>=0||value.indexOf("<")>=0||value.indexOf(">")>=0){
                 return ' ve_promisedays '+value;
@@ -38,11 +38,11 @@ Ext.define('saas.view.document.vendor.BasePanel', {
     },{
         xtype: 'combobox',
         name: 've_statuscode',
-        fieldLabel: '状态',
         queryMode: 'local',
         displayField: 've_status',
         valueField: 've_statuscode',
-        emptyText :'全部',
+        emptyText :'状态',
+        width:100,
         editable:false,
         store: Ext.create('Ext.data.ArrayStore', {
         fields: ['ve_statuscode', 've_status'],

+ 2 - 17
frontend/saas-web/app/view/main/Main.js

@@ -106,11 +106,10 @@ Ext.define('saas.view.main.Main', {
                     }
                 },
                 {
-                    margin: '0 0 0 0',
+                    //margin: '0 0 0 0',
                     xtype: 'tbtext',
                     cls:'nav-realname',
                     bind: {
-                        //tooltip: '{account.realname}',
                         html: '{account.realname}'
                     },
                     style:{
@@ -144,21 +143,7 @@ Ext.define('saas.view.main.Main', {
                             iconCls:'x-fa fa-power-off',
                             handler: 'onLogout'
                         }]
-                    } ,
-                     listeners:{
-                        'mouseover':function(btn){
-                            btn.menu ? (btn.menu.isVisible() ? '' : btn.showMenu()) : '';
-                        },
-                        'mouseout':function(btn,e){
-                            window.setTimeout(function(){
-                                var cx = e.browserEvent.clientX, cy = e.browserEvent.clientY;
-                                var btnLayout = btn.el.dom.getBoundingClientRect();
-                                if(cx <= btnLayout.left || cx >= btnLayout.left+btnLayout.width || cy <= btnLayout.top) {
-                                    btn.hideMenu();
-                                }
-                            }, 10); 
-                        }
-                    } 
+                    }
                 }
             ]
         },

+ 2 - 2
frontend/saas-web/app/view/stock/make/FormPanel.js

@@ -111,7 +111,7 @@ Ext.define('saas.view.stock.make.FormPanel', {
         fieldLabel : "单价",
         readOnly:true,
         editable:false,
-        decimals:8,
+        decimalPrecision:8,
         columnWidth: 0.25
     },{
         xtype : "numberfield", 
@@ -119,7 +119,7 @@ Ext.define('saas.view.stock.make.FormPanel', {
         readOnly:true,
         editable:false, 
         fieldLabel : "金额",
-        decimals:2,
+        decimalPrecision:2,
         columnWidth: 0.25
     },
     {

+ 4 - 0
frontend/saas-web/overrides/i18n.js

@@ -105,4 +105,8 @@ function deleteWarn(msg, fn){
  */
 function isDateString(str) {
     return (/^(\d{4})-(\d{1,2})-(\d{1,2}) (\d{1,2}):(\d{1,2}):(\d{1,2})$/).test(str);
+}
+
+function getCurrentUse() {
+    return Ext.getCmp('mainView').getViewModel().get('account');
 }