Commit 5d9ab311 by 谢明辉

Merge branch 'develop' of http://192.168.9.26/platform/finance_serv into develop

2 parents 60e3bbc6 c6433d9d
Showing 19 changed files with 917 additions and 200 deletions
...@@ -81,6 +81,17 @@ ...@@ -81,6 +81,17 @@
<artifactId>spring-boot-starter-test</artifactId> <artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.1.2</version>
</dependency>
<dependency>
<groupId>net.sf.json-lib</groupId>
<artifactId>json-lib</artifactId>
<version>2.4</version>
<classifier>jdk15</classifier>
</dependency>
</dependencies> </dependencies>
<build> <build>
......
...@@ -9,7 +9,7 @@ import org.springframework.context.annotation.ComponentScan; ...@@ -9,7 +9,7 @@ import org.springframework.context.annotation.ComponentScan;
@SpringBootApplication @SpringBootApplication
@MapperScan(basePackages="com.vion.financial.mapper") @MapperScan(basePackages="com.vion.financial.mapper")
@ComponentScan(basePackages="com.vion.financial") @ComponentScan(basePackages="com.vion.financial.*")
public class FinancialSystemApplication extends SpringBootServletInitializer { public class FinancialSystemApplication extends SpringBootServletInitializer {
public static void main(String[] args) { public static void main(String[] args) {
......
package com.vion.financial.config;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;
@Component
@ConfigurationProperties(prefix = "finance")
public class FinanceConfig {
private String authurl;
public String getAuthurl() {
return authurl;
}
public void setAuthurl(String authurl) {
this.authurl = authurl;
}
}
...@@ -52,7 +52,7 @@ public class ContractController extends BaseController { ...@@ -52,7 +52,7 @@ public class ContractController extends BaseController {
return contractService.queryList(); return contractService.queryList();
} }
@GetMapping @GetMapping()
@ResponseBody @ResponseBody
public Object queryByCondition(SelectVo selectVo) { public Object queryByCondition(SelectVo selectVo) {
return contractService.selectByCondition(selectVo); return contractService.selectByCondition(selectVo);
......
...@@ -4,6 +4,7 @@ import java.util.List; ...@@ -4,6 +4,7 @@ import java.util.List;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import com.vion.financial.vo.ContractVo; import com.vion.financial.vo.ContractVo;
import com.vion.financial.vo.SelectVo; import com.vion.financial.vo.SelectVo;
...@@ -19,5 +20,5 @@ public interface ContractMapper { ...@@ -19,5 +20,5 @@ public interface ContractMapper {
public List<ContractVo> selectByCondition(SelectVo selectVo); public List<ContractVo> selectByCondition(SelectVo selectVo);
public boolean isDelete(String contract_unid); public boolean isDelete(String contract_unid);
public int countNumber();
} }
...@@ -16,10 +16,10 @@ ...@@ -16,10 +16,10 @@
<if test="county != null and county != ''"> <if test="county != null and county != ''">
,county ,county
</if> </if>
<if test="guarantee_period != null and guarantee_period != ''"> <if test="guarantee_period != null">
,guarantee_period ,guarantee_period
</if> </if>
<if test="sign_date != null and sign_date != ''"> <if test="sign_date != null">
,sign_date ,sign_date
</if> </if>
<if test="product_line_type != null and product_line_type != ''"> <if test="product_line_type != null and product_line_type != ''">
...@@ -274,31 +274,37 @@ ...@@ -274,31 +274,37 @@
</delete> </delete>
<select id="selectByCondition" parameterType="com.vion.financial.vo.SelectVo" resultType="com.vion.financial.vo.ContractVo"> <select id="selectByCondition" parameterType="com.vion.financial.vo.SelectVo" resultType="com.vion.financial.vo.ContractVo">
select contract_unid, salesperson_unid, province, city, county, select
contract_unid, salesperson_unid, province, city, county,
guarantee_period, sign_date, product_line_type, contract_state, guarantee_period, sign_date, product_line_type, contract_state,
contract_type, contract_amount, deduct_amount, contract_amount_note, contract_type, cast(contract_amount as decimal(18,2)), cast(deduct_amount as decimal(18,2)), contract_amount_note,
stop_amount, reback_note, exemptions_amount, contract_remain_note, cast(stop_amount as decimal(18,2)), reback_note, cast(exemptions_amount as decimal(18,2)), contract_remain_note,
is_archive, bad_amount, bad_amount_note, confirm_income_amount, is_archive, cast(bad_amount as decimal(18,2)), bad_amount_note, cast(confirm_income_amount as decimal(18,2)),
amount_state_unid, start_guarantee_date, end_guarantee_date, amount_state_unid, start_guarantee_date, end_guarantee_date,
mainten_start_point, contract_note, is_delete, project_unid, mainten_start_point, contract_note, is_delete, project_unid,
customer_unid, customer_unid,
(select total_reback_view.sum from total_reback_view where total_reback_view.contract_unid=tb_contract.contract_unid) as total_reback_amount, (cast(contract_amount as decimal(18,2))-(select cast(total_reback_view.sum as decimal(18,2)) from total_reback_view where total_reback_view.contract_unid=tb_contract.contract_unid)-cast(deduct_amount as decimal(18,2))-cast(stop_amount as decimal(18,2))-cast(exemptions_amount as decimal(18,2))-cast(bad_amount as decimal(18,2))) as contract_remain,
(contract_amount-(select total_reback_view.sum from total_reback_view where total_reback_view.contract_unid=tb_contract.contract_unid)-deduct_amount-stop_amount-exemptions_amount-bad_amount) as contract_remain, (select cast(total_reback_view.sum as decimal(18,2)) from total_reback_view where total_reback_view.contract_unid=tb_contract.contract_unid) as total_reback_amount,
(select total_recv_amount_view.total_recv_amount from total_recv_amount_view where tb_contract.contract_unid=total_recv_amount_view.contract_unid) as total_receive_amount , (select cast(total_recv_amount_view.total_recv_amount as decimal(18,2)) from total_recv_amount_view where tb_contract.contract_unid=total_recv_amount_view.contract_unid) as total_receive_amount ,
((select total_recv_amount_view.total_recv_amount from total_recv_amount_view where tb_contract.contract_unid=total_recv_amount_view.contract_unid)-(select total_reback_view.sum from total_reback_view where total_reback_view.contract_unid=tb_contract.contract_unid)-deduct_amount-stop_amount-exemptions_amount-bad_amount) as total_amount_remain , ((select cast(total_recv_amount_view.total_recv_amount as decimal(18,2)) from total_recv_amount_view where tb_contract.contract_unid=total_recv_amount_view.contract_unid)-(select cast(total_reback_view.sum as decimal(18,2)) from total_reback_view where total_reback_view.contract_unid=tb_contract.contract_unid)-(cast(deduct_amount as decimal(18,2)))-(cast(stop_amount as decimal(18,2)))-(cast(exemptions_amount as decimal(18,2)))-(cast(bad_amount as decimal(18,2)))) as total_amount_remain ,
(select over_days_view.over_days from over_days_view where over_days_view.contract_unid=tb_contract.contract_unid) as over_days (select over_days_view.over_days from over_days_view where over_days_view.contract_unid=tb_contract.contract_unid) as over_days,
(select tb_project.project_name from tb_project where tb_project.project_unid=tb_contract.project_unid) as project_name,
(select tb_customer.customer_name from tb_customer where tb_customer.customer_unid=tb_contract.customer_unid) as customer_name
from tb_contract where 1=1 from tb_contract where 1=1
<if test="salesperson_name__like !=null and salesperson_name__like !=''"> <if test="salesperson_unids !=null">
and and
salesperson_unid like #{salesperson_name__like} salesperson_unid in
<foreach collection="salesperson_unids" index="index" item="salesperson_unid" open="(" close=")" separator=",">
#{salesperson_unid}
</foreach>
</if> </if>
<if test="project_name__like !=null and project_name__like !=''"> <if test="project_name__like !=null and project_name__like !=''">
and and
project_unid like #{project_name__like} tb_contract.project_unid in (select tb_project.project_unid from tb_project where project_name like '%'||#{project_name__like}||'%')
</if> </if>
<if test="customer_name__like !=null and customer_name__like !=''"> <if test="customer_name__like !=null and customer_name__like !=''">
and and
customer_unid like #{customer_name__like} tb_contract.customer_unid in (select tb_customer.customer_unid from tb_customer where customer_name like '%'||#{customer_name__like}||'%')
</if> </if>
<if test="province !=null and province !=''"> <if test="province !=null and province !=''">
and and
...@@ -312,17 +318,17 @@ ...@@ -312,17 +318,17 @@
and and
county=#{county} county=#{county}
</if> </if>
<if test="guarantee_period !=null"> <if test="guarantee_period !=null and guarantee_period !=0">
and and
guarantee_period=#{guarantee_period} guarantee_period=#{guarantee_period}
</if> </if>
<if test="year !=null and year !=''"> <if test="year !=null and year !=''">
and and
to_char(sign_date,"yyyy")=#{year} to_char(sign_date,'yyyy')=#{year}
</if> </if>
<if test="month !=null and month!=''"> <if test="month !=null and month!=''">
and and
to_char(sign_date,"MM")=#{month} to_char(sign_date,'MM')=#{month}
</if> </if>
<if test="product_line_type !=null and product_line_type !=''"> <if test="product_line_type !=null and product_line_type !=''">
and and
...@@ -348,7 +354,7 @@ ...@@ -348,7 +354,7 @@
and and
confirm_income_amount=#{confirm_income_amount} confirm_income_amount=#{confirm_income_amount}
</if> </if>
<if test="amount_state_unid !=null"> <if test="amount_state_unid !=null and amount_state_unid !=''">
and and
amount_state_unid=#{amount_state_unid} amount_state_unid=#{amount_state_unid}
</if> </if>
...@@ -356,18 +362,19 @@ ...@@ -356,18 +362,19 @@
and and
#{start_date} <![CDATA[<=]]> sign_date and sign_date <![CDATA[<=]]> #{end_date} #{start_date} <![CDATA[<=]]> sign_date and sign_date <![CDATA[<=]]> #{end_date}
</if> </if>
<if test="amount_point !=null"> <if test="amount_point !=null and amount_point !=0.0">
and and
contract_amount <![CDATA[>=]]> #{amount_point} contract_amount <![CDATA[>=]]> #{amount_point}
</if> </if>
<if test="overdays_point !=null"> <if test="overdays_point !=null and overdays_point !=0">
and and
<!--逾期天数-->contract_unid in (select over_days_view.contract_unid from over_days_view where over_days <![CDATA[>=]]> #{overdays_point}) <!--逾期天数-->contract_unid in (select over_days_view.contract_unid from over_days_view where over_days <![CDATA[>=]]> #{overdays_point})
</if> </if>
<if test="leave_amount_point !=null"> <if test="leave_amount_point !=null and leave_amount_point !=0.0">
<!--应收款余额-->and <!--应收款余额-->and
contract_unid in (select receive_amount_view.contract_unid from receive_amount_view where receive_amount_view.leave_amount_point <![CDATA[>=]]> #{leave_amount_point}) contract_unid in (select receive_amount_view.contract_unid from receive_amount_view where receive_amount_view.leave_amount_point <![CDATA[>=]]> #{leave_amount_point})
</if> </if>
and is_delete=false
<if test="limit !=null and offset !=null"> <if test="limit !=null and offset !=null">
limit #{limit} offset #{offset} limit #{limit} offset #{offset}
</if> </if>
...@@ -378,4 +385,7 @@ ...@@ -378,4 +385,7 @@
<select id="queryList" resultType="String"> <select id="queryList" resultType="String">
select contract_unid from tb_contract select contract_unid from tb_contract
</select> </select>
<select id="countNumber" resultType="int">
select count(contract_unid) from tb_contract where is_delete=false
</select>
</mapper> </mapper>
<?xml version="1.0" encoding="UTF-8"?> <?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"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.vion.financial.mapper.PaymentAgreeMapper"> <mapper namespace="com.vion.financial.mapper.PaymentAgreeMapper">
<insert id="addPaymentAgree" parameterType="com.vion.financial.entity.PaymentAgree"> <insert id="addPaymentAgree" parameterType="com.vion.financial.entity.PaymentAgree">
insert into tb_payment_agree ( insert into tb_payment_agree (
contract_unid, contract_unid,
<if test="payment_type !=null and payment_type !=''"> <if test="payment_type !=null and payment_type !=''">
payment_type, payment_type,
</if> </if>
<if test="payment_progress !=null and payment_progress !=''"> <if test="payment_progress !=null and payment_progress !=''">
payment_progress, payment_progress,
</if> </if>
<if test="days !=null and days !=''"> <if test="days !=null and days !=''">
days, days,
</if> </if>
<if test="payment_propority !=null and payment_propority !=''"> <if test="payment_propority !=null and payment_propority !=''">
payment_propority, payment_propority,
</if> </if>
<if test="payment_requirement !=null and payment_requirement !=''"> <if test="payment_requirement !=null and payment_requirement !=''">
payment_requirement payment_requirement
</if> </if>
) )
values( values(
#{contract_unid}, #{contract_unid},
<if test="payment_type !=null and payment_type !=''"> <if test="payment_type !=null and payment_type !=''">
#{payment_type}, #{payment_type},
</if> </if>
<if test="payment_progress !=null and payment_progress !=''"> <if test="payment_progress !=null and payment_progress !=''">
#{payment_progress}, #{payment_progress},
</if> </if>
<if test="days !=null and days !=''"> <if test="days !=null and days !=''">
#{days}, #{days},
</if> </if>
<if test="payment_propority !=null and payment_propority !=''"> <if test="payment_propority !=null and payment_propority !=''">
#{payment_propority}, #{payment_propority},
</if> </if>
<if test="payment_requirement !=null and payment_requirement !=''"> <if test="payment_requirement !=null and payment_requirement !=''">
#{payment_requirement} #{payment_requirement}
</if> </if>
) )
</insert> </insert>
<update id="updatePaymentAgree" parameterType="com.vion.financial.entity.PaymentAgree"> <update id="updatePaymentAgree" parameterType="com.vion.financial.entity.PaymentAgree">
update tb_payment_agree set update tb_payment_agree set
contract_unid=#{contract_unid}, contract_unid=#{contract_unid},
<if test="payment_type != null and payment_type !=''"> <if test="payment_type != null and payment_type !=''">
payment_type = #{payment_type} , payment_type = #{payment_type} ,
</if> </if>
<if test="payment_progress !=null and payment_progress !=''"> <if test="payment_progress !=null and payment_progress !=''">
payment_progress = #{payment_progress} , payment_progress = #{payment_progress} ,
</if> </if>
<if test="days !=null and days !=''"> <if test="days !=null and days !=''">
days = #{days} , days = #{days} ,
</if> </if>
<if test="payment_propority !=null and payment_propority !=''"> <if test="payment_propority !=null and payment_propority !=''">
payment_propority = #{payment_propority} , payment_propority = #{payment_propority} ,
</if> </if>
<if test="payment_requirement !=null and payment_requirement !=''"> <if test="payment_requirement !=null and payment_requirement !=''">
payment_requirement = #{payment_requirement} payment_requirement = #{payment_requirement}
</if> </if>
where payment_unid = #{payment_unid} where payment_unid = #{payment_unid}
</update> </update>
<select id="queryPaymentAgree" parameterType="String" resultType="com.vion.financial.entity.PaymentAgree"> <select id="queryPaymentAgree" parameterType="String" resultType="com.vion.financial.entity.PaymentAgree">
select * from tb_payment_agree where contract_unid = #{contract_unid} select payment_unid,contract_unid,payment_type,payment_progress,days,cast(payment_propority as decimal(18,2)),payment_requirement from tb_payment_agree where contract_unid = #{contract_unid}
</select> </select>
<delete id="deletePaymentAgree" parameterType="int"> <delete id="deletePaymentAgree" parameterType="int">
delete from tb_payment_agree where payment_unid = #{payment_unid} delete from tb_payment_agree where payment_unid = #{payment_unid}
</delete> </delete>
</mapper> </mapper>
\ No newline at end of file \ No newline at end of file
...@@ -2,64 +2,76 @@ package com.vion.financial.service.imp; ...@@ -2,64 +2,76 @@ package com.vion.financial.service.imp;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.Map;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import com.vion.financial.config.FinanceConfig;
import com.vion.financial.entity.Appendix; import com.vion.financial.entity.Appendix;
import com.vion.financial.mapper.AppendixMapper; import com.vion.financial.mapper.AppendixMapper;
import com.vion.financial.mapper.ContractMapper; import com.vion.financial.mapper.ContractMapper;
import com.vion.financial.mapper.PaymentAgreeMapper; import com.vion.financial.mapper.PaymentAgreeMapper;
import com.vion.financial.service.ContractService; import com.vion.financial.service.ContractService;
import com.vion.financial.utils.HttpNetClient;
import com.vion.financial.utils.JavaBean2Json;
import com.vion.financial.vo.ContractVo; import com.vion.financial.vo.ContractVo;
import com.vion.financial.vo.FailCode; import com.vion.financial.vo.FailCode;
import com.vion.financial.vo.ResultVo;
import com.vion.financial.vo.SelectVo; import com.vion.financial.vo.SelectVo;
import com.vion.financial.vo.SuccessCode; import com.vion.financial.vo.SuccessCode;
import net.sf.json.JSONObject;
@Service @Service
public class ContractServiceImpl implements ContractService { public class ContractServiceImpl implements ContractService {
Logger logger = LoggerFactory.getLogger(ContractServiceImpl.class); Logger logger = LoggerFactory.getLogger(ContractServiceImpl.class);
@Autowired @Autowired
ContractMapper contractMapper; ContractMapper contractMapper;
@Autowired @Autowired
AppendixMapper appendixMapper; AppendixMapper appendixMapper;
@Autowired @Autowired
PaymentAgreeMapper paymentAgreeMapper; PaymentAgreeMapper paymentAgreeMapper;
@Autowired @Autowired
SuccessCode successCode; SuccessCode successCode;
@Autowired @Autowired
FailCode failCode; FailCode failCode;
@Autowired
FinanceConfig financeConfig;
/*** /***
* 新增合同信息 * 新增合同信息
*/ */
@Override @Override
public Object addOne(ContractVo contractVo) { public Object addOne(ContractVo contractVo) {
try { try {
//先插入合同信息 // 先插入合同信息
logger.info("============新增合同 start ============"); logger.info("============新增合同 start ============");
//根据附件unid集合更新附件表信息 // 根据附件unid集合更新附件表信息
Appendix appendix = new Appendix(); Appendix appendix = new Appendix();
if(contractMapper.queryOne(contractVo.getContract_unid()) !=null) { if (contractMapper.queryOne(contractVo.getContract_unid()) != null) {
contractMapper.updateOne(contractVo); contractMapper.updateOne(contractVo);
}else { } else {
contractMapper.addOne(contractVo); contractMapper.addOne(contractVo);
} }
appendix.setBusiness_table("tb_contract"); appendix.setBusiness_table("tb_contract");
appendix.setBusiness_unid(contractVo.getContract_unid()); appendix.setBusiness_unid(contractVo.getContract_unid());
for(int n:contractVo.getAppendix_unids()) { for (int n : contractVo.getAppendix_unids()) {
appendix.setAppendix_unid(n); appendix.setAppendix_unid(n);
appendixMapper.updateAppendix(appendix); appendixMapper.updateAppendix(appendix);
} }
return successCode; return successCode;
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();
logger.error("增加合同异常:"+e.getLocalizedMessage(), e); logger.error("增加合同异常:" + e.getLocalizedMessage(), e);
failCode.setEcode("500"); failCode.setEcode("500");
failCode.setEnote("增加异常"); failCode.setEnote("增加异常");
return failCode; return failCode;
...@@ -70,17 +82,23 @@ public class ContractServiceImpl implements ContractService { ...@@ -70,17 +82,23 @@ public class ContractServiceImpl implements ContractService {
public Object queryOne(String s) { public Object queryOne(String s) {
try { try {
logger.info("================查询合同start==================="); logger.info("================查询合同start===================");
ContractVo contractVo = contractMapper.queryOne(s); if (contractMapper.isDelete(s)) {
Appendix appendix = new Appendix(); ContractVo contractVo = contractMapper.queryOne(s);
appendix.setBusiness_table("tb_contract"); Appendix appendix = new Appendix();
appendix.setBusiness_unid(s); appendix.setBusiness_table("tb_contract");
List<Appendix> appendixs = appendixMapper.queryAppendixList(appendix); appendix.setBusiness_unid(s);
contractVo.setAppendix_list(appendixs); List<Appendix> appendixs = appendixMapper.queryAppendixList(appendix);
return contractVo; contractVo.setAppendix_list(appendixs);
return contractVo;
} else {
failCode.setEcode("100");
failCode.setEnote("合同已删除");
return failCode;
}
} catch (Exception e) { } catch (Exception e) {
// TODO: handle exception // TODO: handle exception
/* return failCode;*/ /* return failCode; */
logger.error("查询合同异常"+e.getLocalizedMessage(),e); logger.error("查询合同异常" + e.getLocalizedMessage(), e);
e.printStackTrace(); e.printStackTrace();
failCode.setEcode("500"); failCode.setEcode("500");
failCode.setEnote("查询异常"); failCode.setEnote("查询异常");
...@@ -96,14 +114,14 @@ public class ContractServiceImpl implements ContractService { ...@@ -96,14 +114,14 @@ public class ContractServiceImpl implements ContractService {
Appendix appendix = new Appendix(); Appendix appendix = new Appendix();
appendix.setBusiness_table("tb_contract"); appendix.setBusiness_table("tb_contract");
appendix.setBusiness_unid(vontractVo.getContract_unid()); appendix.setBusiness_unid(vontractVo.getContract_unid());
for(int n:vontractVo.getAppendix_unids()) { for (int n : vontractVo.getAppendix_unids()) {
appendix.setAppendix_unid(n); appendix.setAppendix_unid(n);
appendixMapper.updateAppendix(appendix); appendixMapper.updateAppendix(appendix);
} }
return successCode; return successCode;
} catch (Exception e) { } catch (Exception e) {
// TODO: handle exception // TODO: handle exception
logger.error("修改合同异常"+e.getLocalizedMessage(), e); logger.error("修改合同异常" + e.getLocalizedMessage(), e);
e.printStackTrace(); e.printStackTrace();
failCode.setEcode("500"); failCode.setEcode("500");
failCode.setEnote("修改异常"); failCode.setEnote("修改异常");
...@@ -115,11 +133,14 @@ public class ContractServiceImpl implements ContractService { ...@@ -115,11 +133,14 @@ public class ContractServiceImpl implements ContractService {
public Object deleteOne(String s) { public Object deleteOne(String s) {
try { try {
logger.info("=================删除合同================="); logger.info("=================删除合同=================");
//contractMapper.updateSingleContract(contractVo); Appendix appendix = new Appendix();
appendix.setBusiness_unid(s);
// contractMapper.updateSingleContract(contractVo);
contractMapper.deleteOne(s); contractMapper.deleteOne(s);
appendixMapper.deleteAppendix(appendix);
return successCode; return successCode;
} catch (Exception e) { } catch (Exception e) {
logger.error("删除合同异常"+e.getLocalizedMessage(),e); logger.error("删除合同异常" + e.getLocalizedMessage(), e);
e.printStackTrace(); e.printStackTrace();
failCode.setEcode("500"); failCode.setEcode("500");
failCode.setEnote("删除异常"); failCode.setEnote("删除异常");
...@@ -139,7 +160,7 @@ public class ContractServiceImpl implements ContractService { ...@@ -139,7 +160,7 @@ public class ContractServiceImpl implements ContractService {
return contractMapper.queryList(); return contractMapper.queryList();
} catch (Exception e) { } catch (Exception e) {
// TODO: handle exception // TODO: handle exception
logger.error("查询合同列表异常"+e.getLocalizedMessage(),e); logger.error("查询合同列表异常" + e.getLocalizedMessage(), e);
e.printStackTrace(); e.printStackTrace();
failCode.setEcode("500"); failCode.setEcode("500");
failCode.setEnote("查询异常"); failCode.setEnote("查询异常");
...@@ -151,16 +172,49 @@ public class ContractServiceImpl implements ContractService { ...@@ -151,16 +172,49 @@ public class ContractServiceImpl implements ContractService {
public Object selectByCondition(SelectVo selectVo) { public Object selectByCondition(SelectVo selectVo) {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
ResultVo resultVo=new ResultVo();
logger.info("========================筛选合同列表==========================="); logger.info("========================筛选合同列表===========================");
List<ContractVo> list=new ArrayList<ContractVo>(); List<Map> list_data = null;
for(ContractVo contractVo:contractMapper.selectByCondition(selectVo)) { if (StringUtils.isNotBlank(selectVo.getSalesperson_name__like())) {
// 调用auth服务的接口获取用户列表信息
String url = financeConfig.getAuthurl();
String result = HttpNetClient.doGet(url+"?username="+selectVo.getSalesperson_name__like(), null);
Map map = JavaBean2Json.Json2JavaBean(result, Map.class);
list_data = (List<Map>) map.get("list_data");
if(list_data != null && list_data.size() > 0) {
List<String> salesperson_unids = new ArrayList<String>(list_data.size());
for(Map _map:list_data) {
salesperson_unids.add((String) _map.get("user_unid"));
}
selectVo.setSalesperson_unids(salesperson_unids);
}else {
resultVo.setList_data(new ArrayList<>());
resultVo.setList_size(selectVo.getLimit()== null ? 0 : selectVo.getLimit());
resultVo.setOffset(selectVo.getOffset()== null ? 0 : selectVo.getOffset());
resultVo.setTotal_number(0);
return resultVo;
}
}
List<ContractVo> list = contractMapper.selectByCondition(selectVo);
for (ContractVo contractVo : list) {
contractVo.setPaymentAgree_list(paymentAgreeMapper.queryPaymentAgree(contractVo.getContract_unid())); contractVo.setPaymentAgree_list(paymentAgreeMapper.queryPaymentAgree(contractVo.getContract_unid()));
list.add(contractVo); if(list_data != null && list_data.size() > 0) {
for(Map _map:list_data) {
if (contractVo.getSalesperson_unid().equals(_map.get("user_unid"))) {
contractVo.setSalesperson_name((String) _map.get("name"));
}
}
}
} }
return list; resultVo.setList_data(list);
resultVo.setList_size(selectVo.getLimit());
resultVo.setOffset(selectVo.getOffset());
resultVo.setTotal_number(contractMapper.countNumber());
return resultVo;
} catch (Exception e) { } catch (Exception e) {
// TODO: handle exception // TODO: handle exception
logger.error("筛选合同列表异常"+e.getLocalizedMessage(),e); logger.error("筛选合同列表异常" + e.getLocalizedMessage(), e);
failCode.setEcode("500"); failCode.setEcode("500");
failCode.setEnote("筛选异常"); failCode.setEnote("筛选异常");
return failCode; return failCode;
......
...@@ -39,7 +39,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService { ...@@ -39,7 +39,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService {
try { try {
Appendix appendix = new Appendix(); Appendix appendix = new Appendix();
logger.info("=====================增加发货信息====================="); logger.info("=====================增加发货信息=====================");
if((boolean)contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
List<DeliverGoods> list=deliverGoodsVo.getList_deliver_data(); List<DeliverGoods> list=deliverGoodsVo.getList_deliver_data();
for(DeliverGoods deliverGoods:list) { for(DeliverGoods deliverGoods:list) {
deliverGoods.setContract_unid(s); deliverGoods.setContract_unid(s);
...@@ -73,7 +73,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService { ...@@ -73,7 +73,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService {
deliverGoodsVo.setList_deliver_data(new ArrayList()); deliverGoodsVo.setList_deliver_data(new ArrayList());
Appendix appendix = null; Appendix appendix = null;
logger.info("========================查询发货信息========================"); logger.info("========================查询发货信息========================");
if(contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
List<DeliverGoods> list=deliverGoodsMapper.queryDeliverGoods(s); List<DeliverGoods> list=deliverGoodsMapper.queryDeliverGoods(s);
for(DeliverGoods deliverGoods:list) { for(DeliverGoods deliverGoods:list) {
appendix = new Appendix(); appendix = new Appendix();
...@@ -105,7 +105,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService { ...@@ -105,7 +105,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService {
try { try {
Appendix appendix=null; Appendix appendix=null;
logger.info("===========================修改发货信息==========================="); logger.info("===========================修改发货信息===========================");
if(contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
List<DeliverGoods> list_deliver_data=deliverGoodsVo.getList_deliver_data(); List<DeliverGoods> list_deliver_data=deliverGoodsVo.getList_deliver_data();
for(DeliverGoods deliverGoods:list_deliver_data) { for(DeliverGoods deliverGoods:list_deliver_data) {
deliverGoodsMapper.updateDeliverGoods(deliverGoods); deliverGoodsMapper.updateDeliverGoods(deliverGoods);
...@@ -138,7 +138,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService { ...@@ -138,7 +138,7 @@ public class DeliverGoodsServiceImpl implements DeliverGoodsService {
try { try {
logger.info("=========================删除合同发货信息======================="); logger.info("=========================删除合同发货信息=======================");
Appendix appendix=null; Appendix appendix=null;
if(contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
for(int deliverUnid :deliverGoodsVo.getDeliver_unids()) { for(int deliverUnid :deliverGoodsVo.getDeliver_unids()) {
deliverGoodsMapper.deleteDeliverGoods(deliverUnid); deliverGoodsMapper.deleteDeliverGoods(deliverUnid);
appendix=new Appendix(); appendix=new Appendix();
......
...@@ -31,7 +31,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService { ...@@ -31,7 +31,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService {
public Object addPaymentAgree(PaymentAgreeVo paymentAgreeVo,String s) { public Object addPaymentAgree(PaymentAgreeVo paymentAgreeVo,String s) {
try { try {
logger.info("==============增加付款约定信息==================="); logger.info("==============增加付款约定信息===================");
if((boolean) contractServiceImpl.isDelete(s)) { if(! contractServiceImpl.isDelete(s)) {
List<PaymentAgree> list = paymentAgreeVo.getList_payment_data(); List<PaymentAgree> list = paymentAgreeVo.getList_payment_data();
for(PaymentAgree paymentAgree:list) { for(PaymentAgree paymentAgree:list) {
paymentAgree.setContract_unid(s); paymentAgree.setContract_unid(s);
...@@ -56,7 +56,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService { ...@@ -56,7 +56,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService {
public Object queryPaymentAgree(String s) { public Object queryPaymentAgree(String s) {
try { try {
logger.info("===============查询付款约定信息start====================="); logger.info("===============查询付款约定信息start=====================");
if((boolean) contractServiceImpl.isDelete(s)) { if(! contractServiceImpl.isDelete(s)) {
return paymentAgreeMapper.queryPaymentAgree(s); return paymentAgreeMapper.queryPaymentAgree(s);
} }
failCode.setEcode("100"); failCode.setEcode("100");
...@@ -77,7 +77,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService { ...@@ -77,7 +77,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService {
try { try {
logger.info("==============修改付款约定信息==================="); logger.info("==============修改付款约定信息===================");
if((boolean) contractServiceImpl.isDelete(s)) { if(! contractServiceImpl.isDelete(s)) {
List<PaymentAgree> list = paymentAgreeVo.getList_payment_data(); List<PaymentAgree> list = paymentAgreeVo.getList_payment_data();
for(PaymentAgree paymentAgree:list) { for(PaymentAgree paymentAgree:list) {
paymentAgree.setContract_unid(s); paymentAgree.setContract_unid(s);
...@@ -103,7 +103,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService { ...@@ -103,7 +103,7 @@ public class PaymentAgreeServiceImpl implements PaymentAgreeService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("==============删除付款约定信息==================="); logger.info("==============删除付款约定信息===================");
if((boolean) contractServiceImpl.isDelete(s)) { if(! contractServiceImpl.isDelete(s)) {
List<PaymentAgree> list = paymentAgreeVo.getList_payment_data(); List<PaymentAgree> list = paymentAgreeVo.getList_payment_data();
for(PaymentAgree paymentAgree:list) { for(PaymentAgree paymentAgree:list) {
paymentAgree.setContract_unid(s); paymentAgree.setContract_unid(s);
......
...@@ -39,7 +39,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService { ...@@ -39,7 +39,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService {
try { try {
Appendix appendix = new Appendix(); Appendix appendix = new Appendix();
logger.info("=====================增加合同验收信息====================="); logger.info("=====================增加合同验收信息=====================");
if((boolean)contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
List<ProjectAcceptanc> list=projectAcceptancVo.getList_check_data(); List<ProjectAcceptanc> list=projectAcceptancVo.getList_check_data();
for(ProjectAcceptanc projectAcceptanc:list) { for(ProjectAcceptanc projectAcceptanc:list) {
projectAcceptanc.setContract_unid(s); projectAcceptanc.setContract_unid(s);
...@@ -74,7 +74,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService { ...@@ -74,7 +74,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService {
projectAcceptancVo.setList_check_data(new ArrayList()); projectAcceptancVo.setList_check_data(new ArrayList());
Appendix appendix = null; Appendix appendix = null;
logger.info("========================查询合同验收信息========================"); logger.info("========================查询合同验收信息========================");
if(contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
List<ProjectAcceptanc> list=projectAcceptancMapper.queryProjectAcceptanc(s); List<ProjectAcceptanc> list=projectAcceptancMapper.queryProjectAcceptanc(s);
for(ProjectAcceptanc projectAcceptanc:list) { for(ProjectAcceptanc projectAcceptanc:list) {
appendix = new Appendix(); appendix = new Appendix();
...@@ -106,7 +106,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService { ...@@ -106,7 +106,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService {
try { try {
logger.info("===========================修改合同验收信息==========================="); logger.info("===========================修改合同验收信息===========================");
Appendix appendix=null; Appendix appendix=null;
if(contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
List<ProjectAcceptanc> list=projectAcceptancVo.getList_check_data(); List<ProjectAcceptanc> list=projectAcceptancVo.getList_check_data();
for(ProjectAcceptanc projectAcceptanc:list) { for(ProjectAcceptanc projectAcceptanc:list) {
projectAcceptanc.setContract_unid(s); projectAcceptanc.setContract_unid(s);
...@@ -140,7 +140,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService { ...@@ -140,7 +140,7 @@ public class ProjectAcceptancServiceImpl implements ProjectAcceptancService {
try { try {
logger.info("===========================删除合同验收信息==========================="); logger.info("===========================删除合同验收信息===========================");
Appendix appendix =null; Appendix appendix =null;
if(contractService.isDelete(s)) { if(!contractService.isDelete(s)) {
List<Integer> list=projectAcceptancVo.getAcceptanc_unids(); List<Integer> list=projectAcceptancVo.getAcceptanc_unids();
for(int n:list) { for(int n:list) {
projectAcceptancMapper.deleteProjectAcceptanc(n); projectAcceptancMapper.deleteProjectAcceptanc(n);
......
...@@ -31,7 +31,7 @@ public class ReceiptServiceImpl implements ReceiptService { ...@@ -31,7 +31,7 @@ public class ReceiptServiceImpl implements ReceiptService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("=====================增加合同开票信息====================="); logger.info("=====================增加合同开票信息=====================");
if((boolean) contractServiceImpl.isDelete(s)) { if(! contractServiceImpl.isDelete(s)) {
List<Receipt> list=receiptVo.getList_receipt_data(); List<Receipt> list=receiptVo.getList_receipt_data();
for(Receipt receipt: list) { for(Receipt receipt: list) {
receipt.setContract_unid(s); receipt.setContract_unid(s);
...@@ -56,7 +56,7 @@ public class ReceiptServiceImpl implements ReceiptService { ...@@ -56,7 +56,7 @@ public class ReceiptServiceImpl implements ReceiptService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("========================查询合同开票信息======================="); logger.info("========================查询合同开票信息=======================");
if((boolean)contractServiceImpl.isDelete(s)) { if(!contractServiceImpl.isDelete(s)) {
return receiptMapper.queryReceipt(s); return receiptMapper.queryReceipt(s);
}else { }else {
failCode.setEcode("100"); failCode.setEcode("100");
...@@ -76,7 +76,7 @@ public class ReceiptServiceImpl implements ReceiptService { ...@@ -76,7 +76,7 @@ public class ReceiptServiceImpl implements ReceiptService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("===================修改合同开票信息========================"); logger.info("===================修改合同开票信息========================");
if((boolean)contractServiceImpl.isDelete(s)) { if(!contractServiceImpl.isDelete(s)) {
List<Receipt> list=receiptVo.getList_receipt_data(); List<Receipt> list=receiptVo.getList_receipt_data();
for(Receipt receipt:list) { for(Receipt receipt:list) {
receipt.setContract_unid(s); receipt.setContract_unid(s);
...@@ -102,7 +102,7 @@ public class ReceiptServiceImpl implements ReceiptService { ...@@ -102,7 +102,7 @@ public class ReceiptServiceImpl implements ReceiptService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("=========================删除合同开票信息======================="); logger.info("=========================删除合同开票信息=======================");
if((boolean)contractServiceImpl.isDelete(s)) { if(!contractServiceImpl.isDelete(s)) {
List<Receipt> list=receiptVo.getReceipt_unids(); List<Receipt> list=receiptVo.getReceipt_unids();
for(Receipt receiptUnid :list) { for(Receipt receiptUnid :list) {
receiptMapper.deleteReceipt(receiptUnid.getReceipt_unid()); receiptMapper.deleteReceipt(receiptUnid.getReceipt_unid());
......
...@@ -33,7 +33,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService { ...@@ -33,7 +33,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("==============增加合同回款信息==================="); logger.info("==============增加合同回款信息===================");
if((boolean) contractServiceImpl.isDelete(s)) { if(! contractServiceImpl.isDelete(s)) {
List<ReturnInfo> list = returnInfoVo.getList_reback_data(); List<ReturnInfo> list = returnInfoVo.getList_reback_data();
for(ReturnInfo returnInfo:list) { for(ReturnInfo returnInfo:list) {
returnInfo.setContract_unid(s); returnInfo.setContract_unid(s);
...@@ -59,7 +59,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService { ...@@ -59,7 +59,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("===============查询回款信息====================="); logger.info("===============查询回款信息=====================");
if((boolean) contractServiceImpl.isDelete(s)){ if(!contractServiceImpl.isDelete(s)){
return returnInfoMapper.queryReturnInfo(s); return returnInfoMapper.queryReturnInfo(s);
}else { }else {
failCode.setEcode("100"); failCode.setEcode("100");
...@@ -80,7 +80,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService { ...@@ -80,7 +80,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("==============修改回款信息==================="); logger.info("==============修改回款信息===================");
if((boolean) contractServiceImpl.isDelete(s)) { if(! contractServiceImpl.isDelete(s)) {
List<ReturnInfo> list = returnInfoVo.getList_reback_data(); List<ReturnInfo> list = returnInfoVo.getList_reback_data();
for(ReturnInfo returnInfo:list) { for(ReturnInfo returnInfo:list) {
returnInfo.setContract_unid(s); returnInfo.setContract_unid(s);
...@@ -106,7 +106,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService { ...@@ -106,7 +106,7 @@ public class ReturnInfoServiceImpl implements ReturnInfoService {
// TODO Auto-generated method stub // TODO Auto-generated method stub
try { try {
logger.info("==============删除回款信息==================="); logger.info("==============删除回款信息===================");
if((boolean) contractServiceImpl.isDelete(s)) { if(!contractServiceImpl.isDelete(s)) {
List<ReturnInfo> list = paymentAgreeVo.getReback_unids(); List<ReturnInfo> list = paymentAgreeVo.getReback_unids();
for(ReturnInfo returnInfo:list) { for(ReturnInfo returnInfo:list) {
returnInfo.setContract_unid(s); returnInfo.setContract_unid(s);
......
package com.vion.financial.utils;
import java.io.IOException;
import java.nio.charset.Charset;
import java.util.Map;
import org.apache.commons.lang3.StringUtils;
import org.apache.http.HttpResponse;
import org.apache.http.client.ClientProtocolException;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpDelete;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.client.methods.HttpPut;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.client.DefaultHttpClient;
import org.apache.http.util.EntityUtils;
public class HttpNetClient {
public static String doGet(String url,String atoken) {
String result = "";
HttpResponse response;
if (url != null && url.length() != 0) {
HttpGet httpGet = new HttpGet(url);
httpGet.setHeader("Accept-Encoding", "gzip, deflate");
httpGet.setHeader("Accept-Language", "zh-CN");
httpGet.setHeader("Accept",
"application/json, application/xml, text/html, text/*, image/*, */*");
httpGet.setHeader("authorization",atoken);
try {
response = new DefaultHttpClient().execute(httpGet);
if (response != null) {
int statusCode = response.getStatusLine().getStatusCode();
if (statusCode == 200 || statusCode == 403) {
result = EntityUtils.toString(response.getEntity());
}
}
} catch (Exception e) {
e.printStackTrace();
}
}
return result;
}
public static String doPost(String url, String msg,String authorization) {
HttpResponse response;
String result = "";
if (url != null && url.length() != 0) {
HttpPost post = new HttpPost(url);
//post.setHeader("Accept-Encoding", "gzip, deflate");
//post.setHeader("Accept-Language", "zh-CN");
post.setHeader("Accept","application/json, application/xml, text/html, text/*, image/*, */*");
post.setHeader("Content-type", "application/json; charset=utf-8");
if(StringUtils.isNotBlank(authorization)){
post.setHeader("authorization", authorization);
}
DefaultHttpClient client = new DefaultHttpClient();
try {
StringEntity se = new StringEntity(msg,String.valueOf(Charset.forName("utf-8")));
se.setContentEncoding("UTF-8");
se.setContentType("application/json");
post.setEntity(se);
response = client.execute(post);
System.out.println("response:" + response);
if (response != null) {
int statusCode = response.getStatusLine().getStatusCode();
//if (statusCode == 200 || statusCode == 403) {
result = EntityUtils.toString(response.getEntity());
//}
}
}catch (Exception e) {
e.printStackTrace();
}
}
return result;
}
public static String doPut(String url, String msg) {
String result = "";
if (url != null && url.length() > 0) {
StringBuilder sb = new StringBuilder();;
HttpPut request = new HttpPut(url);
String sck = sb.toString();
if (sck.length() > 0) {
request.setHeader("Cookie", sck);
}
request.setHeader("Accept-Encoding", "gzip, deflate");
request.setHeader("Accept-Language", "zh-CN");
request.setHeader("Accept",
"application/json, application/xml, text/html, text/*, image/*, */*");
DefaultHttpClient client = new DefaultHttpClient();
HttpResponse response;
try {
StringEntity se = new StringEntity(msg,String.valueOf(Charset.forName("utf-8")));
se.setContentEncoding("UTF-8");
request.setEntity(se);
response = client.execute(request);
if (response != null) {
int statusCode = response.getStatusLine().getStatusCode();
if (statusCode == 200 || statusCode == 403) {
result = EntityUtils.toString(response.getEntity());
}
}
} catch (Exception e) {
e.printStackTrace();
}
}
return result;
}
public static String doDelete(String url) {
HttpResponse response;
String result = "";
if (url != null && url.length() != 0) {
HttpDelete delete = new HttpDelete(url);
delete.setHeader("Accept-Encoding", "gzip, deflate");
delete.setHeader("Accept-Language", "zh-CN");
delete.setHeader("Accept",
"application/json, application/xml, text/html, text/*, image/*, */*");
try {
response = new DefaultHttpClient().execute(delete);
if (response != null) {
int statusCode = response.getStatusLine().getStatusCode();
if (statusCode == 200 || statusCode == 403) {
result = EntityUtils.toString(response.getEntity());
}
}
} catch (Exception e) {
e.printStackTrace();
}
}
return result;
}
public static String getAuthority(String url,String authorization,String msg) throws ClientProtocolException, IOException{
//参数+解决中文乱码问题
StringEntity entity = new StringEntity(msg, String.valueOf(Charset.forName("UTF-8")));
entity.setContentEncoding("UTF-8");
entity.setContentType("application/json");
HttpPost post = new HttpPost(url);
post.setHeader("authorization", authorization);
post.setEntity(entity);
HttpClient client = new DefaultHttpClient();
HttpResponse response = client.execute(post);
String result="";
if (response != null) {
int statusCode = response.getStatusLine().getStatusCode();
result = EntityUtils.toString(response.getEntity());
Map map = JavaBean2Json.Json2JavaBean(result, Map.class);
map.put("responseStatusCode", statusCode);
result = JavaBean2Json.javaBean2Json(map);
}
return result;
}
}
package com.vion.financial.utils;
import java.beans.BeanInfo;
import java.beans.IntrospectionException;
import java.beans.Introspector;
import java.beans.PropertyDescriptor;
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import net.sf.json.JSONArray;
import net.sf.json.JSONObject;
import net.sf.json.JsonConfig;
import net.sf.json.util.PropertyFilter;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.ObjectMapper;
public class JavaBean2Json {
public static String javaBean2Json(Object obj) {
return JSONObject.fromObject(obj,getJsonConfig()).toString();
}
public static <T> T Json2JavaBean(String json,Class<T> clas) {
try {
ObjectMapper om = new ObjectMapper();
om.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
return om.readValue(json, clas);
} catch (Exception e) {
JSONObject jsb = new JSONObject();
return (T) jsb.toBean(JSONObject.fromObject(json), clas, getJsonConfig());
}
}
/**
* json转List
* @param json
* @param clazz
* @param <T>
* @return
*/
public static <T> List<T> json2List(String json,Class<T> clazz) {
if(json.startsWith("[")){//json.indexOf("[")==0
JSONArray array = JSONArray.fromObject(json);
List<T> list = JSONArray.toList(array, clazz);
return list;
}
return null;
}
/**
* json转Array
* @param json
* @param clazz
* @param <T>
* @return
*/
public static <T> T[] json2Array(String json,Class<T> clazz) {
if(json.indexOf("[")==0){
JSONArray array = JSONArray.fromObject(json);
T[] ray = (T[]) JSONArray.toArray(array, clazz);
return ray;
}
return null;
}
private static JsonConfig getJsonConfig(){
JsonConfig jsonConfig = new JsonConfig();
jsonConfig.setJsonPropertyFilter(new PropertyFilter() {
public boolean apply(Object source/* 属性的拥有者 */, String name /* 属性名字 */,Object value/* 属性值 */) {
if(value instanceof List){
List<Object> list = (List<Object>) value;
if (list == null || list.size()==0) {
return true;
}
}else if(value instanceof Map){
Map map = (Map) value;
if (map == null || map.size() == 0) {
return true;
}
}
return null == value || "".equals(value);
}
});
return jsonConfig;
}
public static void jsonToMap(String json, Map map) {
JSONObject jsonObject = JSONObject.fromObject(json);
populate(jsonObject, map);
}
private static void populate(JSONObject jsonObject, Map map) {
for (Iterator iterator = jsonObject.entrySet().iterator(); iterator
.hasNext();) {
String entryStr = String.valueOf(iterator.next());
String key = entryStr.substring(0, entryStr.indexOf("="));
String value = entryStr.substring(entryStr.indexOf("=") + 1,entryStr.length());
if (jsonObject.get(key).getClass().equals(JSONObject.class)) {
HashMap _map = new HashMap();
map.put(key, _map);
populate(jsonObject.getJSONObject(key), ((Map) (_map)));
} else if (jsonObject.get(key).getClass().equals(JSONArray.class)) {
ArrayList list = new ArrayList();
map.put(key, list);
populateArray(jsonObject.getJSONArray(key), list);
} else {
map.put(key, jsonObject.get(key));
}
}
}
private static void populateArray(JSONArray jsonArray, List list) {
for (int i = 0; i < jsonArray.size(); i++)
if (jsonArray.get(i).getClass().equals(JSONArray.class)) {
ArrayList _list = new ArrayList();
list.add(_list);
populateArray(jsonArray.getJSONArray(i), _list);
} else if (jsonArray.get(i).getClass().equals(JSONObject.class)) {
HashMap _map = new HashMap();
list.add(_map);
populate(jsonArray.getJSONObject(i), _map);
} else {
list.add(jsonArray.get(i));
}
}
/***
* 判断客户端发过来的信息是否是json格式
*
* @param json
* @return
*/
public static boolean isJson(String json) {
try {
JSONObject.fromObject(json);
return true;
} catch (Exception e) {
return false;
}
}
@SuppressWarnings("rawtypes")
public static <T> T convertMap(Class<T> type, Map map)
throws IntrospectionException, IllegalAccessException,
InstantiationException, InvocationTargetException {
BeanInfo beanInfo = Introspector.getBeanInfo(type); // 获取类属性
T obj = (T) type.newInstance(); // 创建 JavaBean 对象
// 给 JavaBean 对象的属性赋值
PropertyDescriptor[] propertyDescriptors = beanInfo.getPropertyDescriptors();
for (int i = 0; i< propertyDescriptors.length; i++) {
PropertyDescriptor descriptor = propertyDescriptors[i];
String propertyName = descriptor.getName();
if (map.containsKey(propertyName)) {
// 下面一句可以 try 起来,这样当一个属性赋值失败的时候就不会影响其他属性赋值。
try {
Object value = map.get(propertyName);
Object[] args = new Object[1];
args[0] = value;
descriptor.getWriteMethod().invoke(obj, args);
} catch (IllegalArgumentException e) {
}
}
}
return obj;
}
}
...@@ -5,51 +5,65 @@ import java.util.List; ...@@ -5,51 +5,65 @@ import java.util.List;
import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include; import com.fasterxml.jackson.annotation.JsonInclude.Include;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.vion.financial.entity.Appendix; import com.vion.financial.entity.Appendix;
import com.vion.financial.entity.PaymentAgree; import com.vion.financial.entity.PaymentAgree;
import com.vion.financial.serializer.DateYMDHMSJsonSerializer;
@JsonInclude(value=Include.NON_NULL) @JsonInclude(value=Include.NON_NULL)
public class ContractVo extends SelectVo{ public class ContractVo extends SelectVo{
private String contract_unid; private String contract_unid;
private String salesperson_unid; private String salesperson_unid;
private int project_unid; private Integer project_unid;
private int customer_unid; private String project_name;
private String customer_name;
private Integer customer_unid;
private String province; private String province;
private String city; private String city;
private String county; private String county;
private int guarantee_period; private Integer guarantee_period;
private Date sign_date; private Date sign_date;
private String product_line_type; private String product_line_type;
private String contract_state; private String contract_state;
private String contract_type; private String contract_type;
private double contract_amount; private Double contract_amount;
private double deduct_amount; private Double deduct_amount;
private String contract_amount_note; private String contract_amount_note;
private double stop_amount; private Double stop_amount;
private String reback_note; private String reback_note;
private double exemptions_amount; private Double exemptions_amount;
private String contract_remain_note; private String contract_remain_note;
private boolean is_archive; private Boolean is_archive;
private double bad_amount; private Double bad_amount;
private String bad_amount_note; private String bad_amount_note;
private double confirm_income_amount; private Double confirm_income_amount;
private String amount_state_unid; private String amount_state_unid;
private Date start_guarantee_date; private Date start_guarantee_date;
private Date end_guarantee_date; private Date end_guarantee_date;
private String mainten_start_point; private String mainten_start_point;
private String contract_note; private String contract_note;
private boolean is_delete; private Boolean is_delete;
private List<Integer> appendix_unids; private List<Integer> appendix_unids;
private List<Appendix> appendix_list; private List<Appendix> appendix_list;
private String business_table; private String business_table;
private String business_unid; private String business_unid;
private double total_reback_amount; private Double total_reback_amount;
private double contract_remain; private Double contract_remain;
private Double total_receive_amount;
private Double total_amount_remain;
private Integer over_days;
private String year;
private String month;
private String salesperson_name;
private Integer total_number;
private Integer list_size;
private Integer offset;
private List<String> salesperson_unids;
private List<PaymentAgree> paymentAgree_list; private List<PaymentAgree> paymentAgree_list;
private List<String> contract_unids; private List<String> contract_unids;
//private List<> payment_data; //private List<> payment_data;
public String getContract_unid() { public String getContract_unid() {
return contract_unid; return contract_unid;
} }
...@@ -62,16 +76,16 @@ public class ContractVo extends SelectVo{ ...@@ -62,16 +76,16 @@ public class ContractVo extends SelectVo{
public void setSalesperson_unid(String salesperson_unid) { public void setSalesperson_unid(String salesperson_unid) {
this.salesperson_unid = salesperson_unid; this.salesperson_unid = salesperson_unid;
} }
public int getProject_unid() { public Integer getProject_unid() {
return project_unid; return project_unid;
} }
public void setProject_unid(int project_unid) { public void setProject_unid(Integer project_unid) {
this.project_unid = project_unid; this.project_unid = project_unid;
} }
public int getCustomer_unid() { public Integer getCustomer_unid() {
return customer_unid; return customer_unid;
} }
public void setCustomer_unid(int customer_unid) { public void setCustomer_unid(Integer customer_unid) {
this.customer_unid = customer_unid; this.customer_unid = customer_unid;
} }
public String getProvince() { public String getProvince() {
...@@ -92,12 +106,13 @@ public class ContractVo extends SelectVo{ ...@@ -92,12 +106,13 @@ public class ContractVo extends SelectVo{
public void setCounty(String county) { public void setCounty(String county) {
this.county = county; this.county = county;
} }
public int getGuarantee_period() { public Integer getGuarantee_period() {
return guarantee_period; return guarantee_period;
} }
public void setGuarantee_period(int guarantee_period) { public void setGuarantee_period(Integer guarantee_period) {
this.guarantee_period = guarantee_period; this.guarantee_period = guarantee_period;
} }
@JsonSerialize(using = DateYMDHMSJsonSerializer.class)
public Date getSign_date() { public Date getSign_date() {
return sign_date; return sign_date;
} }
...@@ -122,16 +137,16 @@ public class ContractVo extends SelectVo{ ...@@ -122,16 +137,16 @@ public class ContractVo extends SelectVo{
public void setContract_type(String contract_type) { public void setContract_type(String contract_type) {
this.contract_type = contract_type; this.contract_type = contract_type;
} }
public double getContract_amount() { public Double getContract_amount() {
return contract_amount; return contract_amount;
} }
public void setContract_amount(double contract_amount) { public void setContract_amount(Double contract_amount) {
this.contract_amount = contract_amount; this.contract_amount = contract_amount;
} }
public double getDeduct_amount() { public Double getDeduct_amount() {
return deduct_amount; return deduct_amount;
} }
public void setDeduct_amount(double deduct_amount) { public void setDeduct_amount(Double deduct_amount) {
this.deduct_amount = deduct_amount; this.deduct_amount = deduct_amount;
} }
public String getContract_amount_note() { public String getContract_amount_note() {
...@@ -140,10 +155,10 @@ public class ContractVo extends SelectVo{ ...@@ -140,10 +155,10 @@ public class ContractVo extends SelectVo{
public void setContract_amount_note(String contract_amount_note) { public void setContract_amount_note(String contract_amount_note) {
this.contract_amount_note = contract_amount_note; this.contract_amount_note = contract_amount_note;
} }
public double getStop_amount() { public Double getStop_amount() {
return stop_amount; return stop_amount;
} }
public void setStop_amount(double stop_amount) { public void setStop_amount(Double stop_amount) {
this.stop_amount = stop_amount; this.stop_amount = stop_amount;
} }
public String getReback_note() { public String getReback_note() {
...@@ -152,10 +167,10 @@ public class ContractVo extends SelectVo{ ...@@ -152,10 +167,10 @@ public class ContractVo extends SelectVo{
public void setReback_note(String reback_note) { public void setReback_note(String reback_note) {
this.reback_note = reback_note; this.reback_note = reback_note;
} }
public double getExemptions_amount() { public Double getExemptions_amount() {
return exemptions_amount; return exemptions_amount;
} }
public void setExemptions_amount(double exemptions_amount) { public void setExemptions_amount(Double exemptions_amount) {
this.exemptions_amount = exemptions_amount; this.exemptions_amount = exemptions_amount;
} }
public String getContract_remain_note() { public String getContract_remain_note() {
...@@ -164,16 +179,16 @@ public class ContractVo extends SelectVo{ ...@@ -164,16 +179,16 @@ public class ContractVo extends SelectVo{
public void setContract_remain_note(String contract_remain_note) { public void setContract_remain_note(String contract_remain_note) {
this.contract_remain_note = contract_remain_note; this.contract_remain_note = contract_remain_note;
} }
public boolean isIs_archive() { public Boolean getIs_archive() {
return is_archive; return is_archive;
} }
public void setIs_archive(boolean is_archive) { public void setIs_archive(Boolean is_archive) {
this.is_archive = is_archive; this.is_archive = is_archive;
} }
public double getBad_amount() { public Double getBad_amount() {
return bad_amount; return bad_amount;
} }
public void setBad_amount(double bad_amount) { public void setBad_amount(Double bad_amount) {
this.bad_amount = bad_amount; this.bad_amount = bad_amount;
} }
public String getBad_amount_note() { public String getBad_amount_note() {
...@@ -182,10 +197,11 @@ public class ContractVo extends SelectVo{ ...@@ -182,10 +197,11 @@ public class ContractVo extends SelectVo{
public void setBad_amount_note(String bad_amount_note) { public void setBad_amount_note(String bad_amount_note) {
this.bad_amount_note = bad_amount_note; this.bad_amount_note = bad_amount_note;
} }
public double getConfirm_income_amount() {
public Double getConfirm_income_amount() {
return confirm_income_amount; return confirm_income_amount;
} }
public void setConfirm_income_amount(double confirm_income_amount) { public void setConfirm_income_amount(Double confirm_income_amount) {
this.confirm_income_amount = confirm_income_amount; this.confirm_income_amount = confirm_income_amount;
} }
public String getAmount_state_unid() { public String getAmount_state_unid() {
...@@ -194,12 +210,14 @@ public class ContractVo extends SelectVo{ ...@@ -194,12 +210,14 @@ public class ContractVo extends SelectVo{
public void setAmount_state_unid(String amount_state_unid) { public void setAmount_state_unid(String amount_state_unid) {
this.amount_state_unid = amount_state_unid; this.amount_state_unid = amount_state_unid;
} }
@JsonSerialize(using = DateYMDHMSJsonSerializer.class)
public Date getStart_guarantee_date() { public Date getStart_guarantee_date() {
return start_guarantee_date; return start_guarantee_date;
} }
public void setStart_guarantee_date(Date start_guarantee_date) { public void setStart_guarantee_date(Date start_guarantee_date) {
this.start_guarantee_date = start_guarantee_date; this.start_guarantee_date = start_guarantee_date;
} }
@JsonSerialize(using = DateYMDHMSJsonSerializer.class)
public Date getEnd_guarantee_date() { public Date getEnd_guarantee_date() {
return end_guarantee_date; return end_guarantee_date;
} }
...@@ -218,10 +236,10 @@ public class ContractVo extends SelectVo{ ...@@ -218,10 +236,10 @@ public class ContractVo extends SelectVo{
public void setContract_note(String contract_note) { public void setContract_note(String contract_note) {
this.contract_note = contract_note; this.contract_note = contract_note;
} }
public boolean isIs_delete() { public Boolean getIs_delete() {
return is_delete; return is_delete;
} }
public void setIs_delete(boolean is_delete) { public void setIs_delete(Boolean is_delete) {
this.is_delete = is_delete; this.is_delete = is_delete;
} }
public List<Integer> getAppendix_unids() { public List<Integer> getAppendix_unids() {
...@@ -230,6 +248,12 @@ public class ContractVo extends SelectVo{ ...@@ -230,6 +248,12 @@ public class ContractVo extends SelectVo{
public void setAppendix_unids(List<Integer> appendix_unids) { public void setAppendix_unids(List<Integer> appendix_unids) {
this.appendix_unids = appendix_unids; this.appendix_unids = appendix_unids;
} }
public List<Appendix> getAppendix_list() {
return appendix_list;
}
public void setAppendix_list(List<Appendix> appendix_list) {
this.appendix_list = appendix_list;
}
public String getBusiness_table() { public String getBusiness_table() {
return business_table; return business_table;
} }
...@@ -242,11 +266,17 @@ public class ContractVo extends SelectVo{ ...@@ -242,11 +266,17 @@ public class ContractVo extends SelectVo{
public void setBusiness_unid(String business_unid) { public void setBusiness_unid(String business_unid) {
this.business_unid = business_unid; this.business_unid = business_unid;
} }
public List<Appendix> getAppendix_list() { public Double getTotal_reback_amount() {
return appendix_list; return total_reback_amount;
} }
public void setAppendix_list(List<Appendix> appendix_list) { public void setTotal_reback_amount(Double total_reback_amount) {
this.appendix_list = appendix_list; this.total_reback_amount = total_reback_amount;
}
public Double getContract_remain() {
return contract_remain;
}
public void setContract_remain(Double contract_remain) {
this.contract_remain = contract_remain;
} }
public List<PaymentAgree> getPaymentAgree_list() { public List<PaymentAgree> getPaymentAgree_list() {
return paymentAgree_list; return paymentAgree_list;
...@@ -260,17 +290,77 @@ public class ContractVo extends SelectVo{ ...@@ -260,17 +290,77 @@ public class ContractVo extends SelectVo{
public void setContract_unids(List<String> contract_unids) { public void setContract_unids(List<String> contract_unids) {
this.contract_unids = contract_unids; this.contract_unids = contract_unids;
} }
public double getTotal_reback_amount() { public String getProject_name() {
return total_reback_amount; return project_name;
} }
public void setTotal_reback_amount(double total_reback_amount) { public void setProject_name(String project_name) {
this.total_reback_amount = total_reback_amount; this.project_name = project_name;
} }
public double getContract_remain() { public String getCustomer_name() {
return contract_remain; return customer_name;
} }
public void setContract_remain(double contract_remain) { public void setCustomer_name(String customer_name) {
this.contract_remain = contract_remain; this.customer_name = customer_name;
}
public Double getTotal_receive_amount() {
return total_receive_amount;
}
public void setTotal_receive_amount(Double total_receive_amount) {
this.total_receive_amount = total_receive_amount;
}
public Double getTotal_amount_remain() {
return total_amount_remain;
}
public void setTotal_amount_remain(Double total_amount_remain) {
this.total_amount_remain = total_amount_remain;
}
public Integer getOver_days() {
return over_days;
}
public void setOver_days(Integer over_days) {
this.over_days = over_days;
}
public String getYear() {
return year;
}
public void setYear(String year) {
this.year = year;
}
public String getMonth() {
return month;
}
public void setMonth(String month) {
this.month = month;
}
public List<String> getSalesperson_unids() {
return salesperson_unids;
}
public void setSalesperson_unids(List<String> salesperson_unids) {
this.salesperson_unids = salesperson_unids;
}
public String getSalesperson_name() {
return salesperson_name;
}
public void setSalesperson_name(String salesperson_name) {
this.salesperson_name = salesperson_name;
}
public Integer getTotal_number() {
return total_number;
}
public void setTotal_number(Integer total_number) {
this.total_number = total_number;
}
public Integer getList_size() {
return list_size;
}
public void setList_size(Integer list_size) {
this.list_size = list_size;
}
public Integer getOffset() {
return offset;
}
public void setOffset(Integer offset) {
this.offset = offset;
} }
......
package com.vion.financial.vo;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
@JsonInclude(value=Include.NON_NULL)
public class ResultVo {
private Integer total_number;
private Integer list_size;
private Integer offset;
List<ContractVo> list_data;
public Integer getTotal_number() {
return total_number;
}
public void setTotal_number(Integer total_number) {
this.total_number = total_number;
}
public Integer getList_size() {
return list_size;
}
public void setList_size(Integer list_size) {
this.list_size = list_size;
}
public Integer getOffset() {
return offset;
}
public void setOffset(Integer offset) {
this.offset = offset;
}
public List<ContractVo> getList_data() {
return list_data;
}
public void setList_data(List<ContractVo> list_data) {
this.list_data = list_data;
}
}
package com.vion.financial.vo; package com.vion.financial.vo;
import java.util.Date; import java.util.Date;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include; import com.fasterxml.jackson.annotation.JsonInclude.Include;
...@@ -13,24 +14,172 @@ public class SelectVo { ...@@ -13,24 +14,172 @@ public class SelectVo {
private String province; //所属省份 private String province; //所属省份
private String city; //所属市 private String city; //所属市
private String county; //所属县 private String county; //所属县
private int guarantee_period; //保质周 private Integer guarantee_period; //保质周
private String year; //所属年份 private String year; //所属年份
private String month; //所属月份 private String month; //所属月份
private String product_line_type; //生产线类型 private String product_line_type; //生产线类型
private String contract_state; //合同状态 private String contract_state; //合同状态
private String contract_type; //合同性质 private String contract_type; //合同性质
private String acceptanc_type; //验收类型 private String acceptanc_type; //验收类型
private boolean is_archive; //是否归档 private Boolean is_archive; //是否归档
private double confirm_income_amount; //确认收入金额 private Double confirm_income_amount; //确认收入金额
private String amount_state_unid; //账款状态 private String amount_state_unid; //账款状态
private Date start_date; //设置开始查询时间 private Date start_date; //设置开始查询时间
private Date end_date; //设置结束时间 private Date end_date; //设置结束时间
private double amount_point; //设置金额查询节点 private Double amount_point; //设置金额查询节点
private int overdays_point; //逾期天数查询节点 private Integer overdays_point; //逾期天数查询节点
private double leave_amount_point; //账款余额查询节点 private Double leave_amount_point; //账款余额查询节点
private int offset; //设置查询起始位置 private Integer offset; //设置查询起始位置
private int limit; //设置每次查询条数 private Integer limit; //设置每次查询条数
private List<String> salesperson_unids;
/* /*
* 查询条件 * 查询条件
*/ */
public String getSalesperson_name__like() {
return salesperson_name__like;
}
public void setSalesperson_name__like(String salesperson_name__like) {
this.salesperson_name__like = salesperson_name__like;
}
public String getProject_name__like() {
return project_name__like;
}
public void setProject_name__like(String project_name__like) {
this.project_name__like = project_name__like;
}
public String getCustomer_name__like() {
return customer_name__like;
}
public void setCustomer_name__like(String customer_name__like) {
this.customer_name__like = customer_name__like;
}
public String getProvince() {
return province;
}
public void setProvince(String province) {
this.province = province;
}
public String getCity() {
return city;
}
public void setCity(String city) {
this.city = city;
}
public String getCounty() {
return county;
}
public void setCounty(String county) {
this.county = county;
}
public Integer getGuarantee_period() {
return guarantee_period;
}
public void setGuarantee_period(Integer guarantee_period) {
this.guarantee_period = guarantee_period;
}
public String getYear() {
return year;
}
public void setYear(String year) {
this.year = year;
}
public String getMonth() {
return month;
}
public void setMonth(String month) {
this.month = month;
}
public String getProduct_line_type() {
return product_line_type;
}
public void setProduct_line_type(String product_line_type) {
this.product_line_type = product_line_type;
}
public String getContract_state() {
return contract_state;
}
public void setContract_state(String contract_state) {
this.contract_state = contract_state;
}
public String getContract_type() {
return contract_type;
}
public void setContract_type(String contract_type) {
this.contract_type = contract_type;
}
public String getAcceptanc_type() {
return acceptanc_type;
}
public void setAcceptanc_type(String acceptanc_type) {
this.acceptanc_type = acceptanc_type;
}
public Boolean getIs_archive() {
return is_archive;
}
public void setIs_archive(Boolean is_archive) {
this.is_archive = is_archive;
}
public Double getConfirm_income_amount() {
return confirm_income_amount;
}
public void setConfirm_income_amount(Double confirm_income_amount) {
this.confirm_income_amount = confirm_income_amount;
}
public String getAmount_state_unid() {
return amount_state_unid;
}
public void setAmount_state_unid(String amount_state_unid) {
this.amount_state_unid = amount_state_unid;
}
public Date getStart_date() {
return start_date;
}
public void setStart_date(Date start_date) {
this.start_date = start_date;
}
public Date getEnd_date() {
return end_date;
}
public void setEnd_date(Date end_date) {
this.end_date = end_date;
}
public Double getAmount_point() {
return amount_point;
}
public void setAmount_point(Double amount_point) {
this.amount_point = amount_point;
}
public Integer getOverdays_point() {
return overdays_point;
}
public void setOverdays_point(Integer overdays_point) {
this.overdays_point = overdays_point;
}
public Double getLeave_amount_point() {
return leave_amount_point;
}
public void setLeave_amount_point(Double leave_amount_point) {
this.leave_amount_point = leave_amount_point;
}
public Integer getOffset() {
return offset;
}
public void setOffset(Integer offset) {
this.offset = offset;
}
public Integer getLimit() {
return limit;
}
public void setLimit(Integer limit) {
this.limit = limit;
}
public List<String> getSalesperson_unids() {
return salesperson_unids;
}
public void setSalesperson_unids(List<String> salesperson_unids) {
this.salesperson_unids = salesperson_unids;
}
} }
...@@ -37,11 +37,15 @@ mybatis: ...@@ -37,11 +37,15 @@ mybatis:
logging: logging:
level: level:
root: INFO root: DEBUG
pattern: pattern:
level: INFO level: DEBUG
console: "[financial_serv]-[%d{yyyy-MM-dd HH:mm:ss.SSS}]-%m%n" console: "[financial_serv]-[%d{yyyy-MM-dd HH:mm:ss.SSS}]-%m%n"
path: F:\LOG\ path: F:\LOG\
finance:
authurl: http://192.168.9.162:20080/api/v1/auth/users
#pagehelper: #pagehelper:
# helperDialect: postgresql # helperDialect: postgresql
# reasonable: true # reasonable: true
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!