Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mes
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ximai
mes
Commits
3677e37d
Commit
3677e37d
authored
Oct 22, 2024
by
温志超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
车间异常单增加车间异常单编号
parent
1f8007b8
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
34 additions
and
0 deletions
+34
-0
QcAbnormalReportController.java
...m/ximai/mes/qc/controller/QcAbnormalReportController.java
+12
-0
QcAbnormalReport.java
...c/main/java/com/ximai/mes/qc/domain/QcAbnormalReport.java
+5
-0
IQcAbnormalReportService.java
...va/com/ximai/mes/qc/service/IQcAbnormalReportService.java
+2
-0
QcAbnormalReportServiceImpl.java
...imai/mes/qc/service/impl/QcAbnormalReportServiceImpl.java
+10
-0
QcAbnormalReportMapper.xml
mes/src/main/resources/mapper/qc/QcAbnormalReportMapper.xml
+5
-0
No files found.
mes/src/main/java/com/ximai/mes/qc/controller/QcAbnormalReportController.java
View file @
3677e37d
...
...
@@ -86,4 +86,16 @@ public class QcAbnormalReportController extends BaseController {
qcAbnormalReportService
.
updateQcAbnormalReportAbmornalStatud
(
abnormalReportIds
);
return
AjaxResult
.
success
(
""
);
}
/**
* 获取车间异常编号
*/
@PreAuthorize
(
"@ss.hasPermi('qc:report:remove')"
)
@GetMapping
(
"/getAbnormalNumber"
)
public
AjaxResult
getAbnormalNumber
()
{
String
abnormalNumber
=
qcAbnormalReportService
.
getAbnormalNumber
();
return
AjaxResult
.
success
(
"操作成功"
,
abnormalNumber
);
}
}
mes/src/main/java/com/ximai/mes/qc/domain/QcAbnormalReport.java
View file @
3677e37d
...
...
@@ -27,6 +27,11 @@ QcAbnormalReport extends BaseEntity
@Excel
(
name
=
"编批单号"
)
private
String
batchNumber
;
/** 编批单号 */
@Excel
(
name
=
"车间异常单单号 来源于编码规则:ABNORMAL_NUMBER"
)
private
String
abnormalNumber
;
/** 工序ID */
@Excel
(
name
=
"工序ID"
)
private
Long
processId
;
...
...
mes/src/main/java/com/ximai/mes/qc/service/IQcAbnormalReportService.java
View file @
3677e37d
...
...
@@ -68,4 +68,6 @@ public interface IQcAbnormalReportService {
* @return 结果
*/
void
updateQcAbnormalReportAbmornalStatud
(
Long
abnormalReportIds
);
String
getAbnormalNumber
();
}
mes/src/main/java/com/ximai/mes/qc/service/impl/QcAbnormalReportServiceImpl.java
View file @
3677e37d
package
com
.
ximai
.
mes
.
qc
.
service
.
impl
;
import
com.ximai.common.constant.UserConstants
;
import
com.ximai.common.exception.ServiceException
;
import
com.ximai.common.utils.MessageUtils
;
import
com.ximai.common.utils.data.DateUtils
;
...
...
@@ -20,6 +21,7 @@ import com.ximai.mes.pro.service.task.IProTaskWorkunitService;
import
com.ximai.mes.qc.domain.QcAbnormalReport
;
import
com.ximai.mes.qc.mapper.QcAbnormalReportMapper
;
import
com.ximai.mes.qc.service.IQcAbnormalReportService
;
import
com.ximai.system.strategy.AutoCodeUtil
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
...
...
@@ -56,6 +58,9 @@ public class QcAbnormalReportServiceImpl implements IQcAbnormalReportService {
@Autowired
private
ProProcessMapper
proProcessMapper
;
@Autowired
private
AutoCodeUtil
autoCodeUtil
;
/**
* 查询车间异常单
*
...
...
@@ -185,4 +190,9 @@ public class QcAbnormalReportServiceImpl implements IQcAbnormalReportService {
qcAbnormalReportMapper
.
updateQcAbnormalReport
(
qcAbnormalReport
);
}
@Override
public
String
getAbnormalNumber
()
{
return
autoCodeUtil
.
genSerialCode
(
"ABNORMAL_NUMBER"
,
null
);
}
}
mes/src/main/resources/mapper/qc/QcAbnormalReportMapper.xml
View file @
3677e37d
...
...
@@ -27,6 +27,7 @@
<sql
id=
"selectQcAbnormalReportVo"
>
select abnormal_report_id, batch_number, process_id, task_id, task_workunit_id, process_code, process_name, workstation_id, workstation_code, workstation_name, abnormal_type, abnormal_reason, abnormal_time, abnormal_status, create_by, create_time, update_by, update_time
,abnormal_number
from qc_abnormal_report
</sql>
...
...
@@ -48,6 +49,7 @@
<if
test=
"beginPurchaseDate != null "
>
abnormal_time BETWEEN #{beginPurchaseDate}
</if>
<if
test=
"endPurchaseDate != null "
>
and #{endPurchaseDate}
</if>
<if
test=
"abnormalStatus != null and abnormalStatus != ''"
>
and abnormal_status = #{abnormalStatus}
</if>
<if
test=
"abnormalNumber != null"
>
and abnormal_number = #{abnormalNumber}
</if>
</where>
</select>
...
...
@@ -76,6 +78,7 @@
<if
test=
"createTime != null"
>
create_time,
</if>
<if
test=
"updateBy != null"
>
update_by,
</if>
<if
test=
"updateTime != null"
>
update_time,
</if>
<if
test=
"abnormalNumber != null"
>
abnormal_number,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"batchNumber != null"
>
#{batchNumber},
</if>
...
...
@@ -95,6 +98,8 @@
<if
test=
"createTime != null"
>
#{createTime},
</if>
<if
test=
"updateBy != null"
>
#{updateBy},
</if>
<if
test=
"updateTime != null"
>
#{updateTime},
</if>
<if
test=
"abnormalNumber != null"
>
#{abnormalNumber},
</if>
</trim>
</insert>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment