Merge remote-tracking branch 'origin/main'

product
chuang 2 years ago
commit 0ea57d94b6

@ -9,8 +9,8 @@ import java.util.Date;
/**
*
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
@ -18,7 +18,7 @@ import java.util.Date;
*/
@Data
@TableName("jg_natural")
public class Jg_naturalEntity {
public class Jg_naturalEntity {
@TableId("ID")
private String id;
@ -68,4 +68,19 @@ public class Jg_naturalEntity {
@TableField("CONTACT")
private String contact;
@TableField("IDENTITY")
private String identity;
@TableField("BANK_ACCOUNT")
private String bankAccount;
@TableField("BANK")
private String bank;
@TableField("BANK_NO")
private String bankNo;
@TableField("PHOTOS")
private String photos;
}

@ -62,8 +62,23 @@ public class Jg_naturalMobileEntity {
@TableField("CONTACT")
private String contact;
//运输总量
@TableField("IDENTITY")
private String identity;
@TableField("BANK_ACCOUNT")
private String bankAccount;
@TableField("BANK")
private String bank;
@TableField("BANK_NO")
private String bankNo;
@TableField("PHOTOS")
private String photos;
//运输总量
private Integer naturalSum;
// 总次数
// 总次数
private Integer naturalCount;
}

@ -7,36 +7,72 @@ import lombok.Data;
/**
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
* @ 2023-02-01
*/
@Data
public class Jg_naturalCrForm {
public class Jg_naturalCrForm {
/** 姓名 **/
/**
*
**/
@JsonProperty("name")
private String name;
/** 地址 **/
/**
*
**/
@JsonProperty("adress")
private String adress;
/** 手机号 **/
/**
*
**/
@JsonProperty("contact")
private String contact;
/** 录入人 **/
/**
*
**/
@JsonProperty("identity")
private String identity;
/**
*
**/
@JsonProperty("bankAccount")
private String bankAccount;
/**
*
**/
@JsonProperty("bank")
private String bank;
/**
*
**/
@JsonProperty("bankNo")
private String bankNo;
/**
*
**/
@JsonProperty("photos")
private String photos;
/**
*
**/
@JsonProperty("creatorUserName")
private String creatorUserName;
/** 创建时间 **/
/**
*
**/
@JsonProperty("creatorTime")
private String creatorTime;
}

@ -8,39 +8,80 @@ import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;
import java.util.Date;
/**
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
* @ 2023-02-01
*/
@Data
public class Jg_naturalInfoVO{
/** 主键 **/
@JsonProperty("id")
private String id;
/** 姓名 **/
@JsonProperty("name")
private String name;
/** 地址 **/
@JsonProperty("adress")
private String adress;
/** 手机号 **/
@JsonProperty("contact")
private String contact;
/** 录入人 **/
@JsonProperty("creatorUserName")
private String creatorUserName;
/** 创建时间 **/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
@JsonProperty("creatorTime")
private Date creatorTime;
public class Jg_naturalInfoVO {
/**
*
**/
@JsonProperty("id")
private String id;
/**
*
**/
@JsonProperty("name")
private String name;
/**
*
**/
@JsonProperty("adress")
private String adress;
/**
*
**/
@JsonProperty("contact")
private String contact;
/**
*
**/
@JsonProperty("identity")
private String identity;
/**
*
**/
@JsonProperty("bankAccount")
private String bankAccount;
/**
*
**/
@JsonProperty("bank")
private String bank;
/**
*
**/
@JsonProperty("bankNo")
private String bankNo;
/**
*
**/
@JsonProperty("photos")
private String photos;
/**
*
**/
@JsonProperty("creatorUserName")
private String creatorUserName;
/**
*
**/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@JsonProperty("creatorTime")
private Date creatorTime;
}

@ -4,8 +4,6 @@ import jnpf.base.Pagination;
import lombok.Data;
/**
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
@ -14,13 +12,21 @@ import lombok.Data;
@Data
public class Jg_naturalListQuery extends Pagination {
/** 姓名 */
private String name;
/**
*
*/
private String name;
/** 手机号 */
private String contact;
/**
* id
*/
/**
*
*/
private String contact;
/**
*
*/
private String bankAccount;
/**
* id
*/
private String menuId;
}

@ -10,44 +10,86 @@ import lombok.Data;
import java.util.Date;
/**
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
* @ 2023-02-01
*/
@Data
public class Jg_naturalListVO{
public class Jg_naturalListVO {
/** 主键 */
/**
*
*/
private String id;
/** 姓名 **/
/**
*
**/
@JsonProperty("name")
private String name;
/** 地址 **/
/**
*
**/
@JsonProperty("adress")
private String adress;
/** 手机号 **/
/**
*
**/
@JsonProperty("contact")
private String contact;
/**
*
**/
@JsonProperty("identity")
private String identity;
/** 录入人 **/
/**
*
**/
@JsonProperty("bankAccount")
private String bankAccount;
/**
*
**/
@JsonProperty("bank")
private String bank;
/**
*
**/
@JsonProperty("bankNo")
private String bankNo;
/**
*
**/
@JsonProperty("photos")
private String photos;
/**
*
**/
@JsonProperty("creatorUserName")
private String creatorUserName;
/** 创建时间 **/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
/**
*
**/
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
@JsonProperty("creatorTime")
private Date creatorTime;
private Date creatorTime;
//运输总量
@JsonProperty("naturalSum")

@ -5,8 +5,6 @@ import jnpf.base.Pagination;
import lombok.Data;
/**
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
@ -15,13 +13,21 @@ import lombok.Data;
@Data
public class Jg_naturalPagination extends Pagination {
/** 姓名 */
private String name;
/**
*
*/
private String name;
/** 手机号 */
private String contact;
/**
* id
*/
private String menuId;
/**
*
*/
private String contact;
/**
*
*/
private String bankAccount;
/**
* id
*/
private String menuId;
}

@ -4,8 +4,6 @@ import jnpf.base.Pagination;
import lombok.Data;
/**
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
@ -21,9 +19,17 @@ public class Jg_naturalPaginationExportModel extends Pagination {
private String dataType;
/** 姓名 */
/**
*
*/
private String name;
/** 手机号 */
/**
*
*/
private String contact;
/**
*
*/
private String bankAccount;
}

@ -6,40 +6,84 @@ import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;
/**
*
*
* @ V3.2.0
* @ LINKAGE-BOOT
* @ LINKAGE-BOOT
* @ 2023-02-01
*/
@Data
public class Jg_naturalUpForm{
/** 主键 */
public class Jg_naturalUpForm {
/**
*
*/
private String id;
/** 姓名 **/
/**
*
**/
@JsonProperty("name")
private String name;
/** 地址 **/
/**
*
**/
@JsonProperty("adress")
private String adress;
/** 手机号 **/
/**
*
**/
@JsonProperty("contact")
private String contact;
/**
*
**/
@JsonProperty("identity")
private String identity;
/** 录入人 **/
/**
*
**/
@JsonProperty("bankAccount")
private String bankAccount;
/**
*
**/
@JsonProperty("bank")
private String bank;
/**
*
**/
@JsonProperty("bankNo")
private String bankNo;
/**
*
**/
@JsonProperty("photos")
private String photos;
/**
*
**/
@JsonProperty("creatorUserName")
private String creatorUserName;
/** 创建时间 **/
/**
*
**/
@JsonProperty("creatorTime")
private String creatorTime;

@ -134,6 +134,8 @@ public class ArinvoicesController {
public ActionResult create(@RequestBody @Valid ArinvoicesCrForm arinvoicesCrForm) throws DataException {
String mainId =RandomUtil.uuId();
UserInfo userInfo=userProvider.get();
arinvoicesCrForm.setCreatorUserName(userInfo.getUserId());
arinvoicesCrForm.setCreatorTime(DateUtil.getNow());
// arinvoicesCrForm.setDocumentNo(generaterSwapUtil.getBillNumber("arinvoices", false));
ArinvoicesEntity entity = JsonUtil.getJsonToBean(arinvoicesCrForm, ArinvoicesEntity.class);
SaleorderitemEntity saleorderitemEntity = saleorderitemService.getInfo(entity.getSalesOrderId());
@ -152,7 +154,9 @@ public class ArinvoicesController {
if (ObjectUtils.isNotEmpty(poundlistEntity)) {
poundlistEntity.setSalesStatus("2");//修改磅单状态
if (arinvoicesCrForm.getAmount() != null && arinvoicesCrForm.getInvoiceAmount() != null) {
if (arinvoicesCrForm.getInvoiceAmount().compareTo(arinvoicesCrForm.getAmount()) > -1) {
BigDecimal a = new BigDecimal(arinvoicesCrForm.getInvoiceAmount());
BigDecimal b = new BigDecimal(arinvoicesCrForm.getAmount());
if (a.compareTo(b) > -1) {
poundlistEntity.setIsExpense("1");//修改销项票状态
}
}

@ -31,11 +31,11 @@ public class ArinvoicesCrForm {
/** 金额 **/
@JsonProperty("amount")
private Integer amount;
private String amount;
/** 数量 **/
@JsonProperty("quantity")
private Integer quantity;
private String quantity;
/** 币别 **/
@JsonProperty("currency")
@ -51,11 +51,11 @@ public class ArinvoicesCrForm {
/** 发票金额 **/
@JsonProperty("invoiceAmount")
private Integer invoiceAmount;
private String invoiceAmount;
/** 发票数量 **/
@JsonProperty("invoiceQuantity")
private Integer invoiceQuantity;
private String invoiceQuantity;
/** 销售订单号 **/
@JsonProperty("salesOrderId")
@ -69,6 +69,14 @@ public class ArinvoicesCrForm {
@JsonProperty("customerId")
private String customerId;
/** 制单人 **/
@JsonProperty("creatorUserName")
private String creatorUserName;
/** 制单时间 **/
@JsonProperty("creatorTime")
private String creatorTime;
/** 子表数据 **/
@JsonProperty("arinvoices_item1List")
private List<Arinvoices_item1Model> arinvoices_item1List;

@ -35,11 +35,11 @@ public class ArinvoicesInfoVO{
/** 金额 **/
@JsonProperty("amount")
private Integer amount;
private String amount;
/** 数量 **/
@JsonProperty("quantity")
private Integer quantity;
private String quantity;
/** 币别 **/
@JsonProperty("currency")
@ -55,11 +55,11 @@ public class ArinvoicesInfoVO{
/** 发票金额 **/
@JsonProperty("invoiceAmount")
private Integer invoiceAmount;
private String invoiceAmount;
/** 发票数量 **/
@JsonProperty("invoiceQuantity")
private Integer invoiceQuantity;
private String invoiceQuantity;
/** 销售订单号 **/
@JsonProperty("salesOrderId")

@ -38,11 +38,11 @@ public class ArinvoicesListVO{
/** 金额 **/
@JsonProperty("amount")
private Integer amount;
private String amount;
/** 数量 **/
@JsonProperty("quantity")
private Integer quantity;
private String quantity;
/** 币别 **/
@JsonProperty("currency")
@ -61,11 +61,11 @@ public class ArinvoicesListVO{
/** 发票金额 **/
@JsonProperty("invoiceAmount")
private Integer invoiceAmount;
private String invoiceAmount;
/** 发票数量 **/
@JsonProperty("invoiceQuantity")
private Integer invoiceQuantity;
private String invoiceQuantity;
/** 销售订单号 **/
@JsonProperty("salesOrderId")

@ -37,12 +37,12 @@ public class ArinvoicesUpForm{
/** 金额 **/
@JsonProperty("amount")
private Integer amount;
private String amount;
/** 数量 **/
@JsonProperty("quantity")
private Integer quantity;
private String quantity;
/** 币别 **/
@ -62,12 +62,12 @@ public class ArinvoicesUpForm{
/** 发票金额 **/
@JsonProperty("invoiceAmount")
private Integer invoiceAmount;
private String invoiceAmount;
/** 发票数量 **/
@JsonProperty("invoiceQuantity")
private Integer invoiceQuantity;
private String invoiceQuantity;
/** 销售订单号 **/

@ -156,7 +156,7 @@ public class ArinvoicesServiceImpl extends ServiceImpl<ArinvoicesMapper, Arinvoi
}
//排序
if(StringUtil.isEmpty(arinvoicesPagination.getSidx())){
arinvoicesPagination.setSidx("CREATOR_TIME");
arinvoicesPagination.setSidx("BUSINESS_DATE");
arinvoicesPagination.setSort("DESC");
}else{
try {

@ -322,26 +322,44 @@ public class CollectionController {
@PostMapping
@Transactional
public ActionResult create(@RequestBody @Valid CollectionCrForm collectionCrForm) throws DataException {
if (collectionCrForm.getCollection_item0List().size()>0) {
SaleorderitemEntity saleorderitemEntity = saleorderitemService.getInfo(collectionCrForm.getCollection_item0List().get(0).getSalesorderId());
if (saleorderitemEntity.getAmountCollected() == null){
saleorderitemEntity.setAmountCollected(new BigDecimal(0));
}
if (saleorderitemEntity.getAmountCollected().equals(saleorderitemEntity.getPrice()) ||
saleorderitemEntity.getAmountCollected().compareTo(saleorderitemEntity.getPrice()) == 1){
return ActionResult.fail("已回完款,无需回款");
List<Collection_item0Entity> Collection_item0List = JsonUtil.getJsonToList(collectionCrForm.getCollection_item0List(),Collection_item0Entity.class);
for (Collection_item0Entity collectionItem0Entity : Collection_item0List){
if (collectionItem0Entity.getSalesorderId() != null){
SaleorderitemEntity saleorderitemEntity = saleorderitemService.getInfo(collectionCrForm.getCollection_item0List().get(0).getSalesorderId());
if (saleorderitemEntity.getAmountCollected() == null){
saleorderitemEntity.setAmountCollected(new BigDecimal(0));
}
if (saleorderitemEntity.getAmountCollected().equals(saleorderitemEntity.getPrice()) ||
saleorderitemEntity.getAmountCollected().compareTo(saleorderitemEntity.getPrice()) == 1){
return ActionResult.fail("已回完款,无需回款");
}
}else {
return ActionResult.fail("销售订单不存在");
}
}else {
return ActionResult.fail("销售订单不存在");
}
// if (collectionCrForm.getCollection_item0List().size()>0) {
//
// SaleorderitemEntity saleorderitemEntity = saleorderitemService.getInfo(collectionCrForm.getCollection_item0List().get(0).getSalesorderId());
// if (saleorderitemEntity.getAmountCollected() == null){
// saleorderitemEntity.setAmountCollected(new BigDecimal(0));
// }
// if (saleorderitemEntity.getAmountCollected().equals(saleorderitemEntity.getPrice()) ||
// saleorderitemEntity.getAmountCollected().compareTo(saleorderitemEntity.getPrice()) == 1){
// return ActionResult.fail("已回完款,无需回款");
// }
// }else {
// return ActionResult.fail("销售订单不存在");
// }
String mainId =RandomUtil.uuId();
UserInfo userInfo=userProvider.get();
collectionCrForm.setCreatorUserName(userInfo.getUserId());
collectionCrForm.setCreatorTime(DateUtil.getNow());
// collectionCrForm.setDocumentNo(generaterSwapUtil.getBillNumber("collection", false));
CollectionEntity entity = JsonUtil.getJsonToBean(collectionCrForm, CollectionEntity.class);
entity.setId(mainId);
entity.setStatus("0");
collectionService.save(entity);
List<Collection_item0Entity> Collection_item0List = JsonUtil.getJsonToList(collectionCrForm.getCollection_item0List(),Collection_item0Entity.class);
// List<Collection_item0Entity> Collection_item0List = JsonUtil.getJsonToList(collectionCrForm.getCollection_item0List(),Collection_item0Entity.class);
for(Collection_item0Entity entitys : Collection_item0List){
entitys.setId(RandomUtil.uuId());
entitys.setCollectionId(entity.getId());

@ -74,6 +74,10 @@ public class CollectionCrForm {
@JsonProperty("creatorUserName")
private String creatorUserName;
/** 制单时间 **/
@JsonProperty("creatorTime")
private String creatorTime;
/** 子表数据 **/
@JsonProperty("collection_item0List")
private List<Collection_item0Model> collection_item0List;

@ -17,26 +17,19 @@ import jnpf.config.ConfigValueUtil;
import jnpf.exception.DataException;
import jnpf.materialvo.entity.MaterialEntity;
import jnpf.materialvo.service.MaterialService;
import jnpf.model.EmployeeModel;
import jnpf.poundlist.entity.PoundlistEntity;
import jnpf.poundlist.service.PoundlistService;
import jnpf.purchaseback.entity.PurchaseorderEntity;
import jnpf.purchaseback.service.PurchaseorderService;
import jnpf.purchaseorder.entity.Purchaseorder_item0Entity;
import jnpf.purchaseorder.entity.PurchaseorderitemEntity;
import jnpf.purchaseorder.service.PurchaseorderitemService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.transaction.annotation.Transactional;
import jnpf.base.entity.ProvinceEntity;
import jnpf.invoices.model.invoices.*;
import jnpf.invoices.model.invoices.InvoicesPagination;
import jnpf.invoices.entity.*;
import jnpf.invoices.entity.InvoicesItem1Entity;
import jnpf.invoices.entity.InvoicesItem0Entity;
import jnpf.util.*;
import jnpf.base.util.*;
import jnpf.base.vo.ListVO;
import jnpf.util.context.SpringContext;
import cn.hutool.core.util.ObjectUtil;
import lombok.extern.slf4j.Slf4j;
import lombok.Cleanup;
@ -46,16 +39,13 @@ import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import jnpf.invoices.entity.InvoicesEntity;
import jnpf.invoices.service.InvoicesService;
import jnpf.invoices.entity.InvoicesItem1Entity;
import jnpf.invoices.service.InvoicesItem1Service;
import jnpf.invoices.entity.InvoicesItem0Entity;
import jnpf.invoices.service.InvoicesItem0Service;
import org.springframework.web.bind.annotation.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.multipart.MultipartFile;
import javax.validation.Valid;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import jnpf.util.GeneraterSwapUtil;
@ -76,7 +66,7 @@ import jnpf.util.enums.FileTypeEnum;
*/
@Slf4j
@RestController
@Api(tags = "应付发票" , value = "invoices")
@Api(tags = "应付发票" , value = "mapper/invoices")
@RequestMapping("/api/invoices/Invoices")
public class InvoicesController {
@ -114,17 +104,17 @@ public class InvoicesController {
public ActionResult list(@RequestBody InvoicesPagination invoicesPagination)throws IOException{
List<InvoicesEntity> list= invoicesService.getList(invoicesPagination);
//处理id字段转名称若无需转或者为空可删除
for(InvoicesEntity entity:list){
/*for(InvoicesEntity entity:list){
Map<String,Object> purchaseorderIdMap = new HashMap<>();
entity.setPurchaseorderId(generaterSwapUtil.getPopupSelectValue("389673535976550149","id","document_no",entity.getPurchaseorderId(),purchaseorderIdMap));
Map<String,Object> contractIdMap = new HashMap<>();
entity.setContractId(generaterSwapUtil.getPopupSelectValue("389673903103979269","id","contract_name",entity.getContractId(),contractIdMap));
Map<String,Object> supplierIdMap = new HashMap<>();
entity.setSupplierId(generaterSwapUtil.getPopupSelectValue("389674191453990661","id","supplier_name",entity.getSupplierId(),supplierIdMap));
}
}*/
List<InvoicesListVO> listVO=JsonUtil.getJsonToList(list,InvoicesListVO.class);
for(InvoicesListVO invoicesVO:listVO){
}
/*for(InvoicesListVO invoicesVO:listVO){
}*/
PageListVO vo=new PageListVO();

@ -1,8 +1,12 @@
package jnpf.invoices.mapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import jnpf.invoices.entity.InvoicesEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import jnpf.invoices.model.invoices.InvoicesPagination;
import org.apache.ibatis.annotations.Param;
/**
*
@ -14,4 +18,5 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
*/
public interface InvoicesMapper extends BaseMapper<InvoicesEntity> {
IPage<InvoicesEntity> queryByKeyword(@Param("page") Page<InvoicesEntity> page, @Param("invoicesPagination") InvoicesPagination invoicesPagination);
}

@ -3,6 +3,8 @@ package jnpf.invoices.model.invoices;
import lombok.Data;
import jnpf.base.Pagination;
import java.util.Date;
import java.util.List;
/**
@ -22,6 +24,8 @@ public class InvoicesPagination extends Pagination {
private String purchaseName;
private String supplierName;
private List<String> creatorTime;
private Date startDate;
private Date endDate;
/**
* id
*/

@ -69,7 +69,8 @@ public class InvoicesServiceImpl extends ServiceImpl<InvoicesMapper, InvoicesEnt
private SupplierService supplierService;
@Autowired
private PurchaseorderitemService purchaseorderitemService;
@Autowired
private InvoicesMapper invoicesMapper;
@Override
public List<InvoicesEntity> getList(InvoicesPagination invoicesPagination){
@ -141,7 +142,38 @@ public class InvoicesServiceImpl extends ServiceImpl<InvoicesMapper, InvoicesEnt
}
}
if(StringUtil.isNotEmpty(invoicesPagination.getDocumentNo())){
if(StringUtil.isNotEmpty(invoicesPagination.getCreatorTime())){
List<String> PoundDateList = invoicesPagination.getCreatorTime();
Long fir = Long.valueOf(PoundDateList.get(0));
Long sec = Long.valueOf(PoundDateList.get(1));
invoicesPagination.setStartDate(new Date(fir));
invoicesPagination.setEndDate(DateUtil.stringToDate(DateUtil.daFormatYmd(sec) + " 23:59:59"));
}
if(StringUtil.isEmpty(invoicesPagination.getSidx())){
invoicesPagination.setSidx("CREATOR_TIME");
invoicesPagination.setSort("DESC");
}else{
try {
String sidx = invoicesPagination.getSidx();
InvoicesEntity invoicesEntity = new InvoicesEntity();
Field declaredField = invoicesEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
invoicesPagination.setSidx(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}
}
Page<InvoicesEntity> page=new Page<>(invoicesPagination.getCurrentPage(), invoicesPagination.getPageSize());
IPage<InvoicesEntity> iPage = invoicesMapper.queryByKeyword(page, invoicesPagination);
return invoicesPagination.setData(iPage.getRecords(),iPage.getTotal());
/*if(StringUtil.isNotEmpty(invoicesPagination.getDocumentNo())){
invoicesNum++;
invoicesQueryWrapper.lambda().like(InvoicesEntity::getDocumentNo,invoicesPagination.getDocumentNo());
}
@ -181,7 +213,8 @@ public class InvoicesServiceImpl extends ServiceImpl<InvoicesMapper, InvoicesEnt
invoicesQueryWrapper.lambda().eq(InvoicesEntity::getContractId, invoicesPagination.getPurchaseName());
}
}
if(StringUtil.isNotEmpty(invoicesPagination.getCreatorTime())){
if(StringUtil.isNotEmpty(invoicesPagination.get
())){
invoicesNum++;
List<String> PoundDateList = invoicesPagination.getCreatorTime();
Long fir = Long.valueOf(PoundDateList.get(0));
@ -219,7 +252,7 @@ public class InvoicesServiceImpl extends ServiceImpl<InvoicesMapper, InvoicesEnt
}else{
List<InvoicesEntity> list = new ArrayList();
return invoicesPagination.setData(list, list.size());
}
}*/
}
@Override
public List<InvoicesEntity> getTypeList(InvoicesPagination invoicesPagination,String dataType){

@ -137,7 +137,7 @@ public class PaymentController {
for (Payment_item0Entity payment_item0Entity: Payment_item0List) {
PaymentdocItem0Entity paymentdocItem0Entity = paymentdoc_item0Service.getById(payment_item0Entity.getPaymentdocitemId());
PurchaseorderitemEntity purchaseorderitemEntity = purchaseorderitemService.getById(paymentdocItem0Entity.getPurchaseorderId());
purchaseorderitemEntity.setPayPrice(purchaseorderitemEntity.getPayPrice().add(paymentdocItem0Entity.getAmount()));
purchaseorderitemEntity.setPayPrice(purchaseorderitemEntity.getPayPrice().add(payment_item0Entity.getAmount()));
purchaseorderitemService.updateById(purchaseorderitemEntity);
List<Purchaseorder_item0Entity> Purchaseorder_item0List = purchaseorderitemService.GetPurchaseorder_item0List(purchaseorderitemEntity.getId());
List<PoundlistEntity> poundlistEntityList = purchaseorderitemService.getPoundList(paymentdocItem0Entity.getPurchaseorderId());
@ -308,6 +308,9 @@ public class PaymentController {
case "duedate" :
entitys.add(new ExcelExportEntity("应付日期" ,"duedate"));
break;
case "businessdate" :
entitys.add(new ExcelExportEntity("实付日期" ,"businessdate"));
break;
case "currency" :
entitys.add(new ExcelExportEntity("币别 " ,"currency"));
break;

@ -77,7 +77,7 @@ public class PaymentEntity {
private BigDecimal requestedamount;
@TableField("BUSINESSDATE")
private String businessdate;
private Date businessdate;
@TableField("DUEDATE")
private Date duedate;

@ -61,6 +61,10 @@ public class PaymentCrForm {
@JsonProperty("duedate")
private Long duedate;
/** 实付日期 **/
@JsonProperty("duedate")
private Long businessdate;
/** 币别 **/
@JsonProperty("currency")
private String currency;

@ -64,6 +64,10 @@ public class PaymentInfoVO{
@JsonProperty("duedate")
private Long duedate;
/** 实付日期 **/
@JsonProperty("duedate")
private Long businessdate;
/** 币别 **/
@JsonProperty("currency")
private String currency;

@ -74,6 +74,10 @@ public class PaymentListVO{
@JsonProperty("duedate")
private Date duedate;
/** 实付日期 **/
@JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
@JsonProperty("businessdate")
private Date businessdate;
/** 币别 **/
@JsonProperty("currency")

@ -75,6 +75,9 @@ public class PaymentUpForm{
@JsonProperty("duedate")
private Date duedate;
/** 实付日期 **/
@JsonProperty("businessdate")
private Date businessdate;
/** 币别 **/
@JsonProperty("currency")

@ -107,12 +107,12 @@ public class PaymentdocController {
List<PaymentdocEntity> list= paymentdocService.getList(paymentdocPagination);
//处理id字段转名称若无需转或者为空可删除
for(PaymentdocEntity entity:list){
Map<String,Object> purchaseIdMap = new HashMap<>();
/*Map<String,Object> purchaseIdMap = new HashMap<>();
entity.setPurchaseId(generaterSwapUtil.getPopupSelectValue("389673535976550149","id","document_no",entity.getPurchaseId(),purchaseIdMap));
Map<String,Object> contractIdMap = new HashMap<>();
entity.setContractId(generaterSwapUtil.getPopupSelectValue("389673903103979269","id","contract_name",entity.getContractId(),contractIdMap));
Map<String,Object> supplierIdMap = new HashMap<>();
entity.setSupplierId(generaterSwapUtil.getPopupSelectValue("389674191453990661","id","supplier_name",entity.getSupplierId(),supplierIdMap));
entity.setSupplierId(generaterSwapUtil.getPopupSelectValue("389674191453990661","id","supplier_name",entity.getSupplierId(),supplierIdMap));*/
QueryWrapper<PaymentEntity> PaymentqueryWrapper = new QueryWrapper<>();
PaymentqueryWrapper.lambda().eq(PaymentEntity::getPaymentno, entity.getDocumentNo());
PaymentEntity paymentEntity = paymentService.getOne(PaymentqueryWrapper);

@ -45,7 +45,9 @@ public class PaymentdocListVO{
/** 供应商 **/
@JsonProperty("supplierId")
private String supplierId;
/** 供应商 **/
@JsonProperty("supplierName")
private String supplierName;
/** 付款类型 **/

@ -18,6 +18,8 @@ public class PaymentdocPagination extends Pagination {
/** 单据编号 */
private String documentNo;
/** 供应商 */
private String supplierName;
/**
* id
*/

@ -4,6 +4,8 @@ import jnpf.paymentdoc.entity.*;
import jnpf.paymentdoc.mapper.PaymentdocMapper;
import jnpf.paymentdoc.service.*;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import jnpf.supplier.entity.SupplierEntity;
import jnpf.supplier.service.SupplierService;
import jnpf.util.RandomUtil;
import java.math.BigDecimal;
import jnpf.permission.model.authorize.AuthorizeConditionModel;
@ -53,7 +55,8 @@ public class PaymentdocServiceImpl extends ServiceImpl<PaymentdocMapper, Payment
@Autowired
private PaymentdocItem0Service paymentdocItem0Service;
@Autowired
private SupplierService supplierService;
@ -111,6 +114,18 @@ public class PaymentdocServiceImpl extends ServiceImpl<PaymentdocMapper, Payment
paymentdocQueryWrapper.lambda().like(PaymentdocEntity::getDocumentNo,paymentdocPagination.getDocumentNo());
}
if(StringUtil.isNotEmpty(paymentdocPagination.getSupplierName())){
QueryWrapper<SupplierEntity> customerQueryWrapper =new QueryWrapper<>();
customerQueryWrapper.lambda().like(SupplierEntity::getSupplierName, paymentdocPagination.getSupplierName());
customerQueryWrapper.lambda().select(SupplierEntity::getId);
List<String> customerIdList = supplierService.listObjs(customerQueryWrapper).stream().map(o -> (String) o).collect(Collectors.toList());
paymentdocNum++;
if(customerIdList.size() > 0){
paymentdocQueryWrapper.lambda().in(PaymentdocEntity::getSupplierId,customerIdList);
}else{
paymentdocQueryWrapper.lambda().eq(PaymentdocEntity::getSupplierId, paymentdocPagination.getSupplierName());
}
}
if(AllIdList.size()>0){
paymentdocQueryWrapper.lambda().in(PaymentdocEntity::getId, AllIdList);
}

@ -392,7 +392,7 @@ public class PoundlistController {
public ActionResult<PoundlistInfoVO> info(@PathVariable("id") String id){
PoundlistEntity entity= poundlistService.getInfo(id);
PoundlistInfoVO vo=JsonUtil.getJsonToBean(entity, PoundlistInfoVO.class);
vo.setOriginPlace(generaterSwapUtil.provinceData(vo.getOriginPlace()));
//子表
//副表
return ActionResult.success(vo);

@ -2,10 +2,7 @@
package jnpf.poundlist.model.poundlist;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data;
import java.util.Date;
import java.util.List;
import java.math.BigDecimal;
import com.fasterxml.jackson.annotation.JsonProperty;
@ -56,19 +53,19 @@ public class PoundlistCrForm {
/** 皮重 **/
@JsonProperty("tareWeight")
private Integer tareWeight;
private String tareWeight;
/** 毛重 **/
@JsonProperty("grossWeight")
private Integer grossWeight;
private String grossWeight;
/** 扣重 **/
@JsonProperty("buckleWeight")
private Integer buckleWeight;
private String buckleWeight;
/** 净重 **/
@JsonProperty("netWeight")
private Integer netWeight;
private String netWeight;
/** 单位 **/
@JsonProperty("unit")
@ -84,11 +81,11 @@ public class PoundlistCrForm {
/** 运费 **/
@JsonProperty("transportPrice")
private Integer transportPrice;
private String transportPrice;
/** 销售价格 **/
@JsonProperty("salesPrice")
private Integer salesPrice;
private String salesPrice;
/** 业务员 **/
@JsonProperty("businessId")

@ -61,19 +61,19 @@ public class PoundlistInfoVO{
/** 皮重 **/
@JsonProperty("tareWeight")
private Integer tareWeight;
private String tareWeight;
/** 毛重 **/
@JsonProperty("grossWeight")
private Integer grossWeight;
private String grossWeight;
/** 扣重 **/
@JsonProperty("buckleWeight")
private Integer buckleWeight;
private String buckleWeight;
/** 净重 **/
@JsonProperty("netWeight")
private Integer netWeight;
private String netWeight;
/** 单位 **/
@JsonProperty("unit")
@ -89,11 +89,11 @@ public class PoundlistInfoVO{
/** 运费 **/
@JsonProperty("transportPrice")
private Integer transportPrice;
private String transportPrice;
/** 销售价格 **/
@JsonProperty("salesPrice")
private Integer salesPrice;
private String salesPrice;
/** 业务员 **/
@JsonProperty("businessId")

@ -9,7 +9,6 @@ import java.sql.Time;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.math.BigDecimal;
/**
*
*
@ -52,7 +51,7 @@ public class PoundlistListVO{
/** 销售价格 **/
@JsonProperty("salesPrice")
private Integer salesPrice;
private String salesPrice;
/** 运输方式 **/
@JsonProperty("transportType")
@ -61,7 +60,7 @@ public class PoundlistListVO{
/** 运费 **/
@JsonProperty("departmentId")
private Integer departmentId;
private String departmentId;
/** 车号 **/
@JsonProperty("licenseNo")
@ -80,19 +79,19 @@ public class PoundlistListVO{
/** 皮重 **/
@JsonProperty("tareWeight")
private Integer tareWeight;
private String tareWeight;
/** 毛重 **/
@JsonProperty("grossWeight")
private Integer grossWeight;
private String grossWeight;
/** 扣重 **/
@JsonProperty("buckleWeight")
private Integer buckleWeight;
private String buckleWeight;
/** 净重 **/
@JsonProperty("netWeight")
private Integer netWeight;
private String netWeight;
/** 备注 **/
@JsonProperty("remark")

@ -68,22 +68,22 @@ public class PoundlistUpForm{
/** 皮重 **/
@JsonProperty("tareWeight")
private Integer tareWeight;
private String tareWeight;
/** 毛重 **/
@JsonProperty("grossWeight")
private Integer grossWeight;
private String grossWeight;
/** 扣重 **/
@JsonProperty("buckleWeight")
private Integer buckleWeight;
private String buckleWeight;
/** 净重 **/
@JsonProperty("netWeight")
private Integer netWeight;
private String netWeight;
/** 单位 **/
@ -103,12 +103,12 @@ public class PoundlistUpForm{
/** 运费 **/
@JsonProperty("transportPrice")
private Integer transportPrice;
private String transportPrice;
/** 销售价格 **/
@JsonProperty("salesPrice")
private Integer salesPrice;
private String salesPrice;
/** 业务员 **/

@ -101,11 +101,11 @@ public class PurchasebackController {
public ActionResult list(@RequestBody PurchasebackPagination purchasebackPagination) throws IOException {
List<PurchasebackEntity> list = purchasebackService.getList(purchasebackPagination);
//处理id字段转名称若无需转或者为空可删除
for (PurchasebackEntity entity : list) {
/*for (PurchasebackEntity entity : list) {
Map<String, Object> purchaseOrderIdMap = new HashMap<>();
entity.setPurchaseOrderId(generaterSwapUtil.getPopupSelectValue("383149471917185157", "id", "document_no", entity.getPurchaseOrderId(), purchaseOrderIdMap));
entity.setCreatorUserName(generaterSwapUtil.userSelectValue(entity.getCreatorUserName()));
}
}*/
List<PurchasebackListVO> listVO = JsonUtil.getJsonToList(list, PurchasebackListVO.class);
for (PurchasebackListVO purchasebackVO : listVO) {
PurchaseorderEntity purchaseorderEntity = purchasebackService.getPurchaseorder(purchasebackVO.getPurchaseOrderId());

@ -89,4 +89,11 @@ public class PurchasebackEntity {
@TableField("REMARK")
private String remark;
@TableField(exist = false)
private String purchaseorderdocumentno;
@TableField(exist = false)
private String contractName;
@TableField(exist = false)
private String supplierName;
}

@ -1,8 +1,12 @@
package jnpf.purchaseback.mapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import jnpf.purchaseback.entity.PurchasebackEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import jnpf.purchaseback.model.purchaseback.PurchasebackPagination;
import org.apache.ibatis.annotations.Param;
/**
*
@ -14,4 +18,5 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
*/
public interface PurchasebackMapper extends BaseMapper<PurchasebackEntity> {
IPage<PurchasebackEntity> queryByKeyword(@Param("page") Page<PurchasebackEntity> page, @Param("purchasebackPagination") PurchasebackPagination purchasebackPagination);
}

@ -78,4 +78,12 @@ public class PurchasebackListVO{
/**列表子表数据 */
@JsonProperty("jg_purchaseorder")
private PurchaseorderListVO jg_purchaseorder;
@JsonProperty("purchaseorderdocumentno")
private String purchaseorderdocumentno;
@JsonProperty("contractName")
private String contractName;
@JsonProperty("supplierName")
private String supplierName;
}

@ -55,6 +55,8 @@ public class PurchasebackServiceImpl extends ServiceImpl<PurchasebackMapper, Pur
@Autowired
private Purchaseback_item0Service purchaseback_item0Service;
@Autowired
private PurchasebackMapper purchasebackMapper;
@ -129,7 +131,25 @@ public class PurchasebackServiceImpl extends ServiceImpl<PurchasebackMapper, Pur
}
}
if(StringUtil.isNotEmpty(purchasebackPagination.getDocumentNo())){
if(StringUtil.isEmpty(purchasebackPagination.getSidx())){
purchasebackPagination.setSidx("CREATOR_TIME");
purchasebackPagination.setSort("DESC");
}else{
try {
String sidx = purchasebackPagination.getSidx();
PurchasebackEntity purchasebackEntity = new PurchasebackEntity();
Field declaredField = purchasebackEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
purchasebackPagination.setSidx(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}
}
Page<PurchasebackEntity> page=new Page<>(purchasebackPagination.getCurrentPage(), purchasebackPagination.getPageSize());
IPage<PurchasebackEntity> iPage = purchasebackMapper.queryByKeyword(page, purchasebackPagination);
return purchasebackPagination.setData(iPage.getRecords(),iPage.getTotal());
/*if(StringUtil.isNotEmpty(purchasebackPagination.getDocumentNo())){
purchasebackNum++;
purchasebackQueryWrapper.lambda().like(PurchasebackEntity::getDocumentNo,purchasebackPagination.getDocumentNo());
}
@ -159,7 +179,7 @@ public class PurchasebackServiceImpl extends ServiceImpl<PurchasebackMapper, Pur
}else{
List<PurchasebackEntity> list = new ArrayList();
return purchasebackPagination.setData(list, list.size());
}
}*/
}
@Override
public List<PurchasebackEntity> getTypeList(PurchasebackPagination purchasebackPagination,String dataType){

@ -103,17 +103,17 @@ public class ReceiptinController {
public ActionResult list(@RequestBody ReceiptinPagination receiptinPagination)throws IOException{
List<ReceiptinEntity> list= receiptinService.getList(receiptinPagination);
//处理id字段转名称若无需转或者为空可删除
for(ReceiptinEntity entity:list){
/*for(ReceiptinEntity entity:list){
Map<String,Object> soucenoMap = new HashMap<>();
entity.setSouceno(generaterSwapUtil.getPopupSelectValue("392931756640102277","id","document_no",entity.getSouceno(),soucenoMap));
Map<String,Object> supplierIdMap = new HashMap<>();
entity.setSupplierId(generaterSwapUtil.getPopupSelectValue("397751667988199621","id","supplier_name",entity.getSupplierId(),supplierIdMap));
entity.setCreatorUserName(generaterSwapUtil.userSelectValue(entity.getCreatorUserName()));
}
}*/
List<ReceiptinListVO> listVO=JsonUtil.getJsonToList(list,ReceiptinListVO.class);
for(ReceiptinListVO receiptinVO:listVO){
/*for(ReceiptinListVO receiptinVO:listVO){
}
*/
PageListVO vo=new PageListVO();
vo.setList(listVO);

@ -104,4 +104,10 @@ public class ReceiptinEntity {
@TableField(exist = false)
private List<Receiptin_item0Entity> receiptin_item0List;
@TableField(exist = false)
private String purchaseorderSouceno;
@TableField(exist = false)
private String supplier;
}

@ -1,8 +1,12 @@
package jnpf.receiptin.mapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import jnpf.receiptin.entity.ReceiptinEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import jnpf.receiptin.model.receiptin.ReceiptinPagination;
import org.apache.ibatis.annotations.Param;
/**
*
@ -14,4 +18,5 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
*/
public interface ReceiptinMapper extends BaseMapper<ReceiptinEntity> {
IPage<ReceiptinEntity> queryByKeyword(@Param("page") Page<ReceiptinEntity> page, @Param("receiptinPagination") ReceiptinPagination receiptinPagination);
}

@ -87,5 +87,10 @@ public class ReceiptinListVO{
@JsonProperty("creatorUserName")
private String creatorUserName;
@JsonProperty("purchaseorderSouceno")
private String purchaseorderSouceno;
@JsonProperty("supplier")
private String supplier;
}

@ -3,6 +3,8 @@ package jnpf.receiptin.model.receiptin;
import lombok.Data;
import jnpf.base.Pagination;
import java.util.Date;
import java.util.List;
/**
@ -25,6 +27,8 @@ public class ReceiptinPagination extends Pagination {
private String souceno;
private String supplierName;
private List<String> creatorTime;
private Date startDate;
private Date endDate;
/**
* id
*/

@ -61,6 +61,8 @@ public class ReceiptinServiceImpl extends ServiceImpl<ReceiptinMapper, Receiptin
private PurchaseorderitemService purchaseorderitemService;
@Autowired
private SupplierService supplierService;
@Autowired
private ReceiptinMapper receiptinMapper;
@Override
public List<ReceiptinEntity> getList(ReceiptinPagination receiptinPagination){
@ -114,7 +116,32 @@ public class ReceiptinServiceImpl extends ServiceImpl<ReceiptinMapper, Receiptin
}
}
if(StringUtil.isNotEmpty(receiptinPagination.getDocumentno())){
if(StringUtil.isNotEmpty(receiptinPagination.getCreatorTime())){
List<String> PoundDateList = receiptinPagination.getCreatorTime();
Long fir = Long.valueOf(PoundDateList.get(0));
Long sec = Long.valueOf(PoundDateList.get(1));
receiptinPagination.setStartDate(new Date(fir));
receiptinPagination.setEndDate(DateUtil.stringToDate(DateUtil.daFormatYmd(sec) + " 23:59:59"));
}
if(StringUtil.isEmpty(receiptinPagination.getSidx())){
receiptinPagination.setSidx("CREATOR_TIME");
receiptinPagination.setSort("DESC");
}else{
try {
String sidx = receiptinPagination.getSidx();
ReceiptinEntity receiptinEntity = new ReceiptinEntity();
Field declaredField = receiptinEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
receiptinPagination.setSidx(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}
}
Page<ReceiptinEntity> page=new Page<>(receiptinPagination.getCurrentPage(), receiptinPagination.getPageSize());
IPage<ReceiptinEntity> iPage = receiptinMapper.queryByKeyword(page, receiptinPagination);
return receiptinPagination.setData(iPage.getRecords(),iPage.getTotal());
/*if(StringUtil.isNotEmpty(receiptinPagination.getDocumentno())){
receiptinNum++;
receiptinQueryWrapper.lambda().like(ReceiptinEntity::getDocumentno,receiptinPagination.getDocumentno());
}
@ -183,7 +210,7 @@ public class ReceiptinServiceImpl extends ServiceImpl<ReceiptinMapper, Receiptin
}else{
List<ReceiptinEntity> list = new ArrayList();
return receiptinPagination.setData(list, list.size());
}
}*/
}
@Override
public List<ReceiptinEntity> getTypeList(ReceiptinPagination receiptinPagination,String dataType){

@ -110,8 +110,8 @@ public class SalebackController {
List<SalebackEntity> list= salebackService.getList(salebackPagination);
//处理id字段转名称若无需转或者为空可删除
for(SalebackEntity entity:list){
Map<String,Object> salesOrderIdMap = new HashMap<>();
entity.setSalesOrderId(generaterSwapUtil.getPopupSelectValue("383568951197606085","id","document_no",entity.getSalesOrderId(),salesOrderIdMap));
// Map<String,Object> salesOrderIdMap = new HashMap<>();
// entity.setSalesOrderId(generaterSwapUtil.getPopupSelectValue("383568951197606085","id","document_no",entity.getSalesOrderId(),salesOrderIdMap));
entity.setCreatorUserName(generaterSwapUtil.userSelectValue(entity.getCreatorUserName()));
}
List<SalebackListVO> listVO=JsonUtil.getJsonToList(list,SalebackListVO.class);
@ -320,12 +320,15 @@ public class SalebackController {
vo.setCreatorTime(vo.getCreatorTime());
}
vo.setCreatorUserName(generaterSwapUtil.userSelectValue(vo.getCreatorUserName()));
List<Saleback_item0Entity> saleback_item0Models = salebackService.querySaleBackItemInfo(id);
//子表数据转换
List<Saleback_item0Model> jg_salesback_item0ModelList = JsonUtil.getJsonToList(saleback_item0Models,Saleback_item0Model.class);
vo.setSaleback_item0List(jg_salesback_item0ModelList);
//子表
List<Saleback_item0Entity> Saleback_item0List = salebackService.GetSaleback_item0List(id);
for(Saleback_item0Entity saleback_item0Entity : Saleback_item0List){
}
vo.setSaleback_item0List(JsonUtil.getJsonToList(Saleback_item0List,Saleback_item0Model.class ));
// List<Saleback_item0Entity> Saleback_item0List = salebackService.GetSaleback_item0List(id);
// for(Saleback_item0Entity saleback_item0Entity : Saleback_item0List){
// }
// vo.setSaleback_item0List(JsonUtil.getJsonToList(Saleback_item0List,Saleback_item0Model.class ));
return ActionResult.success(vo);
}
@ -376,25 +379,9 @@ public class SalebackController {
SalebackEntity entity= salebackService.getInfo(id);
SalebackInfoVO vo=JsonUtil.getJsonToBean(entity, SalebackInfoVO.class);
List<Saleback_item0Entity> saleback_item0Models = salebackService.querySaleBackItemInfo(id);
//子表数据转换
// List<Saleback_item0Entity> jg_salesback_item0List = salebackService.GetSaleback_item0List(id);
List<Saleback_item0Model> jg_salesback_item0ModelList = JsonUtil.getJsonToList(saleback_item0Models,Saleback_item0Model.class);
// for(Saleback_item0Model jg_salesback_item0Model : jg_salesback_item0ModelList){
//
// Map<String,Object> licenseNumMap = new HashMap<>();
// jg_salesback_item0Model.setVehicleId(generaterSwapUtil.getPopupSelectValue("399190838078458949","id","ticketno",jg_salesback_item0Model.getVehicleId(),licenseNumMap));
// Map<String,Object> materialIdMap = new HashMap<>();
// jg_salesback_item0Model.setMaterialId(generaterSwapUtil.getPopupSelectValue("381037852907038533","id","item_name",jg_salesback_item0Model.getMaterialId(),materialIdMap));
// Map<String,Object> businessIdMap = new HashMap<>();
// jg_salesback_item0Model.setBusinessId(generaterSwapUtil.getPopupSelectValue("ebcc44be142e43b795c0d769abd6d25a","F_Id","F_RealName",jg_salesback_item0Model.getBusinessId(),businessIdMap));
// }
vo.setSaleback_item0List(jg_salesback_item0ModelList);
// vo.setJg_salesorder(JsonUtil.getJsonToBean(jg_salesorderEntity, SaleorderModel.class));
//添加到详情表单对象中
Map<String,Object> salesOrderIdMap = new HashMap<>();
vo.setSalesOrderId(generaterSwapUtil.getPopupSelectValue("383568951197606085","id","document_no",vo.getSalesOrderId(),salesOrderIdMap));

@ -114,6 +114,10 @@ public class Saleback_item0Entity {
/** 客户 **/
@TableField(exist = false)
private String customerName;
@TableField(exist = false)
private String vehicleName;
@TableField(exist = false)
private String businessName;
/** 是否垫资 **/
@TableField(exist = false)
@ -135,6 +139,10 @@ public class Saleback_item0Entity {
@TableField(exist = false)
private String vehiclePictures;
/** 不含税金额 **/
@TableField(exist = false)
private String noPrice;

@ -1,5 +1,6 @@
package jnpf.saleback.model.saleback;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.List;
@ -65,6 +66,12 @@ public class Saleback_item0Model {
/** 客户 **/
@JsonProperty("customerName")
private String customerName;
@TableField(exist = false)
private String vehicleName;
@TableField(exist = false)
private String materialName;
@TableField(exist = false)
private String businessName;
/** 是否垫资 **/
@JsonProperty("advance")

@ -124,7 +124,8 @@ public class SalebackServiceImpl extends ServiceImpl<SalebackMapper, SalebackEnt
}
//排序
if(StringUtil.isEmpty(salebackPagination.getSidx())){
salebackQueryWrapper.lambda().orderByDesc(SalebackEntity::getId);
salebackPagination.setSidx("CREATOR_TIME");
salebackPagination.setSort("DESC");
}else{
try {
String sidx = salebackPagination.getSidx();
@ -132,7 +133,8 @@ public class SalebackServiceImpl extends ServiceImpl<SalebackMapper, SalebackEnt
Field declaredField = salebackEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
salebackQueryWrapper="asc".equals(salebackPagination.getSort().toLowerCase())?salebackQueryWrapper.orderByAsc(value):salebackQueryWrapper.orderByDesc(value);
salebackPagination.setSidx(value);
// salebackQueryWrapper="asc".equals(salebackPagination.getSort().toLowerCase())?salebackQueryWrapper.orderByAsc(value):salebackQueryWrapper.orderByDesc(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}

@ -663,30 +663,30 @@ public class SaleorderitemController {
}
vo.setSalesorder_item0List(JsonUtil.getJsonToList(Salesorder_item0List,Salesorder_item0Model.class ));
List<ReceiptoutsoitemEntity> ReceiptoutsoitemList = saleorderitemService.GetReceiptoutsoitemList(id);
for(ReceiptoutsoitemEntity receiptoutsoitemEntity : ReceiptoutsoitemList){
QueryWrapper<Receiptout_item0Entity> queryWrapper = new QueryWrapper<>();
queryWrapper.lambda().eq(Receiptout_item0Entity::getReceiptinId,receiptoutsoitemEntity.getId());
List<Receiptout_item0Entity> list = receiptout_item0Service.list(queryWrapper);
}
vo.setReceiptoutsoitemList(JsonUtil.getJsonToList(ReceiptoutsoitemList,ReceiptoutsoitemModel.class ));
List<Arinvoices_item0soitemEntity> Arinvoices_item0soitemList = saleorderitemService.GetArinvoices_item0soitemList(id);
for(Arinvoices_item0soitemEntity arinvoices_item0soitemEntity : Arinvoices_item0soitemList){
}
vo.setArinvoices_item0soitemList(JsonUtil.getJsonToList(Arinvoices_item0soitemList,Arinvoices_item0soitemModel.class ));
List<CollectionsoitemEntity> CollectionsoitemList = saleorderitemService.GetCollectionsoitemList(id);
for(CollectionsoitemEntity collectionsoitemEntity : CollectionsoitemList){
}
vo.setCollectionsoitemList(JsonUtil.getJsonToList(CollectionsoitemList,CollectionsoitemModel.class ));
List<SalesbacksoitemEntity> SalesbacksoitemList = saleorderitemService.GetSalesbacksoitemList(id);
for(SalesbacksoitemEntity salesbacksoitemEntity : SalesbacksoitemList){
}
vo.setSalesbacksoitemList(JsonUtil.getJsonToList(SalesbacksoitemList,SalesbacksoitemModel.class ));
List<PaymentsoitemEntity> PaymentsoitemList = saleorderitemService.GetPaymentsoitemList(id);
for(PaymentsoitemEntity paymentsoitemEntity : PaymentsoitemList){
}
vo.setPaymentsoitemList(JsonUtil.getJsonToList(PaymentsoitemList,PaymentsoitemModel.class ));
// List<ReceiptoutsoitemEntity> ReceiptoutsoitemList = saleorderitemService.GetReceiptoutsoitemList(id);
// for(ReceiptoutsoitemEntity receiptoutsoitemEntity : ReceiptoutsoitemList){
// QueryWrapper<Receiptout_item0Entity> queryWrapper = new QueryWrapper<>();
// queryWrapper.lambda().eq(Receiptout_item0Entity::getReceiptinId,receiptoutsoitemEntity.getId());
// List<Receiptout_item0Entity> list = receiptout_item0Service.list(queryWrapper);
//
// }
// vo.setReceiptoutsoitemList(JsonUtil.getJsonToList(ReceiptoutsoitemList,ReceiptoutsoitemModel.class ));
// List<Arinvoices_item0soitemEntity> Arinvoices_item0soitemList = saleorderitemService.GetArinvoices_item0soitemList(id);
// for(Arinvoices_item0soitemEntity arinvoices_item0soitemEntity : Arinvoices_item0soitemList){
// }
// vo.setArinvoices_item0soitemList(JsonUtil.getJsonToList(Arinvoices_item0soitemList,Arinvoices_item0soitemModel.class ));
// List<CollectionsoitemEntity> CollectionsoitemList = saleorderitemService.GetCollectionsoitemList(id);
// for(CollectionsoitemEntity collectionsoitemEntity : CollectionsoitemList){
// }
// vo.setCollectionsoitemList(JsonUtil.getJsonToList(CollectionsoitemList,CollectionsoitemModel.class ));
// List<SalesbacksoitemEntity> SalesbacksoitemList = saleorderitemService.GetSalesbacksoitemList(id);
// for(SalesbacksoitemEntity salesbacksoitemEntity : SalesbacksoitemList){
// }
// vo.setSalesbacksoitemList(JsonUtil.getJsonToList(SalesbacksoitemList,SalesbacksoitemModel.class ));
// List<PaymentsoitemEntity> PaymentsoitemList = saleorderitemService.GetPaymentsoitemList(id);
// for(PaymentsoitemEntity paymentsoitemEntity : PaymentsoitemList){
// }
// vo.setPaymentsoitemList(JsonUtil.getJsonToList(PaymentsoitemList,PaymentsoitemModel.class ));
//副表
return ActionResult.success(vo);
}

@ -51,19 +51,19 @@ public class SaleorderitemCrForm {
/** 垫资金额 **/
@JsonProperty("advanceAmount")
private Integer advanceAmount;
private String advanceAmount;
/** 重量 **/
@JsonProperty("num")
private Integer num;
private String num;
/** 金额 **/
@JsonProperty("price")
private Integer price;
private String price;
/** 不含税金额 **/
@JsonProperty("notPrice")
private Integer notPrice;
private String notPrice;
/** 备注信息 **/
@JsonProperty("remark")

@ -53,19 +53,19 @@ public class SaleorderitemInfoVO{
/** 垫资金额 **/
@JsonProperty("advanceAmount")
private Integer advanceAmount;
private String advanceAmount;
/** 重量 **/
@JsonProperty("num")
private Integer num;
private String num;
/** 金额 **/
@JsonProperty("price")
private Integer price;
private String price;
/** 不含税金额 **/
@JsonProperty("notPrice")
private Integer notPrice;
private String notPrice;
/** 备注信息 **/
@JsonProperty("remark")

@ -52,19 +52,19 @@ public class SaleorderitemListVO{
/** 垫资金额 **/
@JsonProperty("advanceAmount")
private Integer advanceAmount;
private String advanceAmount;
/** 重量 **/
@JsonProperty("num")
private Integer num;
private String num;
/** 金额 **/
@JsonProperty("price")
private Integer price;
private String price;
/** 不含税金额 **/
@JsonProperty("notPrice")
private Integer notPrice;
private String notPrice;
/** 备注信息 **/
@JsonProperty("remark")

@ -60,22 +60,22 @@ public class SaleorderitemUpForm{
/** 垫资金额 **/
@JsonProperty("advanceAmount")
private Integer advanceAmount;
private String advanceAmount;
/** 重量 **/
@JsonProperty("num")
private Integer num;
private String num;
/** 金额 **/
@JsonProperty("price")
private Integer price;
private String price;
/** 不含税金额 **/
@JsonProperty("notPrice")
private Integer notPrice;
private String notPrice;
/** 备注信息 **/

@ -57,6 +57,8 @@ import java.io.InputStream;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.*;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
*
@ -193,18 +195,18 @@ public class TradeuploadController {
tradeuploadCrForm.setPoundlistNo(DeliveryNumber);
}
if (StringUtils.isNotEmpty(TareWeight)) {
tradeuploadCrForm.setTareWeight(TareWeight);
tradeuploadCrForm.setTareWeight(numberTransform(TareWeight));
}
if (StringUtils.isNotEmpty(CrossWeight)) {
tradeuploadCrForm.setGrossWeight(CrossWeight);
tradeuploadCrForm.setGrossWeight(numberTransform(CrossWeight));
}
if (StringUtils.isEmpty(NetWeight)) {
tradeuploadCrForm.setBuckleWeight("0");
}else {
tradeuploadCrForm.setBuckleWeight(NetWeight);
tradeuploadCrForm.setBuckleWeight(numberTransform(NetWeight));
}
if (StringUtils.isNotEmpty(NetWeight)) {
tradeuploadCrForm.setNetWeight(NetWeight);
tradeuploadCrForm.setNetWeight(numberTransform(NetWeight));
}
UserInfo userInfo = userProvider.get();
@ -470,7 +472,9 @@ public class TradeuploadController {
//处理id字段转名称若无需转或者为空可删除
for(TradeuploadEntity entity:list){
entity.setPoundPictures(generaterSwapUtil.getFileNameInJson(entity.getPoundPictures()));
Map<String,Object> materialIdMap = new HashMap<>();
/*Map<String,Object> materialIdMap = new HashMap<>();
entity.setMaterialName(generaterSwapUtil.getPopupSelectValue("381037852907038533","id","item_name",entity.getMaterialId(),materialIdMap));
Map<String,Object> customerIdMap = new HashMap<>();
entity.setCustomerName(generaterSwapUtil.getPopupSelectValue("395936123471343749","id","supplier_nm",entity.getCustomerId(),customerIdMap));
@ -486,7 +490,7 @@ public class TradeuploadController {
Map<String,Object> purchaseIdMap = new HashMap<>();
entity.setPurchaseName(generaterSwapUtil.getPopupSelectValue("397408984857931205","id","contract_name",entity.getPurchaseId(),purchaseIdMap));
Map<String,Object> supplierIdMap = new HashMap<>();
entity.setSupplierName(generaterSwapUtil.getPopupSelectValue("382494924156735557","id","supplier_name",entity.getSupplierId(),supplierIdMap));
entity.setSupplierName(generaterSwapUtil.getPopupSelectValue("382494924156735557","id","supplier_name",entity.getSupplierId(),supplierIdMap));*/
entity.setOriginPlace(generaterSwapUtil.provinceData(entity.getOriginPlace()));
}
List<TradeuploadListVO> listVO=JsonUtil.getJsonToList(list,TradeuploadListVO.class);
@ -730,7 +734,7 @@ public class TradeuploadController {
if(vo.getCreatorTime()!=null){
vo.setCreatorTime(vo.getCreatorTime());
}
vo.setOriginPlace(generaterSwapUtil.provinceData(vo.getOriginPlace()));
//子表
//副表
return ActionResult.success(vo);
@ -822,14 +826,27 @@ public class TradeuploadController {
return ActionResult.success("删除成功");
}
public String numberTransform(String str){
List<String> list = new ArrayList<>();
// 声明正则匹配数字1个或多个.数字1个或多个
String regex = "\\d+";
if(str.indexOf(".") > 0){
regex = "\\d+\\.+\\d+";
}
//String regex = "\\d+\\.+\\d+";
// Pattern的构造方法是私有的不可以直接创建通过静态方法compile创建Pattern对象查看源代码发现compile直接调用了Pattern构造函数。
Pattern pattern = Pattern.compile(regex);
// 返回一个Matcher对象。Matcher类的构造方法也是私有的不能随意创建只能通过Pattern.matcher(CharSequence input)方法得到该类的实例。
Matcher matcher = pattern.matcher(str);
// 对目标字符串进行正则匹配通过while可以多次执行find方法获取多次的匹配结果代码编写方式类似于iterator.next()。
while (matcher.find()) {
// group() 返回匹配到的字符串结合find函数使用。
String group = matcher.group();
list.add(group);
}
if(list.size() == 0){
return "0";
}
return list.get(0);
}
}

@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import jnpf.tradeupload.entity.TradeuploadEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import jnpf.tradeupload.model.tradeupload.TradeuploadPagination;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
@ -21,4 +22,6 @@ import java.util.List;
*/
public interface TradeuploadMapper extends BaseMapper<TradeuploadEntity> {
List<TradeuploadEntity> queryVehicle(TradeuploadEntity tradeuploadEntity);
IPage<TradeuploadEntity> queryByKeyword(@Param("page") Page<TradeuploadEntity> page, @Param("tradeuploadPagination") TradeuploadPagination tradeuploadPagination);
}

@ -3,6 +3,8 @@ package jnpf.tradeupload.model.tradeupload;
import lombok.Data;
import jnpf.base.Pagination;
import java.util.Date;
import java.util.List;
/**
@ -36,6 +38,9 @@ public class TradeuploadPagination extends Pagination {
/** 车牌号 */
private String vehicleName;
private Date startDate;
private Date endDate;
/**
* id
*/

@ -108,6 +108,36 @@ public class TradeuploadServiceImpl extends ServiceImpl<TradeuploadMapper, Trade
}
}
if(StringUtil.isNotEmpty(tradeuploadPagination.getPoundDate())){
List<String> PoundDateList = tradeuploadPagination.getPoundDate();
Long fir = Long.valueOf(PoundDateList.get(0));
Long sec = Long.valueOf(PoundDateList.get(1));
tradeuploadPagination.setStartDate(new Date(fir));
tradeuploadPagination.setEndDate(DateUtil.stringToDate(DateUtil.daFormatYmd(sec) + " 23:59:59"));
}
if(StringUtil.isEmpty(tradeuploadPagination.getSidx())){
tradeuploadPagination.setSidx("CREATOR_TIME");
tradeuploadPagination.setSort("DESC");
}else{
try {
String sidx = tradeuploadPagination.getSidx();
TradeuploadEntity tradeuploadEntity = new TradeuploadEntity();
Field declaredField = tradeuploadEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
tradeuploadPagination.setSidx(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}
}
Page<TradeuploadEntity> page=new Page<>(tradeuploadPagination.getCurrentPage(), tradeuploadPagination.getPageSize());
IPage<TradeuploadEntity> iPage = tradeuploadMapper.queryByKeyword(page, tradeuploadPagination);
return tradeuploadPagination.setData(iPage.getRecords(),iPage.getTotal());
/*
if(StringUtil.isNotEmpty(tradeuploadPagination.getPoundDate())){
tradeuploadNum++;
List<String> PoundDateList = tradeuploadPagination.getPoundDate();
@ -209,7 +239,7 @@ public class TradeuploadServiceImpl extends ServiceImpl<TradeuploadMapper, Trade
}else{
List<TradeuploadEntity> list = new ArrayList();
return tradeuploadPagination.setData(list, list.size());
}
}*/
}
@Override
public List<TradeuploadEntity> getTypeList(TradeuploadPagination tradeuploadPagination,String dataType){

@ -1,7 +0,0 @@
<?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="jnpf.invoices.mapper.InvoicesMapper">
</mapper>

@ -1,7 +0,0 @@
<?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="jnpf.purchaseback.mapper.PurchasebackMapper">
</mapper>

@ -1,18 +0,0 @@
<?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="jnpf.tradeupload.mapper.TradeuploadMapper">
<select id="queryVehicle" resultType="jnpf.tradeupload.entity.TradeuploadEntity">
select
*
from
jg_poundlist
where
vehicle_id = #{vehicleId} and
gross_weight = #{grossWeight} and
tare_weight = #{tareWeight} and
net_weight = #{netWeight} and
creator_time = DATE_SUB(NOW(),interval 15 day)
</select>
</mapper>

@ -0,0 +1,32 @@
<?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="jnpf.invoices.mapper.InvoicesMapper">
<select id="queryByKeyword" resultType="jnpf.invoices.entity.InvoicesEntity">
SELECT a.*,b.document_no purchaseorderId,c.contract_name contractId,d.supplier_name supplierId
from jg_invoices a
LEFT JOIN jg_purchaseorder b on a.purchaseorder_id = b.id
LEFT JOIN jg_contract c on a.contract_id = c.id
LEFT JOIN jg_supplier d on a.supplier_id = d.id
where 1=1
<if test="invoicesPagination.startDate != null and invoicesPagination.endDate != null">
AND a.creator_time &gt; #{invoicesPagination.startDate} AND a.creator_time &lt;= #{invoicesPagination.endDate}
</if>
<if test="invoicesPagination.documentNo != null and invoicesPagination.documentNo != ''">
AND a.document_no LIKE CONCAT('%',#{invoicesPagination.documentNo},'%')
</if>
<if test="invoicesPagination.souceno != null and invoicesPagination.souceno != ''">
AND b.document_no LIKE CONCAT('%',#{invoicesPagination.souceno},'%')
</if>
<if test="invoicesPagination.supplierName != null and invoicesPagination.supplierName != ''">
AND d.supplier_name LIKE CONCAT('%',#{invoicesPagination.supplierName},'%')
</if>
<if test="invoicesPagination.purchaseName != null and invoicesPagination.purchaseName != ''">
AND c.contract_name LIKE CONCAT('%',#{invoicesPagination.purchaseName},'%')
</if>
<if test="invoicesPagination.sidx != null and invoicesPagination.sidx != ''">
ORDER BY ${invoicesPagination.sidx} ${invoicesPagination.sort}
</if>
</select>
</mapper>

@ -0,0 +1,20 @@
<?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="jnpf.purchaseback.mapper.PurchasebackMapper">
<select id="queryByKeyword" resultType="jnpf.purchaseback.entity.PurchasebackEntity">
SELECT a.*,b.document_no purchaseorderdocumentno,c.contract_name contractName,d.supplier_name supplierName
from jg_purchaseback a
LEFT JOIN jg_purchaseorder b on a.purchase_order_id = b.id
LEFT JOIN jg_contract c on b.contract_code = c.id
LEFT JOIN jg_supplier d on b.supplier_id = d.id
where 1=1
<if test="purchasebackPagination.documentNo != null and purchasebackPagination.documentNo != ''">
AND a.document_no LIKE CONCAT('%',#{purchasebackPagination.documentNo},'%')
</if>
<if test="purchasebackPagination.sidx != null and purchasebackPagination.sidx != ''">
ORDER BY ${purchasebackPagination.sidx} ${purchasebackPagination.sort}
</if>
</select>
</mapper>

@ -284,7 +284,7 @@
AND a.creator_time &gt; #{purchaseorderPagination.startDate} AND a.creator_time &lt;= #{purchaseorderPagination.endDate}
</if>
<if test="purchaseorderPagination.documentNo != null and purchaseorderPagination.documentNo != ''">
AND a.document_no = #{purchaseorderPagination.documentNo}
AND a.document_no LIKE CONCAT('%',#{purchaseorderPagination.documentNo},'%')
</if>
<if test="purchaseorderPagination.purchaseName != null and purchaseorderPagination.purchaseName != ''">
AND c.contract_name LIKE CONCAT('%',#{purchaseorderPagination.purchaseName},'%')

@ -1,7 +1,28 @@
<?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="jnpf.receiptin.mapper.ReceiptinMapper">
<select id="queryByKeyword" resultType="jnpf.receiptin.entity.ReceiptinEntity">
SELECT a.*,b.document_no purchaseorderSouceno,d.supplier_name supplier
from jg_receiptin a
LEFT JOIN jg_purchaseorder b on a.souceno = b.id
LEFT JOIN jg_supplier d on a.supplier_id = d.id
where 1=1
<if test="receiptinPagination.startDate != null and receiptinPagination.endDate != null">
AND a.creator_time &gt; #{receiptinPagination.startDate} AND a.creator_time &lt;= #{receiptinPagination.endDate}
</if>
<if test="receiptinPagination.documentNo != null and receiptinPagination.documentNo != ''">
AND a.document_no LIKE CONCAT('%',#{receiptinPagination.documentNo},'%')
</if>
<if test="receiptinPagination.souceno != null and receiptinPagination.souceno != ''">
AND b.document_no LIKE CONCAT('%',#{receiptinPagination.souceno},'%')
</if>
<if test="receiptinPagination.supplierName != null and receiptinPagination.supplierName != ''">
AND d.supplier_name LIKE CONCAT('%',#{receiptinPagination.supplierName},'%')
</if>
<if test="receiptinPagination.sidx != null and receiptinPagination.sidx != ''">
ORDER BY ${receiptinPagination.sidx} ${receiptinPagination.sort}
</if>
</select>
</mapper>

@ -25,6 +25,9 @@
<if test="salebackPagination.startDate != null and salebackPagination.endDate != null">
and a.creator_time &gt; #{salebackPagination.startDate} AND a.POUND_DATE &lt;= #{salebackPagination.endDate}
</if>
<if test="salebackPagination.sidx != null and salebackPagination.sidx != ''">
ORDER BY ${salebackPagination.sidx} ${salebackPagination.sort}
</if>
</select>
@ -35,9 +38,10 @@ SELECT
b.price,
b.no_price as noPrice,
c.*,
d.ticketno as vehicleId,
e.item_name as materialId,
f.F_RealName as businessId,
c.pound_type as pountType,
d.ticketno as vehicleName,
e.item_name as materialName,
f.F_RealName as businessName,
g.supplier_nm as customerName
FROM
jg_salesback_item0 a

@ -0,0 +1,56 @@
<?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="jnpf.tradeupload.mapper.TradeuploadMapper">
<select id="queryVehicle" resultType="jnpf.tradeupload.entity.TradeuploadEntity">
select
*
from
jg_poundlist
where
vehicle_id = #{vehicleId} and
gross_weight = #{grossWeight} and
tare_weight = #{tareWeight} and
net_weight = #{netWeight} and
creator_time = DATE_SUB(NOW(),interval 15 day)
</select>
<select id="queryByKeyword" resultType="jnpf.tradeupload.entity.TradeuploadEntity">
SELECT a.*,b.ticketno vehicleName,c.supplier_name supplierName,d.supplier_nm customerName,e.item_name materialName,f.contract_name salesName,g.contract_name purchaseName,h.F_RealName businessName,i.name naturalName,g.contract_no purchaseContractNo,f.contract_no salesContractNo
from jg_poundlist a
LEFT JOIN jg_vehicle b on a.vehicle_id = b.id
LEFT JOIN jg_supplier c on a.supplier_id = c.id
LEFT JOIN jg_customer d on a.customer_id = d.id
LEFT JOIN jg_material e on a.material_id = e.id
LEFT JOIN jg_contract f on a.sales_id = f.id
LEFT JOIN jg_contract g on a.purchase_id = g.id
LEFT JOIN base_user h on a.business_id = h.f_id
LEFT JOIN jg_natural i on a.natural_id = i.id
where a.is_examine = '0'
<if test="tradeuploadPagination.keyword != null and tradeuploadPagination.keyword != ''">
AND (b.ticketno LIKE CONCAT('%',#{tradeuploadPagination.keyword},'%') OR c.supplier_name LIKE CONCAT('%',#{tradeuploadPagination.keyword},'%') OR d.supplier_nm LIKE CONCAT('%',#{tradeuploadPagination.keyword},'%'))
</if>
<if test="tradeuploadPagination.startDate != null and tradeuploadPagination.endDate != null">
AND a.POUND_DATE &gt; #{tradeuploadPagination.startDate} AND a.POUND_DATE &lt;= #{tradeuploadPagination.endDate}
</if>
<if test="tradeuploadPagination.poundlistNo != null and tradeuploadPagination.poundlistNo != ''">
AND a.POUNDLIST_NO LIKE CONCAT('%',#{tradeuploadPagination.poundlistNo},'%')
</if>
<if test="tradeuploadPagination.materialName != null and tradeuploadPagination.materialName != ''">
AND e.item_name LIKE CONCAT('%',#{tradeuploadPagination.materialName},'%')
</if>
<if test="tradeuploadPagination.vehicleName != null and tradeuploadPagination.vehicleName != ''">
AND b.ticketno LIKE CONCAT('%',#{tradeuploadPagination.vehicleName},'%')
</if>
<if test="tradeuploadPagination.salesName != null and tradeuploadPagination.salesName != ''">
AND f.contract_name LIKE CONCAT('%',#{tradeuploadPagination.salesName},'%')
</if>
<if test="tradeuploadPagination.customerName != null and tradeuploadPagination.customerName != ''">
AND d.supplier_nm LIKE CONCAT('%',#{tradeuploadPagination.customerName},'%')
</if>
<if test="tradeuploadPagination.sidx != null and tradeuploadPagination.sidx != ''">
ORDER BY ${tradeuploadPagination.sidx} ${tradeuploadPagination.sort}
</if>
</select>
</mapper>

@ -33,18 +33,18 @@
</popupSelect>
</el-form-item>
</el-col>
</el-col> -->
<el-col :span="8" v-if="judgeShow('supplierId')">
<el-form-item label="供应商" prop="supplierId">
<popupSelect :disabled="judgeWrite('supplierId')" v-model="dataForm.supplierId" placeholder="请选择"
<popupSelect v-model="dataForm.supplierId" placeholder="请选择"
clearable field="supplierId" interfaceId="389674191453990661" :columnOptions="supplierIdcolumnOptions"
propsValue="id" relationField="supplier_name" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
hasPage :pageSize="20">
hasPage :pageSize="20" :disabled="true">
</popupSelect>
</el-form-item>
</el-col> -->
</el-col>
<el-col :span="8" v-if="judgeShow('paymentType')">
<el-form-item label="付款类型" prop="paymentType">
@ -503,6 +503,7 @@
})
}
if(data.purchaseorder && data.purchaseorder.length > 0){
this.dataForm.supplierId = data.purchaseorder[0].supplierId
this.dataForm.businessDate = new Date()
this.dataForm.dueDate = new Date()
var ramount = 0;

@ -29,7 +29,7 @@
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="量" prop="quantity">
<el-form-item label="量" prop="quantity">
<el-input-number v-model="dataForm.quantity" placeholder="数字文本" :step="1" :precision="6"
:style='{"width":"100%"}' :disabled="true">
@ -230,13 +230,13 @@
</el-input>
</template>
</el-table-column>
<el-table-column prop="invoiceQuantity" label="发票数量" width="150">
<el-table-column prop="invoiceQuantity" label="发票数量" width="200">
<template slot-scope="scope">
<!-- <el-input v-model="scope.row.invoiceQuantity" placeholder="请输入" clearable
:style='{"width":"100%"}' @change="invoiceQuantityChange">
</el-input> -->
<el-input-number v-model="scope.row.invoiceQuantity" placeholder="数字文本" :step="1"
:style='{"width":"100%"}' @change="invoiceQuantityChange">
:style='{"width":"100%"}' @change="invoiceQuantityChange" :precision="6">
</el-input-number>
</template>

@ -4,7 +4,7 @@
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll
width="600px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" size="small" label-width="100px" label-position="right" >
<el-form ref="elForm" :model="dataForm" size="small" label-width="100px" label-position="left" >
<template v-if="!loading">
<el-col :span="24" >
<el-form-item label-width="0">
@ -13,36 +13,63 @@
</JNPF-Text>
</el-form-item>
</el-col>
<el-col :span="24" >
<el-col :span="24" v-if="jnpf.hasFormP('name')" >
<el-form-item label="姓名"
prop="name" >
<p>{{dataForm.name}}</p>
</el-form-item>
</el-col>
<el-col :span="24" >
<el-col :span="24" v-if="jnpf.hasFormP('adress')" >
<el-form-item label="地址"
prop="adress" >
<p>{{dataForm.adress}}</p>
</el-form-item>
</el-col>
<el-col :span="24" >
<el-col :span="24" v-if="jnpf.hasFormP('contact')" >
<el-form-item label="手机号"
prop="contact" >
<p>{{dataForm.contact}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-col :span="24" v-if="jnpf.hasFormP('identity')" >
<el-form-item label="身份证"
prop="identity" >
<p>{{dataForm.identity}}</p>
</el-form-item>
</el-col>
<el-col :span="24" v-if="jnpf.hasFormP('bankAccount')" >
<el-form-item label="银行账户"
prop="bankAccount" >
<p>{{dataForm.bankAccount}}</p>
</el-form-item>
</el-col>
<el-col :span="24" v-if="jnpf.hasFormP('bank')" >
<el-form-item label="开户行"
prop="bank" >
<p>{{dataForm.bank}}</p>
</el-form-item>
</el-col>
<el-col :span="24" v-if="jnpf.hasFormP('bankNo')" >
<el-form-item label="行号"
prop="bankNo" >
<p>{{dataForm.bankNo}}</p>
</el-form-item>
</el-col>
<el-col :span="24" v-if="jnpf.hasFormP('photos')" >
<el-form-item label="证件照"
prop="photos" >
<JNPF-UploadImg v-model="dataForm.photos"
disabled
detailed :fileSize="5" sizeUnit="MB" :limit="9" >
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="12" v-if="jnpf.hasFormP('creatorUserName')" >
<el-form-item label="录入人"
prop="creatorUserName" >
<p>{{dataForm.creatorUserName}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="创建时间"
prop="creatorTime" >
<p>{{dataForm.creatorTime}}</p>
</el-form-item>
</el-col>
</template>
</el-form>
</el-row>
@ -69,6 +96,11 @@
name : '',
adress : '',
contact : '',
identity : '',
bankAccount : '',
bank : '',
bankNo : '',
photos : [],
creatorUserName : '',
creatorTime : "",
},
@ -84,6 +116,7 @@
methods: {
dataInfo(dataAll){
let _dataAll =dataAll
_dataAll.photos = _dataAll.photos ? JSON.parse( _dataAll.photos):[]
this.dataForm = _dataAll
},

@ -1,203 +1,221 @@
<template>
<el-dialog :title="!dataForm.id ? '新建' : isDetail ? '详情':'编辑'"
:close-on-click-modal="false" append-to-body
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll
width="800px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="24">
<el-form-item label-width="0">
<JNPF-Text :style='{"width":"100%"}'
:textStyle='{"color":"#000000","font-weight":"normal","text-decoration":"none","font-size":18,"line-height":32,"font-style":"normal","text-align":"left"}'
value="自然人档案">
</JNPF-Text>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="姓名"
prop="name">
<el-input v-model="dataForm.name"
placeholder="请输入姓名" clearable :style='{"width":"100%"}'>
<el-dialog :title="!dataForm.id ? '新建' : isDetail ? '详情' : '编辑'" :close-on-click-modal="false" append-to-body
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll width="600px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="left">
<template v-if="!loading">
<el-col :span="24">
<el-form-item label-width="0">
<JNPF-Text :style='{ "width": "100%" }'
:textStyle='{ "color": "#000000", "font-weight": "normal", "text-decoration": "none", "font-size": 18, "line-height": 32, "font-style": "normal", "text-align": "left" }'
value="自然人档案">
</JNPF-Text>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="姓名" prop="name">
<el-input v-model="dataForm.name" placeholder="请输入姓名" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="地址"
prop="adress">
<el-input v-model="dataForm.adress"
placeholder="请输入地址" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="地址" prop="adress">
<el-input v-model="dataForm.adress" placeholder="请输入地址" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="手机号"
prop="contact">
<el-input v-model="dataForm.contact"
placeholder="请输入手机号" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="手机号" prop="contact">
<el-input v-model="dataForm.contact" placeholder="请输入手机号" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<!-- <el-col :span="12">-->
<!-- <el-form-item label="录入人"-->
<!-- prop="creatorUserName">-->
<!-- <el-input v-model="dataForm.creatorUserName"-->
<!-- placeholder="请输入录入人" clearable :style='{"width":"100%"}'>-->
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="身份证" prop="identity">
<el-input v-model="dataForm.identity" placeholder="请输入身份证" clearable :style='{ "width": "100%" }'>
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
<!-- <el-col :span="12">-->
<!-- <el-form-item label="创建时间"-->
<!-- prop="creatorTime">-->
<!-- <el-input v-model="dataForm.creatorTime"-->
<!-- placeholder="系统自动生成" readonly>-->
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="银行账户" prop="bankAccount">
<el-input v-model="dataForm.bankAccount" placeholder="请输入银行账户" clearable
:style='{ "width": "100%" }'>
<!-- </el-input>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
</template>
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false"> </el-button>
<el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail"> </el-button>
</span>
</el-dialog>
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="开户行" prop="bank">
<el-input v-model="dataForm.bank" placeholder="请输入开户行" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="行号" prop="bankNo">
<el-input v-model="dataForm.bankNo" placeholder="请输入行号" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="证件照" prop="photos">
<JNPF-UploadImg v-model="dataForm.photos" :fileSize="5" sizeUnit="MB" :limit="9">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="录入人" prop="creatorUserName">
<el-input v-model="dataForm.creatorUserName" placeholder="请输入录入人" clearable
:style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
</template>
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false"> </el-button>
<el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail"> </el-button>
</span>
</el-dialog>
</template>
<script>
import request from '@/utils/request'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
export default {
import request from '@/utils/request'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
export default {
components: {},
props: [],
data() {
return {
visible: false,
loading: false,
isDetail: false,
dataForm: {
name: '',
adress: '',
contact: '',
creatorUserName: '',
creatorTime: ''
},
rules:
{
name: [
{
required: true,
message: '请输入姓名',
trigger: 'blur'
}
],
contact: [{
pattern: /^1[3456789]\d{9}$/,
message: '请输入正确的手机号码',
trigger: 'blur'
},]
}
return {
visible: false,
loading: false,
isDetail: false,
dataForm: {
name: '',
adress: '',
contact: '',
identity: '',
bankAccount: '',
bank: '',
bankNo: '',
photos: [],
creatorUserName: '',
creatorTime: "",
},
rules:
{
name: [
{
required: true,
message: '请输入姓名',
trigger: 'blur'
},
],
},
}
}
},
computed: {},
watch: {},
created() {
},
mounted() {
},
mounted() { },
methods: {
clearData(data) {
for (let key in data) {
if (data[key] instanceof Array) {
data[key] = []
} else if (data[key] instanceof Object) {
this.clearData(data[key])
} else {
data[key] = ''
}
}
},
init(id, isDetail) {
this.dataForm.id = id || 0
this.visible = true
this.isDetail = isDetail || false
this.$nextTick(() => {
this.$refs['elForm'].resetFields()
if (this.dataForm.id) {
this.loading = true
request({
url: '/api/example/Jg_natural/' + this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
})
} else {
this.clearData(this.dataForm)
}
})
this.$store.commit('generator/UPDATE_RELATION_DATA', {})
},
//
dataFormSubmit() {
this.$refs['elForm'].validate((valid) => {
if (valid) {
this.request()
}
})
},
request() {
var _data = this.dataList()
if (!this.dataForm.id) {
request({
url: '/api/example/Jg_natural',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
} else {
request({
url: '/api/example/Jg_natural/' + this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
clearData(data) {
for (let key in data) {
if (data[key] instanceof Array) {
data[key] = [];
} else if (data[key] instanceof Object) {
this.clearData(data[key]);
} else {
data[key] = "";
}
}
},
init(id, isDetail) {
this.dataForm.id = id || 0;
this.visible = true;
this.isDetail = isDetail || false;
this.$nextTick(() => {
this.$refs['elForm'].resetFields();
if (this.dataForm.id) {
this.loading = true
request({
url: '/api/example/Jg_natural/' + this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
});
} else {
this.clearData(this.dataForm)
}
});
this.$store.commit('generator/UPDATE_RELATION_DATA', {})
},
//
dataFormSubmit() {
this.$refs['elForm'].validate((valid) => {
if (valid) {
this.request()
}
})
})
}
},
dataList() {
var _data = JSON.parse(JSON.stringify(this.dataForm))
return _data
},
dataInfo(dataAll) {
let _dataAll = dataAll
this.dataForm = _dataAll
}
}
}
},
request() {
var _data = this.dataList()
if (!this.dataForm.id) {
request({
url: '/api/example/Natural',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
} else {
request({
url: '/api/example/Jg_natural/' + this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
}
},
dataList() {
var _data = JSON.parse(JSON.stringify(this.dataForm));
_data.photos = JSON.stringify(_data.photos)
return _data;
},
dataInfo(dataAll) {
let _dataAll = dataAll
_dataAll.photos = JSON.parse(_dataAll.photos)
this.dataForm = _dataAll
},
},
}
</script>

@ -1,264 +1,283 @@
<template>
<div class="JNPF-common-layout">
<div class="JNPF-common-layout">
<div class="JNPF-common-layout-center">
<el-row class="JNPF-common-search-box" :gutter="16">
<el-form @submit.native.prevent>
<el-col :span="6">
<el-form-item label="姓名">
<el-input v-model="query.name" placeholder="请输入" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="手机号">
<el-input v-model="query.contact" placeholder="请输入" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="search()"></el-button>
<el-button icon="el-icon-refresh-right" @click="reset()"></el-button>
</el-form-item>
</el-col>
</el-form>
</el-row>
<div class="JNPF-common-layout-main JNPF-flex-main">
<div class="JNPF-common-head">
<div>
<el-button type="primary" v-has="'btn_add'" icon="el-icon-plus" @click="addOrUpdateHandle()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="exportData()" v-has="'btn_download'">
</el-button>
<!-- <el-button type="text" icon="el-icon-download" v-has="'btn_upload'" @click="">-->
<!-- </el-button>-->
<el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()" v-has="'btn_batchRemove'" >批量删除
</el-button>
</div>
<div class="JNPF-common-head-right">
<el-tooltip effect="dark" content="刷新" placement="top">
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
@click="reset()"/>
</el-tooltip>
<screenfull isContainer/>
</div>
<div class="JNPF-common-layout-center">
<el-row class="JNPF-common-search-box" :gutter="16">
<el-form @submit.native.prevent>
<el-col :span="6">
<el-form-item label="姓名">
<el-input v-model="query.name" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="手机号">
<el-input v-model="query.contact" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="银行账户">
<el-input v-model="query.bankAccount" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
<template v-if="showAll">
<el-col :span="6">
<el-form-item label="身份证">
<el-input v-model="query.identity" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
</template>
<el-col :span="6">
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="search()"></el-button>
<el-button icon="el-icon-refresh-right" @click="reset()"></el-button>
<el-button type="text" icon="el-icon-arrow-down" @click="showAll = true" v-if="!showAll">
展开
</el-button>
<el-button type="text" icon="el-icon-arrow-up" @click="showAll = false" v-else>
收起
</el-button>
</el-form-item>
</el-col>
</el-form>
</el-row>
<div class="JNPF-common-layout-main JNPF-flex-main">
<div class="JNPF-common-head">
<div>
<el-button type="primary" icon="el-icon-plus" v-has="'btn_add'" @click="addOrUpdateHandle()">
</el-button>
<el-button type="text" icon="el-icon-download" @click="exportData()" v-has="'btn_download'">
</el-button>
<el-button type="text" icon="el-icon-delete" @click="handleBatchRemoveDel()"
v-has="'btn_batchRemove'">批量删除
</el-button>
</div>
<div class="JNPF-common-head-right">
<el-tooltip effect="dark" content="刷新" placement="top">
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
@click="reset()" />
</el-tooltip>
<screenfull isContainer />
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c
@selection-change="handleSelectionChange">
<el-table-column prop="name" label="姓名" width="0" align="left" />
<el-table-column prop="adress" label="地址" width="0" align="left" />
<el-table-column prop="contact" label="手机号" width="0" align="left" />
<el-table-column prop="creatorUserName" label="录入人" width="0" align="left" />
<el-table-column prop="creatorTime" label="创建时间" width="0" align="left" />
<el-table-column prop="identity" label="身份证" width="0" align="left" />
<el-table-column prop="bankAccount" label="银行账户" width="0" align="left" />
<el-table-column prop="bank" label="开户行" width="0" align="left" />
<el-table-column prop="bankNo" label="行号" width="0" align="left" />
<el-table-column label="操作" fixed="right" width="100">
<template slot-scope="scope">
<el-button type="text" @click="addOrUpdateHandle(scope.row.id)" v-has="'btn_edit'">
</el-button>
<el-button type="text" class="JNPF-table-delBtn" v-has="'btn_remove'"
@click="handleDel(scope.row.id)">删除
</el-button>
</template>
</el-table-column>
</JNPF-table>
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
@pagination="initData" />
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="name" label="姓名" width="300" align="center" fixed="left" sortable
/>
<el-table-column prop="adress" label="地址" width="300" align="center" sortable
/>
<el-table-column prop="contact" label="手机号" width="300" align="center" sortable
/>
<el-table-column prop="creatorUserName" label="录入人" width="300" align="center" sortable
/>
<el-table-column prop="creatorTime" label="创建时间" width="300" align="center" sortable
/>
<el-table-column label="操作" fixed="right"
width="150">
<template slot-scope="scope">
<el-button type="text" v-has="'btn_edit'"
@click="addOrUpdateHandle(scope.row.id)">编辑
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)" v-has="'btn_remove'">
</el-button>
<el-button type="text"
@click="goDetail(scope.row.id)">详情
</el-button>
</template>
</el-table-column>
</JNPF-table>
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
@pagination="initData"/>
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh" />
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download" />
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible = false" />
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh"/>
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download"/>
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false"/>
</div>
</template>
<script>
import request from '@/utils/request'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import ExportBox from './ExportBox'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import Detail from './Detail'
import request from '@/utils/request'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import ExportBox from './ExportBox'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import Detail from './Detail'
export default {
export default {
components: { JNPFForm, ExportBox, Detail },
data() {
return {
detailVisible: false,
query: {
name: undefined,
contact: undefined
},
treeProps: {
children: 'children',
label: 'fullName',
value: 'id'
},
list: [],
listLoading: true,
multipleSelection: [], total: 0,
listQuery: {
currentPage: 1,
pageSize: 20,
sort: 'desc',
sidx: 'creatorTime'
},
formVisible: false,
exportBoxVisible: false,
columnList: [
{ prop: 'name', label: '姓名' },
{ prop: 'adress', label: '地址' },
{ prop: 'contact', label: '手机号' },
{ prop: 'creatorUserName', label: '录入人' },
{ prop: 'creatorTime', label: '创建时间' }
]
}
return {
showAll: false,
detailVisible: false,
query: {
name: undefined,
contact: undefined,
bankAccount: undefined,
identity: undefined,
},
treeProps: {
children: 'children',
label: 'fullName',
value: 'id'
},
list: [],
listLoading: true,
multipleSelection: [], total: 0,
listQuery: {
currentPage: 1,
pageSize: 20,
sort: "desc",
sidx: "creatorTime",
},
formVisible: false,
exportBoxVisible: false,
columnList: [
{ prop: 'name', label: '姓名' },
{ prop: 'adress', label: '地址' },
{ prop: 'contact', label: '手机号' },
{ prop: 'creatorUserName', label: '录入人' },
{ prop: 'creatorTime', label: '创建时间' },
{ prop: 'identity', label: '身份证' },
{ prop: 'bankAccount', label: '银行账户' },
{ prop: 'bank', label: '开户行' },
{ prop: 'bankNo', label: '行号' },
],
}
},
computed: {
menuId() {
return this.$route.meta.modelId || ''
}
menuId() {
return this.$route.meta.modelId || ''
}
},
created() {
this.initData()
this.initData()
},
methods: {
goDetail(id) {
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(id)
})
},
sortChange({ column, prop, order }) {
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
this.listQuery.sidx = !order ? '' : prop
this.initData()
},
initData() {
this.listLoading = true
let _query = {
...this.listQuery,
...this.query,
menuId: this.menuId
}
request({
url: `/api/example/Jg_natural/getList`,
method: 'post',
data: _query
}).then(res => {
var _list = []
for (let i = 0; i < res.data.list.length; i++) {
let _data = res.data.list[i]
_list.push(_data)
}
this.list = _list
this.total = res.data.pagination.total
goDetail(id) {
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(id)
})
},
sortChange({ column, prop, order }) {
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
this.listQuery.sidx = !order ? '' : prop
this.initData()
},
initData() {
this.listLoading = true;
let _query = {
...this.listQuery,
...this.query,
menuId: this.menuId
};
request({
url: `/api/example/Jg_natural/getList`,
method: 'post',
data: _query
}).then(res => {
var _list = [];
for (let i = 0; i < res.data.list.length; i++) {
let _data = res.data.list[i];
_list.push(_data)
}
this.list = _list
console.log(this.list)
this.total = res.data.pagination.total
this.listLoading = false
})
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Jg_natural/${id}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
this.listLoading = false
})
})
}).catch(() => {
})
},
handleSelectionChange(val) {
const res = val.map(item => item.id)
this.multipleSelection = res
},
handleBatchRemoveDel() {
if (!this.multipleSelection.length) {
this.$message({
type: 'error',
message: '请选择一条数据',
duration: 1500
})
return
}
const ids = this.multipleSelection.join()
this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Jg_natural/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Jg_natural/${id}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}).catch(() => {
});
},
handleSelectionChange(val) {
const res = val.map(item => item.id)
this.multipleSelection = res
},
handleBatchRemoveDel() {
if (!this.multipleSelection.length) {
this.$message({
type: 'error',
message: '请选择一条数据',
duration: 1500,
})
return
}
const ids = this.multipleSelection.join()
this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Jg_natural/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
});
})
}).catch(() => {
})
})
}).catch(() => {
})
},
addOrUpdateHandle(id, isDetail) {
this.formVisible = true
this.$nextTick(() => {
this.$refs.JNPFForm.init(id, isDetail)
})
},
exportData() {
this.exportBoxVisible = true
this.$nextTick(() => {
this.$refs.ExportBox.init(this.columnList)
})
},
download(data) {
let query = { ...data, ...this.listQuery, ...this.query, menuId: this.menuId }
request({
url: `/api/example/Jg_natural/Actions/Export`,
method: 'GET',
data: query
}).then(res => {
if (!res.data.url) return
this.jnpf.downloadFile(res.data.url)
this.$refs.ExportBox.visible = false
this.exportBoxVisible = false
})
},
search() {
this.listQuery = {
currentPage: 1,
pageSize: 20,
sort: 'desc',
sidx: 'creatorTime'
}
this.initData()
},
refresh(isrRefresh) {
this.formVisible = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {
this.query[key] = undefined
},
addOrUpdateHandle(id, isDetail) {
this.formVisible = true
this.$nextTick(() => {
this.$refs.JNPFForm.init(id, isDetail)
})
},
exportData() {
this.exportBoxVisible = true
this.$nextTick(() => {
this.$refs.ExportBox.init(this.columnList)
})
},
download(data) {
let query = { ...data, ...this.listQuery, ...this.query, menuId: this.menuId }
request({
url: `/api/example/Jg_natural/Actions/Export`,
method: 'GET',
data: query
}).then(res => {
if (!res.data.url) return
this.jnpf.downloadFile(res.data.url)
this.$refs.ExportBox.visible = false
this.exportBoxVisible = false
})
},
search() {
this.listQuery = {
currentPage: 1,
pageSize: 20,
sort: "desc",
sidx: "creatorTime",
}
this.initData()
},
refresh(isrRefresh) {
this.formVisible = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {
this.query[key] = undefined
}
this.search()
}
this.search()
}
}
}
}
</script>

@ -77,6 +77,14 @@
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="实付日期" prop="businessdate">
<el-date-picker v-model="dataForm.businessdate" placeholder="请选择" clearable :style='{"width":"100%"}'
type="date" format="yyyy-MM-dd" value-format="timestamp">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="币别 " prop="currency">
<el-select v-model="dataForm.currency" placeholder="请选择" clearable :style='{"width":"100%"}'>

@ -77,6 +77,14 @@
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="实付日期" prop="businessdate">
<el-date-picker v-model="dataForm.businessdate" placeholder="请选择" clearable :style='{"width":"100%"}'
type="date" format="yyyy-MM-dd" value-format="timestamp">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="币别 " prop="currency">
<el-select v-model="dataForm.currency" placeholder="请选择" clearable :style='{"width":"100%"}'>
@ -259,6 +267,7 @@
collectionbank: '',
requestedamount: '',
duedate: '',
businessdate: '',
currency: "0",
settlementtype: "0",
paymentno: '',
@ -282,6 +291,12 @@
trigger: 'blur'
},
],
businessdate: [{
required: true,
message: '请选择实付日期',
trigger: 'blur'
}
],
},
paymenttypeOptions: [{
"fullName": "货款",

@ -69,6 +69,7 @@
</template>
</el-table-column>
<el-table-column prop="duedate" label="应付日期" sortable width="140" align="center" />
<el-table-column prop="businessdate" label="实付日期" sortable width="140" align="center" />
<el-table-column prop="paymentamount" label="付款金额" sortable width="140" align="center" />
<el-table-column prop="requestedamount" label="申请金额" sortable width="140" align="center" />
<el-table-column prop="paymentaccount" label="付款账户" sortable width="140" align="center" />

@ -8,6 +8,11 @@
<el-input v-model="query.documentNo" placeholder="请输入" clearable> </el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="供应商">
<el-input v-model="query.supplierName" placeholder="请输入" clearable></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="search()"></el-button>
@ -51,6 +56,7 @@
{{ scope.row.settlementType | dynamicText(settlementTypeOptions) }}
</template>
</el-table-column>
<el-table-column prop="supplierName" label="供应商" width="200" align="center" sortable="custom" />
<el-table-column prop="ramount" label="申请金额" width="150" align="center" sortable="custom" />
<el-table-column prop="paymentAmount" label="付款金额" width="150" align="center" sortable="custom" />
<el-table-column prop="unpaymentAmount" label="未付款金额" width="150" align="center" sortable="custom" />
@ -345,7 +351,7 @@
},
fukuanHandle(id, flowState, docStatus){
if(flowState == 2){
if(docStatus != 3){
//if(docStatus != 3){
this.formVisible = true
this.$nextTick(() => {
request({
@ -355,14 +361,14 @@
this.$refs.JNPFForm.init(res.data)
})
})
}else{
/* }else{
this.$message({
type: 'error',
message: '该订单已付款',
duration: 1000
});
return
}
} */
}else{
this.$message({

@ -81,6 +81,14 @@
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="实付日期" prop="businessdate">
<el-date-picker v-model="dataForm.businessdate" placeholder="请选择" clearable :style='{"width":"100%"}'
type="date" format="yyyy-MM-dd" value-format="timestamp">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="币别 " prop="currency">
<el-select v-model="dataForm.currency" placeholder="请选择" clearable :style='{"width":"100%"}'>
@ -270,6 +278,7 @@
collectionbank: '',
requestedamount: '',
duedate: '',
businessdate: '',
currency: "0",
settlementtype: "0",
paymentno: '',
@ -293,6 +302,12 @@
trigger: 'blur'
},
],
businessdate: [{
required: true,
message: '请选择实付日期',
trigger: 'blur'
}
],
},
paymenttypeOptions: [{
"fullName": "货款",
@ -428,6 +443,7 @@
this.dataForm.collectionaccount = paymentdoc.collectionAccount
this.dataForm.collectionbank = paymentdoc.colectionBank
this.dataForm.duedate = paymentdoc.dueDate
this.dataForm.businessdate = paymentdoc.businessdate
this.dataForm.currency = paymentdoc.currency
this.dataForm.settlementtype = paymentdoc.settlementType
this.dataForm.paymentno = paymentdoc.documentNo

@ -4,13 +4,20 @@
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="24">
<el-col :span="12">
<el-form-item label="磅单上传" prop="poundPictures">
<JNPF-UploadImg v-model="dataForm.poundPictures" :fileSize="500" sizeUnit="MB" :limit="1" :disabled="true">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="车辆图片" prop="vehiclePictures">
<JNPF-UploadImg v-model="dataForm.vehiclePictures" :fileSize="500" sizeUnit="MB" :limit="9">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="物料名称" prop="materialId">
<popupSelect v-model="dataForm.materialId" placeholder="请选择物料名称" clearable field="materialId"
@ -63,7 +70,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="采购价格" prop="purchasePrice">
<el-input-number v-model="dataForm.purchasePrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.purchasePrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -79,40 +86,32 @@
<el-col :span="6">
<el-form-item label="收货价格" prop="collectPrice">
<el-input-number v-model="dataForm.collectPrice" :style='{"width":"100%"}'></el-input-number>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="车辆图片" prop="vehiclePictures">
<JNPF-UploadImg v-model="dataForm.vehiclePictures" :fileSize="500" sizeUnit="MB" :limit="9">
</JNPF-UploadImg>
<el-input-number v-model="dataForm.collectPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="销售价格" prop="salesPrice">
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="扣重" prop="buckleWeight">
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="净重" prop="netWeight">
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -159,7 +158,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="运费" prop="transportPrice">
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -169,7 +168,7 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务员" prop="businessId">
<el-form-item label="业务员1" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员" clearable field="businessId"
interfaceId="ebcc44be142e43b795c0d769abd6d25a" :columnOptions="businessIdcolumnOptions"
propsValue="F_Id" relationField="F_RealName" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
@ -179,8 +178,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="自然人" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择自然人" clearable field="naturalId"
<el-form-item label="业务员2" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择业务员2" clearable field="naturalId"
interfaceId="395933800510599301" :columnOptions="naturalIdcolumnOptions" propsValue="id"
relationField="name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage :pageSize="20">
@ -434,13 +433,13 @@
"value": "positionName"
}],
naturalIdcolumnOptions: [{
"label": "自然人名称",
"label": "业务员2名称",
"value": "name"
}, {
"label": "自然人手机号",
"label": "业务员2手机号",
"value": "contact"
}, {
"label": "自然人地址",
"label": "业务员2地址",
"value": "adress"
}, ],

@ -4,13 +4,20 @@
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="24">
<el-col :span="12">
<el-form-item label="磅单上传" prop="poundPictures">
<JNPF-UploadImg v-model="dataForm.poundPictures" :fileSize="500" sizeUnit="MB" :limit="9" :disabled="true">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="车辆图片" prop="vehiclePictures">
<JNPF-UploadImg v-model="dataForm.vehiclePictures" :fileSize="500" sizeUnit="MB" :limit="9">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="物料名称" prop="materialId">
<popupSelect v-model="dataForm.materialId" placeholder="请选择物料名称" clearable field="materialId"
@ -63,7 +70,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="采购价格" prop="purchasePrice">
<el-input-number v-model="dataForm.purchasePrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.purchasePrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -79,40 +86,32 @@
<el-col :span="6">
<el-form-item label="收货价格" prop="collectPrice">
<el-input-number v-model="dataForm.collectPrice" :style='{"width":"100%"}'></el-input-number>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="车辆图片" prop="vehiclePictures">
<JNPF-UploadImg v-model="dataForm.vehiclePictures" :fileSize="500" sizeUnit="MB" :limit="9">
</JNPF-UploadImg>
<el-input-number v-model="dataForm.collectPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="扣重" prop="buckleWeight">
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="净重" prop="netWeight">
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="销售价格" prop="salesPrice">
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
@ -160,7 +159,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="运费" prop="transportPrice">
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -170,8 +169,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务员" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员" clearable field="businessId"
<el-form-item label="业务员1" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员1" clearable field="businessId"
interfaceId="ebcc44be142e43b795c0d769abd6d25a" :columnOptions="businessIdcolumnOptions"
propsValue="F_Id" relationField="F_RealName" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
hasPage :pageSize="20" :bissId="dataForm.businessId">
@ -180,8 +179,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="自然人" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择自然人" clearable field="naturalId"
<el-form-item label="业务员2" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择业务员2" clearable field="naturalId"
interfaceId="395933800510599301" :columnOptions="naturalIdcolumnOptions" propsValue="id"
relationField="name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage :pageSize="20">
@ -432,13 +431,13 @@
"value": "positionName"
}],
naturalIdcolumnOptions: [{
"label": "自然人名称",
"label": "业务员2名称",
"value": "name"
}, {
"label": "自然人手机号",
"label": "业务员2手机号",
"value": "contact"
}, {
"label": "自然人地址",
"label": "业务员2地址",
"value": "adress"
}, ],
@ -476,7 +475,6 @@
},
customerSelect2(a, b) {
this.dataForm.supplierId = b.code;
debugger
},
handleAvatarSuccess(res, file) {
this.imageUrl = URL.createObjectURL(file.raw);
@ -620,7 +618,6 @@
},
request2() {
var _data = this.dataList()
debugger
if (!this.dataForm.id) {
request({
url: '/api/tradeupload/Tradeupload',

@ -49,35 +49,35 @@
</el-col>
<el-col :span="8">
<el-form-item label="垫资金额" prop="advanceAmount">
<el-input-number v-model="dataForm.advanceAmount" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}'>
<el-input-number v-model="dataForm.advanceAmount" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}' :disabled="true">
</el-input-number>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="重量" prop="num">
<el-input-number v-model="dataForm.num" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}'>
<el-input-number v-model="dataForm.num" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}' :disabled="true">
</el-input-number>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="金额" prop="amount">
<el-input-number v-model="dataForm.amount" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}'>
<el-input-number v-model="dataForm.amount" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}' :disabled="true">
</el-input-number>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="不含税金额" prop="notAmount">
<el-input-number v-model="dataForm.notAmount" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}'>
<el-input-number v-model="dataForm.notAmount" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}' :disabled="true">
</el-input-number>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="税额" prop="rate">
<el-input-number v-model="dataForm.rate" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}'>
<el-input-number v-model="dataForm.rate" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}' :disabled="true">
</el-input-number>
</el-form-item>
@ -221,21 +221,21 @@
</el-select>
</template>
</el-table-column>
<el-table-column prop="amount" label="金额" align="center" width="130" >
<el-table-column prop="remark" label="备注" align="center" width="130" >
<template slot-scope="scope">
<el-input v-model="scope.row.amount" placeholder="请输入" clearable :style='{"width":"100%"}' :disabled="true">
<el-input v-model="scope.row.remark" placeholder="请输入" clearable :style='{"width":"100%"}'>
</el-input>
</template>
</el-table-column>
<el-table-column prop="notAmount" label="不含税金额" align="center" width="130" >
<el-table-column prop="amount" label="金额" align="center" width="130" >
<template slot-scope="scope">
<el-input v-model="scope.row.notAmount" placeholder="请输入" clearable :style='{"width":"100%"}' :disabled="true">
<el-input v-model="scope.row.amount" placeholder="请输入" clearable :style='{"width":"100%"}' :disabled="true">
</el-input>
</template>
</el-table-column>
<el-table-column prop="remark" label="备注" align="center" width="130" >
<el-table-column prop="notAmount" label="不含税金额" align="center" width="130" >
<template slot-scope="scope">
<el-input v-model="scope.row.remark" placeholder="请输入" clearable :style='{"width":"100%"}'>
<el-input v-model="scope.row.notAmount" placeholder="请输入" clearable :style='{"width":"100%"}' :disabled="true">
</el-input>
</template>
</el-table-column>

@ -0,0 +1,764 @@
<template>
<el-dialog :title="!dataForm.id ? '新建' : isDetail ? '详情':'审核'" :close-on-click-modal="false" append-to-body
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll width="1500px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" :rules="rules" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="12">
<el-form-item label="磅单上传" prop="poundPictures">
<JNPF-UploadImg disabled v-model="dataForm.poundPictures" :fileSize="500" sizeUnit="MB" :limit="1" :disabled="true">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="车辆图片" prop="vehiclePictures">
<JNPF-UploadImg v-model="dataForm.vehiclePictures" :fileSize="500" sizeUnit="MB" :limit="9">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="物料名称" prop="materialId">
<popupSelect disabled v-model="dataForm.materialId" placeholder="请选择物料编码" clearable field="materialId"
interfaceId="381037852907038533" :columnOptions="materialIdcolumnOptions" propsValue="id"
relationField="item_name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage
:pageSize="20">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="客户名称" prop="customerId">
<popupSelect disabled v-model="dataForm.customerId" placeholder="请选择客户" clearable field="customerId"
interfaceId="395936123471343749" :columnOptions="customerIdcolumnOptions" propsValue="id"
relationField="supplier_nm" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage
:pageSize="20" @change="customerSelect">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="销售合同" prop="salesId">
<popupSelect disabled v-model="dataForm.salesId" placeholder="请选择合同" clearable field="salesId"
interfaceId="396203872441416837" :columnOptions="salesIdcolumnOptions" propsValue="id"
relationField="contract_name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" :bissId="dataForm.customerId"
hasPage :pageSize="20">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="采购合同" prop="purchaseId">
<popupSelect disabled v-model="dataForm.purchaseId" placeholder="请选择合同" clearable field="purchaseId"
interfaceId="397408984857931205" :columnOptions="salesIdcolumnOptions" propsValue="id"
relationField="contract_name" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
hasPage :pageSize="20" @change="customerSelect2">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="供应商" prop="supplierId">
<popupSelect disabled v-model="dataForm.supplierId" placeholder="请选择客户" clearable field="supplierId"
interfaceId="382494924156735557" :columnOptions="supplierIdcolumnOptions" propsValue="id"
relationField="supplier_name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage
:pageSize="20" :disabled="true">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="采购价格" prop="purchasePrice">
<el-input-number disabled v-model="dataForm.purchasePrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="销售价格" prop="salesPrice">
<el-input-number disabled v-model="dataForm.salesPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="毛重" prop="grossWeight">
<el-input-number disabled v-model="dataForm.grossWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="皮重" prop="tareWeight">
<el-input-number disabled v-model="dataForm.tareWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="扣重" prop="buckleWeight">
<el-input-number disabled v-model="dataForm.buckleWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="净重" prop="netWeight">
<el-input-number disabled v-model="dataForm.netWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="车牌号" prop="vehicleId">
<popupSelect disabled v-model="dataForm.vehicleId" placeholder="请选择车辆" clearable field="vehicleId"
interfaceId="381432451370615173" :columnOptions="vehicleIdcolumnOptions" propsValue="id"
relationField="ticketno" popupType="dialog" popupTitle="选择数据" popupWidth="800px" @change="changePicture"
hasPage :pageSize="20">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="磅单时间" prop="poundDate">
<el-date-picker disabled v-model="dataForm.poundDate" placeholder="请选择" clearable :style='{"width":"100%"}'
type="date" format="yyyy-MM-dd" value-format="timestamp">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="磅单号" prop="poundlistNo">
<el-input disabled v-model="dataForm.poundlistNo" placeholder="请输入" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="单位 " prop="unit">
<el-select disabled v-model="unit" placeholder="请选择" clearable :style='{"width":"100%"}' @change="unitChange">
<el-option v-for="(item, index) in unitOptions" :key="index" :label="item.fullName" :value="item.id"
:disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="运输类型" prop="transportType">
<el-select disabled v-model="transportType" placeholder="请选择" clearable :style='{"width":"100%"}' @change="transportTypeChange">
<el-option v-for="(item, index) in transportTypeOptions" :key="index" :label="item.fullName"
:value="item.id" :disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="是否垫资" prop="advance">
<el-select disabled v-model="advance" placeholder="请选择" clearable :style='{"width":"100%"}' @change="advanceChange">
<el-option v-for="(item, index) in advanceOptions" :key="index" :label="item.fullName" :value="item.id"
:disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="运费" prop="transportPrice">
<el-input-number disabled v-model="dataForm.transportPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="起始地" prop="originPlace">
<JNPF-Address disabled v-model="dataForm.originPlace" placeholder="请选择省市区" clearable :level='2' >
</JNPF-Address>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务员1" prop="businessId">
<popupSelect disabled v-model="dataForm.businessId" placeholder="请选择业务员1" clearable field="businessId"
interfaceId="ebcc44be142e43b795c0d769abd6d25a" :columnOptions="businessIdcolumnOptions"
propsValue="F_Id" relationField="F_RealName" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
hasPage :pageSize="20" :bissId="dataForm.businessId">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务员2" prop="naturalId">
<popupSelect disabled v-model="dataForm.naturalId" placeholder="请选择业务员2" clearable field="naturalId"
interfaceId="395933800510599301" :columnOptions="naturalIdcolumnOptions" propsValue="id"
relationField="name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage :pageSize="20">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="备注" prop="remark">
<el-input v-model="dataForm.remark" placeholder="请输入备注信息" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
</template>
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false"> </el-button>
<el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail"> </el-button>
<!-- <el-button type="primary" @click="continueUpload()"> </el-button>-->
</span>
</el-dialog>
</template>
<script>
import request from '@/utils/request'
import {
getDataInterfaceRes
} from '@/api/systemData/dataInterface'
import {
getDictionaryDataSelector
} from '@/api/systemData/dictionary'
export default {
components: {},
props: [],
data() {
return {
unit: "0",
transportType: "0",
advance: "0",
action: this.define.APIURl + '/api/tradeupload/Tradeupload/UploaderPondList/annexpic',
imageUrl: '',
code: '100',
fileList: [],
visible: false,
loading: false,
isDetail: false,
dataForm: {
poundPictures: [],
materialId: "",
customerId: "",
supplierId: "",
salesId: "",
vehicleId: "",
vehiclePictures: [],
poundDate: '',
poundlistNo: '',
tareWeight: 0,
grossWeight: 0,
buckleWeight: 0,
netWeight: 0,
unit: "0",
transportType: "0",
originPlace:[],
advance: "0",
transportPrice: 0,
salesPrice: 0,
purchasePrice: 0,
businessId: "",
naturalId: "",
remark: '',
creatorTime: "",
isExamine: "",
},
rules: {
materialId: [{
required: true,
message: '请选择物料编码',
trigger: 'change'
}, ],
customerId: [{
required: true,
message: '请选择客户',
trigger: 'change'
}, ],
supplierId: [{
required: true,
message: '请选择供应商',
trigger: 'change'
}, ],
purchaseId: [{
required: true,
message: '请选择采购合同',
trigger: 'change'
}, ],
salesId: [{
required: true,
message: '请选择合同',
trigger: 'change'
}, ],
vehicleId: [{
required: true,
message: '请选择车辆',
trigger: 'change'
}, ],
// vehiclePictures: [{
// required: true,
// message: '',
// trigger: 'click'
// }, ],
poundDate: [{
required: true,
message: '请选择',
trigger: 'change'
}, ],
poundlistNo: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
tareWeight: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
grossWeight: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
buckleWeight: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
netWeight: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
salesPrice: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
purchasePrice: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
businessId: [{
required: true,
message: '请选择业务员',
trigger: 'change'
}, ],
},
materialIdcolumnOptions: [{
"label": "物料编码",
"value": "item_code"
}, {
"label": "物料名称",
"value": "item_name"
}, {
"label": "单位",
"value": "primary_unit_of_measure"
}, {
"label": "默认入库区",
"value": "in_area"
}, {
"label": "默认出库区",
"value": "out_area"
}, ],
customerIdcolumnOptions: [{
"label": "客户编码",
"value": "supplier_cd"
}, {
"label": "客户名称",
"value": "supplier_nm"
}, {
"label": "地址",
"value": "address"
}, {
"label": "银行账号",
"value": "bank_account"
}, ],
supplierIdcolumnOptions: [{
"label": "供应商编码",
"value": "supplier_code"
}, {
"label": "供应商名称",
"value": "supplier_name"
}],
salesIdcolumnOptions: [{
"label": "合同编码",
"value": "contract_code"
}, {
"label": "合同名称",
"value": "contract_name"
}, {
"label": "合同类型",
"value": "contract_type"
}, {
"label": "供应商/客户名称",
"value": "name"
}, ],
vehicleIdcolumnOptions: [{
"label": "车牌号",
"value": "ticketno"
}, {
"label": "司机",
"value": "drivername"
}, {
"label": "手机号",
"value": "contact"
}, ],
unitOptions: [{
"fullName": "吨",
"id": "0"
}, {
"fullName": "千克",
"id": "1"
}],
transportTypeOptions: [{
"fullName": "汽运",
"id": "0"
}, {
"fullName": "船运",
"id": "1"
}, {
"fullName": "火车",
"id": "2"
}],
advanceOptions: [{
"fullName": "否",
"id": "0"
}, {
"fullName": "是",
"id": "1"
}],
businessIdcolumnOptions: [{
"label": "人员名称",
"value": "F_RealName"
}, {
"label": "人员职位",
"value": "F_FullName"
}, ],
naturalIdcolumnOptions: [{
"label": "业务员2名称",
"value": "name"
}, {
"label": "业务员2手机号",
"value": "contact"
}, {
"label": "业务员2地址",
"value": "adress"
}, ],
}
},
computed: {},
watch: {},
created() {},
mounted() {},
methods: {
unitChange(e){
this.dataForm.unit = e;
},
transportTypeChange(e){
this.dataForm.transportType = e;
},
advanceChange(e){
this.dataForm.advance = e;
},
customerSelect(e, d) {
const query = {
code: d.id
}
request({
url: '/api/example/ContractFile/getListByCustomer',
method: 'post',
data: query
}).then((res) => {
if(res.data.length > 0){
// type
this.dataForm.salesId = res.data[0].id
this.dataForm.salesName = res.data[0].contractName
}
})
},
customerSelect2(a, b) {
this.dataForm.supplierId = b.code;
debugger
},
handleAvatarSuccess(res, file) {
this.imageUrl = URL.createObjectURL(file.raw);
this.dataForm.customerId = res.data.customerId;
this.dataForm.customerName = res.data.customerName;
this.dataForm.salesId = res.data.salesId;
this.dataForm.salesName = res.data.salesName;
this.dataForm.vehicleId = res.data.vehicleId;
this.dataForm.poundDate = res.data.poundDate;
this.dataForm.poundlistNo = res.data.poundlistNo;
this.dataForm.tareWeight = res.data.tareWeight;
this.dataForm.grossWeight = res.data.grossWeight;
this.dataForm.buckleWeight = res.data.buckleWeight;
this.dataForm.netWeight = res.data.netWeight;
this.dataForm.vehiclePictures = JSON.parse(res.data.vehiclePictures);
},
changePicture(a, b) {
this.dataForm.vehiclePictures = JSON.parse(b.vehiclephotos);
},
continueUpload() {
var tareWeight = this.dataForm.tareWeight;//
var grossWeight = this.dataForm.grossWeight;//
var buckleWeight = this.dataForm.buckleWeight;//
var netWeight = this.dataForm.netWeight;//
if(grossWeight < tareWeight + buckleWeight + netWeight){
this.$message({
message: '毛重不得小于皮重+扣重+净重',
type: 'success',
duration: 1000
})
return
}
if(buckleWeight >= netWeight){
this.$message({
message: '扣重不得大于净重',
type: 'success',
duration: 1000
})
return
}
if(buckleWeight >= grossWeight){
this.$message({
message: '扣重不得大于毛重',
type: 'success',
duration: 1000
})
return
}
this.$refs['elForm'].validate((valid) => {
if (valid) {
this.request3()
}
})
},
// poundAI(){
// let formData = new FormData();
// let file = this.dataForm.poundPictures
// formData.append('file',file);
// request({
// url: '/api/tradeupload/Tradeupload/poundai',
// method: 'post',
// data: formData
// }).then(res => {
// this.dataInfo(res.data)
// this.loading = false
// });
// },
clearData(data) {
for (let key in data) {
if (data[key] instanceof Array) {
data[key] = [];
} else if (data[key] instanceof Object) {
this.clearData(data[key]);
} else {
data[key] = "";
}
}
},
init(id, isDetail) {
this.dataForm.id = id || 0;
this.visible = true;
this.isDetail = isDetail || false;
this.$nextTick(() => {
this.$refs['elForm'].resetFields();
if (this.dataForm.id) {
this.loading = true
request({
url: '/api/tradeupload/Tradeupload/' + this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
});
} else {
this.clearData(this.dataForm)
this.dataForm.poundDate = new Date();
this.dataForm.businessId = this.$store.state.user.userInfo.userId;
this.dataForm.businessName = this.$store.state.user.userInfo.userName;
}
});
this.$store.commit('generator/UPDATE_RELATION_DATA', {})
},
//
dataFormSubmit() {
var tareWeight = this.dataForm.tareWeight;//
var grossWeight = this.dataForm.grossWeight;//
var buckleWeight = this.dataForm.buckleWeight;//
var netWeight = this.dataForm.netWeight;//
this.dataForm.isExamine = '1';
this.dataForm.unit = this.dataForm.unit ? this.dataForm.unit : 0;
this.dataForm.transportType = this.dataForm.transportType ? this.dataForm.transportType : 0;
this.dataForm.advance = this.dataForm.advance ? this.dataForm.advance : 0;
if(grossWeight < tareWeight + buckleWeight + netWeight){
this.$message({
message: '毛重不得小于皮重+扣重+净重',
type: 'success',
duration: 1000
})
return
}
if(buckleWeight >= netWeight){
this.$message({
message: '扣重不得大于净重',
type: 'success',
duration: 1000
})
return
}
if(buckleWeight >= grossWeight){
this.$message({
message: '扣重不得大于毛重',
type: 'success',
duration: 1000
})
return
}
this.$refs['elForm'].validate((valid) => {
if (valid) {
this.request2()
}
})
},
request2() {
var _data = this.dataList()
debugger
if (!this.dataForm.id) {
request({
url: '/api/tradeupload/Tradeupload',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
} else {
request({
url: '/api/tradeupload/Tradeupload/' + this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
}
},
request3() {
var _data = this.dataList()
if (!this.dataForm.id) {
request({
url: '/api/tradeupload/Tradeupload',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
})
})
} else {
request({
url: '/api/tradeupload/Tradeupload/' + this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
})
})
}
this.dataForm.vehicleId = null;
this.dataForm.vehiclePictures = null;
this.dataForm.poundDate = null;
this.dataForm.poundlistNo = null;
this.dataForm.tareWeight = null;
this.dataForm.grossWeight = null;
this.dataForm.buckleWeight = null;
this.dataForm.netWeight = null;
},
request() {
var _data = this.dataList()
if (!this.dataForm.id) {
request({
url: '/api/tradeupload/Tradeupload',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
} else {
request({
url: '/api/tradeupload/Tradeupload/' + this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
}
},
dataList() {
var _data = JSON.parse(JSON.stringify(this.dataForm));
_data.poundPictures = JSON.stringify(_data.poundPictures)
_data.vehiclePictures = JSON.stringify(_data.vehiclePictures)
_data.originPlace = JSON.stringify(_data.originPlace)
return _data;
},
dataInfo(dataAll) {
let _dataAll = dataAll
_dataAll.poundPictures = JSON.parse(_dataAll.poundPictures)
_dataAll.vehiclePictures = JSON.parse(_dataAll.vehiclePictures)
if(_dataAll.originPlace.length > 0){
_dataAll.originPlace = JSON.parse(_dataAll.originPlace)
}else{
_dataAll.originPlace = []
}
this.dataForm = _dataAll
},
},
}
</script>
<style>
.avatar-uploader .el-upload {
border: 1px dashed #d9d9d9;
border-radius: 6px;
cursor: pointer;
position: relative;
overflow: hidden;
}
.avatar-uploader .el-upload:hover {
border-color: #409EFF;
}
.avatar-uploader-icon {
font-size: 28px;
color: #8c939d;
width: 120px;
height: 120px;
line-height: 120px;
text-align: center;
}
.avatar {
width: 120px;
height: 120px;
display: block;
}
</style>

@ -112,7 +112,7 @@
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
@selection-change="handleSelectionChange" border show-summary :summary-method="getSummaries">
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="vehicleName" label="车号" fixed="left" sortable width="120" align="center" />
<el-table-column prop="purchaseStatus" label="采购状态" sortable width="100" align="center" >
@ -126,20 +126,19 @@
</template>
</el-table-column>
<el-table-column prop="materialName" label="物料名称" sortable width="150" align="center" />
<el-table-column prop="settlement" sortable label="结算重量" width="100" align="center" />
<el-table-column prop="purchasePrice" sortable label="采购单价" width="100" align="center" />
<el-table-column prop="salesPrice" sortable label="销售价格" width="100" align="center" />
<el-table-column prop="collectPrice" sortable label="收货价格" width="100" align="center" />
<el-table-column prop="grossWeight" sortable label="毛重" width="100" align="center" />
<el-table-column prop="tareWeight" sortable label="皮重" width="100" align="center" />
<el-table-column prop="netWeight" sortable label="净重" width="100" align="center" />
<el-table-column prop="buckleWeight" sortable label="扣重" width="100" align="center" />
<el-table-column prop="unit" label="单位" sortable width="100" align="center" >
<template slot-scope="scope">
{{ scope.row.unit | dynamicText(unitOptions) }}
</template>
</el-table-column>
<el-table-column prop="grossWeight" sortable label="毛重" width="100" align="center" />
<el-table-column prop="tareWeight" sortable label="皮重" width="100" align="center" />
<el-table-column prop="netWeight" sortable label="净重" width="100" align="center" />
<el-table-column prop="buckleWeight" sortable label="扣重" width="100" align="center" />
<el-table-column prop="settlement" sortable label="结算重量" width="100" align="center" />
<el-table-column prop="purchasePrice" sortable label="采购单价" width="100" align="center" />
<el-table-column prop="salesPrice" sortable label="销售价格" width="100" align="center" />
<el-table-column prop="collectPrice" sortable label="收货价格" width="100" align="center" />
<el-table-column prop="poundlistNo" label="磅单号" width="200" align="center" sortable />
<el-table-column prop="customerName" label="客户名称" sortable width="150" align="center" />
<el-table-column prop="salesName" label="销售合同" sortable width="150" align="center" />
@ -151,16 +150,12 @@
{{ scope.row.advance | dynamicText(advanceOptions) }}
</template>
</el-table-column>
<el-table-column prop="creatorTime" label="创建时间" width="200" align="center" sortable
/>
<el-table-column prop="inputDate" sortable label="进项票日期" width="150" align="center" />
<el-table-column prop="outputDate" sortable label="销项票日期" width="150" align="center" />
<el-table-column prop="payDate" sortable label="付款日期" width="150" align="center" />
<el-table-column prop="paymentDate" sortable label="回款日期" width="150" align="center" />
<el-table-column prop="poundDate" sortable label="磅单日期" width="150" align="center" />
<el-table-column prop="inputDateStr" sortable label="进项票日期" width="150" align="center" />
<el-table-column prop="outputDateStr" sortable label="销项票日期" width="150" align="center" />
<el-table-column prop="payDateStr" sortable label="付款日期" width="150" align="center" />
<el-table-column prop="paymentDateStr" sortable label="回款日期" width="150" align="center" />
<el-table-column prop="poundDateStr" sortable label="磅单日期" width="150" align="center" />
<el-table-column prop="creatorTimeStr" sortable label="创建日期" width="150" align="center" />
<el-table-column prop="businessName" sortable label="业务员" width="150" align="center" />
<el-table-column label="是否开进项票" width="120" sortable prop="isInvoicing" align="center" >
<template slot-scope="scope">
@ -213,14 +208,18 @@
</span>
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="100" align="center">
<el-table-column label="操作" fixed="right" width="150" align="center">
<template slot-scope="scope">
<el-button type="text" @click="addOrUpdateHandle(scope.row.id)">
<el-button type="text" @click="addOrUpdateHandle(scope.row)">
</el-button>
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row)">
</el-button>
<el-button type="text" @click="goDetail(scope.row.id)">
</el-button>
<el-button type="text" @click="addOvheicle(scope.row.id)">
</el-button>
</template>
</el-table-column>
</JNPF-table>
@ -230,8 +229,8 @@
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh" />
<JNPF-Form2 v-if="formVisible2" ref="JNPFForm2" @refresh="refresh2" />
<JNPF-Form3 v-if="formVisible3" ref="JNPFForm3" @refresh="refresh3" />
<JNPF-Form4 v-if="formVisible" ref="JNPFForm4" @refresh="refresh" />
<JNPF-Form4 v-if="formVisible4" ref="JNPFForm4" @refresh="refresh4" />
<JNPF-Form6 v-if="formVisible6" ref="JNPFForm6" @refresh="refresh6" />
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download" />
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false" />
</div>
@ -244,8 +243,9 @@
} from '@/api/systemData/dictionary'
import JNPFForm from './Form'
import JNPFForm2 from './PurchaseOrderForm'
import JNPFForm3 from './PurchaseOrderForm'
import JNPFForm4 from './salesForm'
import JNPFForm6 from './VechicleForm'
import ExportBox from './ExportBox'
import {
getDataInterfaceRes
@ -256,8 +256,8 @@
components: {
JNPFForm,
JNPFForm2,
JNPFForm3,
JNPFForm4,
JNPFForm6,
ExportBox,
Detail
},
@ -287,6 +287,8 @@
formVisible: false,
formVisible2: false,
formVisible3: false,
formVisible4: false,
formVisible6: false,
exportBoxVisible: false,
columnList: [{
prop: 'licenseNo',
@ -472,6 +474,31 @@
this.initData()
},
methods: {
getSummaries(param) {
const { columns, data } = param;
const sums = [];
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '合计';
return;
}
const values = data.map(item => Number(item[column.property]));
if (!values.every(value => isNaN(value)) && (index === 7 || index === 8 || index === 9 || index === 10|| index === 11)) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr);
if (!isNaN(value)) {
return prev + curr;
} else {
return prev;
}
}, 0);
} else {
sums[index] = '';
}
});
return sums;
},
goDetail(id) {
this.detailVisible = true
this.$nextTick(() => {
@ -501,16 +528,18 @@
}).then(res => {
var _list = [];
for (let i = 0; i < res.data.list.length; i++) {
res.data.list[i].inputDate = res.data.list[i].inputDate ? res.data.list[i].inputDate.substring(0,
res.data.list[i].inputDateStr = res.data.list[i].inputDate ? res.data.list[i].inputDate.substring(0,
10) : '';
res.data.list[i].outputDate = res.data.list[i].outputDate ? res.data.list[i].outputDate
res.data.list[i].outputDateStr = res.data.list[i].outputDate ? res.data.list[i].outputDate
.substring(0, 10) : '';
res.data.list[i].payDate = res.data.list[i].payDate ? res.data.list[i].payDate
res.data.list[i].payDateStr = res.data.list[i].payDate ? res.data.list[i].payDate
.substring(0, 10) : '';
res.data.list[i].paymentDate = res.data.list[i].paymentDate ? res.data.list[i].paymentDate
res.data.list[i].paymentDateStr = res.data.list[i].paymentDate ? res.data.list[i].paymentDate
.substring(0, 10) : '';
res.data.list[i].poundDate = res.data.list[i].poundDate ? res.data.list[i].poundDate
res.data.list[i].poundDateStr = res.data.list[i].poundDate ? res.data.list[i].poundDate
.substring(0, 10) : '';
res.data.list[i].creatorTimeStr = res.data.list[i].creatorTime ? res.data.list[i].creatorTime
.substring(0, 10) : '';
let _data = res.data.list[i];
_list.push(_data)
}
@ -623,7 +652,7 @@
}
if (list.length>0) {
// this.list = _list
this.formVisible = true
this.formVisible4 = true
this.$nextTick(() => {
this.$refs.JNPFForm4.init(list)
})
@ -684,12 +713,29 @@
})
}).catch(() => {})
},
addOrUpdateHandle(id, isDetail) {
addOrUpdateHandle(row, isDetail) {
var id = undefined;
if(row.isInvoicing == '1'){
var msg = '开进项票';
this.$message({
type: 'error',
message: '已' + msg +'无法删除',
duration: 1500
});
return
}
this.formVisible = true
this.$nextTick(() => {
this.$refs.JNPFForm.init(id, isDetail)
})
},
addOvheicle(id,isDetail){
this.formVisible6 = true
this.$nextTick(() => {
this.$refs.JNPFForm6.init(id, isDetail)
})
},
exportData() {
this.exportBoxVisible = true
this.$nextTick(() => {
@ -734,6 +780,14 @@
refresh3(isrRefresh) {
this.formVisible3 = false
if (isrRefresh) this.reset()
},
refresh4(isrRefresh) {
this.formVisible4 = false
if (isrRefresh) this.reset()
},
refresh4(isrRefresh) {
this.formVisible6 = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {

@ -43,8 +43,9 @@
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="documentNo" label="单据编号" width="200" align="center"sortable fixed="left" />
<el-table-column prop="jg_purchaseorder.contractName" label="合同名称" width="200" align="center"sortable/>
<el-table-column prop="jg_purchaseorder.supplierName" label="供应商名称" width="200" align="center"sortable/>
<el-table-column prop="purchaseorderdocumentno" label="来源单号" width="200" align="center"sortable/>
<el-table-column prop="contractName" label="合同名称" width="200" align="center"sortable/>
<el-table-column prop="supplierName" label="供应商名称" width="200" align="center"sortable/>
<el-table-column prop="refundAmount" label="退货金额" width="120" align="center"sortable/>
<el-table-column prop="actualAmount" label="实退金额" width="120" align="center"sortable/>
@ -129,13 +130,17 @@
columnList: [{
prop: 'documentNo',
label: '单据编号'
},
{
prop: 'purchaseorderdocumentno',
label: '来源单号'
},
{
prop: 'jg_purchaseorder.contractName',
prop: 'contractName',
label: '合同名称'
},
{
prop: 'jg_purchaseorder.supplierName',
prop: 'supplierName',
label: '供应商名称'
},
{

@ -215,7 +215,7 @@
</el-input>
</template>
</el-table-column>
<el-table-column prop="invoiceQuantity" label="发票数量" width="150">
<el-table-column prop="invoiceQuantity" label="发票数量" width="200">
<template slot-scope="scope">
<el-input-number v-model="scope.row.invoiceQuantity" placeholder="数字文本" :step="1" :precision="6" :style='{"width":"100%"}' @change="invoiceQuantityChange(scope.row)">
</el-input-number>

@ -84,7 +84,7 @@
{{ scope.row.status | dynamicText(statusOptions) }}
</template>
</el-table-column>
<el-table-column prop="erpNo" label="ERP订单号" sortable width="200" align="center" />
<!-- <el-table-column prop="erpNo" label="ERP订单号" sortable width="200" align="center" /> -->
<el-table-column prop="contractName" label="合同" sortable width="250" align="center" />
<el-table-column prop="supplierName" label="供应商" sortable width="200" align="center" />
<el-table-column prop="amount" label="金额" sortable width="150" align="center" />
@ -522,8 +522,10 @@
})
return
}
var supplierIdArr = [];
var statusFlag = true;
for(var i=0;i<this.multipleSelectionItem.length;i++){
supplierIdArr.push(this.multipleSelectionItem[i].supplierId);
if(this.multipleSelectionItem[i].status != '2'){
statusFlag = false;
}
@ -536,10 +538,14 @@
})
return
}
for(var i=0;i<this.multipleSelectionItem.length;i++){
if(this.multipleSelectionItem[i].status != '2'){
statusFlag = false;
}
var newSupplierIdArr = [...new Set(supplierIdArr)]; //Set
if(newSupplierIdArr.length != 1){
this.$message({
type: 'error',
message: '所选数据供应商需一致',
duration: 1000
});
return
}
const ids = this.multipleSelection.join()
request({

@ -70,7 +70,7 @@
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="documentno" label="单据编号" sortable width="200" align="center" fixed="left" />
<el-table-column prop="supplierId" label="供应商" sortable width="220" align="center" fixed="left" />
<el-table-column prop="supplier" label="供应商" sortable width="220" align="center" fixed="left" />
<el-table-column prop="receiptamount" label="入库金额" sortable width="120" align="center" />
<el-table-column prop="receiptnum" label="入库数量" sortable width="120" align="center" />
<el-table-column prop="currency" label="币别" sortable width="80" align="center">
@ -79,7 +79,7 @@
</template>
</el-table-column>
<el-table-column prop="warehousingdate" sortable label="入库日期" width="120" align="center" />
<el-table-column prop="souceno" sortable label="来源单号" width="200" align="center" />
<el-table-column prop="purchaseorderSouceno" sortable label="来源单号" width="200" align="center" />
<el-table-column prop="type" sortable label="业务类型" width="120" align="center">
<template slot-scope="scope">
{{ scope.row.type | dynamicText(typeOptions) }}
@ -162,7 +162,7 @@
label: '单据编号'
},
{
prop: 'suppliername',
prop: 'supplier',
label: '供应商名称'
},
{
@ -182,7 +182,7 @@
label: '入库日期'
},
{
prop: 'souceno',
prop: 'purchaseorderSouceno',
label: '来源单号'
},
{

@ -54,13 +54,13 @@
<p>{{dataForm.remark}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-col :span="8" >
<el-form-item label="出库日期"
prop="issueDate" >
<p>{{jnpf.dateFormat(dataForm.issueDate)}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-col :span="8" >
<el-form-item label="单据状态"
prop="status" >
<p>{{ dataForm.status | dynamicText(statusOptions) }} </p>

@ -88,14 +88,14 @@
</div>
<el-table :data="dataForm.saleback_item0List" size='mini' >
<el-table-column type="index" width="50" label="序号" align="center" />
<el-table-column prop="vehicleId" label="车牌号">
<el-table-column prop="vehicleName" label="车牌号">
<template slot-scope="scope">
<p>{{scope.row.vehicleId}}</p>
<p>{{scope.row.vehicleName}}</p>
</template>
</el-table-column>
<el-table-column prop="materialId" label="物料名称">
<el-table-column prop="materialName" label="物料名称">
<template slot-scope="scope">
<p>{{scope.row.materialId}}</p>
<p>{{scope.row.materialName}}</p>
</template>
</el-table-column>
<el-table-column prop="settlement" label="结算重量 ">
@ -108,9 +108,9 @@
<p>{{ scope.row.unit | dynamicText(unitOptions) }}</p>
</template>
</el-table-column>
<el-table-column prop="price" label="采购单价">
<el-table-column prop="salesPrice" label="销售单价">
<template slot-scope="scope">
<p>{{scope.row.price}}</p>
<p>{{scope.row.salesPrice}}</p>
</template>
</el-table-column>
<el-table-column prop="rate" label="税率">
@ -128,9 +128,9 @@
<p>{{scope.row.notAmount}}</p>
</template>
</el-table-column>
<el-table-column prop="businessId" label="业务员">
<el-table-column prop="businessName" label="业务员">
<template slot-scope="scope">
<p>{{scope.row.businessId}}</p>
<p>{{scope.row.businessName}}</p>
</template>
</el-table-column>
<el-table-column prop="pountType" label="磅单类型 ">
@ -220,10 +220,15 @@
if(this.dataForm.id){
this.loading = true
request({
url: '/api/saleback/Saleback/detail/'+this.dataForm.id,
url: '/api/saleback/Saleback/detail2/'+this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
for (let i = 0;i<res.data.saleback_item0List.length;i++){
this.dataForm.saleback_item0List[i].amount = res.data.saleback_item0List[i].price
this.dataForm.saleback_item0List[i].price = res.data.saleback_item0List[i].salesPrice
this.dataForm.saleback_item0List[i].notAmount = this.dataForm.saleback_item0List[i].amount - res.data.saleback_item0List[i].noPrice
}
this.loading = false
})
}

@ -35,14 +35,14 @@
</el-col>
<el-col :span="8">
<el-form-item label="退款金额" prop="refundAmount" >
<el-input v-model="dataForm.refundAmount" readonly clearable :style='{"width":"100%"}' :disabled="true">
<el-input v-model="dataForm.refundAmount" readonly clearable :style='{"width":"100%"}' >
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="退货数量" prop="refundNum" >
<el-input v-model="dataForm.refundNum" readonly clearable :style='{"width":"100%"}' :disabled="true">
<el-input v-model="dataForm.refundNum" readonly clearable :style='{"width":"100%"}' >
</el-input>
</el-form-item>
@ -260,7 +260,7 @@
{"label":"税额","value":"no_price"},
{"label":"业务员","value":"business_id"},
{"label":"磅单类型","value":"pound_type"},],
jg_salesback_item0materialIdcolumnOptions:[ {"label":"物料编码","value":"item_code"}, {"label":"物料名称","value":"item_name"}, {"label":"单位","value":"primary_unit_of_measure"}, {"label":"默认入库区","value":"in_area"}, {"label":"默认出库区","value":"out_area"},],
unitOptions: [{
"fullName": "吨",
"id": "0"
@ -327,10 +327,14 @@
return sums;
},
popupSelectChange2(a, b){
var sumPrice = 0;
var sumNum = 0;
var excludeFields = [];
for (let i = 0; i < this.dataForm.saleback_item0List.length; i++) {
excludeFields.push(this.dataForm.saleback_item0List[i].vehicleId);
if(a == this.dataForm.saleback_item0List[i].vehicleId){
debugger
this.dataForm.saleback_item0List[i].vehicleId = b.vehicle_id;
this.dataForm.saleback_item0List[i].materialId = b.material_id;
this.dataForm.saleback_item0List[i].settlement = b.settlement;
this.dataForm.saleback_item0List[i].unit = b.unit;
@ -345,9 +349,12 @@
this.dataForm.saleback_item0List[i].notAmount = this.dataForm.saleback_item0List[i].amount*item.fullName/100
}
})
sumNum = sumNum + parseFloat(b.settlement);
sumPrice = sumPrice + parseFloat(this.dataForm.saleback_item0List[i].amount);
}
}
let price =
this.dataForm.refundNum = sumNum;
this.dataForm.refundAmount = sumPrice;
this.excludeFields = excludeFields;
},
popupSelectChange(e,d){
@ -396,8 +403,12 @@
url: '/api/saleback/Saleback/' + this.dataForm.id,
method: 'get'
}).then(res => {
debugger
this.dataInfo(res.data)
for (let i = 0;i<res.data.saleback_item0List.length;i++){
this.dataForm.saleback_item0List[i].amount = res.data.saleback_item0List[i].price
this.dataForm.saleback_item0List[i].price = res.data.saleback_item0List[i].salesPrice
this.dataForm.saleback_item0List[i].notAmount = this.dataForm.saleback_item0List[i].amount - res.data.saleback_item0List[i].noPrice
}
this.loading = false
});
} else {
@ -480,14 +491,12 @@
},
dataInfo(dataAll) {
let _dataAll = dataAll
debugger
// _dataAll.jnpf_jg_salesorder_jnpf_contractName = _dataAll.jg_salesorder.contractName
// _dataAll.jnpf_jg_salesorder_jnpf_costomerName = _dataAll.jg_salesorder.costomerName
for (let i = 0; i < _dataAll.saleback_item0List.length; i++) {
var _list = _dataAll.saleback_item0List[i];
}
this.dataForm = _dataAll
debugger
},
},
}

@ -655,7 +655,7 @@
salesbacksoitemList:[],
paymentsoitemList:[],
},
activemtmitd:'1',
activemtmitd:'0',
rules:
{
contractCode: [

@ -58,8 +58,8 @@
</el-button>
<el-button type="text" icon="el-icon-delete" @click="invoicesEntry()" >发票录入
</el-button>
<!-- <el-button type="text" icon="el-icon-delete" @click="collection()" >回款-->
<!-- </el-button>-->
<el-button type="text" icon="el-icon-delete" @click="collection()" >回款
</el-button>
<el-button type="text" icon="el-icon-check" @click="archive()" >归档
</el-button>
<el-button type="text" icon="el-icon-check" @click="materialBack()" >退货
@ -128,10 +128,10 @@ width="150" >
</div>
</div>
<JNPF-Form v-if="formVisible" ref="JNPFForm" @refresh="refresh"/>
<JNPF-Form2 v-if="formVisible" ref="JNPFForm2" @refresh="refresh"/>
<JNPF-Form3 v-if="formVisible" ref="JNPFForm3" @refresh="refresh"/>
<JNPF-Form4 v-if="formVisible" ref="JNPFForm4" @refresh="refresh"/>
<JNPF-Form5 v-if="formVisible" ref="JNPFForm5" @refresh="refresh"/>
<JNPF-Form2 v-if="formVisible2" ref="JNPFForm2" @refresh="refresh2"/>
<JNPF-Form3 v-if="formVisible3" ref="JNPFForm3" @refresh="refresh3"/>
<JNPF-Form4 v-if="formVisible4" ref="JNPFForm4" @refresh="refresh4"/>
<JNPF-Form5 v-if="formVisible5" ref="JNPFForm5" @refresh="refresh5"/>
<ExportBox v-if="exportBoxVisible" ref="ExportBox" @download="download"/>
<Detail v-if="detailVisible" ref="Detail" @refresh="detailVisible=false"/>
</div>
@ -173,6 +173,10 @@ width="150" >
sidx: "",
},
formVisible: false,
formVisible2: false,
formVisible3: false,
formVisible4: false,
formVisible5: false,
exportBoxVisible: false,
columnList: [
{prop: 'documentNo', label: '单据编号'},
@ -227,7 +231,7 @@ width="150" >
debugger
}
if (list.length>0) {
this.formVisible = true
this.formVisible3 = true
this.$nextTick(() => {
this.$refs.JNPFForm3.init(list)
})
@ -263,7 +267,7 @@ width="150" >
list.push(_data)
}
if (list.length > 0) {
this.formVisible = true
this.formVisible2 = true
this.$nextTick(() => {
this.$refs.JNPFForm2.init(list)
})
@ -280,7 +284,7 @@ width="150" >
list2 = res.data
debugger
if (list2 != null){
this.formVisible = true
this.formVisible2 = true
this.$nextTick(() => {
this.$refs.JNPFForm2.init2(list2)
debugger
@ -318,7 +322,7 @@ width="150" >
debugger
}
if (list.length > 0) {
this.formVisible = true
this.formVisible5 = true
this.$nextTick(() => {
this.$refs.JNPFForm5.init(list)
})
@ -377,7 +381,7 @@ width="150" >
debugger
}
if (list.length > 0) {
this.formVisible = true
this.formVisible4 = true
this.$nextTick(() => {
this.$refs.JNPFForm4.init(list)
})
@ -525,6 +529,22 @@ width="150" >
this.formVisible = false
if (isrRefresh) this.reset()
},
refresh2(isrRefresh) {
this.formVisible2 = false
if (isrRefresh) this.reset()
},
refresh3(isrRefresh) {
this.formVisible3 = false
if (isrRefresh) this.reset()
},
refresh4(isrRefresh) {
this.formVisible4 = false
if (isrRefresh) this.reset()
},
refresh5(isrRefresh) {
this.formVisible5 = false
if (isrRefresh) this.reset()
},
reset() {
for (let key in this.query) {
this.query[key] = undefined

@ -270,7 +270,7 @@
{"label":"税额","value":"no_price"},
{"label":"业务员","value":"business_id"},
{"label":"磅单类型","value":"pound_type"},],
jg_salesback_item0materialIdcolumnOptions:[ {"label":"物料编码","value":"item_code"}, {"label":"物料名称","value":"item_name"}, {"label":"单位","value":"primary_unit_of_measure"}, {"label":"默认入库区","value":"in_area"}, {"label":"默认出库区","value":"out_area"},],
unitOptions: [{
"fullName": "吨",
"id": "0"
@ -331,11 +331,12 @@
return sums;
},
popupSelectChange2(a, b){
debugger
var excludeFields = [];
for (let i = 0; i < this.dataForm.saleback_item0List.length; i++) {
excludeFields.push(this.dataForm.saleback_item0List[i].vehicleId);
if(a == this.dataForm.saleback_item0List[i].vehicleId){
if(a == this.dataForm.saleback_item0List[i].id){
debugger
this.dataForm.saleback_item0List[i].vehicleId = b.vehicle_id;
this.dataForm.saleback_item0List[i].materialId = b.material_id;
this.dataForm.saleback_item0List[i].settlement = b.settlement;
this.dataForm.saleback_item0List[i].unit = b.unit;

@ -7,14 +7,14 @@
<el-col :span="12">
<el-form-item label="磅单上传" prop="poundPictures">
<JNPF-UploadImg v-model="dataForm.poundPictures" :fileSize="500" sizeUnit="MB" :limit="1" :disabled="true">
</JNPF-UploadImg>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="车辆图片" prop="vehiclePictures">
<JNPF-UploadImg v-model="dataForm.vehiclePictures" :fileSize="500" sizeUnit="MB" :limit="9">
</JNPF-UploadImg>
</el-form-item>
</el-col>
@ -60,27 +60,27 @@
</el-col>
<el-col :span="6">
<el-form-item label="销售价格" prop="salesPrice">
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}' @change="grossWeightChange" :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}' @change="grossWeightChange"></el-input-number>
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="扣重" prop="buckleWeight">
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="净重" prop="netWeight">
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -125,7 +125,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="运费" prop="transportPrice">
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -135,8 +135,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务员" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员" clearable field="businessId"
<el-form-item label="业务员1" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员1" clearable field="businessId"
interfaceId="ebcc44be142e43b795c0d769abd6d25a" :columnOptions="businessIdcolumnOptions"
propsValue="F_Id" relationField="F_RealName" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
hasPage :pageSize="20" :bissId="dataForm.businessId">
@ -145,8 +145,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="自然人" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择自然人" clearable field="naturalId"
<el-form-item label="业务员2" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择业务员2" clearable field="naturalId"
interfaceId="395933800510599301" :columnOptions="naturalIdcolumnOptions" propsValue="id"
relationField="name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage :pageSize="20">
@ -390,13 +390,13 @@
"value": "positionName"
}],
naturalIdcolumnOptions: [{
"label": "自然人名称",
"label": "业务员2名称",
"value": "name"
}, {
"label": "自然人手机号",
"label": "业务员2手机号",
"value": "contact"
}, {
"label": "自然人地址",
"label": "业务员2地址",
"value": "adress"
}, ],

@ -60,27 +60,27 @@
</el-col>
<el-col :span="6">
<el-form-item label="销售价格" prop="salesPrice">
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}' @change="grossWeightChange" :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}' @change="grossWeightChange"></el-input-number>
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="扣重" prop="buckleWeight">
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="净重" prop="netWeight">
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -125,7 +125,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="运费" prop="transportPrice">
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
@ -137,8 +137,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务员" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员" clearable field="businessId"
<el-form-item label="业务员1" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员1" clearable field="businessId"
interfaceId="ebcc44be142e43b795c0d769abd6d25a" :columnOptions="businessIdcolumnOptions"
propsValue="F_Id" relationField="F_RealName" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
hasPage :pageSize="20" :bissId="dataForm.businessId">
@ -147,8 +147,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="自然人" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择自然人" clearable field="naturalId"
<el-form-item label="业务员2" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择业务员2" clearable field="naturalId"
interfaceId="395933800510599301" :columnOptions="naturalIdcolumnOptions" propsValue="id"
relationField="name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage :pageSize="20">
@ -256,11 +256,11 @@
message: '请选择车辆',
trigger: 'change'
}, ],
vehiclePictures: [{
required: true,
message: '请至少选择一个',
trigger: 'click'
}, ],
// vehiclePictures: [{
// required: true,
// message: '',
// trigger: 'click'
// }, ],
poundDate: [{
required: true,
message: '请选择',
@ -389,13 +389,13 @@
"value": "positionName"
}],
naturalIdcolumnOptions: [{
"label": "自然人名称",
"label": "业务员2名称",
"value": "name"
}, {
"label": "自然人手机号",
"label": "业务员2手机号",
"value": "contact"
}, {
"label": "自然人地址",
"label": "业务员2地址",
"value": "adress"
}, ],
@ -556,6 +556,9 @@
});
} else {
this.clearData(this.dataForm)
this.dataForm.businessId = this.$store.state.user.userInfo.userId;
this.dataForm.businessName = this.$store.state.user.userInfo.userName;
this.dataForm.poundDate = new Date();
}
});
this.$store.commit('generator/UPDATE_RELATION_DATA', {})
@ -572,7 +575,7 @@
if(grossWeight < tareWeight + buckleWeight + netWeight){
this.$message({
message: '毛重不得小于皮重+扣重+净重',
type: 'success',
type: 'error',
duration: 1000
})
return
@ -580,7 +583,7 @@
if(buckleWeight >= netWeight){
this.$message({
message: '扣重不得大于净重',
type: 'success',
type: 'error',
duration: 1000
})
return
@ -588,7 +591,7 @@
if(buckleWeight >= grossWeight){
this.$message({
message: '扣重不得大于毛重',
type: 'success',
type: 'error',
duration: 1000
})
return
@ -596,7 +599,7 @@
if(netWeight <= 0){
this.$message({
message: '净重必须大于0',
type: 'success',
type: 'error',
duration: 1000
})
return

@ -70,32 +70,32 @@
</el-col>
<el-col :span="6">
<el-form-item label="采购价格" prop="purchasePrice">
<el-input-number v-model="dataForm.purchasePrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.purchasePrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="销售价格" prop="salesPrice">
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="毛重" prop="grossWeight">
<el-input-number v-model="dataForm.grossWeight" :style='{"width":"100%"}'></el-input-number>
<el-form-item label="皮重" prop="tareWeight">
<el-input-number v-model="dataForm.tareWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="扣重" prop="buckleWeight">
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.buckleWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="净重" prop="netWeight">
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.netWeight" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -152,7 +152,7 @@
</el-col>
<el-col :span="6">
<el-form-item label="运费" prop="transportPrice">
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}'></el-input-number>
<el-input-number v-model="dataForm.transportPrice" :style='{"width":"100%"}' :precision="6"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
@ -162,8 +162,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="业务员" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员" clearable field="businessId"
<el-form-item label="业务员1" prop="businessId">
<popupSelect v-model="dataForm.businessId" placeholder="请选择业务员1" clearable field="businessId"
interfaceId="ebcc44be142e43b795c0d769abd6d25a" :columnOptions="businessIdcolumnOptions"
propsValue="F_Id" relationField="F_RealName" popupType="dialog" popupTitle="选择数据" popupWidth="800px"
hasPage :pageSize="20" :bissId="dataForm.businessId">
@ -172,8 +172,8 @@
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="自然人" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择自然人" clearable field="naturalId"
<el-form-item label="业务员2" prop="naturalId">
<popupSelect v-model="dataForm.naturalId" placeholder="请选择业务员2" clearable field="naturalId"
interfaceId="395933800510599301" :columnOptions="naturalIdcolumnOptions" propsValue="id"
relationField="name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage :pageSize="20">
@ -278,11 +278,11 @@
message: '请选择车辆',
trigger: 'change'
}, ],
vehiclePictures: [{
required: true,
message: '请至少选择一个',
trigger: 'click'
}, ],
// vehiclePictures: [{
// required: true,
// message: '',
// trigger: 'click'
// }, ],
poundDate: [{
required: true,
message: '请选择',
@ -420,13 +420,13 @@
"value": "F_FullName"
}, ],
naturalIdcolumnOptions: [{
"label": "自然人名称",
"label": "业务员2名称",
"value": "name"
}, {
"label": "自然人手机号",
"label": "业务员2手机号",
"value": "contact"
}, {
"label": "自然人地址",
"label": "业务员2地址",
"value": "adress"
}, ],

Loading…
Cancel
Save