fix: pos机管理,优化。
This commit is contained in:
@@ -57,7 +57,7 @@
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
<u--text lines="1"
|
||||
:text="item.account+'可用余额:'+item.availableLimit" size="30rpx" color="#333333" ></u--text>
|
||||
:text="item.account+':'+item.availableLimit" size="25rpx" color="#333333" ></u--text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
@@ -16,9 +16,15 @@
|
||||
inputAlign="right" border="none"></u--input>
|
||||
<u-icon slot="right" name="arrow-down"></u-icon>
|
||||
</u-form-item>
|
||||
<u-form-item label="刷卡费率" prop="rate" >
|
||||
<u-form-item label="刷卡费率" required prop="rate" >
|
||||
<u--input v-model="form.rate" placeholder="请填写刷卡费率"
|
||||
inputAlign="right" border="none"></u--input>
|
||||
inputAlign="right" border="none">
|
||||
<template #suffix>
|
||||
<up-text
|
||||
text="%"
|
||||
></up-text>
|
||||
</template>
|
||||
</u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="费率+" prop="ratePlus" >
|
||||
<u--input v-model="form.ratePlus" placeholder="请填写费率+"
|
||||
|
||||
@@ -40,12 +40,23 @@
|
||||
</u-form-item>
|
||||
<u-form-item label="刷卡费率" required prop="rate" >
|
||||
<u--input v-model="form.rate" placeholder="请填写刷卡费率"
|
||||
inputAlign="right" border="none"></u--input>
|
||||
inputAlign="right" border="none">
|
||||
<template #suffix>
|
||||
<up-text
|
||||
text="%"
|
||||
></up-text>
|
||||
</template>
|
||||
</u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="费率+" required prop="ratePlus" >
|
||||
<u--input v-model="form.ratePlus" placeholder="请填写费率+"
|
||||
inputAlign="right" border="none"></u--input>
|
||||
</u-form-item>
|
||||
<u-form-item label="舍入模式" required prop="roundingModeName" @click="handleShowRoundingMode">
|
||||
<u--input v-model="form.roundingModeName" disabled disabledColor="#ffffff" placeholder="请选择舍入模式"
|
||||
inputAlign="right" border="none"></u--input>
|
||||
<u-icon slot="right" name="arrow-down"></u-icon>
|
||||
</u-form-item>
|
||||
<u-form-item label="厂商" prop="manufacture" >
|
||||
<u--input v-model="form.manufacture" placeholder="请填写厂商"
|
||||
inputAlign="right" border="none"></u--input>
|
||||
@@ -88,6 +99,8 @@
|
||||
@confirm="handleMerchantTypeConfirm"></u-picker>
|
||||
<u-picker itemHeight="88" :show="showStatus" :columns="statusList" keyName="dictLabel" @cancel="handleStatusCancel"
|
||||
@confirm="handleStatusConfirm"></u-picker>
|
||||
<u-picker itemHeight="88" :show="showRoundingMode" :columns="roundingModeList" keyName="dictLabel" @cancel="handleRoundingModeCancel"
|
||||
@confirm="handleRoundingModeConfirm"></u-picker>
|
||||
<u-datetime-picker
|
||||
:show="datePickShow"
|
||||
mode="date"
|
||||
@@ -117,6 +130,8 @@ const typeList = ref([])
|
||||
const merchantTypeList = ref([])
|
||||
const showStatus = ref(false)
|
||||
const statusList = ref([])
|
||||
const showRoundingMode = ref(false)
|
||||
const roundingModeList = ref([])
|
||||
const debitCardList = ref([])
|
||||
const dateType = ref(1)
|
||||
const data = reactive({
|
||||
@@ -141,7 +156,9 @@ const data = reactive({
|
||||
ratePlus: 0,
|
||||
activationDate: null,
|
||||
status: '1',
|
||||
statusName: '正常使用'
|
||||
statusName: '正常使用',
|
||||
roundingMode: '1',
|
||||
roundingModeName: '四舍五入'
|
||||
},
|
||||
queryDebitCardParams: {
|
||||
pageNum: 1,
|
||||
@@ -158,6 +175,7 @@ const data = reactive({
|
||||
code: [{ type: 'string', required: true, message: '编号不能为空', trigger: ['change', 'blur'] }],
|
||||
rate: [{ type: 'number', required: true, message: '刷卡费率不能为空', trigger: ['change', 'blur'] }],
|
||||
ratePlus: [{ type: 'number', required: true, message: '费率+不能为空', trigger: ['change', 'blur'] }],
|
||||
roundingModeName: [{ type: 'string', required: true, message: '费舍入模式不能为空', trigger: ['change', 'blur'] }],
|
||||
debitCard: [{ type: 'string', required: true, message: '结算卡不能为空', trigger: ['change', 'blur'] }],
|
||||
}
|
||||
})
|
||||
@@ -192,6 +210,10 @@ onLoad((option) => {
|
||||
getDicts('account_status').then(res => {
|
||||
statusList.value =[res.data]
|
||||
})
|
||||
// 类型
|
||||
getDicts('rounding_mode').then(res => {
|
||||
roundingModeList.value =[res.data]
|
||||
})
|
||||
if(form.value.id!=null){
|
||||
getPosmachine(form.value.id).then(res => {
|
||||
form.value = res.data
|
||||
@@ -206,6 +228,10 @@ onLoad((option) => {
|
||||
// 类型
|
||||
getDicts('account_status').then(result => {
|
||||
form.value.statusName=dictStr(form.value.status, result.data)
|
||||
})
|
||||
// 类型
|
||||
getDicts('rounding_mode').then(result => {
|
||||
form.value.roundingModeName=dictStr(form.value.roundingMode, result.data)
|
||||
})
|
||||
})
|
||||
}
|
||||
@@ -287,6 +313,23 @@ onLoad((option) => {
|
||||
function handleStatusCancel() {
|
||||
showStatus.value = false
|
||||
}
|
||||
function handleShowRoundingMode() {
|
||||
if (roundingModeList.value[0].length === 0) {
|
||||
proxy.$refs['uToast'].show({
|
||||
message: '舍入模式操作为空 ', type: 'warning'
|
||||
})
|
||||
} else {
|
||||
showRoundingMode.value = true
|
||||
}
|
||||
}
|
||||
function handleRoundingModeConfirm(e) {
|
||||
form.value.roundingModeName = e.value[0].dictLabel
|
||||
form.value.roundingMode = e.value[0].dictValue
|
||||
showRoundingMode.value = false
|
||||
}
|
||||
function handleRoundingModeCancel() {
|
||||
showRoundingMode.value = false
|
||||
}
|
||||
|
||||
function selectDate(type) {
|
||||
dateType.value=type
|
||||
|
||||
@@ -13,8 +13,9 @@
|
||||
<u-cell title="类型:" titleStyle="font-weight:bolder" :value="detailInfo.type"></u-cell>
|
||||
<u-cell title="账户状态:" titleStyle="font-weight:bolder" :value="detailInfo.status"></u-cell>
|
||||
<u-cell title="商户名称:" titleStyle="font-weight:bolder" center :value="detailInfo.merchantName"> </u-cell>
|
||||
<u-cell title="刷卡费率:" titleStyle="font-weight:bolder" :value="detailInfo.rate"></u-cell>
|
||||
<u-cell title="刷卡费率:" titleStyle="font-weight:bolder" :value="detailInfo.rateName"></u-cell>
|
||||
<u-cell title="费率+:" titleStyle="font-weight:bolder" :value="detailInfo.ratePlus+''"></u-cell>
|
||||
<u-cell title="舍入模式:" titleStyle="font-weight:bolder" :value="detailInfo.roundingMode"></u-cell>
|
||||
<u-cell title="结算卡:" titleStyle="font-weight:bolder" :value="detailInfo.bankNameCode"></u-cell>
|
||||
<u-cell title="商户类型:" titleStyle="font-weight:bolder" :value="detailInfo.merchantType"></u-cell>
|
||||
<u-cell title="商户码:" titleStyle="font-weight:bolder" :value="detailInfo.merchantCode"></u-cell>
|
||||
@@ -56,6 +57,10 @@ onLoad((option) => {
|
||||
// 类型
|
||||
getDicts('account_status').then(result => {
|
||||
detailInfo.value.status=dictStr(detailInfo.value.status, result.data)
|
||||
})
|
||||
// 类型
|
||||
getDicts('rounding_mode').then(result => {
|
||||
detailInfo.value.roundingMode=dictStr(detailInfo.value.roundingMode, result.data)
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
</view>
|
||||
<view class="item-row">
|
||||
<text class="row-label">刷卡费率:</text>
|
||||
<text class="row-value">{{ item.rate+'+'+ item.ratePlus}}</text>
|
||||
<text class="row-value">{{ item.rateName+'+'+ item.ratePlus}}</text>
|
||||
</view>
|
||||
<view class="item-row">
|
||||
<text class="row-label">结算卡:</text>
|
||||
|
||||
Reference in New Issue
Block a user