Ver código fonte

库存管理-客户下拉框修改

jingbb 3 meses atrás
pai
commit
e14afcf980

+ 3 - 12
src/views/inventiry/otherOut/otherOutList.vue

@@ -36,17 +36,7 @@
             <a-col :lg="8">
               <a-form-item name="customer">
                 <template #label><span title="客户(customer)">客户(customer)</span></template>
-                <ApiSelect
-                  :api="CustomerOption"
-                  showSearch
-                  v-model:value="queryParam.customer"
-                  :filterOption="true"
-                  resultField="records"
-                  labelField="abbreviation"
-                  valueField="id"
-                  :params="{ pageSize: -1 }"
-                  optionFilterProp="label"
-                />
+                <JSelect   v-model:value="queryParam.customer" :get-option-url="CustomerOption" :showField="showField"></JSelect>
               </a-form-item>
             </a-col>
             <a-col :lg="8">
@@ -148,10 +138,11 @@
     CustomerOption,
   } from './otherOutForm.api';
   import { cloneDeep } from 'lodash-es';
-  import { JDictSelectTag, ApiSelect, JInput } from '/@/components/Form';
+  import { JDictSelectTag, ApiSelect, JInput,JSelect} from '/@/components/Form';
   import { message } from 'ant-design-vue';
   const formRef = ref();
   const queryParam = reactive<any>({});
+  var showField = ref('currency+name');
   //注册model
   const [registerModal, { openModal }] = useModal();
   //注册table数据

+ 3 - 11
src/views/inventiry/salesOutbound/components/SelectDeliveryModal.vue

@@ -40,16 +40,7 @@
                         </a-col>
                         <a-col :md="6" :sm="8">
                             <a-form-item label="客户(customer)" :label-col="labelCol1" :wrapper-col="wrapperCol1">
-                                <ApiSelect
-                                    :api="CustomerOption"
-                                    showSearch
-                                    v-model:value="queryParams.customer"
-                                    optionFilterProp="label"
-                                    resultField="records"
-                                    labelField="abbreviation"
-                                    valueField="id"
-                                    :params='{pageSize:-1}'
-                                />
+                                <JSelect   v-model:value="queryParams.customer" :get-option-url="CustomerOption" :showField="showField"></JSelect>
                             </a-form-item>
                         </a-col>
                         
@@ -144,12 +135,13 @@
     import { defHttp} from '/@/utils/http/axios';
     import { message } from 'ant-design-vue';
     import { filterObj, getFileAccessHttpUrl } from '/@/utils/common/compUtils';
-    import { JDictSelectTag,ApiSelect,JInput} from '/@/components/Form';
+    import { JDictSelectTag,ApiSelect,JInput,JSelect} from '/@/components/Form';
     import {ProjectOption,CustomerOption,ClassList} from '../salesOutboundForm.api';
     const emit = defineEmits([ 'SelectDelivery']); //定义emit
     var visible = ref(false)
     var fatherProject = ref('')
     var fatherSourceCode = ref('')
