3
2
فهرست منبع

宇信公司,附件上传功能

yuedefeng 6 سال پیش
والد
کامیت
418dd55732

+ 4 - 0
src/dashoo.cn/backend/api/controllers/lims/limsdataentry.go

@@ -181,6 +181,7 @@ func (this *LimsDataEntryController) GetToDoList() {
 	conUserBy := this.GetString("conUserBy")
 	CheckStatus := this.GetString("CheckStatus")
 	BalanceTime := this.GetString("BalanceTime")
+	DocId := this.GetString("docid")
 	orderby := "a.Id desc"
 	Order := this.GetString("Order")
 	Prop := this.GetString("Prop")
@@ -204,6 +205,9 @@ func (this *LimsDataEntryController) GetToDoList() {
 	if CheckStatus != "" {
 		where = where + " and a.CheckStatus = '" + CheckStatus + "'"
 	}
+	if DocId != "" {
+		where = where + " and a.DocId = '" + DocId + "'"
+	}
 	if BalanceTime != "" {
 		dates := strings.Split(BalanceTime, ",")
 		if len(dates) == 2 {

BIN
src/dashoo.cn/backend/api/static/limsdoc/dataentry/template/pdf/tmp_1557832618.pdf


BIN
src/dashoo.cn/backend/api/static/limsdoc/dataentry/template/pdf/tmp_1557832620.pdf


+ 22 - 13
src/dashoo.cn/frontend_web/src/components/lims/attachlist.vue

@@ -3,48 +3,57 @@
     <el-tabs tabPosition="left" v-model="activeName"  @tab-click="handleClick">
 
       <el-tab-pane label="上传附件" name="first">
-        <el-table :data="FiletableData" stripe style="width: 100%" class="mytable">
+        <el-upload action="" multiple ref="refuploadattach" :http-request="uploadrequest" :on-success="uploadfile"
+                   :before-upload="beforeAvatarUpload" :show-file-list="false">
+          <el-button size="mini" type="primary">上传附件</el-button>
+        </el-upload>
+        <el-table :data="FiletableData" stripe style="width: 100%" size="mini">
           <el-table-column prop="CreateOn" label="上传日期" width="180">
             <template slot-scope="scope">
                 {{ jstimehandle(scope.row.CreateOn+'') }}
               </template>
           </el-table-column>
-          <el-table-column prop="FileName" label="预览" width="180">
+          <el-table-column prop="FileName" label="文件名" >
             <template slot-scope="scope">
             <a :href="scope.row.FileUrl" target="_blank" class="buttonText">{{scope.row.FileName}}</a>
           </template>
           </el-table-column>
-          <el-table-column prop="address" label="文件地址">
-            <template slot="header" slot-scope="scope">
+          <!--<el-table-column prop="address" label="备注" width="180">
+            &lt;!&ndash;<template slot="header" slot-scope="scope">
               <el-upload action="" multiple ref="refuploadattach" :http-request="uploadrequest" :on-success="uploadfile"
                 :before-upload="beforeAvatarUpload" :show-file-list="false">
                 <el-button size="mini" type="primary">上传附件</el-button>
               </el-upload>
-            </template>
-          </el-table-column>
+            </template>&ndash;&gt;
+          </el-table-column>-->
         </el-table>
       </el-tab-pane>
+
       <el-tab-pane label="问题附件" name="second">
-        <el-table :data="QueFiletableData" stripe style="width: 100%" class="mytable">
+        <el-upload action="" multiple ref="refuploadattach" :http-request="uploadrequest"
+                   :before-upload="beforeAvatarUpload" :on-success="uploadquefile" :show-file-list="false">
+          <el-button size="mini" type="primary">上传问题附件</el-button>
+        </el-upload>
+        <el-table :data="QueFiletableData" stripe style="width: 100%" size="mini">
           <el-table-column prop="CreateOn" label="上传日期" width="180">
             <template slot-scope="scope">
                 {{ jstimehandle(scope.row.CreateOn+'') }}
               </template>
           </el-table-column>
-          <el-table-column prop="FileName" label="预览" width="180">
+          <el-table-column prop="FileName" label="文件名">
              <template slot-scope="scope">
             <a :href="scope.row.FileUrl" target="_blank" class="buttonText">{{scope.row.FileName}}</a>
           </template>
           </el-table-column>
-          <el-table-column prop="address" label="文件地址">
-            <template slot="header" slot-scope="scope">
+          <!--<el-table-column prop="address" label="备注" width="180">
+            &lt;!&ndash;<template slot="header" slot-scope="scope">
               <el-upload action="" multiple ref="refuploadattach" :http-request="uploadrequest"
                 :before-upload="beforeAvatarUpload" :on-success="uploadquefile" :show-file-list="false">
                 <el-button size="mini" type="primary">上传问题附件</el-button>
               </el-upload>
-              <!-- <el-button size="mini" type="primary" @click="openfiledialog('2')">上传问题附件</el-button> -->
-            </template>
-          </el-table-column>
+              &lt;!&ndash; <el-button size="mini" type="primary" @click="openfiledialog('2')">上传问题附件</el-button> &ndash;&gt;
+            </template>&ndash;&gt;
+          </el-table-column>-->
         </el-table>
       </el-tab-pane>
     </el-tabs>

+ 6 - 0
src/dashoo.cn/frontend_web/src/pages/lims/dataentry/tacktodo.vue

@@ -421,6 +421,11 @@
       this.getDetaillist() // 检测明细项下拉
       this.initdata2()
     },
+    watch: {
+      $route(val) {
+        this.initdata2()
+      }
+    },
     methods: {
       // 添加数据录入记录
       adddataentry() {
@@ -482,6 +487,7 @@
         }
         // paginate
         const params = {
+          docid: this.$route.query.docid,
           _currentPage: this.currentPage,
           _size: this.size,
           Order: this.Column.Order,

+ 9 - 1
src/dashoo.cn/frontend_web/src/pages/lims/reportairfoamgenerator/subdata/datamain.vue

@@ -91,6 +91,12 @@
       </el-form>
       <data-history ref="DataoperaCompoment" @init-datalist="initDatalist"></data-history>
     </el-collapse-item>
+    <el-collapse-item name="2">
+      <template slot="title">
+        <i class="el-icon-upload"></i> 附件列表
+      </template>
+      <attach-list :DataEntryId="DataEntryId+''"></attach-list>
+    </el-collapse-item>
   </el-collapse>
 </template>
 <script>
@@ -99,6 +105,7 @@
   import entrustApi from '@/api/lims/limsentrust'
   import DataHistory from './datahistory.vue'
   import {makePy} from '@/utils/initials.js'
+  import AttachList from '@/components/lims/attachlist.vue'
 
   export default {
     computed: {
@@ -107,7 +114,8 @@
       })
     },
     components: {
-      DataHistory
+      DataHistory,
+      AttachList
     },
     name: 'reportairfoamgeneratorDataMain',
     props: {

+ 10 - 0
src/dashoo.cn/frontend_web/src/pages/lims/reportbeampumpingUnits/subdata/dataopera.vue

@@ -343,6 +343,12 @@
       </el-form>
 
     </el-card>
+    <el-card>
+      <template slot="header">
+        <i class="el-icon-upload"></i> 附件列表
+      </template>
+      <attach-list :DataEntryId="formData.DataEntryId+''"></attach-list>
+    </el-card>
     <el-dialog title="提交校核" :visible.sync="ProoFreadShow" top="5vh">
       <el-form :model="shenhesubmitForm" label-width="130px" ref="shenhesubmitForm">
         <el-row>
@@ -391,6 +397,7 @@
   import api from '@/api/lims/reportbeampumpingunits'
   import entrustApi from '@/api/lims/limsentrust'
   import {makePy} from '@/utils/initials.js'
+  import AttachList from '@/components/lims/attachlist.vue'
 
   export default {
     computed: {
@@ -398,6 +405,9 @@
         authUser: 'authUser'
       })
     },
+    components: {
+      AttachList
+    },
     name: 'reportnobeampumpingunitsEdit',
     props: {
       EId: String,

+ 9 - 1
src/dashoo.cn/frontend_web/src/pages/lims/reporthydraulicsafe/subdata/datamain.vue

@@ -130,6 +130,12 @@
       </el-form>
       <data-history ref="DataoperaCompoment" @init-datalist="initDatalist"></data-history>
     </el-collapse-item>
+    <el-collapse-item name="2">
+      <template slot="title">
+        <i class="el-icon-upload"></i> 附件列表
+      </template>
+      <attach-list :DataEntryId="DataEntryId+''"></attach-list>
+    </el-collapse-item>
   </el-collapse>
 </template>
 <script>
@@ -138,6 +144,7 @@
   import entrustApi from '@/api/lims/limsentrust'
   import DataHistory from './datahistory.vue'
   import {makePy} from '@/utils/initials.js'
+  import AttachList from '@/components/lims/attachlist.vue'
 
   export default {
     computed: {
@@ -146,7 +153,8 @@
       })
     },
     components: {
-      DataHistory
+      DataHistory,
+      AttachList
     },
     name: 'reportairfoamgeneratorDataMain',
     props: {

+ 10 - 0
src/dashoo.cn/frontend_web/src/pages/lims/reportnobeampumpingUnits/subdata/dataopera.vue

@@ -346,6 +346,12 @@
       </el-form>
     <!--</el-dialog>-->
     </el-card>
+    <el-card>
+      <template slot="header">
+        <i class="el-icon-upload"></i> 附件列表
+      </template>
+      <attach-list :DataEntryId="formData.DataEntryId+''"></attach-list>
+    </el-card>
     <el-dialog title="提交校核" :visible.sync="ProoFreadShow" top="5vh">
       <el-form :model="shenhesubmitForm" label-width="130px" ref="shenhesubmitForm">
         <el-row>
@@ -394,6 +400,7 @@
   import api from '@/api/lims/reportnobeampumpingUnits'
   import entrustApi from '@/api/lims/limsentrust'
   import {makePy} from '@/utils/initials.js'
+  import AttachList from '@/components/lims/attachlist.vue'
 
   export default {
     computed: {
@@ -401,6 +408,9 @@
         authUser: 'authUser'
       })
     },
+    components: {
+      AttachList
+    },
     name: 'reportnobeampumpingunitEdit',
     props: {
       EId: String,

+ 9 - 1
src/dashoo.cn/frontend_web/src/pages/lims/reportzuhq/subdata/datamain.vue

@@ -130,6 +130,12 @@
       </el-form>
       <data-history ref="DataoperaCompoment" @init-datalist="initDatalist"></data-history>
     </el-collapse-item>
+    <el-collapse-item name="2">
+      <template slot="title">
+        <i class="el-icon-upload"></i> 附件列表
+      </template>
+      <attach-list :DataEntryId="DataEntryId+''"></attach-list>
+    </el-collapse-item>
   </el-collapse>
 </template>
 <script>
@@ -138,6 +144,7 @@
   import entrustApi from '@/api/lims/limsentrust'
   import DataHistory from './datahistory.vue'
   import {makePy} from '@/utils/initials.js'
+  import AttachList from '@/components/lims/attachlist.vue'
 
   export default {
     computed: {
@@ -146,7 +153,8 @@
       })
     },
     components: {
-      DataHistory
+      DataHistory,
+      AttachList
     },
     name: 'reportZuhqDataMain',
     props: {