Commit 0ed8e042 by 王衍超

解决冲突;

parents 286c2b50 5ddfd0fc
...@@ -277,4 +277,48 @@ public class DateTimeUtils { ...@@ -277,4 +277,48 @@ public class DateTimeUtils {
return calendar.getTime(); return calendar.getTime();
} }
/**
* 判断1个日期是否小于当前时间所在年
* eg: now = new Date 2021-04-16
* isLtNowYear(2020-12-31) true
* isLtNowYear(2021-01-01) false
* @return Boolean
*/
public static Boolean isLtNowYear(Date date) {
Calendar cal1 = Calendar.getInstance();
cal1.setTime(date);
Calendar cal2 = Calendar.getInstance();
cal2.setTime(new Date());
return cal1.get(Calendar.YEAR) < cal2.get(Calendar.YEAR);
}
/**
* 判断2个日期是否同年
* eg: isSameYear(2020-12-31,2021-01-01) false
* isSameYear(2020-01-01,2020-12-31) true
* @return Boolean
*/
public static Boolean isSameYear(Date startDate , Date endDate) {
Calendar cal1 = Calendar.getInstance();
cal1.setTime(startDate);
Calendar cal2 = Calendar.getInstance();
cal2.setTime(endDate);
return cal1.get(Calendar.YEAR) == cal2.get(Calendar.YEAR);
}
/**
* 判断2个日期是否同月
* eg: isSameYear(2020-12-31,2021-01-01) false
* isSameYear(2020-12-31,2020-12-01) true
* isSameYear(2020-12-31,2021-12-01) true
* @return Boolean
*/
public static Boolean isSameMonth(Date startDate , Date endDate) {
Calendar cal1 = Calendar.getInstance();
cal1.setTime(startDate);
Calendar cal2 = Calendar.getInstance();
cal2.setTime(endDate);
return cal1.get(Calendar.MONTH) == cal2.get(Calendar.MONTH);
}
} }
\ No newline at end of file
...@@ -126,7 +126,11 @@ public class BaseBusinessWarn { ...@@ -126,7 +126,11 @@ public class BaseBusinessWarn {
//2.当前存在执行中的预警记录,则修改预警执行信息 //2.当前存在执行中的预警记录,则修改预警执行信息
Date currentTime = new Date(); Date currentTime = new Date();
warnExeRecord.setRecentlyTime(currentTime); warnExeRecord.setRecentlyTime(currentTime);
if(!isWarning) {//2.1 如果没有处罚预警,则结束该预警记录 if(!isWarning) {//2.1 如果没有触发预警,则结束该预警记录
//如果预警已经结束,则不修改
if((WarnStateEnum.OVER.getValue()+"").equals(warnExeRecord.getWarnState())){
return true;
}
warnExeRecord.setEndTime(currentTime); warnExeRecord.setEndTime(currentTime);
warnExeRecord.setWarnState(WarnStateEnum.OVER.getValue()+""); warnExeRecord.setWarnState(WarnStateEnum.OVER.getValue()+"");
} }
......
...@@ -15,6 +15,8 @@ public class WarnSettingConstant { ...@@ -15,6 +15,8 @@ public class WarnSettingConstant {
/** 最近预警时间 */ /** 最近预警时间 */
public static final String RECENTLY_TIME = "recentlyTime"; public static final String RECENTLY_TIME = "recentlyTime";
public static final String WARN_STATE = "warnState";
/** /**
* 超采预警类型 * 超采预警类型
...@@ -29,7 +31,18 @@ public class WarnSettingConstant { ...@@ -29,7 +31,18 @@ public class WarnSettingConstant {
/** /**
* 许可证船只进入告警区类型 * 许可证船只进入告警区类型
*/ */
public static final String SAND_SHIP_WARN_BILL_TYPE = "采区船只预警"; public static final String SAND_SHIP_WARN_BILL_TYPE = "采区船只报警";
/**
* 许可证船只进入告警区指标-进入告警区
*/
public static final String SAND_SHIP_WARN_TARGET_ENTER_WARNING_AREA = "进入告警区";
/**
* 许可证船只进入告警区指标-非作业时间进入采砂区
*/
public static final String SAND_SHIP_WARN_TARGET_NO_OPERATING_HOURS = "非作业时间进入采砂区";
} }
package com.xyst.dinas.biz.warn; package com.xyst.dinas.biz.warn;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.UUID; import java.util.UUID;
import com.xyst.dinas.biz.enumeration.WarnStateEnum;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.Assert; import org.springframework.util.Assert;
...@@ -34,6 +36,8 @@ public class WarningServiceImpl implements WarningService{ ...@@ -34,6 +36,8 @@ public class WarningServiceImpl implements WarningService{
JsonNode json = JSONObjectUtils.toJson(warnSetting); JsonNode json = JSONObjectUtils.toJson(warnSetting);
KObject object = JSONObjectUtils.toObject(json, type); KObject object = JSONObjectUtils.toObject(json, type);
object.set(BaseConstants.CREATE_TIME, LocalDateTime.now()); object.set(BaseConstants.CREATE_TIME, LocalDateTime.now());
object.set(BaseConstants.DEL,false);
object.set(BaseConstants.DISCARD,false);
return warnSettingDao.create(object); return warnSettingDao.create(object);
} }
...@@ -60,7 +64,8 @@ public class WarningServiceImpl implements WarningService{ ...@@ -60,7 +64,8 @@ public class WarningServiceImpl implements WarningService{
* 结束一条预警设置的预警执行记录 * 结束一条预警设置的预警执行记录
* @param warnSettingId * @param warnSettingId
*/ */
public void endWarnStateBySettingId(UUID warnSettingId) { @Override
public void endWarnStateBySettingId(UUID warnSettingId) {
KObject warnExeRecord = warnSettingDao.queryWarnExeRecordBySettingId(warnSettingId); KObject warnExeRecord = warnSettingDao.queryWarnExeRecordBySettingId(warnSettingId);
warnSettingDao.endWarnRecordState(warnExeRecord); warnSettingDao.endWarnRecordState(warnExeRecord);
...@@ -86,7 +91,19 @@ public class WarningServiceImpl implements WarningService{ ...@@ -86,7 +91,19 @@ public class WarningServiceImpl implements WarningService{
return null; return null;
} }
@Override @Override
public void ignoreWarnExeRecord(UUID id) {
KObject kObject = warnSettingDao.queryWarningExeById(id);
kObject.set(WarnSettingConstant.WARN_STATE, WarnStateEnum.IGNORE.getValue()+"");
warnSettingDao.update(kObject);
}
@Override
public HashMap<String, Object> warnRecodeGroupInfo(List<UUID> regionalCompanyIds, List<String> targets) {
return warnSettingDao.warnRecodeGroupInfo(regionalCompanyIds,targets);
}
@Override
public void updateWarnExe(WarnExeRecord warnExeRecord) { public void updateWarnExe(WarnExeRecord warnExeRecord) {
KClass type = Amino.getApplicationMetadataContext().getBean(WarnSettingConstant.ENTITY_WARNINGEXE, KClass.class); KClass type = Amino.getApplicationMetadataContext().getBean(WarnSettingConstant.ENTITY_WARNINGEXE, KClass.class);
JsonNode json = JSONObjectUtils.toJson(warnExeRecord); JsonNode json = JSONObjectUtils.toJson(warnExeRecord);
...@@ -122,12 +139,41 @@ public class WarningServiceImpl implements WarningService{ ...@@ -122,12 +139,41 @@ public class WarningServiceImpl implements WarningService{
warSettingIdObj.set("min", min); warSettingIdObj.set("min", min);
String max = warnSetting.getMax(); String max = warnSetting.getMax();
warSettingIdObj.set("max", max); warSettingIdObj.set("max", max);
warnSettingDao.update(warSettingIdObj); warnSettingDao.update(warSettingIdObj);
} }
/**
private String UuidListToString(List<UUID> uuids) { * 删除预警设置
*
* @param warnSettingId
*/
@Override
public void deleteWarnSetting(UUID warnSettingId) {
KObject kObject = warnSettingDao.queryWarnSettingById(warnSettingId);
kObject.set("del",true);
kObject.set("discard",true);
warnSettingDao.update(kObject);
}
/**
* 删除预警设置
*
* @param billType
* @param billId
* @param target
*/
@Override
public void deleteWarnSetting(String billType, UUID billId, String target) {
WarnSetting warnSetting = warnSettingDao.getWarnSetting(billType, billId, target);
KObject kObject = warnSettingDao.queryWarnSettingById(warnSetting.getSettingId());
kObject.set("del",true);
kObject.set("discard",true);
warnSettingDao.update(kObject);
}
private String UuidListToString(List<UUID> uuids) {
StringBuilder str = new StringBuilder(); StringBuilder str = new StringBuilder();
for (int i = 0; i < uuids.size(); i++) { for (int i = 0; i < uuids.size(); i++) {
if (i == uuids.size() - 1) { if (i == uuids.size() - 1) {
......
package com.xyst.dinas.biz.warn.service; package com.xyst.dinas.biz.warn.service;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.UUID; import java.util.UUID;
...@@ -20,8 +21,10 @@ public interface WarningService { ...@@ -20,8 +21,10 @@ public interface WarningService {
* @return * @return
*/ */
public UUID insertWarnSetting(WarnSetting warnSetting) ; public UUID insertWarnSetting(WarnSetting warnSetting) ;
WarnSetting getWarnSetting(@NonNull UUID warnSettingId); void endWarnStateBySettingId(UUID warnSettingId);
WarnSetting getWarnSetting(@NonNull UUID warnSettingId);
WarnSetting getWarnSetting(@NonNull String billType, @Nullable UUID billId, @Nullable String target); WarnSetting getWarnSetting(@NonNull String billType, @Nullable UUID billId, @Nullable String target);
/** /**
...@@ -36,6 +39,17 @@ public interface WarningService { ...@@ -36,6 +39,17 @@ public interface WarningService {
* @param warnSetting * @param warnSetting
*/ */
void updateWarnSetting(UpdateWarnSetting warnSetting); void updateWarnSetting(UpdateWarnSetting warnSetting);
/**
* 删除预警设置
* @param warnSettingId
*/
void deleteWarnSetting(@NonNull UUID warnSettingId);
/**
* 删除预警设置
*/
void deleteWarnSetting(@NonNull String billType, @Nullable UUID billId, @Nullable String target);
/***************************************/ /***************************************/
...@@ -64,4 +78,9 @@ public interface WarningService { ...@@ -64,4 +78,9 @@ public interface WarningService {
BaseBusinessWarn createWarn(@NonNull UUID warnSettingId); BaseBusinessWarn createWarn(@NonNull UUID warnSettingId);
void ignoreWarnExeRecord(UUID id);
HashMap<String, Object> warnRecodeGroupInfo(List<UUID> regionalCompanyIds, List<String> targets);
} }
...@@ -133,6 +133,26 @@ public class DinasCommonController { ...@@ -133,6 +133,26 @@ public class DinasCommonController {
* @param date * @param date
* @return * @return
*/ */
@GetMapping("/sand/user/planningCycleObj/{planningCycle}/{date}")
public KObject getPlanningCycleObjBySand(@PathVariable String planningCycle,@PathVariable @DateTimeFormat(pattern = "yyyy-MM-dd") Date date) {
PlanningCycleEnum planningCycleType = null;
if (PlanningCycleEnum.DAY.name().equalsIgnoreCase(planningCycle)) {
planningCycleType = PlanningCycleEnum.DAY;
}else if (PlanningCycleEnum.WEEK.name().equalsIgnoreCase(planningCycle)) {
planningCycleType = PlanningCycleEnum.WEEK;
}else {
return null;
}
return planningCycleService.getPlanningCycleObj(planningCycleType, date);
}
/**
* 获取指定日期和计划周期类型的计划周期实体
* @param planningCycleType 计划周期
* @param date
* @return
*/
@GetMapping("/planningCycleObj/{planningCycle}/{date}") @GetMapping("/planningCycleObj/{planningCycle}/{date}")
public KObject getPlanningCycleObj(@PathVariable String planningCycle,@PathVariable @DateTimeFormat(pattern = "yyyy-MM-dd") Date date) { public KObject getPlanningCycleObj(@PathVariable String planningCycle,@PathVariable @DateTimeFormat(pattern = "yyyy-MM-dd") Date date) {
......
...@@ -119,11 +119,11 @@ public class SandMiningAreaController { ...@@ -119,11 +119,11 @@ public class SandMiningAreaController {
return ResponseObj.success("预警设置更新成功"); return ResponseObj.success("预警设置更新成功");
} }
//更新预警设置 //忽略预警记录
@GetMapping("/warnRecode/ignore")//采区预警设置更新 @GetMapping("/warnRecode/ignore")
public ResponseObj ignoreWarnExe(UUID id) { public ResponseObj ignoreWarnExe(@RequestParam("id")UUID id) {
warningSettingService.queryWarnExeRecord(id); warningSettingService.ignoreWarnExeRecord(id);
return ResponseObj.success("预警设置更新成功"); return ResponseObj.success("忽略成功");
} }
......
...@@ -5,6 +5,8 @@ import java.util.ArrayList; ...@@ -5,6 +5,8 @@ import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.UUID; import java.util.UUID;
import javax.servlet.http.HttpServletRequest;
import org.json.JSONArray; import org.json.JSONArray;
import org.json.JSONObject; import org.json.JSONObject;
import org.slf4j.Logger; import org.slf4j.Logger;
...@@ -36,6 +38,12 @@ import com.beecode.bcp.biz.BusinessException; ...@@ -36,6 +38,12 @@ import com.beecode.bcp.biz.BusinessException;
import com.beecode.bcp.query.scene.ScenePrecidate; import com.beecode.bcp.query.scene.ScenePrecidate;
import com.beecode.bcp.type.KObject; import com.beecode.bcp.type.KObject;
import com.beecode.bcp.type.json.JSONObjectUtils; import com.beecode.bcp.type.json.JSONObjectUtils;
import com.beecode.inz.common.BatchDeleteItem;
import com.beecode.inz.common.BatchDiscardItem;
import com.beecode.inz.common.BatchUpdatePICItem;
import com.beecode.inz.common.enumeration.BatchOperationEnum;
import com.beecode.inz.common.service.CommonService;
import com.beecode.inz.common.service.FollowerService;
import com.beecode.inz.query.define.QueryDefinition; import com.beecode.inz.query.define.QueryDefinition;
import com.beecode.inz.query.entity.PaginationResult; import com.beecode.inz.query.entity.PaginationResult;
import com.beecode.inz.query.exception.QueryException; import com.beecode.inz.query.exception.QueryException;
...@@ -61,6 +69,15 @@ public class SandQueryController { ...@@ -61,6 +69,15 @@ public class SandQueryController {
private PrivilegeService privilegeService; private PrivilegeService privilegeService;
@Autowired @Autowired
private HttpServletRequest request;
@Autowired
private CommonService commonService;
@Autowired
private FollowerService followerService;
@Autowired
MultipartProperties multipartProperties; MultipartProperties multipartProperties;
...@@ -69,6 +86,95 @@ public class SandQueryController { ...@@ -69,6 +86,95 @@ public class SandQueryController {
private static final ObjectMapper OBJECTMAPPER = new ObjectMapper(); private static final ObjectMapper OBJECTMAPPER = new ObjectMapper();
@ResponseBody @ResponseBody
@RequestMapping(value = "/sand/user/common/batch", method = RequestMethod.PUT)
public void batchOperation(@RequestBody String body){
String operation = request.getHeader("operation");
BatchOperationEnum oper = null;
try {
oper = BatchOperationEnum.valueOf(operation.toUpperCase());
} catch (Exception e) {
logger.error("not support common batch operation,operation: {}", operation);
throw new UnsupportedOperationException("not support common batch operation,operation: " + operation);
}
switch (oper) {
case BATCH_UPDATE_PIC:
BatchUpdatePICItem[] batchUpdatePICs = handleBatchUpdatePICInputs(body);
commonService.batchUpdatePIC(batchUpdatePICs);
//如果负责人已经在相关团队里面了,从相关团队里面移除
for (BatchUpdatePICItem batchUpdatePICItem : batchUpdatePICs) {
UUID[] entityIds = batchUpdatePICItem.getIds();
for (UUID entityID : entityIds) {
followerService.removeStaff(batchUpdatePICItem.getDatamodelName(), entityID, batchUpdatePICItem.getPic().getId());
}
}
return;
case BATCH_DISCARD:
BatchDiscardItem[] batchDiscards = handleBatchDiscardInputs(body);
commonService.batchDiscard(batchDiscards);
return;
case BATCH_DELETE:
BatchDeleteItem[] batchDeletes = handleBatchDeleteInputs(body);
commonService.batchDelete(batchDeletes);
return;
default:
logger.error("not support common batch operation,operation: {}", operation);
throw new UnsupportedOperationException("not support common batch operation,operation: " + operation);
}
}
private BatchUpdatePICItem[] handleBatchUpdatePICInputs(String body){
try{
List<BatchUpdatePICItem> list = new ArrayList<BatchUpdatePICItem>();
JSONArray arr = new JSONArray(body);
if(arr.length() == 0){
throw new RuntimeException("batch update PIC items must not be 0!");
}
for(int i = 0; i < arr.length(); i ++){
list.add(new BatchUpdatePICItem(arr.getJSONObject(i)));
};
return list.toArray(new BatchUpdatePICItem[0]);
}catch(Exception e){
logger.error("illegal Argument,body: {}", body);
throw new IllegalArgumentException("illegal Argument,body: " + body, e);
}
}
private BatchDiscardItem[] handleBatchDiscardInputs(String body){
try{
List<BatchDiscardItem> list = new ArrayList<BatchDiscardItem>();
JSONArray arr = new JSONArray(body);
if(arr.length() == 0){
throw new RuntimeException("batch discard items must not be 0!");
}
for(int i = 0; i < arr.length(); i ++){
list.add(new BatchDiscardItem(arr.getJSONObject(i)));
};
return list.toArray(new BatchDiscardItem[0]);
}catch(Exception e){
logger.error("illegal Argument,body: {}", body);
throw new IllegalArgumentException("illegal Argument,body: " + body, e);
}
}
private BatchDeleteItem[] handleBatchDeleteInputs(String body) {
try{
List<BatchDeleteItem> list = new ArrayList<BatchDeleteItem>();
JSONArray arr = new JSONArray(body);
if(arr.length() == 0){
throw new RuntimeException("batch delete items must not be 0!");
}
for(int i = 0; i < arr.length(); i ++){
list.add(new BatchDeleteItem(arr.getJSONObject(i)));
};
return list.toArray(new BatchDeleteItem[0]);
}catch(Exception e){
logger.error("illegal Argument,body: {}", body);
throw new IllegalArgumentException("illegal Argument,body: " + body, e);
}
}
@ResponseBody
@RequestMapping(value="/sand/user/common/config/getMaxFileSize", method = RequestMethod.GET, consumes = "application/json") @RequestMapping(value="/sand/user/common/config/getMaxFileSize", method = RequestMethod.GET, consumes = "application/json")
public String getMaxFileSize() { public String getMaxFileSize() {
JSONObject o = new JSONObject(); JSONObject o = new JSONObject();
......
...@@ -5,6 +5,8 @@ import java.util.ArrayList; ...@@ -5,6 +5,8 @@ import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.UUID; import java.util.UUID;
import javax.servlet.http.HttpServletRequest;
import org.json.JSONArray; import org.json.JSONArray;
import org.json.JSONObject; import org.json.JSONObject;
import org.slf4j.Logger; import org.slf4j.Logger;
...@@ -36,6 +38,12 @@ import com.beecode.bcp.biz.BusinessException; ...@@ -36,6 +38,12 @@ import com.beecode.bcp.biz.BusinessException;
import com.beecode.bcp.query.scene.ScenePrecidate; import com.beecode.bcp.query.scene.ScenePrecidate;
import com.beecode.bcp.type.KObject; import com.beecode.bcp.type.KObject;
import com.beecode.bcp.type.json.JSONObjectUtils; import com.beecode.bcp.type.json.JSONObjectUtils;
import com.beecode.inz.common.BatchDeleteItem;
import com.beecode.inz.common.BatchDiscardItem;
import com.beecode.inz.common.BatchUpdatePICItem;
import com.beecode.inz.common.enumeration.BatchOperationEnum;
import com.beecode.inz.common.service.CommonService;
import com.beecode.inz.common.service.FollowerService;
import com.beecode.inz.query.define.QueryDefinition; import com.beecode.inz.query.define.QueryDefinition;
import com.beecode.inz.query.entity.PaginationResult; import com.beecode.inz.query.entity.PaginationResult;
import com.beecode.inz.query.exception.QueryException; import com.beecode.inz.query.exception.QueryException;
...@@ -61,6 +69,15 @@ public class WarehouseQueryController { ...@@ -61,6 +69,15 @@ public class WarehouseQueryController {
private PrivilegeService privilegeService; private PrivilegeService privilegeService;
@Autowired @Autowired
private HttpServletRequest request;
@Autowired
private CommonService commonService;
@Autowired
private FollowerService followerService;
@Autowired
MultipartProperties multipartProperties; MultipartProperties multipartProperties;
...@@ -69,6 +86,95 @@ public class WarehouseQueryController { ...@@ -69,6 +86,95 @@ public class WarehouseQueryController {
private static final ObjectMapper OBJECTMAPPER = new ObjectMapper(); private static final ObjectMapper OBJECTMAPPER = new ObjectMapper();
@ResponseBody @ResponseBody
@RequestMapping(value = "/warehouse/api/common/batch", method = RequestMethod.PUT)
public void batchOperation(@RequestBody String body){
String operation = request.getHeader("operation");
BatchOperationEnum oper = null;
try {
oper = BatchOperationEnum.valueOf(operation.toUpperCase());
} catch (Exception e) {
logger.error("not support common batch operation,operation: {}", operation);
throw new UnsupportedOperationException("not support common batch operation,operation: " + operation);
}
switch (oper) {
case BATCH_UPDATE_PIC:
BatchUpdatePICItem[] batchUpdatePICs = handleBatchUpdatePICInputs(body);
commonService.batchUpdatePIC(batchUpdatePICs);
//如果负责人已经在相关团队里面了,从相关团队里面移除
for (BatchUpdatePICItem batchUpdatePICItem : batchUpdatePICs) {
UUID[] entityIds = batchUpdatePICItem.getIds();
for (UUID entityID : entityIds) {
followerService.removeStaff(batchUpdatePICItem.getDatamodelName(), entityID, batchUpdatePICItem.getPic().getId());
}
}
return;
case BATCH_DISCARD:
BatchDiscardItem[] batchDiscards = handleBatchDiscardInputs(body);
commonService.batchDiscard(batchDiscards);
return;
case BATCH_DELETE:
BatchDeleteItem[] batchDeletes = handleBatchDeleteInputs(body);
commonService.batchDelete(batchDeletes);
return;
default:
logger.error("not support common batch operation,operation: {}", operation);
throw new UnsupportedOperationException("not support common batch operation,operation: " + operation);
}
}
private BatchUpdatePICItem[] handleBatchUpdatePICInputs(String body){
try{
List<BatchUpdatePICItem> list = new ArrayList<BatchUpdatePICItem>();
JSONArray arr = new JSONArray(body);
if(arr.length() == 0){
throw new RuntimeException("batch update PIC items must not be 0!");
}
for(int i = 0; i < arr.length(); i ++){
list.add(new BatchUpdatePICItem(arr.getJSONObject(i)));
};
return list.toArray(new BatchUpdatePICItem[0]);
}catch(Exception e){
logger.error("illegal Argument,body: {}", body);
throw new IllegalArgumentException("illegal Argument,body: " + body, e);
}
}
private BatchDiscardItem[] handleBatchDiscardInputs(String body){
try{
List<BatchDiscardItem> list = new ArrayList<BatchDiscardItem>();
JSONArray arr = new JSONArray(body);
if(arr.length() == 0){
throw new RuntimeException("batch discard items must not be 0!");
}
for(int i = 0; i < arr.length(); i ++){
list.add(new BatchDiscardItem(arr.getJSONObject(i)));
};
return list.toArray(new BatchDiscardItem[0]);
}catch(Exception e){
logger.error("illegal Argument,body: {}", body);
throw new IllegalArgumentException("illegal Argument,body: " + body, e);
}
}
private BatchDeleteItem[] handleBatchDeleteInputs(String body) {
try{
List<BatchDeleteItem> list = new ArrayList<BatchDeleteItem>();
JSONArray arr = new JSONArray(body);
if(arr.length() == 0){
throw new RuntimeException("batch delete items must not be 0!");
}
for(int i = 0; i < arr.length(); i ++){
list.add(new BatchDeleteItem(arr.getJSONObject(i)));
};
return list.toArray(new BatchDeleteItem[0]);
}catch(Exception e){
logger.error("illegal Argument,body: {}", body);
throw new IllegalArgumentException("illegal Argument,body: " + body, e);
}
}
@ResponseBody
@RequestMapping(value="/warehouse/api/common/config/getMaxFileSize", method = RequestMethod.GET, consumes = "application/json") @RequestMapping(value="/warehouse/api/common/config/getMaxFileSize", method = RequestMethod.GET, consumes = "application/json")
public String getMaxFileSize() { public String getMaxFileSize() {
JSONObject o = new JSONObject(); JSONObject o = new JSONObject();
......
package com.xyst.dinas.biz.web; package com.xyst.dinas.biz.web;
import java.util.HashMap;
import java.util.List;
import java.util.UUID; import java.util.UUID;
import org.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.Assert; import org.springframework.util.Assert;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import com.beecode.bcp.type.KObject; import com.beecode.bcp.type.KObject;
import com.xyst.dinas.biz.request.UpdateWarnSetting; import com.beecode.inz.basis.team.pojo.ResponseObj;
import com.xyst.dinas.biz.warn.service.WarningService; import com.xyst.dinas.biz.warn.service.WarningService;
/** /**
...@@ -42,6 +42,16 @@ public class WarnSettingController { ...@@ -42,6 +42,16 @@ public class WarnSettingController {
Assert.notNull(id,"The id must not be null"); Assert.notNull(id,"The id must not be null");
return warningSettingService.queryWarnSettingById(id); return warningSettingService.queryWarnSettingById(id);
} }
//查询预警汇总信息
@GetMapping("/warnRecode/groupInfo")
public ResponseObj groupInfo(@RequestParam(name = "regionalCompanyIds") List<UUID> regionalCompanyIds, @RequestParam(name = "targets")List<String> targets) {
HashMap<String,Object> groupInfo = warningSettingService.warnRecodeGroupInfo(regionalCompanyIds,targets);
return ResponseObj.success("查询成功", groupInfo);
}
} }
...@@ -46,6 +46,15 @@ ...@@ -46,6 +46,15 @@
</ref> </ref>
<description></description> <description></description>
</field> </field>
<field title='业务类型'>
<name>billType</name>
<type>string</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='预警指标'> <field title='预警指标'>
<name>target</name> <name>target</name>
<type>string</type> <type>string</type>
......
...@@ -60,6 +60,16 @@ ...@@ -60,6 +60,16 @@
<m:desc></m:desc> <m:desc></m:desc>
</m:field> </m:field>
<m:field> <m:field>
<m:name>billType</m:name>
<m:title>业务类型</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>target</m:name> <m:name>target</m:name>
<m:title>预警指标</m:title> <m:title>预警指标</m:title>
<m:type>string</m:type> <m:type>string</m:type>
......
...@@ -2,6 +2,7 @@ package com.xyst.dinas.production.internal.service; ...@@ -2,6 +2,7 @@ package com.xyst.dinas.production.internal.service;
import com.beecode.bap.attachment.common.Page; import com.beecode.bap.attachment.common.Page;
import com.beecode.bcp.type.KObject; import com.beecode.bcp.type.KObject;
import com.xyst.dinas.biz.warn.WarnSetting;
import com.xyst.dinas.biz.warn.WarnSettingConstant; import com.xyst.dinas.biz.warn.WarnSettingConstant;
import com.xyst.dinas.biz.warn.WarnSettingEntity; import com.xyst.dinas.biz.warn.WarnSettingEntity;
import com.xyst.dinas.biz.warn.service.WarningService; import com.xyst.dinas.biz.warn.service.WarningService;
...@@ -39,7 +40,7 @@ public class SandMiningServiceImpl implements SandMiningService { ...@@ -39,7 +40,7 @@ public class SandMiningServiceImpl implements SandMiningService {
WarnSettingEntity warnSetting = new WarnSettingEntity(); WarnSettingEntity warnSetting = new WarnSettingEntity();
warnSetting.setBillType(WarnSettingConstant.SAND_SHIP_WARN_BILL_TYPE); warnSetting.setBillType(WarnSettingConstant.SAND_SHIP_WARN_BILL_TYPE);
warnSetting.setBillId(uuid); warnSetting.setBillId(uuid);
warnSetting.setTarget("进入告警区"); warnSetting.setTarget(WarnSettingConstant.SAND_SHIP_WARN_TARGET_ENTER_WARNING_AREA);
warnSetting.setOpen(false); warnSetting.setOpen(false);
warnSetting.setMemo(getSandShipInfo(kObject)); warnSetting.setMemo(getSandShipInfo(kObject));
warningSettingService.insertWarnSetting(warnSetting); warningSettingService.insertWarnSetting(warnSetting);
...@@ -47,7 +48,7 @@ public class SandMiningServiceImpl implements SandMiningService { ...@@ -47,7 +48,7 @@ public class SandMiningServiceImpl implements SandMiningService {
WarnSettingEntity warnSetting1 = new WarnSettingEntity(); WarnSettingEntity warnSetting1 = new WarnSettingEntity();
warnSetting1.setBillType(WarnSettingConstant.SAND_SHIP_WARN_BILL_TYPE); warnSetting1.setBillType(WarnSettingConstant.SAND_SHIP_WARN_BILL_TYPE);
warnSetting1.setBillId(uuid); warnSetting1.setBillId(uuid);
warnSetting1.setTarget("非作业时间采砂"); warnSetting1.setTarget(WarnSettingConstant.SAND_SHIP_WARN_TARGET_NO_OPERATING_HOURS);
warnSetting1.setOpen(false); warnSetting1.setOpen(false);
warnSetting1.setMemo(getSandShipInfo(kObject)); warnSetting1.setMemo(getSandShipInfo(kObject));
warningSettingService.insertWarnSetting(warnSetting1); warningSettingService.insertWarnSetting(warnSetting1);
...@@ -84,6 +85,23 @@ public class SandMiningServiceImpl implements SandMiningService { ...@@ -84,6 +85,23 @@ public class SandMiningServiceImpl implements SandMiningService {
@Override @Override
public void deleteById(UUID id) { public void deleteById(UUID id) {
sandMiningDao.deleteById(id); sandMiningDao.deleteById(id);
//删除预警设置 结束预警记录
//进入告警区的
WarnSetting warnSetting = warningSettingService.getWarnSetting(WarnSettingConstant.SAND_SHIP_WARN_BILL_TYPE, id, WarnSettingConstant.SAND_SHIP_WARN_TARGET_ENTER_WARNING_AREA);
if(null!=warnSetting){
warningSettingService.deleteWarnSetting(warnSetting.getSettingId());
warningSettingService.endWarnStateBySettingId(warnSetting.getSettingId());
}
//非作业时间采砂的
WarnSetting warnSetting1 = warningSettingService.getWarnSetting(WarnSettingConstant.SAND_SHIP_WARN_BILL_TYPE, id, WarnSettingConstant.SAND_SHIP_WARN_TARGET_NO_OPERATING_HOURS);
if(null!=warnSetting1){
warningSettingService.deleteWarnSetting(warnSetting1.getSettingId());
warningSettingService.endWarnStateBySettingId(warnSetting1.getSettingId());
}
} }
@Override @Override
......
...@@ -161,4 +161,16 @@ public class DischargingController { ...@@ -161,4 +161,16 @@ public class DischargingController {
return ResponseObj.success(); return ResponseObj.success();
} }
//接驳统计
// @RequestMapping(value = "groupInfoByYear", method = RequestMethod.GET)
// public ResponseObj groupInfo(
// @RequestParam(name = "regionalCompanyIds", required = false) List<UUID> regionalCompanyIds,
// @RequestParam(name = "year", required = false) List<UUID> regionalCompanyIds,
// ) throws Exception {
//
// return ResponseObj.success("查询成功", dischargingService.groupInfo(transportShipId,type,startDate,endDate,sandMiningAreaType,stationIds,sandMiningAreaId,sandMiningShipId,parentId));
// }
} }
\ No newline at end of file
...@@ -35,7 +35,6 @@ public class SandMiningController { ...@@ -35,7 +35,6 @@ public class SandMiningController {
@RequestParam(name = "pageSize") Integer pageSize, @RequestParam(name = "pageSize") Integer pageSize,
@RequestParam(name = "sandMiningStatus", required = false) Integer sandMiningStatus @RequestParam(name = "sandMiningStatus", required = false) Integer sandMiningStatus
) throws Exception { ) throws Exception {
Page<KObject> objectPage = new Page<>(); Page<KObject> objectPage = new Page<>();
objectPage.setPageNo(pageNo); objectPage.setPageNo(pageNo);
objectPage.setPageSize(pageSize); objectPage.setPageSize(pageSize);
......
...@@ -50,6 +50,16 @@ ...@@ -50,6 +50,16 @@
<m:desc></m:desc> <m:desc></m:desc>
</m:field> </m:field>
<m:field> <m:field>
<m:name>warnSetting.billType</m:name>
<m:title>预警指标</m:title>
<m:type>com.xyst.dinas.biz.datamodel.WarnSetting</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>startTime</m:name> <m:name>startTime</m:name>
<m:title>开始时间</m:title> <m:title>开始时间</m:title>
<m:type>datetime</m:type> <m:type>datetime</m:type>
......
...@@ -104,4 +104,16 @@ public class SalesPlanDao { ...@@ -104,4 +104,16 @@ public class SalesPlanDao {
}); });
} }
public List<KObject> querySalesPlanDetailsByMasterIdWarehouse(UUID salesPlanId, UUID stationId) {
return template.execute(session ->{
String hql = "from " + SalesPlanConstant.ENTITY_DETAIL + " where master.id =:salesPlanId and station.id =:stationId GROUP BY purchaseSandUnit.id, project.id, contract.id, id ";
Query<KObject> query = session.createQuery(hql, KObject.class);
query.setParameter("salesPlanId", salesPlanId);
query.setParameter("stationId", stationId);
List<KObject> resultList = query.getResultList();
return resultList;
});
}
} }
...@@ -119,6 +119,14 @@ public class SalesPlanServiceImpl implements SalesPlanService{ ...@@ -119,6 +119,14 @@ public class SalesPlanServiceImpl implements SalesPlanService{
kObject.set("SalesPlanDetails", details); kObject.set("SalesPlanDetails", details);
return kObject; return kObject;
} }
@Override
public Object querySalesPlanDetailsByMasterIdWarehouse(UUID salesPlanId, UUID stationId) {
KObject kObject = salesPlanDao.load(salesPlanId);
List<KObject> details = salesPlanDao.querySalesPlanDetailsByMasterIdWarehouse(salesPlanId, stationId);
kObject.set("SalesPlanDetails", details);
return kObject;
}
......
...@@ -40,5 +40,7 @@ public interface SalesPlanService { ...@@ -40,5 +40,7 @@ public interface SalesPlanService {
public void approveSalesPlanForTemp(UUID id,int approveState,String approveMemo); public void approveSalesPlanForTemp(UUID id,int approveState,String approveMemo);
public Object querySalesPlanDetailsByMasterId(UUID fromString); public Object querySalesPlanDetailsByMasterId(UUID fromString);
public Object querySalesPlanDetailsByMasterIdWarehouse(UUID fromString, UUID fromString2);
} }
...@@ -88,8 +88,19 @@ public class SalesPlanController { ...@@ -88,8 +88,19 @@ public class SalesPlanController {
*/ */
@ResponseBody @ResponseBody
@RequestMapping(value = "/salesplan/querySalesPlanDetailsByMasterId", method = RequestMethod.GET) @RequestMapping(value = "/salesplan/querySalesPlanDetailsByMasterId", method = RequestMethod.GET)
public Object verifyName(@RequestParam("saleaPlanId") String saleaPlanId) { public Object querySalesPlanDetailsByMasterId(@RequestParam("saleaPlanId") String saleaPlanId) {
return ResponseObj.success("success", salesPlanService.querySalesPlanDetailsByMasterId(UUID.fromString(saleaPlanId))); return ResponseObj.success("success", salesPlanService.querySalesPlanDetailsByMasterId(UUID.fromString(saleaPlanId)));
} }
/**
* 根据销售计划id查询计划明细(分组)场站用户
* @param saleaPlanId
* @return
*/
@ResponseBody
@RequestMapping(value = "/warehouse/api/salesplan/querySalesPlanDetailsByMasterId", method = RequestMethod.GET)
public Object querySalesPlanDetailsByMasterIdWarehouse(@RequestParam("saleaPlanId") String saleaPlanId, @RequestParam("stationId") String stationId) {
return ResponseObj.success("success", salesPlanService.querySalesPlanDetailsByMasterIdWarehouse(UUID.fromString(saleaPlanId), UUID.fromString(stationId)));
}
} }
<model>
<header>
<type>bcp.type.DataModel</type>
<package>com.xyst.dinas.sales.datamodel</package>
<title>销售台账</title>
<name>SalesRecord</name>
<tags></tags>
<description>销售台账</description>
<templateName>mk.ide.ui.editor.data.model.template.bill</templateName>
<tablePrefix>xyst_dinas_sales_</tablePrefix>
</header>
<content>
<dataModel id='bfc7131b-d5ff-4f08-ad20-1500b5946520' multiVersion='' domainInherit='undefined' tableName='xyst_dinas_sales_record'>
<parent>com.beecode.bap.biztrait.datamodel.StoreMainTableRequirement</parent>
<parent>com.beecode.inz.common.datamodel.BaseInfo</parent>
<attribute id='ef9bb259-9746-4f38-bb70-e1159966297d' name='createTime' title='创建时间' type='datetime' default='' precision='' isArray='false'>
</attribute>
<attribute id='ca273c9d-0981-4f6d-94b4-4a3b76742a1e' name='modifyTime' title='修改时间' type='datetime' default='' precision='' isArray='false'>
</attribute>
<attribute id='abea2870-1ac4-404e-bc4b-b1673e718520' name='project' columnName='project_id' title='项目' type='com.xyst.dinas.project.datamodel.ProjectFiled' default='' precision='' isArray='false'>
<annotation id='0b313200-1cc3-4993-ba99-87635a3db90d' attributeId='9e4d26e3-f2ff-4970-b7d6-97a220f1db45' name='length' value='undefined'></annotation>
<annotation id='ac444b70-c3de-4855-bddc-426530b65175' attributeId='08e34b10-3948-42de-89e5-d27da7eb28ae' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='c1127719-c3c7-47a9-bdc5-3bb4e377cb5f' name='regionalCompany' columnName='regional_company_id' title='区域公司' type='com.xyst.dinas.biz.datamodel.Organization' default='' precision='' isArray='false'>
<annotation id='2081312d-7ad9-4002-99fb-8ae3a7e8de80' attributeId='11b55409-4df5-45c3-8d5f-fe55bb2206c3' name='length' value='undefined'></annotation>
<annotation id='5a733091-6283-48cf-9cac-0963e852b43e' attributeId='d42df0f8-cd8b-4d54-910f-ea76d8c85d15' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='970577bc-d8d2-4f4e-89e5-5f00a10dc8a2' name='contract' columnName='contract_id' title='合同' type='com.xyst.dinas.contract.datamodel.Contract' default='' precision='' isArray='false'>
<annotation id='916dea94-3c48-4bf8-ace3-d706146fea01' attributeId='f19e66ee-c414-4a3d-9c27-bd6e4a7a9d3e' name='length' value='undefined'></annotation>
<annotation id='90f40008-4bcf-4460-823e-2e871546f2b0' attributeId='848a53fe-4a54-4a61-bc82-79aa59d0350a' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='302a145d-c461-4524-8c04-61672080b8da' name='purchaseSandCompany' columnName='purchase_sand_company_id' title='购砂单位' type='com.xyst.dinas.project.datamodel.PurchaseSandCompany' default='' precision='' isArray='false'>
<annotation id='e066e806-9a51-4afd-8a2e-9b82015abb81' attributeId='76efcfd0-78f0-4978-8fdc-500cf6d7079c' name='length' value='undefined'></annotation>
<annotation id='ab7b9c40-302a-45ab-9eee-215357b782e5' attributeId='ba277f8b-6b82-46cb-bedd-d8b6861d281f' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='a2d1d0c4-4dee-44d7-89a2-15c53fc879bd' name='station' columnName='station_id' title='场站' type='com.xyst.dinas.biz.datamodel.Station' default='' precision='' isArray='false'>
<annotation id='125a63f1-c11d-4433-88e5-cfc8cee0f7fe' attributeId='80eb92e9-ca45-49c3-bc6a-c0f470296c2d' name='length' value='undefined'></annotation>
<annotation id='45d8448b-4388-467b-b495-bb97a5e43b69' attributeId='e2eafb9d-a3e2-42f6-90fe-691e4586f6d5' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='0ba03ee9-2a71-4d3b-8f84-cdff871b80d2' name='productionLine' columnName='production_line_id' title='生产线' type='com.xyst.dinas.biz.datamodel.ProductionLine' default='' precision='' isArray='false'>
<annotation id='e03b0863-da6f-43e4-b65a-8f62438b0647' attributeId='8acbe217-8d38-45bc-bb9a-90756f1272e4' name='length' value='undefined'></annotation>
<annotation id='166c3674-5f7f-453f-836a-38cf7663ed5f' attributeId='3aa49fb7-340b-43fc-a93a-736232ca272a' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='37f7cb1f-2426-49d7-af70-e0f573fe4f00' name='retailInfo' columnName='retail_info_id' title='散户' type='com.xyst.dinas.biz.datamodel.RetailInfo' default='' precision='' isArray='false'>
<annotation id='88bcad4f-7d3e-4912-9518-de8982104022' attributeId='90d6ec8c-ee9b-4d96-b03f-cda71b2cd8c8' name='length' value='undefined'></annotation>
<annotation id='6b62d994-9ec7-4e26-a5cd-51bd08c9a53d' attributeId='b4c4758c-95c7-4847-8992-d4313d3240a0' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='34f0a228-faa0-4465-9c2c-4ec8b6fb6e43' name='dinasType' columnName='dinas_type_id' title='砂石种类' type='com.xyst.dinas.biz.datamodel.DinasType' default='' precision='' isArray='false'>
<annotation id='dc33cc92-a26a-49d3-a397-544041e0a78e' attributeId='b38113c0-08d7-46ad-94e8-f2738826024d' name='length' value='undefined'></annotation>
<annotation id='1d48af9f-11de-4f14-8dc8-bd66fa69898b' attributeId='52ca140c-60ae-4a98-816f-b223c93a69a7' name='mappingType' value='many-to-one'></annotation>
</attribute>
<attribute id='9ed97388-563a-4634-a555-b56bb1664dd0' name='customerType' columnName='customer_type' title='客户类型' type='string' default='' precision='' isArray='false'>
<annotation id='9f44e7df-2ecb-490d-a420-2f53f09e3c38' attributeId='fe172826-06ad-4e73-9a8c-5dbab39d0394' name='length' value='20'></annotation>
</attribute>
<attribute id='46656ba1-31bc-4b40-a63d-4a2a4b9f7944' name='dealTime' columnName='deal_time' title='销售时间' type='datetime' default='' precision='' isArray='false'>
<annotation id='18fc1ef9-5b5c-4000-a2d9-7a5d3e5a2fd5' attributeId='b6d2026b-a671-4054-86f2-cce248a72464' name='length' value='50'></annotation>
</attribute>
<attribute id='b01e62bc-ee7b-4470-b695-a78292348d83' name='syncTime' columnName='sync_time' title='同步时间' type='datetime' default='' precision='' isArray='false'>
<annotation id='09e719cd-4d0b-42aa-823d-3af534d95c73' attributeId='d7b8947c-0459-4b7e-a6a8-4acb0416a391' name='length' value='50'></annotation>
</attribute>
<attribute id='9ed97388-563a-4634-a555-b56bb1664dd0' name='carInfo' columnName='car_info' title='车辆信息' type='string' default='' precision='' isArray='false'>
<annotation id='9f44e7df-2ecb-490d-a420-2f53f09e3c38' attributeId='fe172826-06ad-4e73-9a8c-5dbab39d0394' name='length' value='20'></annotation>
</attribute>
<attribute id='d307fa81-7819-4216-887c-2a0fdffd3190' name='dealAmount' columnName='deal_amount' title='销售数量' type='fixnum' default='' precision='' isArray='false'>
<annotation id='8f3f5db5-4480-4a68-9399-cbec70cd118a' attributeId='cf1e0d8f-784b-4587-83a3-1167fc10042f' name='length' value='100'></annotation>
<annotation id='c342cc44-eabb-4f24-8872-b3cd6085b269' attributeId='1faca45c-ea26-47cc-a2ef-ae00daf88586' name='precision' value='12'></annotation>
<annotation id='ae5380d7-75c6-44ff-862f-c9d6c3af409d' attributeId='88762e9e-7c48-40e0-aac1-abcf20e9071a' name='scale' value='4'></annotation>
</attribute>
<attribute id='35c5c23b-bb32-4e2d-909a-712cfadd3519' name='price' columnName='price' title='单价' type='fixnum' default='' precision='' isArray='false'>
<annotation id='5efadf89-6201-4ee6-9088-473404a74f6d' attributeId='e846437b-1583-4068-9690-262ec2c98b61' name='length' value='100'></annotation>
<annotation id='d81f33ea-7612-45c3-9bdd-089af6abd635' attributeId='a5d530ef-9a7d-433e-93c3-240c9fbc7178' name='precision' value='12'></annotation>
<annotation id='f9331547-8e28-4001-9bc4-3ec7eba27583' attributeId='c785deaf-ff5f-4bb2-a1f5-56c01171249b' name='scale' value='2'></annotation>
</attribute>
<attribute id='183f4e16-b718-4d39-8e9f-f4c58978cf40' name='amount' columnName='amount' title='总价' type='fixnum' default='' precision='' isArray='false'>
<annotation id='25565de8-3953-4d8f-9529-391a0c3e0d26' attributeId='4051b501-63da-40a7-bcb4-378fb2490846' name='length' value='100'></annotation>
<annotation id='0bd515ea-8e8f-44f0-a164-ba4b8968fee3' attributeId='6d2151e5-4109-4ba9-ba58-fab898049169' name='precision' value='12'></annotation>
<annotation id='84f4043c-183b-4a8f-93c2-9724c357ad41' attributeId='9e00e008-c516-4176-b410-19010608e16d' name='scale' value='2'></annotation>
</attribute>
<attribute id='9b6efd34-a746-4808-b940-f7f2fd4ccca8' name='paymentSource' columnName='payment_source' title='付款来源' type='string' default='' precision='' isArray='false'>
<annotation id='d39fe1a2-0f6d-4a23-964e-32829f3d7834' attributeId='500a443c-9bc1-4b18-80b9-bf1ad5a090f7' name='length' value='50'></annotation>
</attribute>
<attribute id='7b72bf25-26fd-4e24-b3f9-67d4f4733ff2' name='dealBillCode' columnName='deal_bill_code' title='销售单号' type='string' default='' precision='' isArray='false'>
<annotation id='82dec9ef-61f8-4e17-ba12-4df0472b1e73' attributeId='511c5c00-ccf7-48cb-a7bb-1743a2b92e57' name='length' value='50'></annotation>
</attribute>
<hibernate>/xyst.dinas.sales/src/main/resources/config/SalesRecord.hbm.xml</hibernate>
</dataModel>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>inz.query.Query</type>
<package>com.xyst.dinas.sales.query</package>
<name>SalesRecord</name>
<title>销售台账</title>
<tags></tags>
<description></description>
</header>
<content>
<customQuery id='d5154782-eec0-44ed-8993-b7fc029d2fdf'>
<kclass>com.xyst.dinas.sales.datamodel.SalesRecord</kclass>
<dataProcessor></dataProcessor>
<authorityItem></authorityItem>
<innerScene title='全部'>
<id>d52de6d1-6252-42fb-bbb4-5d9a65b26ee7</id>
<javaImplement>com.beecode.inz.common.scene.CommonAllScene</javaImplement>
<defaultExecute></defaultExecute>
<hide></hide>
</innerScene>
<innerScene title='权限过滤'>
<id>d10c3034-6fcc-4ffd-88cf-553d84d177ff</id>
<javaImplement>com.xyst.dinas.biz.scene.XystDinasCommonAllScene</javaImplement>
<defaultExecute>true</defaultExecute>
<hide>true</hide>
</innerScene>
<field title='id'>
<name>id</name>
<type>uuid</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='项目ID'>
<name>project.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.project.datamodel.ProjectFiled</name>
</ref>
<description></description>
</field>
<field title='项目编号'>
<name>project.projectNum</name>
<type>string</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='项目名称'>
<name>project.projectName</name>
<type>string</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='区域公司ID'>
<name>regionalCompany.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.biz.datamodel.Organization</name>
</ref>
<description></description>
</field>
<field title='区域公司名称'>
<name>regionalCompany.name</name>
<type>string</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='购砂单位'>
<name>purchaseSandCompany.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.project.datamodel.PurchaseSandCompany</name>
</ref>
<description></description>
</field>
<field title='购砂单位名称'>
<name>purchaseSandCompany.name</name>
<type>string</type>
<description></description>
</field>
<field title='合同id'>
<name>contract.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.contract.datamodel.Contract</name>
</ref>
<description></description>
</field>
<field title='合同名称'>
<name>contract.contractName</name>
<type>string</type>
<description></description>
</field>
<field title='合同编号'>
<name>contract.contractCode</name>
<type>string</type>
<description></description>
</field>
<field title='场站id'>
<name>station.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.biz.datamodel.Station</name>
</ref>
<description></description>
</field>
<field title='场站名称'>
<name>station.stationName</name>
<type>string</type>
<description></description>
</field>
<field title='生产线id'>
<name>productionLine.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.biz.datamodel.ProductionLine</name>
</ref>
<description></description>
</field>
<field title='生产线名称'>
<name>productionLine.name</name>
<type>string</type>
<description></description>
</field>
<field title='散户id'>
<name>retailInfo.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.biz.datamodel.RetailInfo</name>
</ref>
<description></description>
</field>
<field title='散户名称'>
<name>retailInfo.retailInfoName</name>
<type>string</type>
<description></description>
</field>
<field title='砂石种类id'>
<name>dinasType.id</name>
<type>uuid</type>
<ref>
<type></type>
<name>com.xyst.dinas.biz.datamodel.RetailInfo</name>
</ref>
<description></description>
</field>
<field title='砂石种类名称'>
<name>dinasType.dinasTypeName</name>
<type>string</type>
<description></description>
</field>
<field title='客户类型'>
<name>customerType</name>
<type>string</type>
<description></description>
</field>
<field title='销售时间'>
<name>dealTime</name>
<type>datetime</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='同步时间'>
<name>syncTime</name>
<type>datetime</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='车辆信息'>
<name>carInfo</name>
<type>string</type>
<description></description>
</field>
<field title='销售数量'>
<name>dealAmount</name>
<type>fixnum</type>
<description></description>
</field>
<field title='单价'>
<name>price</name>
<type>fixnum</type>
<description></description>
</field>
<field title='总价'>
<name>amount</name>
<type>fixnum</type>
<description></description>
</field>
<field title='付款来源'>
<name>paymentSource</name>
<type>string</type>
<description></description>
</field>
<field title='销售单号'>
<name>dealBillCode</name>
<type>string</type>
<description></description>
</field>
<field title='创建时间'>
<name>createTime</name>
<type>datetime</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
<field title='修改时间'>
<name>modifyTime</name>
<type>datetime</type>
<ref>
<type></type>
<name></name>
</ref>
<description></description>
</field>
</customQuery>
</content>
</model>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-type">
<specification>1.0</specification>
<id>bfc7131b-d5ff-4f08-ad20-1500b5946520</id>
<name>com.xyst.dinas.sales.datamodel.SalesRecord</name>
<title>销售台账</title>
<description>销售台账</description>
<define>bcp.type.Class</define>
<define-version>1.0</define-version>
<dependency>com.xyst.dinas.biz.datamodel.Organization</dependency>
<dependency>com.xyst.dinas.project.datamodel.PurchaseSandCompany</dependency>
<dependency>bcp.type.constraint.StringLength</dependency>
<dependency>com.beecode.inz.common.datamodel.BaseInfo</dependency>
<dependency>com.xyst.dinas.biz.datamodel.Station</dependency>
<dependency>com.xyst.dinas.biz.datamodel.RetailInfo</dependency>
<dependency>com.xyst.dinas.biz.datamodel.DinasType</dependency>
<dependency>bcp.type.constraint.Numeric</dependency>
<dependency>com.beecode.bap.biztrait.datamodel.StoreMainTableRequirement</dependency>
<dependency>com.xyst.dinas.project.datamodel.ProjectFiled</dependency>
<dependency>com.xyst.dinas.contract.datamodel.Contract</dependency>
<dependency>com.xyst.dinas.biz.datamodel.ProductionLine</dependency>
<content>
<m:class>
<m:parents>
<m:parent>com.beecode.bap.biztrait.datamodel.StoreMainTableRequirement</m:parent>
<m:parent>com.beecode.inz.common.datamodel.BaseInfo</m:parent>
</m:parents>
<m:attributes>
<m:attribute>
<m:annotations/>
<m:id>ef9bb259-9746-4f38-bb70-e1159966297d</m:id>
<m:name>createTime</m:name>
<m:title>创建时间</m:title>
<m:type>datetime</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>ca273c9d-0981-4f6d-94b4-4a3b76742a1e</m:id>
<m:name>modifyTime</m:name>
<m:title>修改时间</m:title>
<m:type>datetime</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>abea2870-1ac4-404e-bc4b-b1673e718520</m:id>
<m:name>project</m:name>
<m:title>项目</m:title>
<m:type>com.xyst.dinas.project.datamodel.ProjectFiled</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>c1127719-c3c7-47a9-bdc5-3bb4e377cb5f</m:id>
<m:name>regionalCompany</m:name>
<m:title>区域公司</m:title>
<m:type>com.xyst.dinas.biz.datamodel.Organization</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>970577bc-d8d2-4f4e-89e5-5f00a10dc8a2</m:id>
<m:name>contract</m:name>
<m:title>合同</m:title>
<m:type>com.xyst.dinas.contract.datamodel.Contract</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>302a145d-c461-4524-8c04-61672080b8da</m:id>
<m:name>purchaseSandCompany</m:name>
<m:title>购砂单位</m:title>
<m:type>com.xyst.dinas.project.datamodel.PurchaseSandCompany</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>a2d1d0c4-4dee-44d7-89a2-15c53fc879bd</m:id>
<m:name>station</m:name>
<m:title>场站</m:title>
<m:type>com.xyst.dinas.biz.datamodel.Station</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>0ba03ee9-2a71-4d3b-8f84-cdff871b80d2</m:id>
<m:name>productionLine</m:name>
<m:title>生产线</m:title>
<m:type>com.xyst.dinas.biz.datamodel.ProductionLine</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>37f7cb1f-2426-49d7-af70-e0f573fe4f00</m:id>
<m:name>retailInfo</m:name>
<m:title>散户</m:title>
<m:type>com.xyst.dinas.biz.datamodel.RetailInfo</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>34f0a228-faa0-4465-9c2c-4ec8b6fb6e43</m:id>
<m:name>dinasType</m:name>
<m:title>砂石种类</m:title>
<m:type>com.xyst.dinas.biz.datamodel.DinasType</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations>
<m:annotation>
<m:type>bcp.type.constraint.StringLength</m:type>
<m:value>20</m:value>
</m:annotation>
</m:annotations>
<m:id>9ed97388-563a-4634-a555-b56bb1664dd0</m:id>
<m:name>customerType</m:name>
<m:title>客户类型</m:title>
<m:type>string</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>46656ba1-31bc-4b40-a63d-4a2a4b9f7944</m:id>
<m:name>dealTime</m:name>
<m:title>销售时间</m:title>
<m:type>datetime</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations/>
<m:id>b01e62bc-ee7b-4470-b695-a78292348d83</m:id>
<m:name>syncTime</m:name>
<m:title>同步时间</m:title>
<m:type>datetime</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations>
<m:annotation>
<m:type>bcp.type.constraint.StringLength</m:type>
<m:value>20</m:value>
</m:annotation>
</m:annotations>
<m:id>9ed97388-563a-4634-a555-b56bb1664dd0</m:id>
<m:name>carInfo</m:name>
<m:title>车辆信息</m:title>
<m:type>string</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations>
<m:annotation>
<m:type>bcp.type.constraint.Numeric</m:type>
<m:properties>
<m:property>
<m:key>precision</m:key>
<m:value>12</m:value>
</m:property>
<m:property>
<m:key>scale</m:key>
<m:value>4</m:value>
</m:property>
</m:properties>
</m:annotation>
</m:annotations>
<m:id>d307fa81-7819-4216-887c-2a0fdffd3190</m:id>
<m:name>dealAmount</m:name>
<m:title>销售数量</m:title>
<m:type>fixnum</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations>
<m:annotation>
<m:type>bcp.type.constraint.Numeric</m:type>
<m:properties>
<m:property>
<m:key>precision</m:key>
<m:value>12</m:value>
</m:property>
<m:property>
<m:key>scale</m:key>
<m:value>2</m:value>
</m:property>
</m:properties>
</m:annotation>
</m:annotations>
<m:id>35c5c23b-bb32-4e2d-909a-712cfadd3519</m:id>
<m:name>price</m:name>
<m:title>单价</m:title>
<m:type>fixnum</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations>
<m:annotation>
<m:type>bcp.type.constraint.Numeric</m:type>
<m:properties>
<m:property>
<m:key>precision</m:key>
<m:value>12</m:value>
</m:property>
<m:property>
<m:key>scale</m:key>
<m:value>2</m:value>
</m:property>
</m:properties>
</m:annotation>
</m:annotations>
<m:id>183f4e16-b718-4d39-8e9f-f4c58978cf40</m:id>
<m:name>amount</m:name>
<m:title>总价</m:title>
<m:type>fixnum</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations>
<m:annotation>
<m:type>bcp.type.constraint.StringLength</m:type>
<m:value>50</m:value>
</m:annotation>
</m:annotations>
<m:id>9b6efd34-a746-4808-b940-f7f2fd4ccca8</m:id>
<m:name>paymentSource</m:name>
<m:title>付款来源</m:title>
<m:type>string</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
<m:attribute>
<m:annotations>
<m:annotation>
<m:type>bcp.type.constraint.StringLength</m:type>
<m:value>50</m:value>
</m:annotation>
</m:annotations>
<m:id>7b72bf25-26fd-4e24-b3f9-67d4f4733ff2</m:id>
<m:name>dealBillCode</m:name>
<m:title>销售单号</m:title>
<m:type>string</m:type>
<m:description></m:description>
<m:default></m:default>
</m:attribute>
</m:attributes>
</m:class>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/inz-query">
<specification>1.0</specification>
<id>d5154782-eec0-44ed-8993-b7fc029d2fdf</id>
<name>com.xyst.dinas.sales.query.SalesRecord</name>
<title>销售台账</title>
<define>inz.query.Query</define>
<define-version>1.0</define-version>
<dependency>com.xyst.dinas.sales.datamodel.SalesRecord</dependency>
<content>
<m:query>
<m:type>com.xyst.dinas.sales.datamodel.SalesRecord</m:type>
<m:dataProcessor></m:dataProcessor>
<m:authorityItem></m:authorityItem>
<m:innerScenes>
<m:innerScene>
<m:id>d52de6d1-6252-42fb-bbb4-5d9a65b26ee7</m:id>
<m:title>全部</m:title>
<m:javaImplement>com.beecode.inz.common.scene.CommonAllScene</m:javaImplement>
<m:defaultExecute></m:defaultExecute>
<m:hide></m:hide>
</m:innerScene>
<m:innerScene>
<m:id>d10c3034-6fcc-4ffd-88cf-553d84d177ff</m:id>
<m:title>权限过滤</m:title>
<m:javaImplement>com.xyst.dinas.biz.scene.XystDinasCommonAllScene</m:javaImplement>
<m:defaultExecute>true</m:defaultExecute>
<m:hide>true</m:hide>
</m:innerScene>
</m:innerScenes>
<m:fields>
<m:field>
<m:name>id</m:name>
<m:title>id</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>project.id</m:name>
<m:title>项目ID</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.project.datamodel.ProjectFiled</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>project.projectNum</m:name>
<m:title>项目编号</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>project.projectName</m:name>
<m:title>项目名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>regionalCompany.id</m:name>
<m:title>区域公司ID</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.biz.datamodel.Organization</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>regionalCompany.name</m:name>
<m:title>区域公司名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>purchaseSandCompany.id</m:name>
<m:title>购砂单位</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.project.datamodel.PurchaseSandCompany</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>purchaseSandCompany.name</m:name>
<m:title>购砂单位名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>contract.id</m:name>
<m:title>合同id</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.contract.datamodel.Contract</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>contract.contractName</m:name>
<m:title>合同名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>contract.contractCode</m:name>
<m:title>合同编号</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>station.id</m:name>
<m:title>场站id</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.biz.datamodel.Station</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>station.stationName</m:name>
<m:title>场站名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>productionLine.id</m:name>
<m:title>生产线id</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.biz.datamodel.ProductionLine</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>productionLine.name</m:name>
<m:title>生产线名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>retailInfo.id</m:name>
<m:title>散户id</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.biz.datamodel.RetailInfo</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>retailInfo.retailInfoName</m:name>
<m:title>散户名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>dinasType.id</m:name>
<m:title>砂石种类id</m:title>
<m:type>uuid</m:type>
<m:ref>
<m:name>com.xyst.dinas.biz.datamodel.RetailInfo</m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>dinasType.dinasTypeName</m:name>
<m:title>砂石种类名称</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>customerType</m:name>
<m:title>客户类型</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>dealTime</m:name>
<m:title>销售时间</m:title>
<m:type>datetime</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>syncTime</m:name>
<m:title>同步时间</m:title>
<m:type>datetime</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>carInfo</m:name>
<m:title>车辆信息</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>dealAmount</m:name>
<m:title>销售数量</m:title>
<m:type>fixnum</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>price</m:name>
<m:title>单价</m:title>
<m:type>fixnum</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>amount</m:name>
<m:title>总价</m:title>
<m:type>fixnum</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>paymentSource</m:name>
<m:title>付款来源</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>dealBillCode</m:name>
<m:title>销售单号</m:title>
<m:type>string</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>createTime</m:name>
<m:title>创建时间</m:title>
<m:type>datetime</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
<m:field>
<m:name>modifyTime</m:name>
<m:title>修改时间</m:title>
<m:type>datetime</m:type>
<m:ref>
<m:name></m:name>
<m:type></m:type>
</m:ref>
<m:desc></m:desc>
</m:field>
</m:fields>
</m:query>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<hibernate-mapping xmlns="http://www.hibernate.org/xsd/hibernate-mapping"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.hibernate.org/xsd/hibernate-mapping
http://www.hibernate.org/xsd/hibernate-mapping/hibernate-mapping-4.0.xsd">
<class entity-name="com.xyst.dinas.sales.datamodel.SalesRecord" table="xyst_dinas_sales_record" optimistic-lock="version">
<tuplizer entity-mode="dynamic-map" class="com.beecode.bcp.store.hibernate.KObjectEntityTuplizer"/>
<id name="id" type="uuid-binary" column="id" length="16">
<generator class="uuid2" />
</id>
<version name="version" type="int" column="version"/>
<property name="createTime" type="timestamp" not-null="false">
<column name="create_time"></column>
</property>
<property name="modifyTime" type="timestamp" not-null="false">
<column name="modify_time"></column>
</property>
<property name="discard" type="boolean" not-null="false">
<column name="discard"></column>
</property>
<property name="del" type="boolean" not-null="false">
<column name="del"></column>
</property>
<property name="approveState" type="integer" not-null="false">
<column name="approve_state"></column>
</property>
<many-to-one name="pic" entity-name="com.beecode.bap.staff.datamodel.Staff" fetch="select">
<column name="pic_id" not-null="false"/>
</many-to-one>
<many-to-one name="project" entity-name="com.xyst.dinas.project.datamodel.ProjectFiled" fetch="select">
<column name="project_id" not-null="false"/>
</many-to-one>
<many-to-one name="regionalCompany" entity-name="com.xyst.dinas.biz.datamodel.Organization" fetch="select">
<column name="regional_company_id" not-null="false"/>
</many-to-one>
<many-to-one name="contract" entity-name="com.xyst.dinas.contract.datamodel.Contract" fetch="select">
<column name="contract_id" not-null="false"/>
</many-to-one>
<many-to-one name="purchaseSandCompany" entity-name="com.xyst.dinas.project.datamodel.PurchaseSandCompany" fetch="select">
<column name="purchase_sand_company_id" not-null="false"/>
</many-to-one>
<many-to-one name="station" entity-name="com.xyst.dinas.biz.datamodel.Station" fetch="select">
<column name="station_id" not-null="false"/>
</many-to-one>
<many-to-one name="productionLine" entity-name="com.xyst.dinas.biz.datamodel.ProductionLine" fetch="select">
<column name="production_line_id" not-null="false"/>
</many-to-one>
<many-to-one name="retailInfo" entity-name="com.xyst.dinas.biz.datamodel.RetailInfo" fetch="select">
<column name="retail_info_id" not-null="false"/>
</many-to-one>
<many-to-one name="dinasType" entity-name="com.xyst.dinas.biz.datamodel.DinasType" fetch="select">
<column name="dinas_type_id" not-null="false"/>
</many-to-one>
<property name="customerType" type="nstring" not-null="false">
<column name="customer_type" length="20"></column>
</property>
<property name="dealTime" type="timestamp" not-null="false">
<column name="deal_time"></column>
</property>
<property name="syncTime" type="timestamp" not-null="false">
<column name="sync_time"></column>
</property>
<property name="carInfo" type="nstring" not-null="false">
<column name="car_info" length="20"></column>
</property>
<property name="dealAmount" type="big_decimal" not-null="false">
<column name="deal_amount" precision="12" scale="4"></column>
</property>
<property name="price" type="big_decimal" not-null="false">
<column name="price" precision="12" scale="2"></column>
</property>
<property name="amount" type="big_decimal" not-null="false">
<column name="amount" precision="12" scale="2"></column>
</property>
<property name="paymentSource" type="nstring" not-null="false">
<column name="payment_source" length="50"></column>
</property>
<property name="dealBillCode" type="nstring" not-null="false">
<column name="deal_bill_code" length="50"></column>
</property>
</class>
</hibernate-mapping>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment