明树Git Lab
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
L
letian_backend
Project
Project
Details
Activity
Releases
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
zengfanpei
letian_backend
Commits
5219c62f
Commit
5219c62f
authored
Nov 21, 2024
by
zfp1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
85fcf5ff
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
3 deletions
+20
-3
agrInputRecordController.js
controller/agrInputRecordController.js
+18
-1
letianAgrMatInOut.js
db/models/letianAgrMatInOut.js
+1
-1
agrRouter.js
router/agrRouter.js
+1
-1
No files found.
controller/agrInputRecordController.js
View file @
5219c62f
...
...
@@ -9,6 +9,22 @@ const fs = require('fs');
async
function
listFroDP
(
req
,
res
,
next
)
{
try
{
let
search
=
{
del
:
0
};
let
page
=
req
.
body
.
page
||
1
;
let
pageSize
=
req
.
body
.
pageSize
||
10
;
let
skip
=
(
page
-
1
)
*
pageSize
;
if
(
req
.
body
.
agrProName
)
{
search
.
agrProName
=
req
.
body
.
agrProName
;
}
let
count
=
await
DB
.
AgrInputRecord
.
countDocuments
(
search
)
let
list
=
await
DB
.
AgrInputRecord
.
find
(
search
).
skip
(
skip
).
limit
(
1000
);
//甲方要求整体循环,暂时调整
res
.
sendData
({
count
,
list
});
}
catch
(
error
)
{
next
(
error
)
}
}
async
function
list
(
req
,
res
,
next
)
{
try
{
let
search
=
{
del
:
0
};
...
...
@@ -118,5 +134,6 @@ module.exports = {
create
,
importExcel
,
deleteOne
,
updateOne
updateOne
,
listFroDP
}
\ No newline at end of file
db/models/letianAgrMatInOut.js
View file @
5219c62f
...
...
@@ -3,7 +3,7 @@ const Schema = mongoose.Schema;
const
moment
=
require
(
'moment'
);
/**
* 农资管理-
农资库存信息表
* 农资管理-
导入导出内容--记录
*/
const
AgrMaterialInOutSchema
=
new
Schema
({
...
...
router/agrRouter.js
View file @
5219c62f
...
...
@@ -9,7 +9,7 @@ const agrInputEmployController = require('../controller/agrInputEmployController
// excel采集信息上传 甲方要求
//1. 青皮柚农业投入品使用情况
router
.
post
(
'/input/list'
,
agrInputRecordController
.
list
);
router
.
post
(
'/input/list'
,
agrInputRecordController
.
list
FroDP
);
router
.
post
(
'/inputRecord/list'
,
agrInputRecordController
.
list
);
router
.
post
(
'/inputRecord/update'
,
agrInputRecordController
.
updateOne
);
router
.
post
(
'/inputRecord/delete'
,
agrInputRecordController
.
deleteOne
);
...
...
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