Эх сурвалжийг харах

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

zhoudw 7 жил өмнө
parent
commit
f76ccd1471
67 өөрчлөгдсөн 1977 нэмэгдсэн , 628 устгасан
  1. 227 0
      applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/Bankinformation.java
  2. 38 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/controller/BankinformationController.java
  3. 20 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/mapper/BankinformationMapper.java
  4. 15 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/service/BankinformationService.java
  5. 34 0
      applications/document/document-server/src/main/java/com/usoftchina/saas/document/service/impl/BankinformationServiceImpl.java
  6. 329 0
      applications/document/document-server/src/main/resources/mapper/BankinformationMapper.xml
  7. 58 13
      frontend/saas-web/Readme.md
  8. 1 1
      frontend/saas-web/app/model/document/product.js
  9. 11 0
      frontend/saas-web/app/model/money/RecBalance1.js
  10. 14 0
      frontend/saas-web/app/model/money/RecBalance2.js
  11. 2 2
      frontend/saas-web/app/model/purchase/prodIODetail.js
  12. 2 2
      frontend/saas-web/app/model/purchase/purchasedetail.js
  13. 39 0
      frontend/saas-web/app/model/sale/ProdIODetail.js
  14. 16 0
      frontend/saas-web/app/model/sale/Saledetail.js
  15. 39 0
      frontend/saas-web/app/model/stock/ProdIODetail.js
  16. 1 1
      frontend/saas-web/app/util/FormUtil.js
  17. 69 52
      frontend/saas-web/app/view/core/form/FormPanel.js
  18. 4 3
      frontend/saas-web/app/view/core/form/FormPanelController.js
  19. 1 3
      frontend/saas-web/app/view/core/form/field/DetailGridField.js
  20. 31 7
      frontend/saas-web/app/view/document/customer/panel/FormPanel.js
  21. 8 8
      frontend/saas-web/app/view/document/kind/Kind.js
  22. 4 4
      frontend/saas-web/app/view/document/kind/KindModel.js
  23. 3 3
      frontend/saas-web/app/view/document/vendor/FormPanel.js
  24. 11 17
      frontend/saas-web/app/view/money/payBalance/FormPanel.js
  25. 3 3
      frontend/saas-web/app/view/money/payBalance/FormPanelController.js
  26. 1 1
      frontend/saas-web/app/view/money/payBalance/FormPanelModel.js
  27. 1 1
      frontend/saas-web/app/view/money/payBalance/QueryPanel.js
  28. 2 2
      frontend/saas-web/app/view/money/payBalance/QueryPanelController.js
  29. 177 0
      frontend/saas-web/app/view/money/recBalance/FormPanel.js
  30. 158 0
      frontend/saas-web/app/view/money/recBalance/FormPanelController.js
  31. 5 0
      frontend/saas-web/app/view/money/recBalance/FormPanelModel.js
  32. 196 0
      frontend/saas-web/app/view/money/recBalance/QueryPanel.js
  33. 117 0
      frontend/saas-web/app/view/money/recBalance/QueryPanelController.js
  34. 5 0
      frontend/saas-web/app/view/money/recBalance/QueryPanelModel.js
  35. 2 2
      frontend/saas-web/app/view/purchase/purchase/FormPanel.js
  36. 1 2
      frontend/saas-web/app/view/purchase/purchase/QueryPanel.js
  37. 12 15
      frontend/saas-web/app/view/purchase/purchaseIn/FormPanel.js
  38. 13 11
      frontend/saas-web/app/view/purchase/purchaseIn/QueryPanel.js
  39. 1 0
      frontend/saas-web/app/view/purchase/purchaseOut/FormPanel.js
  40. 8 1
      frontend/saas-web/app/view/purchase/purchaseOut/QueryPanel.js
  41. 3 1
      frontend/saas-web/app/view/sale/sale/FormPanel.js
  42. 9 2
      frontend/saas-web/app/view/sale/sale/QueryPanel.js
  43. 47 92
      frontend/saas-web/app/view/sale/saleIn/FormPanel.js
  44. 2 20
      frontend/saas-web/app/view/sale/saleIn/FormPanelController.js
  45. 0 3
      frontend/saas-web/app/view/sale/saleIn/FormPanelModel.js
  46. 12 5
      frontend/saas-web/app/view/sale/saleIn/QueryPanel.js
  47. 13 5
      frontend/saas-web/app/view/sale/saleOut/FormPanel.js
  48. 20 1
      frontend/saas-web/app/view/sale/saleOut/FormPanelController.js
  49. 1 4
      frontend/saas-web/app/view/sale/saleOut/FormPanelModel.js
  50. 9 3
      frontend/saas-web/app/view/sale/saleOut/QueryPanel.js
  51. 14 27
      frontend/saas-web/app/view/stock/appropriationInOut/FormPanel.js
  52. 2 2
      frontend/saas-web/app/view/stock/appropriationInOut/FormPanelController.js
  53. 1 4
      frontend/saas-web/app/view/stock/appropriationInOut/FormPanelModel.js
  54. 16 16
      frontend/saas-web/app/view/stock/appropriationInOut/QueryPanel.js
  55. 2 2
      frontend/saas-web/app/view/stock/appropriationInOut/QueryPanelController.js
  56. 28 86
      frontend/saas-web/app/view/stock/otherIn/FormPanel.js
  57. 2 2
      frontend/saas-web/app/view/stock/otherIn/FormPanelController.js
  58. 0 4
      frontend/saas-web/app/view/stock/otherIn/FormPanelModel.js
  59. 77 95
      frontend/saas-web/app/view/stock/otherIn/QueryPanel.js
  60. 2 2
      frontend/saas-web/app/view/stock/otherIn/QueryPanelController.js
  61. 14 55
      frontend/saas-web/app/view/stock/otherOut/FormPanel.js
  62. 2 2
      frontend/saas-web/app/view/stock/otherOut/FormPanelController.js
  63. 6 25
      frontend/saas-web/app/view/stock/otherOut/QueryPanel.js
  64. 2 2
      frontend/saas-web/app/view/stock/otherOut/QueryPanelController.js
  65. 3 3
      frontend/saas-web/app/view/test/order/FormController.js
  66. 8 8
      frontend/saas-web/app/view/test/order/FormPanel.js
  67. 3 3
      frontend/saas-web/app/view/test/query/QueryPanel.js

+ 227 - 0
applications/document/document-dto/src/main/java/com/usoftchina/saas/document/entities/Bankinformation.java

@@ -0,0 +1,227 @@
+package com.usoftchina.saas.document.entities;
+
+import com.usoftchina.saas.base.entity.CommonBaseEntity;
+
+import java.util.Date;
+
+public class Bankinformation extends CommonBaseEntity {
+    private Integer bkId;
+
+    private String bkBankcode;
+
+    private String bkBankname;
+
+    private Date bkDate;
+
+    private String bkType;
+
+    private Double bkBeginamount;
+
+    private Double bkThisamount;
+
+    private String bkStatus;
+
+    private String bkStatuscode;
+
+    private Integer bkRecorderid;
+
+    private String bkRecorder;
+
+    private Date bkRecorddate;
+
+    private Integer bkYm;
+
+    private Integer companyid;
+
+    private Integer updaterid;
+
+    private Date updatetime;
+
+    private String bkText1;
+
+    private String bkText2;
+
+    private String bkText3;
+
+    private String bkText4;
+
+    private String bkText5;
+
+    private String bkRemark;
+
+    public Integer getBkId() {
+        return bkId;
+    }
+
+    public void setBkId(Integer bkId) {
+        this.bkId = bkId;
+    }
+
+    public String getBkBankcode() {
+        return bkBankcode;
+    }
+
+    public void setBkBankcode(String bkBankcode) {
+        this.bkBankcode = bkBankcode == null ? null : bkBankcode.trim();
+    }
+
+    public String getBkBankname() {
+        return bkBankname;
+    }
+
+    public void setBkBankname(String bkBankname) {
+        this.bkBankname = bkBankname == null ? null : bkBankname.trim();
+    }
+
+    public Date getBkDate() {
+        return bkDate;
+    }
+
+    public void setBkDate(Date bkDate) {
+        this.bkDate = bkDate;
+    }
+
+    public String getBkType() {
+        return bkType;
+    }
+
+    public void setBkType(String bkType) {
+        this.bkType = bkType == null ? null : bkType.trim();
+    }
+
+    public Double getBkBeginamount() {
+        return bkBeginamount;
+    }
+
+    public void setBkBeginamount(Double bkBeginamount) {
+        this.bkBeginamount = bkBeginamount;
+    }
+
+    public Double getBkThisamount() {
+        return bkThisamount;
+    }
+
+    public void setBkThisamount(Double bkThisamount) {
+        this.bkThisamount = bkThisamount;
+    }
+
+    public String getBkStatus() {
+        return bkStatus;
+    }
+
+    public void setBkStatus(String bkStatus) {
+        this.bkStatus = bkStatus == null ? null : bkStatus.trim();
+    }
+
+    public String getBkStatuscode() {
+        return bkStatuscode;
+    }
+
+    public void setBkStatuscode(String bkStatuscode) {
+        this.bkStatuscode = bkStatuscode == null ? null : bkStatuscode.trim();
+    }
+
+    public Integer getBkRecorderid() {
+        return bkRecorderid;
+    }
+
+    public void setBkRecorderid(Integer bkRecorderid) {
+        this.bkRecorderid = bkRecorderid;
+    }
+
+    public String getBkRecorder() {
+        return bkRecorder;
+    }
+
+    public void setBkRecorder(String bkRecorder) {
+        this.bkRecorder = bkRecorder == null ? null : bkRecorder.trim();
+    }
+
+    public Date getBkRecorddate() {
+        return bkRecorddate;
+    }
+
+    public void setBkRecorddate(Date bkRecorddate) {
+        this.bkRecorddate = bkRecorddate;
+    }
+
+    public Integer getBkYm() {
+        return bkYm;
+    }
+
+    public void setBkYm(Integer bkYm) {
+        this.bkYm = bkYm;
+    }
+
+    public Integer getCompanyid() {
+        return companyid;
+    }
+
+    public void setCompanyid(Integer companyid) {
+        this.companyid = companyid;
+    }
+
+    public Integer getUpdaterid() {
+        return updaterid;
+    }
+
+    public void setUpdaterid(Integer updaterid) {
+        this.updaterid = updaterid;
+    }
+
+    public Date getUpdatetime() {
+        return updatetime;
+    }
+
+    public void setUpdatetime(Date updatetime) {
+        this.updatetime = updatetime;
+    }
+
+    public String getBkText1() {
+        return bkText1;
+    }
+
+    public void setBkText1(String bkText1) {
+        this.bkText1 = bkText1 == null ? null : bkText1.trim();
+    }
+
+    public String getBkText2() {
+        return bkText2;
+    }
+
+    public void setBkText2(String bkText2) {
+        this.bkText2 = bkText2 == null ? null : bkText2.trim();
+    }
+
+    public String getBkText3() {
+        return bkText3;
+    }
+
+    public void setBkText3(String bkText3) {
+        this.bkText3 = bkText3 == null ? null : bkText3.trim();
+    }
+
+    public String getBkText4() {
+        return bkText4;
+    }
+
+    public void setBkText4(String bkText4) {
+        this.bkText4 = bkText4 == null ? null : bkText4.trim();
+    }
+
+    public String getBkText5() {
+        return bkText5;
+    }
+
+    public void setBkText5(String bkText5) {
+        this.bkText5 = bkText5 == null ? null : bkText5.trim();
+    }
+
+    public String getBkRemark() {
+        return bkRemark;
+    }
+
+    public void setBkRemark(String bkRemark) {
+        this.bkRemark = bkRemark == null ? null : bkRemark.trim();
+    }
+}

+ 38 - 0
applications/document/document-server/src/main/java/com/usoftchina/saas/document/controller/BankinformationController.java

@@ -0,0 +1,38 @@
+package com.usoftchina.saas.document.controller;
+
+import com.usoftchina.saas.base.Result;
+import com.usoftchina.saas.document.entities.Bankinformation;
+import com.usoftchina.saas.document.service.BankinformationService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+/**
+ * @author heqw
+ * @date 2018/10/25 15:33
+ **/
+@RestController
+@RequestMapping("/Bankinformation")
+public class BankinformationController {
+    @Autowired
+    BankinformationService bankinformationService;
+
+    @PostMapping("/save")
+    public Result save(@RequestBody Bankinformation bankinformation){
+        bankinformationService.save(bankinformation);
+        return Result.success();
+    }
+
+    @PostMapping("/delete/{id}")
+    public Result delete(@PathVariable("id") int id){
+        bankinformationService.removeByPrimaryKey(id);
+        return Result.success();
+    }
+
+    @GetMapping("/getAll")
+    public Result getAll(){
+        List<Bankinformation> bankinformationList = bankinformationService.findAll();
+        return Result.success(bankinformationList);
+    }
+}

+ 20 - 0
applications/document/document-server/src/main/java/com/usoftchina/saas/document/mapper/BankinformationMapper.java

@@ -0,0 +1,20 @@
+package com.usoftchina.saas.document.mapper;
+
+import com.usoftchina.saas.base.mapper.CommonBaseMapper;
+import com.usoftchina.saas.document.entities.Bankinformation;
+
+public interface BankinformationMapper extends CommonBaseMapper<Bankinformation> {
+    int deleteByPrimaryKey(Integer bkId);
+
+    int insert(Bankinformation record);
+
+    int insertSelective(Bankinformation record);
+
+    Bankinformation selectByPrimaryKey(Integer bkId);
+
+    int updateByPrimaryKeySelective(Bankinformation record);
+
+    int updateByPrimaryKeyWithBLOBs(Bankinformation record);
+
+    int updateByPrimaryKey(Bankinformation record);
+}

+ 15 - 0
applications/document/document-server/src/main/java/com/usoftchina/saas/document/service/BankinformationService.java

@@ -0,0 +1,15 @@
+package com.usoftchina.saas.document.service;
+
+import com.usoftchina.saas.base.service.CommonBaseService;
+import com.usoftchina.saas.document.entities.Bankinformation;
+import com.usoftchina.saas.document.mapper.BankinformationMapper;
+
+/**
+ * @author heqw
+ * @date 2018/10/25 15:36
+ **/
+public interface BankinformationService extends CommonBaseService<BankinformationMapper, Bankinformation> {
+    boolean save(Bankinformation bankinformation);
+
+    boolean removeByPrimaryKey(int id);
+}

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

@@ -0,0 +1,34 @@
+package com.usoftchina.saas.document.service.impl;
+
+import com.usoftchina.saas.base.service.CommonBaseServiceImpl;
+import com.usoftchina.saas.document.entities.Bankinformation;
+import com.usoftchina.saas.document.mapper.BankinformationMapper;
+import com.usoftchina.saas.document.service.BankinformationService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+/**
+ * @author heqw
+ * @date 2018/10/25 15:36
+ **/
+@Service
+public class BankinformationServiceImpl extends CommonBaseServiceImpl<BankinformationMapper, Bankinformation> implements BankinformationService {
+    @Autowired
+    private BankinformationMapper bankinformationMapper;
+
+    @Override
+    public boolean save(Bankinformation bankinformation){
+        if(bankinformation.getBkId() == 0){
+            bankinformationMapper.insertSelective(bankinformation);
+        }else{
+            bankinformationMapper.updateByPrimaryKeySelective(bankinformation);
+        }
+        return true;
+    }
+
+    @Override
+    public boolean removeByPrimaryKey(int id){
+        bankinformationMapper.deleteByPrimaryKey(id);
+        return true;
+    }
+}

+ 329 - 0
applications/document/document-server/src/main/resources/mapper/BankinformationMapper.xml

