ソースを参照

fix: 调整按钮位置

zh 2 年 前
コミット
ab40504308

+ 1 - 0
src/components/LogisticsTabs/index.vue

@@ -140,6 +140,7 @@ export default {
         }
       },
       defaultTableAttributes: {
+        height: '100%',
         border: true,
         size: 'mini',
         'summary-method': this.$getSummaries,

+ 23 - 21
src/views/sales_policy/components/details.vue

@@ -505,18 +505,7 @@
                     handelBatchData()
                   }"
                 >批量修改</el-button> -->
-                <template v-if="detail.type === 'LIMIT'">
-                  <el-button
-                    v-if="policyLimitGroupList.length"
-                    type="primary"
-                    size="mini"
-                    @click="()=>{
-                      buyNumvisible = true
-                      handelLimitGroupData()
-                    }"
-                  >批量修改上限</el-button>
-                </template>
-                <template v-else>
+                <template v-if="detail.type !== 'LIMIT'">
 
                   <el-button
                     v-if="list.length"
@@ -625,15 +614,28 @@
                   ex-text="导出经销商配提套数"
                   :ex-params="{ policyId: detail.code }"
                 />
-                <el-button
-                  v-if="policyLimitGroupList.length"
-                  type="primary"
-                  size="mini"
-                  @click="()=>{
-                    limitGroupvisible = true
-                    handelLimitGroupData()
-                  }"
-                >批量修改配提套数上限</el-button>
+                <template v-if="detail.type !== 'LIMIT'">
+                  <el-button
+                    v-if="policyLimitGroupList.length"
+                    type="primary"
+                    size="mini"
+                    @click="()=>{
+                      limitGroupvisible = true
+                      handelLimitGroupData()
+                    }"
+                  >批量修改配提套数上限</el-button>
+                </template>
+                <template v-else>
+                  <el-button
+                    v-if="policyLimitGroupList.length"
+                    type="primary"
+                    size="mini"
+                    @click="()=>{
+                      buyNumvisible = true
+                      handelLimitGroupData()
+                    }"
+                  >批量修改上限</el-button>
+                </template>
                 <!-- <el-button type="primary" size="mini" @click="hanleDownloadFilesPolicyLimitGroupPolicy"
                   >下载模板</el-button
                 > -->

+ 33 - 32
src/views/supply/transferOrder/transferOrderForm.vue

@@ -5,6 +5,7 @@
       <zj-form-module title="调拨单明细" :form-items="detailData" label-width="0" :column="3" />
       <zj-form-module
         v-if="moduleType === 2"
+        style="height: 100%;"
         title="物流费用"
         :form-items="formLogisticsData"
         label-width="0"
@@ -102,6 +103,7 @@ export default {
       },
       itemTableEvents: { 'selection-change': this.itemSelectionChange },
       defaultTableAttributes: {
+
         border: true,
         headerCellClassName: 'headerRowColor',
         size: 'mini',
@@ -305,9 +307,9 @@ export default {
           },
           render: (h, { row, index }) => {
             return (
-              <div style="margin:0 20px">
+              <div style='margin:0 20px'>
                 <el-input
-                  type="number"
+                  type='number'
                   disabled={this.comDisabled}
                   value={row.qty}
                   // onInput={e => (row.qty = e)}
@@ -315,8 +317,8 @@ export default {
                     row.qty = value
                     this.debounceChange(value, index)
                   }}
-                  placeholder="调拨数量"
-                  size="mini"
+                  placeholder='调拨数量'
+                  size='mini'
                 ></el-input>
               </div>
             )
@@ -330,12 +332,12 @@ export default {
           render: (h, { row }) => {
             return (
               <el-input
-                type="text"
+                type='text'
                 value={row.notes}
                 disabled={this.comDisabled}
                 onInput={e => (row.notes = e)}
-                placeholder="备注"
-                size="mini"
+                placeholder='备注'
+                size='mini'
               ></el-input>
             )
           }
@@ -356,8 +358,8 @@ export default {
               <div>
                 {!this.comDisabled ? (
                   <el-button
-                    type="text"
-                    size="default"
+                    type='text'
+                    size='default'
                     onClick={() => {
                       this.handleDel(index)
                     }}
@@ -376,29 +378,29 @@ export default {
         ...[
           !this.comDisabled
             ? {
-                name: 'slot-component',
-                md: 24,
-                attributes: { disabled: false },
-                formItemAttributes: { label: '', prop: '' },
-                render: () => {
-                  return (
-                    <div>
-                      <el-button
-                        size="mini"
-                        onClick={() => {
-                          this.visible = true
-                          this.recordSelected = []
-                        }}
-                      >
+              name: 'slot-component',
+              md: 24,
+              attributes: { disabled: false },
+              formItemAttributes: { label: '', prop: '' },
+              render: () => {
+                return (
+                  <div>
+                    <el-button
+                      size='mini'
+                      onClick={() => {
+                        this.visible = true
+                        this.recordSelected = []
+                      }}
+                    >
                         添加
-                      </el-button>
-                      <el-button size="mini" onClick={() => this.handleAllDel()}>
+                    </el-button>
+                    <el-button size='mini' onClick={() => this.handleAllDel()}>
                         删除
-                      </el-button>
-                    </div>
-                  )
-                }
+                    </el-button>
+                  </div>
+                )
               }
+            }
             : {}
         ],
         {
@@ -869,8 +871,7 @@ export default {
             var { value } = props
             return (
               <zj-table
-                style="height: 600px;"
-                tableAttributes={{ ...this.defaultTableAttributes }}
+                tableAttributes={{ maxHeight: '600px', ...this.defaultTableAttributes }}
                 isDrop={true}
                 columns={this.formLogistics}
                 tableData={this.logisticsData}
@@ -917,7 +918,7 @@ export default {
     }
   },
   methods: {
-    debounceChange: debounce(function (val, index) {
+    debounceChange: debounce(function(val, index) {
       if (val <= 0) {
         this.selectData[index].qty = 1
       } else {