Ver Fonte

Merge branch 'master' of http://139.196.39.194:9021/chenc/sen-yu-new-web

huxy há 1 ano atrás
pai
commit
9d311e2ac8

+ 1 - 1
public/index.html

@@ -4,7 +4,7 @@
     <meta charset="utf-8" />
     <meta http-equiv="X-UA-Compatible" content="IE=edge" />
     <meta name="viewport" content="width=device-width,initial-scale=1.0" />
-    <title>森语</title>
+    <title>马菲羊</title>
     <link rel="icon" href="<%= BASE_URL %>logo1.png" />
     <script src="<%= BASE_URL %>cdn/babel-polyfill/polyfill_7_2_5.js"></script>
     <style>

BIN
src/assets/mfy.png


+ 1 - 1
src/components/layouts/TabLayout.vue

@@ -177,7 +177,7 @@
 
       // update-begin-author:sunjianlei date:20200120 for: 动态更改页面标题
       changeTitle(title) {
-        let projectTitle = "森语"
+        let projectTitle = "马菲羊"
         // 首页特殊处理
         if (this.$route.path === indexKey) {
           document.title = projectTitle

+ 1 - 1
src/components/layouts/UserLayout.vue

@@ -5,7 +5,7 @@
         <div class="header">
           <a href="/">
             <img src="~@/assets/logo-new.png" class="logo" alt="logo">
-            <span class="title">森语</span>
+            <span class="title">马菲羊</span>
           </a>
         </div>
         <!-- <div class="desc">

+ 1 - 1
src/components/page/GlobalFooter.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="footer">
     <div class="links">
-      <a href="http://www.jeecg.com" target="_blank">森语 首页</a>
+      <a href="http://www.jeecg.com" target="_blank">马菲羊 首页</a>
       <a href="https://github.com/zhangdaiscott/jeecg-boot" target="_blank">
         <a-icon type="github"/>
       </a>

+ 2 - 2
src/components/page/GlobalHeader.vue

@@ -17,8 +17,8 @@
         :type="collapsed ? 'menu-unfold' : 'menu-fold'"
         @click="toggle"/>
 
-      <span v-if="device === 'desktop'">欢迎进入森语中后台</span>
-      <span v-else>森语</span>
+      <span v-if="device === 'desktop'">欢迎进马菲羊中后台</span>
+      <span v-else>马菲羊</span>
 
       <user-menu :theme="theme"/>
        <!-- <a href="http://www.myfitt.cn:18086"  target="_top" style="color:white;margin-left: 21px;float: right;">切换OA系统</a> -->

+ 1 - 1
src/components/page/GlobalLayout.vue

@@ -594,7 +594,7 @@
       }
 
       img {
-        height: 50px;
+        height: 106px;
       }
 
       h1 {

+ 4 - 3
src/components/tools/Logo.vue

@@ -3,8 +3,8 @@
     <router-link :to="routerLinkTo">
 
       <!-- update-begin- author:sunjianlei --- date:20190814 --- for: logo颜色根据主题颜色变化 -->
-      <img v-if="navTheme === 'dark'" src="~@/assets/logo-new.png" alt="logo">
-      <img v-else src="~@/assets/logo-new.png" alt="logo">
+      <img v-if="navTheme === 'dark'" src="~@/assets/mfy.png" alt="logo">
+      <img v-else src="~@/assets/mfy.png" alt="logo">
       <!-- update-begin- author:sunjianlei --- date:20190814 --- for: logo颜色根据主题颜色变化 -->
 
       <h1 v-if="showTitle">{{ title }}</h1>
@@ -48,7 +48,8 @@
       line-height: @height !important;
       box-shadow: none !important;
       transition: background 300ms;
-
+      display: flex;
+      align-items: center;
       a {
         color: white;
         &:hover {

+ 47 - 20
src/views/cost-allocation-total/costDetailDrawer.vue

@@ -246,6 +246,14 @@
               </h4>
               </a-form-model-item>
             </a-col>
+            <a-col :md="6" :sm="8" class="noprint">
+              <a-upload  productName="file" :showUploadList="true" :file-list="fileList" :headers="tokenHeader" :multiple="false"   :action="importExcelUrl"   :data="{code:this.detailsPlanNum.planNum,name:this.fileName}"  >
+                <a-button type="primary" disabled>附件上传</a-button>
+              </a-upload>
+            </a-col>
+            <a-col :md="6" :sm="8" class="noprint">
+              <a-button type="primary" @click="openEnclosure">附件</a-button>
+            </a-col>
         </a-form-model>
       </div>
       </a-row>
@@ -328,7 +336,8 @@
        <Csubmit-information ref="CsubmitInformation" @close="closeInformation"></Csubmit-information>
        <!-- 选择指派人员 -->
        <select-user-modal ref="SelectUserModal" @selectFinished="selectFinished"></select-user-modal>
-    </div>
+       <attachment-display ref="attachmentDisplay"></attachment-display>
+      </div>
   </div>
   </a-modal>
 </template>
@@ -352,11 +361,11 @@ import accidentListModal from '@views/cost-allocation-total/modal/accidentListMo
 import SelectUserModal from '@views/cost-allocation-total/modal/SelectUserModal.vue'
 import { USER_AUTH } from "@/store/mutation-types"
 import { seachPlanNum, addHalfInfo,deleteFileDetail,assignedData,cancelSubmit } from '@api/document/cost-allocation-total.js'
-
+import AttachmentDisplay from '@views/reportForms/fabric-loss-table/attachment-display.vue'
 export default {
   name: 'CostAllocationTable', // 成本分配 (新增)
   mixins: [JeecgListMixin],
-  components: { JEllipsis,SelectUserModal,CsubmitInformation, moment, tabs, mainTableExpenseCNYModal, mainTableExpenseUSDModal, accidentListModal },
+  components: { JEllipsis,AttachmentDisplay,SelectUserModal,CsubmitInformation, moment, tabs, mainTableExpenseCNYModal, mainTableExpenseUSDModal, accidentListModal },
 
   data() {
     return {
@@ -504,18 +513,18 @@ export default {
               this.detailsPlanNum.shortseveral = 0
               this.detailsPlanNum.shortvalue = 0
             }
-            // var fileList =  (this.detailsPlanNum.attachs!==''&&this.detailsPlanNum.attachs)?this.detailsPlanNum.attachs.split(","):[]
-            //   this.fileList = []
-            //   if(fileList.length!==0){
-            //     fileList.map(item=>{
-            //       this.fileList.push({
-            //         uid: '-1',
-            //         name: item,
-            //         status: 'done',
-            //         url:'http://www.myfitt.cn:18001/jeecg-boot/sys/common/static' +'/'+item
-            //       })
-            //   })
-            //   }
+            var fileList =  (this.detailsPlanNum.attachs!==''&&this.detailsPlanNum.attachs)?this.detailsPlanNum.attachs.split(","):[]
+              this.fileList = []
+              if(fileList.length!==0){
+                fileList.map(item=>{
+                  this.fileList.push({
+                    uid: '-1',
+                    name: item,
+                    status: 'done',
+                    url:'http://www.myfitt.cn:18001/jeecg-boot/sys/common/static' +'/'+item
+                  })
+              })
+              }
             //调整表头格式
             this.adjustingHeader()
             // this.accidentListData = res.result.syCostAllocationAccidentList //事故单
@@ -649,6 +658,20 @@ export default {
       this.color2 = this.color2>0?this.color2:-this.color2
     },
 
+    openEnclosure(){
+      this.$refs.attachmentDisplay.AttachmentModVis = true
+      var attachList = [];
+      if (this.detailsPlanNum != null && this.detailsPlanNum.accessorItemList != null){
+        this.detailsPlanNum.accessorItemList.forEach(e=>{
+          var attach = {};
+          attach.name = e.filename;
+          attach.src=e.fileurl;
+          attachList.push(attach);
+        });
+      }
+      this.$refs.attachmentDisplay.attachmentData =  attachList;
+    },
+
 
     //判断有无指派人
     determineAssignedPerson(){
@@ -819,7 +842,9 @@ export default {
       priceExcludingtaxAll = 0
       this.$refs.unitTabs.ingData.map(item=>{
           if(item.goodsName!=='合计'){
-            item.usdAmount = ((item.priceExcludingtax?Number(item.priceExcludingtax):0)/this.detailsPlanNum.exchangeRate)
+            if((!item.usdAmount|| item.usdAmount=='')||item.rmbAmount == item.usdAmount){
+              item.usdAmount = ((item.priceExcludingtax?Number(item.priceExcludingtax):0)/Number(this.detailsPlanNum.exchangeRate)).toFixed(2)
+            }
             if(item.rmbAmount !== item.usdAmount){  usdAmountAll+=item.usdAmount?Number(item.usdAmount):0   }
             transferCostAll+=item.transferCostAll?Number(item.transferCost):0
             rmbAmountAll+=item.rmbAmount?Number(item.rmbAmount):0
@@ -936,13 +961,15 @@ export default {
       var usaMoney = 0,
           rmbMoney = 0
       val.map(item=>{
-        if(item.accidentType=='应补' && item.amount!==''&&item.amount&&item.amount!=='0'){
+        if(item.accidentType=='应补' && item.amount!==''&&item.amount&&item.amount!=='0'&&Number(item.amount)>0){
            item.amount=Number(item.amount)*(-1)
-        }else if(item.accidentType=='应补' && item.amountrmb!==''&&item.amountrmb&&item.amountrmb!=='0'){
+        }else if(item.accidentType=='应补' && item.amountrmb!==''&&item.amountrmb&&item.amountrmb!=='0'&&Number(item.amount)>0){
           item.amountrmb = Number(item.amountrmb)*(-1)
         }
-        usaMoney += Number(item.amount),
-        rmbMoney+=Number(item.amountrmb)
+        if(item.accidentUndertaker!=='合计'){
+          usaMoney += Number(item.amount),
+          rmbMoney+=Number(item.amountrmb)
+        }
       })
       this.detailsPlanNum.accidentUsdamount = usaMoney.toFixed(2)
       this.detailsPlanNum.accidentcnyAmount = rmbMoney.toFixed(2)

+ 1 - 1
src/views/cost-allocation-total/fabricLossesSummary.vue

@@ -285,7 +285,7 @@ export default {
   created() {
     this.apply = this.$route.query.apply;
     this.getCostList()
-    document.title = '面料损耗列表'+ ' · ' + '森语'
+    document.title = '面料损耗列表'+ ' · ' + '马菲羊'
   },
   methods: {
    // 分页查询

+ 1 - 1
src/views/cost-allocation-total/inancialReconciliation.vue

@@ -430,7 +430,7 @@ export default {
   async created() {
     await this.defaultData()
     await this.getCostList()
-    document.title = '计划单统计表'+ ' · ' + '森语'
+    document.title = '计划单统计表'+ ' · ' + '马菲羊'
   },
   methods: {
    // 分页查询

+ 18 - 3
src/views/cost-allocation-total/list.vue

@@ -136,11 +136,12 @@
         </span> -->
         <span slot="action" slot-scope="text, record">
           <!-- <a @click="handleApply(record)" v-if="apply == 1 && (record.status=='保存' || record.status=='' || !record.status)">发起申请</a> -->
-          <a @click="detail(record)">详情</a>
+          <a @click="openAppendixList(record)">附件</a>
           <a-divider type="vertical"  />
           <a-dropdown>
           <a class="ant-dropdown-link">更多<a-icon type="down"/></a>
             <a-menu slot="overlay" >
+              <a-menu-item><a @click="detail(record)">详情</a></a-menu-item>
               <a-menu-item><a @click="cancelSumit(record)">取消提交</a></a-menu-item>
               <a-menu-item><a @click="approvalHistory(record)">审批历史</a></a-menu-item>
             </a-menu>
@@ -150,6 +151,7 @@
     </a-card>
   </a-spin>
     <ChistoryModal ref="ChistoryModal"></ChistoryModal>
+    <attachment   ref="attachment"></attachment>
     <!-- 详情 大抽屉 -->
     <costDetail-drawer ref="costDetailDrawer"   @close="getCostList"></costDetail-drawer>
   </div>
@@ -161,6 +163,7 @@ import JEllipsis from '@/components/jeecg/JEllipsis'
 import moment from 'moment'
 import { downFile } from '@/api/manage'
 import costDetailDrawer from '@views/cost-allocation-total/costDetailDrawer.vue'
+import attachment from '@views/cost-allocation-total/modal/attachment.vue'
 import ChistoryModal from '@views/cost-allocation-total/modal/ChistoryModal'
 
 import { costList, itemCheck, cancelItemCheck,cancelSubmit } from '@api/document/cost-allocation-total.js'
@@ -168,7 +171,7 @@ import { costList, itemCheck, cancelItemCheck,cancelSubmit } from '@api/document
 export default {
   name: 'CostAllocationTotal', // 成本分配汇总 单证
   mixins: [JeecgListMixin],
-  components: { JEllipsis, moment, costDetailDrawer,ChistoryModal },
+  components: { JEllipsis, moment,attachment, costDetailDrawer,ChistoryModal },
 
   data() {
     let ellipsis = (v, l = 20) => <j-ellipsis value={v} length={l} />
@@ -260,7 +263,7 @@ export default {
     this.apply = this.$route.query.apply;
     console.log(this.$route.query)
     this.getCostList()
-    document.title = '成本分配列表'+ ' · ' + '森语'
+    document.title = '成本分配列表'+ ' · ' + '马菲羊'
   },
   methods: {
     // 分页查询
@@ -306,6 +309,18 @@ export default {
       // console.log('参数record', this.$refs.costDetailDrawer.record.planNum)
       this.$refs.costDetailDrawer.onSearch(record.planNum)
     },
+    openAppendixList(record){
+      this.$refs.attachment.AttachmentModVis = true
+      var attachmentArr = record.attachs.split(',')
+      var attachList = [];
+      attachmentArr.forEach(item=>{
+        var attach = {};
+          attach.name = item;
+          attach.src=item;
+          attachList.push(attach);
+      })
+      this.$refs.attachment.attachmentData =  attachList;
+    },
     //  审核
     check(record) {
       this.$nextTick(() => {

+ 10 - 6
src/views/reportForms/cost-allocation-table.vue

@@ -453,7 +453,7 @@ export default {
     }
   },
   created() {
-    document.title = '成本分配表'+ ' · ' + '森语'
+    document.title = '成本分配表'+ ' · ' + '马菲羊'
   },
   filters: {
                 //文字数超出时,超出部分使用...
@@ -760,7 +760,9 @@ export default {
       priceExcludingtaxAll = 0
       this.$refs.unitTabs.ingData.map(item=>{
           if(item.goodsName!=='合计'){
-            item.usdAmount = ((item.priceExcludingtax?Number(item.priceExcludingtax):0)/this.detailsPlanNum.exchangeRate)
+            if((!item.usdAmount|| item.usdAmount=='')||item.rmbAmount == item.usdAmount){
+              item.usdAmount = ((item.priceExcludingtax?Number(item.priceExcludingtax):0)/Number(this.detailsPlanNum.exchangeRate)).toFixed(2)
+            }
             if(item.rmbAmount !== item.usdAmount){  usdAmountAll+=item.usdAmount?Number(item.usdAmount):0   }
             transferCostAll+=item.transferCostAll?Number(item.transferCost):0
             rmbAmountAll+=item.rmbAmount?Number(item.rmbAmount):0
@@ -908,13 +910,15 @@ export default {
       var usaMoney = 0,
           rmbMoney = 0
       val.map(item=>{
-        if(item.accidentType=='应补' && item.amount!==''&&item.amount&&item.amount!=='0'){
+        if(item.accidentType=='应补' && item.amount!==''&&item.amount&&item.amount!=='0'&&Number(item.amount)>0){
            item.amount=Number(item.amount)*(-1)
-        }else if(item.accidentType=='应补' && item.amountrmb!==''&&item.amountrmb&&item.amountrmb!=='0'){
+        }else if(item.accidentType=='应补' && item.amountrmb!==''&&item.amountrmb&&item.amountrmb!=='0'&&Number(item.amount)>0){
           item.amountrmb = Number(item.amountrmb)*(-1)
         }
-        usaMoney += Number(item.amount),
-        rmbMoney+=Number(item.amountrmb)
+        if(item.accidentUndertaker!=='合计'){
+          usaMoney += Number(item.amount),
+          rmbMoney+=Number(item.amountrmb)
+        }
       })
       this.detailsPlanNum.accidentUsdamount = usaMoney.toFixed(2)
       this.detailsPlanNum.accidentcnyAmount = rmbMoney.toFixed(2)

+ 4 - 5
src/views/reportForms/cost-allocation-table/tabs.vue

@@ -450,11 +450,10 @@ export default {
           width: '6%',
           className: 'replacecolor',
           customRender: (text, record, index) => {
-            if (record.rmbAmount == record.usdAmount)
-              return "";
-            else
-              return Number(record.usdAmount).toFixed(2);
-           } 
+            if(text!==''&&text){
+              return Number(text).toFixed(2)
+            }
+          },
         },
         {
           title: '不含税金额',

+ 1 - 1
src/views/reportForms/fabric-loss-table.vue

@@ -1490,7 +1490,7 @@ export default {
     // }
   },
   created(){
-    document.title = '面料损耗表'+ ' · ' + '森语'
+    document.title = '面料损耗表'+ ' · ' + '马菲羊'
     var ccode = this.$route.query.ccode;
     /*
     console.log("----------------ccode 1:"+ccode);

+ 1 - 1
src/views/reportForms/pro-progress-report.vue

@@ -283,7 +283,7 @@ export default {
     }
   },
   created() {
-    document.title = '生产进度报表'+ ' · ' + '森语'
+    document.title = '生产进度报表'+ ' · ' + '马菲羊'
     // this.getproProgressList()
   },
   methods: {

+ 1 - 1
src/views/reportForms/supplier-capacity.vue

@@ -281,7 +281,7 @@ export default {
   async created() {
     await this.getOption()
     this.getSupplierList()
-    document.title = '供应商产能维护'+ ' · ' + '森语'
+    document.title = '供应商产能维护'+ ' · ' + '马菲羊'
     
   },
   computed: {},

+ 1 - 1
src/views/reportForms/supply-capacity-table.vue

@@ -257,7 +257,7 @@ export default {
   created() {
     this.getData()
     this.getSupplyCapList() // 渲染 供应链产能报表
-    document.title = '供应商产能报表'+ ' · ' + '森语'
+    document.title = '供应商产能报表'+ ' · ' + '马菲羊'
   },
 
   methods: {

+ 4 - 3
src/views/shipment-details/shipmentList.vue

@@ -184,7 +184,7 @@
       </div>
       
       <!-- 测试 -->
-      <ve-table :columns="columns" :virtual-scroll-option="virtualScrollOption"  :max-height="600" :table-data="shipmentListData" style="width:100%" :border-y="true" :sort-option="sortOption" :scroll-width="1500"  row-key-field-name="itemIds"   :checkbox-option="checkboxOption">
+      <ve-table :columns="columns" :virtual-scroll-option="virtualScrollOption"  :max-height="600" :table-data="shipmentListData" style="width:100%" :border-y="true" :sort-option="sortOption" :scroll-width="2500"  row-key-field-name="itemIds"   :checkbox-option="checkboxOption">
       </ve-table>
       <div v-show="showEmpty" class="empty-data">暂无数据</div>
       <span style="margin-right: 55%;">共勾选{{selectedNumber}}条数</span>
@@ -586,7 +586,7 @@ export default {
           { field: "itemNumber", key: "c", title: "款号", align: "center",width: 130,sortBy: "",ellipsis: {showTitle: true,}, },
           { field: "salesman", key: "d", title: "业务员", align: "center", width: 100,sortBy: "", ellipsis: {showTitle: true,},},
           { field: "distributionPoint", key: "e", title: "分销点", align: "center", width: 110,sortBy: "", ellipsis: {showTitle: true,},},
-          { field: "smallPo", key: "f", title: "小po", align: "center", width: 110,sortBy: "", ellipsis: {showTitle: true,},},
+          { field: "smallPo", key: "f", title: "小po", align: "center", width: 200,sortBy: "", ellipsis: {showTitle: true,},},
           { field: "inventoryName", key: "g", title: "存货名称", align: "center", width: 220,sortBy: "", ellipsis: {showTitle: true,},},
           { field: "declarationName", key: "h", title: "报关品名", align: "center", width: 175,sortBy: "",ellipsis: {showTitle: true,}, },
           { field: "isTc", key: "i", title: "是否TC", align: "center", width: 110,sortBy: "", ellipsis: {showTitle: true,}, renderBodyCell: ({ row, column, rowIndex }, h) => {
@@ -892,7 +892,8 @@ export default {
       if(yesA == 'yes'){
         this.loading = true
         exportXls(obj).then(res =>{
-        if(res.success==false){
+        if(!res){
+          this.loading = false
           this.$message.error(res.message)
         }else{
           downFile('/shippingDetails/syShippingDetails/exportXls',obj).then(data => {