Browse Source

修改任务 #5594

Handy_Cao 2 years ago
parent
commit
4dfea2fe83

+ 8 - 6
src/packages/mobile/views/bank/wallet/components/deposit/Index.vue

@@ -63,12 +63,14 @@ const formRules: { [key: string]: FieldRule[] } = {
         required: true,
         required: true,
         message: '请填写入金金额',
         message: '请填写入金金额',
     }],
     }],
-    // filePath: [{
-    //     message: '请上传转账凭证',
-    //     validator: () => {
-    //         return !!certificate_photo_url.value
-    //     }
-    // }]
+    filePath: [{
+        message: '请上传转账凭证',
+        validator: () => {
+            /// 是否非必填
+            const ismandatory = Number(getSystemParamValue('316'))
+            return ismandatory === 0 ? true : !!certificate_photo_url.value
+        }
+    }]
 }
 }
 
 
 const onUploadSuccess = (filePath: string) => {
 const onUploadSuccess = (filePath: string) => {

+ 9 - 1
src/packages/sbyj/views/delivery/components/processing/components/pay/index.vue

@@ -46,7 +46,7 @@
 </template>
 </template>
 
 
 <script lang="ts" setup>
 <script lang="ts" setup>
-import { shallowRef, PropType, reactive, computed, onMounted } from 'vue'
+import { shallowRef, PropType, reactive, computed, onMounted, ref } from 'vue'
 import { CellGroup, Cell, Form, Field, Stepper, Button, FieldRule, FormInstance, Radio, RadioGroup } from 'vant'
 import { CellGroup, Cell, Form, Field, Stepper, Button, FieldRule, FormInstance, Radio, RadioGroup } from 'vant'
 import { fullloading, dialog } from '@/utils/vant'
 import { fullloading, dialog } from '@/utils/vant'
 import { formatDecimal, handleRequestBigNumber } from '@/filters'
 import { formatDecimal, handleRequestBigNumber } from '@/filters'
@@ -65,6 +65,7 @@ const props = defineProps({
 const formRef = shallowRef<FormInstance>()
 const formRef = shallowRef<FormInstance>()
 const showModal = shallowRef(true)
 const showModal = shallowRef(true)
 const refresh = shallowRef(false) // 是否刷新父组件数据
 const refresh = shallowRef(false) // 是否刷新父组件数据
+const headurl = ref('')
 
 
 const formData = reactive<Proto.DeliveryClientOperatorReq>({
 const formData = reactive<Proto.DeliveryClientOperatorReq>({
     DeliveryOrderID: handleRequestBigNumber(props.selectedRow.deliveryorderid),
     DeliveryOrderID: handleRequestBigNumber(props.selectedRow.deliveryorderid),
@@ -85,9 +86,16 @@ const formRules: { [key: string]: FieldRule[] } = {
             return !!formData.PayAmount
             return !!formData.PayAmount
         }
         }
     }],
     }],
+    headurl: [{
+        message: '请上传付款凭证',
+        validator: () => {
+            return !!headurl.value
+        }
+    }],
 }
 }
 
 
 const onUpload = (filePath: string) => {
 const onUpload = (filePath: string) => {
+    headurl.value = filePath
     formData.PayAttr?.push({
     formData.PayAttr?.push({
         FileAddr: filePath
         FileAddr: filePath
     })
     })