+    var showField = ref('currency+name');
     const columns = [
         { 
             type: 'selection',

+ 3 - 11
src/views/inventiry/salesOutbound/components/SelectStaningStockModal.vue

@@ -44,16 +44,7 @@
                         </a-col>
                         <a-col :md="6" :sm="8">
                             <a-form-item label="客户(customer)">
-                                <ApiSelect
-                                    :api="CustomerOption"
-                                    showSearch
-                                    v-model:value="queryParams.customer"
-                                    optionFilterProp="label"
-                                    resultField="records"
-                                    labelField="abbreviation"
-                                    valueField="id"
-                                    :params='{pageSize:-1}'
-                                />
+                                <JSelect   v-model:value="queryParams.customer" :get-option-url="CustomerOption" :showField="showField"></JSelect>
                             </a-form-item>
                         </a-col>
                         <a-col :md="6" :sm="8">
@@ -148,11 +139,12 @@
     import { defHttp} from '/@/utils/http/axios';
     import { message } from 'ant-design-vue';
     import { filterObj, getFileAccessHttpUrl } from '/@/utils/common/compUtils';
-    import { JDictSelectTag,ApiSelect,JInput } from '/@/components/Form';
+    import { JDictSelectTag,ApiSelect,JInput,JSelect } from '/@/components/Form';
     import {CustomerOption,ClassList,supplierOption} from '../salesOutboundForm.api';
     const emit = defineEmits([ 'SelectStaningStock']); //定义emit
     var visible = ref(false)
     var father = ref({})
+    var showField = ref('currency+name');
     const columns = [
         { 
             type: 'selection',

+ 3 - 12
src/views/inventiry/salesOutbound/salesOutboundList.vue

@@ -36,17 +36,7 @@
             <a-col :lg="8">
               <a-form-item name="customer">
                 <template #label><span title="客户(customer)">客户(customer)</span></template>
-                <ApiSelect
-                  :api="CustomerOption"
-                  showSearch
-                  v-model:value="queryParam.customer"
-                  :filterOption="true"
-                  resultField="records"
-                  labelField="abbreviation"
-                  valueField="id"
-                  :params="{ pageSize: -1 }"
-                  optionFilterProp="label"
-                />
+                <JSelect   v-model:value="queryParam.customer" :get-option-url="CustomerOption" :showField="showField"></JSelect>
               </a-form-item>
             </a-col>
             <a-col :lg="8">
@@ -194,7 +184,7 @@
     ClassList,
   } from './salesOutboundForm.api';
   import { cloneDeep } from 'lodash-es';
-  import { JDictSelectTag, ApiSelect, JInput } from '/@/components/Form';
+  import { JDictSelectTag, ApiSelect, JInput,JSelect } from '/@/components/Form';
   import { message } from 'ant-design-vue';
   import { useGlobSetting } from '/@/hooks/setting';
   import { getHeaders } from '/@/utils/common/compUtils';
@@ -202,6 +192,7 @@
   const baseUploadUrl = globSetting.uploadUrl;
   const uploadUrl = `${baseUploadUrl}/sys/common/upload`;
   const headers = getHeaders();
+  var showField = ref('currency+name');
   const formRef = ref();
   const queryParam = reactive<any>({});
   //注册model

+ 3 - 11
src/views/publicComponents/SelectStaningStockModal.vue

@@ -54,16 +54,7 @@
                         </a-col>
                         <a-col :md="6" :sm="8">
                             <a-form-item label="客户(customer)">
-                                <ApiSelect
-                                    :api="CustomerOption"
-                                    showSearch
-                                    v-model:value="queryParams.customer"
-                                    optionFilterProp="label"
-                                    resultField="records"
-                                    labelField="abbreviation"
-                                    valueField="id"
-                                    :params='{pageSize:-1}'
-                                />
+                                <JSelect   v-model:value="queryParams.customer" :get-option-url="CustomerOption" :showField="showField"></JSelect>
                             </a-form-item>
                         </a-col>
                         <a-col :md="6" :sm="8">
@@ -160,13 +151,14 @@
     import { defHttp} from '/@/utils/http/axios';
     import { message } from 'ant-design-vue';
     import { filterObj, getFileAccessHttpUrl } from '/@/utils/common/compUtils';
-    import { JDictSelectTag,ApiSelect,JInput} from '/@/components/Form';
+    import { JDictSelectTag,ApiSelect,JInput,JSelect} from '/@/components/Form';
     import {CustomerOption,ClassList,supplierOption,ProjectOption} from '../inventiry/otherout/otherOutForm.api';
     const emit = defineEmits([ 'SelectStaningStock']); //定义emit
     var visible = ref(false)
     var fatherProject = ref('')
     var fatherWarehouse = ref('')
     var fatherGoodsAllocation = ref('')
+    var showField = ref('currency+name');
     const columns = [
         { 
             type: 'selection',