chenrui 9 kuukautta sitten
vanhempi
commit
6b017c61ea
1 muutettua tiedostoa jossa 4 lisäystä ja 3 poistoa
  1. 4 3
      src/views/easyPassManagement/shoppingManagement/list.vue

+ 4 - 3
src/views/easyPassManagement/shoppingManagement/list.vue

@@ -22,7 +22,7 @@
         bordered>
         <!-- 图片 -->
         <template slot="imgs" slot-scope="text, record">
-          <div class="addType-img">
+          <div class="addType-img" v-if="record.iconUrl">
             <img
               :src="record.iconUrl"
               alt="图片走丢啦"
@@ -31,6 +31,7 @@
               @click="handleImg(record)"
               :id="'shoppingManagementList-img-'+record.id"/>
           </div>
+          <span v-else>--</span>
         </template>
         <!-- 状态 -->
         <template slot="enabledFlag" slot-scope="text, record">
@@ -71,7 +72,7 @@
             type="link"
             class="button-error"
             @click="handleDel(record)"
-            v-if="$hasPermissions('B_delCategory')&&!record.enableFlag"
+            v-if="$hasPermissions('B_delCategory')&&(record.type=='root'&&(record.shopCategoryCount==0&&record.shopProductCount==0))"
             :id="'shoppingManagementList-del-btn'+record.id">删除</a-button>
         </template>
       </a-table>
@@ -113,7 +114,7 @@ export default {
         { title: '图片', scopedSlots: { customRender: 'imgs' }, width: '10%', align: 'center' },
         { title: '易码通优先级', dataIndex: 'sort', width: '10%', align: 'center', customRender: function (text) { return (text || text == 0) ? text : '--' }, ellipsis: true },
         { title: '创建时间', dataIndex: 'createDate', width: '20%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '状态', scopedSlots: { customRender: 'enabledFlag' }, width: '15%', align: 'center' },
+        // { title: '状态', scopedSlots: { customRender: 'enabledFlag' }, width: '15%', align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '23%', align: 'center' }
       ],
       parentData: null, // 父级类目一行数据