@@ -0,0 +1,329 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
+<mapper namespace="com.usoftchina.saas.document.mapper.BankinformationMapper" >
+  <resultMap id="BaseResultMap" type="com.usoftchina.saas.document.po.Bankinformation" >
+    <id column="bk_id" property="bkId" jdbcType="INTEGER" />
+    <result column="bk_bankcode" property="bkBankcode" jdbcType="VARCHAR" />
+    <result column="bk_bankname" property="bkBankname" jdbcType="VARCHAR" />
+    <result column="bk_date" property="bkDate" jdbcType="TIMESTAMP" />
+    <result column="bk_type" property="bkType" jdbcType="VARCHAR" />
+    <result column="bk_beginamount" property="bkBeginamount" jdbcType="DOUBLE" />
+    <result column="bk_thisamount" property="bkThisamount" jdbcType="DOUBLE" />
+    <result column="bk_status" property="bkStatus" jdbcType="VARCHAR" />
+    <result column="bk_statuscode" property="bkStatuscode" jdbcType="VARCHAR" />
+    <result column="bk_recorderid" property="bkRecorderid" jdbcType="INTEGER" />
+    <result column="bk_recorder" property="bkRecorder" jdbcType="VARCHAR" />
+    <result column="bk_recorddate" property="bkRecorddate" jdbcType="TIMESTAMP" />
+    <result column="bk_ym" property="bkYm" jdbcType="INTEGER" />
+    <result column="companyid" property="companyid" jdbcType="INTEGER" />
+    <result column="updaterid" property="updaterid" jdbcType="INTEGER" />
+    <result column="updatetime" property="updatetime" jdbcType="TIMESTAMP" />
+    <result column="bk_text1" property="bkText1" jdbcType="VARCHAR" />
+    <result column="bk_text2" property="bkText2" jdbcType="VARCHAR" />
+    <result column="bk_text3" property="bkText3" jdbcType="VARCHAR" />
+    <result column="bk_text4" property="bkText4" jdbcType="VARCHAR" />
+    <result column="bk_text5" property="bkText5" jdbcType="VARCHAR" />
+  </resultMap>
+  <resultMap id="ResultMapWithBLOBs" type="com.usoftchina.saas.document.po.Bankinformation" extends="BaseResultMap" >
+    <result column="bk_remark" property="bkRemark" jdbcType="LONGVARCHAR" />
+  </resultMap>
+  <sql id="Base_Column_List" >
+    bk_id, bk_bankcode, bk_bankname, bk_date, bk_type, bk_beginamount, bk_thisamount, 
+    bk_status, bk_statuscode, bk_recorderid, bk_recorder, bk_recorddate, bk_ym, companyid, 
+    updaterid, updatetime, bk_text1, bk_text2, bk_text3, bk_text4, bk_text5
+  </sql>
+  <sql id="Blob_Column_List" >
+    bk_remark
+  </sql>
+  <select id="selectByPrimaryKey" resultMap="ResultMapWithBLOBs" parameterType="java.lang.Integer" >
+    select 
+    <include refid="Base_Column_List" />
+    ,
+    <include refid="Blob_Column_List" />
+    from bankinformation
+    where bk_id = #{bkId,jdbcType=INTEGER}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
+    delete from bankinformation
+    where bk_id = #{bkId,jdbcType=INTEGER}
+  </delete>
+  <insert id="insert" parameterType="com.usoftchina.saas.document.po.Bankinformation" >
+    insert into bankinformation (bk_id, bk_bankcode, bk_bankname, 
+      bk_date, bk_type, bk_beginamount, 
+      bk_thisamount, bk_status, bk_statuscode, 
+      bk_recorderid, bk_recorder, bk_recorddate, 
+      bk_ym, companyid, updaterid, 
+      updatetime, bk_text1, bk_text2, 
+      bk_text3, bk_text4, bk_text5, 
+      bk_remark)
+    values (#{bkId,jdbcType=INTEGER}, #{bkBankcode,jdbcType=VARCHAR}, #{bkBankname,jdbcType=VARCHAR}, 
+      #{bkDate,jdbcType=TIMESTAMP}, #{bkType,jdbcType=VARCHAR}, #{bkBeginamount,jdbcType=DOUBLE}, 
+      #{bkThisamount,jdbcType=DOUBLE}, #{bkStatus,jdbcType=VARCHAR}, #{bkStatuscode,jdbcType=VARCHAR}, 
+      #{bkRecorderid,jdbcType=INTEGER}, #{bkRecorder,jdbcType=VARCHAR}, #{bkRecorddate,jdbcType=TIMESTAMP}, 
+      #{bkYm,jdbcType=INTEGER}, #{companyid,jdbcType=INTEGER}, #{updaterid,jdbcType=INTEGER}, 
+      #{updatetime,jdbcType=TIMESTAMP}, #{bkText1,jdbcType=VARCHAR}, #{bkText2,jdbcType=VARCHAR}, 
+      #{bkText3,jdbcType=VARCHAR}, #{bkText4,jdbcType=VARCHAR}, #{bkText5,jdbcType=VARCHAR}, 
+      #{bkRemark,jdbcType=LONGVARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.usoftchina.saas.document.po.Bankinformation" >
+    insert into bankinformation
+    <trim prefix="(" suffix=")" suffixOverrides="," >
+      <if test="bkId != null" >
+        bk_id,
+      </if>
+      <if test="bkBankcode != null" >
+        bk_bankcode,
+      </if>
+      <if test="bkBankname != null" >
+        bk_bankname,
+      </if>
+      <if test="bkDate != null" >
+        bk_date,
+      </if>
+      <if test="bkType != null" >
+        bk_type,
+      </if>
+      <if test="bkBeginamount != null" >
+        bk_beginamount,
+      </if>
+      <if test="bkThisamount != null" >
+        bk_thisamount,
+      </if>
+      <if test="bkStatus != null" >
+        bk_status,
+      </if>
+      <if test="bkStatuscode != null" >
+        bk_statuscode,
+      </if>
+      <if test="bkRecorderid != null" >
+        bk_recorderid,
+      </if>
+      <if test="bkRecorder != null" >
+        bk_recorder,
+      </if>
+      <if test="bkRecorddate != null" >
+        bk_recorddate,
+      </if>
+      <if test="bkYm != null" >
+        bk_ym,
+      </if>
+      <if test="companyid != null" >
+        companyid,
+      </if>
+      <if test="updaterid != null" >
+        updaterid,
+      </if>
+      <if test="updatetime != null" >
+        updatetime,
+      </if>
+      <if test="bkText1 != null" >
+        bk_text1,
+      </if>
+      <if test="bkText2 != null" >
+        bk_text2,
+      </if>
+      <if test="bkText3 != null" >
+        bk_text3,
+      </if>
+      <if test="bkText4 != null" >
+        bk_text4,
+      </if>
+      <if test="bkText5 != null" >
+        bk_text5,
+      </if>
+      <if test="bkRemark != null" >
+        bk_remark,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides="," >
+      <if test="bkId != null" >
+        #{bkId,jdbcType=INTEGER},
+      </if>
+      <if test="bkBankcode != null" >
+        #{bkBankcode,jdbcType=VARCHAR},
+      </if>
+      <if test="bkBankname != null" >
+        #{bkBankname,jdbcType=VARCHAR},
+      </if>
+      <if test="bkDate != null" >
+        #{bkDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="bkType != null" >
+        #{bkType,jdbcType=VARCHAR},
+      </if>
+      <if test="bkBeginamount != null" >
+        #{bkBeginamount,jdbcType=DOUBLE},
+      </if>
+      <if test="bkThisamount != null" >
+        #{bkThisamount,jdbcType=DOUBLE},
+      </if>
+      <if test="bkStatus != null" >
+        #{bkStatus,jdbcType=VARCHAR},
+      </if>
+      <if test="bkStatuscode != null" >
+        #{bkStatuscode,jdbcType=VARCHAR},
+      </if>
+      <if test="bkRecorderid != null" >
+        #{bkRecorderid,jdbcType=INTEGER},
+      </if>
+      <if test="bkRecorder != null" >
+        #{bkRecorder,jdbcType=VARCHAR},
+      </if>
+      <if test="bkRecorddate != null" >
+        #{bkRecorddate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="bkYm != null" >
+        #{bkYm,jdbcType=INTEGER},
+      </if>
+      <if test="companyid != null" >
+        #{companyid,jdbcType=INTEGER},
+      </if>
+      <if test="updaterid != null" >
+        #{updaterid,jdbcType=INTEGER},
+      </if>
+      <if test="updatetime != null" >
+        #{updatetime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="bkText1 != null" >
+        #{bkText1,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText2 != null" >
+        #{bkText2,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText3 != null" >
+        #{bkText3,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText4 != null" >
+        #{bkText4,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText5 != null" >
+        #{bkText5,jdbcType=VARCHAR},
+      </if>
+      <if test="bkRemark != null" >
+        #{bkRemark,jdbcType=LONGVARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKeySelective" parameterType="com.usoftchina.saas.document.po.Bankinformation" >
+    update bankinformation
+    <set >
+      <if test="bkBankcode != null" >
+        bk_bankcode = #{bkBankcode,jdbcType=VARCHAR},
+      </if>
+      <if test="bkBankname != null" >
+        bk_bankname = #{bkBankname,jdbcType=VARCHAR},
+      </if>
+      <if test="bkDate != null" >
+        bk_date = #{bkDate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="bkType != null" >
+        bk_type = #{bkType,jdbcType=VARCHAR},
+      </if>
+      <if test="bkBeginamount != null" >
+        bk_beginamount = #{bkBeginamount,jdbcType=DOUBLE},
+      </if>
+      <if test="bkThisamount != null" >
+        bk_thisamount = #{bkThisamount,jdbcType=DOUBLE},
+      </if>
+      <if test="bkStatus != null" >
+        bk_status = #{bkStatus,jdbcType=VARCHAR},
+      </if>
+      <if test="bkStatuscode != null" >
+        bk_statuscode = #{bkStatuscode,jdbcType=VARCHAR},
+      </if>
+      <if test="bkRecorderid != null" >
+        bk_recorderid = #{bkRecorderid,jdbcType=INTEGER},
+      </if>
+      <if test="bkRecorder != null" >
+        bk_recorder = #{bkRecorder,jdbcType=VARCHAR},
+      </if>
+      <if test="bkRecorddate != null" >
+        bk_recorddate = #{bkRecorddate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="bkYm != null" >
+        bk_ym = #{bkYm,jdbcType=INTEGER},
+      </if>
+      <if test="companyid != null" >
+        companyid = #{companyid,jdbcType=INTEGER},
+      </if>
+      <if test="updaterid != null" >
+        updaterid = #{updaterid,jdbcType=INTEGER},
+      </if>
+      <if test="updatetime != null" >
+        updatetime = #{updatetime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="bkText1 != null" >
+        bk_text1 = #{bkText1,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText2 != null" >
+        bk_text2 = #{bkText2,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText3 != null" >
+        bk_text3 = #{bkText3,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText4 != null" >
+        bk_text4 = #{bkText4,jdbcType=VARCHAR},
+      </if>
+      <if test="bkText5 != null" >
+        bk_text5 = #{bkText5,jdbcType=VARCHAR},
+      </if>
+      <if test="bkRemark != null" >
+        bk_remark = #{bkRemark,jdbcType=LONGVARCHAR},
+      </if>
+    </set>
+    where bk_id = #{bkId,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKeyWithBLOBs" parameterType="com.usoftchina.saas.document.po.Bankinformation" >
+    update bankinformation
+    set bk_bankcode = #{bkBankcode,jdbcType=VARCHAR},
+      bk_bankname = #{bkBankname,jdbcType=VARCHAR},
+      bk_date = #{bkDate,jdbcType=TIMESTAMP},
+      bk_type = #{bkType,jdbcType=VARCHAR},
+      bk_beginamount = #{bkBeginamount,jdbcType=DOUBLE},
+      bk_thisamount = #{bkThisamount,jdbcType=DOUBLE},
+      bk_status = #{bkStatus,jdbcType=VARCHAR},
+      bk_statuscode = #{bkStatuscode,jdbcType=VARCHAR},
+      bk_recorderid = #{bkRecorderid,jdbcType=INTEGER},
+      bk_recorder = #{bkRecorder,jdbcType=VARCHAR},
+      bk_recorddate = #{bkRecorddate,jdbcType=TIMESTAMP},
+      bk_ym = #{bkYm,jdbcType=INTEGER},
+      companyid = #{companyid,jdbcType=INTEGER},
+      updaterid = #{updaterid,jdbcType=INTEGER},
+      updatetime = #{updatetime,jdbcType=TIMESTAMP},
+      bk_text1 = #{bkText1,jdbcType=VARCHAR},
+      bk_text2 = #{bkText2,jdbcType=VARCHAR},
+      bk_text3 = #{bkText3,jdbcType=VARCHAR},
+      bk_text4 = #{bkText4,jdbcType=VARCHAR},
+      bk_text5 = #{bkText5,jdbcType=VARCHAR},
+      bk_remark = #{bkRemark,jdbcType=LONGVARCHAR}
+    where bk_id = #{bkId,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.usoftchina.saas.document.po.Bankinformation" >
+    update bankinformation
+    set bk_bankcode = #{bkBankcode,jdbcType=VARCHAR},
+      bk_bankname = #{bkBankname,jdbcType=VARCHAR},
+      bk_date = #{bkDate,jdbcType=TIMESTAMP},
+      bk_type = #{bkType,jdbcType=VARCHAR},
+      bk_beginamount = #{bkBeginamount,jdbcType=DOUBLE},
+      bk_thisamount = #{bkThisamount,jdbcType=DOUBLE},
+      bk_status = #{bkStatus,jdbcType=VARCHAR},
+      bk_statuscode = #{bkStatuscode,jdbcType=VARCHAR},
+      bk_recorderid = #{bkRecorderid,jdbcType=INTEGER},
+      bk_recorder = #{bkRecorder,jdbcType=VARCHAR},
+      bk_recorddate = #{bkRecorddate,jdbcType=TIMESTAMP},
+      bk_ym = #{bkYm,jdbcType=INTEGER},
+      companyid = #{companyid,jdbcType=INTEGER},
+      updaterid = #{updaterid,jdbcType=INTEGER},
+      updatetime = #{updatetime,jdbcType=TIMESTAMP},
+      bk_text1 = #{bkText1,jdbcType=VARCHAR},
+      bk_text2 = #{bkText2,jdbcType=VARCHAR},
+      bk_text3 = #{bkText3,jdbcType=VARCHAR},
+      bk_text4 = #{bkText4,jdbcType=VARCHAR},
+      bk_text5 = #{bkText5,jdbcType=VARCHAR}
+    where bk_id = #{bkId,jdbcType=INTEGER}
+  </update>
+
+  <select id="selectAll" resultMap="BaseResultMap">
+    SELECT * FROM bankinformation
+  </select>
+</mapper>

+ 58 - 13
frontend/saas-web/Readme.md

@@ -1,11 +1,11 @@
 # 精简SaaS前端界面配置说明
 ## 导航栏配置
 
-- 配置文件:
+#### 配置文件
 ```
 resources/json/navigation.json
 ```
-- 格式样例:
+#### 格式样例:
 ```json
 [{
     "text": "采购",
@@ -27,7 +27,7 @@ resources/json/navigation.json
     }]
 }]
 ```
-- 字段说明
+#### 字段说明
 ```
 text: 一级菜单项名称
 iconCls: 一级菜单项图标
@@ -42,23 +42,25 @@ items[i].items[i].addType: 可选设置,添加“新增”按钮,点击进
 ```
 
 ## 主从表配置
-- 基础主从表组件
+#### 基础主从表组件
 ```
 view: view.core.form.FormPanel
 controller: view.core.form.FormPanelController
 viewModel: view.core.form.FormPanelModel
 ```
-自定义的主从表view、controller、viewModel需要继承自以上基础组件。
+- 自定义的主从表view、controller、viewModel需要继承自以上基础组件。
 
-- 配置字段说明
+
+#### 配置字段说明
 
 | 字段名 | 说明 | 必填 | 样例 |
 | --- | --- | --- | --- |
 | extend | 继承,默认继承基础主从表 | √ | "saas.view.core.form.FormPanel" |
-| xtype | 格式为'-'连接的该文件全小写路径 | √ | "purchase-purchase-formpanel" |
+| xtype | 文件路径,使用'-'连接,全小写 | √ | "purchase-purchase-formpanel" |
 | controller | 控制层,可定义自定义的方法等。命名与xtype一致 | x | "purchase-purchase-formpanel" |
 | viewModel | Model层,可定义数据绑定关系等。命名与xtype一致 | x | "purchase-purchase-formpanel" |
 | viewName | 用于获取界面自定义配置 | x | "purchase-purchase-formpanel" |
+| caller | 用于获取单据编号 | √ | "Purchase" |
 | addTitle | 新增时打开的页面标题 | √ | "采购单" |
 | idField | id字段 | √ | "id" |
 | codeField | 编号字段 | √ | "pu_code" |
@@ -70,11 +72,11 @@ viewModel: view.core.form.FormPanelModel
 | deleteUrl | 删除接口 | √ | basePath + "purchase/purchase/delete" |
 | deleteDetailUrl | 删除明细接口 | √ | basePath + "purchase/purchase/deleteItem" |
 | toolBtns | 自定义按钮 | x | [ Button ] |
-| defaultItems | 界面字段 | √ | [ Fields ]|
+| defaultItems | 界面字段 | √ | [ Field ]|
 
-主表字段配置说明
+##### 主表字段配置说明
 
-_包括部分原有配置和主从表专属配置_
+包括部分原有配置和主从表专属配置,不包括detailGridField
 
 | 字段 | 说明 | 必填 | 样例 |
 | --- | --- | --- | --- |
@@ -82,7 +84,7 @@ _包括部分原有配置和主从表专属配置_
 | ignore | 是否忽略,为真时getFormData方法不会得到该字段值 | x | true |
 | defaultValue | 默认值 | x | "1001" |
 
-从表配置说明
+##### 从表配置说明
 
 从表被定义为一个formfield(_xtype=detailGridField_),可以与其他字段一同放到主从表的items中。
 
@@ -92,11 +94,54 @@ _包括部分原有配置和主从表专属配置_
 | detnoColumn | 序号列 | √ | "pud_detno" |
 | columns[i].ignore | 是否忽略,为真时在调用保存方法时不会取到该列值 | x | true |
 
+- 需要根据columns在models文件夹下添加storeModel对应的Model
+
+---
 
 ## 查询列表配置
-- 基础组件
+#### 基础查询列表组件
 ```
 view: view.core.query.QueryPanel
 controller: view.core.query.QuertPanelController
 viewModel: view.core.query.QueryPanelModel
-```
+```
+#### view配置字段说明
+
+| 字段 | 说明 | 必填 | 样例 |
+| --- | --- | --- | --- |
+| extend | 一般需要继承基础查询列表组件 | √ | "saas.view.core.query.QueryPanel" |
+| xtype | 文件路径,使用'-'连接,全小写 | √ | "purchase-purchase-querypanel" |
+| controller | 控制层,可定义自定义的方法等。命名与xtype一致 | x | "purchase-purchase-querypanel" |
+| viewModel | Model层,可定义数据绑定关系等。命名与xtype一致 | x | "purchase-purchase-querypanel" |
+| viewName | 用于获取界面自定义配置 | x | "purchase-purchase-querypanel" |
+| queryFormItems | 查询字段 | √ | 参看[查询字段配置说明](#cxzd) |
+| moreQueryFormItems | 更多查询字段 | x | 参看[查询字段配置说明](cxzd) |
+| queryGridConfig | 查询列表配置 | √ | 参看[列表配置说明](#) |
+
+查询字段配置说明
+
+
+| 字段 | 说明 | 必填 | 样例 |
+| --- | --- | --- | --- |
+| xtype | 字段类型 | √ | "textfield" |
+| name | 字段绑定名 | √ | "pu_vendname" |
+| fieldLabel | 字段名| x | "供应商名称" |
+| fieldType | 字段类型,默认根据xtype自动创建,可以指定["string", "date", "number", "enum"] | x | "string" |
+| operation | 字段条件连接符,默认根据xtype自动创建 | x | "between" |
+| getCondition | 自定义条件规则,定义后将使用该方法生成条件,传入参数为字段value,返回sql条件 | x | function(value) { return "pu_vendname like'" + value + "'" } |
+| showDetail | 当该值为true时,该字段生成条件后查询结果将以关联列表展示 | x | true |
+| isShowDetail | 自定义需要按照关联列表显示的条件,传入参数为字段value,返回Boolean,默认返回!!value | x | function(value) {return !!value;} |
+
+列表配置说明
+
+| 字段 | 说明 | 必填 | 样例 |
+| --- | --- | --- | --- |
+| idField | id字段 | √ | "pu_id" |
+| codeField | code字段 | √ | "pu_code" |
+| addTitle | 单据名称,新增tab标题 | √ | "采购单" |
+| addXtype | 主从表单据xtype | √ | "purchase-purchase-formpanel" |
+| defaultCondition | 默认条件 | x | "pu_class='采购单'" |
+| baseVastUrl | 查询列表接口 | √ | basePath + "purchase/purchase/" |
+| baseColumn | 基础列配置 | √ | [ Column ] |
+| relativeColumn | 关联列设置 | x | [ Column ] |
+

+ 1 - 1
frontend/saas-web/app/model/document/product.js

@@ -1,4 +1,4 @@
-Ext.define('saas.model.document.product', {
+Ext.define('saas.model.document.Product', {
     extend: 'saas.model.Base',
     fields: [
         { name: 'pr_detail', type: 'string' },

+ 11 - 0
frontend/saas-web/app/model/money/RecBalance1.js

@@ -0,0 +1,11 @@
+Ext.define('saas.model.money.RecBalance1', {
+    extend: 'saas.model.Base',
+    fields: [
+        { name: 'rd_detno', type: 'number' },
+        { name: 'rd_bankname', type: 'string' },
+        { name: 'rd_amount', type: 'number' },
+        { name: 'rd_paymethod', type: 'string' },
+        { name: 'rd_paycode', type: 'string' },
+        { name: 'rd_remark', type: 'string' }
+    ]
+});

+ 14 - 0
frontend/saas-web/app/model/money/RecBalance2.js

@@ -0,0 +1,14 @@
+Ext.define('saas.model.money.RecBalance2', {
+    extend: 'saas.model.Base',
+    fields: [
+        { name: 'rbd_detno', type: 'number' },
+        { name: 'rbd_slcode', type: 'string' },
+        { name: 'rbd_slkind', type: 'string' },
+        { name: 'rbd_sldate', type: 'date' },
+        { name: 'rbd_amount', type: 'number' },
+        { name: 'rbd_remark', type: 'number' },
+        { name: 'pbd_nowbalance', type: 'number' },
+        { name: 'pbd_nowbalance', type: 'number' },
+        { name: 'pbd_nowbalance', type: 'number' }
+    ]
+});

+ 2 - 2
frontend/saas-web/app/model/purchase/prodIODetail.js

@@ -1,4 +1,4 @@
-Ext.define('saas.model.purchase.prodIODetail', {
+Ext.define('saas.model.purchase.ProdIODetail', {
     extend: 'saas.model.Base',
 
     fields: [
@@ -37,5 +37,5 @@ Ext.define('saas.model.purchase.prodIODetail', {
         { name: 'pd_ioid', type: 'int' },
     ],
     //一对一映射
-    associations: [{ type: 'hasOne', model: 'saas.model.document.product', associationKey: 'product'}]
+    associations: [{ type: 'hasOne', model: 'saas.model.document.Product', associationKey: 'product'}]
 });

+ 2 - 2
frontend/saas-web/app/model/purchase/purchasedetail.js

@@ -1,4 +1,4 @@
-Ext.define('saas.model.purchase.purchasedetail', {
+Ext.define('saas.model.purchase.Purchasedetail', {
     extend: 'saas.model.Base',
 
     fields: [
@@ -14,5 +14,5 @@ Ext.define('saas.model.purchase.purchasedetail', {
         { name: 'pd_taxtotal', type: 'float' }
     ],
     //一对一映射
-    associations: [{ type: 'hasOne', model: 'saas.model.document.product', associationKey: 'product'}]
+    associations: [{ type: 'hasOne', model: 'saas.model.document.Product', associationKey: 'product'}]
 });

+ 39 - 0
frontend/saas-web/app/model/sale/ProdIODetail.js

@@ -0,0 +1,39 @@
+Ext.define('saas.model.sale.ProdIODetail', {
+    extend: 'saas.model.Base',
+
+    fields: [
+
+        { name: 'id', type: 'int' },
+        { name: 'pd_piid', type: 'int' },
+        { name: 'pd_inoutno', type: 'string' },
+        { name: 'pd_piclass', type: 'string' },
+        { name: 'pd_pdno', type: 'int' },
+        { name: 'pd_ordercode', type: 'string' },
+        { name: 'pd_orderdetno', type: 'int' },
+        { name: 'pd_prodid', type: 'int' },
+        { name: 'pd_prodcode', type: 'string' },
+        { name: 'pd_unit', type: 'string' },
+        { name: 'pd_inqty', type: 'int' },
+        { name: 'pd_outqty', type: 'int' },
+        { name: 'pd_orderprice', type: 'float' },
+        { name: 'pd_sendprice', type: 'float' },
+        { name: 'pd_price', type: 'float' },
+        { name: 'pd_total', type: 'float' },
+        { name: 'pd_taxrate', type: 'float' },
+        { name: 'pd_netprice', type: 'float' },
+        { name: 'pd_nettotal', type: 'float' },
+        { name: 'pd_whid', type: 'int' },
+        { name: 'pd_whcode', type: 'string' },
+        { name: 'pd_whname', type: 'string' },
+        { name: 'pd_inwhid', type: 'int' },
+        { name: 'pd_inwhcode', type: 'string' },
+        { name: 'pd_inwhname', type: 'string' },
+        { name: 'pd_orderid', type: 'int' },
+        { name: 'pd_sdid', type: 'int' },
+        { name: 'pd_status', type: 'string' },
+        { name: 'pd_ym', type: 'int' },
+        { name: 'pd_yqty', type: 'int' },
+        { name: 'pd_remark', type: 'string' },
+        { name: 'pd_ioid', type: 'int' },
+    ]
+});

+ 16 - 0
frontend/saas-web/app/model/sale/Saledetail.js

@@ -0,0 +1,16 @@
+Ext.define('saas.model.sale.Saledetail', {
+    extend: 'saas.model.Base',
+
+    fields: [
+        { name: 'sd_detno', type: 'int' },
+        { name: 'id', type: 'int' },
+        { name: 'sd_prodcode', type: 'string' },
+        { name: 'sd_qty', type: 'int' },
+        { name: 'sd_yqty', type: 'int' },
+        { name: 'sd_price', type: 'float' },
+        { name: 'sd_taxrate', type: 'float' },
+        { name: 'sd_total', type: 'float' },
+        { name: 'sd_delivery', type: 'date' },
+        { name: 'sd_taxtotal', type: 'float' }
+    ]
+});

+ 39 - 0
frontend/saas-web/app/model/stock/ProdIODetail.js

@@ -0,0 +1,39 @@
+Ext.define('saas.model.stock.ProdIODetail', {
+    extend: 'saas.model.Base',
+
+    fields: [
+
+        { name: 'id', type: 'int' },
+        { name: 'pd_piid', type: 'int' },
+        { name: 'pd_inoutno', type: 'string' },
+        { name: 'pd_piclass', type: 'string' },
+        { name: 'pd_pdno', type: 'int' },
+        { name: 'pd_ordercode', type: 'string' },
+        { name: 'pd_orderdetno', type: 'int' },
+        { name: 'pd_prodid', type: 'int' },
+        { name: 'pd_prodcode', type: 'string' },
+        { name: 'pd_unit', type: 'string' },
+        { name: 'pd_inqty', type: 'int' },
+        { name: 'pd_outqty', type: 'int' },
+        { name: 'pd_orderprice', type: 'float' },
+        { name: 'pd_sendprice', type: 'float' },
+        { name: 'pd_price', type: 'float' },
+        { name: 'pd_total', type: 'float' },
+        { name: 'pd_taxrate', type: 'float' },
+        { name: 'pd_netprice', type: 'float' },
+        { name: 'pd_nettotal', type: 'float' },
+        { name: 'pd_whid', type: 'int' },
+        { name: 'pd_whcode', type: 'string' },
+        { name: 'pd_whname', type: 'string' },
+        { name: 'pd_inwhid', type: 'int' },
+        { name: 'pd_inwhcode', type: 'string' },
+        { name: 'pd_inwhname', type: 'string' },
+        { name: 'pd_orderid', type: 'int' },
+        { name: 'pd_sdid', type: 'int' },
+        { name: 'pd_status', type: 'string' },
+        { name: 'pd_ym', type: 'int' },
+        { name: 'pd_yqty', type: 'int' },
+        { name: 'pd_remark', type: 'string' },
+        { name: 'pd_ioid', type: 'int' },
+    ]
+});

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

@@ -3,7 +3,7 @@ Ext.define('saas.util.FormUtil', {
     BaseUtil: Ext.create('saas.util.BaseUtil'),
 
     // 请求页面组件接口模板
-    baseUrl: 'http://192.168.0.181:8560/api/ui/co_view/config?name={viewName}',
+    baseUrl: basePath+'ui/co_view/config?name={viewName}',
     // 模板替换正则
     urlRe: /(.*){viewName}(.*)/g,
     

+ 69 - 52
frontend/saas-web/app/view/core/form/FormPanel.js

@@ -37,7 +37,7 @@ Ext.define('saas.view.core.form.FormPanel', {
     remoteConfig: true, // 是否需要从远端读取form配置
     toolBtns: [], // 自定义按钮
 
-    initComponent: function() {
+    initComponent: function () {
         var me = this;
         me.initViewModel();
         me.FormUtil.setItems(me);
@@ -53,21 +53,38 @@ Ext.define('saas.view.core.form.FormPanel', {
                     xtype: 'tbtext',
                     bind: {
                         html: '<span class="x-tb x-no">NO. </span>' +
-                        '<span class="x-tb x-code">{base.codeEditable ? "" : form.' + me._codeField + '}</span>'
+                            '<span class="x-tb x-code">{base.codeEditable ? "" : form.' + me._codeField + '}</span>'
                     }
                 }, {
                     xtype: 'textfield',
                     minHeight: 24,
                     maxHeight: 24,
+                    width: 150,
                     cls: 'x-codeeditor',
+                    hidden: true,
                     bind: {
                         value: '{form.' + me._codeField + '}',
                         hidden: '{!base.codeEditable}'
                     },
                     listeners: {
                         blur: 'codeEditorBlur',
-                        show: function(field, eOpts) {
+                        show: function (field, eOpts) {
+                            // field.animate({
+                            //     duration: 500,
+                            //     to: {
+                            //         width: 200
+                            //     }
+                            // });
+
                             field.focus();
+                        },
+                        hide: function(field) {
+                            // field.animate({
+                            //     duration: 500,
+                            //     to: {
+                            //         width: 150
+                            //     }
+                            // });
                         }
                     }
                 }, {
@@ -86,11 +103,11 @@ Ext.define('saas.view.core.form.FormPanel', {
                         hidden: '{!base.editable}'
                     },
                     handler: 'codeEditorClick'
-                },'->'].concat(me.toolBtns.map(function(btn){
-                    btn.cls = btn.cls ? btn.cls + ' x-formpanel-btn-blue':'x-formpanel-btn-blue';
+                }, '->'].concat(me.toolBtns.map(function (btn) {
+                    btn.cls = btn.cls ? btn.cls + ' x-formpanel-btn-blue' : 'x-formpanel-btn-blue';
                     return btn;
                 }).concat([{
-                    cls:'x-formpanel-btn-orange',
+                    cls: 'x-formpanel-btn-orange',
                     xtype: 'button',
                     text: '新增',
                     handler: 'add'
@@ -112,7 +129,7 @@ Ext.define('saas.view.core.form.FormPanel', {
                         text: '{auditBtnText}'
                     },
                     handler: "auditBtnClick",
-                    
+
                 }]))
             }]
         });
@@ -122,34 +139,34 @@ Ext.define('saas.view.core.form.FormPanel', {
     /**
      * 一些初始化viewModel的方法
      */
-    initViewModel: function() {
+    initViewModel: function () {
         var me = this,
-        codeField = me._codeField,
-        statusField = me._statusField,
-        statusCodeField = me._statusCodeField,
-        viewModel = me.getViewModel();
-        
-        viewModel.set('form.' + codeField, '--------------');
+            codeField = me._codeField,
+            statusField = me._statusField,
+            statusCodeField = me._statusCodeField,
+            viewModel = me.getViewModel();
+
+        viewModel.set('form.' + codeField, '');
         viewModel.set('form.createTime', new Date());
         viewModel.set('form.updateTime', new Date());
 
-        if(statusCodeField) {
+        if (statusCodeField) {
             var o = {};
             o['auditBtnText'] = {
                 bind: '{form.' + statusCodeField + '}',
                 get: function(value) {
-                    viewModel.set('form.' + statusField, value == 'AUDITED' ? '审核' : '反审核');
+                    viewModel.set('form.' + statusField, value == 'AUDITED' ? '已审核' : '未审核');
                     return value == 'AUDITED' ? '反审核' : '审核'
                 }
             };
             viewModel.setFormulas(o);
             viewModel.set('form.' + statusCodeField, "UNAUDITED");
-        }else {
+        } else {
             viewModel.set('auditBtnText', "审核");
         }
     },
 
-    addItems: function(items) {
+    addItems: function (items) {
         var me = this;
         me.setBindFields(items);
         return this.add(items);
@@ -158,19 +175,19 @@ Ext.define('saas.view.core.form.FormPanel', {
     /**
      * 获取form数据
      */
-    getFormData: function() {
+    getFormData: function () {
         var me = this,
-        viewModel = me.getViewModel(),
-        allData = viewModel.getData(),
-        formData = allData['form'],
-        detailCount = me.detailCount,
-        data = {
-            main: formData,
-        };
-
-        for(var i = 0; i < detailCount; i++) {
+            viewModel = me.getViewModel(),
+            allData = viewModel.getData(),
+            formData = allData['form'],
+            detailCount = me.detailCount,
+            data = {
+                main: formData,
+            };
+
+        for (var i = 0; i < detailCount; i++) {
             var detail = allData['detail' + i],
-            store = detail.detailStore;
+                store = detail.detailStore;
 
             data['detail' + i] = store.getData().items;
         }
@@ -178,21 +195,21 @@ Ext.define('saas.view.core.form.FormPanel', {
         return data;
     },
 
-    setFormData: function(formData) {
+    setFormData: function (formData) {
         var me = this,
-        main = formData.main,
-        detailCount = me.detailCount,
-        viewModel = me.getViewModel(),
-        viewData = viewModel.getData();
+            main = formData.main,
+            detailCount = me.detailCount,
+            viewModel = me.getViewModel(),
+            viewData = viewModel.getData();
 
         viewModel.set('form', main);
 
-        for(var i = 0; i < detailCount; i++) {
+        for (var i = 0; i < detailCount; i++) {
             var detailData = formData['detail' + i] || [],
-            detail = viewData['detail' + i],
-            store = detail.detailStore;
+                detail = viewData['detail' + i],
+                store = detail.detailStore;
 
-            if(detailData){
+            if (detailData) {
                 store.loadData(detailData);
             }
         }
@@ -201,36 +218,36 @@ Ext.define('saas.view.core.form.FormPanel', {
     /**
      * 设置需要绑定的字段
      */
-    setBindFields: function(items) {
+    setBindFields: function (items) {
         var me = this,
-        viewModel = me.getViewModel();
+            viewModel = me.getViewModel();
 
-        Ext.Array.each(items, function(item) {
+        Ext.Array.each(items, function (item) {
             var xtype = item.xtype,
-            bind = item.bind,
-            name = item.name,
-            ignore = item.ignore,
-            defaultValue = item.defaultValue;
+                bind = item.bind,
+                name = item.name,
+                ignore = item.ignore,
+                defaultValue = item.defaultValue;
 
-            if(xtype == 'detailGridField') {
+            if (xtype == 'detailGridField') {
                 return;
             }
 
             // 设置model绑定
-            if(!ignore) {
-                if(bind) {
-                    if(!Ext.isString(bind)) {
+            if (!ignore) {
+                if (bind) {
+                    if (!Ext.isString(bind)) {
                         Ext.apply(bind, {
                             value: '{form.' + name + '}'
                         });
-                    }else {
+                    } else {
                         item.bind = '{form.' + name + '}';
                     }
-                }else {
+                } else {
                     item.bind = '{form.' + name + '}';
                 }
                 // 设置默认值
-                if(defaultValue) {
+                if (defaultValue) {
                     viewModel.set('form.' + name, defaultValue);
                 }
             }

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

@@ -205,12 +205,13 @@ Ext.define('saas.view.core.form.FormPanelController', {
         var me = this,
         viewModel = me.getViewModel();
 
-        viewModel.set('base.codeEditable', false);
+        // viewModel.set('base.codeEditable', false);
     },
     codeEditorClick: function() {
         var me = this,
-        viewModel = me.getViewModel();
+        viewModel = me.getViewModel(),
+        codeEditable = viewModel.get('base.codeEditable');
 
-        viewModel.set('base.codeEditable', true);
+        viewModel.set('base.codeEditable', !codeEditable);
     }
 });

+ 1 - 3
frontend/saas-web/app/view/core/form/field/DetailGridField.js

@@ -134,15 +134,13 @@ Ext.define('saas.view.core.form.field.DetailGridField', {
 
     deleteDetail: function() {
         var me = this,
-            form = me.ownerCt;
             store = me.getStore(),
             selectedRecord = me.selModel.lastSelected;
 
         var id = selectedRecord.data.id;
-        var form = me.ownerGrid.ownerCt;
         if(id&&id!=0&&(typeof id) == 'number'){
             Ext.Ajax.request({
-                url: form._deleteDetailUrl+id,
+                url: me._deleteDetailUrl+id,
                 params: '',
                 headers: {
                     'Access-Control-Allow-Origin': '*'

+ 31 - 7
frontend/saas-web/app/view/document/customer/panel/FormPanel.js

@@ -5,7 +5,7 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
     controller: 'customer-panel-formpanel',
     viewModel: 'customer-panel-formpanel',
     
-    caller:'Purchase',
+    caller:'Customer',
 
     //字段属性
     _title:'客户资料',
@@ -17,7 +17,6 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
     _saveUrl:'http://192.168.253.228:9480/customer/save',
     _auditUrl:'http://192.168.253.228:8800/purchase/audit',
     _deleteUrl:'http://192.168.253.228:8800/purchase/delete/',
-    _deleteDetailUrl:'http://192.168.253.228:8800/purchase/deleteItem/',
     initId:0,
 
     defaultItems: [{
@@ -52,7 +51,7 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
         columnWidth: 0.25
     },{
         xtype : "remotecombo", 
-        storeUrl:"http://192.168.253.41:9480/customerkind/getCombo",
+        storeUrl:"http://192.168.253.31:9480/customerkind/getCombo",
         name : "cu_type", 
         fieldLabel : "客户类型", 
         allowBlank : true, 
@@ -64,8 +63,8 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
             vendorkind:{
                 keyField:'id',
                 dataField:'ck_name',
-                reqUrl:'http://192.168.253.41:9480/customerkind/save',
-                delUrl:'http://192.168.253.41:9480/customerkind/delete'
+                reqUrl:'http://192.168.253.31:9480/customerkind/save',
+                delUrl:'http://192.168.253.31:9480/customerkind/delete'
             }
         },
         addHandler:function(b){
@@ -84,7 +83,7 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
             this.dialog.show();
         }
     },{
-        format : "Y-m-d", 
+        format : "Y-m-d",
         xtype : "datefield", 
         name : "createTime", 
         fieldLabel : "创建时间", 
@@ -142,7 +141,6 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
         format : "Y-m-d",
         xtype : "datefield", 
         name : "updateTime", 
-        bind : "{updateTime}", 
         fieldLabel : "更新时间", 
         allowBlank : true, 
         columnWidth : 0.25
@@ -150,6 +148,7 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
         xtype : "detailGridField", 
         _detnoColumn:  'cc_detno',
         storeModel:'saas.model.document.customercontact',
+        _deleteDetailUrl:'http://192.168.253.228:8800/purchase/deleteItem/',
         columns : [
             {
                 text : "序号", 
@@ -163,6 +162,18 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
                     return Ext.String.format('合计: {0}条', value);
                 },
             },
+            {
+                text : "ID", 
+                dataIndex : "id", 
+                width : 0, 
+                xtype : "numbercolumn"
+            },
+            {
+                text : "关联ID", 
+                dataIndex : "cc_cuid", 
+                width : 0, 
+                xtype : "numbercolumn"
+            },
             {
                 text : "联系人", 
                 editor : {
@@ -240,6 +251,7 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
         xtype : "detailGridField", 
         _detnoColumn:  'ca_detno',
         storeModel:'saas.model.document.customeraddress',
+        _deleteDetailUrl:'http://192.168.253.228:8800/purchase/deleteItem/',
         columns : [
             {
                 text : "序号", 
@@ -253,6 +265,18 @@ Ext.define('saas.view.document.customer.panel.FormPanel', {
                     return Ext.String.format('合计: {0}条', value);
                 },
             }, 
+            {
+                text : "ID", 
+                dataIndex : "id", 
+                width : 0, 
+                xtype : "numbercolumn"
+            },
+            {
+                text : "关联ID", 
+                dataIndex : "ca_cuid", 
+                width : 0, 
+                xtype : "numbercolumn"
+            },
             {
                 text : "送货地址", 
                 editor : {

+ 8 - 8
frontend/saas-web/app/view/document/kind/Kind.js

@@ -68,8 +68,8 @@ Ext.define('saas.view.document.kind.Kind', {
             }],
             keyField:'id',
             dataField:'ck_name',
-            reqUrl:'http://192.168.253.41:9480/customerkind/save',
-            delUrl:'http://192.168.253.41:9480/customerkind/delete'
+            reqUrl:basePath + 'document/customerkind/save',
+            delUrl:basePath + 'document/customerkind/delete'
         },
         vendorkind:{
             columns: [{
@@ -79,8 +79,8 @@ Ext.define('saas.view.document.kind.Kind', {
             }],
             keyField:'id',
             dataField:'vk_name',
-            reqUrl:'http://192.168.253.41:9480/vendorkind/save',
-            delUrl:'http://192.168.253.41:9480/vendorkind/delete'
+            reqUrl:basePath + 'document/vendorkind/save',
+            delUrl:basePath + 'document/vendorkind/delete'
         },
         productkind:{
             columns: [{
@@ -90,8 +90,8 @@ Ext.define('saas.view.document.kind.Kind', {
             }],
             keyField:'id',
             dataField:'pt_name',
-            reqUrl:'http://192.168.253.41:9480/producttype/save',
-            delUrl:'http://192.168.253.41:9480/producttype/delete'
+            reqUrl:basePath + 'document/producttype/save',
+            delUrl:basePath + 'document/producttype/delete'
         },
         productbrand:{
             columns: [{
@@ -101,8 +101,8 @@ Ext.define('saas.view.document.kind.Kind', {
             }],
             keyField:'id',
             dataField:'pb_name',
-            reqUrl:'http://192.168.253.41:9480/productbrand/save',
-            delUrl:'http://192.168.253.41:9480/productbrand/delete'
+            reqUrl:basePath + 'document/productbrand/save',
+            delUrl:basePath + 'document/productbrand/delete'
         },
         inoutkind:{
             columns: [{

+ 4 - 4
frontend/saas-web/app/view/document/kind/KindModel.js

@@ -15,7 +15,7 @@ Ext.define('saas.view.document.kind.KindModel', {
             ],
             proxy: {
                 type: 'ajax',
-                url: 'http://192.168.253.41:9480/customerkind/getAll',
+                url: basePath + 'document/customerkind/getAll',
                 actionMethods: {
                     read: 'GET'
                 },
@@ -34,7 +34,7 @@ Ext.define('saas.view.document.kind.KindModel', {
             ],
             proxy: {
                 type: 'ajax',
-                url: 'http://192.168.253.41:9480/vendorkind/getAll',
+                url: basePath + 'document/vendorkind/getAll',
                 actionMethods: {
                     read: 'GET'
                 },
@@ -53,7 +53,7 @@ Ext.define('saas.view.document.kind.KindModel', {
             ],
             proxy: {
                 type: 'ajax',
-                url: 'http://192.168.253.41:9480/producttype/getAll',
+                url: basePath + 'document/producttype/getAll',
                 actionMethods: {
                     read: 'GET'
                 },
@@ -72,7 +72,7 @@ Ext.define('saas.view.document.kind.KindModel', {
             ],
             proxy: {
                 type: 'ajax',
-                url: 'http://192.168.253.41:9480/productbrand/getAll',
+                url: basePath + 'document/productbrand/getAll',
                 actionMethods: {
                     read: 'GET'
                 },

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

@@ -23,9 +23,9 @@ Ext.define('saas.view.document.vendor.FormPanel', {
 
     //字段属性
     _title:'供应商管理',
-    _dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
-    _saveUrl:'http://192.168.253.228:8800/api/document/vendor/save',
-    _deleteUrl:'http://192.168.253.228:8800/api/document/vendor/delete',
+    _dataUrl:basePath + 'document/vendor/getVendorsByCondition',
+    _saveUrl:basePath + 'document/vendor/save',
+    _deleteUrl:basePath + 'document/vendor/delete',
 
     initComponent: function () {
         var me = this;

+ 11 - 17
frontend/saas-web/app/view/money/payBalance/FormPanel.js

@@ -6,30 +6,24 @@ Ext.define('saas.view.money.payBalance.FormPanel', {
     viewModel: 'money-paybalance-formpanel',
 
     viewName: 'money-paybalance-formpanel',
-
-    caller: 'Purchase',
+    caller: 'PayBalance',
 
     //字段属性
     _title: '付款单',
     _idField: 'id',
-    _codeField: 'pu_code',
-    _statusField: 'pu_status',
-    _statusCodeField: 'pu_statuscode',
+    _codeField: 'pd_code',
+    _statusField: 'pd_status',
+    _statusCodeField: 'pd_statuscode',
     
-    _relationColumn: 'pd_puid',
-    _readUrl: 'http://192.168.0.181:8560/api/purchase/purchase/read/',
-    _saveUrl: 'http://192.168.0.181:8560/api/purchase/purchase/save',
-    _auditUrl: 'http://192.168.0.181:8560/api/purchase/purchase/audit',
-    _deleteUrl: 'http://192.168.0.181:8560/api/purchase/purchase/delete/',
-    _deleteDetailUrl: 'http://192.168.0.181:8560/api/purchase/purchase/deleteItem/',
-    _turnInUrl: 'http://192.168.253.228:8800/purchase/turnProdin/',
+    _readUrl: basePath + 'money/paybalance/read/',
+    _saveUrl: basePath + 'money/paybalance/save',
+    _auditUrl: basePath + 'money/paybalance/audit',
+    _deleteUrl: basePath + 'money/paybalance/delete/',
+    _deleteDetailUrl: basePath + 'money/paybalance/deleteItem/',
+    _turnInUrl: basePath + 'money/paybalance/turnProdin/',
     initId: 0,
 
-    // toolBtns: [{
-    //     xtype: 'button',
-    //     text: '转采购验收单',
-    //     handler: 'turnIn'
-    // }],
+    toolBtns: [],
 
     defaultItems: [{
         xtype: 'hidden',

+ 3 - 3
frontend/saas-web/app/view/money/payBalance/FormPanelController.js

@@ -1,4 +1,4 @@
-Ext.define('saas.view.money.paybalance.FormPanelController', {
+Ext.define('saas.view.money.payBalance.FormPanelController', {
     extend: 'saas.view.core.form.FormPanelController',
     alias: 'controller.money-paybalance-formpanel',
 
@@ -15,7 +15,7 @@ Ext.define('saas.view.money.paybalance.FormPanelController', {
             'dbfindtrigger[name=pu_vendcode]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.0.181:8570/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -67,7 +67,7 @@ Ext.define('saas.view.money.paybalance.FormPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.0.181:8570/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode'
                         }],

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

@@ -1,4 +1,4 @@
-Ext.define('saas.view.money.paybalance.FormPanelModel', {
+Ext.define('saas.view.money.payBalance.FormPanelModel', {
     extend: 'saas.view.core.form.FormPanelModel',
     alias: 'viewmodel.money-paybalance-formpanel',
 

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

@@ -101,7 +101,7 @@ Ext.define('saas.view.money.paybalance.QueryPanel', {
         addTitle: '采购单',
         addXtype: 'purchase-purchase-formpanel',
         defaultCondition:'',
-        baseVastUrl: 'http://192.168.253.58:8800/purchase/',
+        baseVastUrl: basePath + 'purchase/',
         baseColumn: [{
             text: '序号',
             width: 80,

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

@@ -9,7 +9,7 @@ Ext.define('saas.view.money.paybalance.QueryPanelController', {
             'dbfindtrigger[name=pu_vendname]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -61,7 +61,7 @@ Ext.define('saas.view.money.paybalance.QueryPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode',
                         }, {

+ 177 - 0
frontend/saas-web/app/view/money/recBalance/FormPanel.js

@@ -0,0 +1,177 @@
+Ext.define('saas.view.money.recBalance.FormPanel', {
+    extend: 'saas.view.core.form.FormPanel',
+    xtype: 'money-recbalance-formpanel',
+
+    controller: 'money-recbalance-formpanel',
+    viewModel: 'money-recbalance-formpanel',
+
+    viewName: 'money-recbalance-formpanel',
+
+    caller: 'RecBalance',
+
+    //字段属性
+    _title: '收款单',
+    _idField: 'id',
+    _codeField: 'pd_code',
+    _statusField: 'pd_status',
+    _statusCodeField: 'pd_statuscode',
+    
+    _readUrl: 'http://192.168.253.129:8920/api/money/recbalance/read',
+    _saveUrl: 'http://192.168.253.129:8920/money/recbalance/save',
+    _auditUrl: 'http://192.168.0.181:8560/api/purchase/purchase/audit',
+    _deleteUrl: 'http://192.168.0.181:8560/api/purchase/purchase/delete/',
+    _deleteDetailUrl: 'http://192.168.0.181:8560/api/purchase/purchase/deleteItem/',
+    _turnInUrl: 'http://192.168.253.228:8800/purchase/turnProdin/',
+    initId: 0,
+
+    defaultItems: [{
+        xtype: 'hidden',
+        name: 'id',
+        fieldLabel: 'id'
+    }, {
+        xtype: 'hidden',
+        name: 'custid',
+        fieldLabel: '客户ID'
+    }, {
+        xtype: 'hidden',
+        name: 'custcode',
+        fieldLabel: '客户编号'
+    }, {
+        xtype: "dbfindtrigger",
+        name: "rb_custname",
+        fieldLabel: "客户名称"
+    }, {
+        xtype: "numberfield",
+        name: "rb_rbdamount",
+        fieldLabel: "总欠款"
+    }, {
+        xtype: "datefield",
+        name: "rb_date",
+        fieldLabel: "日期"
+    }, {
+        xtype: "dbfindtrigger",
+        name: "rb_manname",
+        fieldLabel: "收款人"
+    }, {
+        xtype: 'textareafield',
+        name: 'rb_remark',
+        fieldLabel: '备注',
+        columnWidth: 1
+    }, {
+        xtype: "numberfield",
+        name: "rb_discounts",
+        fieldLabel: "整单折扣"
+    }, {
+        xtype: 'numberfield',
+        name: 'rb_preamount',
+        fieldLabel : '本次预收款'
+    }, {
+        xtype: "detailGridField",
+        storeModel: 'saas.model.money.RecBalance1',
+        _detnoColumn: 'rd_detno',
+        columns: [{
+            text: "序号",
+            dataIndex: "rd_detno",
+            width: 100,
+            xtype: "numbercolumn",
+            align: 'center',
+            format: '0',
+            summaryType: 'count',
+            summaryRenderer: function (value, summaryData, dataIndex) {
+                return Ext.String.format('合计: {0}条', value);
+            },
+        }, {
+            text: '资金账户',
+            dataIndex: 'rd_bankname',
+            width : 200.0, 
+            editor : {
+                displayField : "display", 
+                editable : true, 
+                format : "", 
+                hideTrigger : false, 
+                maxLength : 100.0, 
+                minValue : null, 
+                positiveNum : false, 
+                queryMode : "local", 
+                store : null, 
+                valueField : "value", 
+                xtype : "dbfindtrigger"
+            }
+        }, {
+            text: "收款金额",
+            dataIndex: "rd_amount",
+        }, {
+            text: "结算方式",
+            dataIndex: "rd_paymethod"
+        }, {
+            text: "结算号",
+            dataIndex: "rd_paycode"
+        }, {
+            text: "备注",
+            dataIndex: "rd_remark"
+        }]
+    }, {
+        xtype: "detailGridField",
+        storeModel: 'saas.model.money.RecBalance1',
+        _detnoColumn: 'rbd_detno',
+        columns: [{
+            text: "序号",
+            dataIndex: "rbd_detno",
+            width: 100,
+            xtype: "numbercolumn",
+            align: 'center',
+            format: '0',
+            summaryType: 'count',
+            summaryRenderer: function (value, summaryData, dataIndex) {
+                return Ext.String.format('合计: {0}条', value);
+            },
+        }, {
+            text: '来源单号',
+            dataIndex: 'rbd_slcode'
+        }, {
+            text: "业务类型",
+            dataIndex: "rbd_slkind",
+        }, {
+            text: "单据日期",
+            dataIndex: "rbd_sldate"
+        }, {
+            text: "单据金额",
+            dataIndex: "rbd_amount"
+        }, {
+            text: "已核销金额",
+            dataIndex: "rbd_nowbalance"
+        }, {
+            text: "未核销金额",
+            dataIndex: "pbd_nowbalance"
+        }, {
+            text: "本次核销金额",
+            dataIndex: "pbd_nowbalance"
+        }]
+    }, {
+        xtype: 'textfield',
+        name: 'companyid',
+        fieldLabel: '公司id'
+    }, {
+        format: "Y-m-d h:i:s",
+        xtype: "datefield",
+        name: "pb_recorddate",
+        fieldLabel: "创建时间"
+    }, {
+        format: "Y-m-d h:i:s",
+        xtype: "datefield",
+        name: "updatedate",
+        fieldLabel: "更新时间"
+    }, {
+        xtype: "textfield",
+        readOnly: true,
+        editable: false,
+        name: "pd_status",
+        fieldLabel: "单据状态"
+    }, {
+        xtype: "hidden",
+        readOnly: true,
+        editable: false,
+        name: "pd_statuscode",
+        fieldLabel: "单据状态码"
+    }]
+});

+ 158 - 0
frontend/saas-web/app/view/money/recBalance/FormPanelController.js

@@ -0,0 +1,158 @@
+Ext.define('saas.view.money.recBalance.FormPanelController', {
+    extend: 'saas.view.core.form.FormPanelController',
+    alias: 'controller.money-recbalance-formpanel',
+
+    init: function (form) {
+        var me = this;
+        this.control({
+            /**放大镜新增demo*/
+            "field[name=combo]":{
+                beforerender:function(f){
+                    f.addHandler=me.addCombo;
+                }
+            },
+            //放大镜赋值关系 以及 tpl模板
+            'dbfindtrigger[name=pu_vendcode]':{
+                beforerender:function(f){
+                    Ext.apply(f,{
+                        dataUrl:'http://192.168.0.181:8570/api/document/vendor/getVendorsByCondition',
+                        dbfinds:[{
+                            from:'ve_code',to:'pu_vendcode'
+                        },{
+                            from:'ve_name',to:'pu_vendname'
+                        }],
+                        dbtpls:[{
+                            field:'ve_code',width:100
+                        },{
+                            field:'ve_name',width:100
+                        }],
+                        dbColumns:[{
+                            conditionCode:'ve_id',
+                            "text": "供应商ID",
+                            "flex": 0,
+                            "dataIndex": "ve_id",
+                            "width": 0,
+                            "xtype": "",
+                            "items": null
+                        },{
+                            conditionCode:'ve_code',
+                            "text": "供应商编号",
+                            "flex": 1,
+                            "dataIndex": "ve_code",
+                            "width": 100,
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            conditionCode:'ve_name',
+                            "text": "供应商名称",
+                            "flex": 1,
+                            "dataIndex": "ve_name",
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            conditionCode:'ve_type',
+                            "text": "供应商类型",
+                            "flex": 0,
+                            "dataIndex": "ve_type",
+                            "width": 200,
+                            "xtype": "",
+                            "items": null
+                        }]
+                    }) ;   
+
+                }
+            },
+            //放大镜赋值关系 以及 tpl模板
+            'dbfindtrigger[name=pd_prodcode]':{
+                beforerender:function(f){
+                    Ext.apply(f,{
+                        conditionCode:'pr_code',
+                        dataUrl:'http://192.168.0.181:8570/api/document/product/getProductsByCondition',
+                        dbfinds:[{
+                            from:'pr_code',to:'pd_prodcode'
+                        }],
+                        dbtpls:[{
+                            field:'pr_code',width:100
+                        },{
+                            field:'pr_detail',width:100
+                        }],
+                        dbColumns:[{
+                            "text": "物料ID",
+                            "flex": 0,
+                            "dataIndex": "pr_id",
+                            "width": 0,
+                            "xtype": "",
+                            "items": null
+                        },{
+                            "text": "物料编号",
+                            "flex": 1,
+                            "dataIndex": "pr_code",
+                            "width": 100,
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            "text": "物料名称",
+                            "flex": 1,
+                            "dataIndex": "pr_detail",
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            "text": "物料规格",
+                            "flex": 0,
+                            "dataIndex": "pr_spec",
+                            "width": 200,
+                            "xtype": "",
+                            "items": null
+                        }]
+                    }) ;   
+
+                }
+            }
+        });
+
+    },
+    addCombo:function(){
+        var combo=this.ownerCmp;
+        Ext.create('Ext.window.Window',{
+            layout:'vbox',
+            bodyPadding: 15,
+            width:500,
+            items:[{
+                fieldLabel:'实际值',
+                xtype:'textfield'
+            },{
+                fieldLabel:'显示值',
+                xtype:'textfield'
+            }],
+            buttons:[{
+                text:'确认',
+                handler:function(b){
+                    combo.setValue('ok');
+                    b.up('window').close();
+                }
+            }],
+            renderTo:this.ownerCmp.ownerCt.getEl()
+        }).show();
+
+    },
+
+    turnIn: function() {
+        var me = this,
+        form = me.getView(),
+        id = form.getForm().findField(form._idField);
+        form.BaseUtil.request({
+            url: form._turnInUrl+id.value,
+            method: 'GET',
+        })
+        .then(function(res) {
+            var localJson = new Ext.decode(res.responseText);
+            if(localJson.success){
+                Ext.Msg.alert('提示','转单成功');
+              
+            }
+        })
+        .catch(function() {
+            Ext.Msg.alert('提示','转单失败');
+        });
+     }
+});

+ 5 - 0
frontend/saas-web/app/view/money/recBalance/FormPanelModel.js

@@ -0,0 +1,5 @@
+Ext.define('saas.view.money.recBalance.FormPanelModel', {
+    extend: 'saas.view.core.form.FormPanelModel',
+    alias: 'viewmodel.money-recbalance-formpanel',
+
+});

+ 196 - 0
frontend/saas-web/app/view/money/recBalance/QueryPanel.js

@@ -0,0 +1,196 @@
+Ext.define('saas.view.money.recBalance.QueryPanel', {
+    extend: 'saas.view.core.query.QueryPanel',
+    xtype: 'money-recbalance-querypanel',
+
+    controller: 'money-recbalance-querypanel',
+    viewModel: 'money-recbalance-querypanel',
+
+    viewName: 'money-recbalance-querypanel',
+    
+    queryFormItems: [{
+        xtype: 'hidden',
+        name: 'pu_id',
+        bind: '{pu_id}',
+        fieldLabel: 'ID',
+        allowBlank: true,
+        getCondition: function(value) {
+            return 'pu_id=' + value;
+        }
+    }, {
+        xtype: 'textfield',
+        name: 'pu_code',
+        bind: '{pu_code}',
+        fieldLabel: '单据编号'
+    }, {
+        xtype: 'condatefield',
+        name: 'pu_date',
+        bind: '{pu_date}',
+        fieldLabel: '采购日期',
+        columnWidth: 0.5,
+        operation: 'between'
+    }, {
+        xtype: 'dbfindtrigger',
+        name: 'pu_vendcode',
+        bind: '{pu_vendcode}',
+        fieldLabel: '供应商编号'
+    }, {
+        xtype: 'textfield',
+        name: 'pu_vendname',
+        bind: '{pu_vendname}',
+        fieldLabel: '供应商名称'
+    }, {
+        xtype: 'dbfindtrigger',
+        name: 'pd_prodcode',
+        bind: '{pd_prodcode}',
+        fieldLabel: '物料编号',
+        showDetail: true
+    }, {
+        xtype: 'textfield',
+        name: 'pr_detail',
+        bind: '{pr_detail}',
+        fieldLabel: '物料名称',
+        showDetail: true
+    }, {
+        xtype: 'combobox',
+        name: 'pu_statuscode',
+       // bind: '{pu_statuscode}',
+        fieldLabel: '审核状态',
+        queryMode: 'local',
+        displayField: 'pu_status',
+        valueField: 'pu_statuscode',
+        editable:false,
+        store: Ext.create('Ext.data.ArrayStore', {
+        fields: ['pu_statuscode', 'pu_status'],
+        data: [
+            ["$ALL", "全部"],
+            ["AUDITED", "已审核"],
+            ["UNAUDITED", "未审核"]
+        ]
+        })
+    }, {
+        xtype: 'multicombo',
+        name: 'pu_acceptstatuscode',
+        bind: '{pu_acceptstatuscode}',
+        fieldLabel: '入库状态',
+        datas: [
+            ["TURNIN", "已入库"],
+            ["UNTURNIN", "未入库"],
+            ["PARTIN", "部分入库"]
+        ]
+    }],
+    moreQueryFormItems: [{
+        xtype: 'textfield',
+        name: 'pu_buyername',
+        bind: '{pu_buyername}',
+        fieldLabel: '采购员'
+    }, {
+        xtype: 'textfield',
+        name: 'pu_total',
+        bind: '{pu_total}',
+        fieldLabel: '金额'
+    }, {
+        xtype: 'condatefield',
+        name: 'pu_delivery',
+        bind: '{pu_delivery}',
+        fieldLabel: '交货日期',
+        columnWidth: 1
+    }],
+    queryGridConfig: {
+        idField: 'pu_id',
+        codeField: 'pu_code',
+        addTitle: '采购单',
+        addXtype: 'purchase-purchase-formpanel',
+        defaultCondition:'',
+        baseVastUrl: 'http://192.168.253.58:8800/purchase/',
+        baseColumn: [{
+            text: '序号',
+            width: 80,
+            xtype: 'rownumberer'
+        }, {
+            text: 'id',
+            dataIndex: 'pu_id',
+            width: 100,
+            xtype: 'numbercolumn'
+        }, {
+            text: '单据编号',
+            dataIndex: 'pu_code',
+            width: 120
+        }, {
+            text: '单据状态',
+            dataIndex: 'pu_status',
+            width: 120
+        }, {
+            text: '下单日期',
+            dataIndex: 'pu_indate',
+            xtype: 'datecolumn',
+            width: 200
+        }, {
+            text: '供应商名称',
+            dataIndex: 'pu_vendname',
+            width: 120
+        }, {
+            text: '含税金额',
+            dataIndex: 'pu_taxtotal',
+            xtype: 'numbercolumn',
+            width: 120
+        }, {
+            text: '金额',
+            dataIndex: 'pu_total',
+            xtype: 'numbercolumn',
+            width: 120,
+            flex: 1
+        }],
+        relativeColumn: [{
+            text: '序号',
+            width: 80,
+            xtype: 'rownumberer'
+        }, {
+            text: 'id',
+            dataIndex: 'pu_id',
+            width: 100,
+            xtype: 'numbercolumn'
+        }, {
+            text: '单据编号',
+            dataIndex: 'pu_code',
+            width: 120
+        }, {
+            text: '单据状态',
+            dataIndex: 'pu_status',
+            width: 120
+        }, {
+            text: '下单日期',
+            dataIndex: 'pu_indate',
+            xtype: 'datecolumn',
+            width: 200
+        }, {
+            text: '供应商名称',
+            dataIndex: 'pu_vendname',
+            width: 120
+        }, {
+            text: '采购序号',
+            dataIndex: 'pd_detno',
+            xtype: 'numbercolumn',
+            width: 120
+        }, {
+            text: '物料编号',
+            dataIndex: 'pd_prodcode',
+            width: 120
+        }, {
+            text: '数量',
+            dataIndex: 'pd_qty',
+            xtype: 'numbercolumn',
+            width: 120
+        }, {
+            text: '单价',
+            dataIndex: 'pd_price',
+            xtype: 'numbercolumn',
+            width: 120
+        }, {
+            text: '已转数',
+            dataIndex: 'pd_ytqy',
+            xtype: 'numbercolumn',
+            width: 120,
+            flex: 1
+        }]
+    }
+});

+ 117 - 0
frontend/saas-web/app/view/money/recBalance/QueryPanelController.js

@@ -0,0 +1,117 @@
+Ext.define('saas.view.money.recBalance.QueryPanelController', {
+    extend: 'saas.view.core.query.QueryPanelController',
+    alias: 'controller.money-recbalance-querypanel',
+    
+    init: function (form) {
+        var me = this;
+        this.control({
+            //放大镜赋值关系 以及 tpl模板
+            'dbfindtrigger[name=pu_vendname]':{
+                beforerender:function(f){
+                    Ext.apply(f,{
+                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dbfinds:[{
+                            from:'ve_code',to:'pu_vendcode'
+                        },{
+                            from:'ve_name',to:'pu_vendname'
+                        }],
+                        dbtpls:[{
+                            field:'ve_code',width:100
+                        },{
+                            field:'ve_name',width:100
+                        }],
+                        dbColumns:[{
+                            conditionCode:'ve_id',
+                            "text": "供应商ID",
+                            "flex": 0,
+                            "dataIndex": "ve_id",
+                            "width": 0,
+                            "xtype": "",
+                            "items": null
+                        },{
+                            conditionCode:'ve_code',
+                            "text": "供应商编号",
+                            "flex": 1,
+                            "dataIndex": "ve_code",
+                            "width": 100,
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            conditionCode:'ve_name',
+                            "text": "供应商名称",
+                            "flex": 1,
+                            "dataIndex": "ve_name",
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            conditionCode:'ve_type',
+                            "text": "供应商类型",
+                            "flex": 0,
+                            "dataIndex": "ve_type",
+                            "width": 200,
+                            "xtype": "",
+                            "items": null
+                        }]
+                    }) ;   
+
+                }
+            },
+            //放大镜赋值关系 以及 tpl模板
+            'dbfindtrigger[name=pd_prodcode]':{
+                beforerender:function(f){
+                    Ext.apply(f,{
+                        conditionCode:'pr_code',
+                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dbfinds:[{
+                            from:'pr_code',to:'pd_prodcode',
+                        }, {
+                            from:'pr_detail',to:'pr_detail'
+                        }],
+                        dbtpls:[{
+                            field:'pr_code',width:100
+                        },{
+                            field:'pr_detail',width:100
+                        }],
+                        dbColumns:[{
+                            "text": "物料ID",
+                            "flex": 0,
+                            "dataIndex": "pr_id",
+                            "width": 0,
+                            "xtype": "",
+                            "items": null
+                        },{
+                            "text": "物料编号",
+                            "flex": 1,
+                            "dataIndex": "pr_code",
+                            "width": 100,
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            "text": "物料名称",
+                            "flex": 1,
+                            "dataIndex": "pr_detail",
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            "text": "物料规格",
+                            "flex": 0,
+                            "dataIndex": "pr_spec",
+                            "width": 200,
+                            "xtype": "",
+                            "items": null
+                        }, {
+                            "text": "物料单位",
+                            "flex": 0,
+                            "dataIndex": "pr_unit",
+                            "width": 200,
+                            "xtype": "",
+                            "items": null
+                        }]
+                    }) ;   
+
+                }
+            }
+        });
+
+    }
+});

+ 5 - 0
frontend/saas-web/app/view/money/recBalance/QueryPanelModel.js

@@ -0,0 +1,5 @@
+Ext.define('saas.view.money.recBalance.QueryPanelModel', {
+    extend: 'saas.view.core.query.QueryPanelModel',
+    alias: 'viewmodel.money-recbalance-querypanel'
+
+});

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

@@ -6,7 +6,6 @@ Ext.define('saas.view.purchase.purchase.FormPanel', {
     viewModel: 'purchase-purchase-formpanel',
 
     viewName: 'purchase-purchase-formpanel',
-    
     caller:'Purchase',
     
      //字段属性
@@ -112,7 +111,7 @@ Ext.define('saas.view.purchase.purchase.FormPanel', {
     }, {
         name : "detailGridField", 
         xtype : "detailGridField", 
-        storeModel:'saas.model.purchase.purchasedetail',
+        storeModel:'saas.model.purchase.ProdIODetail',
         _detnoColumn:  'pd_detno',
         columns : [
             {
@@ -123,6 +122,7 @@ Ext.define('saas.view.purchase.purchase.FormPanel', {
                 align : 'center',
                 format:'0',
                 summaryType: 'count',
+                locked:true,
                 summaryRenderer: function(value, summaryData, dataIndex) {
                     return Ext.String.format('合计: {0}条', value);
                 },

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

@@ -34,7 +34,7 @@ Ext.define('saas.view.purchase.purchase.QueryPanel', {
         bind: '{pu_vendcode}',
         fieldLabel: '供应商编号'
     }, {
-        xtype: 'textfield',
+        xtype: 'dbfindtrigger',
         name: 'pu_vendname',
         bind: '{pu_vendname}',
         fieldLabel: '供应商名称'
@@ -53,7 +53,6 @@ Ext.define('saas.view.purchase.purchase.QueryPanel', {
     }, {
         xtype: 'combobox',
         name: 'pu_statuscode',
-       // bind: '{pu_statuscode}',
         fieldLabel: '审核状态',
         queryMode: 'local',
         displayField: 'pu_status',

+ 12 - 15
frontend/saas-web/app/view/purchase/purchaseIn/FormPanel.js

@@ -4,6 +4,8 @@ Ext.define('saas.view.purchase.purchaseIn.FormPanel', {
 
     controller: 'purchase-purchasein-formpanel',
     viewModel: 'purchase-purchasein-formpanel',
+
+    viewName: 'purchase-purchasein-formpanel',
     caller:'PurchaseIn',
     
      //字段属性
@@ -58,21 +60,16 @@ Ext.define('saas.view.purchase.purchaseIn.FormPanel', {
         fieldLabel : "供应商ID", 
         allowBlank : true, 
         columnWidth : 0.0
+    },{
+        xtype: 'hidden',
+        name: 'pu_vendcode',
+        bind: '{pu_vendcode}',
+        fieldLabel: '供应商编号'
     }, {
-        xtype : "textfield", 
-        name : "pi_vendcode", 
-        bind : "{pi_vendcode}", 
-        fieldLabel : "供应商编号", 
-        hidden:true,
-        allowBlank : true, 
-        columnWidth : 0, 
-    }, {
-        xtype : "dbfindtrigger", 
-        name : "pi_vendname", 
-        bind : "{pi_vendname}", 
-        fieldLabel : "供应商名称", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        xtype: 'dbfindtrigger',
+        name: 'pu_vendname',
+        bind: '{pu_vendname}',
+        fieldLabel: '供应商名称'
     },{
         xtype : "datefield", 
         name : "pi_date", 
@@ -105,7 +102,7 @@ Ext.define('saas.view.purchase.purchaseIn.FormPanel', {
     }, {
         name : "detailGridField", 
         xtype : "detailGridField",
-        storeModel:'saas.model.purchase.prodIODetail', 
+        storeModel:'saas.model.purchase.ProdIODetail', 
         _detnoColumn:  'pd_pdno',
         columns : [
             {

+ 13 - 11
frontend/saas-web/app/view/purchase/purchaseIn/QueryPanel.js

@@ -48,18 +48,13 @@ Ext.define('saas.view.purchase.purchaseIn.QueryPanel', {
         name: 'pd_prodcode',
         bind: '{pd_prodcode}',
         fieldLabel: '物料编号',
-        fieldMode: 'DETAIL',
-        queryType:'VAG',
-        hidden:true,
-        allowBlank: true,
-        columnWidth: 0.25
+        showDetail: true
     }, {
-        xtype: 'dbfindtrigger',
-        name: 'pr_detail#pd_prodcode',
+        xtype: 'textfield',
+        name: 'pr_detail',
         bind: '{pr_detail}',
         fieldLabel: '物料名称',
-        allowBlank: true,
-        columnWidth: 0.25
+        showDetail: true
     }, {
         xtype: 'combobox',
         name: 'pi_statuscode',
@@ -73,11 +68,18 @@ Ext.define('saas.view.purchase.purchaseIn.QueryPanel', {
         store: Ext.create('Ext.data.ArrayStore', {
             fields: ['pi_statuscode', 'pi_status'],
             data: [
-                ["$ALL", "全部"],
+                ["ALL", "全部"],
                 ["AUDITED", "已审核"],
                 ["UNAUDITED", "未审核"]
             ]
-        })
+        }),
+        getCondition: function(value) {
+            if(value == 'ALL') {
+                return '1=1';
+            }else {
+                return 'pi_statuscode=\'' + value + '\'';
+            }
+        }
     }],
     moreQueryFormItems: [{
         xtype: 'textfield',

+ 1 - 0
frontend/saas-web/app/view/purchase/purchaseOut/FormPanel.js

@@ -100,6 +100,7 @@ Ext.define('saas.view.purchase.purchaseOut.FormPanel', {
     },{
         name : "detailGridField", 
         xtype : "detailGridField", 
+        storeModel:'saas.model.purchase.ProdIODetail', 
         _detnoColumn:  'pd_pdno',
         columns : [
             {

+ 8 - 1
frontend/saas-web/app/view/purchase/purchaseOut/QueryPanel.js

@@ -77,7 +77,14 @@ Ext.define('saas.view.purchase.purchaseOut.QueryPanel', {
                 ["AUDITED", "已审核"],
                 ["UNAUDITED", "未审核"]
             ]
-        })
+        }),
+        getCondition: function(value) {
+            if(value == 'ALL') {
+                return '1=1';
+            }else {
+                return 'pi_statuscode=\'' + value + '\'';
+            }
+        }
     }],
     moreQueryFormItems: [{
         xtype: 'textfield',

+ 3 - 1
frontend/saas-web/app/view/sale/sale/FormPanel.js

@@ -4,7 +4,8 @@ Ext.define('saas.view.sale.sale.FormPanel', {
 
     controller: 'sale-sale-formpanel',
     viewModel: 'sale-sale-formpanel',
-    
+
+    viewName: 'sale-sale-formpanel',
     caller:'Sale',
     
      //字段属性
@@ -114,6 +115,7 @@ Ext.define('saas.view.sale.sale.FormPanel', {
     ,{
         name : "detailGridField", 
         xtype : "detailGridField", 
+        storeModel:'saas.model.sale.Saledetail',
         _detnoColumn:  'sd_detno',
         columnWidth : 1,
         columns : [

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

@@ -72,11 +72,18 @@ Ext.define('saas.view.sale.sale.QueryPanel', {
         store: Ext.create('Ext.data.ArrayStore', {
         fields: ['sa_statuscode', 'sa_status'],
         data: [
-            ["$ALL", "全部"],
+            ["ALL", "全部"],
             ["AUDITED", "已审核"],
             ["UNAUDITED", "未审核"]
         ]
-        })
+        }),
+        getCondition: function(value) {
+            if(value == 'ALL') {
+                return '1=1';
+            }else {
+                return 'sa_statuscode=\'' + value + '\'';
+            }
+        }
     }, {
         xtype: 'multicombo',
         name: 'sa_sendstatuscode',

+ 47 - 92
frontend/saas-web/app/view/sale/saleIn/FormPanel.js

@@ -4,7 +4,9 @@ Ext.define('saas.view.sale.saleIn.FormPanel', {
 
     controller: 'sale-salein-formpanel',
     viewModel: 'sale-salein-formpanel',
-    caller:'ProdInOut!SaleReturn',
+    
+    viewName: 'sale-salein-formpanel',
+    caller:'SaleIn',
     
      //字段属性
     _title:'销售退货单',
@@ -23,88 +25,52 @@ Ext.define('saas.view.sale.saleIn.FormPanel', {
     _turnOutUrl:basePath+'sale/prodinout/turnProdOut/',
     initId:0,
 
-    // toolBtns: [{
-    //     xtype: 'button',
-    //     text: '',
-    //     handler: 'turnOut'
-    // }],
-
     defaultItems: [{
         xtype: 'hidden',
         name: 'id',
-        bind: '{id}',
         fieldLabel: 'id',
-        allowBlank: true,
         columnWidth: 0
-    }, {
+    },{
         xtype : "textfield", 
         name : "pi_inoutno", 
-        bind : "{pi_inoutno}", 
-        fieldLabel : "退货单号", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        fieldLabel : "单据编号"
     },{
         xtype : "textfield", 
-        name : "pi_class", 
-        bind : "{pi_class}", 
-        fieldLabel : "单据类型", 
+        name : "pi_status", 
+        fieldLabel : "状态", 
         readOnly:true,
-        allowBlank : true, 
-        columnWidth : 0.25
-    }, {
-        xtype : "hidden", 
-        name : "pi_custid", 
-        bind : "{pi_custid}", 
-        fieldLabel : "客户ID", 
-        allowBlank : true, 
-        columnWidth : 0.0
-    }, {
-        xtype : "textfield", 
-        name : "pi_custcode", 
-        bind : "{pi_custcode}", 
-        fieldLabel : "客户编号", 
-        hidden:true,
-        allowBlank : true, 
-        columnWidth : 0, 
-    }, {
-        xtype : "dbfindtrigger", 
-        name : "pi_custname", 
-        bind : "{pi_custname}", 
-        fieldLabel : "客户名称", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        allowBlank : false, 
+        defaultValue:'未审核'
     },{
-        xtype : "datefield", 
-        name : "pi_date", 
-        bind : "{pi_date}", 
-        fieldLabel : "单据日期", 
+        xtype : "hidden", 
+        name : "pi_statuscode", 
+        fieldLabel : "状态码", 
+        readOnly:true,
         allowBlank : false, 
-        columnWidth : 0.25
+        defaultValue:'UNAUDITED', 
     },{
         xtype : "textfield", 
-        name : "pi_total", 
-        bind : "{pi_total}", 
-        fieldLabel : "总额", 
-        allowBlank : true,
-        readOnly: true,
-        columnWidth : 0.25
-    }, {
+        name : "pi_class", 
+        fieldLabel : "单据类型", 
+        readOnly:true,
+        allowBlank : false, 
+        defaultValue:'销售入库单'
+    },{
+        xtype : "hidden", 
+        name : "pi_custid",  
+        fieldLabel : "客户ID"
+    },{
         xtype : "hidden", 
-        name : "pi_said", 
-        bind : "{pi_said}", 
-        fieldLabel : "销售单id", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        name : "pi_custcode",  
+        fieldLabel : "客户编号"
     },{
         xtype : "textfield", 
-        name : "pi_sacode", 
-        bind : "{pi_sacode}", 
-        fieldLabel : "采购单号", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        name : "pi_custname",  
+        fieldLabel : "客户"
     }, {
         name : "detailGridField", 
         xtype : "detailGridField", 
+        storeModel:'saas.model.sale.ProdIODetail',
         _detnoColumn:  'pd_pdno',
         columns : [
             {
@@ -172,9 +138,6 @@ Ext.define('saas.view.sale.saleIn.FormPanel', {
             },            {
                 text : "已转数", 
                 dataIndex : "pd_yqty", 
-                editor : {
-                    xtype : "numberfield"
-                },
                 width : 120.0, 
                 xtype : "numbercolumn", 
                 format:'0',
@@ -204,6 +167,9 @@ Ext.define('saas.view.sale.saleIn.FormPanel', {
                 text : "单价", 
                 dataIndex : "pd_sendprice", 
                 width : 120.0, 
+                editor : {
+                    xtype : "numberfield"
+                },
                 xtype : "numbercolumn", 
                 items : null
             }, 
@@ -216,6 +182,9 @@ Ext.define('saas.view.sale.saleIn.FormPanel', {
                 text : "税率", 
                 dataIndex : "pd_taxrate", 
                 width : 120.0, 
+                editor : {
+                    xtype : "numberfield"
+                },
                 xtype : "numbercolumn", 
                 items : null
             },
@@ -241,38 +210,24 @@ Ext.define('saas.view.sale.saleIn.FormPanel', {
                 flex:1
             }
         ]
+    },{
+        xtype : "textfield", 
+        name : "pi_recordman", 
+        fieldLabel : "录入人",
+        readOnly:true,
     }, {
         format : "Y-m-d", 
         xtype : "datefield", 
         name : "createTime", 
-        bind : "{createTime}", 
-        fieldLabel : "创建时间", 
-        allowBlank : true, 
-        columnWidth : 0.25
-    }, {
-        xtype : "datefield", 
-        name : "updateTime", 
-        bind : "{updateTime}", 
-        fieldLabel : "更新时间", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        fieldLabel : "创建时间"
     }, {
         xtype : "textfield", 
-        readOnly : true, 
-        editable : false, 
-        name : "pi_status", 
-        bind : "{pi_status}", 
-        fieldLabel : "单据状态", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        name : "pi_auditman", 
+        fieldLabel : "过账人"
     }, {
-        xtype : "hidden", 
-        readOnly : true, 
-        editable : false, 
-        name : "pi_statuscode", 
-        bind : "{pi_statuscode}", 
-        fieldLabel : "单据状态码", 
-        allowBlank : true, 
-        columnWidth : 0.0
+        format : "Y-m-d", 
+        xtype : "datefield", 
+        name : "pi_auditman", 
+        fieldLabel : "过账时间"
     }]
 });

+ 2 - 20
frontend/saas-web/app/view/sale/saleIn/FormPanelController.js

@@ -98,24 +98,6 @@ Ext.define('saas.view.sale.saleIn.FormPanelController', {
             renderTo:this.ownerCmp.ownerCt.getEl()
         }).show();
 
-    },
-    turnOut: function() {
-        var me = this,
-        form = me.getView(),
-        id = form.getForm().findField(form._idField);
-        form.BaseUtil.request({
-            url: form._turnOutUrl+id.value,
-            method: 'GET',
-        })
-        .then(function(res) {
-            var localJson = new Ext.decode(res.responseText);
-            if(localJson.success){
-                Ext.Msg.alert('提示','转单成功');
-              
-            }
-        })
-        .catch(function() {
-            Ext.Msg.alert('提示','转单失败');
-        });
-     }
+    }
+    
 });

+ 0 - 3
frontend/saas-web/app/view/sale/saleIn/FormPanelModel.js

@@ -1,7 +1,4 @@
 Ext.define('saas.view.sale.saleIn.FormPanelModel', {
     extend: 'saas.view.core.form.FormPanelModel',
     alias: 'viewmodel.sale-salein-formpanel',
-    data: {
-        pi_class: '销售退货单'
-     }
 });

+ 12 - 5
frontend/saas-web/app/view/sale/saleIn/QueryPanel.js

@@ -77,16 +77,23 @@ Ext.define('saas.view.sale.saleIn.QueryPanel', {
                 ["AUDITED", "已审核"],
                 ["UNAUDITED", "未审核"]
             ]
-        })
+        }),
+        getCondition: function(value) {
+            if(value == 'ALL') {
+                return '1=1';
+            }else {
+                return 'pi_statuscode=\'' + value + '\'';
+            }
+        }
     }],
     moreQueryFormItems: [],
     queryGridConfig: {
         idField:'id',
         codeField:'pi_inoutno',
-        addTitle:'销售出货单',
-        addXtype:'purchase-purchaseIn-formpanel',
-        defaultCondition:' pi_class = \'销售货单\'',
-        baseVastUrl: basePath+'sale/sale/',
+        addTitle:'销售退货单',
+        addXtype:'sale-salein-formpanel',
+        defaultCondition:' pi_class = \'销售退货单\'',
+        baseVastUrl: basePath+'sale/prodinout/',
         baseColumn: [{
             text: '序号',
             width: 80,

+ 13 - 5
frontend/saas-web/app/view/sale/saleOut/FormPanel.js

@@ -6,8 +6,7 @@ Ext.define('saas.view.sale.saleout.FormPanel', {
     viewModel: 'sale-saleout-formpanel',
 
     viewName: 'sale-saleout-formpanel',
-    
-    caller:'ProdInOut!Sale',
+    caller:'SaleOut',
     
     //字段属性
     _title:'销售出货单',
@@ -23,11 +22,15 @@ Ext.define('saas.view.sale.saleout.FormPanel', {
     _auditUrl:basePath+'sale/prodinout/audit',
     _deleteUrl:basePath+'sale/prodinout/delete/',
     _deleteDetailUrl:basePath+'sale/prodinout/deleteItem/',
-    _turnInUrl:basePath+'sale/prodinout/turnProdin/',
+    _turnInUrl:basePath+'sale/prodinout/turnProdIn/',
     _turnOutUrl:basePath+'sale/prodinout/turnProdOut/',
     initId:0,
 
-    toolBtns: [],
+    toolBtns: [{
+        xtype: 'button',
+        text: '转销售验退',
+        handler: 'turnProdIn'
+    }],
 
     defaultItems: [{
         xtype: 'hidden',
@@ -49,7 +52,8 @@ Ext.define('saas.view.sale.saleout.FormPanel', {
         bind : "{pi_class}", 
         fieldLabel : "单据类型", 
         readOnly:true,
-        allowBlank : true, 
+        allowBlank : false, 
+        defaultValue:'销售出货单',
         columnWidth : 0.25
     }, {
         xtype : "hidden", 
@@ -112,6 +116,7 @@ Ext.define('saas.view.sale.saleout.FormPanel', {
     },{
         name : "detailGridField", 
         xtype : "detailGridField", 
+        storeModel:'saas.model.sale.ProdIODetail',
         _detnoColumn:  'pd_pdno',
         columns : [
             {
@@ -194,6 +199,9 @@ Ext.define('saas.view.sale.saleout.FormPanel', {
             {
                 text : "单价", 
                 dataIndex : "pd_sendprice", 
+                editor : {
+                    xtype : "numberfield"
+                },
                 width : 120.0, 
                 xtype : "numbercolumn", 
                 items : null

+ 20 - 1
frontend/saas-web/app/view/sale/saleOut/FormPanelController.js

@@ -93,5 +93,24 @@ Ext.define('saas.view.sale.saleout.FormPanelController', {
             renderTo:this.ownerCmp.ownerCt.getEl()
         }).show();
 
-    }
+    },
+    turnProdIn: function() {
+        var me = this,
+        form = me.getView(),
+        id = form.getForm().findField(form._idField);
+        form.BaseUtil.request({
+            url: form._turnInUrl+id.value,
+            method: 'GET',
+        })
+        .then(function(res) {
+            var localJson = new Ext.decode(res.responseText);
+            if(localJson.success){
+                Ext.Msg.alert('提示','转单成功');
+              
+            }
+        })
+        .catch(function() {
+            Ext.Msg.alert('提示','转单失败');
+        });
+     }
 });

+ 1 - 4
frontend/saas-web/app/view/sale/saleOut/FormPanelModel.js

@@ -1,8 +1,5 @@
 Ext.define('saas.view.sale.saleout.FormPanelModel', {
     extend: 'saas.view.core.form.FormPanelModel',
     alias: 'viewmodel.sale-saleout-formpanel',
-    
-    data: {
-        pi_class: '销售出货单'
-     }
+
 });

+ 9 - 3
frontend/saas-web/app/view/sale/saleOut/QueryPanel.js

@@ -63,7 +63,6 @@ Ext.define('saas.view.sale.saleout.QueryPanel', {
     }, {
         xtype: 'combobox',
         name: 'pi_statuscode',
-        bind: '{pi_statuscode}',
         fieldLabel: '审核状态',
         allowBlank: true,
         columnWidth: 0.25,
@@ -77,7 +76,14 @@ Ext.define('saas.view.sale.saleout.QueryPanel', {
                 ["AUDITED", "已审核"],
                 ["UNAUDITED", "未审核"]
             ]
-        })
+        }),
+        getCondition: function(value) {
+            if(value == 'ALL') {
+                return '1=1';
+            }else {
+                return 'pi_statuscode=\'' + value + '\'';
+            }
+        }
     }],
     moreQueryFormItems: [],
     queryGridConfig: {
@@ -86,7 +92,7 @@ Ext.define('saas.view.sale.saleout.QueryPanel', {
         addTitle:'销售出货单',
         addXtype:'sale-saleout-formpanel',
         defaultCondition:' pi_class = \'销售出货单\'',
-        baseVastUrl: basePath+'sale/sale/',
+        baseVastUrl: basePath+'sale/prodinout/',
         baseColumn: [{
             text: '序号',
             width: 80,

+ 14 - 27
frontend/saas-web/app/view/stock/appropriationInOut/FormPanel.js

@@ -5,6 +5,9 @@ Ext.define('saas.view.stock.appropriationInOut.FormPanel', {
     controller: 'stock-appropriationinout-formpanel',
     viewModel: 'stock-appropriationinout-formpanel',
     
+    viewName: 'stock-appropriationinout-formpanel',
+    caller:'AppropriationInOut',
+
      //字段属性
      _title:'调拨单',
      _idField: 'id',
@@ -13,49 +16,33 @@ Ext.define('saas.view.stock.appropriationInOut.FormPanel', {
      _statusCodeField: 'pi_statuscode',
      
      _relationColumn: 'pd_piid',
-     _readUrl:'http://localhost:9000/prodinout/read/',
-     _saveUrl:'http://localhost:9000/prodinout/save',
-     _auditUrl:'http://localhost:9000/prodinout/audit',
-     _deleteUrl:'http://localhost:9000/prodinout/delete/',
-     _deleteDetailUrl:'http://localhost:9000/prodinout/deleteItem/',
+     _readUrl:basePath+'storage/prodinout/read/',
+     _saveUrl:basePath+'storage/prodinout/save',
+     _auditUrl:basePath+'storage/prodinout/audit',
+     _deleteUrl:basePath+'storage/prodinout/delete/',
+     _deleteDetailUrl:basePath+'storage/prodinout/deleteItem/',
      initId:0,
- 
-     toolBtns: [],
 
     defaultItems: [{
         xtype: 'hidden',
         name: 'id',
-        bind: '{id}',
         fieldLabel: 'id',
-        allowBlank: true,
         columnWidth: 0
-    },{
-        xtype : "textfield", 
-        name : "pi_inoutno", 
-        bind : "{pi_inoutno}", 
-        fieldLabel : "调拨单号", 
-        allowBlank : true, 
-        columnWidth : 0.25
     },{
         xtype : "textfield", 
         name : "pi_class", 
-        bind : "{pi_class}", 
         fieldLabel : "单据类型", 
         readOnly:true,
-        allowBlank : true,
-        hidden:true,
-        defaultValue:"调拨单", 
-        columnWidth : 0.25
+        allowBlank : false, 
+        defaultValue:'调拨单'
     },{
-        xtype : "datefield", 
-        name : "pi_date", 
-        bind : "{pi_date}", 
-        fieldLabel : "单据日期", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        xtype : "hidden", 
+        name : "pi_total",  
+        fieldLabel : "单据金额"
     },{
         name : "detailGridField", 
         xtype : "detailGridField", 
+        storeModel:'saas.model.stock.ProdIODetail',
         _detnoColumn:  'pd_pdno',
         columns : [
             {

+ 2 - 2
frontend/saas-web/app/view/stock/appropriationInOut/FormPanelController.js

@@ -15,7 +15,7 @@ Ext.define('saas.view.stock.appropriationInOut.FormPanelController', {
             'dbfindtrigger[name=pu_vendcode]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -67,7 +67,7 @@ Ext.define('saas.view.stock.appropriationInOut.FormPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode'
                         }],

+ 1 - 4
frontend/saas-web/app/view/stock/appropriationInOut/FormPanelModel.js

@@ -1,8 +1,5 @@
 Ext.define('saas.view.stock.appropriationInOut.FormPanelModel', {
     extend: 'saas.view.core.form.FormPanelModel',
-    alias: 'viewmodel.stock-appropriationinout-formpanel',
-    data: {
-        pi_class: '调拨单'
-     }
+    alias: 'viewmodel.stock-appropriationinout-formpanel'
 
 });

+ 16 - 16
frontend/saas-web/app/view/stock/appropriationInOut/QueryPanel.js

@@ -16,37 +16,31 @@ Ext.define('saas.view.stock.appropriationInOut.QueryPanel', {
         columnWidth: 0
     }, {
         xtype: 'textfield',
-        name: 'pi_inoutno',
-        bind: '{pi_inoutno}',
+        name: 'pu_code',
         fieldLabel: '单据编号',
         allowBlank: true,
         columnWidth: 0.25
     }, {
         xtype: 'condatefield',
-        name: 'pi_date',
-        bind: '{pi_date}',
+        name: 'pu_date',
         fieldLabel: '采购日期',
         allowBlank: true,
         columnWidth: 0.5
     }, {
         xtype: 'dbfindtrigger',
         name: 'pu_vendcode',
-        bind: '{pu_vendcode}',
         fieldLabel: '供应商编号',
         allowBlank: true,
         columnWidth: 0.25
     }, {
         xtype: 'textfield',
         name: 'pu_vendname',
-        bind: '{pu_vendname}',
         fieldLabel: '供应商名称',
         allowBlank: true,
         columnWidth: 0.25
     }, {
         xtype: 'dbfindtrigger',
         name: 'pd_prodcode#pd_prodcode',
-        //#pr_detail
-        bind: '{pd_prodcode}',
         fieldLabel: '物料编号',
         fieldMode: 'DETAIL',
         queryType: 'VAG',
@@ -62,7 +56,6 @@ Ext.define('saas.view.stock.appropriationInOut.QueryPanel', {
     }, {
         xtype: 'combobox',
         name: 'pu_statuscode',
-       // bind: '{pu_statuscode}',
         fieldLabel: '审核状态',
         allowBlank: true,
         columnWidth: 0.25,
@@ -73,11 +66,18 @@ Ext.define('saas.view.stock.appropriationInOut.QueryPanel', {
         store: Ext.create('Ext.data.ArrayStore', {
         fields: ['pu_statuscode', 'pu_status'],
         data: [
-            ["$ALL", "全部"],
+            ["ALL", "全部"],
             ["AUDITED", "已审核"],
             ["UNAUDITED", "未审核"]
         ]
-        })
+        }),
+        getCondition: function(value) {
+            if(value == 'ALL') {
+                return '1=1';
+            }else {
+                return 'pi_statuscode=\'' + value + '\'';
+            }
+        }
     }, {
         xtype: 'multicombo',
         name: 'pu_acceptstatuscode',
@@ -112,12 +112,12 @@ Ext.define('saas.view.stock.appropriationInOut.QueryPanel', {
         columnWidth: 1
     }],
     queryGridConfig: {
-        idField: 'id',
-        codeField: 'pi_inoutno',
-        addTitle: '其它入库单',
+        idField: 'pu_id',
+        codeField: 'pu_code',
+        addTitle: '调拨单',
         addXtype: 'stock-appropriationinout-formpanel',
-        defaultCondition:' pi_class = \'其它入库单\'',
-        baseVastUrl: 'http://localhost:9000/prodinout/',
+        defaultCondition:' pi_class = \'调拨单\'',
+        baseVastUrl: basePath+'storage/prodinout/',
         baseColumn: [{
             text: '序号',
             width: 80,

+ 2 - 2
frontend/saas-web/app/view/stock/appropriationInOut/QueryPanelController.js

@@ -8,7 +8,7 @@ Ext.define('saas.view.stock.appropriationInOut.QueryPanelController', {
             'dbfindtrigger[name=pu_vendname]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -60,7 +60,7 @@ Ext.define('saas.view.stock.appropriationInOut.QueryPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode',
                             from:'pr_detail',to:'pr_detail'

+ 28 - 86
frontend/saas-web/app/view/stock/otherIn/FormPanel.js

@@ -5,6 +5,9 @@ Ext.define('saas.view.stock.otherIn.FormPanel', {
     controller: 'stock-otherin-formpanel',
     viewModel: 'stock-otherin-formpanel',
     
+    viewName: 'stock-otherin-formpanel',
+    caller:'OtherIn',
+
      //字段属性
      _title:'其它入库单',
      _idField: 'id',
@@ -13,82 +16,35 @@ Ext.define('saas.view.stock.otherIn.FormPanel', {
      _statusCodeField: 'pi_statuscode',
      
      _relationColumn: 'pd_piid',
-     _readUrl:'http://localhost:9000/prodinout/read/',
-     _saveUrl:'http://localhost:9000/prodinout/save',
-     _auditUrl:'http://localhost:9000/prodinout/audit',
-     _deleteUrl:'http://localhost:9000/prodinout/delete/',
-     _deleteDetailUrl:'http://localhost:9000/prodinout/deleteItem/',
-     _turnInUrl:'http://localhost:9000/prodinout/turnProdin/',
-     initId:0,
+    _readUrl:basePath+'storage/prodinout/read/',
+    _saveUrl:basePath+'storage/prodinout/save',
+    _auditUrl:basePath+'storage/prodinout/audit',
+    _deleteUrl:basePath+'storage/prodinout/delete/',
+    _deleteDetailUrl:basePath+'storage/prodinout/deleteItem/',
+    initId:0,
  
-     toolBtns: [{
-         xtype: 'button',
-         text: '转其他出库',
-         handler: 'turnIn'
-     }],
+    toolBtns: [],
 
     defaultItems: [{
         xtype: 'hidden',
         name: 'id',
-        bind: '{id}',
         fieldLabel: 'id',
-        allowBlank: true,
         columnWidth: 0
-    },{
-        xtype : "textfield", 
-        name : "pi_inoutno", 
-        bind : "{pi_inoutno}", 
-        fieldLabel : "入库单号", 
-        allowBlank : true, 
-        columnWidth : 0.25
     },{
         xtype : "textfield", 
         name : "pi_class", 
-        bind : "{pi_class}", 
         fieldLabel : "单据类型", 
-        readOnly:false,
-        allowBlank : true,
-        defaultValue:"其它入库单",
-        columnWidth : 0.25
+        readOnly:true,
+        allowBlank : false, 
+        defaultValue:'其它入库单'
     },{
         xtype : "hidden", 
-        name : "pi_vendid", 
-        bind : "{pi_vendid}", 
-        fieldLabel : "供应商ID", 
-        allowBlank : true, 
-        columnWidth : 0.0
-    }, {
-        xtype : "textfield", 
-        name : "pi_vendcode", 
-        bind : "{pi_vendcode}", 
-        fieldLabel : "供应商编号", 
-        hidden:true,
-        allowBlank : true, 
-        columnWidth : 0, 
-    }, {
-        xtype : "dbfindtrigger", 
-        name : "pi_vendname", 
-        bind : "{pi_vendname}", 
-        fieldLabel : "供应商名称", 
-        allowBlank : true, 
-        columnWidth : 0.25
-    }, {
-        xtype : "datefield", 
-        name : "pi_date", 
-        bind : "{pi_date}", 
-        fieldLabel : "单据日期", 
-        allowBlank : true, 
-        columnWidth : 0.25
-    },{
-        xtype : "numberfield", 
-        name : "pi_total", 
-        bind : "{pi_total}", 
-        fieldLabel : "单据金额", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        name : "pi_total",  
+        fieldLabel : "单据金额"
     }, {
         name : "detailGridField", 
         xtype : "detailGridField", 
+        storeModel:'saas.model.stock.ProdIODetail',
         _detnoColumn:  'pd_pdno',
         columns : [
             {
@@ -218,38 +174,24 @@ Ext.define('saas.view.stock.otherIn.FormPanel', {
                 flex : 1.0
             }
         ]
+    },{
+        xtype : "textfield", 
+        name : "pi_recordman", 
+        fieldLabel : "录入人",
+        readOnly:true,
     }, {
         format : "Y-m-d", 
         xtype : "datefield", 
         name : "createTime", 
-        bind : "{createTime}", 
-        fieldLabel : "创建时间", 
-        allowBlank : true, 
-        columnWidth : 0.25
-    }, {
-        xtype : "datefield", 
-        name : "updateTime", 
-        bind : "{updateTime}", 
-        fieldLabel : "更新时间", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        fieldLabel : "创建时间"
     }, {
         xtype : "textfield", 
-        readOnly : true, 
-        editable : false, 
-        name : "pu_status", 
-        bind : "{pi_status}", 
-        fieldLabel : "单据状态", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        name : "pi_auditman", 
+        fieldLabel : "过账人"
     }, {
-        xtype : "hidden", 
-        readOnly : true, 
-        editable : false, 
-        name : "pi_statuscode", 
-        bind : "{pi_statuscode}", 
-        fieldLabel : "单据状态码", 
-        allowBlank : true, 
-        columnWidth : 0.0
+        format : "Y-m-d", 
+        xtype : "datefield", 
+        name : "pi_auditman", 
+        fieldLabel : "过账时间"
     }]
 });

+ 2 - 2
frontend/saas-web/app/view/stock/otherIn/FormPanelController.js

@@ -15,7 +15,7 @@ Ext.define('saas.view.stock.otherIn.FormPanelController', {
             'dbfindtrigger[name=pu_vendcode]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -67,7 +67,7 @@ Ext.define('saas.view.stock.otherIn.FormPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode'
                         }],

+ 0 - 4
frontend/saas-web/app/view/stock/otherIn/FormPanelModel.js

@@ -1,8 +1,4 @@
 Ext.define('saas.view.stock.otherIn.FormPanelModel', {
     extend: 'saas.view.core.form.FormPanelModel',
     alias: 'viewmodel.stock-otherin-formpanel',
-    data: {
-        pi_class: '其它入库单'
-     }
-
 });

+ 77 - 95
frontend/saas-web/app/view/stock/otherIn/QueryPanel.js

@@ -25,99 +25,75 @@ Ext.define('saas.view.stock.otherIn.QueryPanel', {
         xtype: 'condatefield',
         name: 'pi_date',
         bind: '{pi_date}',
-        fieldLabel: '采购日期',
+        fieldLabel: '单据日期',
         allowBlank: true,
         columnWidth: 0.5
     }, {
-        xtype: 'dbfindtrigger',
-        name: 'pu_vendcode',
-        bind: '{pu_vendcode}',
+        xtype: 'textfield',
+        name: 'pi_vendcode',
+        bind: '{pi_vendcode}',
         fieldLabel: '供应商编号',
         allowBlank: true,
+        hidden:true,
         columnWidth: 0.25
     }, {
         xtype: 'textfield',
-        name: 'pu_vendname',
-        bind: '{pu_vendname}',
+        name: 'pi_vendname',
+        bind: '{pi_vendname}',
         fieldLabel: '供应商名称',
         allowBlank: true,
         columnWidth: 0.25
     }, {
         xtype: 'dbfindtrigger',
-        name: 'pd_prodcode#pd_prodcode',
-        //#pr_detail
+        name: 'pd_prodcode',
         bind: '{pd_prodcode}',
         fieldLabel: '物料编号',
         fieldMode: 'DETAIL',
-        queryType: 'VAG',
+        queryType:'VAG',
+        hidden:true,
         allowBlank: true,
         columnWidth: 0.25
     }, {
-        xtype: 'textfield',
-        name: 'pr_detail',
+        xtype: 'dbfindtrigger',
+        name: 'pr_detail#pd_prodcode',
         bind: '{pr_detail}',
         fieldLabel: '物料名称',
         allowBlank: true,
         columnWidth: 0.25
     }, {
         xtype: 'combobox',
-        name: 'pu_statuscode',
-       // bind: '{pu_statuscode}',
+        name: 'pi_statuscode',
+        bind: '{pi_statuscode}',
         fieldLabel: '审核状态',
         allowBlank: true,
         columnWidth: 0.25,
         queryMode: 'local',
-        displayField: 'pu_status',
-        valueField: 'pu_statuscode',
-        editable:false,
+        displayField: 'pi_status',
+        valueField: 'pi_statuscode',
         store: Ext.create('Ext.data.ArrayStore', {
-        fields: ['pu_statuscode', 'pu_status'],
-        data: [
-            ["$ALL", "全部"],
-            ["AUDITED", "已审核"],
-            ["UNAUDITED", "未审核"]
-        ]
-        })
-    }, {
-        xtype: 'multicombo',
-        name: 'pu_acceptstatuscode',
-        bind: '{pu_acceptstatuscode}',
-        fieldLabel: '入库状态',
-        allowBlank: true,
-        columnWidth: 0.25,
-        datas: [
-            ["TURNIN", "已入库"],
-            ["UNTURNIN", "未入库"],
-            ["PARTIN", "部分入库"]
-        ]
-    }],
-    moreQueryFormItems: [{
-        xtype: 'textfield',
-        name: 'pu_buyername',
-        bind: '{pu_buyername}',
-        fieldLabel: '采购员',
-        allowBlank: true
-    }, {
-        xtype: 'textfield',
-        name: 'pu_total',
-        bind: '{pu_total}',
-        fieldLabel: '金额',
-        allowBlank: true
-    }, {
-        xtype: 'condatefield',
-        name: 'pu_delivery',
-        bind: '{pu_delivery}',
-        fieldLabel: '交货日期',
-        allowBlank: true,
-        columnWidth: 1
+            fields: ['pi_statuscode', 'pi_status'],
+            data: [
+                ["ALL", "全部"],
+                ["AUDITED", "已审核"],
+                ["UNAUDITED", "未审核"]
+            ]
+        }),
+        getCondition: function(value) {
+            if(value == 'ALL') {
+                return '1=1';
+            }else {
+                return 'pi_statuscode=\'' + value + '\'';
+            }
+        }
     }],
+    moreQueryFormItems: [],
     queryGridConfig: {
         idField: 'id',
         codeField: 'pi_inoutno',
         addTitle: '其它入库单',
         addXtype: 'stock-otherin-formpanel',
         defaultCondition:' pi_class = \'其它入库单\'',
-        baseVastUrl: 'http://localhost:9000/prodinout/',
+        baseVastUrl: basePath+'storage/prodinout/',
         baseColumn: [{
             text: '序号',
             width: 80,
@@ -135,78 +111,84 @@ Ext.define('saas.view.stock.otherIn.QueryPanel', {
             text: '单据状态',
             dataIndex: 'pi_status',
             width: 120
+        }, {
+            text: '单据类型',
+            dataIndex: 'pi_class',
+            width: 120
         }, {
             text: '下单日期',
             dataIndex: 'pi_date',
-            xtype: 'datecolumn',
+            xtype:'datecolumn',
             width: 200
-        }, {
+        },{
             text: '供应商名称',
-            dataIndex: 'pu_vendname',
+            dataIndex: 'pi_vendname',
             width: 120
-        }, {
+        },{
             text: '含税金额',
-            dataIndex: 'pu_taxtotal',
-            xtype: 'numbercolumn',
+            dataIndex: 'pi_total',
+            xtype:'numbercolumn',
             width: 120
-        }, {
-            text: '金额',
-            dataIndex: 'pu_total',
-            xtype: 'numbercolumn',
+        },{
+            text: '不含税金额',
+            dataIndex: 'pi_nettotal',
+            xtype:'numbercolumn',
             width: 120,
             flex: 1
         }],
         relativeColumn: [{
-            text: '序号',
-            width: 80,
-            xtype: 'rownumberer'
+            text : "序号", 
+            dataIndex : "pd_pdno", 
+            width : 100, 
+            xtype : "numbercolumn",
+            align : 'center'
         }, {
             text: 'id',
-            dataIndex: 'id',
-            width: 100,
+            dataIndex: 'pu_id',
+            width: 0,
             xtype: 'numbercolumn'
         }, {
             text: '单据编号',
-            dataIndex: 'pu_code',
+            dataIndex: 'pd_inoutno',
             width: 120
         }, {
             text: '单据状态',
-            dataIndex: 'pu_status',
+            dataIndex: 'pi_status',
             width: 120
         }, {
             text: '下单日期',
-            dataIndex: 'pu_indate',
-            xtype: 'datecolumn',
+            dataIndex: 'pi_date',
+            xtype:'datecolumn',
             width: 200
-        }, {
+        },{
             text: '供应商名称',
-            dataIndex: 'pu_vendname',
+            dataIndex: 'pi_vendname',
             width: 120
-        }, {
-            text: '采购序号',
-            dataIndex: 'pd_detno',
-            xtype: 'numbercolumn',
-            width: 120
-        }, {
+        },{
             text: '物料编号',
             dataIndex: 'pd_prodcode',
             width: 120
-        }, {
-            text: '数量',
-            dataIndex: 'pd_qty',
-            xtype: 'numbercolumn',
+        },{
+            text: '入库数量',
+            dataIndex: 'pd_inqty',
+            xtype:'numbercolumn',
             width: 120
-        }, {
-            text: '单价',
+        },{
+            text: '成本单价',
             dataIndex: 'pd_price',
-            xtype: 'numbercolumn',
-            width: 120
-        }, {
-            text: '已转数',
-            dataIndex: 'pd_ytqy',
-            xtype: 'numbercolumn',
+            xtype:'numbercolumn',
             width: 120,
             flex: 1
+        },{
+            text: '金额',
+            dataIndex: 'pd_total',
+            xtype:'numbercolumn',
+            width: 120
+        },{
+            text: '税率',
+            dataIndex: 'pd_taxrate',
+            xtype:'numbercolumn',
+            width: 120
         }]
     }
 });

+ 2 - 2
frontend/saas-web/app/view/stock/otherIn/QueryPanelController.js

@@ -8,7 +8,7 @@ Ext.define('saas.view.stock.otherIn.QueryPanelController', {
             'dbfindtrigger[name=pu_vendname]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -60,7 +60,7 @@ Ext.define('saas.view.stock.otherIn.QueryPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode',
                             from:'pr_detail',to:'pr_detail'

+ 14 - 55
frontend/saas-web/app/view/stock/otherOut/FormPanel.js

@@ -5,20 +5,22 @@ Ext.define('saas.view.stock.otherOut.FormPanel', {
     controller: 'stock-otherout-formpanel',
     viewModel: 'stock-otherout-formpanel',
     
+    viewName: 'stock-otherout-formpanel',
+    caller:'OtherOut',
+
      //字段属性
-     _title:'其它入库单',
+     _title:'其它库单',
      _idField: 'id',
      _codeField: 'pi_inoutno',
      _statusField: 'pi_status',
      _statusCodeField: 'pi_statuscode',
      
      _relationColumn: 'pd_piid',
-     _readUrl:'http://localhost:9000/prodinout/read/',
-     _saveUrl:'http://localhost:9000/prodinout/save',
-     _auditUrl:'http://localhost:9000/prodinout/audit',
-     _deleteUrl:'http://localhost:9000/prodinout/delete/',
-     _deleteDetailUrl:'http://localhost:9000/prodinout/deleteItem/',
-     _turnInUrl:'http://localhost:9000/prodinout/turnProdin/',
+     _readUrl:basePath+'storage/prodinout/read/',
+    _saveUrl:basePath+'storage/prodinout/save',
+    _auditUrl:basePath+'storage/prodinout/audit',
+    _deleteUrl:basePath+'storage/prodinout/delete/',
+    _deleteDetailUrl:basePath+'storage/prodinout/deleteItem/',
      initId:0,
  
      toolBtns: [],
@@ -26,66 +28,23 @@ Ext.define('saas.view.stock.otherOut.FormPanel', {
     defaultItems: [{
         xtype: 'hidden',
         name: 'id',
-        bind: '{id}',
         fieldLabel: 'id',
-        allowBlank: true,
         columnWidth: 0
-    },{
-        xtype : "textfield", 
-        name : "pi_inoutno", 
-        bind : "{pi_inoutno}", 
-        fieldLabel : "出库单号", 
-        allowBlank : true, 
-        columnWidth : 0.25
     },{
         xtype : "textfield", 
         name : "pi_class", 
-        bind : "{pi_class}", 
         fieldLabel : "单据类型", 
         readOnly:true,
-        allowBlank : true,
-        hidden:true, 
-        defaultValue:"其它出库单",
-        columnWidth : 0.25
+        allowBlank : false, 
+        defaultValue:'其它出库单'
     },{
         xtype : "hidden", 
-        name : "pi_vendid", 
-        bind : "{pi_vendid}", 
-        fieldLabel : "供应商ID", 
-        allowBlank : true, 
-        columnWidth : 0.0
-    }, {
-        xtype : "textfield", 
-        name : "pi_vendcode", 
-        bind : "{pi_vendcode}", 
-        fieldLabel : "供应商编号", 
-        hidden:true,
-        allowBlank : true, 
-        columnWidth : 0, 
-    }, {
-        xtype : "dbfindtrigger", 
-        name : "pi_vendname", 
-        bind : "{pi_vendname}", 
-        fieldLabel : "供应商名称", 
-        allowBlank : true, 
-        columnWidth : 0.25
-    }, {
-        xtype : "datefield", 
-        name : "pi_date", 
-        bind : "{pi_date}", 
-        fieldLabel : "单据日期", 
-        allowBlank : true, 
-        columnWidth : 0.25
-    },{
-        xtype : "numberfield", 
-        name : "pi_total", 
-        bind : "{pi_total}", 
-        fieldLabel : "单据金额", 
-        allowBlank : true, 
-        columnWidth : 0.25
+        name : "pi_total",  
+        fieldLabel : "单据金额"
     }, {
         name : "detailGridField", 
         xtype : "detailGridField", 
+        storeModel:'saas.model.stock.ProdIODetail',
         _detnoColumn:  'pd_pdno',
         columns : [
             {

+ 2 - 2
frontend/saas-web/app/view/stock/otherOut/FormPanelController.js

@@ -14,7 +14,7 @@ Ext.define('saas.view.stock.otherOut.FormPanelController', {
             'dbfindtrigger[name=pu_vendcode]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -66,7 +66,7 @@ Ext.define('saas.view.stock.otherOut.FormPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode'
                         }],

+ 6 - 25
frontend/saas-web/app/view/stock/otherOut/QueryPanel.js

@@ -91,33 +91,14 @@ Ext.define('saas.view.stock.otherOut.QueryPanel', {
             ["PARTIN", "部分入库"]
         ]
     }],
-    moreQueryFormItems: [{
-        xtype: 'textfield',
-        name: 'pu_buyername',
-        bind: '{pu_buyername}',
-        fieldLabel: '采购员',
-        allowBlank: true
-    }, {
-        xtype: 'textfield',
-        name: 'pu_total',
-        bind: '{pu_total}',
-        fieldLabel: '金额',
-        allowBlank: true
-    }, {
-        xtype: 'condatefield',
-        name: 'pu_delivery',
-        bind: '{pu_delivery}',
-        fieldLabel: '交货日期',
-        allowBlank: true,
-        columnWidth: 1
-    }],
+    moreQueryFormItems: [],
     queryGridConfig: {
-        idField: 'id',
-        codeField: 'pi_inoutno',
-        addTitle: '其它库单',
+        idField: 'pu_id',
+        codeField: 'pu_code',
+        addTitle: '其它出库单',
         addXtype: 'stock-otherout-formpanel',
-        defaultCondition:' pi_class = \'其它库单\'',
-        baseVastUrl: 'http://localhost:9000/prodinout/',
+        defaultCondition:' pi_class = \'其它出库单\'',
+        baseVastUrl: basePath+'storage/prodinout/',
         baseColumn: [{
             text: '序号',
             width: 80,

+ 2 - 2
frontend/saas-web/app/view/stock/otherOut/QueryPanelController.js

@@ -8,7 +8,7 @@ Ext.define('saas.view.stock.otherOut.QueryPanelController', {
             'dbfindtrigger[name=pu_vendname]':{
                 beforerender:function(f){
                     Ext.apply(f,{
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
                         },{
@@ -60,7 +60,7 @@ Ext.define('saas.view.stock.otherOut.QueryPanelController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         conditionCode:'pr_code',
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode',
                             from:'pr_detail',to:'pr_detail'

+ 3 - 3
frontend/saas-web/app/view/test/order/FormController.js

@@ -16,7 +16,7 @@ Ext.define('saas.view.test.order.FormController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         //数据接口
-                        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+                        dataUrl:basePath + 'document/vendor/getVendorsByCondition',
                         //赋值 
                         dbfinds:[{
                             from:'ve_code',to:'pu_vendcode'
@@ -77,7 +77,7 @@ Ext.define('saas.view.test.order.FormController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         //数据接口
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         //放大镜赋值设置
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode'
@@ -139,7 +139,7 @@ Ext.define('saas.view.test.order.FormController', {
                 beforerender:function(f){
                     Ext.apply(f,{
                         //数据接口
-                        dataUrl:'http://192.168.253.41:9480/api/document/product/getProductsByCondition',
+                        dataUrl:basePath + 'document/product/getProductsByCondition',
                         //放大镜赋值设置
                         dbfinds:[{
                             from:'pr_code',to:'pd_prodcode'

+ 8 - 8
frontend/saas-web/app/view/test/order/FormPanel.js

@@ -15,11 +15,11 @@ Ext.define('saas.view.test.order.FormPanel', {
     _statusCodeField: 'pu_statuscode',
     _detnoColumn:  'pd_detno',
     _relationColumn: 'pd_puid',
-    _readUrl:'http://192.168.253.228:8800/purchase/read/',
-    _saveUrl:'http://192.168.253.228:8800/purchase/save',
-    _auditUrl:'http://192.168.253.228:8800/purchase/audit',
-    _deleteUrl:'http://192.168.253.228:8800/purchase/delete/',
-    _deleteDetailUrl:'http://192.168.253.228:8800/purchase/deleteItem/',
+    _readUrl:basePath + 'purchase/purchase/read/',
+    _saveUrl:basePath + 'purchase/purchase/save',
+    _auditUrl:basePath + 'purchase/purchase/audit',
+    _deleteUrl:basePath + 'purchase/purchase/delete/',
+    _deleteDetailUrl:basePath + 'purchase/purchase/deleteItem/',
     initId:0,
 
     toolBtns: [{
@@ -114,7 +114,7 @@ Ext.define('saas.view.test.order.FormPanel', {
         columnWidth : 0.25
     },{
         xtype : "remotecombo", 
-        storeUrl:"http://192.168.253.41:9480/api/document/product/getProdUnit",
+        storeUrl:basePath+'ducument/product/getProdUnit',
         name : "pu_text1", 
         bind : "{pu_text1}", 
         fieldLabel : "供应商类型", 
@@ -127,8 +127,8 @@ Ext.define('saas.view.test.order.FormPanel', {
             vendorkind:{
                 keyField:'id',
                 dataField:'vk_name',
-                reqUrl:'http://192.168.253.41:9480/api/document/vendorkind/save',
-                delUrl:'http://192.168.253.41:9480/api/document/vendorkind/delete'
+                reqUrl:basePath+'ducument/vendorkind/save',
+                delUrl:basePath+'ducument/vendorkind/delete'
             }
         },
         addHandler:function(b){

+ 3 - 3
frontend/saas-web/app/view/test/query/QueryPanel.js

@@ -6,7 +6,7 @@ Ext.define('saas.view.test.query.QueryPanel', {
     viewModel: 'test-query-querypanel',
     
     viewName: 'test-query-formpanel',
-    _baseVastUrl:'http://192.168.253.58:8800/purchase/',
+    _baseVastUrl:basePath+'purchase/',
     _idField:'pu_id',
     _codeField:'pu_code',
     queryFormItems: [{
@@ -23,7 +23,7 @@ Ext.define('saas.view.test.query.QueryPanel', {
         fieldLabel: '单据编号',
         allowBlank: true,
         columnWidth: 0.25,
-        dataUrl:'http://192.168.253.41:9480/api/document/vendor/getVendorsByCondition',
+        dataUrl:basePath+'ducument/vendor/getVendorsByCondition',
         dbfinds:[{
             from:'ve_code',to:'pu_code'
         }],
@@ -157,7 +157,7 @@ Ext.define('saas.view.test.query.QueryPanel', {
         _codeField:'pu_code',
         _title:'采购单',
         _addXtype:'test-order-formpanel',
-        _baseVastUrl:'http://192.168.253.58:8800/purchase/',
+        _baseVastUrl:basePath+'purchase/',
         _baseColumn: [{
             text: '序号',
             width: 80,