Ver Fonte

bug fix

刘洋 há 1 ano atrás
pai
commit
0a35bbe7b4

+ 12 - 0
src/assets/icons/icon-batch-delineation.svg

@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+    <title>icon-批量划定</title>
+    <g id="服务单元管理" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
+        <g id="6.1-派单管理" transform="translate(-564, -24)">
+            <g id="icon-批量划定" transform="translate(564, 24)">
+                <rect id="queue-(Background)" opacity="0" transform="translate(8, 8) scale(-1, 1) translate(-8, -8)" x="0" y="0" width="16" height="16"></rect>
+                <path d="M13,2 C13.5522852,2 14,2.44771552 14,3 L14,12 L13,12 L13,3 L4,3 L4,2 Z M4.74279451,6.84669418 L7.61068249,9.71463604 L9.25742292,8.06789799 L9.96452904,8.77500553 L7.61067486,11.1288559 L4.03568077,7.5537941 L4.74279451,6.84669418 Z M3,14 L11,14 C11.5522852,14 12,13.5522861 12,13 L12,5 C12,4.44771624 11.5522852,4 11,4 L3,4 C2.44771659,4 2,4.44771576 2,5 L2,13 C2,13.5522842 2.44771552,14 3,14 Z M3,13 L11,13 L11,5 L3,5 L3,13 Z" fill="#262626" transform="translate(8, 8) scale(-1, 1) translate(-8, -8)"></path>
+            </g>
+        </g>
+    </g>
+</svg>

+ 1 - 1
src/config/constants.js

@@ -82,7 +82,7 @@ export const SERVICE_UNIT_STATUS = {
   NEW: '新建',
   PUBLISH: '已发布',
   FINISH: '已完结',
-  CANCEL: '已作废',
+  // CANCEL: '已作废',
 };
 
 // 项目质量管理 ------->

+ 21 - 21
src/views/password-modify/index.vue

@@ -28,7 +28,7 @@
             type="password"
             clearable
             placeholder="请输入旧密码"
-            size="large"
+            size="medium"
           >
           </t-input>
         </t-form-item>
@@ -39,7 +39,7 @@
             type="password"
             clearable
             placeholder="请输入新密码"
-            size="large"
+            size="medium"
           >
           </t-input>
         </t-form-item>
@@ -49,7 +49,7 @@
             type="password"
             clearable
             placeholder="请再次输入新密码"
-            size="large"
+            size="medium"
           >
           </t-input>
         </t-form-item>
