qinhb hace 3 meses
padre
commit
2fd62cbf5e
Se han modificado 1 ficheros con 4 adiciones y 0 borrados
  1. 4 0
      src/views/base/craftManagement/route/components/groupSort.vue

+ 4 - 0
src/views/base/craftManagement/route/components/groupSort.vue

@@ -8,6 +8,10 @@ const getLineArray = async () => {
   const { data } = await getLineSortList(route.params.id);
   //设置form
   form.value = data;
+  if(form.value){
+    form.value = form.value.slice().sort((a, b) => a.lineTag.localeCompare(b.lineTag));
+    form.value = form.value.slice().sort((a, b) => a.lineTag.length - b.lineTag.length);
+  }
 };
 const reset = () => {
   drawer.value = false;