系统功能细节优化

This commit is contained in:
季圣华
2020-02-18 13:23:37 +08:00
parent 05dbdf8964
commit 3f76280df0
10 changed files with 47 additions and 248 deletions

View File

@@ -10,8 +10,6 @@ public class DepotHead {
private String subtype;
private Long projectid;
private String defaultnumber;
private String number;
@@ -30,8 +28,6 @@ public class DepotHead {
private BigDecimal changeamount;
private Long allocationprojectid;
private BigDecimal totalprice;
private String paytype;
@@ -90,14 +86,6 @@ public class DepotHead {
this.subtype = subtype == null ? null : subtype.trim();
}
public Long getProjectid() {
return projectid;
}
public void setProjectid(Long projectid) {
this.projectid = projectid;
}
public String getDefaultnumber() {
return defaultnumber;
}
@@ -170,14 +158,6 @@ public class DepotHead {
this.changeamount = changeamount;
}
public Long getAllocationprojectid() {
return allocationprojectid;
}
public void setAllocationprojectid(Long allocationprojectid) {
this.allocationprojectid = allocationprojectid;
}
public BigDecimal getTotalprice() {
return totalprice;
}

View File

@@ -306,66 +306,6 @@ public class DepotHeadExample {
return (Criteria) this;
}
public Criteria andProjectidIsNull() {
addCriterion("ProjectId is null");
return (Criteria) this;
}
public Criteria andProjectidIsNotNull() {
addCriterion("ProjectId is not null");
return (Criteria) this;
}
public Criteria andProjectidEqualTo(Long value) {
addCriterion("ProjectId =", value, "projectid");
return (Criteria) this;
}
public Criteria andProjectidNotEqualTo(Long value) {
addCriterion("ProjectId <>", value, "projectid");
return (Criteria) this;
}
public Criteria andProjectidGreaterThan(Long value) {
addCriterion("ProjectId >", value, "projectid");
return (Criteria) this;
}
public Criteria andProjectidGreaterThanOrEqualTo(Long value) {
addCriterion("ProjectId >=", value, "projectid");
return (Criteria) this;
}
public Criteria andProjectidLessThan(Long value) {
addCriterion("ProjectId <", value, "projectid");
return (Criteria) this;
}
public Criteria andProjectidLessThanOrEqualTo(Long value) {
addCriterion("ProjectId <=", value, "projectid");
return (Criteria) this;
}
public Criteria andProjectidIn(List<Long> values) {
addCriterion("ProjectId in", values, "projectid");
return (Criteria) this;
}
public Criteria andProjectidNotIn(List<Long> values) {
addCriterion("ProjectId not in", values, "projectid");
return (Criteria) this;
}
public Criteria andProjectidBetween(Long value1, Long value2) {
addCriterion("ProjectId between", value1, value2, "projectid");
return (Criteria) this;
}
public Criteria andProjectidNotBetween(Long value1, Long value2) {
addCriterion("ProjectId not between", value1, value2, "projectid");
return (Criteria) this;
}
public Criteria andDefaultnumberIsNull() {
addCriterion("DefaultNumber is null");
return (Criteria) this;
@@ -936,66 +876,6 @@ public class DepotHeadExample {
return (Criteria) this;
}
public Criteria andAllocationprojectidIsNull() {
addCriterion("AllocationProjectId is null");
return (Criteria) this;
}
public Criteria andAllocationprojectidIsNotNull() {
addCriterion("AllocationProjectId is not null");
return (Criteria) this;
}
public Criteria andAllocationprojectidEqualTo(Long value) {
addCriterion("AllocationProjectId =", value, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidNotEqualTo(Long value) {
addCriterion("AllocationProjectId <>", value, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidGreaterThan(Long value) {
addCriterion("AllocationProjectId >", value, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidGreaterThanOrEqualTo(Long value) {
addCriterion("AllocationProjectId >=", value, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidLessThan(Long value) {
addCriterion("AllocationProjectId <", value, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidLessThanOrEqualTo(Long value) {
addCriterion("AllocationProjectId <=", value, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidIn(List<Long> values) {
addCriterion("AllocationProjectId in", values, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidNotIn(List<Long> values) {
addCriterion("AllocationProjectId not in", values, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidBetween(Long value1, Long value2) {
addCriterion("AllocationProjectId between", value1, value2, "allocationprojectid");
return (Criteria) this;
}
public Criteria andAllocationprojectidNotBetween(Long value1, Long value2) {
addCriterion("AllocationProjectId not between", value1, value2, "allocationprojectid");
return (Criteria) this;
}
public Criteria andTotalpriceIsNull() {
addCriterion("TotalPrice is null");
return (Criteria) this;

View File

@@ -94,6 +94,14 @@ public class DepotHeadService {
}
if (null != list) {
for (DepotHeadVo4List dh : list) {
if(dh.getAccountidlist() != null) {
String accountidlistStr = dh.getAccountidlist().replace("[", "").replace("]", "").replaceAll("\"", "");
dh.setAccountidlist(accountidlistStr);
}
if(dh.getAccountmoneylist() != null) {
String accountmoneylistStr = dh.getAccountmoneylist().replace("[", "").replace("]", "").replaceAll("\"", "");
dh.setAccountmoneylist(accountmoneylistStr);
}
if(dh.getOthermoneylist() != null) {
String otherMoneyListStr = dh.getOthermoneylist().replace("[", "").replace("]", "").replaceAll("\"", "");
dh.setOthermoneylist(otherMoneyListStr);
@@ -291,20 +299,6 @@ public class DepotHeadService {
return list;
}
public List<DepotHead> getDepotHeadGiftOut(String projectId)throws Exception {
DepotHeadExample example = new DepotHeadExample();
if (projectId != null) {
example.createCriteria().andProjectidEqualTo(Long.parseLong(projectId));
}
List<DepotHead> list = null;
try{
list =depotHeadMapper.selectByExample(example);
}catch(Exception e){
JshException.readFail(logger, e);
}
return list;
}
public List<DepotHeadVo4InDetail> findByAll(String beginTime, String endTime, String type, Integer pid, String dids, Integer oId, Integer offset, Integer rows) throws Exception{
List<DepotHeadVo4InDetail> list = null;
try{

View File

@@ -5,7 +5,6 @@
<id column="Id" jdbcType="BIGINT" property="id" />
<result column="Type" jdbcType="VARCHAR" property="type" />
<result column="SubType" jdbcType="VARCHAR" property="subtype" />
<result column="ProjectId" jdbcType="BIGINT" property="projectid" />
<result column="DefaultNumber" jdbcType="VARCHAR" property="defaultnumber" />
<result column="Number" jdbcType="VARCHAR" property="number" />
<result column="OperPersonName" jdbcType="VARCHAR" property="operpersonname" />
@@ -15,7 +14,6 @@
<result column="HandsPersonId" jdbcType="BIGINT" property="handspersonid" />
<result column="AccountId" jdbcType="BIGINT" property="accountid" />
<result column="ChangeAmount" jdbcType="DECIMAL" property="changeamount" />
<result column="AllocationProjectId" jdbcType="BIGINT" property="allocationprojectid" />
<result column="TotalPrice" jdbcType="DECIMAL" property="totalprice" />
<result column="PayType" jdbcType="VARCHAR" property="paytype" />
<result column="Remark" jdbcType="VARCHAR" property="remark" />
@@ -93,11 +91,10 @@
</where>
</sql>
<sql id="Base_Column_List">
Id, Type, SubType, ProjectId, DefaultNumber, Number, OperPersonName, CreateTime,
OperTime, OrganId, HandsPersonId, AccountId, ChangeAmount, AllocationProjectId, TotalPrice,
PayType, Remark, Salesman, AccountIdList, AccountMoneyList, Discount, DiscountMoney,
DiscountLastMoney, OtherMoney, OtherMoneyList, OtherMoneyItem, AccountDay, Status,
LinkNumber, tenant_id, delete_Flag
Id, Type, SubType, DefaultNumber, Number, OperPersonName, CreateTime, OperTime, OrganId,
HandsPersonId, AccountId, ChangeAmount, TotalPrice, PayType, Remark, Salesman, AccountIdList,
AccountMoneyList, Discount, DiscountMoney, DiscountLastMoney, OtherMoney, OtherMoneyList,
OtherMoneyItem, AccountDay, Status, LinkNumber, tenant_id, delete_Flag
</sql>
<select id="selectByExample" parameterType="com.jsh.erp.datasource.entities.DepotHeadExample" resultMap="BaseResultMap">
select
@@ -131,27 +128,25 @@
</delete>
<insert id="insert" parameterType="com.jsh.erp.datasource.entities.DepotHead">
insert into jsh_depothead (Id, Type, SubType,
ProjectId, DefaultNumber, Number,
OperPersonName, CreateTime, OperTime,
OrganId, HandsPersonId, AccountId,
ChangeAmount, AllocationProjectId, TotalPrice,
PayType, Remark, Salesman,
AccountIdList, AccountMoneyList, Discount,
DiscountMoney, DiscountLastMoney, OtherMoney,
OtherMoneyList, OtherMoneyItem, AccountDay,
Status, LinkNumber, tenant_id,
delete_Flag)
DefaultNumber, Number, OperPersonName,
CreateTime, OperTime, OrganId,
HandsPersonId, AccountId, ChangeAmount,
TotalPrice, PayType, Remark,
Salesman, AccountIdList, AccountMoneyList,
Discount, DiscountMoney, DiscountLastMoney,
OtherMoney, OtherMoneyList, OtherMoneyItem,
AccountDay, Status, LinkNumber,
tenant_id, delete_Flag)
values (#{id,jdbcType=BIGINT}, #{type,jdbcType=VARCHAR}, #{subtype,jdbcType=VARCHAR},
#{projectid,jdbcType=BIGINT}, #{defaultnumber,jdbcType=VARCHAR}, #{number,jdbcType=VARCHAR},
#{operpersonname,jdbcType=VARCHAR}, #{createtime,jdbcType=TIMESTAMP}, #{opertime,jdbcType=TIMESTAMP},
#{organid,jdbcType=BIGINT}, #{handspersonid,jdbcType=BIGINT}, #{accountid,jdbcType=BIGINT},
#{changeamount,jdbcType=DECIMAL}, #{allocationprojectid,jdbcType=BIGINT}, #{totalprice,jdbcType=DECIMAL},
#{paytype,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{salesman,jdbcType=VARCHAR},
#{accountidlist,jdbcType=VARCHAR}, #{accountmoneylist,jdbcType=VARCHAR}, #{discount,jdbcType=DECIMAL},
#{discountmoney,jdbcType=DECIMAL}, #{discountlastmoney,jdbcType=DECIMAL}, #{othermoney,jdbcType=DECIMAL},
#{othermoneylist,jdbcType=VARCHAR}, #{othermoneyitem,jdbcType=VARCHAR}, #{accountday,jdbcType=INTEGER},
#{status,jdbcType=VARCHAR}, #{linknumber,jdbcType=VARCHAR}, #{tenantId,jdbcType=BIGINT},
#{deleteFlag,jdbcType=VARCHAR})
#{defaultnumber,jdbcType=VARCHAR}, #{number,jdbcType=VARCHAR}, #{operpersonname,jdbcType=VARCHAR},
#{createtime,jdbcType=TIMESTAMP}, #{opertime,jdbcType=TIMESTAMP}, #{organid,jdbcType=BIGINT},
#{handspersonid,jdbcType=BIGINT}, #{accountid,jdbcType=BIGINT}, #{changeamount,jdbcType=DECIMAL},
#{totalprice,jdbcType=DECIMAL}, #{paytype,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{salesman,jdbcType=VARCHAR}, #{accountidlist,jdbcType=VARCHAR}, #{accountmoneylist,jdbcType=VARCHAR},
#{discount,jdbcType=DECIMAL}, #{discountmoney,jdbcType=DECIMAL}, #{discountlastmoney,jdbcType=DECIMAL},
#{othermoney,jdbcType=DECIMAL}, #{othermoneylist,jdbcType=VARCHAR}, #{othermoneyitem,jdbcType=VARCHAR},
#{accountday,jdbcType=INTEGER}, #{status,jdbcType=VARCHAR}, #{linknumber,jdbcType=VARCHAR},
#{tenantId,jdbcType=BIGINT}, #{deleteFlag,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.jsh.erp.datasource.entities.DepotHead">
insert into jsh_depothead
@@ -165,9 +160,6 @@
<if test="subtype != null">
SubType,
</if>
<if test="projectid != null">
ProjectId,
</if>
<if test="defaultnumber != null">
DefaultNumber,
</if>
@@ -195,9 +187,6 @@
<if test="changeamount != null">
ChangeAmount,
</if>
<if test="allocationprojectid != null">
AllocationProjectId,
</if>
<if test="totalprice != null">
TotalPrice,
</if>
@@ -260,9 +249,6 @@
<if test="subtype != null">
#{subtype,jdbcType=VARCHAR},
</if>
<if test="projectid != null">
#{projectid,jdbcType=BIGINT},
</if>
<if test="defaultnumber != null">
#{defaultnumber,jdbcType=VARCHAR},
</if>
@@ -290,9 +276,6 @@
<if test="changeamount != null">
#{changeamount,jdbcType=DECIMAL},
</if>
<if test="allocationprojectid != null">
#{allocationprojectid,jdbcType=BIGINT},
</if>
<if test="totalprice != null">
#{totalprice,jdbcType=DECIMAL},
</if>
@@ -364,9 +347,6 @@
<if test="record.subtype != null">
SubType = #{record.subtype,jdbcType=VARCHAR},
</if>
<if test="record.projectid != null">
ProjectId = #{record.projectid,jdbcType=BIGINT},
</if>
<if test="record.defaultnumber != null">
DefaultNumber = #{record.defaultnumber,jdbcType=VARCHAR},
</if>
@@ -394,9 +374,6 @@
<if test="record.changeamount != null">
ChangeAmount = #{record.changeamount,jdbcType=DECIMAL},
</if>
<if test="record.allocationprojectid != null">
AllocationProjectId = #{record.allocationprojectid,jdbcType=BIGINT},
</if>
<if test="record.totalprice != null">
TotalPrice = #{record.totalprice,jdbcType=DECIMAL},
</if>
@@ -458,7 +435,6 @@
set Id = #{record.id,jdbcType=BIGINT},
Type = #{record.type,jdbcType=VARCHAR},
SubType = #{record.subtype,jdbcType=VARCHAR},
ProjectId = #{record.projectid,jdbcType=BIGINT},
DefaultNumber = #{record.defaultnumber,jdbcType=VARCHAR},
Number = #{record.number,jdbcType=VARCHAR},
OperPersonName = #{record.operpersonname,jdbcType=VARCHAR},
@@ -468,7 +444,6 @@
HandsPersonId = #{record.handspersonid,jdbcType=BIGINT},
AccountId = #{record.accountid,jdbcType=BIGINT},
ChangeAmount = #{record.changeamount,jdbcType=DECIMAL},
AllocationProjectId = #{record.allocationprojectid,jdbcType=BIGINT},
TotalPrice = #{record.totalprice,jdbcType=DECIMAL},
PayType = #{record.paytype,jdbcType=VARCHAR},
Remark = #{record.remark,jdbcType=VARCHAR},
@@ -499,9 +474,6 @@
<if test="subtype != null">
SubType = #{subtype,jdbcType=VARCHAR},
</if>
<if test="projectid != null">
ProjectId = #{projectid,jdbcType=BIGINT},
</if>
<if test="defaultnumber != null">
DefaultNumber = #{defaultnumber,jdbcType=VARCHAR},
</if>
@@ -529,9 +501,6 @@
<if test="changeamount != null">
ChangeAmount = #{changeamount,jdbcType=DECIMAL},
</if>
<if test="allocationprojectid != null">
AllocationProjectId = #{allocationprojectid,jdbcType=BIGINT},
</if>
<if test="totalprice != null">
TotalPrice = #{totalprice,jdbcType=DECIMAL},
</if>
@@ -590,7 +559,6 @@
update jsh_depothead
set Type = #{type,jdbcType=VARCHAR},
SubType = #{subtype,jdbcType=VARCHAR},
ProjectId = #{projectid,jdbcType=BIGINT},
DefaultNumber = #{defaultnumber,jdbcType=VARCHAR},
Number = #{number,jdbcType=VARCHAR},
OperPersonName = #{operpersonname,jdbcType=VARCHAR},
@@ -600,7 +568,6 @@
HandsPersonId = #{handspersonid,jdbcType=BIGINT},
AccountId = #{accountid,jdbcType=BIGINT},
ChangeAmount = #{changeamount,jdbcType=DECIMAL},
AllocationProjectId = #{allocationprojectid,jdbcType=BIGINT},
TotalPrice = #{totalprice,jdbcType=DECIMAL},
PayType = #{paytype,jdbcType=VARCHAR},
Remark = #{remark,jdbcType=VARCHAR},

View File

@@ -3,11 +3,9 @@
<mapper namespace="com.jsh.erp.datasource.mappers.DepotHeadMapperEx">
<resultMap extends="com.jsh.erp.datasource.mappers.DepotHeadMapper.BaseResultMap" id="ResultMapEx" type="com.jsh.erp.datasource.vo.DepotHeadVo4List">
<result column="ProjectName" jdbcType="VARCHAR" property="projectName" />
<result column="OrganName" jdbcType="VARCHAR" property="organName" />
<result column="HandsPersonName" jdbcType="VARCHAR" property="handsPersonName" />
<result column="AccountName" jdbcType="VARCHAR" property="accountName" />
<result column="AllocationProjectName" jdbcType="VARCHAR" property="allocationProjectName" />
</resultMap>
<resultMap id="ResultWithInfoExMap" type="com.jsh.erp.datasource.vo.DepotHeadVo4InDetail">
@@ -42,13 +40,11 @@
</resultMap>
<select id="selectByConditionDepotHead" parameterType="com.jsh.erp.datasource.entities.DepotHeadExample" resultMap="ResultMapEx">
select distinct dh.*, d.name ProjectName, s.supplier OrganName, p.name HandsPersonName, a.name AccountName, dd.name AllocationProjectName
select distinct dh.*, s.supplier OrganName, p.name HandsPersonName, a.name AccountName
from jsh_depothead dh
left join jsh_depot d on dh.ProjectId=d.id and ifnull(d.delete_Flag,'0') !='1'
left join jsh_supplier s on dh.OrganId=s.id and ifnull(s.delete_Flag,'0') !='1'
left join jsh_person p on dh.HandsPersonId=p.id and ifnull(p.delete_Flag,'0') !='1'
left join jsh_account a on dh.AccountId=a.id and ifnull(a.delete_Flag,'0') !='1'
left join jsh_depot dd on dh.AllocationProjectId=dd.id and ifnull(dd.delete_Flag,'0') !='1'
left join jsh_depotitem di on dh.Id = di.HeaderId and ifnull(di.delete_Flag,'0') !='1'
left join jsh_material m on di.MaterialId = m.Id and ifnull(m.delete_Flag,'0') !='1'
where 1=1