Merge remote-tracking branch 'origin/main'

product
chuang 2 years ago
commit 1aa1a69623

@ -24,8 +24,8 @@ import org.springframework.stereotype.Component;
//@Intercepts({@Signature(type = Executor.class, method = "update", args = {MappedStatement.class, Object.class})})
public class MybatisPlusMetaObjectHandler implements MetaObjectHandler {
//@Autowired
private static ApplicationContext applicationContext;
//@Autowired
private static ApplicationContext applicationContext;
private UserProvider userProvider;
@Override
@ -38,22 +38,28 @@ private static ApplicationContext applicationContext;
// String tableName = tableInfo.getTableName();
log.info("start insert fill ....");
System.out.println(userInfo);
this.setFieldValByName("creatorUserId", userInfo.getUserId(), metaObject);
this.setFieldValByName("creatorTime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("creatorUserName", userInfo.getUserName(), metaObject);
this.setFieldValByName("creatorUserId", userInfo.getUserId(), metaObject);
this.setFieldValByName("creatoruserid", userInfo.getUserId(), metaObject);
this.setFieldValByName("creatorTime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("creatortime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("creatorUserName", userInfo.getUserName(), metaObject);
this.setFieldValByName("creatorusername", userInfo.getUserName(), metaObject);
this.setFieldValByName("creatoruserid", userInfo.getUserId(), metaObject);
this.setFieldValByName("lastModifyUserId", userInfo.getUserId(), metaObject);
this.setFieldValByName("creatortime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("lastModifyTime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("creatorusername", userInfo.getUserName(), metaObject);
this.setFieldValByName("lastModifyUserName", userInfo.getUserName(), metaObject);
}
this.setFieldValByName("orgnizeId", userInfo.getOrganizeId(), metaObject);
this.setFieldValByName("departmentId", userInfo.getDepartmentId(), metaObject);
}
@Override
public void updateFill(MetaObject metaObject) {
@ -64,37 +70,37 @@ private static ApplicationContext applicationContext;
UserInfo userInfo = userProvider.get();
this.setFieldValByName("lastModifyTime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("lastModifyTime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("lastModifyUserId", userInfo.getUserId(), metaObject);
this.setFieldValByName("lastModifyUserId", userInfo.getUserId(), metaObject);
this.setFieldValByName("lastModifyUserName", userInfo.getUserName(), metaObject);
this.setFieldValByName("lastModifyUserName", userInfo.getUserName(), metaObject);
this.setFieldValByName("deleteTime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("deleteTime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("deleteUserId", userInfo.getUserId(), metaObject);
this.setFieldValByName("deleteUserId", userInfo.getUserId(), metaObject);
this.setFieldValByName("deleteUserName", userInfo.getUserName(), metaObject);
this.setFieldValByName("deleteUserName", userInfo.getUserName(), metaObject);
this.setFieldValByName("lastmodifytime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("lastmodifytime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("lastmodifyuserid", userInfo.getUserId(), metaObject);
this.setFieldValByName("lastmodifyuserid", userInfo.getUserId(), metaObject);
this.setFieldValByName("lastmodifyusername", userInfo.getUserName(), metaObject);
this.setFieldValByName("lastmodifyusername", userInfo.getUserName(), metaObject);
this.setFieldValByName("deletetime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("deletetime", DateUtil.getNowDate(), metaObject);
this.setFieldValByName("deleteuserid", userInfo.getUserId(), metaObject);
this.setFieldValByName("deleteuserid", userInfo.getUserId(), metaObject);
this.setFieldValByName("deleteusername", userInfo.getUserName(), metaObject);
this.setFieldValByName("deleteusername", userInfo.getUserName(), metaObject);
}

@ -51,6 +51,7 @@ import java.util.*;
import jnpf.util.file.UploadUtil;
import jnpf.util.enums.FileTypeEnum;
import org.springframework.web.multipart.MultipartFile;
/**
*
@ -488,7 +489,30 @@ public class ArinvoicesController {
}
/**
* (excel)
*
* @return
*/
@ApiOperation("上传文件")
@PostMapping("/Uploader")
public ActionResult Uploader() {
List<MultipartFile> list = UpUtil.getFileAll();
MultipartFile file = list.get(0);
if (file.getOriginalFilename().endsWith(".xlsx") || file.getOriginalFilename().endsWith(".xls")) {
String filePath = configValueUtil.getTemporaryFilePath();
String fileName = RandomUtil.uuId() + "." + UpUtil.getFileType(file);
fileName = XSSEscape.escape(fileName);
//上传文件
FileUtil.upFile(file, filePath, fileName);
DownloadVO vo = DownloadVO.builder().build();
vo.setName(fileName);
return ActionResult.success(vo);
} else {
return ActionResult.fail("选择文件不符合导入");
}
}

@ -156,7 +156,8 @@ public class ArinvoicesServiceImpl extends ServiceImpl<ArinvoicesMapper, Arinvoi
}
//排序
if(StringUtil.isEmpty(arinvoicesPagination.getSidx())){
arinvoicesQueryWrapper.lambda().orderByDesc(ArinvoicesEntity::getId);
arinvoicesPagination.setSidx("CREATOR_TIME");
arinvoicesPagination.setSort("DESC");
}else{
try {
String sidx = arinvoicesPagination.getSidx();
@ -164,7 +165,8 @@ public class ArinvoicesServiceImpl extends ServiceImpl<ArinvoicesMapper, Arinvoi
Field declaredField = arinvoicesEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
arinvoicesQueryWrapper="asc".equals(arinvoicesPagination.getSort().toLowerCase())?arinvoicesQueryWrapper.orderByAsc(value):arinvoicesQueryWrapper.orderByDesc(value);
arinvoicesPagination.setSidx(value);
// arinvoicesQueryWrapper="asc".equals(arinvoicesPagination.getSort().toLowerCase())?arinvoicesQueryWrapper.orderByAsc(value):arinvoicesQueryWrapper.orderByDesc(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}

@ -127,7 +127,8 @@ public class CollectionServiceImpl extends ServiceImpl<CollectionMapper, Collect
}
//排序
if(StringUtil.isEmpty(collectionPagination.getSidx())){
collectionQueryWrapper.lambda().orderByDesc(CollectionEntity::getId);
collectionPagination.setSidx("CREATOR_TIME");
collectionPagination.setSort("DESC");
}else{
try {
String sidx = collectionPagination.getSidx();
@ -135,7 +136,8 @@ public class CollectionServiceImpl extends ServiceImpl<CollectionMapper, Collect
Field declaredField = collectionEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
collectionQueryWrapper="asc".equals(collectionPagination.getSort().toLowerCase())?collectionQueryWrapper.orderByAsc(value):collectionQueryWrapper.orderByDesc(value);
collectionPagination.setSidx(value);
// collectionQueryWrapper="asc".equals(collectionPagination.getSort().toLowerCase())?collectionQueryWrapper.orderByAsc(value):collectionQueryWrapper.orderByDesc(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}

@ -15,6 +15,8 @@ import jnpf.base.UserInfo;
import jnpf.base.vo.DownloadVO;
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;
@ -23,6 +25,7 @@ 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.*;
@ -99,7 +102,8 @@ public class InvoicesController {
private PurchaseorderitemService purchaseorderitemService;
@Autowired
private PoundlistService poundlistService;
@Autowired
private MaterialService materialService;
/**
*
*
@ -359,6 +363,12 @@ public class InvoicesController {
//子表
List<InvoicesItem1Entity> InvoicesItem1List = invoicesService.GetInvoicesItem1List(id);
for(InvoicesItem1Entity invoicesitem1Entity : InvoicesItem1List){
if(StringUtils.isNotEmpty(invoicesitem1Entity.getMaterialId())){
MaterialEntity materialEntity = materialService.getById(invoicesitem1Entity.getMaterialId());
if(materialEntity != null){
invoicesitem1Entity.setMaterialName(materialEntity.getItemName());
}
}
}
vo.setInvoicesItem1List(JsonUtil.getJsonToList(InvoicesItem1List,InvoicesItem1Model.class ));
List<InvoicesItem0Entity> InvoicesItem0List = invoicesService.GetInvoicesItem0List(id);

@ -1,6 +1,7 @@
package jnpf.invoices.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -29,40 +30,40 @@ public class InvoicesEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -2,6 +2,7 @@ package jnpf.invoices.entity;
import cn.afterturn.easypoi.excel.annotation.Excel;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -30,41 +31,40 @@ public class InvoicesItem0Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@Excel(name = "购方企业名称")
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@Excel(name = "发票代码")

@ -1,6 +1,7 @@
package jnpf.invoices.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -30,40 +31,40 @@ public class InvoicesItem1Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("INVOICES_ID")
@ -93,4 +94,6 @@ public class InvoicesItem1Entity {
@TableField("REMARK")
private String remark;
@TableField(exist = false)
private String materialName;
}

@ -50,5 +50,8 @@ public class InvoicesItem1Model {
@JsonProperty("remark")
private String remark;
/** 物料 **/
@JsonProperty("materialName")
private String materialName;
}

@ -1,6 +1,7 @@
package jnpf.payment.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -27,40 +28,40 @@ public class PaymentEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
private String creatorTime;
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
private String lastModifyTime;
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
private String deleteTime;
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENTNO")

@ -1,6 +1,7 @@
package jnpf.payment.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -26,40 +27,40 @@ public class Payment_item0Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("PAYMENT_ID")

@ -15,6 +15,8 @@ import jnpf.config.ConfigValueUtil;
import jnpf.contractfile.entity.ContractFileEntity;
import jnpf.contractfile.service.ContractFileService;
import jnpf.exception.DataException;
import jnpf.payment.entity.PaymentEntity;
import jnpf.payment.service.PaymentService;
import jnpf.purchaseback.entity.PurchaseorderEntity;
import jnpf.purchaseback.service.PurchaseorderService;
import org.apache.commons.lang3.StringUtils;
@ -91,6 +93,9 @@ public class PaymentdocController {
@Autowired
private ContractFileService contractFileService;
@Autowired
private PaymentService paymentService;
/**
*
*
@ -108,6 +113,15 @@ public class PaymentdocController {
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));
QueryWrapper<PaymentEntity> PaymentqueryWrapper = new QueryWrapper<>();
PaymentqueryWrapper.lambda().eq(PaymentEntity::getPaymentno, entity.getDocumentNo());
PaymentEntity paymentEntity = paymentService.getOne(PaymentqueryWrapper);
if(paymentEntity != null){
entity.setPaymentEntity(paymentEntity);
}else{
entity.setPaymentEntity(new PaymentEntity());
}
}
List<PaymentdocListVO> listVO=JsonUtil.getJsonToList(list,PaymentdocListVO.class);
for(PaymentdocListVO paymentdocVO:listVO){

@ -1,9 +1,11 @@
package jnpf.paymentdoc.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import jnpf.payment.entity.PaymentEntity;
import lombok.Data;
import java.util.Date;
@ -26,40 +28,40 @@ public class PaymentdocEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")
@ -125,4 +127,6 @@ public class PaymentdocEntity {
@TableField("CONTRACT_ID")
private String contractId;
@TableField(exist = false)
private PaymentEntity paymentEntity;
}

@ -1,6 +1,7 @@
package jnpf.paymentdoc.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -24,40 +25,40 @@ public class PaymentdocItem0Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("PAYMENTDOC_ID")

@ -3,6 +3,7 @@
package jnpf.paymentdoc.model.paymentdoc;
import jnpf.payment.entity.PaymentEntity;
import lombok.Data;
import java.sql.Time;
import java.util.Date;
@ -131,4 +132,7 @@ public class PaymentdocListVO{
@JsonProperty("flowState")
private Integer flowState;
@JsonProperty("paymentEntity")
private PaymentEntity paymentEntity;
}

@ -325,6 +325,10 @@ public class PoundlistController {
case "remark" :
entitys.add(new ExcelExportEntity("备注" ,"remark"));
break;
case "collectPrice" :
entitys.add(new ExcelExportEntity("收货单价" ,"collectPrice"));
break;
default:
break;
}

@ -1,6 +1,7 @@
package jnpf.poundlist.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -33,40 +34,40 @@ public class PoundlistEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("CUSTOMER_ID")
@ -111,6 +112,9 @@ public class PoundlistEntity {
@TableField("PURCHASE_PRICE")
private BigDecimal purchasePrice;
@TableField("COLLECT_PRICE")
private BigDecimal collectPrice;
@TableField("SALES_PRICE")
private BigDecimal salesPrice;

@ -115,6 +115,10 @@ public class PoundlistCrForm {
@JsonProperty("purchasePrice")
private String purchasePrice;
/** 收货单价 **/
@JsonProperty("collectPrice")
private String collectPrice;
/** 进项票日期 **/
@JsonProperty("inputDate")
private Long inputDate;

@ -119,6 +119,10 @@ public class PoundlistInfoVO{
@JsonProperty("purchasePrice")
private String purchasePrice;
/** 收货单价 **/
@JsonProperty("collectPrice")
private String collectPrice;
/** 进项票日期 **/
@JsonProperty("inputDate")
private Long inputDate;

@ -163,6 +163,10 @@ public class PoundlistListVO{
@JsonProperty("purchasePrice")
private String purchasePrice;
/** 收货单价 **/
@JsonProperty("collectPrice")
private String collectPrice;
/** 进项票日期 **/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")

@ -140,6 +140,10 @@ public class PoundlistUpForm{
@JsonProperty("purchasePrice")
private String purchasePrice;
/** 收货单价 **/
@JsonProperty("collectPrice")
private String collectPrice;
/** 进项票日期 **/
@JsonProperty("inputDate")

@ -19,6 +19,7 @@ import jnpf.poundlist.entity.PoundlistEntity;
import jnpf.poundlist.service.PoundlistService;
import jnpf.purchaseorder.entity.Purchaseorder_item0Entity;
import jnpf.purchaseorder.service.Purchaseorder_item0Service;
import jnpf.purchaseorder.service.PurchaseorderitemService;
import org.springframework.transaction.annotation.Transactional;
import jnpf.base.entity.ProvinceEntity;
import jnpf.purchaseback.model.purchaseback.*;
@ -137,34 +138,28 @@ public class PurchasebackController {
purchasebackCrForm.setCreatorTime(DateUtil.getNow());
purchasebackCrForm.setCreatorUserName(userInfo.getUserId());
PurchasebackEntity entity = JsonUtil.getJsonToBean(purchasebackCrForm, PurchasebackEntity.class);
entity.setId(mainId);
purchasebackService.save(entity);
List<Purchaseback_item0Entity> Purchaseback_item0List = JsonUtil.getJsonToList(purchasebackCrForm.getPurchaseback_item0List(),Purchaseback_item0Entity.class);
for(Purchaseback_item0Entity entitys : Purchaseback_item0List){
entitys.setId(RandomUtil.uuId());
entitys.setPurchasebackId(entity.getId());
purchaseback_item0Service.save(entitys);
}
entity.setId(mainId);
purchasebackService.save(entity);
PurchaseorderEntity purchaseorderEntity = purchaseorderService.getById(entity.getPurchaseOrderId());
purchaseorderEntity.setRefundableAmount(entity.getRefundAmount());
purchaseorderEntity.setRefundableNum(entity.getRefundNum());
purchaseorderService.save(purchaseorderEntity);
List<Purchaseback_item0Entity> Purchaseback_item0List = JsonUtil.getJsonToList(purchasebackCrForm.getPurchaseback_item0List(),Purchaseback_item0Entity.class);
for(Purchaseback_item0Entity entitys : Purchaseback_item0List){
entitys.setId(RandomUtil.uuId());
entitys.setPurchasebackId(entity.getId());
purchaseback_item0Service.save(entitys);
}
//子表数据
if(ObjectUtil.isNotEmpty(purchasebackCrForm.getJg_purchaseorder())){
PurchaseorderEntity jg_purchaseorderentity = JsonUtil.getJsonToBean(purchasebackCrForm.getJg_purchaseorder(), PurchaseorderEntity.class);
jg_purchaseorderentity.setId(entity.getPurchaseOrderId());
//自动生成的字段
jg_purchaseorderentity.setId(mainId);
purchaseorderService.save(jg_purchaseorderentity);
}
//子表数据
if(ObjectUtil.isNotEmpty(purchasebackCrForm.getJg_purchaseorder())){
PurchaseorderEntity jg_purchaseorderentity = JsonUtil.getJsonToBean(purchasebackCrForm.getJg_purchaseorder(), PurchaseorderEntity.class);
jg_purchaseorderentity.setId(entity.getPurchaseOrderId());
//自动生成的字段
jg_purchaseorderentity.setId(mainId);
purchaseorderService.save(jg_purchaseorderentity);
}
return ActionResult.success("创建成功");
}
@ -417,7 +412,10 @@ public class PurchasebackController {
subentity.setCreatorTime(entity.getCreatorTime());
subentity.setCreatorUserName(entity.getCreatorUserName());
purchasebackService.update(id, subentity);
PurchaseorderEntity purchaseorderEntity = purchaseorderService.getById(subentity.getPurchaseOrderId());
purchaseorderEntity.setRefundableAmount(subentity.getRefundAmount());
purchaseorderEntity.setRefundableNum(subentity.getRefundNum());
purchaseorderService.save(purchaseorderEntity);
QueryWrapper<Purchaseback_item0Entity> Purchaseback_item0queryWrapper = new QueryWrapper<>();
Purchaseback_item0queryWrapper.lambda().eq(Purchaseback_item0Entity::getPurchasebackId, entity.getId());
purchaseback_item0Service.remove(Purchaseback_item0queryWrapper);

@ -1,6 +1,7 @@
package jnpf.purchaseback.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -28,40 +29,40 @@ public class PurchasebackEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -1,6 +1,7 @@
package jnpf.purchaseback.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -29,40 +30,40 @@ public class Purchaseback_item0Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("POUNDLIST_ID")

@ -1,6 +1,7 @@
package jnpf.purchaseback.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -35,40 +36,40 @@ public class PurchaseorderEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -1,6 +1,7 @@
package jnpf.purchasement.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -29,40 +30,40 @@ public class PurchasementEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
private Date creatorTime;
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private String creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
private Date lastModifyTime;
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
private Date deleteTime;
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private String deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENTNO")

@ -1,6 +1,7 @@
package jnpf.purchasement.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -25,40 +26,40 @@ public class Purchasement_item0Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("PURCHASEMENT_ID")

@ -41,6 +41,7 @@ import jnpf.receiptin.entity.ReceiptinEntity;
import jnpf.receiptin.entity.Receiptin_item0Entity;
import jnpf.receiptin.model.receiptin.Receiptin_item0Model;
import jnpf.receiptin.service.ReceiptinService;
import jnpf.receiptin.service.Receiptin_item0Service;
import jnpf.reservoirarea.entity.ReservoirareaEntity;
import jnpf.reservoirarea.service.ReservoirareaService;
import jnpf.supplier.entity.SupplierEntity;
@ -134,6 +135,8 @@ public class PurchaseorderController {
private ReceiptinService receiptinService;
@Autowired
private Purchaseback_item0Service purchaseback_item0Service;
@Autowired
private Receiptin_item0Service receiptin_item0Service;
/**
*
@ -594,6 +597,23 @@ public class PurchaseorderController {
if (invoicesitemList != null && invoicesitemList.size() > 0) {
vo.setInvoicesitemEntity(invoicesitemList.get(0));
}
QueryWrapper<ReceiptinEntity> receiptinWrapper = new QueryWrapper<>();
receiptinWrapper.lambda().eq(ReceiptinEntity::getSouceno, id);
ReceiptinEntity receiptinEntity = receiptinService.getOne(receiptinWrapper);
if(receiptinEntity != null){
vo.setReceiptamount(receiptinEntity.getReceiptamount());
vo.setReceiptnum(receiptinEntity.getReceiptnum());
QueryWrapper<Receiptin_item0Entity> receiptinitem0Wrapper = new QueryWrapper<>();
receiptinitem0Wrapper.lambda().eq(Receiptin_item0Entity::getReceiptinId, receiptinEntity.getId());
List<Receiptin_item0Entity> receiptin_item0EntityList = receiptin_item0Service.list(receiptinitem0Wrapper);
receiptinEntity.setReceiptin_item0List(receiptin_item0EntityList);
vo.setReceiptinEntity(receiptinEntity);
}else{
vo.setReceiptinEntity(new ReceiptinEntity());
}
List<PaymentListVO> paymentList = paymentService.queryByPurchaseorderId(id);
vo.setPaymentList(paymentList);
QueryWrapper<PurchasebackEntity> purchasebackWrapper = new QueryWrapper<>();
@ -675,6 +695,12 @@ public class PurchaseorderController {
List<PaymentListVO> paymentList = paymentService.queryByPurchaseorderId(id);
vo.setPaymentList(paymentList);
List<Receiptin_item0Entity> receiptin_item0itemList = purchaseorderitemService.GetReceiptin_item0itemList(id);
List<Receiptin_item0Model> jg_receiptin_item0ModelList = JsonUtil.getJsonToList(receiptin_item0itemList, Receiptin_item0Model.class);
vo.setReceiptin_item0List(jg_receiptin_item0ModelList);
@ -684,10 +710,14 @@ public class PurchaseorderController {
if (receiptinEntity != null) {
vo.setReceiptamount(receiptinEntity.getReceiptamount());
vo.setReceiptnum(receiptinEntity.getReceiptnum());
QueryWrapper<Receiptin_item0Entity> receiptinitem0Wrapper = new QueryWrapper<>();
receiptinitem0Wrapper.lambda().eq(Receiptin_item0Entity::getReceiptinId, receiptinEntity.getId());
List<Receiptin_item0Entity> receiptin_item0EntityList = receiptin_item0Service.list(receiptinitem0Wrapper);
receiptinEntity.setReceiptin_item0List(receiptin_item0EntityList);
vo.setReceiptinEntity(receiptinEntity);
}else{
vo.setReceiptinEntity(new ReceiptinEntity());
}
/* `receiptamount` decimal(32,6) DEFAULT NULL COMMENT '',
`receiptnum` decimal(32,6) DEFAULT NULL COMMENT '',*/
QueryWrapper<PurchasebackEntity> purchasebackWrapper = new QueryWrapper<>();
purchasebackWrapper.lambda().eq(PurchasebackEntity::getPurchaseOrderId, id);
List<PurchasebackEntity> PurchasebackList = purchasebackService.list(purchasebackWrapper);

@ -1,6 +1,7 @@
package jnpf.purchaseorder.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -26,40 +27,40 @@ public class CollectionpoEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -1,6 +1,7 @@
package jnpf.purchaseorder.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -29,40 +30,40 @@ public class Invoices_item0itemEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("INVOICE_CODE")

@ -1,5 +1,6 @@
package jnpf.purchaseorder.entity;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -24,40 +25,40 @@ public class InvoicesitemEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -1,5 +1,6 @@
package jnpf.purchaseorder.entity;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -24,40 +25,40 @@ public class PaymentdocpoEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -1,6 +1,7 @@
package jnpf.purchaseorder.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -27,40 +28,40 @@ public class PaymentitemEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENTNO")

@ -1,6 +1,7 @@
package jnpf.purchaseorder.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -28,40 +29,40 @@ public class PurchasebackitemEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -1,6 +1,7 @@
package jnpf.purchaseorder.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -30,40 +31,40 @@ public class Purchaseorder_item0Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("PURCHASEORDER_ID")

@ -1,6 +1,7 @@
package jnpf.purchaseorder.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -38,40 +39,40 @@ public class PurchaseorderitemEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENT_NO")

@ -12,6 +12,7 @@ import jnpf.purchaseorder.model.purchaseorder.Invoices_item0itemModel;
import jnpf.purchaseorder.model.purchaseorder.PaymentitemModel;
import jnpf.purchaseorder.model.purchaseorder.PurchasebackitemModel;
import jnpf.purchaseorder.model.purchaseorder.CollectionitemModel;
import jnpf.receiptin.entity.ReceiptinEntity;
import jnpf.receiptin.model.receiptin.Receiptin_item0Model;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonProperty;
@ -164,4 +165,7 @@ public class PurchaseorderInfoVO{
@JsonProperty("invoicesitemEntity")
private InvoicesitemEntity invoicesitemEntity;
@JsonProperty("receiptinEntity")
private ReceiptinEntity receiptinEntity;
}

@ -1,6 +1,7 @@
package jnpf.receiptin.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -9,6 +10,8 @@ import lombok.Data;
import java.util.Date;
import java.math.BigDecimal;
import java.math.BigDecimal;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonProperty;
@ -27,40 +30,40 @@ public class ReceiptinEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("DOCUMENTNO")
@ -98,4 +101,7 @@ public class ReceiptinEntity {
@TableField("SUPPLIER_ID")
private String supplierId;
@TableField(exist = false)
private List<Receiptin_item0Entity> receiptin_item0List;
}

@ -1,6 +1,7 @@
package jnpf.receiptin.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -29,40 +30,40 @@ public class Receiptin_item0Entity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("RECEIPTIN_ID")

@ -129,7 +129,8 @@ public class ReceiptoutServiceImpl extends ServiceImpl<ReceiptoutMapper, Receipt
}
//排序
if(StringUtil.isEmpty(receiptoutPagination.getSidx())){
receiptoutQueryWrapper.lambda().orderByDesc(ReceiptoutEntity::getId);
receiptoutPagination.setSidx("CREATOR_TIME");
receiptoutPagination.setSort("DESC");
}else{
try {
String sidx = receiptoutPagination.getSidx();
@ -137,7 +138,8 @@ public class ReceiptoutServiceImpl extends ServiceImpl<ReceiptoutMapper, Receipt
Field declaredField = receiptoutEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
receiptoutQueryWrapper="asc".equals(receiptoutPagination.getSort().toLowerCase())?receiptoutQueryWrapper.orderByAsc(value):receiptoutQueryWrapper.orderByDesc(value);
receiptoutPagination.setSidx(value);
// receiptoutQueryWrapper="asc".equals(receiptoutPagination.getSort().toLowerCase())?receiptoutQueryWrapper.orderByAsc(value):receiptoutQueryWrapper.orderByDesc(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}

@ -293,7 +293,7 @@ public class SaleorderitemController {
}
}
}else{
return ActionResult.fail("发票金额、金额、已付款金额不一致");
return ActionResult.fail("发票金额、金额、已付款金额不一致或当前状态无法归档");
}
}else {
return ActionResult.fail("未找到该数据");
@ -422,15 +422,10 @@ public class SaleorderitemController {
for (Salesorder_item0Entity salesorder_item0Entity : Salesorder_item0List){
PoundlistEntity poundlistEntity = poundlistService.getInfo(salesorder_item0Entity.getPoundlistId());
if(ObjectUtils.isNotEmpty(poundlistEntity) && poundlistEntity.getPurchaseStatus() != null){
if (!poundlistEntity.getPurchaseStatus().equals("2") || !poundlistEntity.getPurchaseStatus().equals("3")){
if (!poundlistEntity.getPurchaseStatus().equals("2") && !poundlistEntity.getPurchaseStatus().equals("3")){
return ActionResult.fail("存在磅单号为【磅单号-"+poundlistEntity.getPoundlistNo()+"】未开票或未入库");
}
}
// if (ObjectUtils.isNotEmpty(poundlistEntity)){
// if (poundlistEntity.getIsInvoicing().equals("0")){
// return ActionResult.fail("存在磅单号为【磅单号-"+poundlistEntity.getPoundlistNo()+"】未开进项票");
// }
// }
}
String mainId =RandomUtil.uuId();
UserInfo userInfo=userProvider.get();

@ -250,7 +250,8 @@ public class SaleorderitemServiceImpl extends ServiceImpl<SaleorderitemMapper, S
}
//排序
if(StringUtil.isEmpty(saleorderitemPagination.getSidx())){
saleorderitemQueryWrapper.lambda().orderByDesc(SaleorderitemEntity::getId);
saleorderitemPagination.setSidx("CREATOR_TIME");
saleorderitemPagination.setSort("DESC");
}else{
try {
String sidx = saleorderitemPagination.getSidx();
@ -258,7 +259,8 @@ public class SaleorderitemServiceImpl extends ServiceImpl<SaleorderitemMapper, S
Field declaredField = saleorderitemEntity.getClass().getDeclaredField(sidx);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
saleorderitemQueryWrapper="asc".equals(saleorderitemPagination.getSort().toLowerCase())?saleorderitemQueryWrapper.orderByAsc(value):saleorderitemQueryWrapper.orderByDesc(value);
saleorderitemPagination.setSidx(value);
// saleorderitemQueryWrapper="asc".equals(saleorderitemPagination.getSort().toLowerCase())?saleorderitemQueryWrapper.orderByAsc(value):saleorderitemQueryWrapper.orderByDesc(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}

@ -1,6 +1,7 @@
package jnpf.tradeupload.entity;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -33,40 +34,40 @@ public class TradeuploadEntity {
@TableId("ID")
private String id;
@TableField("CREATOR_USER_ID")
@TableField(value = "CREATOR_USER_ID",fill = FieldFill.INSERT)
private String creatorUserId;
@TableField("CREATOR_USER_NAME")
@TableField(value = "CREATOR_USER_NAME",fill = FieldFill.INSERT)
private String creatorUserName;
@TableField("CREATOR_TIME")
@TableField(value = "CREATOR_TIME",fill = FieldFill.INSERT)
private Date creatorTime;
@TableField("LAST_MODIFY_USER_ID")
@TableField(value = "LAST_MODIFY_USER_ID",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserId;
@TableField("LAST_MODIFY_USER_NAME")
@TableField(value = "LAST_MODIFY_USER_NAME",fill = FieldFill.INSERT_UPDATE)
private String lastModifyUserName;
@TableField("LAST_MODIFY_TIME")
@TableField(value = "LAST_MODIFY_TIME",fill = FieldFill.INSERT_UPDATE)
private Date lastModifyTime;
@TableField("DELETE_USER_ID")
@TableField(value = "DELETE_USER_ID",fill = FieldFill.UPDATE)
private String deleteUserId;
@TableField("DELETE_USER_NAME")
@TableField(value = "DELETE_USER_NAME",fill = FieldFill.UPDATE)
private String deleteUserName;
@TableField("DELETE_TIME")
@TableField(value = "DELETE_TIME",fill = FieldFill.UPDATE)
private Date deleteTime;
@TableField("DELETE_MARK")
@TableField(value = "DELETE_MARK",fill = FieldFill.UPDATE)
private String deleteMark;
@TableField("ORGNIZE_ID")
@TableField(value = "ORGNIZE_ID",fill = FieldFill.INSERT)
private String orgnizeId;
@TableField("DEPARTMENT_ID")
@TableField(value = "DEPARTMENT_ID",fill = FieldFill.INSERT)
private String departmentId;
@TableField("CUSTOMER_ID")

@ -54,7 +54,7 @@ public class VehicleListVO{
/** 创建时间 **/
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
@JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
@JsonProperty("creatortime")
private Date creatortime;
// 运输总次数

@ -29,6 +29,9 @@
<if test="arinvoicesPagination.startDate != null and arinvoicesPagination.endDate != null">
and a.business_date &gt; #{arinvoicesPagination.startDate} AND a.business_date &lt;= #{arinvoicesPagination.endDate}
</if>
<if test="arinvoicesPagination.sidx != null and arinvoicesPagination.sidx != ''">
ORDER BY ${arinvoicesPagination.sidx} ${arinvoicesPagination.sort}
</if>
</select>
</mapper>

@ -26,6 +26,9 @@
<if test="collectionPagination.customerNm != null and collectionPagination.customerNm != ''">
and b.supplier_nm LIKE CONCAT('%',#{collectionPagination.customerNm},'%')
</if>
<if test="collectionPagination.sidx != null and collectionPagination.sidx != ''">
ORDER BY ${collectionPagination.sidx} ${collectionPagination.sort}
</if>
</select>
</mapper>

@ -27,6 +27,9 @@
<if test="receiptoutPagination.startDate != null and receiptoutPagination.endDate != null">
and a.creator_time &gt; #{receiptoutPagination.startDate} AND a.creator_time &lt;= #{receiptoutPagination.endDate}
</if>
<if test="receiptoutPagination.sidx != null and receiptoutPagination.sidx != ''">
ORDER BY ${receiptoutPagination.sidx} ${receiptoutPagination.sort}
</if>
</select>
</mapper>

@ -28,6 +28,9 @@
<if test="saleorderitemPagination.startDate != null and saleorderitemPagination.endDate != null">
and a.creator_time &gt; #{saleorderitemPagination.startDate} AND a.creator_time &lt;= #{saleorderitemPagination.endDate}
</if>
<if test="saleorderitemPagination.sidx != null and saleorderitemPagination.sidx != ''">
ORDER BY ${saleorderitemPagination.sidx} ${saleorderitemPagination.sort}
</if>
</select>

@ -0,0 +1,25 @@
import request from '@/utils/request'
// 导入
export function ImportData(data) {
return request({
url: '/api/arinvoices/Arinvoices/ImportData',
method: 'post',
data
})
}
// 导入预览
export function ImportPreview(data) {
return request({
url: '/api/arinvoices/Arinvoices/ImportPreview',
method: 'get',
data
})
}
//模板下载
export function TemplateDownload() {
return request({
url: '/api/arinvoices/Arinvoices/TemplateDownload',
method: 'get'
})
}

@ -307,17 +307,20 @@
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button type="primary" icon="el-icon-upload2" @click="uploadForm"></el-button>
<el-button @click="visible = false"> </el-button>
<el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail"> </el-button>
</span>
<ImportForm v-if="importFormVisible" ref="importForm" @importData="importData" />
</el-dialog>
</template>
<script>
import request from '@/utils/request'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
import ImportForm from '../saleorder/ImportForm'
export default {
components: {},
components: { ImportForm },
props: [],
data() {
return {
@ -362,6 +365,30 @@
},
mounted() {},
methods: {
importData(param){
param.checkedList.forEach((column, index) => {
if(column.taxRate == '0.13'){
column.taxRate = '0';
}else if(column.taxRate == '0.09'){
column.taxRate = '1';
}else if(column.taxRate == '0.06'){
column.taxRate = '2';
}else if(column.taxRate == '0.05'){
column.taxRate = '3';
}else if(column.taxRate == '0.03'){
column.taxRate = '4';
}else if(column.taxRate == '0'){
column.taxRate = '5';
}
this.dataForm.invoicesitem0List.push(column);
});
},
uploadForm() {
this.importFormVisible = true
this.$nextTick(() => {
this.$refs.importForm.init()
})
},
getSummaries(param) {
const { columns, data } = param;
const sums = [];

@ -454,11 +454,13 @@
this.dataForm.amountCollected = sum;
},
popupSelect(e, d) {
debugger
this.dataForm.code = d.id;
this.dataForm.collectionCount = d.bank_account;
this.dataForm.collectionBank = d.bank;
debugger
this.dataForm.collection_item0List = [];
},
contractSelect(){
this.dataForm.collection_item0List = [];
},
popupSelect2(a, b) {
for (let i = 0; i < this.dataForm.collection_item0List.length; i++) {

@ -92,8 +92,8 @@
</el-button>
<!-- <el-button type="text" @click="addOrUpdateHandle(scope.row.id)">-->
<!-- </el-button>-->
<!-- <el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">-->
<!-- </el-button>-->
<el-button type="text" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">
</el-button>
<el-button type="text" v-has="'btn_look'" @click="goDetail(scope.row.id)">
</el-button>
</template>

@ -139,7 +139,7 @@
},
customerLevelOptions:[{"fullName":"一级","id":"1"},{"fullName":"二级","id":"2"},{"fullName":"三级","id":"3"}],
statusOptions:[{"fullName":"启用","id":"1"},{"fullName":"禁用","id":"2"}],
enterpriseOptions:[{"fullName":"民营","id":"0"},{"fullName":"私企","id":"1"}],
enterpriseOptions:[{ 'fullName': '民营', 'id': '0' }, { 'fullName': '国有', 'id': '1' }, { 'fullName': '其它', 'id': '2' }],
classificationOptions:[{"fullName":"国内","id":"0"},{"fullName":"国外","id":"1"}],
}

@ -216,7 +216,7 @@
orgIdcolumnOptions:[ {"label":"机构编号","value":"F_EnCode"}, {"label":"公司名称","value":"F_FullName"},],
customerLevelOptions:[{"fullName":"一级","id":"1"},{"fullName":"二级","id":"2"},{"fullName":"三级","id":"3"}],
statusOptions:[{"fullName":"启用","id":"1"},{"fullName":"禁用","id":"2"}],
enterpriseOptions:[{"fullName":"民营","id":"0"},{"fullName":"私企","id":"1"}],
enterpriseOptions:[{ 'fullName': '民营', 'id': '0' }, { 'fullName': '国有', 'id': '1' }, { 'fullName': '其它', 'id': '2' }],
classificationOptions:[{"fullName":"国内","id":"0"},{"fullName":"国外","id":"1"}],
}

@ -200,7 +200,7 @@
customerLevelProps: { 'label': 'fullName', 'value': 'id' },
statusOptions: [{ 'fullName': '启用', 'id': '1' }, { 'fullName': '禁用', 'id': '2' }],
statusProps: { 'label': 'fullName', 'value': 'id' },
enterpriseOptions: [{ 'fullName': '民营', 'id': '0' }, { 'fullName': '私企', 'id': '1' }],
enterpriseOptions: [{ 'fullName': '民营', 'id': '0' }, { 'fullName': '国有', 'id': '1' }, { 'fullName': '其它', 'id': '2' }],
enterpriseProps: { 'label': 'fullName', 'value': 'id' },
classificationOptions: [{ 'fullName': '国内', 'id': '0' }, { 'fullName': '国外', 'id': '1' }],
classificationProps: { 'label': 'fullName', 'value': 'id' }

@ -76,6 +76,13 @@
</popupSelect>
</el-form-item>
</el-col>
<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">
@ -242,6 +249,7 @@
transportPrice: 0,
salesPrice: 0,
purchasePrice: 0,
collectPrice: 0,
businessId: "",
naturalId: "",
remark: '',
@ -313,6 +321,11 @@
message: '请输入',
trigger: 'blur'
}, ],
collectPrice: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
purchasePrice: [{
required: true,
message: '请输入',

@ -76,6 +76,13 @@
</popupSelect>
</el-form-item>
</el-col>
<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">
@ -108,6 +115,7 @@
<el-input-number v-model="dataForm.salesPrice" :style='{"width":"100%"}'></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="磅单日期" prop="poundDate">
<el-date-picker v-model="dataForm.poundDate" placeholder="请选择" clearable :style='{"width":"100%"}'
@ -240,6 +248,7 @@
transportType: "0",
advance: "0",
transportPrice: 0,
collectPrice: 0,
salesPrice: 0,
purchasePrice: 0,
businessId: "",
@ -313,6 +322,11 @@
message: '请输入',
trigger: 'blur'
}, ],
collectPrice: [{
required: true,
message: '请输入',
trigger: 'blur'
}, ],
purchasePrice: [{
required: true,
message: '请输入',

@ -114,40 +114,48 @@
<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="poundlistNo" label="磅单号" width="200" align="center" sortable fixed="left" />
<el-table-column prop="vehicleName" label="车号" fixed="left" sortable width="120" 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" >
<template slot-scope="scope">
{{ scope.row.purchaseStatus | dynamicText(purchaseStatusOptions) }}
</template>
<template slot-scope="scope">
{{ scope.row.purchaseStatus | dynamicText(purchaseStatusOptions) }}
</template>
</el-table-column>
<el-table-column prop="salesStatus" label="销售状态" sortable width="100" align="center" >
<template slot-scope="scope">
{{ scope.row.salesStatus | dynamicText(salesStatusOptions) }}
</template>
<template slot-scope="scope">
{{ scope.row.salesStatus | dynamicText(salesStatusOptions) }}
</template>
</el-table-column>
<el-table-column prop="materialName" label="物料名称" sortable width="150" 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" />
<el-table-column prop="supplierName" label="供应商名称" sortable width="150" align="center" />
<el-table-column prop="purchaseName" label="采购合同" sortable width="150" align="center" />
<el-table-column prop="materialName" label="物料名称" sortable width="150" align="center" />
<el-table-column prop="advance" label="是否垫资" sortable width="100" align="center" >
<template slot-scope="scope">
{{ scope.row.advance | dynamicText(advanceOptions) }}
</template>
</el-table-column>
<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="buckleWeight" sortable label="扣重" width="100" align="center" />
<el-table-column prop="netWeight" 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="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" />
@ -316,6 +324,7 @@
prop: 'unit',
label: '单位'
},
{ prop: 'creatorTime', label: '创建时间' },
{
prop: 'grossWeight',
label: '毛重'
@ -344,6 +353,10 @@
prop: 'salesPrice',
label: '销售价格'
},
{
prop: 'collectPrice',
label: '收货价格'
},
{
prop: 'inputDate',
label: '进项票日期'
@ -593,6 +606,7 @@
})
return
}
const ids = this.multipleSelection.join()
request({
url: `/api/poundlist/Poundlist/createsale/${ids}`,

@ -46,14 +46,6 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="币别" prop="currency">
<el-select v-model="dataForm.currency" placeholder="请选择币别" :disabled="true">
<el-option v-for="(item, index) in currencyOptions" :key="index" :label="item.fullName" :value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="入库重量" prop="receiptnum">
<el-input v-model="dataForm.receiptnum" placeholder="请输入入库重量" readonly>
@ -61,13 +53,21 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="币别" prop="currency">
<el-select v-model="dataForm.currency" placeholder="请选择币别" :disabled="true">
<el-option v-for="(item, index) in currencyOptions" :key="index" :label="item.fullName" :value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<!-- <el-form-item label="供应商名称" prop="suppliername">
<el-input v-model="dataForm.suppliername" placeholder="请输入供应商名称" readonly>
</el-input>
</el-form-item> -->
<el-form-item label="供应商id" prop="supplierId">
<el-form-item label="供应商" prop="supplierId">
<popupSelect v-model="dataForm.supplierId" placeholder="请选择" clearable field="supplierId"
interfaceId="397751667988199621" :columnOptions="supplierIdcolumnOptions" propsValue="id"
relationField="supplier_name" popupType="dialog" popupTitle="选择数据" popupWidth="800px" hasPage

@ -494,7 +494,7 @@
salesbacksoitemList:[],
paymentsoitemList:[],
},
activemtmitd:'1',
activemtmitd:'0',
currencyOptions:[{"fullName":"人民币","id":"0"},{"fullName":"美元","id":"1"},{"fullName":"英镑","id":"2"}],
statusOptions:[{"fullName":"已保存","id":"0"},{"fullName":"开票中","id":"1"},{"fullName":"付款申请","id":"2"},{"fullName":"待回款","id":"3"},{"fullName":"回款中","id":"4"},{"fullName":"归档","id":"5"}],

@ -0,0 +1,247 @@
<template>
<el-dialog title="批量导入" :close-on-click-modal="false" :visible.sync="visible"
class="JNPF-dialog JNPF-dialog_center JNPF-dialog-import" lock-scroll width="1000px" :modal="false" :modal-append-to-body="false">
<el-steps :active="active" align-center>
<el-step title="上传文件"></el-step>
<el-step title="数据预览"></el-step>
<el-step title="导入数据"></el-step>
</el-steps>
<div class="import-main" v-show="active==1">
<div class="upload">
<div class="up_left">
<img src="@/assets/images/upload.png">
</div>
<div class="up_right">
<p class="title">上传填好的数据表</p>
<p class="tip">文件后缀名必须是xls或xlsx文件大小不超过500KB最多支持导入1000条数据</p>
<el-upload :action="define.comUrl+'/api/arinvoices/Arinvoices/Uploader'"
:headers="{ Authorization: $store.getters.token}" :on-success="handleSuccess"
:on-remove="handleRemove" :before-remove="beforeRemove" :on-change="handleChange"
:file-list="fileList" accept=".xls,.xlsx" :before-upload="beforeUpload"
class="upload-area">
<el-button type="text">上传文件</el-button>
</el-upload>
</div>
</div>
<div class="upload">
<div class="up_left">
<img src="@/assets/images/import.png">
</div>
<div class="up_right">
<p class="title">填写导入数据信息</p>
<p class="tip">请按照数据模板的格式准备导入数据模板中的表头名称不可更改表头行不能删除</p>
<el-button type="text" @click="templateDownload"></el-button>
</div>
</div>
</div>
<div class="import-main" v-show="active==2">
<JNPF-table v-loading="listLoading" :data="list">
<!-- <el-table-column prop="materialName" label="物料名称" width="150">-->
<!-- <template slot-scope="scope">-->
<!-- <el-input v-model="scope.row.materialName" />-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column prop="invoiceCode" label="发票代码" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.invoiceCode" />
</template>
</el-table-column>
<el-table-column prop="invoiceNo" label="发票号码" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.invoiceNo" />
</template>
</el-table-column>
<el-table-column prop="invoiceQuantity" label="发票数量" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.invoiceQuantity" />
</template>
</el-table-column>
<el-table-column prop="involceAmount" label="发票金额" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.involceAmount" />
</template>
</el-table-column>
<el-table-column prop="taxRate" label="税率" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.taxRate" />
</template>
</el-table-column>
<el-table-column prop="taxAmount" label="税额" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.taxAmount" />
</template>
</el-table-column>
<el-table-column prop="amountNotTax" label="不含税金额" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.amountNotTax" />
</template>
</el-table-column>
<!-- <el-table-column prop="invoiceStatus" label="发票状态" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.invoiceStatus" />
</template>
</el-table-column> -->
<el-table-column prop="creatorUserName" label="开票人" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.creatorUserName" />
</template>
</el-table-column>
<el-table-column prop="invoiceDate" label="开票日期" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.invoiceDate" />
</template>
</el-table-column>
<el-table-column label="操作" fixed="right" width="50">
<template slot-scope="scope">
<el-button size="mini" type="text" class="JNPF-table-delBtn"
@click="handleDel(scope.$index)">删除</el-button>
</template>
</el-table-column>
</JNPF-table>
</div>
<div class="import-main" v-show="active==3">
<div class="success" v-if="!result.resultType">
<img src="@/assets/images/success.png" alt="">
<p class="success-title">批量导入成功</p>
<p class="success-tip">您已成功导入数据</p>
</div>
<div class="unsuccess" v-if="result.resultType">
<el-alert title="错误提醒:导入失败数据展示" type="warning" show-icon :closable="false" />
<div class="upload error-show">
<div class="up_left">
<img class="" src="@/assets/images/tip.png">
</div>
<div class="up_right">
<p class="tip">正常数量条数<el-link type="success" :underline="false">{{result.snum}}
</el-link>
</p>
<p class="tip">异常数量条数<el-link type="danger" :underline="false">{{result.fnum}}
</el-link>
</p>
</div>
</div>
<p class="contips">以下文件数据为导入异常数据</p>
<JNPF-table :data="resultList" height="280px">
<el-table-column prop="materialName" label="物料名称" width="100" />
<el-table-column prop="invoiceCode" label="发票代码" width="100" />
<el-table-column prop="invoiceNo" label="发票号码" width="80" />
<el-table-column prop="invoiceQuantity" label="发票数量" width="120" />
<el-table-column prop="involceAmount" label="发票金额" width="120" />
<el-table-column prop="taxRate" label="税率" width="100" />
<el-table-column prop="taxAmount" label="税额" width="150" />
<el-table-column prop="amountNotTax" label="不含税金额" width="100" />
<!-- <el-table-column prop="invoiceStatus" label="发票状态" width="100" /> -->
<el-table-column prop="creatorUserName" label="开票人" width="100" />
<el-table-column prop="invoicingDate" label="开票日期" width="100" />
</JNPF-table>
</div>
</div>
<span slot="footer" class="dialog-footer">
<el-button @click="cancel()" v-if="active == 1"> </el-button>
<el-button @click="prev" v-if="active == 2"></el-button>
<el-button @click="next" type="primary" v-if="active < 3" :loading="btnLoading"
:disabled="active == 1 && !fileName">下一步
</el-button>
<el-button @click="cancel(true)" type="primary" v-else> </el-button>
</span>
</el-dialog>
</template>
<script>
import { TemplateDownload, ImportData, ImportPreview } from '@/api/scm/invoices'
export default {
data() {
return {
visible: false,
btnLoading: false,
listLoading: false,
fileName: '',
fileList: [],
active: 1,
list: [],
resultList: [],
result: {
resultType: 0,
snum: 0,
fnum: 0
}
}
},
methods: {
prev() {
if (this.active == 1) return
this.active--
},
next() {
if (this.active == 2) {
if (!this.list.length) return this.$message({ message: '导入数据为空', type: 'warning' })
this.btnLoading = true
this.btnLoading = false
this.result = this.list
console.log('rrrrrrr', this.list);
//this.$emit('importData', this.list)
this.active++
/* ImportData({ list: this.list }).then(res => {
this.result = res.data
this.resultList = res.data.failResult
this.btnLoading = false
this.active++
}).catch(() => { this.btnLoading = false }) */
}
if (this.active == 1) {
if (!this.fileList.length || !this.fileName) return this.$message({ message: '请先上传文件', type: 'warning' })
this.btnLoading = true
ImportPreview({ fileName: this.fileName }).then(res => {
this.list = res.data.dataRow
this.btnLoading = false
this.active++
}).catch(() => { this.btnLoading = false })
}
},
cancel(isRefresh) {
this.visible = false
this.$emit('importData', {
checkedList: this.result
})
//if (isRefresh) this.$emit('refresh')
},
init() {
this.active = 1
this.fileList = []
this.fileName = ''
this.visible = true
},
handleDel(index) {
this.list.splice(index, 1)
},
templateDownload() {
TemplateDownload().then(res => {
this.jnpf.downloadFile(res.data.url)
})
},
beforeUpload(file) {
let isRightSize = file.size / 1024 < 500
if (!isRightSize) this.$message.error(`文件大小不能超过500KB`)
return isRightSize
},
handleRemove(file, fileList) {
this.fileList = []
},
beforeRemove(file, fileList) {
return this.$confirm(`确定移除 ${file.name}`).catch(() => { })
},
handleChange(file, fileList) {
this.fileList = fileList.slice(-1)
},
handleSuccess(res, file, fileList) {
if (res.code == 200) {
this.fileList = fileList.slice(-1)
this.fileName = res.data.name
} else {
this.fileList = fileList.filter(o => o.uid != file.uid)
this.$message({ message: res.msg, type: 'error', duration: 1000 })
}
}
}
}
</script>

@ -319,21 +319,25 @@
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button type="primary" icon="el-icon-upload2" @click="uploadForm"></el-button>
<el-button @click="visible = false"> </el-button>
<el-button type="primary" @click="dataFormSubmit()" v-if="!isDetail"> </el-button>
</span>
<ImportForm v-if="importFormVisible" ref="importForm" @importData="importData" />
</el-dialog>
</template>
<script>
import request from '@/utils/request'
import { getDataInterfaceRes } from '@/api/systemData/dataInterface'
import { getDictionaryDataSelector } from '@/api/systemData/dictionary'
import ImportForm from './ImportForm'
export default {
components: {},
components: { ImportForm },
props: [],
data() {
return {
importFormVisible: false,
visible: false,
loading: false,
isDetail: false,
@ -378,6 +382,30 @@
},
mounted() {},
methods: {
importData(param){
param.checkedList.forEach((column, index) => {
if(column.taxRate == '0.13'){
column.taxRate = '0';
}else if(column.taxRate == '0.09'){
column.taxRate = '1';
}else if(column.taxRate == '0.06'){
column.taxRate = '2';
}else if(column.taxRate == '0.05'){
column.taxRate = '3';
}else if(column.taxRate == '0.03'){
column.taxRate = '4';
}else if(column.taxRate == '0'){
column.taxRate = '5';
}
this.dataForm.invoicesitem0List.push(column);
});
},
uploadForm() {
this.importFormVisible = true
this.$nextTick(() => {
this.$refs.importForm.init()
})
},
getSummaries(param) {
const { columns, data } = param;
const sums = [];

@ -1,225 +1,202 @@
<template>
<el-dialog title="详情"
:close-on-click-modal="false" append-to-body
:visible.sync="visible" class="JNPF-dialog JNPF-dialog_center" lock-scroll
width="1000px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" size="small" label-width="100px" label-position="right" >
<template v-if="!loading">
<el-col :span="12" >
<el-form-item label="供应商编码"
prop="supplierCode" >
<p>{{dataForm.supplierCode}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="所属公司"
prop="companyId" >
<p>{{dataForm.companyId}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商名称"
prop="supplierName" >
<p>{{dataForm.supplierName}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="国家"
prop="country" >
<p>{{dataForm.country}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供货指标"
prop="supply" >
<p>{{dataForm.supply}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="省"
prop="province" >
<p>{{dataForm.province}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="联系人"
prop="contactName" >
<p>{{dataForm.contactName}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商等级"
prop="supplierLevel" >
<p>{{ dataForm.supplierLevel | dynamicText(supplierLevelOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="联系电话"
prop="contactPhone" >
<p>{{dataForm.contactPhone}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商性质"
prop="enterprise" >
<p>{{ dataForm.enterprise | dynamicText(enterpriseOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="地址"
prop="address" >
<p>{{dataForm.address}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商类型"
prop="classification" >
<p>{{ dataForm.classification | dynamicText(classificationOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="开户行"
prop="bank" >
<p>{{dataForm.bank}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="默认税码"
prop="taxCode" >
<p>{{ dataForm.taxCode | dynamicText(taxCodeOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="纳税编号"
prop="vatRegistrationNum" >
<p>{{dataForm.vatRegistrationNum}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否采购"
prop="isPurchase" >
<p>{{ dataForm.isPurchase | dynamicText(isPurchaseOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="银行账户"
prop="bankAccount" >
<p>{{dataForm.bankAccount}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否付款"
prop="isPayment" >
<p>{{ dataForm.isPayment | dynamicText(isPaymentOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="应付科目"
prop="payable" >
<p>{{dataForm.payable}}</p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否启用"
prop="status" >
<p>{{ dataForm.status | dynamicText(statusOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="预付科目"
prop="prepaid" >
<p>{{dataForm.prepaid}}</p>
</el-form-item>
</el-col>
</template>
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false"> </el-button>
</span>
<el-dialog title="详情" :close-on-click-modal="false" append-to-body :visible.sync="visible"
class="JNPF-dialog JNPF-dialog_center" lock-scroll width="1000px">
<el-row :gutter="15" class="">
<el-form ref="elForm" :model="dataForm" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="12">
<el-form-item label="供应商编码" prop="supplierCode">
<p>{{ dataForm.supplierCode }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="所属公司" prop="companyId">
<p>{{ dataForm.companyId }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商名称" prop="supplierName">
<p>{{ dataForm.supplierName }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="国家" prop="country">
<p>{{ dataForm.country }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供货指标" prop="supply">
<p>{{ dataForm.supply }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="省" prop="province">
<p>{{ dataForm.province }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系人" prop="contactName">
<p>{{ dataForm.contactName }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商等级" prop="supplierLevel">
<p>{{ dataForm.supplierLevel | dynamicText(supplierLevelOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系电话" prop="contactPhone">
<p>{{ dataForm.contactPhone }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商性质" prop="enterprise">
<p>{{ dataForm.enterprise | dynamicText(enterpriseOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="地址" prop="address">
<p>{{ dataForm.address }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商类型" prop="classification">
<p>{{ dataForm.classification | dynamicText(classificationOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="开户行" prop="bank">
<p>{{ dataForm.bank }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="默认税码" prop="taxCode">
<p>{{ dataForm.taxCode | dynamicText(taxCodeOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="纳税编号" prop="vatRegistrationNum">
<p>{{ dataForm.vatRegistrationNum }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否采购" prop="isPurchase">
<p>{{ dataForm.isPurchase | dynamicText(isPurchaseOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="银行账户" prop="bankAccount">
<p>{{ dataForm.bankAccount }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否付款" prop="isPayment">
<p>{{ dataForm.isPayment | dynamicText(isPaymentOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="应付科目" prop="payable">
<p>{{ dataForm.payable }}</p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否启用" prop="status">
<p>{{ dataForm.status | dynamicText(statusOptions) }} </p>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="预付科目" prop="prepaid">
<p>{{ dataForm.prepaid }}</p>
</el-form-item>
</el-col>
</template>
</el-form>
</el-row>
<span slot="footer" class="dialog-footer">
<el-button @click="visible = false"> </el-button>
</span>
</el-dialog>
</template>
<script>
import request from '@/utils/request'
import PrintBrowse from '@/components/PrintBrowse'
import jnpf from '@/utils/jnpf'
export default {
components: {PrintBrowse},
props: [],
data() {
return {
visible: false,
loading: false,
printBrowseVisible: false,
printId: '',
import request from '@/utils/request'
import PrintBrowse from '@/components/PrintBrowse'
import jnpf from '@/utils/jnpf'
export default {
components: { PrintBrowse },
props: [],
data() {
return {
visible: false,
loading: false,
printBrowseVisible: false,
printId: '',
dataForm: {
id :'',
supplierCode : '',
companyId : "",
supplierName : '',
country : "CHINA",
supply : '',
province : [],
contactName : '',
supplierLevel : "1",
contactPhone : '',
enterprise : "0",
address : '',
classification : "0",
bank : '',
taxCode : "0",
vatRegistrationNum : '',
isPurchase : "0",
bankAccount : '',
isPayment : "0",
payable : '',
status : "1",
prepaid : '',
supplierSiteCode : '',
creatorTime : "",
lastModifyTime : "",
id: '',
supplierCode: '',
companyId: "",
supplierName: '',
country: "CHINA",
supply: '',
province: [],
contactName: '',
supplierLevel: "1",
contactPhone: '',
enterprise: "0",
address: '',
classification: "0",
bank: '',
taxCode: "0",
vatRegistrationNum: '',
isPurchase: "0",
bankAccount: '',
isPayment: "0",
payable: '',
status: "1",
prepaid: '',
supplierSiteCode: '',
creatorTime: "",
lastModifyTime: "",
},
supplierLevelOptions:[{"fullName":"一级","id":"1"},{"fullName":"二级","id":"2"},{"fullName":"三级","id":"3"},{"fullName":"四级","id":"4"}],
enterpriseOptions:[{"fullName":"民营","id":"0"},{"fullName":"私营","id":"1"}],
classificationOptions:[{"fullName":"国内","id":"0"},{"fullName":"国外","id":"1"}],
taxCodeOptions:[{"fullName":"13个点","id":"0"},{"fullName":"9个点","id":"1"},{"fullName":"6个点","id":"2"},{"fullName":"5个点","id":"3"}],
isPurchaseOptions:[{"fullName":"否","id":"0"},{"fullName":"是","id":"1"}],
isPaymentOptions:[{"fullName":"否","id":"0"},{"fullName":"是","id":"1"}],
statusOptions:[{"fullName":"启用","id":"1"},{"fullName":"停用","id":"2"}],
supplierLevelOptions: [{ "fullName": "一级", "id": "1" }, { "fullName": "二级", "id": "2" }, { "fullName": "三级", "id": "3" }, { "fullName": "四级", "id": "4" }],
enterpriseOptions: [{ 'fullName': '民营', 'id': '0' }, { 'fullName': '国有', 'id': '1' }, { 'fullName': '其它', 'id': '2' }],
classificationOptions: [{ "fullName": "国内", "id": "0" }, { "fullName": "国外", "id": "1" }],
taxCodeOptions: [{ "fullName": "13", "id": "0" }, { "fullName": "9", "id": "1" }, { "fullName": "6", "id": "2" }, { "fullName": "5", "id": "3" }, { "fullName": "3", "id": "4" }, { "fullName": "0", "id": "5" }],
isPurchaseOptions: [{ "fullName": "否", "id": "0" }, { "fullName": "是", "id": "1" }],
isPaymentOptions: [{ "fullName": "否", "id": "0" }, { "fullName": "是", "id": "1" }],
statusOptions: [{ "fullName": "启用", "id": "1" }, { "fullName": "停用", "id": "2" }],
}
},
computed: {},
watch: {},
created() {
},
computed: {},
watch: {},
created() {
},
mounted() { },
methods: {
dataInfo(dataAll) {
let _dataAll = dataAll
this.dataForm = _dataAll
},
mounted() {},
methods: {
dataInfo(dataAll){
let _dataAll =dataAll
this.dataForm = _dataAll
},
init(id) {
this.dataForm.id = id || 0;
this.visible = true;
this.$nextTick(() => {
if(this.dataForm.id){
this.loading = true
request({
url: '/api/example/Supplier/detail/'+this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
})
}
init(id) {
this.dataForm.id = id || 0;
this.visible = true;
this.$nextTick(() => {
if (this.dataForm.id) {
this.loading = true
request({
url: '/api/example/Supplier/detail/' + this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
})
}
})
},
})
},
}
},
}
</script>

@ -1,393 +1,363 @@
<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="1000px">
<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="supplierCode" >
<el-input v-model="dataForm.supplierCode"
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="1000px">
<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="supplierCode">
<el-input v-model="dataForm.supplierCode" placeholder="请输入供应商编码" clearable
:style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="所属公司"
prop="companyId" >
<popupSelect v-model="dataForm.companyId"
placeholder="请选择" clearable field="companyId" interfaceId="394016341591396805" :columnOptions="companyIdcolumnOptions" propsValue="F_Id" relationField="F_FullName" popupType="dialog"
popupTitle="选择数据" popupWidth="800px"
>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="所属公司" prop="companyId">
<popupSelect v-model="dataForm.companyId" placeholder="请选择" clearable field="companyId"
interfaceId="394016341591396805" :columnOptions="companyIdcolumnOptions" propsValue="F_Id"
relationField="F_FullName" popupType="dialog" popupTitle="选择数据" popupWidth="800px">
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商名称"
prop="supplierName" >
<el-input v-model="dataForm.supplierName"
placeholder="请输入供应商名称" clearable :style='{"width":"100%"}'>
</popupSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商名称" prop="supplierName">
<el-input v-model="dataForm.supplierName" placeholder="请输入供应商名称" clearable
:style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="国家"
prop="country" >
<el-input v-model="dataForm.country"
placeholder="请输入国家" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="国家" prop="country">
<el-input v-model="dataForm.country" placeholder="请输入国家" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供货指标"
prop="supply" >
<el-input v-model="dataForm.supply"
placeholder="请输入供货指标" clearable :style='{"width":"100%"}'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供货指标" prop="supply">
<el-input v-model="dataForm.supply" placeholder="请输入供货指标" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="省"
prop="province" >
<JNPF-Address v-model="dataForm.province"
placeholder="请选择省市区" clearable :level=2 >
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="省" prop="province">
<JNPF-Address v-model="dataForm.province" placeholder="请选择省市区" clearable :level=2>
</JNPF-Address>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="联系人"
prop="contactName" >
<el-input v-model="dataForm.contactName"
placeholder="请输入联系人" clearable :style='{"width":"100%"}'>
</JNPF-Address>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系人" prop="contactName">
<el-input v-model="dataForm.contactName" placeholder="请输入联系人" clearable
:style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商等级"
prop="supplierLevel" >
<el-select v-model="dataForm.supplierLevel"
placeholder="请选择" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in supplierLevelOptions" :key="index" :label="item.fullName" :value="item.id" :disabled="item.disabled" ></el-option>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商等级" prop="supplierLevel">
<el-select v-model="dataForm.supplierLevel" placeholder="请选择" clearable
:style='{ "width": "100%" }'>
<el-option v-for="(item, index) in supplierLevelOptions" :key="index" :label="item.fullName"
:value="item.id" :disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="联系电话"
prop="contactPhone" >
<el-input v-model="dataForm.contactPhone"
placeholder="请输入联系电话" clearable :style='{"width":"100%"}'>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系电话" prop="contactPhone">
<el-input v-model="dataForm.contactPhone" placeholder="请输入联系电话" clearable
:style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商性质"
prop="enterprise" >
<el-radio-group v-model="dataForm.enterprise"
size="small" >
<el-radio v-for="(item, index) in enterpriseOptions" :key="index" :label="item.id" :disabled="item.disabled" >
{{item.fullName}}
</el-radio>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商性质" prop="enterprise">
<el-radio-group v-model="dataForm.enterprise" size="small">
<el-radio v-for="(item, index) in enterpriseOptions" :key="index" :label="item.id"
:disabled="item.disabled">
{{ item.fullName }}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="地址"
prop="address" >
<el-input v-model="dataForm.address"
placeholder="请输入地址" clearable :style='{"width":"100%"}'>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="地址" prop="address">
<el-input v-model="dataForm.address" placeholder="请输入地址" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="供应商类型"
prop="classification" >
<el-radio-group v-model="dataForm.classification"
size="small" >
<el-radio v-for="(item, index) in classificationOptions" :key="index" :label="item.id" :disabled="item.disabled" >
{{item.fullName}}
</el-radio>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="供应商类型" prop="classification">
<el-radio-group v-model="dataForm.classification" size="small">
<el-radio v-for="(item, index) in classificationOptions" :key="index" :label="item.id"
:disabled="item.disabled">
{{ item.fullName }}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="开户行"
prop="bank" >
<el-input v-model="dataForm.bank"
placeholder="请输入开户行" clearable :style='{"width":"100%"}'>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<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="12" >
<el-form-item label="默认税码"
prop="taxCode" >
<el-select v-model="dataForm.taxCode"
placeholder="请选择税码" clearable :style='{"width":"100%"}'>
<el-option v-for="(item, index) in taxCodeOptions" :key="index" :label="item.fullName" :value="item.id" :disabled="item.disabled" ></el-option>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="默认税码" prop="taxCode">
<el-select v-model="dataForm.taxCode" placeholder="请选择税码" clearable :style='{ "width": "100%" }'>
<el-option v-for="(item, index) in taxCodeOptions" :key="index" :label="item.fullName"
:value="item.id" :disabled="item.disabled"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="纳税编号"
prop="vatRegistrationNum" >
<el-input v-model="dataForm.vatRegistrationNum"
placeholder="请输入纳税编号" clearable :style='{"width":"100%"}'>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="纳税编号" prop="vatRegistrationNum">
<el-input v-model="dataForm.vatRegistrationNum" placeholder="请输入纳税编号" clearable
:style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否采购"
prop="isPurchase" >
<el-radio-group v-model="dataForm.isPurchase"
size="small" >
<el-radio v-for="(item, index) in isPurchaseOptions" :key="index" :label="item.id" :disabled="item.disabled" >
{{item.fullName}}
</el-radio>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否采购" prop="isPurchase">
<el-radio-group v-model="dataForm.isPurchase" size="small">
<el-radio v-for="(item, index) in isPurchaseOptions" :key="index" :label="item.id"
:disabled="item.disabled">
{{ item.fullName }}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="银行账户"
prop="bankAccount" >
<el-input v-model="dataForm.bankAccount"
placeholder="请输入银行账户" clearable :style='{"width":"100%"}'>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="银行账户" prop="bankAccount">
<el-input v-model="dataForm.bankAccount" placeholder="请输入银行账户" clearable
:style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否付款"
prop="isPayment" >
<el-radio-group v-model="dataForm.isPayment"
size="small" >
<el-radio v-for="(item, index) in isPaymentOptions" :key="index" :label="item.id" :disabled="item.disabled" >
{{item.fullName}}
</el-radio>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否付款" prop="isPayment">
<el-radio-group v-model="dataForm.isPayment" size="small">
<el-radio v-for="(item, index) in isPaymentOptions" :key="index" :label="item.id"
:disabled="item.disabled">
{{ item.fullName }}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="应付科目"
prop="payable" >
<el-input v-model="dataForm.payable"
placeholder="请输入应付科目" clearable :style='{"width":"100%"}'>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="应付科目" prop="payable">
<el-input v-model="dataForm.payable" placeholder="请输入应付科目" clearable :style='{ "width": "100%" }'>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="是否启用"
prop="status" >
<el-radio-group v-model="dataForm.status"
size="small" >
<el-radio v-for="(item, index) in statusOptions" :key="index" :label="item.id" :disabled="item.disabled" >
{{item.fullName}}
</el-radio>
</el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否启用" prop="status">
<el-radio-group v-model="dataForm.status" size="small">
<el-radio v-for="(item, index) in statusOptions" :key="index" :label="item.id"
:disabled="item.disabled">
{{ item.fullName }}
</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12" >
<el-form-item label="预付科目"
prop="prepaid" >
<el-input v-model="dataForm.prepaid"
placeholder="请输入预付科目" clearable :style='{"width":"100%"}'>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="预付科目" prop="prepaid">
<el-input v-model="dataForm.prepaid" 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-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 {
components: {},
props: [],
data() {
return {
visible: false,
loading: false,
isDetail: false,
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: {
supplierCode : '',
companyId : "",
supplierName : '',
country : "CHINA",
supply : '',
province : [],
contactName : '',
supplierLevel : "1",
contactPhone : '',
enterprise : "0",
address : '',
classification : "0",
bank : '',
taxCode : "0",
vatRegistrationNum : '',
isPurchase : "0",
bankAccount : '',
isPayment : "0",
payable : '',
status : "1",
prepaid : '',
supplierSiteCode : '',
creatorTime : "",
lastModifyTime : "",
supplierCode: '',
companyId: "",
supplierName: '',
country: "CHINA",
supply: '',
province: [],
contactName: '',
supplierLevel: "1",
contactPhone: '',
enterprise: "0",
address: '',
classification: "0",
bank: '',
taxCode: "0",
vatRegistrationNum: '',
isPurchase: "0",
bankAccount: '',
isPayment: "0",
payable: '',
status: "1",
prepaid: '',
supplierSiteCode: '',
creatorTime: "",
lastModifyTime: "",
},
rules:
{
supplierCode: [
{
required: true,
message: '请输入供应商编码',
trigger: 'blur'
},
],
supplierName: [
{
required: true,
message: '请输入供应商名称',
trigger: 'blur'
},
],
supply: [
],
contactPhone: [
],
bankAccount: [
],
supplierCode: [
{
required: true,
message: '请输入供应商编码',
trigger: 'blur'
},
],
supplierName: [
{
required: true,
message: '请输入供应商名称',
trigger: 'blur'
},
],
supply: [
],
contactPhone: [
],
bankAccount: [
],
},
companyIdcolumnOptions:[ {"label":"公司编码","value":"F_EnCode"}, {"label":"公司名称","value":"F_FullName"},],
supplierLevelOptions:[{"fullName":"一级","id":"1"},{"fullName":"二级","id":"2"},{"fullName":"三级","id":"3"},{"fullName":"四级","id":"4"}],
enterpriseOptions:[{"fullName":"民营","id":"0"},{"fullName":"私营","id":"1"}],
classificationOptions:[{"fullName":"国内","id":"0"},{"fullName":"国外","id":"1"}],
taxCodeOptions:[{"fullName":"13个点","id":"0"},{"fullName":"9个点","id":"1"},{"fullName":"6个点","id":"2"},{"fullName":"5个点","id":"3"}],
isPurchaseOptions:[{"fullName":"否","id":"0"},{"fullName":"是","id":"1"}],
isPaymentOptions:[{"fullName":"否","id":"0"},{"fullName":"是","id":"1"}],
statusOptions:[{"fullName":"启用","id":"1"},{"fullName":"停用","id":"2"}],
companyIdcolumnOptions: [{ "label": "公司编码", "value": "F_EnCode" }, { "label": "公司名称", "value": "F_FullName" },],
supplierLevelOptions: [{ "fullName": "一级", "id": "1" }, { "fullName": "二级", "id": "2" }, { "fullName": "三级", "id": "3" }, { "fullName": "四级", "id": "4" }],
enterpriseOptions: [{ 'fullName': '民营', 'id': '0' }, { 'fullName': '国有', 'id': '1' }, { 'fullName': '其它', 'id': '2' }],
classificationOptions: [{ "fullName": "国内", "id": "0" }, { "fullName": "国外", "id": "1" }],
taxCodeOptions: [{ "fullName": "13", "id": "0" }, { "fullName": "9", "id": "1" }, { "fullName": "6", "id": "2" }, { "fullName": "5", "id": "3" }, { "fullName": "3", "id": "4" }, { "fullName": "0", "id": "5" }],
isPurchaseOptions: [{ "fullName": "否", "id": "0" }, { "fullName": "是", "id": "1" }],
isPaymentOptions: [{ "fullName": "否", "id": "0" }, { "fullName": "是", "id": "1" }],
statusOptions: [{ "fullName": "启用", "id": "1" }, { "fullName": "停用", "id": "2" }],
}
},
computed: {},
watch: {},
created() {
},
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] = "";
}
}
},
computed: {},
watch: {},
created() {
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/Supplier/' + 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', {})
},
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] = "";
}
//
dataFormSubmit() {
this.$refs['elForm'].validate((valid) => {
if (valid) {
this.request()
}
},
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/Supplier/'+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/Supplier',
method: 'post',
data: _data
}).then((res) => {
this.$message({
message: res.msg,
type: 'success',
duration: 1000,
onClose: () => {
this.visible = false
this.$emit('refresh', true)
}
})
})
},
request() {
var _data = this.dataList()
if (!this.dataForm.id) {
request({
url: '/api/example/Supplier',
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/Supplier/'+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)
}
})
})
} else {
request({
url: '/api/example/Supplier/' + 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.province = JSON.stringify(_data.province)
return _data;
},
dataInfo(dataAll){
let _dataAll =dataAll
_dataAll.province = JSON.parse( _dataAll.province)
this.dataForm = _dataAll
},
})
}
},
dataList() {
var _data = JSON.parse(JSON.stringify(this.dataForm));
_data.province = JSON.stringify(_data.province)
return _data;
},
dataInfo(dataAll) {
let _dataAll = dataAll
_dataAll.province = JSON.parse(_dataAll.province)
this.dataForm = _dataAll
},
}
},
}
</script>

@ -35,10 +35,10 @@
<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 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 type="text" icon="el-icon-arrow-up" @click="showAll = false" v-else>
收起
</el-button>
</el-form-item>
@ -48,40 +48,34 @@
<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="primary" v-has="'btn_add'" icon="el-icon-plus" @click="addOrUpdateHandle()">-->
<!-- </el-button>-->
<el-button type="text" v-has="'btn_download'" icon="el-icon-download" @click="exportData()">
</el-button>
<!-- <el-button type="text" v-has="'btn_upload'" icon="el-icon-download" @click="">-->
<!-- </el-button>-->
<!-- <el-button type="text" v-has="'btn_batchRemove'" icon="el-icon-delete" @click="handleBatchRemoveDel()">-->
<!-- </el-button>-->
<!-- <el-button type="text" v-has="'btn_upload'" icon="el-icon-download" @click="">-->
<!-- </el-button>-->
<!-- <el-button type="text" v-has="'btn_batchRemove'" icon="el-icon-delete" @click="handleBatchRemoveDel()">-->
<!-- </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-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false" @click="reset()" />
</el-tooltip>
<screenfull isContainer/>
<screenfull isContainer />
</div>
</div>
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' has-c :hasNO="false"
@selection-change="handleSelectionChange" border>
@selection-change="handleSelectionChange" border>
<el-table-column type="index" width="50" label="序号" fixed="left" align="center" />
<el-table-column prop="supplierCode" label="供应商编码" width="200" align="center" fixed="left" sortable
sortable="custom"/>
<el-table-column prop="companyId" label="所属公司" width="200" align="center" fixed="left" sortable
sortable="custom"/>
<el-table-column prop="supplierName" label="供应商名称" width="200" align="center" sortable
sortable="custom"/>
<el-table-column prop="country" label="国家" width="120" align="center" sortable
/>
<el-table-column prop="supply" label="供货指标" width="120" align="center" sortable
/>
<el-table-column prop="province" label="省" width="120" align="center" sortable
/>
<el-table-column prop="contactName" label="联系人" width="120" align="center" sortable
sortable="custom"/>
<el-table-column prop="supplierCode" label="供应商编码" width="200" align="center" fixed="left" sortable
sortable="custom" />
<el-table-column prop="companyId" label="所属公司" width="200" align="center" fixed="left" sortable
sortable="custom" />
<el-table-column prop="supplierName" label="供应商名称" width="200" align="center" sortable sortable="custom" />
<el-table-column prop="country" label="国家" width="120" align="center" sortable />
<el-table-column prop="supply" label="供货指标" width="120" align="center" sortable />
<el-table-column prop="province" label="省" width="120" align="center" sortable />
<el-table-column prop="contactName" label="联系人" width="120" align="center" sortable sortable="custom" />
<el-table-column label="供应商等级" width="120" sortable prop="supplierLevel" align="center">
<template slot-scope="scope">
@ -89,8 +83,7 @@
</template>
</el-table-column>
<el-table-column prop="contactPhone" label="联系电话" width="200" align="center" sortable
sortable="custom"/>
<el-table-column prop="contactPhone" label="联系电话" width="200" align="center" sortable sortable="custom" />
<el-table-column label="供应商性质" width="120" sortable prop="enterprise" align="center">
@ -100,8 +93,7 @@
</el-table-column>
<el-table-column prop="address" label="地址" width="200" align="center" sortable
sortable="custom"/>
<el-table-column prop="address" label="地址" width="200" align="center" sortable sortable="custom" />
<el-table-column label="供应商类型" width="120" sortable prop="classification" align="center">
@ -110,12 +102,9 @@
</template>
</el-table-column>
<el-table-column prop="bank" label="开户行" width="200" align="center" sortable
/>
<el-table-column prop="vatRegistrationNum" label="纳税编号" width="200" align="center" sortable
/>
<el-table-column prop="bankAccount" label="银行账户" width="200" align="center" sortable
/>
<el-table-column prop="bank" label="开户行" width="200" align="center" sortable />
<el-table-column prop="vatRegistrationNum" label="纳税编号" width="200" align="center" sortable />
<el-table-column prop="bankAccount" label="银行账户" width="200" align="center" sortable />
<el-table-column label="默认税码" width="120" sortable prop="taxCode" align="center">
<template slot-scope="scope">
@ -123,8 +112,7 @@
</template>
</el-table-column>
<el-table-column prop="payable" label="应付科目" width="120" align="center" sortable
/>
<el-table-column prop="payable" label="应付科目" width="120" align="center" sortable />
<el-table-column label="是否采购" width="120" sortable prop="isPurchase" align="center">
<template slot-scope="scope">
@ -132,8 +120,7 @@
</template>
</el-table-column>
<el-table-column prop="prepaid" label="预付科目" width="120" align="center" sortable
/>
<el-table-column prop="prepaid" label="预付科目" width="120" align="center" sortable />
<el-table-column label="是否付款" width="120" sortable prop="isPayment" align="center">
@ -148,254 +135,248 @@
</template>
</el-table-column>
<el-table-column prop="supplierSiteCode" label="供应商地点" width="120" align="center" sortable
sortable="custom"/>
<el-table-column label="操作" fixed="right"
width="80">
<el-table-column prop="supplierSiteCode" label="供应商地点" width="120" align="center" sortable sortable="custom" />
<el-table-column label="操作" fixed="right" width="80">
<template slot-scope="scope">
<!-- <el-button type="text" v-has="'btn_edit'"-->
<!-- @click="addOrUpdateHandle(scope.row.id)">编辑-->
<!-- </el-button>-->
<!-- <el-button type="text" v-has="'btn_remove'" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">-->
<!-- </el-button>-->
<!-- <el-button type="text" v-has="'btn_edit'"-->
<!-- @click="addOrUpdateHandle(scope.row.id)">编辑-->
<!-- </el-button>-->
<!-- <el-button type="text" v-has="'btn_remove'" class="JNPF-table-delBtn" @click="handleDel(scope.row.id)">-->
<!-- </el-button>-->
<el-button type="text"
@click="goDetail(scope.row.id)">详情
<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"/>
@pagination="initData" />
</div>
</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"/>
<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 {
components: { JNPFForm, ExportBox, Detail },
data() {
return {
showAll: false,
detailVisible: false,
query: {
supplierCode: undefined,
supplierName: undefined,
contactName: undefined,
contactPhone: undefined,
supplierSiteCode: 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: 'supplierCode', label: '供应商编码' },
{ prop: 'companyId', label: '所属公司' },
{ prop: 'supplierName', label: '供应商名称' },
{ prop: 'country', label: '国家' },
{ prop: 'supply', label: '供货指标' },
{ prop: 'province', label: '省' },
{ prop: 'contactName', label: '联系人' },
{ prop: 'supplierLevel', label: '供应商等级' },
{ prop: 'contactPhone', label: '联系电话' },
{ prop: 'enterprise', label: '供应商性质' },
{ prop: 'address', label: '地址' },
{ prop: 'classification', label: '供应商类型' },
{ prop: 'bank', label: '开户行' },
{ prop: 'vatRegistrationNum', label: '纳税编号' },
{ prop: 'bankAccount', label: '银行账户' },
{ prop: 'taxCode', label: '默认税码' },
{ prop: 'payable', label: '应付科目' },
{ prop: 'isPurchase', label: '是否采购' },
{ prop: 'prepaid', label: '预付科目' },
{ prop: 'isPayment', label: '是否付款' },
{ prop: 'status', label: '是否启用' },
{ prop: 'supplierSiteCode', label: '供应商地点' }
],
supplierLevelOptions: [{ 'fullName': '一级', 'id': '1' }, { 'fullName': '二级', 'id': '2' }, {
'fullName': '三级',
'id': '3'
}, { 'fullName': '四级', 'id': '4' }],
supplierLevelProps: { 'label': 'fullName', 'value': 'id' },
enterpriseOptions: [{ 'fullName': '民营', 'id': '0' }, { 'fullName': '私营', 'id': '1' }],
enterpriseProps: { 'label': 'fullName', 'value': 'id' },
classificationOptions: [{ 'fullName': '国内', 'id': '0' }, { 'fullName': '国外', 'id': '1' }],
classificationProps: { 'label': 'fullName', 'value': 'id' },
taxCodeOptions: [{ 'fullName': '13个点', 'id': '0' }, { 'fullName': '9个点', 'id': '1' }, {
'fullName': '6个点',
'id': '2'
}, { 'fullName': '5个点', 'id': '3' }],
taxCodeProps: { 'label': 'fullName', 'value': 'id' },
isPurchaseOptions: [{ 'fullName': '否', 'id': '0' }, { 'fullName': '是', 'id': '1' }],
isPurchaseProps: { 'label': 'fullName', 'value': 'id' },
isPaymentOptions: [{ 'fullName': '否', 'id': '0' }, { 'fullName': '是', 'id': '1' }],
isPaymentProps: { 'label': 'fullName', 'value': 'id' },
statusOptions: [{ 'fullName': '启用', 'id': '1' }, { 'fullName': '停用', 'id': '2' }],
statusProps: { 'label': 'fullName', 'value': 'id' }
}
},
computed: {
menuId() {
return this.$route.meta.modelId || ''
}
export default {
components: { JNPFForm, ExportBox, Detail },
data() {
return {
showAll: false,
detailVisible: false,
query: {
supplierCode: undefined,
supplierName: undefined,
contactName: undefined,
contactPhone: undefined,
supplierSiteCode: 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: 'supplierCode', label: '供应商编码' },
{ prop: 'companyId', label: '所属公司' },
{ prop: 'supplierName', label: '供应商名称' },
{ prop: 'country', label: '国家' },
{ prop: 'supply', label: '供货指标' },
{ prop: 'province', label: '省' },
{ prop: 'contactName', label: '联系人' },
{ prop: 'supplierLevel', label: '供应商等级' },
{ prop: 'contactPhone', label: '联系电话' },
{ prop: 'enterprise', label: '供应商性质' },
{ prop: 'address', label: '地址' },
{ prop: 'classification', label: '供应商类型' },
{ prop: 'bank', label: '开户行' },
{ prop: 'vatRegistrationNum', label: '纳税编号' },
{ prop: 'bankAccount', label: '银行账户' },
{ prop: 'taxCode', label: '默认税码' },
{ prop: 'payable', label: '应付科目' },
{ prop: 'isPurchase', label: '是否采购' },
{ prop: 'prepaid', label: '预付科目' },
{ prop: 'isPayment', label: '是否付款' },
{ prop: 'status', label: '是否启用' },
{ prop: 'supplierSiteCode', label: '供应商地点' }
],
supplierLevelOptions: [{ 'fullName': '一级', 'id': '1' }, { 'fullName': '二级', 'id': '2' }, {
'fullName': '三级',
'id': '3'
}, { 'fullName': '四级', 'id': '4' }],
supplierLevelProps: { 'label': 'fullName', 'value': 'id' },
enterpriseOptions: [{ 'fullName': '民营', 'id': '0' }, { 'fullName': '国有', 'id': '1' }, { 'fullName': '其它', 'id': '2' }],
enterpriseProps: { 'label': 'fullName', 'value': 'id' },
classificationOptions: [{ 'fullName': '国内', 'id': '0' }, { 'fullName': '国外', 'id': '1' }],
classificationProps: { 'label': 'fullName', 'value': 'id' },
taxCodeOptions: [{ "fullName": "13", "id": "0" }, { "fullName": "9", "id": "1" }, { "fullName": "6", "id": "2" }, { "fullName": "5", "id": "3" }, { "fullName": "3", "id": "4" }, { "fullName": "0", "id": "5" }],
taxCodeProps: { 'label': 'fullName', 'value': 'id' },
isPurchaseOptions: [{ 'fullName': '否', 'id': '0' }, { 'fullName': '是', 'id': '1' }],
isPurchaseProps: { 'label': 'fullName', 'value': 'id' },
isPaymentOptions: [{ 'fullName': '否', 'id': '0' }, { 'fullName': '是', 'id': '1' }],
isPaymentProps: { 'label': 'fullName', 'value': 'id' },
statusOptions: [{ 'fullName': '启用', 'id': '1' }, { 'fullName': '停用', 'id': '2' }],
statusProps: { 'label': 'fullName', 'value': 'id' }
}
},
computed: {
menuId() {
return this.$route.meta.modelId || ''
}
},
created() {
this.initData()
},
methods: {
goDetail(id) {
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(id)
})
},
created() {
sortChange({ column, prop, order }) {
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
this.listQuery.sidx = !order ? '' : prop
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
initData() {
this.listLoading = true
let _query = {
...this.listQuery,
...this.query,
menuId: this.menuId
}
request({
url: `/api/example/Supplier/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
this.listLoading = false
})
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Supplier/getList`,
method: 'post',
data: _query
url: `/api/example/Supplier/${id}`,
method: 'DELETE'
}).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
this.listLoading = false
})
},
handleDel(id) {
this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Supplier/${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/Supplier/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
})
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
})
}).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)
}).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
})
},
download(data) {
let query = { ...data, ...this.listQuery, ...this.query, menuId: this.menuId }
return
}
const ids = this.multipleSelection.join()
this.$confirm('您确定要删除这些数据吗, 是否继续?', '提示', {
type: 'warning'
}).then(() => {
request({
url: `/api/example/Supplier/Actions/Export`,
method: 'GET',
data: query
url: `/api/example/Supplier/batchRemove/${ids}`,
method: 'DELETE'
}).then(res => {
if (!res.data.url) return
this.jnpf.downloadFile(res.data.url)
this.$refs.ExportBox.visible = false
this.exportBoxVisible = false
this.$message({
type: 'success',
message: res.msg,
onClose: () => {
this.initData()
}
})
})
},
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()
}).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/Supplier/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()
}
}
}
</script>

Loading…
Cancel
Save