yuansh 1 주 전
부모
커밋
81728687d0

+ 5 - 0
src/views/saleCode/salesOrder/SaleOrderForm.data.ts

@@ -99,6 +99,11 @@ export const columns: BasicColumn[] = [
     align:"center",
     dataIndex: 'sourceCode',
    },
+   {
+    title: 'Notified',
+    align:"center",
+    dataIndex: 'notified',
+   },
    {
     title: '状态(status)',
     align:"center",

+ 14 - 0
src/views/saleCode/salesOrder/SaleOrderFormList.vue

@@ -208,6 +208,7 @@
         <!-- <a-button type="primary" @click="cancelClose"> 取消关闭(cancel close)</a-button> -->
         <a-button type="primary" @click="confirm" v-auth="'saleCode:sale_order:confirm'"> 确认(confirm)</a-button>
         <a-button type="primary" @click="cancelConfirm" v-auth="'saleCode:sale_order:cancelConfirm'"> 取消确认(cancel confirm)</a-button>
+		<a-button type="primary" @click="setIsNotified" v-auth="'saleCode:sale_order:setIsNotified'"> Set Notified</a-button>
         <a-dropdown v-if="selectedRowKeys.length > 0">
           <template #overlay>
             <a-menu>
@@ -240,6 +241,7 @@
     <SelectSaleOrderModal ref="SelectSaleOrderModalRef" @copy-product="handleCopyProduct" />
     <SetCloseReasonModal ref="SetCloseReasonModalRef"  @success="successfullyClosed"></SetCloseReasonModal>
     <ViewHistoryVersionModal ref="ViewHistoryVersionModallRef" />
+    <SetIsNotified ref="setIsNotifiedRef" @success="handleSuccess" />
   </div>
 </template>
 
@@ -250,6 +252,7 @@
   import { useModal } from '/@/components/Modal';
   import SaleInquiryFormModal from './components/SaleOrderFormModal.vue';
   import { columns, superQuerySchema } from './SaleOrderForm.data';
+  import SetIsNotified from './components/SetIsNotified.vue';
   import {
     list,
     deleteOne,
@@ -287,6 +290,7 @@
   const SelectSaleOrderModalRef = ref();
   const ViewHistoryVersionModallRef = ref();
   var SetCloseReasonModalRef = ref();
+  const setIsNotifiedRef = ref();
   const queryParam = reactive<any>({});
   //注册model
   const [registerModal, { openModal }] = useModal();
@@ -509,6 +513,16 @@
       SetCloseReasonModalRef.value.getTable(ids)
     }
   }
+  
+  function setIsNotified() {
+    if (selectedRowKeys.value.length == 0) {
+      message.warning('请选择数据');
+    } else {
+      var ids = selectedRowKeys.value.join(',');
+      setIsNotifiedRef.value.getTable(ids);
+    }
+  }
+  
   function successfullyClosed(reason,id){
     var params={
       ids: id,

+ 83 - 0
src/views/saleCode/salesOrder/components/SetIsNotified.vue

@@ -0,0 +1,83 @@
+<template>
+    <a-modal
+      title="Set Notified Date"
+      width="35%"
+      :visible="visible"
+      :maskClosable="false"
+      switchFullscreen
+      @ok = "handleOk"
+      @cancel="handleCancel">
+        <div>
+          <a-card  :body-style="{ padding: '10px' }" :bordered="false" style="margin: 10px;">
+            <div class="table-page-search-wrapper">
+                <a-form :model="form" :label-col="labelCol" :wrapper-col="wrapperCol" >
+                <a-row :gutter="24">
+                    <a-col :md="24" :sm="24">
+                        <a-form-item label="Notified Date">
+                            <a-date-picker v-model:value="form.notified" value-format="YYYY-MM-DD" style="width: 100%;"/>
+                        </a-form-item>
+                    </a-col>
+                </a-row>
+            </a-form>
+           </div>
+        </a-card>
+      </div>
+    </a-modal>
+</template>
+<script lang="ts" setup>
+    import {ref, reactive } from 'vue';
+    import { defHttp } from '/@/utils/http/axios';
+    import { message } from 'ant-design-vue';
+    import { JDictSelectTag} from '/@/components/Form';
+    var visible = ref(false);
+    const emit = defineEmits([ 'success']); //定义emit
+    var form = ref({
+        notified :""
+    });
+    const labelCol = ref({
+        xs: { span: 24 },
+        sm: { span: 5 },
+    });
+    const wrapperCol = ref({
+        xs: { span: 24 },
+        sm: { span: 19 },
+    });
+    var fatherIds=ref("");
+    function handleOk(){
+        let params ={
+            ids:fatherIds.value,
+            notified:form.value.notified
+        }
+        defHttp
+        .get({ url: '/saleCode/saleOrder/notifiedBatch',params}, { isTransformResponse: false })
+        .then((res) => {
+            if (res.success) {
+                emit('success')
+                handleCancel()
+            }else{
+                message.error(res.message);
+            }
+        })
+    }
+    function handleCancel(){
+        visible.value = false;
+        form.value.notified=''
+        fatherIds.value = ''
+    }
+    function getTable(ids){
+        visible.value = true
+        fatherIds.value = ids
+    }
+    defineExpose({
+        getTable
+    });
+</script>
+<style scoped lang="less">
+/deep/.ant-form-item{
+    margin-bottom: 8px !important;
+}
+// /deep/.ant-table-wrapper .ant-table-thead > tr > th, .ant-table-wrapper .ant-table-thead > tr > td{
+//     padding: 8px !important;
+// }
+
+</style>