From 87e5654c26476fabd1156023350d7726092af8c1 Mon Sep 17 00:00:00 2001
From: jiazx0107 <jiazx0107@163.com>
Date: 星期日, 30 十一月 2025 18:28:41 +0800
Subject: [PATCH] 调整通知单
---
fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml | 402 ++++++++++++++------------------
fzzy-igdss-core/src/main/java/com/fzzy/igds/utils/ContextUtil.java | 41 ++
fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticePR.java | 86 ++-----
fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/InoutNoticeIn.java | 13
fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeOut.view.xml | 8
fzzy-igdss-core/src/main/java/com/fzzy/igds/service/InoutNoticeService.java | 46 ++
fzzy-igdss-view/src/main/java/models/core.model.xml | 81 +++++
fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/InoutNoticeInMapper.java | 10
fzzy-igdss-web/src/main/resources/d7/common.css | 12
9 files changed, 363 insertions(+), 336 deletions(-)
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/InoutNoticeIn.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/InoutNoticeIn.java
index 2880c79..6c6dca2 100644
--- a/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/InoutNoticeIn.java
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/InoutNoticeIn.java
@@ -46,9 +46,9 @@
@TableField("type")
private String type;
- @Column(name = "contract_id", columnDefinition = "varchar(40) COMMENT '鎵�灞炲悎鍚�'")
- @TableField("contract_id")
- private String contractId;
+ @Column(name = "contract", columnDefinition = "varchar(40) COMMENT '鎵�灞炲悎鍚�'")
+ @TableField("contract")
+ private String contract;
@Column(name = "depot_id", columnDefinition = "varchar(40) COMMENT '鍏ュ簱浠撳簱'")
@TableField("depot_id")
@@ -66,7 +66,7 @@
@TableField("food_variety")
private String foodVariety;
- @Column(name = "year", columnDefinition = "varchar(4) COMMENT '骞翠唤'")
+ @Column(name = "year", columnDefinition = "varchar(4) COMMENT '绮骞翠唤'")
@TableField("year")
private String year;
@@ -103,10 +103,5 @@
@Column(name = "remark", columnDefinition = "varchar(100) COMMENT '澶囨敞璇存槑'")
@TableField("remark")
private String remark;
-
-
- @Transient
- @PropertyDef(label = "鏍囪", description = "鐢ㄤ簬鍒ゆ柇閫氱煡鍗曟槸鍚︿负鏂板")
- private String tag;
}
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/InoutNoticeInMapper.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/InoutNoticeInMapper.java
new file mode 100644
index 0000000..7e6a8bc
--- /dev/null
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/InoutNoticeInMapper.java
@@ -0,0 +1,10 @@
+package com.fzzy.igds.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fzzy.igds.domain.InoutNoticeIn;
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface InoutNoticeInMapper extends BaseMapper<InoutNoticeIn> {
+
+}
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/InoutNoticeService.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/InoutNoticeService.java
index cc37c83..9f157ce 100644
--- a/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/InoutNoticeService.java
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/InoutNoticeService.java
@@ -1,8 +1,10 @@
package com.fzzy.igds.service;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.fzzy.igds.constant.Constant;
import com.fzzy.igds.data.NoticeDto;
import com.fzzy.igds.data.NoticeParam;
+import com.fzzy.igds.mapper.InoutNoticeInMapper;
import com.fzzy.igds.mapper.InoutNoticeMapper;
import com.fzzy.igds.repository.InoutNoticeInRepository;
import com.fzzy.igds.repository.InoutNoticeOutRepository;
@@ -12,14 +14,17 @@
import com.ruoyi.common.utils.StringUtils;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.BeanUtils;
-import org.springframework.data.domain.Page;
+
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;
import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+
import javax.annotation.Resource;
import java.util.Date;
import java.util.List;
+import java.util.Map;
/**
* @Description 鍑哄叆搴撻�氱煡鍗晄ervice灞傦紝鍖呭惈鍏ュ簱閫氱煡鍗曞拰鍑哄簱閫氱煡鍗�
@@ -37,15 +42,27 @@
@Resource
private InoutNoticeMapper noticeMapper;
- /**
+ @Resource
+ private InoutNoticeInMapper noticeInMapper;
+
+
+/* *//**
* JPA鍒嗛〉鏌ヨ鏁版嵁
*
- * @param specification
- * @param pageable
- * @return
- */
+ *//*
public Page<InoutNoticeIn> queryAllNoticeIn(Specification<InoutNoticeIn> specification, Pageable pageable) {
return noticeInRepository.findAll(specification, pageable);
+ }*/
+
+ public void pageQueryIn(Page<InoutNoticeIn> page, NoticeParam param) {
+ QueryWrapper<InoutNoticeIn> queryWrapper = new QueryWrapper<>();
+
+ if(null == param) param = new NoticeParam();
+ param.setCompanyId(ContextUtil.getCompanyId());
+
+ queryWrapper.eq("company_id", param.getCompanyId());
+
+ noticeInMapper.selectPage(page, queryWrapper);
}
/**
@@ -77,15 +94,20 @@
* @return
*/
public String saveOrUpdateIn(InoutNoticeIn data) {
- if (Constant.YN_Y.equals(data.getTag())) {
+ if (null == data.getUpdateBy()) {
+ data.setUpdateBy(ContextUtil.getLoginUserName());
+ data.setUpdateTime(new Date());
data.setCreateBy(ContextUtil.getLoginUserName());
data.setCreateTime(new Date());
data.setAuditStatus(Constant.COMPLETE_STATUS_NONE);
data.setCompleteStatus(Constant.COMPLETE_STATUS_NONE);
+ noticeInRepository.save(data);
+ } else {
+ data.setUpdateBy(ContextUtil.getLoginUserName());
+ data.setUpdateTime(new Date());
+ noticeInRepository.save(data);
}
- data.setUpdateBy(ContextUtil.getLoginUserName());
- data.setUpdateTime(new Date());
- noticeInRepository.save(data);
+
return null;
}
@@ -108,7 +130,8 @@
* @return
*/
public Page<InoutNoticeOut> queryAllNoticeOut(Specification<InoutNoticeOut> specification, Pageable pageable) {
- return noticeOutRepository.findAll(specification, pageable);
+ //return noticeOutRepository.findAll(specification, pageable);
+ return null;
}
/**
@@ -285,4 +308,5 @@
return null;
}
+
}
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/utils/ContextUtil.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/utils/ContextUtil.java
index f36b989..c23c9e4 100644
--- a/fzzy-igdss-core/src/main/java/com/fzzy/igds/utils/ContextUtil.java
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/utils/ContextUtil.java
@@ -22,6 +22,7 @@
private static final AtomicLong sequence = new AtomicLong(0);
private static String lastTimestamp = "";
+
//鍏ㄥ眬鐢ㄦ埛瀹炴椂鍧愬湪閮ㄩ棬
public static Map<String, String> contextUserDept = new HashMap<>();
@@ -30,13 +31,33 @@
*/
public static Map<String, String> contextSnCompanyIdMap = new HashMap<>();
+
/**
* 鐢熸垚椤哄簭ID锛氬勾鏈堟棩鏃跺垎绉掓绉�(17浣�) + 搴忓垪鍙�(4浣�) = 21浣�
+ */
+ public static String generateId() {
+ String pattern = "yyyyMMddHHmmssSSS";
+ return generateId(null, pattern);
+ }
+
+ /**
+ * 鐢熸垚鍗曟嵁缂栫爜锛� (鏍煎紡: yyyyMMddHHmmss + 4浣嶉殢鏈烘暟)
+ * @param prefix
+ * @return
+ */
+ public static String generateOrderId(String prefix) {
+ String pattern = "yyyyMMddHHmmss";
+ return generateId(prefix, pattern);
+ }
+
+ /**
+ *
*
* @return
*/
- public static String generateId() {
- String currentTimestamp = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyyyMMddHHmmssSSS"));
+ private static String generateId(String prefix, String pattern) {
+ if (null == pattern) pattern = "yyyyMMddHHmmss";
+ String currentTimestamp = LocalDateTime.now().format(DateTimeFormatter.ofPattern(pattern));
long seq;
synchronized (ContextUtil.class) {
if (currentTimestamp.equals(lastTimestamp)) {
@@ -44,12 +65,14 @@
} else {
sequence.set(0);
seq = 0;
-
lastTimestamp = currentTimestamp;
}
}
- return String.format("%s%04d", currentTimestamp, seq);
+
+ if (null == prefix) return String.format("%s%04d", currentTimestamp, seq);
+ return prefix + "_" + String.format("%s%04d", currentTimestamp, seq);
}
+
public static String UUID() {
return UUID.randomUUID().toString().replaceAll("-", "");
@@ -63,7 +86,7 @@
public static String getCompanyId() {
SysUser user = ShiroUtils.getSysUser();
- if(null != user) return user.getCompanyId();
+ if (null != user) return user.getCompanyId();
return FrameworkConfig.getCompanyId();
}
@@ -113,16 +136,16 @@
Integer index5 = 100001;
Integer index = 0;
String orderId = "001";
- if(StringUtils.isNotEmpty(oldOrderId)){
+ if (StringUtils.isNotEmpty(oldOrderId)) {
index = Integer.valueOf(oldOrderId);
}
- if(3 == num){
+ if (3 == num) {
orderId = ((index3 + index) + "").substring(1);
}
- if(4 == num){
+ if (4 == num) {
orderId = ((index4 + index) + "").substring(1);
}
- if(5 == num){
+ if (5 == num) {
orderId = ((index5 + index) + "").substring(1);
}
return orderId;
diff --git a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml
index c1e4663..5b52c7b 100644
--- a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml
+++ b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeIn.view.xml
@@ -7,7 +7,7 @@
<Property name="creationType">com.fzzy.igds.domain.InoutNoticeIn</Property>
<PropertyDef name="id">
<Property></Property>
- <Property name="label">閫氱煡鍗曞彿</Property>
+ <Property name="label">鍗曟嵁鍙�</Property>
</PropertyDef>
<PropertyDef name="companyId">
<Property></Property>
@@ -16,29 +16,24 @@
<PropertyDef name="deptId">
<Property></Property>
<Property name="label">鎵�灞炲垎搴�</Property>
- <Property name="mapping">
- <Property name="mapValues">${dorado.getDataProvider("deptPR#getAllData").getResult()}</Property>
- <Property name="keyProperty">id</Property>
- <Property name="valueProperty">kqmc</Property>
- </Property>
</PropertyDef>
<PropertyDef name="name">
<Property></Property>
- <Property name="label">閫氱煡鍗曞悕绉�</Property>
+ <Property name="label">鍗曟嵁鍚嶇О</Property>
<Property name="required">true</Property>
</PropertyDef>
<PropertyDef name="type">
<Property></Property>
- <Property name="label">绫诲瀷</Property>
+ <Property name="label">鍗曟嵁绫诲瀷</Property>
<Property name="mapping">
<Property name="mapValues">
<Collection>
<Entity>
- <Property name="name">搴撳尯鑷缓</Property>
+ <Property name="name">搴撳尯閫氱煡鍗�</Property>
<Property name="code">10</Property>
</Entity>
<Entity>
- <Property name="name">閾惰鐩戠</Property>
+ <Property name="name">鐩戠閫氱煡鍗�</Property>
<Property name="code">20</Property>
</Entity>
</Collection>
@@ -46,10 +41,11 @@
<Property name="keyProperty">code</Property>
<Property name="valueProperty">name</Property>
</Property>
+ <Property name="required">true</Property>
</PropertyDef>
- <PropertyDef name="contractId">
+ <PropertyDef name="contract">
<Property></Property>
- <Property name="label">璐ㄦ娂鍚堝悓</Property>
+ <Property name="label">鍏宠仈鍚堝悓</Property>
<Property name="required">false</Property>
</PropertyDef>
<PropertyDef name="depotId">
@@ -89,13 +85,12 @@
<PropertyDef name="year">
<Property></Property>
<Property name="label">骞翠唤</Property>
- <Property name="required">true</Property>
</PropertyDef>
<PropertyDef name="targetNumber">
<Property name="dataType">Double</Property>
<Property name="displayFormat">#0.0 KG</Property>
<Property name="required">true</Property>
- <Property name="label">鐩爣鏁伴噺</Property>
+ <Property name="label">璁″垝鏁伴噺</Property>
</PropertyDef>
<PropertyDef name="completeNumber">
<Property name="dataType">Double</Property>
@@ -155,7 +150,7 @@
</Property>
</PropertyDef>
<PropertyDef name="completeTime">
- <Property name="dataType">DateTime</Property>
+ <Property name="dataType">Date</Property>
<Property name="label">瀹屾垚鏃堕棿</Property>
</PropertyDef>
<PropertyDef name="remark">
@@ -168,72 +163,19 @@
</PropertyDef>
<PropertyDef name="createTime">
<Property name="dataType">DateTime</Property>
- <Property name="label">鍒涘缓鏃堕棿</Property>
- <Property name="readOnly">true</Property>
+ <Property name="label">鍒跺崟鏃堕棿</Property>
</PropertyDef>
<PropertyDef name="createBy">
<Property></Property>
- <Property name="label">鍒涘缓浜�</Property>
- <Property name="readOnly">true</Property>
+ <Property name="label">鍒跺崟浜�</Property>
</PropertyDef>
<PropertyDef name="updateTime">
<Property name="dataType">DateTime</Property>
<Property name="label">鏇存柊鏃堕棿</Property>
- <Property name="readOnly">true</Property>
</PropertyDef>
<PropertyDef name="updateBy">
<Property></Property>
<Property name="label">鏇存柊浜�</Property>
- <Property name="readOnly">true</Property>
- </PropertyDef>
- </DataType>
- <DataType name="dtQuery">
- <PropertyDef name="depotId">
- <Property></Property>
- <Property name="label">瑁呭嵏浠撳簱</Property>
- <Property name="mapping">
- <Property name="mapValues">${dorado.getDataProvider("depotPR#getAllCache").getResult()}</Property>
- <Property name="keyProperty">id</Property>
- <Property name="valueProperty">name</Property>
- </Property>
- </PropertyDef>
- <PropertyDef name="customerName">
- <Property></Property>
- <Property name="label">鍙戣揣瀹㈡埛</Property>
- </PropertyDef>
- <PropertyDef name="foodVariety">
- <Property></Property>
- <Property name="label">绮鍝佺</Property>
- <Property name="mapping">
- <Property name="mapValues">${dorado.getDataProvider("dicPR#sysDictData").getResult("FOOD_VARIETY_")}</Property>
- <Property name="keyProperty">dictValue</Property>
- <Property name="valueProperty">dictLabel</Property>
- </Property>
- </PropertyDef>
- <PropertyDef name="completeStatus">
- <Property></Property>
- <Property name="label">瀹屾垚鐘舵��</Property>
- <Property name="mapping">
- <Property name="mapValues">
- <Collection>
- <Entity>
- <Property name="name">鏈畬鎴�</Property>
- <Property name="code">NONE</Property>
- </Entity>
- <Entity>
- <Property name="name">宸插畬鎴�</Property>
- <Property name="code">COMPLETE</Property>
- </Entity>
- </Collection>
- </Property>
- <Property name="keyProperty">code</Property>
- <Property name="valueProperty">name</Property>
- </Property>
- </PropertyDef>
- </DataType>
- <DataType name="dtQueryTitle">
- <PropertyDef name="title">
- <Property name="label">title</Property>
</PropertyDef>
</DataType>
</Model>
@@ -245,14 +187,9 @@
};
query();

-queryTitle = function(){
- view.get("#dsQueryTitle").set("parameter",{type:TYPE,deptId:deptId}).flushAsync();
-};
-queryTitle();
- 
//鏂板
add = function(){
- view.get("#ajaxInitAdd").set("parameter", TYPE).execute(function(data){
+ view.get("#ajaxInitAdd").execute(function(data){
view.get("#dsMain").insert(data);
view.get("#dialogMain").show();
});
@@ -265,14 +202,9 @@
<Property name="loadMode">lazy</Property>
</DataSet>
<DataSet id="dsQuery">
- <Property name="dataType">dtQuery</Property>
<Property name="dataProvider">inoutNoticePR#getYearQuery</Property>
<Property name="loadMode">manual</Property>
- </DataSet>
- <DataSet id="dsQueryTitle">
- <Property name="dataType">dtQueryTitle</Property>
- <Property name="dataProvider">inoutNoticePR#getTitle</Property>
- <Property name="loadMode">manual</Property>
+ <Property name="dataType">dtNoticeParam</Property>
</DataSet>
<Container>
<Property name="className">c-param</Property>
@@ -310,7 +242,7 @@
}</ClientEvent>
<Property name="caption">鎼滅储</Property>
<Property name="iconClass">fa fa-search</Property>
- <Property name="exClassName">btn-q1</Property>>
+ <Property name="exClassName">btn-q1</Property>
</Button>
<Button>
<ClientEvent name="onClick">view.get("#dsQuery").flushAsync();</ClientEvent>
@@ -443,34 +375,29 @@
<Property name="width">160</Property>
</DataColumn>
</DataGrid>
- </Container>
- <Container layoutConstraint="bottom">
- <Property name="className">c-bottom</Property>
- <DataPilot layoutConstraint="right">
- <Property name="itemCodes">pageSize,pages</Property>
- <Property name="dataSet">dsMain</Property>
- </DataPilot>
+ <ToolBar layoutConstraint="bottom">
+ <Fill/>
+ <DataPilot layoutConstraint="right">
+ <Property name="itemCodes">pageSize,pages</Property>
+ <Property name="dataSet">dsMain</Property>
+ </DataPilot>
+ </ToolBar>
</Container>
<Dialog id="dialogMain" layout="regionPadding:8">
<Property name="closeable">false</Property>
<Property name="caption">鍏ュ簱閫氱煡鍗�</Property>
- <Property name="width">60%</Property>
+ <Property name="width">1200</Property>
<Property name="iconClass">fa fa-tasks</Property>
<Buttons>
<Button id="btnOk">
- <ClientEvent name="onClick">var data = view.get("#dsMain.data:#");
- if(data.validate() != 'ok'){
- $notify("鏁版嵁鏍¢獙澶辫触锛侊紒");
- return;
- }
- view.get("#ajaxSave").set("parameter",data).execute(function(result){
- if(result){
- $alert(result);
- return;
- }
- $notify("鏁版嵁鎵ц瀹屾垚锛侊紒");
- self.get("parent").hide();
- });</ClientEvent>
+ <ClientEvent name="onClick">view.get("#udpateSave").execute(function(result){
+ if(result){
+ $alert(result);
+ return;
+ }
+ $notify("鏁版嵁鎵ц瀹屾垚锛侊紒");
+ self.get("parent").hide();
+});</ClientEvent>
<Property name="caption">淇濆瓨</Property>
<Property name="iconClass">fa fa-check-circle</Property>
<Property name="exClassName">btn1</Property>
@@ -487,134 +414,148 @@
</Buttons>
<Children>
<Container>
- <AutoForm id="autoForm1" layoutConstraint="top padding:10">
- <Property name="cols">*,*,*,*,*,*,*</Property>
- <Property name="dataSet">dsQueryTitle</Property>
- <Property name="labelAlign">right</Property>
+ <AutoForm layoutConstraint="top ">
+ <Property name="dataSet">dsMain</Property>
<Property name="showHint">false</Property>
- <AutoFormElement layoutConstraint="colSpan:7">
- <Property name="name">title</Property>
- <Property name="property">title</Property>
- <Property name="showLabel">false</Property>
+ <Property name="cols">210,*,210</Property>
+ <Control/>
+ <AutoFormElement>
+ <Property name="name">name</Property>
+ <Property name="property">name</Property>
<Property name="editorType">Label</Property>
- <Property name="style">
- <Property name="font">bold 30px Georgia, serif;</Property>
- <Property name="text-align">center</Property>
- </Property>
+ <Property name="showLabel">false</Property>
+ <Property name="showHint">false</Property>
+ <Property name="className">f-title</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">id</Property>
+ <Property name="property">id</Property>
+ <Property name="editorType">Label</Property>
+ <Property name="showHint">false</Property>
+ <Property name="labelAlign">right</Property>
+ <Property name="showLabel">false</Property>
<Editor/>
</AutoFormElement>
</AutoForm>
- <Container layout="padding:15">
- <AutoForm>
- <Property name="dataSet">dsMain</Property>
- <Property name="cols">*,*,*</Property>
- <Property name="labelAlign">right</Property>
- <Property name="labelSeparator">锛�</Property>
- <Property name="labelWidth">120</Property>
- <AutoFormElement>
- <Property name="name">name</Property>
- <Property name="property">name</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">depotId</Property>
- <Property name="property">depotId</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">id</Property>
- <Property name="property">id</Property>
- <Property name="readOnly">true</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">foodVariety</Property>
- <Property name="property">foodVariety</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">customerName</Property>
- <Property name="property">customerName</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">unitName</Property>
- <Property name="property">unitName</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">year</Property>
- <Property name="property">year</Property>
- <Property name="trigger">defaultYearDropDown</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">targetNumber</Property>
- <Property name="property">targetNumber</Property>
- <Property name="readOnly">false</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">completeNumber</Property>
- <Property name="property">completeNumber</Property>
- <Property name="readOnly">false</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">type</Property>
- <Property name="property">type</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">completeStatus</Property>
- <Property name="property">completeStatus</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">completeTime</Property>
- <Property name="property">completeTime</Property>
- <Property name="readOnly">false</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">contractId</Property>
- <Property name="property">contractId</Property>
- <Editor/>
- </AutoFormElement>
- <Label layoutConstraint="colSpan:2">
- <Property name="style">
- <Property name="color">blue</Property>
- </Property>
- <Property name="text">娉細绫诲瀷涓洪摱琛岀洃绠℃椂锛岄渶鍏宠仈璐ㄦ娂鍚堝悓</Property>
- </Label>
- <AutoFormElement layoutConstraint="colSpan:2">
- <Property name="name">remark</Property>
- <Property name="property">remark</Property>
- <Property name="editorType">TextArea</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">createBy</Property>
- <Property name="property">createBy</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">createTime</Property>
- <Property name="property">createTime</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">updateBy</Property>
- <Property name="property">updateBy</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">updateTime</Property>
- <Property name="property">updateTime</Property>
- <Editor/>
- </AutoFormElement>
- </AutoForm>
- </Container>
+ <AutoForm>
+ <Property name="dataSet">dsMain</Property>
+ <Property name="cols">*,*,*</Property>
+ <Property name="labelAlign">right</Property>
+ <Property name="labelSeparator">锛�</Property>
+ <Property name="labelWidth">120</Property>
+ <AutoFormElement layoutConstraint="colSpan:2">
+ <Property name="name">name</Property>
+ <Property name="property">name</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">type</Property>
+ <Property name="property">type</Property>
+ <Property name="editorType">RadioGroup</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">depotId</Property>
+ <Property name="property">depotId</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">foodVariety</Property>
+ <Property name="property">foodVariety</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">year</Property>
+ <Property name="property">year</Property>
+ <Property name="trigger">defaultYearDropDown</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement layoutConstraint="colSpan:2">
+ <Property name="name">customerName</Property>
+ <Property name="property">customerName</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">unitName</Property>
+ <Property name="property">unitName</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">targetNumber</Property>
+ <Property name="property">targetNumber</Property>
+ <Property name="readOnly">false</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">completeNumber</Property>
+ <Property name="property">completeNumber</Property>
+ <Property name="readOnly">false</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">completeStatus</Property>
+ <Property name="property">completeStatus</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">completeTime</Property>
+ <Property name="property">completeTime</Property>
+ <Property name="readOnly">false</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">createBy</Property>
+ <Property name="property">createBy</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">auditStatus</Property>
+ <Property name="property">auditStatus</Property>
+ <Property name="readOnly">true</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement layoutConstraint="colSpan:2">
+ <Property name="name">contract</Property>
+ <Property name="property">contract</Property>
+ <Editor/>
+ </AutoFormElement>
+ <Label>
+ <Property name="style">
+ <Property name="color">blue</Property>
+ </Property>
+ <Property name="text">娉細鐩戠閫氱煡鍗曪紝鍙~鍐欒川鎶煎悎鍚屽悕绉�</Property>
+ </Label>
+ <AutoFormElement layoutConstraint="colSpan:3">
+ <Property name="name">remark</Property>
+ <Property name="property">remark</Property>
+ <Property name="editorType">TextArea</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">createTime</Property>
+ <Property name="property">createTime</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">auditUser</Property>
+ <Property name="property">auditUser</Property>
+ <Property name="readOnly">true</Property>
+ <Editor/>
+ </AutoFormElement>
+ <AutoFormElement>
+ <Property name="name">auditDate</Property>
+ <Property name="property">auditDate</Property>
+ <Property name="readOnly">true</Property>
+ <Editor/>
+ </AutoFormElement>
+ <HtmlContainer layoutConstraint="colSpan:3">
+ <Property name="content">1.鍏ュ簱閫氱煡鍗曚綔涓哄叆搴撲綔涓氱殑鍓嶇疆鏉′欢锛屽繀椤婚厤缃紝鍚﹀垯鏃犳硶杩涜鍏ュ簱浣滀笟銆�<br>
+2.鍗曟嵁绫诲瀷=搴撳尯閫氱煡鍗曪紝琛ㄧず搴撳尯鑷繁浣滀笟涓氬姟锛屼笉鍙楃洃绠$鐞嗐��</Property>
+ <Property name="exClassName">h-tip</Property>
+ <Property name="contentOverflow">hidden</Property>
+ </HtmlContainer>
+ </AutoForm>
</Container>
</Children>
<Tools/>
@@ -622,6 +563,13 @@
<AjaxAction id="ajaxSave">
<Property name="service">inoutNoticePR#saveIn</Property>
</AjaxAction>
+ <UpdateAction id="udpateSave">
+ <Property name="dataResolver">inoutNoticePR#saveIn</Property>
+ <UpdateItem>
+ <Property name="dataPath">[#current]</Property>
+ <Property name="dataSet">dsMain</Property>
+ </UpdateItem>
+ </UpdateAction>
<AjaxAction id="ajaxDel">
<Property name="service">inoutNoticePR#delDataIn</Property>
<Property name="confirmMessage">纭畾瑕佹墽琛屽垹闄や箞锛�</Property>
diff --git a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeOut.view.xml b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeOut.view.xml
index f5e3789..5f8af8a 100644
--- a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeOut.view.xml
+++ b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticeOut.view.xml
@@ -767,16 +767,10 @@
<Property name="cols">*,*</Property>
<Property name="labelAlign">right</Property>
<Property name="labelSeparator">锛�</Property>
- <Property name="labelWidth">120</Property>
+ <Property name="labelWidth">110</Property>
<AutoFormElement>
<Property name="name">name</Property>
<Property name="property">name</Property>
- <Editor/>
- </AutoFormElement>
- <AutoFormElement>
- <Property name="name">id</Property>
- <Property name="property">id</Property>
- <Property name="readOnly">true</Property>
<Editor/>
</AutoFormElement>
<AutoFormElement>
diff --git a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticePR.java b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticePR.java
index 74ead93..35a3da4 100644
--- a/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticePR.java
+++ b/fzzy-igdss-view/src/main/java/com/fzzy/igds/InoutNoticePR.java
@@ -2,10 +2,12 @@
import com.bstek.dorado.annotation.DataProvider;
+import com.bstek.dorado.annotation.DataResolver;
import com.bstek.dorado.annotation.Expose;
import com.bstek.dorado.data.provider.Page;
import com.fzzy.igds.constant.Constant;
import com.fzzy.igds.data.NoticeDto;
+import com.fzzy.igds.data.NoticeParam;
import com.fzzy.igds.service.InoutNoticeService;
import com.fzzy.igds.domain.InoutNoticeIn;
import com.fzzy.igds.domain.InoutNoticeOut;
@@ -41,12 +43,12 @@
@Resource
private SysDeptService sysDeptService;
- /**
+/* *//**
* inoutNoticePR#getTitle 鏍规嵁鎶ヨ〃绫诲瀷锛岃幏鍙栭粯璁ゆ煡璇俊鎭紝姣斿琛ㄥご淇℃伅绛�
*
* @param
* @return
- */
+ *//*
@DataProvider
public Map<String, Object> getTitle(Map<String, Object> param) {
Map<String, Object> result = new HashMap<String, Object>();
@@ -72,7 +74,7 @@
}
}
return result;
- }
+ }*/
/**
* inoutNoticePR#getYearQuery 榛樿骞翠唤
@@ -143,11 +145,13 @@
public InoutNoticeIn initAddIn() {
SysUser user = ContextUtil.getLoginUser();
InoutNoticeIn data = new InoutNoticeIn();
- data.setId("RKTZD_" + ContextUtil.generateId());
+ data.setId(ContextUtil.generateOrderId("RK"));
data.setName("鍏ュ簱閫氱煡鍗�");
data.setCompanyId(user.getCompanyId());
data.setDeptId(ContextUtil.subDeptId(user));
- data.setTag(Constant.YN_Y);
+ data.setYear(DateFormatUtils.format(new Date(), "yyyy"));
+ data.setCreateBy(ContextUtil.getLoginUserName());
+ data.setCreateTime(new Date());
return data;
}
@@ -158,62 +162,20 @@
* @return
*/
@DataProvider
- public void pageQueryIn(Page<InoutNoticeIn> page, Map<String, Object> param) {
- if (null == param) {
- param = new HashMap<>();
- }
- Map<String, Object> finalParam = param;
+ public void pageQueryIn(Page<InoutNoticeIn> page, NoticeParam param) {
+ com.baomidou.mybatisplus.extension.plugins.pagination.Page<InoutNoticeIn> corePage = new com.baomidou.mybatisplus.extension.plugins.pagination.Page<>(page.getPageNo(), page.getPageSize());
- //澶氬弬鏁板垎椤垫煡璇�
- Pageable pageable = PageRequest.of(0, 10000, Sort.Direction.ASC, InoutNoticeIn.SORT_PROP);
- Specification<InoutNoticeIn> specification = new Specification<InoutNoticeIn>() {
- private static final long serialVersionUID = 1L;
+ inoutNoticeService.pageQueryIn(corePage, param);
- public Predicate toPredicate(Root<InoutNoticeIn> root, CriteriaQuery<?> query, CriteriaBuilder cb) {
- List<Predicate> predicates = new ArrayList<Predicate>(); //鎵�鏈夌殑鏂█
-
- Predicate predicate1 = cb.equal(root.get("companyId"), ContextUtil.getCompanyId());
- predicates.add(predicate1);
- Predicate predicate2 = cb.equal(root.get("deptId"), ContextUtil.subDeptId(null));
- predicates.add(predicate2);
-
- String key = String.valueOf(finalParam.get("year"));
- if (StringUtils.isBlank(key)) {
- Predicate predicate3 = cb.equal(root.get("year"), key);
- predicates.add(predicate3);
- }
- key = (String) finalParam.get("id");
- if (StringUtils.isBlank(key)) {
- Predicate predicate4 = cb.equal(root.get("id"), key);
- predicates.add(predicate4);
- }
- key = (String) finalParam.get("customerName");
- if (StringUtils.isBlank(key)) {
- Predicate predicate5 = cb.like(root.get("customerName"), "%" + key + "%");
- predicates.add(predicate5);
- }
- key = (String) finalParam.get("completeStatus");
- if (StringUtils.isBlank(key)) {
- Predicate predicate6 = cb.equal(root.get("completeStatus"), key);
- predicates.add(predicate6);
- }
- key = (String) finalParam.get("foodVariety");
- if (StringUtils.isBlank(key)) {
- Predicate predicate7 = cb.equal(root.get("foodVariety"), key);
- predicates.add(predicate7);
- }
- return cb.and(predicates.toArray(new Predicate[0]));
- }
- };
- org.springframework.data.domain.Page<InoutNoticeIn> japPage = inoutNoticeService.queryAllNoticeIn(specification, pageable);
- page.setEntityCount((int) japPage.getTotalElements());
- page.setEntities(japPage.getContent());
+ // 閲嶆柊灏佽
+ page.setEntities(corePage.getRecords());
+ page.setEntityCount(Integer.parseInt(String.valueOf(corePage.getTotal())));
}
/**
* inoutNoticePR#saveIn 鏇存柊鍏ュ簱閫氱煡鍗�
*/
- @Expose
+ @DataResolver
public String saveIn(InoutNoticeIn data) {
InoutNoticeIn inoutNoticeIn = new InoutNoticeIn();
BeanUtils.copyProperties(data, inoutNoticeIn);
@@ -279,9 +241,10 @@
return cb.and(predicates.toArray(new Predicate[0]));
}
};
- org.springframework.data.domain.Page<InoutNoticeIn> japPage = inoutNoticeService.queryAllNoticeIn(specification, pageable);
+ //org.springframework.data.domain.Page<InoutNoticeIn> japPage = inoutNoticeService.queryAllNoticeIn(specification, pageable);
- return japPage.getContent();
+ //return japPage.getContent();
+ return null;
}
/**
@@ -382,9 +345,9 @@
return cb.and(predicates.toArray(new Predicate[0]));
}
};
- org.springframework.data.domain.Page<InoutNoticeOut> japPage = inoutNoticeService.queryAllNoticeOut(specification, pageable);
- page.setEntityCount((int) japPage.getTotalElements());
- page.setEntities(japPage.getContent());
+ //org.springframework.data.domain.Page<InoutNoticeOut> japPage = inoutNoticeService.queryAllNoticeOut(specification, pageable);
+ //page.setEntityCount((int) japPage.getTotalElements());
+ //page.setEntities(japPage.getContent());
}
/**
@@ -458,9 +421,10 @@
return cb.and(predicates.toArray(new Predicate[0]));
}
};
- org.springframework.data.domain.Page<InoutNoticeOut> japPage = inoutNoticeService.queryAllNoticeOut(specification, pageable);
+ //org.springframework.data.domain.Page<InoutNoticeOut> japPage = inoutNoticeService.queryAllNoticeOut(specification, pageable);
- return japPage.getContent();
+ //return japPage.getContent();
+ return null;
}
/**
diff --git a/fzzy-igdss-view/src/main/java/models/core.model.xml b/fzzy-igdss-view/src/main/java/models/core.model.xml
index 3464b49..49c0a85 100644
--- a/fzzy-igdss-view/src/main/java/models/core.model.xml
+++ b/fzzy-igdss-view/src/main/java/models/core.model.xml
@@ -3,14 +3,14 @@
<DataType name="dtBank">
<Property name="matchType">com.fzzy.igds.domain.Bank</Property>
<PropertyDef name="id">
- <Property/>
+ <Property></Property>
</PropertyDef>
<PropertyDef name="name">
- <Property/>
+ <Property></Property>
<Property name="label">閾惰鍚嶇О</Property>
</PropertyDef>
<PropertyDef name="status">
- <Property/>
+ <Property></Property>
<Property name="label">鏄惁鍚敤</Property>
<Property name="mapping">
<Property name="mapValues">${dorado.getDataProvider("dicPR#triggerYN").getResult("DEVICE_STATUS")}</Property>
@@ -19,15 +19,15 @@
</Property>
</PropertyDef>
<PropertyDef name="remark">
- <Property/>
+ <Property></Property>
<Property name="label">澶囨敞璇存槑</Property>
</PropertyDef>
<PropertyDef name="companyId">
- <Property/>
+ <Property></Property>
<Property name="label">鎵�灞炵粍缁�</Property>
</PropertyDef>
<PropertyDef name="createBy">
- <Property/>
+ <Property></Property>
<Property name="label">鍒涘缓浜�</Property>
</PropertyDef>
<PropertyDef name="createTime">
@@ -35,7 +35,7 @@
<Property name="label">鍒涘缓鏃堕棿</Property>
</PropertyDef>
<PropertyDef name="updateBy">
- <Property/>
+ <Property></Property>
<Property name="label">鏇存柊浜�</Property>
</PropertyDef>
<PropertyDef name="updateTime">
@@ -46,14 +46,14 @@
<DataType name="dtBaseParam">
<Property name="matchType">com.fzzy.igds.data.IgdsBaseParam</Property>
<PropertyDef name="id">
- <Property/>
+ <Property></Property>
</PropertyDef>
<PropertyDef name="name">
- <Property/>
+ <Property></Property>
<Property name="label">鍚嶇О</Property>
</PropertyDef>
<PropertyDef name="key">
- <Property/>
+ <Property></Property>
<Property name="label">鍏抽敭瀛�</Property>
</PropertyDef>
<PropertyDef name="start">
@@ -911,4 +911,65 @@
<Property name="readOnly">true</Property>
</PropertyDef>
</DataType>
+ <DataType name="dtNoticeParam">
+ <Property name="matchType">com.fzzy.igds.data.NoticeParam</Property>
+ <PropertyDef name="id">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="companyId">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="depotId">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="deptId">
+ <Property/>
+ <Property name="label">瑁呭嵏浠撳簱</Property>
+ </PropertyDef>
+ <PropertyDef name="customerName">
+ <Property/>
+ <Property name="label">瀹㈡埛鍚嶇О</Property>
+ </PropertyDef>
+ <PropertyDef name="foodVariety">
+ <Property/>
+ <Property name="label">绮鍝佺</Property>
+ </PropertyDef>
+ <PropertyDef name="contractId">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="planId">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="foodType">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="year">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="type">
+ <Property/>
+ </PropertyDef>
+ <PropertyDef name="weight">
+ <Property name="dataType">Double</Property>
+ </PropertyDef>
+ <PropertyDef name="taskNum">
+ <Property name="dataType">Double</Property>
+ </PropertyDef>
+ <PropertyDef name="completeStatus">
+ <Property/>
+ <Property name="label">瀹屾垚鐘舵��</Property>
+ </PropertyDef>
+ <PropertyDef name="storageReal">
+ <Property name="dataType">Double</Property>
+ </PropertyDef>
+ <PropertyDef name="start">
+ <Property name="dataType">Date</Property>
+ </PropertyDef>
+ <PropertyDef name="end">
+ <Property name="dataType">Date</Property>
+ </PropertyDef>
+ <PropertyDef name="createUser">
+ <Property/>
+ </PropertyDef>
+ </DataType>
</Model>
diff --git a/fzzy-igdss-web/src/main/resources/d7/common.css b/fzzy-igdss-web/src/main/resources/d7/common.css
index 106ee04..0908072 100644
--- a/fzzy-igdss-web/src/main/resources/d7/common.css
+++ b/fzzy-igdss-web/src/main/resources/d7/common.css
@@ -275,14 +275,22 @@
/**琛ㄥ崟TITLE**/
.f-title{
- font-weight: bold;
+ font: bold 30px Arial, sans-serif;
text-align: center;
- font-size:22px;
}
.bar-title {
font-weight: bold;
font-family: "寰蒋闆呴粦", Arial, sans-serif;
}
+/**琛ㄥ崟鎻愮ず淇℃伅**/
+.h-tip {
+ display: block;
+ color: #8a6d3b;
+ background-color: #fcf8e3;
+ border-color: #faebcc;
+ padding: 15px;
+ border-radius: 4px;
+}
/**瀹氬埗鏍峰紡**/
#d_cddWarehouse.d-modern-scroller {
--
Gitblit v1.9.3