@@ -155,15 +155,17 @@ const submitHandler = () => {
     position: absolute;
   }
   .login-bg {
-    position: absolute;
-    top: 80px;
-    bottom: 80px;
-    left: 0;
-    width: 70%;
-    z-index: 99;
-    background: url(../../assets//imgs/login_bg_grid.png) center center
-      no-repeat;
-    background-size: contain;
+    // position: absolute;
+    // top: 80px;
+    // bottom: 80px;
+    // left: 0;
+    // width: 70%;
+    // z-index: 99;
+    width: 488px;
+    height: 586px;
+    background: url(../../assets/imgs/login_bg_grid.png) center center no-repeat;
+    // background-size: contain;
+    background-size: 100% 100%;
     .login-bg-inner-box {
       img {
         height: 260px;
@@ -184,30 +186,28 @@ const submitHandler = () => {
     }
   }
   .login-box {
-    width: 350px;
-    height: 360px;
+    width: 344px;
     background: #fff;
     box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.08);
     border-radius: 8px;
     border: 1px solid #e5e6eb;
-    padding: 24px;
-    position: absolute;
-    left: 60%;
-    z-index: 101;
+    padding: 32px;
+    position: relative;
     .title1 {
       span {
-        font-size: 20px;
-        font-weight: bold;
+        font-size: 24px;
+        font-weight: 700;
         color: #262626;
         line-height: 32px;
       }
     }
     .title2 {
-      font-size: 14px;
+      font-size: 16px;
       color: #8c8c8c;
       line-height: 24px;
       margin-top: 4px;
       margin-bottom: 28px;
+      font-weight: 400;
     }
   }
 }

+ 3 - 1
src/views/service-unit/dispatch/dispatch-manage/index.vue

@@ -20,7 +20,9 @@
         :disabled="!selectedRowKeys.length"
         @click="handleMultDelineation"
       >
-        <template #icon><FactCheckIcon /></template>批量划定</t-button
+        <template #icon
+          ><svg-icon name="batch-delineation" color="#262626" /></template
+        >批量划定</t-button
       >
     </div>
     <SearchForm :fields="fields" :params="params">

+ 159 - 0
src/views/sop/components/sop-sort-panel/index.vue

@@ -0,0 +1,159 @@
+<template>
+  <t-popup
+    overlayClassName="select-filter"
+    placement="bottom-left"
+    :visible="visible"
+  >
+    <t-button variant="outline" @click="toggleVisible">
+      <template #icon><svg-icon name="sort" color="#262626" /></template>
+      排序</t-button
+    >
+    <template #content>
+      <div class="filter-box">
+        <div class="filter-header">
+          <p>请选择排序字段</p>
+        </div>
+        <div class="filter-body">
+          <div class="filter-list">
+            <div class="filter-item">
+              <div class="filter-field">
+                <t-select
+                  v-model="fieldId"
+                  filterable
+                  clearable
+                  @change="fieldIdChange"
+                >
+                  <t-option
+                    v-for="item in metadataList"
+                    :key="item.fieldId"
+                    :label="item.fieldTitle"
+                    :value="item.fieldId"
+                  />
+                </t-select>
+              </div>
+              <div class="filter-value">
+                <t-radio-group
+                  variant="primary-filled"
+                  v-model="sortMethod"
+                  allowUncheck
+                >
+                  <t-radio-button value="ASC">升序</t-radio-button>
+                  <t-radio-button value="DESC">降序</t-radio-button>
+                </t-radio-group>
+              </div>
+            </div>
+          </div>
+        </div>
+        <div class="filter-footer">
+          <div></div>
+          <t-space :size="10">
+            <t-button theme="default" size="small" @click="toggleVisible"
+              >取消</t-button
+            >
+            <t-button theme="primary" size="small" @click="confirmHandle"
+              >确定</t-button
+            >
+          </t-space>
+        </div>
+      </div>
+    </template>
+  </t-popup>
+</template>
+
+<script setup name="SopSortPanel">
+import { randomCode } from '@/utils/tool';
+import { ref, computed, reactive } from 'vue';
+import { staticMetadata } from '../select-filter/config';
+import { MessagePlugin } from 'tdesign-vue-next';
+
+const emit = defineEmits(['confirm']);
+const props = defineProps({
+  metadata: {
+    type: Array,
+    default() {
+      return [];
+    },
+  },
+});
+const sortMethod = ref('');
+const visible = ref(false);
+const toggleVisible = () => {
+  visible.value = !visible.value;
+};
+const fieldId = ref('');
+const metadataList = computed(() => {
+  return [...props.metadata, ...staticMetadata];
+});
+const fieldIdChange = (fieldId) => {
+  if (!fieldId) {
+    sortMethod.value = undefined;
+  }
+};
+const confirmHandle = () => {
+  let data = sortMethod.value
+    ? [
+        {
+          fieldId: fieldId.value,
+          order: sortMethod.value,
+        },
+      ]
+    : [];
+  emit('confirm', data);
+  toggleVisible();
+};
+</script>
+
+<style lang="less">
+.select-filter {
+  .t-popup__content {
+    padding: 0;
+  }
+}
+</style>
+<style lang="less" scoped>
+.filter-box {
+  width: 400px;
+
+  .filter-header {
+    height: 32px;
+    margin-bottom: 6px;
+    color: @dark-text-color-2;
+    padding: 6px 12px 0;
+  }
+  .filter-body {
+    min-height: 60px;
+    padding: 0 12px 12px;
+  }
+  .filter-list {
+    margin-top: 6px;
+  }
+  .filter-item {
+    font-size: 0;
+
+    &:not(:first-child) {
+      margin-top: 12px;
+    }
+
+    & > div {
+      display: inline-block;
+      vertical-align: top;
+      font-size: 14px;
+
+      &:not(:first-child) {
+        margin-left: 6px;
+      }
+    }
+  }
+  .filter-field {
+    width: 180px;
+  }
+
+  .filter-footer {
+    border-top: 1px solid @light-border-color;
+    padding: 12px;
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
+  }
+}
+</style>

+ 11 - 2
src/views/sop/sop-manage/office-sop/index.vue

@@ -19,10 +19,14 @@
         <template #icon><svg-icon name="refresh" color="#262626" /></template>
         刷新</t-button
       >
-      <t-button variant="outline" @click="handleSort">
+      <!-- <t-button variant="outline" @click="handleSort">
         <template #icon><svg-icon name="sort" color="#262626" /></template>
         排序</t-button
-      >
+      > -->
+      <sop-sort-panel
+        :metadata="formWidgetMetadataViewList"
+        @confirm="sortConfirm"
+      ></sop-sort-panel>
       <t-button
         v-if="appStore.showSubmenu"
         variant="outline"
@@ -215,6 +219,7 @@ import useFetchTable from '@/hooks/useFetchTable';
 import { sopListApi, sopBatchCancelApi } from '@/api/sop';
 import { timestampFilter } from '@/utils/filter';
 import SelectFilter from '../../components/select-filter/index.vue';
+import SopSortPanel from '../../components/sop-sort-panel/index.vue';
 import SelectMetadata from '../../components/select-metadata.vue';
 import SopStepDialog from '../sop-step/sop-step-dialog.vue';
 import QualityIssueDialog from '../quality-issue/quality-issue-dialog.vue';
@@ -304,6 +309,7 @@ const params = reactive({
   serviceId: '',
   formWidgetMetadataViewList: [],
   formWidgetMetadataConditionList: [],
+  formWidgetMetadataOrderList: [],
 });
 const transParams = computed(() => {
   return { ...params, type: 'OFFICE_SOP_FLOW' };
@@ -331,6 +337,9 @@ const filterConfirm = (data) => {
     };
   });
 };
+const sortConfirm = (data) => {
+  params.formWidgetMetadataOrderList = data;
+};
 
 const handleSort = () => {
   // TODO: