投递配置优化

master
guochaojie 4 months ago
parent 222b88e360
commit 79c6fc34e0

@ -70,10 +70,10 @@ spring:
# redis单机模式
redis:
database: 0 #缓存库编号
host: 222.71.165.187
# host: 127.0.0.1
# host: 222.71.165.187
host: 127.0.0.1
port: 6379
password: qawsed,.123 # 密码为空时,请将本行注释
# password: qawsed,.123 # 密码为空时,请将本行注释
timeout: 3000 #超时时间(单位:秒)
lettuce: #Lettuce为Redis的Java驱动包
pool:
@ -211,7 +211,7 @@ xxl:
max: 100
# xxl-job服务端地址
admin:
addresses: http://127.0.0.1:30020/xxl-job-admin/
addresses: http://192.168.0.23:9999/xxl-job-admin/
executor:
address: ''
appname: xxl-job-executor-sample1

@ -5,11 +5,11 @@ import jnpf.entity.RecycleBucketEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* RecycleBucket
*
* V3.5
* https://www.jnpfsoft.com
* JNPF
* 2024-05-29
* 2024-06-17
*/
public interface RecycleBucketMapper extends BaseMapper<RecycleBucketEntity> {

@ -1,16 +1,16 @@
package jnpf.mapper;
import jnpf.entity.RecycleDeviceConfigeEntity;
import jnpf.entity.RecycleDeviceConfigEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
*
*
* V3.5
* https://www.jnpfsoft.com
* JNPF
* 2024-05-31
* 2024-06-17
*/
public interface RecycleDeviceConfigeMapper extends BaseMapper<RecycleDeviceConfigeEntity> {
public interface RecycleDeviceConfigMapper extends BaseMapper<RecycleDeviceConfigEntity> {
}

@ -2,23 +2,21 @@ package jnpf.service;
import jnpf.model.recyclebucket.*;
import jnpf.entity.*;
import java.util.*;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
/**
* RecycleBucket
*
* V3.5
* https://www.jnpfsoft.com
* JNPF
* 2024-05-29
* 2024-06-17
*/
public interface RecycleBucketService extends IService<RecycleBucketEntity> {
List<RecycleBucketEntity> getList(RecycleBucketPagination recycleBucketPagination);
List<RecycleBucketEntity> getTypeList(RecycleBucketPagination recycleBucketPagination, String dataType);
List<RecycleBucketEntity> getTypeList(RecycleBucketPagination recycleBucketPagination,String dataType);
RecycleBucketEntity getInfo(String id);
@ -30,9 +28,8 @@ public interface RecycleBucketService extends IService<RecycleBucketEntity> {
//子表方法
//副表数据方法
String checkForm(RecycleBucketForm form, int i);
String checkForm(RecycleBucketForm form,int i);
void saveOrUpdate(RecycleBucketForm recycleBucketForm, String id, boolean isSave) throws Exception;
void saveOrUpdate(RecycleBucketForm recycleBucketForm,String id, boolean isSave) throws Exception;
List<RecycleBucketEntity> getList(RecycleBucketEntity entity);
}

@ -0,0 +1,35 @@
package jnpf.service;
import jnpf.model.recycledeviceconfig.*;
import jnpf.entity.*;
import java.util.*;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
/**
*
* V3.5
* https://www.jnpfsoft.com
* JNPF
* 2024-06-17
*/
public interface RecycleDeviceConfigService extends IService<RecycleDeviceConfigEntity> {
List<RecycleDeviceConfigEntity> getList(RecycleDeviceConfigPagination recycleDeviceConfigPagination);
List<RecycleDeviceConfigEntity> getTypeList(RecycleDeviceConfigPagination recycleDeviceConfigPagination,String dataType);
RecycleDeviceConfigEntity getInfo(String id);
void delete(RecycleDeviceConfigEntity entity);
void create(RecycleDeviceConfigEntity entity);
boolean update(String id, RecycleDeviceConfigEntity entity);
//子表方法
//副表数据方法
String checkForm(RecycleDeviceConfigForm form,int i);
void saveOrUpdate(RecycleDeviceConfigForm recycleDeviceConfigForm,String id, boolean isSave) throws Exception;
}

@ -1,35 +0,0 @@
package jnpf.service;
import jnpf.model.recycledeviceconfige.*;
import jnpf.entity.*;
import java.util.*;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
/**
*
* V3.5
* https://www.jnpfsoft.com
* JNPF
* 2024-05-31
*/
public interface RecycleDeviceConfigeService extends IService<RecycleDeviceConfigeEntity> {
List<RecycleDeviceConfigeEntity> getList(RecycleDeviceConfigePagination recycleDeviceConfigePagination);
List<RecycleDeviceConfigeEntity> getTypeList(RecycleDeviceConfigePagination recycleDeviceConfigePagination,String dataType);
RecycleDeviceConfigeEntity getInfo(String id);
void delete(RecycleDeviceConfigeEntity entity);
void create(RecycleDeviceConfigeEntity entity);
boolean update(String id, RecycleDeviceConfigeEntity entity);
//子表方法
//副表数据方法
String checkForm(RecycleDeviceConfigeForm form,int i);
void saveOrUpdate(RecycleDeviceConfigeForm recycleDeviceConfigeForm,String id, boolean isSave) throws Exception;
}

@ -32,11 +32,11 @@ import jnpf.base.UserInfo;
import jnpf.permission.entity.UserEntity;
/**
*
* RecycleBucket
*
* V3.5
* https://www.jnpfsoft.com
* JNPF
* 2024-05-29
* 2024-06-17
*/
@Service
public class RecycleBucketServiceImpl extends ServiceImpl<RecycleBucketMapper, RecycleBucketEntity> implements RecycleBucketService{
@ -305,12 +305,4 @@ public class RecycleBucketServiceImpl extends ServiceImpl<RecycleBucketMapper, R
this.saveOrUpdate(entity);
}
@Override
public List<RecycleBucketEntity> getList(RecycleBucketEntity entity) {
QueryWrapper<RecycleBucketEntity> wrapper = new QueryWrapper<>();
wrapper.eq(StringUtil.isNotEmpty(entity.getDeviceCode()), "device_code", entity.getDeviceCode());
wrapper.eq(StringUtil.isNotEmpty(entity.getBucketCode()), "bucket_code", entity.getBucketCode());
return this.list(wrapper);
}
}

@ -1,10 +1,10 @@
package jnpf.service.impl;
import jnpf.entity.*;
import jnpf.mapper.RecycleDeviceConfigeMapper;
import jnpf.mapper.RecycleDeviceConfigMapper;
import jnpf.service.*;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import jnpf.model.recycledeviceconfige.*;
import jnpf.model.recycledeviceconfig.*;
import java.math.BigDecimal;
import cn.hutool.core.util.ObjectUtil;
import jnpf.permission.model.authorize.AuthorizeConditionModel;
@ -32,14 +32,14 @@ import jnpf.base.UserInfo;
import jnpf.permission.entity.UserEntity;
/**
*
*
*
* V3.5
* https://www.jnpfsoft.com
* JNPF
* 2024-05-31
* 2024-06-17
*/
@Service
public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceConfigeMapper, RecycleDeviceConfigeEntity> implements RecycleDeviceConfigeService{
public class RecycleDeviceConfigServiceImpl extends ServiceImpl<RecycleDeviceConfigMapper, RecycleDeviceConfigEntity> implements RecycleDeviceConfigService{
@Autowired
private GeneraterSwapUtil generaterSwapUtil;
@ -47,38 +47,38 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
private UserProvider userProvider;
@Override
public List<RecycleDeviceConfigeEntity> getList(RecycleDeviceConfigePagination recycleDeviceConfigePagination){
return getTypeList(recycleDeviceConfigePagination,recycleDeviceConfigePagination.getDataType());
public List<RecycleDeviceConfigEntity> getList(RecycleDeviceConfigPagination recycleDeviceConfigPagination){
return getTypeList(recycleDeviceConfigPagination,recycleDeviceConfigPagination.getDataType());
}
/** 列表查询 */
@Override
public List<RecycleDeviceConfigeEntity> getTypeList(RecycleDeviceConfigePagination recycleDeviceConfigePagination,String dataType){
public List<RecycleDeviceConfigEntity> getTypeList(RecycleDeviceConfigPagination recycleDeviceConfigPagination,String dataType){
String userId=userProvider.get().getUserId();
List<String> AllIdList =new ArrayList();
List<List<String>> intersectionList =new ArrayList<>();
boolean isPc = ServletUtil.getHeader("jnpf-origin").equals("pc");
String columnData = !isPc ? RecycleDeviceConfigeConstant.getAppColumnData() : RecycleDeviceConfigeConstant.getColumnData();
String columnData = !isPc ? RecycleDeviceConfigConstant.getAppColumnData() : RecycleDeviceConfigConstant.getColumnData();
ColumnDataModel columnDataModel = JsonUtil.getJsonToBean(columnData, ColumnDataModel.class);
String ruleJson = !isPc ? JsonUtil.getObjectToString(columnDataModel.getRuleListApp()) : JsonUtil.getObjectToString(columnDataModel.getRuleList());
int total=0;
int recycleDeviceConfigeNum =0;
QueryWrapper<RecycleDeviceConfigeEntity> recycleDeviceConfigeQueryWrapper=new QueryWrapper<>();
int recycleDeviceConfigNum =0;
QueryWrapper<RecycleDeviceConfigEntity> recycleDeviceConfigQueryWrapper=new QueryWrapper<>();
List<String> allSuperIDlist = new ArrayList<>();
String superOp ="";
if (ObjectUtil.isNotEmpty(recycleDeviceConfigePagination.getSuperQueryJson())){
if (ObjectUtil.isNotEmpty(recycleDeviceConfigPagination.getSuperQueryJson())){
List<String> allSuperList = new ArrayList<>();
List<List<String>> intersectionSuperList = new ArrayList<>();
String queryJson = recycleDeviceConfigePagination.getSuperQueryJson();
String queryJson = recycleDeviceConfigPagination.getSuperQueryJson();
SuperJsonModel superJsonModel = JsonUtil.getJsonToBean(queryJson, SuperJsonModel.class);
int superNum = 0;
QueryWrapper<RecycleDeviceConfigeEntity> recycleDeviceConfigeSuperWrapper = new QueryWrapper<>();
recycleDeviceConfigeSuperWrapper = generaterSwapUtil.getCondition(new QueryModel(recycleDeviceConfigeSuperWrapper,RecycleDeviceConfigeEntity.class,queryJson,"0"));
int recycleDeviceConfigeNum1 = recycleDeviceConfigeSuperWrapper.getExpression().getNormal().size();
if (recycleDeviceConfigeNum1>0){
List<String> recycleDeviceConfigeList =this.list(recycleDeviceConfigeSuperWrapper).stream().map(RecycleDeviceConfigeEntity::getId).collect(Collectors.toList());
allSuperList.addAll(recycleDeviceConfigeList);
intersectionSuperList.add(recycleDeviceConfigeList);
QueryWrapper<RecycleDeviceConfigEntity> recycleDeviceConfigSuperWrapper = new QueryWrapper<>();
recycleDeviceConfigSuperWrapper = generaterSwapUtil.getCondition(new QueryModel(recycleDeviceConfigSuperWrapper,RecycleDeviceConfigEntity.class,queryJson,"0"));
int recycleDeviceConfigNum1 = recycleDeviceConfigSuperWrapper.getExpression().getNormal().size();
if (recycleDeviceConfigNum1>0){
List<String> recycleDeviceConfigList =this.list(recycleDeviceConfigSuperWrapper).stream().map(RecycleDeviceConfigEntity::getId).collect(Collectors.toList());
allSuperList.addAll(recycleDeviceConfigList);
intersectionSuperList.add(recycleDeviceConfigList);
superNum++;
}
superOp = superNum > 0 ? superJsonModel.getMatchLogic() : "";
@ -96,13 +96,13 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
List<List<String>> intersectionRuleList = new ArrayList<>();
SuperJsonModel ruleJsonModel = JsonUtil.getJsonToBean(ruleJson, SuperJsonModel.class);
int ruleNum = 0;
QueryWrapper<RecycleDeviceConfigeEntity> recycleDeviceConfigeSuperWrapper = new QueryWrapper<>();
recycleDeviceConfigeSuperWrapper = generaterSwapUtil.getCondition(new QueryModel(recycleDeviceConfigeSuperWrapper,RecycleDeviceConfigeEntity.class,ruleJson,"0"));
int recycleDeviceConfigeNum1 = recycleDeviceConfigeSuperWrapper.getExpression().getNormal().size();
if (recycleDeviceConfigeNum1>0){
List<String> recycleDeviceConfigeList =this.list(recycleDeviceConfigeSuperWrapper).stream().map(RecycleDeviceConfigeEntity::getId).collect(Collectors.toList());
allRuleList.addAll(recycleDeviceConfigeList);
intersectionRuleList.add(recycleDeviceConfigeList);
QueryWrapper<RecycleDeviceConfigEntity> recycleDeviceConfigSuperWrapper = new QueryWrapper<>();
recycleDeviceConfigSuperWrapper = generaterSwapUtil.getCondition(new QueryModel(recycleDeviceConfigSuperWrapper,RecycleDeviceConfigEntity.class,ruleJson,"0"));
int recycleDeviceConfigNum1 = recycleDeviceConfigSuperWrapper.getExpression().getNormal().size();
if (recycleDeviceConfigNum1>0){
List<String> recycleDeviceConfigList =this.list(recycleDeviceConfigSuperWrapper).stream().map(RecycleDeviceConfigEntity::getId).collect(Collectors.toList());
allRuleList.addAll(recycleDeviceConfigList);
intersectionRuleList.add(recycleDeviceConfigList);
ruleNum++;
}
ruleOp = ruleNum > 0 ? ruleJsonModel.getMatchLogic() : "";
@ -117,26 +117,26 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
boolean appPermission = false;
if(isPc && pcPermission){
if (!userProvider.get().getIsAdministrator()){
Object recycleDeviceConfigeObj=generaterSwapUtil.getAuthorizeCondition(new QueryModel(recycleDeviceConfigeQueryWrapper,RecycleDeviceConfigeEntity.class,recycleDeviceConfigePagination.getMenuId(),"0"));
if (ObjectUtil.isEmpty(recycleDeviceConfigeObj)){
Object recycleDeviceConfigObj=generaterSwapUtil.getAuthorizeCondition(new QueryModel(recycleDeviceConfigQueryWrapper,RecycleDeviceConfigEntity.class,recycleDeviceConfigPagination.getMenuId(),"0"));
if (ObjectUtil.isEmpty(recycleDeviceConfigObj)){
return new ArrayList<>();
} else {
recycleDeviceConfigeQueryWrapper = (QueryWrapper<RecycleDeviceConfigeEntity>)recycleDeviceConfigeObj;
if( recycleDeviceConfigeQueryWrapper.getExpression().getNormal().size()>0){
recycleDeviceConfigeNum++;
recycleDeviceConfigQueryWrapper = (QueryWrapper<RecycleDeviceConfigEntity>)recycleDeviceConfigObj;
if( recycleDeviceConfigQueryWrapper.getExpression().getNormal().size()>0){
recycleDeviceConfigNum++;
}
}
}
}
if(!isPc && appPermission){
if (!userProvider.get().getIsAdministrator()){
Object recycleDeviceConfigeObj=generaterSwapUtil.getAuthorizeCondition(new QueryModel(recycleDeviceConfigeQueryWrapper,RecycleDeviceConfigeEntity.class,recycleDeviceConfigePagination.getMenuId(),"0"));
if (ObjectUtil.isEmpty(recycleDeviceConfigeObj)){
Object recycleDeviceConfigObj=generaterSwapUtil.getAuthorizeCondition(new QueryModel(recycleDeviceConfigQueryWrapper,RecycleDeviceConfigEntity.class,recycleDeviceConfigPagination.getMenuId(),"0"));
if (ObjectUtil.isEmpty(recycleDeviceConfigObj)){
return new ArrayList<>();
} else {
recycleDeviceConfigeQueryWrapper = (QueryWrapper<RecycleDeviceConfigeEntity>)recycleDeviceConfigeObj;
if( recycleDeviceConfigeQueryWrapper.getExpression().getNormal().size()>0){
recycleDeviceConfigeNum++;
recycleDeviceConfigQueryWrapper = (QueryWrapper<RecycleDeviceConfigEntity>)recycleDeviceConfigObj;
if( recycleDeviceConfigQueryWrapper.getExpression().getNormal().size()>0){
recycleDeviceConfigNum++;
}
}
@ -144,12 +144,12 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
}
}
if(isPc){
if(ObjectUtil.isNotEmpty(recycleDeviceConfigePagination.getOrganizeJsonId())){
recycleDeviceConfigeNum++;
if(ObjectUtil.isNotEmpty(recycleDeviceConfigPagination.getOrganizeJsonId())){
recycleDeviceConfigNum++;
List<String> idList = new ArrayList<>();
try {
String[][] organizeJsonId = JsonUtil.getJsonToBean(recycleDeviceConfigePagination.getOrganizeJsonId(),String[][].class);
String[][] organizeJsonId = JsonUtil.getJsonToBean(recycleDeviceConfigPagination.getOrganizeJsonId(),String[][].class);
for(int i=0;i<organizeJsonId.length;i++){
if(organizeJsonId[i].length>0){
idList.add(JsonUtil.getObjectToString(Arrays.asList(organizeJsonId[i])));
@ -157,17 +157,17 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
}
}catch (Exception e1){
try {
List<String> organizeJsonId = JsonUtil.getJsonToList(recycleDeviceConfigePagination.getOrganizeJsonId(),String.class);
List<String> organizeJsonId = JsonUtil.getJsonToList(recycleDeviceConfigPagination.getOrganizeJsonId(),String.class);
if(organizeJsonId.size()>0){
idList.add(organizeJsonId.get(organizeJsonId.size()-1));
}
}catch (Exception e2){
idList.add(String.valueOf(recycleDeviceConfigePagination.getOrganizeJsonId()));
idList.add(String.valueOf(recycleDeviceConfigPagination.getOrganizeJsonId()));
}
}
recycleDeviceConfigeQueryWrapper.lambda().and(t->{
recycleDeviceConfigQueryWrapper.lambda().and(t->{
idList.forEach(tt->{
t.like(RecycleDeviceConfigeEntity::getOrganizeJsonId, tt).or();
t.like(RecycleDeviceConfigEntity::getOrganizeJsonId, tt).or();
});
});
@ -179,7 +179,7 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
if (intersection.size()==0){
intersection.add("jnpfNullList");
}
recycleDeviceConfigeQueryWrapper.lambda().in(RecycleDeviceConfigeEntity::getId, intersection);
recycleDeviceConfigQueryWrapper.lambda().in(RecycleDeviceConfigEntity::getId, intersection);
}
//是否有高级查询
if (StringUtil.isNotEmpty(superOp)){
@ -187,7 +187,7 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
allSuperIDlist.add("jnpfNullList");
}
List<String> finalAllSuperIDlist = allSuperIDlist;
recycleDeviceConfigeQueryWrapper.lambda().and(t->t.in(RecycleDeviceConfigeEntity::getId, finalAllSuperIDlist));
recycleDeviceConfigQueryWrapper.lambda().and(t->t.in(RecycleDeviceConfigEntity::getId, finalAllSuperIDlist));
}
//是否有数据过滤查询
if (StringUtil.isNotEmpty(ruleOp)){
@ -195,21 +195,21 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
allRuleIDlist.add("jnpfNullList");
}
List<String> finalAllRuleIDlist = allRuleIDlist;
recycleDeviceConfigeQueryWrapper.lambda().and(t->t.in(RecycleDeviceConfigeEntity::getId, finalAllRuleIDlist));
recycleDeviceConfigQueryWrapper.lambda().and(t->t.in(RecycleDeviceConfigEntity::getId, finalAllRuleIDlist));
}
//排序
if(StringUtil.isEmpty(recycleDeviceConfigePagination.getSidx())){
recycleDeviceConfigeQueryWrapper.lambda().orderByDesc(RecycleDeviceConfigeEntity::getId);
if(StringUtil.isEmpty(recycleDeviceConfigPagination.getSidx())){
recycleDeviceConfigQueryWrapper.lambda().orderByDesc(RecycleDeviceConfigEntity::getId);
}else{
try {
String sidx = recycleDeviceConfigePagination.getSidx();
String sidx = recycleDeviceConfigPagination.getSidx();
String[] strs= sidx.split("_name");
RecycleDeviceConfigeEntity recycleDeviceConfigeEntity = new RecycleDeviceConfigeEntity();
Field declaredField = recycleDeviceConfigeEntity.getClass().getDeclaredField(strs[0]);
RecycleDeviceConfigEntity recycleDeviceConfigEntity = new RecycleDeviceConfigEntity();
Field declaredField = recycleDeviceConfigEntity.getClass().getDeclaredField(strs[0]);
declaredField.setAccessible(true);
String value = declaredField.getAnnotation(TableField.class).value();
recycleDeviceConfigeQueryWrapper="asc".equals(recycleDeviceConfigePagination.getSort().toLowerCase())?recycleDeviceConfigeQueryWrapper.orderByAsc(value):recycleDeviceConfigeQueryWrapper.orderByDesc(value);
recycleDeviceConfigQueryWrapper="asc".equals(recycleDeviceConfigPagination.getSort().toLowerCase())?recycleDeviceConfigQueryWrapper.orderByAsc(value):recycleDeviceConfigQueryWrapper.orderByDesc(value);
} catch (NoSuchFieldException e) {
e.printStackTrace();
}
@ -217,40 +217,40 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
if("0".equals(dataType)){
if((total>0 && AllIdList.size()>0) || total==0){
Page<RecycleDeviceConfigeEntity> page=new Page<>(recycleDeviceConfigePagination.getCurrentPage(), recycleDeviceConfigePagination.getPageSize());
IPage<RecycleDeviceConfigeEntity> userIPage=this.page(page, recycleDeviceConfigeQueryWrapper);
return recycleDeviceConfigePagination.setData(userIPage.getRecords(),userIPage.getTotal());
Page<RecycleDeviceConfigEntity> page=new Page<>(recycleDeviceConfigPagination.getCurrentPage(), recycleDeviceConfigPagination.getPageSize());
IPage<RecycleDeviceConfigEntity> userIPage=this.page(page, recycleDeviceConfigQueryWrapper);
return recycleDeviceConfigPagination.setData(userIPage.getRecords(),userIPage.getTotal());
}else{
List<RecycleDeviceConfigeEntity> list = new ArrayList();
return recycleDeviceConfigePagination.setData(list, list.size());
List<RecycleDeviceConfigEntity> list = new ArrayList();
return recycleDeviceConfigPagination.setData(list, list.size());
}
}else{
return this.list(recycleDeviceConfigeQueryWrapper);
return this.list(recycleDeviceConfigQueryWrapper);
}
}
@Override
public RecycleDeviceConfigeEntity getInfo(String id){
QueryWrapper<RecycleDeviceConfigeEntity> queryWrapper=new QueryWrapper<>();
queryWrapper.lambda().eq(RecycleDeviceConfigeEntity::getId,id);
public RecycleDeviceConfigEntity getInfo(String id){
QueryWrapper<RecycleDeviceConfigEntity> queryWrapper=new QueryWrapper<>();
queryWrapper.lambda().eq(RecycleDeviceConfigEntity::getId,id);
return this.getOne(queryWrapper);
}
@Override
public void create(RecycleDeviceConfigeEntity entity){
public void create(RecycleDeviceConfigEntity entity){
this.save(entity);
}
@Override
public boolean update(String id, RecycleDeviceConfigeEntity entity){
public boolean update(String id, RecycleDeviceConfigEntity entity){
return this.updateById(entity);
}
@Override
public void delete(RecycleDeviceConfigeEntity entity){
public void delete(RecycleDeviceConfigEntity entity){
if(entity!=null){
this.removeById(entity.getId());
}
}
/** 验证表单唯一字段,正则,非空 i-0新增-1修改*/
@Override
public String checkForm(RecycleDeviceConfigeForm form,int i) {
public String checkForm(RecycleDeviceConfigForm form,int i) {
boolean isUp =StringUtil.isNotEmpty(form.getId()) && !form.getId().equals("0");
String id="";
String countRecover = "";
@ -333,17 +333,17 @@ public class RecycleDeviceConfigeServiceImpl extends ServiceImpl<RecycleDeviceCo
/**
* ()
* @param id
* @param recycleDeviceConfigeForm
* @param recycleDeviceConfigForm
* @return
*/
@Override
@Transactional
public void saveOrUpdate(RecycleDeviceConfigeForm recycleDeviceConfigeForm,String id, boolean isSave) throws Exception{
public void saveOrUpdate(RecycleDeviceConfigForm recycleDeviceConfigForm,String id, boolean isSave) throws Exception{
UserInfo userInfo=userProvider.get();
UserEntity userEntity = generaterSwapUtil.getUser(userInfo.getUserId());
recycleDeviceConfigeForm = JsonUtil.getJsonToBean(
generaterSwapUtil.swapDatetime(RecycleDeviceConfigeConstant.getFormData(),recycleDeviceConfigeForm),RecycleDeviceConfigeForm.class);
RecycleDeviceConfigeEntity entity = JsonUtil.getJsonToBean(recycleDeviceConfigeForm, RecycleDeviceConfigeEntity.class);
recycleDeviceConfigForm = JsonUtil.getJsonToBean(
generaterSwapUtil.swapDatetime(RecycleDeviceConfigConstant.getFormData(),recycleDeviceConfigForm),RecycleDeviceConfigForm.class);
RecycleDeviceConfigEntity entity = JsonUtil.getJsonToBean(recycleDeviceConfigForm, RecycleDeviceConfigEntity.class);
if(isSave){
String mainId = RandomUtil.uuId() ;

@ -30,15 +30,15 @@ import jnpf.exception.WorkFlowException;
import org.springframework.transaction.annotation.Transactional;
/**
* RecycleBucket
*
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-29
* @ 2024-06-17
*/
@Slf4j
@RestController
@Tag(name = "RecycleBucket" , description = "scm")
@Tag(name = "回收桶配置" , description = "scm")
@RequestMapping("/api/scm/RecycleBucket")
public class RecycleBucketController {

@ -11,7 +11,7 @@ import jnpf.permission.entity.UserEntity;
import jnpf.service.*;
import jnpf.entity.*;
import jnpf.util.*;
import jnpf.model.recycledeviceconfige.*;
import jnpf.model.recycledeviceconfig.*;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
@ -30,17 +30,17 @@ import jnpf.exception.WorkFlowException;
import org.springframework.transaction.annotation.Transactional;
/**
*
*
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-31
* @ 2024-06-17
*/
@Slf4j
@RestController
@Tag(name = "投递清单" , description = "scm")
@RequestMapping("/api/scm/RecycleDeviceConfige")
public class RecycleDeviceConfigeController {
@Tag(name = "商户设备配置" , description = "scm")
@RequestMapping("/api/scm/RecycleDeviceConfig")
public class RecycleDeviceConfigController {
@Autowired
private GeneraterSwapUtil generaterSwapUtil;
@ -49,53 +49,53 @@ public class RecycleDeviceConfigeController {
private UserProvider userProvider;
@Autowired
private RecycleDeviceConfigeService recycleDeviceConfigeService;
private RecycleDeviceConfigService recycleDeviceConfigService;
/**
*
*
* @param recycleDeviceConfigePagination
* @param recycleDeviceConfigPagination
* @return
*/
@Operation(summary = "获取列表")
@PostMapping("/getList")
public ActionResult list(@RequestBody RecycleDeviceConfigePagination recycleDeviceConfigePagination)throws IOException{
List<RecycleDeviceConfigeEntity> list= recycleDeviceConfigeService.getList(recycleDeviceConfigePagination);
public ActionResult list(@RequestBody RecycleDeviceConfigPagination recycleDeviceConfigPagination)throws IOException{
List<RecycleDeviceConfigEntity> list= recycleDeviceConfigService.getList(recycleDeviceConfigPagination);
List<Map<String, Object>> realList=new ArrayList<>();
for (RecycleDeviceConfigeEntity entity : list) {
Map<String, Object> recycleDeviceConfigeMap=JsonUtil.entityToMap(entity);
recycleDeviceConfigeMap.put("id", recycleDeviceConfigeMap.get("id"));
for (RecycleDeviceConfigEntity entity : list) {
Map<String, Object> recycleDeviceConfigMap=JsonUtil.entityToMap(entity);
recycleDeviceConfigMap.put("id", recycleDeviceConfigMap.get("id"));
//副表数据
//子表数据
realList.add(recycleDeviceConfigeMap);
realList.add(recycleDeviceConfigMap);
}
//数据转换
realList = generaterSwapUtil.swapDataList(realList, RecycleDeviceConfigeConstant.getFormData(), RecycleDeviceConfigeConstant.getColumnData(), recycleDeviceConfigePagination.getModuleId(),false);
realList = generaterSwapUtil.swapDataList(realList, RecycleDeviceConfigConstant.getFormData(), RecycleDeviceConfigConstant.getColumnData(), recycleDeviceConfigPagination.getModuleId(),false);
//返回对象
PageListVO vo = new PageListVO();
vo.setList(realList);
PaginationVO page = JsonUtil.getJsonToBean(recycleDeviceConfigePagination, PaginationVO.class);
PaginationVO page = JsonUtil.getJsonToBean(recycleDeviceConfigPagination, PaginationVO.class);
vo.setPagination(page);
return ActionResult.success(vo);
}
/**
*
*
* @param recycleDeviceConfigeForm
* @param recycleDeviceConfigForm
* @return
*/
@PostMapping()
@Operation(summary = "创建")
public ActionResult create(@RequestBody @Valid RecycleDeviceConfigeForm recycleDeviceConfigeForm) {
String b = recycleDeviceConfigeService.checkForm(recycleDeviceConfigeForm,0);
public ActionResult create(@RequestBody @Valid RecycleDeviceConfigForm recycleDeviceConfigForm) {
String b = recycleDeviceConfigService.checkForm(recycleDeviceConfigForm,0);
if (StringUtil.isNotEmpty(b)){
return ActionResult.fail(b );
}
try{
recycleDeviceConfigeService.saveOrUpdate(recycleDeviceConfigeForm, null ,true);
recycleDeviceConfigService.saveOrUpdate(recycleDeviceConfigForm, null ,true);
}catch(Exception e){
return ActionResult.fail("新增数据失败");
}
@ -104,24 +104,24 @@ public class RecycleDeviceConfigeController {
/**
*
* @param id
* @param recycleDeviceConfigeForm
* @param recycleDeviceConfigForm
* @return
*/
@PutMapping("/{id}")
@Operation(summary = "更新")
public ActionResult update(@PathVariable("id") String id,@RequestBody @Valid RecycleDeviceConfigeForm recycleDeviceConfigeForm,
public ActionResult update(@PathVariable("id") String id,@RequestBody @Valid RecycleDeviceConfigForm recycleDeviceConfigForm,
@RequestParam(value = "isImport", required = false) boolean isImport){
recycleDeviceConfigeForm.setId(id);
recycleDeviceConfigForm.setId(id);
if (!isImport) {
String b = recycleDeviceConfigeService.checkForm(recycleDeviceConfigeForm,1);
String b = recycleDeviceConfigService.checkForm(recycleDeviceConfigForm,1);
if (StringUtil.isNotEmpty(b)){
return ActionResult.fail(b );
}
}
RecycleDeviceConfigeEntity entity= recycleDeviceConfigeService.getInfo(id);
RecycleDeviceConfigEntity entity= recycleDeviceConfigService.getInfo(id);
if(entity!=null){
try{
recycleDeviceConfigeService.saveOrUpdate(recycleDeviceConfigeForm,id,false);
recycleDeviceConfigService.saveOrUpdate(recycleDeviceConfigForm,id,false);
}catch(Exception e){
return ActionResult.fail("修改数据失败");
}
@ -139,10 +139,10 @@ public class RecycleDeviceConfigeController {
@DeleteMapping("/{id}")
@Transactional
public ActionResult delete(@PathVariable("id") String id){
RecycleDeviceConfigeEntity entity= recycleDeviceConfigeService.getInfo(id);
RecycleDeviceConfigEntity entity= recycleDeviceConfigService.getInfo(id);
if(entity!=null){
//主表数据删除
recycleDeviceConfigeService.delete(entity);
recycleDeviceConfigService.delete(entity);
}
return ActionResult.success("删除成功");
}
@ -155,16 +155,16 @@ public class RecycleDeviceConfigeController {
@Operation(summary = "表单信息(详情页)")
@GetMapping("/detail/{id}")
public ActionResult detailInfo(@PathVariable("id") String id){
RecycleDeviceConfigeEntity entity= recycleDeviceConfigeService.getInfo(id);
RecycleDeviceConfigEntity entity= recycleDeviceConfigService.getInfo(id);
if(entity==null){
return ActionResult.fail("表单数据不存在!");
}
Map<String, Object> recycleDeviceConfigeMap=JsonUtil.entityToMap(entity);
recycleDeviceConfigeMap.put("id", recycleDeviceConfigeMap.get("id"));
Map<String, Object> recycleDeviceConfigMap=JsonUtil.entityToMap(entity);
recycleDeviceConfigMap.put("id", recycleDeviceConfigMap.get("id"));
//副表数据
//子表数据
recycleDeviceConfigeMap = generaterSwapUtil.swapDataDetail(recycleDeviceConfigeMap,RecycleDeviceConfigeConstant.getFormData(),"565858748388610501",false);
return ActionResult.success(recycleDeviceConfigeMap);
recycleDeviceConfigMap = generaterSwapUtil.swapDataDetail(recycleDeviceConfigMap,RecycleDeviceConfigConstant.getFormData(),"565858748388610501",false);
return ActionResult.success(recycleDeviceConfigMap);
}
/**
* ()
@ -175,16 +175,16 @@ public class RecycleDeviceConfigeController {
@Operation(summary = "信息")
@GetMapping("/{id}")
public ActionResult info(@PathVariable("id") String id){
RecycleDeviceConfigeEntity entity= recycleDeviceConfigeService.getInfo(id);
RecycleDeviceConfigEntity entity= recycleDeviceConfigService.getInfo(id);
if(entity==null){
return ActionResult.fail("表单数据不存在!");
}
Map<String, Object> recycleDeviceConfigeMap=JsonUtil.entityToMap(entity);
recycleDeviceConfigeMap.put("id", recycleDeviceConfigeMap.get("id"));
Map<String, Object> recycleDeviceConfigMap=JsonUtil.entityToMap(entity);
recycleDeviceConfigMap.put("id", recycleDeviceConfigMap.get("id"));
//副表数据
//子表数据
recycleDeviceConfigeMap = generaterSwapUtil.swapDataForm(recycleDeviceConfigeMap,RecycleDeviceConfigeConstant.getFormData(),RecycleDeviceConfigeConstant.TABLEFIELDKEY,RecycleDeviceConfigeConstant.TABLERENAMES);
return ActionResult.success(recycleDeviceConfigeMap);
recycleDeviceConfigMap = generaterSwapUtil.swapDataForm(recycleDeviceConfigMap,RecycleDeviceConfigConstant.getFormData(),RecycleDeviceConfigConstant.TABLEFIELDKEY,RecycleDeviceConfigConstant.TABLERENAMES);
return ActionResult.success(recycleDeviceConfigMap);
}
}

@ -13,7 +13,7 @@ import java.math.BigDecimal;
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-29
* @ 2024-06-17
*/
@Data
@TableName("nx_recycle_bucket")
@ -42,8 +42,8 @@ public class RecycleBucketEntity {
private Integer fullStatus;
@TableField(value = "FULL_SET" , updateStrategy = FieldStrategy.IGNORED)
private Integer fullSet;
@TableField(value = "SMOG_STAUTS" , updateStrategy = FieldStrategy.IGNORED)
private Integer smogStauts;
@TableField(value = "SMOG_STATUS" , updateStrategy = FieldStrategy.IGNORED)
private Integer smogStatus;
@TableField(value = "SMOG_SET" , updateStrategy = FieldStrategy.IGNORED)
private Integer smogSet;
@TableField(value = "CONTAINER_WEIGHT" , updateStrategy = FieldStrategy.IGNORED)

@ -23,11 +23,11 @@ import java.math.BigDecimal;
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-31
* @ 2024-06-17
*/
@Data
@TableName("nx_recycle_device_confige")
public class RecycleDeviceConfigeEntity {
@TableName("nx_recycle_device_config")
public class RecycleDeviceConfigEntity {
@TableId(value ="ID" )
private String id;
@TableField(value = "DELIVERY_PRICE" , updateStrategy = FieldStrategy.IGNORED)

@ -6,11 +6,11 @@ import java.math.BigDecimal;
import com.fasterxml.jackson.annotation.JsonProperty;
/**
* RecycleBucket
*
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-29
* @ 2024-06-17
*/
@Data
public class RecycleBucketForm {
@ -51,8 +51,8 @@ public class RecycleBucketForm {
@JsonProperty("fullSet")
private String fullSet;
/** 烟雾状态 **/
@JsonProperty("smogStauts")
private String smogStauts;
@JsonProperty("smogStatus")
private String smogStatus;
/** 烟雾设置 **/
@JsonProperty("smogSet")
private String smogSet;

@ -7,11 +7,11 @@ import java.util.List;
/**
*
* RecycleBucket
*
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-29
* @ 2024-06-17
*/
@Data
public class RecycleBucketPagination extends Pagination {

@ -1,4 +1,4 @@
package jnpf.model.recycledeviceconfige;
package jnpf.model.recycledeviceconfig;
import lombok.Data;
import java.util.List;
@ -6,14 +6,14 @@ import java.math.BigDecimal;
import com.fasterxml.jackson.annotation.JsonProperty;
/**
*
*
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-31
* @ 2024-06-17
*/
@Data
public class RecycleDeviceConfigeForm {
public class RecycleDeviceConfigForm {
/** 主键 */
private String id;
@ -56,7 +56,7 @@ public class RecycleDeviceConfigeForm {
/** 12号桶价格 **/
@JsonProperty("bucket12Price")
private String bucket12Price;
/** 投递审核 **/
/** 投递审核配置 **/
@JsonProperty("deliveryAdjustSet")
private String deliveryAdjustSet;
/** 手机号登录 **/
@ -65,13 +65,13 @@ public class RecycleDeviceConfigeForm {
/** 清运锁 **/
@JsonProperty("cleanLock")
private String cleanLock;
/** 清运审核 **/
/** 清运审核配置 **/
@JsonProperty("cleanAdjustSet")
private String cleanAdjustSet;
/** 烟雾报警 **/
@JsonProperty("smogSet")
private String smogSet;
/** 关门延时 **/
/** 投递关门 **/
@JsonProperty("closeDelay")
private String closeDelay;
/** 满溢报警 **/
@ -95,7 +95,7 @@ public class RecycleDeviceConfigeForm {
/** 修改时间 **/
@JsonProperty("lastModifyTime")
private String lastModifyTime;
/** 组织json_id **/
/** 组织架构 **/
@JsonProperty("organizeJsonId")
private Object organizeJsonId;
/** 公司id **/

@ -1,4 +1,4 @@
package jnpf.model.recycledeviceconfige;
package jnpf.model.recycledeviceconfig;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;
@ -7,14 +7,14 @@ import java.util.List;
/**
*
*
*
* @ V3.5
* @ https://www.jnpfsoft.com
* @ JNPF
* @ 2024-05-31
* @ 2024-06-17
*/
@Data
public class RecycleDeviceConfigePagination extends Pagination {
public class RecycleDeviceConfigPagination extends Pagination {
/** 查询key */
private String[] selectKey;
/** json */

@ -11,9 +11,9 @@ module.exports = {
// APIURl: 'http://222.71.165.187:30000'
//生产环境接口配置 5555
// APIURl: 'http://222.71.165.187:50000'
// 开发环境接口配置
APIURl: 'http://127.0.0.1:30000'
// 测试环境接口配置
// APIURl: 'http://192.168.0.23:30000'
// APIURl: 'http://222.71.165.187:30000'
}

@ -1,253 +1,283 @@
<template>
<transition name="el-zoom-in-center">
<div class="JNPF-preview-main">
<Detail v-if="detailVisible" ref="Detail" @close="detailVisible = false" />
<div class="JNPF-common-page-header">
<el-page-header @back="goBack" content="详情" />
<div class="options">
<el-button @click="goBack"> </el-button>
</div>
</div>
<el-row :gutter="15" class=" main" :style="{ margin: '0 auto', width: '100%' }">
<el-form ref="formRef" :model="dataForm" size="small" label-width="100px" label-position="right">
<template v-if="!loading">
<el-col :span="8">
<jnpf-form-tip-item label="显示别名" prop="showName">
<p>{{ dataForm.showName }}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="门号" prop="doorNum">
<p>{{ dataForm.doorNum }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="所属设备" prop="deviceCode">
<p>{{ dataForm.deviceCode }}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="是否显示" prop="isShow">
<p>{{ dataForm.isShow }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="显示顺序" prop="showOrd">
<JnpfNumber v-model="dataForm.showOrd" placeholder="数字文本" disabled :step="1">
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="24">
<jnpf-form-tip-item label="回收品大类" prop="productCode">
<p>{{ dataForm.productCode }}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="24">
<jnpf-form-tip-item label="回收品子类" prop="productSubCode">
<p>{{ dataForm.productSubCode }}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="价格" prop="price">
<JnpfNumber v-model="dataForm.price" placeholder="数字文本" disabled :step="1"
:precision="2">
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="满溢状态" prop="fullStatus">
<p>{{ dataForm.fullStatus }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="满溢设置" prop="fullSet">
<p>{{ dataForm.fullSet }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="烟雾状态" prop="smogStauts">
<p>{{ dataForm.smogStauts }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="烟雾设置" prop="smogSet">
<p>{{ dataForm.smogSet }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="容器重量" prop="containerWeight">
<JnpfNumber v-model="dataForm.containerWeight" placeholder="数字文本" disabled :step="1"
:precision="2" addonAfter="KG">
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="当前重量" prop="currentWeight">
<JnpfNumber v-model="dataForm.currentWeight" placeholder="数字文本" disabled :step="1"
:precision="2" addonAfter="KG">
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="重量上限" prop="warningWeight">
<JnpfNumber v-model="dataForm.warningWeight" placeholder="数字文本" disabled :step="1"
:precision="2" addonAfter="KG">
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="关闭延时" prop="closeDelay" tip-label="">
<p>{{ dataForm.closeDelay }}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="投递门" prop="deliveryDoorStatus" tip-label="">
<p>{{ dataForm.deliveryDoorStatus }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="清运门" prop="cleanDoorStatus" tip-label="">
<p>{{ dataForm.cleanDoorStatus }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="垃圾袋编码" prop="bagNo">
<p>{{ dataForm.bagNo }}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="24">
<jnpf-form-tip-item label="桶身图片" prop="bucketImg">
<JnpfUploadImg v-model="dataForm.bucketImg" disabled detailed :fileSize="10"
sizeUnit="MB" :limit="9" pathType="defaultPath" :isAccount="0">
</JnpfUploadImg>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="状态" prop="status">
<p>{{ dataForm.status }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8">
<jnpf-form-tip-item label="租户" prop="tenantId">
<p>{{ dataForm.tenantId }}</p>
</jnpf-form-tip-item>
</el-col>
</template>
</el-form>
</el-row>
<transition name="el-zoom-in-center">
<div class="JNPF-preview-main">
<Detail v-if="detailVisible" ref="Detail" @close="detailVisible = false" />
<div class="JNPF-common-page-header">
<el-page-header @back="goBack"
content="详情"/>
<div class="options">
<el-button @click="goBack"> </el-button>
</div>
</transition>
</div>
<el-row :gutter="15" class=" main" :style="{margin: '0 auto',width: '100%'}">
<el-form ref="formRef" :model="dataForm" size="small" label-width="100px" label-position="right" >
<template v-if="!loading">
<el-col :span="8" >
<jnpf-form-tip-item label="显示别名"
prop="showName" >
<p>{{dataForm.showName}}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="门号"
prop="doorNum" >
<p>{{ dataForm.doorNum }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="所属设备"
prop="deviceCode" >
<p>{{dataForm.deviceCode}}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="是否显示"
prop="isShow" >
<p>{{ dataForm.isShow }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="显示顺序"
prop="showOrd" >
<JnpfNumber v-model="dataForm.showOrd"
placeholder="数字文本" disabled
:step="1" >
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="24" >
<jnpf-form-tip-item label="回收品大类"
prop="productCode" >
<p>{{dataForm.productCode}}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="24" >
<jnpf-form-tip-item label="回收品子类"
prop="productSubCode" >
<p>{{dataForm.productSubCode}}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="价格"
prop="price" >
<JnpfNumber v-model="dataForm.price"
placeholder="数字文本" disabled
:step="1" :precision="2" >
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="满溢状态"
prop="fullStatus" >
<p>{{ dataForm.fullStatus }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="满溢设置"
prop="fullSet" >
<p>{{ dataForm.fullSet }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="烟雾状态"
prop="smogStatus" >
<p>{{ dataForm.smogStatus }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="烟雾设置"
prop="smogSet" >
<p>{{ dataForm.smogSet }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="容器重量"
prop="containerWeight" >
<JnpfNumber v-model="dataForm.containerWeight"
placeholder="数字文本" disabled
:step="1" :precision="2" addonAfter="KG" >
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="当前重量"
prop="currentWeight" >
<JnpfNumber v-model="dataForm.currentWeight"
placeholder="数字文本" disabled
:step="1" :precision="2" addonAfter="KG" >
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="重量上限"
prop="warningWeight" >
<JnpfNumber v-model="dataForm.warningWeight"
placeholder="数字文本" disabled
:step="1" :precision="2" addonAfter="KG" >
</JnpfNumber>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="关闭延时"
prop="closeDelay" tip-label="投递门关闭延时" >
<p>{{dataForm.closeDelay}}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="投递门"
prop="deliveryDoorStatus" tip-label="投递门状态" >
<p>{{ dataForm.deliveryDoorStatus }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="清运门"
prop="cleanDoorStatus" tip-label="清运门状态" >
<p>{{ dataForm.cleanDoorStatus }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="垃圾袋编码"
prop="bagNo" >
<p>{{dataForm.bagNo}}</p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="24" >
<jnpf-form-tip-item label="桶身图片"
prop="bucketImg" >
<JnpfUploadImg v-model="dataForm.bucketImg"
disabled
detailed :fileSize="10" sizeUnit="MB" :limit="9" pathType="defaultPath" :isAccount="0" >
</JnpfUploadImg>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="状态"
prop="status" >
<p>{{ dataForm.status }} </p>
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="租户"
prop="tenantId" >
<p>{{dataForm.tenantId}}</p>
</jnpf-form-tip-item>
</el-col>
</template>
</el-form>
</el-row>
</div>
</transition>
</template>
<script>
import request from '@/utils/request'
import request from '@/utils/request'
import { getConfigData } from '@/api/onlineDev/visualDev'
import jnpf from '@/utils/jnpf'
import Detail from '@/views/basic/dynamicModel/list/detail'
import { thousandsFormat } from "@/components/Generator/utils/index"
export default {
components: { Detail },
props: [],
data() {
return {
visible: false,
detailVisible: false,
loading: false,
import { getConfigData } from '@/api/onlineDev/visualDev'
import jnpf from '@/utils/jnpf'
import Detail from '@/views/basic/dynamicModel/list/detail'
import { thousandsFormat } from "@/components/Generator/utils/index"
export default {
components: { Detail},
props: [],
data() {
return {
visible: false,
detailVisible: false,
loading: false,
dataForm: {
id: '',
bucketCode: '',
showName: '',
doorNum: "",
deviceCode: "",
isShow: "1",
showOrd: 0,
productCode: "542987705491919312",
productSubCode: "",
price: '',
fullStatus: '',
fullSet: '',
smogStauts: '',
smogSet: '',
containerWeight: '',
currentWeight: '',
warningWeight: '',
closeDelay: '',
deliveryDoorStatus: '',
cleanDoorStatus: '',
bagNo: '',
bucketImg: [],
status: '',
tenantId: [],
id :'',
bucketCode : '',
showName : '',
doorNum : "",
deviceCode : "",
isShow : "1",
showOrd : 0,
productCode : "542987705491919312",
productSubCode : "",
price : '',
fullStatus : '',
fullSet : '',
smogStatus : '',
smogSet : '',
containerWeight : '',
currentWeight : '',
warningWeight : '',
closeDelay : '',
deliveryDoorStatus : '',
cleanDoorStatus : '',
bagNo : '',
bucketImg : [],
status : '',
tenantId : [],
},
doorNumOptions: [{ "fullName": "1号", "id": "1" }, { "fullName": "2号", "id": "2" }, { "fullName": "3号", "id": "3" }, { "fullName": "4号", "id": "4" }, { "fullName": "5号", "id": "5" }, { "fullName": "6号", "id": "6" }, { "fullName": "7号", "id": "7" }, { "fullName": "8号", "id": "8" }, { "fullName": "9号", "id": "9" }, { "fullName": "10号", "id": "10" }, { "fullName": "11号", "id": "11" }, { "fullName": "12号", "id": "12" }],
doorNumProps: { "label": "fullName", "value": "id" },
isShowOptions: [{ "fullName": "关闭", "id": 0 }, { "fullName": "显示", "id": 1 }],
isShowProps: { "label": "fullName", "value": "id" },
productCodeProps: { "label": "name", "value": "id" },
productSubCodeProps: { "label": "name", "value": "id" },
fullStatusOptions: [{ "fullName": "未满", "id": 0 }, { "fullName": "满", "id": 1 }],
fullStatusProps: { "label": "fullName", "value": "id" },
fullSetOptions: [{ "fullName": "关闭", "id": 0 }, { "fullName": "开启", "id": 1 }],
fullSetProps: { "label": "fullName", "value": "id" },
smogStautsOptions: [{ "fullName": "正常", "id": 0 }, { "fullName": "报警", "id": 1 }],
smogStautsProps: { "label": "fullName", "value": "id" },
smogSetOptions: [{ "fullName": "关闭", "id": 0 }, { "fullName": "开启", "id": 1 }],
smogSetProps: { "label": "fullName", "value": "id" },
deliveryDoorStatusOptions: [{ "fullName": "关闭", "id": 0 }, { "fullName": "开启", "id": 1 }],
deliveryDoorStatusProps: { "label": "fullName", "value": "id" },
cleanDoorStatusOptions: [{ "fullName": "关闭", "id": 0 }, { "fullName": "开启", "id": 1 }],
cleanDoorStatusProps: { "label": "fullName", "value": "id" },
statusOptions: [{ "fullName": "停用", "id": 0 }, { "fullName": "启用", "id":1 }],
statusProps: { "label": "fullName", "value": "id" },
doorNumOptions:[{"fullName":"1号","id":"1"},{"fullName":"2号","id":"2"},{"fullName":"3号","id":"3"},{"fullName":"4号","id":"4"},{"fullName":"5号","id":"5"},{"fullName":"6号","id":"6"},{"fullName":"7号","id":"7"},{"fullName":"8号","id":"8"},{"fullName":"9号","id":"9"},{"fullName":"10号","id":"10"},{"fullName":"11号","id":"11"},{"fullName":"12号","id":"12"}],
doorNumProps:{"label":"fullName","value":"id" },
isShowOptions:[{"fullName":"关闭","id":"0"},{"fullName":"显示","id":"1"}],
isShowProps:{"label":"fullName","value":"id" },
productCodeProps:{"label":"name","value":"id" },
productSubCodeProps:{"label":"name","value":"id" },
fullStatusOptions:[{"fullName":"未满","id":"0"},{"fullName":"满","id":"1"}],
fullStatusProps:{"label":"fullName","value":"id" },
fullSetOptions:[{"fullName":"关闭","id":"0"},{"fullName":"开启","id":"1"}],
fullSetProps:{"label":"fullName","value":"id" },
smogStatusOptions:[{"fullName":"正常","id":"0"},{"fullName":"报警","id":"1"}],
smogStatusProps:{"label":"fullName","value":"id" },
smogSetOptions:[{"fullName":"关闭","id":"0"},{"fullName":"开启","id":"1"}],
smogSetProps:{"label":"fullName","value":"id" },
deliveryDoorStatusOptions:[{"fullName":"关闭","id":"0"},{"fullName":"开启","id":"1"}],
deliveryDoorStatusProps:{"label":"fullName","value":"id" },
cleanDoorStatusOptions:[{"fullName":"关闭","id":"0"},{"fullName":"开启","id":"1"}],
cleanDoorStatusProps:{"label":"fullName","value":"id" },
statusOptions:[{"fullName":"停用","id":"0"},{"fullName":"启用","id":"1"}],
statusProps:{"label":"fullName","value":"id" },
}
},
computed: {},
watch: {},
created() {
},
mounted() { },
methods: {
toDetail(defaultValue, modelId) {
if (!defaultValue) return
getConfigData(modelId).then(res => {
if (!res.data || !res.data.formData) return
let formData = JSON.parse(res.data.formData)
formData.popupType = 'general'
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(formData, modelId, defaultValue)
})
})
},
dataInfo(dataAll) {
let _dataAll = dataAll
this.dataForm = _dataAll
},
computed: {},
watch: {},
created() {
goBack() {
this.$emit('refresh')
},
init(id) {
this.dataForm.id = id || 0;
this.visible = true;
this.$nextTick(() => {
if (this.dataForm.id) {
this.loading = true
request({
url: '/api/scm/RecycleBucket/detail/' + this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
mounted() {},
methods: {
toDetail(defaultValue, modelId) {
if (!defaultValue) return
getConfigData(modelId).then(res => {
if (!res.data || !res.data.formData) return
let formData = JSON.parse(res.data.formData)
formData.popupType = 'general'
this.detailVisible = true
this.$nextTick(() => {
this.$refs.Detail.init(formData, modelId, defaultValue)
})
}
})
},
dataInfo(dataAll){
let _dataAll =dataAll
this.dataForm = _dataAll
},
goBack() {
this.$emit('refresh')
},
init(id) {
this.dataForm.id = id || 0;
this.visible = true;
this.$nextTick(() => {
if(this.dataForm.id){
this.loading = true
request({
url: '/api/scm/RecycleBucket/detail/'+this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
this.loading = false
})
}
})
})
},
},
},
}
}
</script>

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

@ -13,7 +13,7 @@
<el-form ref="formRef" :model="dataForm" size="medium" label-width="150px" label-position="right" >
<template v-if="!loading">
<el-col :span="24">
<el-collapse :accordion="false" v-model="activeajjooa" class="mb-20">
<el-collapse :accordion="false" v-model="activesvflpo" class="mb-20">
<el-collapse-item title="价格配置" name="1">
<el-col :span="8" >
<jnpf-form-tip-item label="统一投递价格"
@ -103,7 +103,7 @@
</el-collapse-item>
<el-collapse-item title="设备配置" name="2">
<el-col :span="8" >
<jnpf-form-tip-item label="投递审核"
<jnpf-form-tip-item label="投递审核配置 "
prop="deliveryAdjustSet" tip-label="投递后审核结算" >
<p>{{ dataForm.deliveryAdjustSet }} </p>
</jnpf-form-tip-item>
@ -121,7 +121,7 @@
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="清运审核"
<jnpf-form-tip-item label="清运审核配置"
prop="cleanAdjustSet" tip-label="清运数据审核入库" >
<p>{{ dataForm.cleanAdjustSet }} </p>
</jnpf-form-tip-item>
@ -133,7 +133,7 @@
</jnpf-form-tip-item>
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item label="关门延时"
<jnpf-form-tip-item label="投递关门"
prop="closeDelay" >
<p>{{dataForm.closeDelay}}</p>
</jnpf-form-tip-item>
@ -237,7 +237,7 @@
companyId : "",
departmentId : "",
},
activeajjooa:["1","2"],
activesvflpo:["1","2"],
deliveryAdjustSetOptions:[{"fullName":"即时自动","id":"1"},{"fullName":"24H自动","id":"2"},{"fullName":"48H自动","id":"3"}],
deliveryAdjustSetProps:{"label":"fullName","value":"id" },
allowPhoneLoginProps:{"label":"fullName","value":"enCode" },
@ -284,7 +284,7 @@
if(this.dataForm.id){
this.loading = true
request({
url: '/api/scm/RecycleDeviceConfige/detail/'+this.dataForm.id,
url: '/api/scm/RecycleDeviceConfig/detail/'+this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)

File diff suppressed because one or more lines are too long

@ -35,7 +35,7 @@
<template v-if="!loading">
<!-- 具体表单 -->
<el-col :span="24">
<el-collapse :accordion="false" v-model="activeajjooa" class="mb-20">
<el-collapse :accordion="false" v-model="activesvflpo" class="mb-20">
<el-collapse-item title="价格配置" name="1">
<el-col :span="8" >
<jnpf-form-tip-item
@ -152,7 +152,7 @@
<el-collapse-item title="设备配置" name="2">
<el-col :span="8" >
<jnpf-form-tip-item
label="投递审核" tipLabel="投递后审核结算" prop="deliveryAdjustSet" >
label="投递审核配置 " tipLabel="投递后审核结算" prop="deliveryAdjustSet" >
<JnpfRadio v-model="dataForm.deliveryAdjustSet" @change="changeData('deliveryAdjustSet',-1)"
optionType="button" direction="horizontal" size="small" :options="deliveryAdjustSetOptions" :props="deliveryAdjustSetProps" >
</JnpfRadio>
@ -176,7 +176,7 @@
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item
label="清运审核" tipLabel="清运数据审核入库" prop="cleanAdjustSet" >
label="清运审核配置" tipLabel="清运数据审核入库" prop="cleanAdjustSet" >
<JnpfRadio v-model="dataForm.cleanAdjustSet" @change="changeData('cleanAdjustSet',-1)"
optionType="button" direction="horizontal" size="small" :options="cleanAdjustSetOptions" :props="cleanAdjustSetProps" >
</JnpfRadio>
@ -192,7 +192,7 @@
</el-col>
<el-col :span="8" >
<jnpf-form-tip-item
label="关门延时" prop="closeDelay" >
label="投递关门" prop="closeDelay" >
<JnpfInput v-model="dataForm.closeDelay" @change="changeData('closeDelay',-1)"
placeholder="请输入" addonAfter="秒" clearable :style='{"width":"100%"}'>
</JnpfInput>
@ -332,7 +332,7 @@
departmentId : undefined,
},
tableRequiredData: {},
activeajjooa:["1","2"],
activesvflpo:["1","2"],
dataRule:
{
deliveryPrice: [
@ -571,7 +571,7 @@
},
getInfo(id) {
request({
url: '/api/scm/RecycleDeviceConfige/'+ id,
url: '/api/scm/RecycleDeviceConfig/'+ id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
@ -679,7 +679,7 @@
if(this.dataForm.id){
this.loading = true
request({
url: '/api/scm/RecycleDeviceConfige/'+this.dataForm.id,
url: '/api/scm/RecycleDeviceConfig/'+this.dataForm.id,
method: 'get'
}).then(res => {
this.dataInfo(res.data)
@ -714,7 +714,7 @@
}
if (!this.dataForm.id) {
request({
url: '/api/scm/RecycleDeviceConfige',
url: '/api/scm/RecycleDeviceConfig',
method: 'post',
data: _data
}).then((res) => {
@ -742,7 +742,7 @@
})
}else{
request({
url: '/api/scm/RecycleDeviceConfige/'+this.dataForm.id,
url: '/api/scm/RecycleDeviceConfig/'+this.dataForm.id,
method: 'PUT',
data: _data
}).then((res) => {

@ -46,112 +46,73 @@
>
<el-table-column
prop="organizeJsonId"
label="当前商户" align="left"
label="组织架构" align="left"
>
</el-table-column>
<el-table-column
prop="deliveryPrice"
label="统一价格" align="left"
label="统一投递价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.deliveryPrice" >
<JnpfNumber v-model="scope.row.deliveryPrice" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket1Price"
label="1号桶价" align="left"
label="1号桶价" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket1Price" >
<JnpfNumber v-model="scope.row.bucket1Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket2Price"
label="2号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket2Price" >
<JnpfNumber v-model="scope.row.bucket2Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket3Price"
label="3号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket3Price" >
<JnpfNumber v-model="scope.row.bucket3Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket4Price"
label="4号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket4Price" >
<JnpfNumber v-model="scope.row.bucket4Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket5Price"
label="5号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket5Price" >
<JnpfNumber v-model="scope.row.bucket5Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket6Price"
label="6号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket6Price" >
<JnpfNumber v-model="scope.row.bucket6Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket7Price"
label="7号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket7Price" >
<JnpfNumber v-model="scope.row.bucket7Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket8Price"
label="8号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket8Price" >
<JnpfNumber v-model="scope.row.bucket8Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket9Price"
label="9号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket9Price" >
<JnpfNumber v-model="scope.row.bucket9Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket10Price"
label="10号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket10Price" >
<JnpfNumber v-model="scope.row.bucket10Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket11Price"
label="11号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket11Price" >
<JnpfNumber v-model="scope.row.bucket11Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="bucket12Price"
label="12号桶价格" align="left"
>
<template slot-scope="scope" v-if="scope.row.bucket12Price" >
<JnpfNumber v-model="scope.row.bucket12Price" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="allowPhoneLogin"
@ -160,27 +121,21 @@
</el-table-column>
<el-table-column
prop="closeDelay"
label="关门延时" align="left"
label="投递关门" align="left"
>
<template slot-scope="scope" v-if="scope.row.closeDelay" >
<JnpfNumber v-model="scope.row.closeDelay" :thousands="false"/>
</template>
</el-table-column>
<el-table-column
prop="warningWeight"
label="报警重量" align="left"
>
<template slot-scope="scope" v-if="scope.row.warningWeight" >
<JnpfNumber v-model="scope.row.warningWeight" :thousands="false"/>
</template>
</el-table-column>
<el-table-column label="投递审核" prop="deliveryAdjustSet" algin="left"
<el-table-column label="投递审核配置 " prop="deliveryAdjustSet" algin="left"
>
<template slot-scope="scope">
{{ scope.row.deliveryAdjustSet}}
</template>
</el-table-column>
<el-table-column label="清运审核" prop="cleanAdjustSet" algin="left"
<el-table-column label="清运审核配置" prop="cleanAdjustSet" algin="left"
>
<template slot-scope="scope">
{{ scope.row.cleanAdjustSet}}
@ -525,7 +480,7 @@
type:1,
};
request({
url: `/api/scm/RecycleDeviceConfige/getList`,
url: `/api/scm/RecycleDeviceConfig/getList`,
method: 'post',
data: _query
}).then(res => {
@ -543,7 +498,7 @@
type: 'warning'
}).then(() => {
request({
url: `/api/scm/RecycleDeviceConfige/${id}`,
url: `/api/scm/RecycleDeviceConfig/${id}`,
method: 'DELETE'
}).then(res => {
this.$message({
@ -560,7 +515,7 @@
handelUpload(){
this.uploadBoxVisible = true
this.$nextTick(() => {
this.$refs.UploadBox.init("","scm/RecycleDeviceConfige")
this.$refs.UploadBox.init("","scm/RecycleDeviceConfig")
})
},
openSuperQuery() {
@ -590,7 +545,7 @@
download(data) {
let query = {...data, ...this.listQuery, ...this.query,menuId:this.menuId}
request({
url: `/api/scm/RecycleDeviceConfige/Actions/Export`,
url: `/api/scm/RecycleDeviceConfig/Actions/Export`,
method: 'post',
data: query
}).then(res => {

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save