Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
patzn-cloud-web-back-soil
Overview
Overview
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
wangweidong
patzn-cloud-web-back-soil
Commits
83e688a9
Commit
83e688a9
authored
Nov 07, 2020
by
wangweidong
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
df0ebe7b
59c16123
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
315 additions
and
32 deletions
+315
-32
.env.production
env/.env.production
+1
-0
nuxt.config.js
nuxt.config.js
+3
-1
RegisterItemBatchEdit.vue
pages/meter-entrust/RegisterItemBatchEdit.vue
+235
-0
SoilSampleItemManageEdit.vue
pages/meter-entrust/SoilSampleItemManageEdit.vue
+35
-12
SampleBackupsManage.vue
...-sample-manage/backups-manage/tab/SampleBackupsManage.vue
+19
-3
AddressManage.vue
pages/soil-sample-manage/keep-address/AddressManage.vue
+12
-12
SampleSurplusManage.vue
...-sample-manage/surplus-manage/tab/SampleSurplusManage.vue
+7
-1
SelectOriTempRecord.vue
pages/soil-test-manage/test-input/SelectOriTempRecord.vue
+2
-2
common.js
plugins/common.js
+1
-1
No files found.
env/.env.production
View file @
83e688a9
...
...
@@ -3,4 +3,5 @@ WEB_URL=http://soil.patzn.com
BASE_URL=http://api.patzn.com
SSO_URL=http://sso.patzn.com
STATIC_URL=http://static.patzn.com
RECORD_URL=http://record.patzn.com
NC_URL=http://123.133.38.68:8088
nuxt.config.js
View file @
83e688a9
...
...
@@ -169,5 +169,7 @@ module.exports = {
'~/plugins/element-ui.js'
,
'~/plugins/vue-inject.js'
]
}
},
// 启动时不会询问那句话了
telemetry
:
false
}
pages/meter-entrust/RegisterItemBatchEdit.vue
0 → 100644
View file @
83e688a9
<
template
>
<div>
<Modal
v-model=
"showModal"
:mask-closable=
"false"
>
<p
slot=
"header"
>
填写试验项目信息
</p>
<div>
<Form
id=
"storage-location-form"
ref=
"formObj"
:model=
"formObj"
:rules=
"ruleValidate"
:label-width=
"100"
>
<Form-item
label=
"英文简写:"
prop=
"shortName"
>
<el-input
v-model=
"formObj.shortName"
name=
"shortName"
placeholder=
"请输入英文简写"
>
</el-input>
</Form-item>
<Form-item
label=
"大类:"
prop=
"mainType"
>
<el-input
v-model=
"formObj.mainType"
name=
"mainType"
placeholder=
"请输入大类"
>
</el-input>
</Form-item>
<Form-item
label=
"小类:"
prop=
"smallType"
>
<el-input
v-model=
"formObj.smallType"
name=
"smallType"
placeholder=
"请输入小类"
>
</el-input>
</Form-item>
<Form-item
label=
"试验方法:"
prop=
"testMethod"
>
<el-input
v-model=
"formObj.testMethod"
name=
"testMethod"
placeholder=
"请输入试验方法"
>
</el-input>
</Form-item>
<Form-item
label=
"试验科室:"
>
<el-select
:value=
"formObj.groupName"
@
change=
"selGroupName"
style=
"width:100%"
size=
"small"
>
<el-option
v-for=
"item in groupoptions"
:value=
"item.id"
:label=
"item.name"
:key=
"item.name"
>
{{
item
.
name
}}
</el-option>
</el-select>
</Form-item>
<Form-item
label=
"检测依据:"
>
<AutoCompletes
v-model=
"formObj.testBasis"
:down-data=
"testBasisList"
@
on-result-change=
"_selTestBasis"
style=
"editable:false"
clearable
placeholder=
"请选择检测依据"
show-key=
"name"
></AutoCompletes>
</Form-item>
</Form>
</div>
<div
slot=
"footer"
>
<modal-footer
ref=
"footerModal"
@
on-result-change=
"_footerResult"
:footer=
"footerList"
></modal-footer>
</div>
</Modal>
</div>
</
template
>
<
script
>
import
{
soilAptitude
,
soilSample
}
from
'../../api'
import
AutoCompletes
from
'../../components/base/AutoCompletes'
export
default
{
components
:
{
AutoCompletes
},
data
()
{
return
{
ids
:
[],
// 委托ids
showModal
:
false
,
formObj
:
{},
ruleValidate
:
{},
footerList
:
[
{
id
:
''
,
name
:
'取消'
,
type
:
''
},
{
id
:
''
,
name
:
'保存'
,
type
:
'primary'
}
],
conditionList
:
[],
locList
:
[],
backupUserList
:
[],
prepareWayList
:
[],
keepWayList
:
[],
keepContainerList
:
[],
groupoptions
:
[],
testBasisList
:
[],
sampleUnit
:
''
}
},
mounted
()
{
this
.
_getGroupList
()
this
.
_getTestBasisList
()
},
methods
:
{
_locChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'select'
:
this
.
formObj
.
backupPlace
=
data
.
backupPlace
this
.
_getCondition
(
data
.
backupPlace
)
break
case
'query'
:
this
.
formObj
.
backupPlace
=
data
.
backupPlace
this
.
_getLocList
(
data
.
backupPlace
)
break
}
},
_getGroupList
:
async
function
()
{
const
result
=
await
soilAptitude
.
getGroupList
()
if
(
result
)
{
this
.
groupoptions
=
result
console
.
log
(
'试验科室'
,
result
)
}
},
_getTestBasisList
:
async
function
()
{
const
result
=
await
soilAptitude
.
getBasisList
()
if
(
result
)
{
this
.
testBasisList
=
result
}
},
_selTestBasis
(
msg
,
data
)
{
if
(
msg
===
'select'
)
{
this
.
formObj
.
testBasis
=
data
.
name
}
},
channelInputLimit
(
e
)
{
const
key
=
e
.
key
// 不允许输入'e'和'.'
if
(
key
===
'e'
||
key
===
'.'
)
{
e
.
returnValue
=
false
return
false
}
return
true
},
selPrepareWay
(
data
)
{
this
.
$forceUpdate
()
this
.
formObj
.
prepareWay
=
data
},
selKeepWay
(
data
)
{
this
.
$forceUpdate
()
this
.
formObj
.
keepWay
=
data
},
selKeepContainer
(
msg
,
data
)
{
this
.
$forceUpdate
()
if
(
msg
===
'select'
)
{
this
.
formObj
.
keepContainer
=
data
.
name
}
else
if
(
msg
===
'query'
)
{
this
.
formObj
.
keepContainer
=
data
.
name
}
},
selGroupName
(
data
)
{
this
.
$forceUpdate
()
if
(
data
)
{
for
(
let
i
=
0
;
i
<
this
.
groupoptions
.
length
;
i
++
)
{
if
(
this
.
groupoptions
[
i
].
id
===
data
)
{
this
.
formObj
.
groupName
=
this
.
groupoptions
[
i
].
name
}
}
}
else
{
this
.
getPage
.
records
[
this
.
currentIndex
].
groupName
=
''
}
this
.
formObj
.
groupId
=
data
// this.$forceUpdate()
// this.getPage.records[this.currentIndex].backupUser = data
// this.getPage.records[this.currentIndex].backupUser = data
},
// 存储条件 回调
_locChangeCondition
(
msg
,
data
)
{
switch
(
msg
)
{
case
'select'
:
this
.
formObj
.
storageCondition
=
data
.
name
this
.
_getLocCondition
(
data
.
name
)
break
case
'query'
:
this
.
formObj
.
storageCondition
=
data
.
name
this
.
_getLocConditionList
(
data
.
name
)
break
}
},
_footerResult
(
name
)
{
switch
(
name
)
{
case
'取消'
:
this
.
_cancel
()
break
case
'保存'
:
this
.
_ok
()
break
}
},
_open
(
data
)
{
this
.
showModal
=
true
this
.
formObj
=
this
.
$resetFields
(
this
.
formObj
)
this
.
sampleUnit
=
''
this
.
$refs
.
footerModal
.
_hideLoading
()
this
.
ids
=
data
// 循环遍历数据
},
_getPrepareWay
:
async
function
()
{
const
result
=
await
soilSample
.
getDictList
(
'制备方式'
)
if
(
result
)
{
this
.
prepareWayList
=
result
}
},
_getkeepWayList
:
async
function
()
{
const
result
=
await
soilSample
.
getDictList
(
'保存方式'
)
if
(
result
)
{
this
.
keepWayList
=
result
}
},
_getkeepContainerList
:
async
function
()
{
const
result
=
await
soilSample
.
getDictList
(
'保存容器'
)
if
(
result
)
{
this
.
keepContainerList
=
result
}
},
_getUserList
:
async
function
()
{
const
result
=
await
soilSample
.
getUserList
()
if
(
result
)
{
console
.
log
(
result
)
this
.
backupUserList
=
result
.
records
}
},
//
_dateChange
(
data
)
{
this
.
formObj
.
endDate
=
data
},
_cancel
()
{
this
.
showModal
=
false
this
.
$refs
.
footerModal
.
_hideLoading
()
},
_hideLoading
()
{
this
.
$refs
.
footerModal
.
_hideLoading
()
},
_ok
()
{
this
.
$refs
.
formObj
.
validate
(
valid
=>
{
if
(
valid
)
{
console
.
log
(
this
.
formObj
)
const
tempData
=
this
.
formObj
tempData
.
ids
=
this
.
ids
.
join
(
','
)
this
.
_saveInfo
(
tempData
)
}
else
{
this
.
$Message
.
error
(
'表单验证失败!'
)
this
.
$refs
.
footerModal
.
_hideLoading
()
}
})
},
_saveInfo
:
async
function
(
data
)
{
const
result
=
await
soilSample
.
editItem
(
data
)
if
(
result
)
{
this
.
showModal
=
false
this
.
$refs
.
footerModal
.
_hideLoading
()
this
.
$emit
(
'on-result-change'
)
this
.
$Message
.
success
(
'保存成功'
)
}
}
}
}
</
script
>
pages/meter-entrust/SoilSampleItemManageEdit.vue
View file @
83e688a9
...
...
@@ -31,7 +31,7 @@
<!-- 表格 -->
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:table-height=
"tableHeight"
:form-id=
"formId"
:loading=
"true"
:get-page=
"getPage"
@
on-result-change=
"_tableResultChange"
is-edit
>
:get-page=
"getPage"
@
on-result-change=
"_tableResultChange"
is-edit
select-data
>
<vxe-table-column
v-for=
"item in pageColumns"
:key=
"item.key"
...
...
@@ -110,19 +110,32 @@
<modal-footer
ref=
"footerModal"
:footer=
"footerList"
@
on-result-change=
"_footerResult"
/>
</div>
</Modal>
<RegisterItemBatchEdit
ref=
"batchEdit"
@
on-result-change=
"_pageByEntrustId"
></RegisterItemBatchEdit>
</div>
</template>
<
script
>
import
http
from
'../../api/http'
import
{
soilAptitude
,
soilEntrust
}
from
'../../api'
import
AutoCompletes
from
'../../components/base/AutoCompletes'
import
RegisterItemBatchEdit
from
'./RegisterItemBatchEdit'
export
default
{
components
:
{
AutoCompletes
},
components
:
{
AutoCompletes
,
RegisterItemBatchEdit
},
data
()
{
return
{
formId
:
'SampleItemManage'
,
currentComponent
:
''
,
btn
:
[],
btn
:
[
{
type
:
'success'
,
id
:
''
,
name
:
'批量填写试验项目信息'
},
{
type
:
'error'
,
id
:
''
,
name
:
'删除'
}
],
iconMsg
:
[{
type
:
'pt-a-end'
,
id
:
''
,
name
:
'删除'
}],
sampleId
:
''
,
// 样品id
entrustId
:
''
,
...
...
@@ -198,6 +211,13 @@ export default {
this
.
_cancelSub
(
data
.
id
)
}
},
_writeInfo
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请选择一条或多条数据!'
)
}
else
{
this
.
$refs
.
batchEdit
.
_open
(
this
.
selectIds
)
}
},
_footerResult
(
name
)
{
switch
(
name
)
{
case
'取消'
:
...
...
@@ -325,6 +345,9 @@ export default {
case
'导入检测项目'
:
this
.
_importItem
()
break
case
'批量填写试验项目信息'
:
this
.
_writeInfo
()
break
case
'导入检测项目包'
:
this
.
_importItemPackage
()
break
...
...
@@ -354,7 +377,7 @@ export default {
const
result
=
await
soilEntrust
.
pageItemEdit
(
data
)
if
(
result
)
{
this
.
$message
.
success
(
'保存成功'
)
this
.
_page
()
this
.
_page
ByEntrustId
()
}
else
{
this
.
$message
.
warning
(
'保存失败'
)
}
...
...
@@ -363,7 +386,7 @@ export default {
const
result
=
await
soilEntrust
.
pageItemEdit
(
data
)
if
(
result
)
{
this
.
$message
.
success
(
'保存成功'
)
this
.
_page
()
this
.
_page
ByEntrustId
()
}
else
{
this
.
$message
.
warning
(
'保存失败'
)
}
...
...
@@ -372,7 +395,7 @@ export default {
const
result
=
await
soilEntrust
.
pageItemEdit
(
data
)
if
(
result
)
{
this
.
$message
.
success
(
'保存成功'
)
this
.
_page
()
this
.
_page
ByEntrustId
()
}
else
{
this
.
$message
.
warning
(
'保存失败'
)
}
...
...
@@ -381,7 +404,7 @@ export default {
const
result
=
await
soilEntrust
.
pageItemEdit
(
data
)
if
(
result
)
{
this
.
$message
.
success
(
'保存成功'
)
this
.
_page
()
this
.
_page
ByEntrustId
()
}
else
{
this
.
$message
.
warning
(
'保存失败'
)
}
...
...
@@ -523,7 +546,7 @@ export default {
this
.
showModal
=
true
this
.
sampleId
=
id
// 委托id
this
.
$refs
.
pageTable
.
_hideLoading
()
this
.
_page
()
this
.
_page
ByEntrustId
()
},
_openByEntrustId
(
id
)
{
this
.
formObj
=
this
.
$resetFields
(
this
.
formObj
)
...
...
@@ -542,7 +565,7 @@ export default {
this
.
sampleId
=
id
// 委托id
this
.
$refs
.
pageTable
.
_hideLoading
()
this
.
showOption
=
false
this
.
_page
()
this
.
_page
ByEntrustId
()
},
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
...
...
@@ -584,7 +607,7 @@ export default {
},
_deleteOk
:
async
function
(
ids
)
{
const
result
=
await
soilEntrust
.
d
eleteById
(
ids
)
const
result
=
await
soilEntrust
.
experimentD
eleteById
(
ids
)
if
(
result
)
{
this
.
_resultChange
(
'删除成功! '
)
}
...
...
@@ -636,10 +659,10 @@ export default {
}
},
_search
()
{
this
.
_page
()
this
.
_page
ByEntrustId
()
},
_resultChange
(
msg
)
{
this
.
_page
()
this
.
_page
ByEntrustId
()
this
.
$Message
.
success
(
msg
)
this
.
$emit
(
'on-result-change'
)
},
...
...
pages/soil-sample-manage/backups-manage/tab/SampleBackupsManage.vue
View file @
83e688a9
...
...
@@ -459,7 +459,7 @@ export default {
const
errorIds
=
[]
for
(
let
i
=
0
;
i
<
this
.
selectIds
.
length
;
i
++
)
{
if
(
this
.
selectData
[
i
].
status
.
display
!==
'处理审批通过'
)
{
errorIds
.
push
(
this
.
selectData
[
i
].
sampleCode
)
errorIds
.
push
(
this
.
selectData
[
i
].
index
+
1
)
}
}
if
(
errorIds
.
length
===
0
)
{
...
...
@@ -471,7 +471,18 @@ export default {
}
})
}
else
{
this
.
$Message
.
warning
(
'试样编号为 '
+
errorIds
+
' 的审批未通过'
)
// this.$Notice.error({
// title: '文件格式不正确',
// duration: 10,
// desc: '试样编号为 ' + errorIds + ' 的审批未通过'
// })
// this.$Message.warning('试样编号为 ' + errorIds + ' 的审批未通过')
this
.
$notify
({
title
:
'提示'
,
message
:
'第 '
+
errorIds
+
' 行数据的审批未通过'
,
duration
:
4000
,
type
:
'error'
})
// this.$Modal.confirm({
// title: '提示',
// content: '试样编号为 ' + errorIds + ' 的审批未通过'
...
...
@@ -660,7 +671,12 @@ export default {
}
}
</
script
>
<
style
scoped
>
<
style
>
.el-notification__content
p
{
white-space
:
pre-wrap
!important
;
word-wrap
:
break-word
;
word-break
:
break-all
;
}
/******副样、备样卡片********/
.reimbursement-item
{
flex
:
1
;
...
...
pages/soil-sample-manage/keep-address/AddressManage.vue
View file @
83e688a9
...
...
@@ -11,6 +11,9 @@
<Form-item
class=
"search-item"
label=
"委托编号:"
>
<Input
@
on-enter=
"_formSearch"
v-model=
"formObj.entrustCode"
name=
"entrustCode"
placeholder=
"请输入委托编号"
clearable
/>
</Form-item>
<Form-item
class=
"search-item"
label=
"试样编号:"
>
<Input
@
on-enter=
"_formSearch"
v-model=
"formObj.sampleCode"
name=
"sampleCode"
placeholder=
"请输入试样编号"
clearable
/>
</Form-item>
<Form-item
class=
"search-btn"
>
<Button
@
click=
"_formSearch"
type=
"primary"
>
搜索
</Button>
</Form-item>
...
...
@@ -85,6 +88,7 @@ export default {
currentComponent
:
''
,
formObj
:
{
entrustCode
:
undefined
,
sampleCode
:
undefined
,
name
:
undefined
},
btn
:
[
...
...
@@ -102,18 +106,14 @@ export default {
pageColumns
:
[
{
title
:
'委托商'
,
key
:
'client'
,
width
:
200
},
{
title
:
'委托编号'
,
key
:
'entrustCode'
,
width
:
120
},
{
title
:
'委托日期'
,
key
:
'entrustDate'
,
width
:
120
,
date
:
true
},
{
title
:
'钻孔位置'
,
key
:
'boreholeLocation'
,
width
:
120
},
{
title
:
'水深(米)'
,
key
:
'waterDepth'
,
width
:
120
},
{
title
:
'钻孔名称'
,
key
:
'boreholeName'
,
width
:
120
},
{
title
:
'进度'
,
key
:
'progress'
,
width
:
120
,
status
:
true
},
{
title
:
'平均容重'
,
key
:
'projectNo'
,
width
:
120
},
{
title
:
'报告编号'
,
key
:
'reportCode'
,
width
:
120
},
{
title
:
'制表日期'
,
key
:
'tabulateDate'
,
width
:
120
,
date
:
true
},
{
title
:
'制表人'
,
key
:
'tabulater'
,
width
:
120
},
{
title
:
'批准日期'
,
key
:
'approveDate'
,
width
:
120
,
date
:
true
},
{
title
:
'批准人'
,
key
:
'approver'
,
width
:
120
},
{
title
:
'检验类别'
,
key
:
'testType'
,
width
:
120
}
{
title
:
'试样编号'
,
key
:
'sampleCode'
,
width
:
100
},
{
title
:
'试样深度'
,
key
:
'sampleDepth'
,
width
:
95
},
{
title
:
'现场编号'
,
key
:
'siteNo'
,
width
:
100
},
{
title
:
'接收人'
,
key
:
'receiver'
,
width
:
120
},
{
title
:
'接收时间'
,
key
:
'receiveTime'
,
width
:
140
,
date
:
true
},
{
title
:
'收样存储位置'
,
key
:
'receiveLocation'
,
width
:
140
},
{
title
:
'土质描述'
,
key
:
'sampleDescribe'
,
width
:
185
},
{
title
:
'样品包装类型'
,
key
:
'samplePack'
,
width
:
120
}
],
// 操作
iconMsg
:
[
...
...
pages/soil-sample-manage/surplus-manage/tab/SampleSurplusManage.vue
View file @
83e688a9
...
...
@@ -379,7 +379,13 @@ export default {
}
})
}
else
{
this
.
$Message
.
warning
(
'第 '
+
errorIds
+
' 条数据的审批未通过'
)
// this.$Message.warning('第 ' + errorIds + ' 条数据的审批未通过')
this
.
$notify
({
title
:
'提示'
,
message
:
'第 '
+
errorIds
+
' 行数据的审批未通过'
,
duration
:
4000
,
type
:
'error'
})
}
}
},
...
...
pages/soil-test-manage/test-input/SelectOriTempRecord.vue
View file @
83e688a9
...
...
@@ -199,7 +199,7 @@ export default {
ids
:
'1289126946969550850'
,
tempId
:
this
.
selectData
[
0
].
id
}
console
.
log
(
param
)
console
.
log
(
'模板'
,
param
)
this
.
_createOriginalRecord
()
// this._check(param)
// this.$store.dispatch('EnvItem/checkLimit', param).then(() => {
...
...
@@ -234,7 +234,7 @@ export default {
// labelSample: ''
}
this
.
$refs
.
iframeModal
.
_createIframe
(
url
,
params
)
console
.
log
(
'原始记录'
,
url
,
params
)
localStorage
.
setItem
(
'recordStatus'
,
'addLabRecord'
)
},
// 生成原始记录
...
...
plugins/common.js
View file @
83e688a9
...
...
@@ -974,7 +974,7 @@ Vue.prototype.$optColWidth = function(list) {
}
return
arrayList
.
length
>
0
?
85
+
width
*
(
arrayList
.
length
-
1
)
:
0
}
Vue
.
prototype
.
$defRow
=
50
Vue
.
prototype
.
$defRow
=
50
0
Vue
.
prototype
.
$setOptimization
=
function
(
msg
)
{
// 默认 数据超过200条,启用虚拟加载,每次加载50条
let
result
=
{
gt
:
200
,
oSize
:
20
,
rSize
:
50
}
...
...
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