修改
This commit is contained in:
@@ -57,7 +57,7 @@
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-6 button-primary" @tap="seachList">查询</button>
|
||||
<button class="zd-col-16 button-primary" :class="{'button-info': !pkId}" @tap="_materialConfirm">确认</button>
|
||||
<button class="zd-col-16 button-primary" :class="{'button-info': !dataList.length}" @tap="_callMaterialConfirm">确认</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -65,7 +65,7 @@
|
||||
<script>
|
||||
import NavBar from '@/components/NavBar.vue'
|
||||
import SearchBox from '@/components/SearchBox.vue'
|
||||
import {getRegion, linegetMaterialDtl, materialConfirm} from '@/utils/getData3.js'
|
||||
import {getRegion, linegetMaterialDtl, callMaterialConfirm} from '@/utils/getData3.js'
|
||||
export default {
|
||||
components: {
|
||||
NavBar,
|
||||
@@ -106,7 +106,7 @@
|
||||
methods: {
|
||||
async _getRegion () {
|
||||
try {
|
||||
let res = await getRegion()
|
||||
let res = await getRegion('YZHJ')
|
||||
if (res) {
|
||||
this.options = res
|
||||
} else {
|
||||
@@ -166,14 +166,14 @@
|
||||
this.pkId = this.pkId === e.group_id ? '' : e.group_id
|
||||
this.pkObj = this.pkId === e.group_id ? e : {}
|
||||
},
|
||||
async _materialConfirm () {
|
||||
async _callMaterialConfirm () {
|
||||
this.disabled = true
|
||||
if (!this.val1 || !this.val2 || !this.pkId) {
|
||||
if (!this.val1 || !this.val2 || !this.dataList.length) {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
try {
|
||||
let res = await materialConfirm(this.index, this.val1, this.pkObj)
|
||||
let res = await callMaterialConfirm(this.index, this.val1, this.pkObj)
|
||||
if (res.code === '200') {
|
||||
uni.showToast({
|
||||
title: res.message,
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
</view>
|
||||
<view class="zd-row submit-bar">
|
||||
<button class="zd-col-6 button-primary" @tap="seachList">查询</button>
|
||||
<button class="zd-col-16 button-primary" :class="{'button-info': !pkId}" @tap="_materialConfirm">确认</button>
|
||||
<button class="zd-col-16 button-primary" :class="{'button-info': !dataList.length}" @tap="_materialConfirm">确认</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
@@ -106,7 +106,7 @@
|
||||
methods: {
|
||||
async _getSect () {
|
||||
try {
|
||||
let res = await getSect()
|
||||
let res = await getSect('XB')
|
||||
if (res) {
|
||||
this.options = res
|
||||
} else {
|
||||
@@ -168,7 +168,7 @@
|
||||
},
|
||||
async _materialConfirm () {
|
||||
this.disabled = true
|
||||
if (!this.val1 || !this.val2 || !this.pkId) {
|
||||
if (!this.dataList.length) {
|
||||
this.disabled = false
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user