Browse Source

联系我们模块更新

xiaoming_global 5 years ago
parent
commit
eeb4d5cd9d

+ 65 - 0
src/api/site/site.js View File

451
     })
451
     })
452
 }
452
 }
453
 
453
 
454
+
455
+export function addrotationpic(data){
456
+   return request({
457
+       url:"/api/site/addrotationpic",
458
+       method:"Post",
459
+       data:data,
460
+   })
461
+}
462
+
463
+export function GetRotationImages(params){
464
+    return request({
465
+        url:"/api/site/getrotationimages",
466
+        method:"Post",
467
+        params:params
468
+    })
469
+}
470
+
471
+export function addrotationImage(data){
472
+    return request({
473
+        url:"/api/site/addrotationimage",
474
+        method:"Post",
475
+        data:data,
476
+    })
477
+}
478
+
479
+export function AddImageslink(data){
480
+   return request({
481
+       url:"/api/site/addimageslink",
482
+       method:"Post",
483
+       data:data,
484
+   })
485
+}
486
+
487
+export function getEditImages(params){
488
+    return request({
489
+        url:"/api/site/geteditimages",
490
+        method:"Post",
491
+        params:params
492
+    })
493
+}
494
+
495
+export function AddMagicNavi(data){
496
+   return request({
497
+       url:"/api/site/addmagicnavi",
498
+       method:"Post",
499
+       data:data,
500
+   })
501
+}
502
+
503
+export function getMagicImages(params){
504
+   return request({
505
+      url:"/api/site/getmagicimages",
506
+      method:"Post",
507
+      params:params,
508
+   })
509
+}
510
+
511
+export function AddMarginChart(data){
512
+   return request({
513
+      url:"/api/site/addmarginchart",
514
+      method:"Post",
515
+      data:data,
516
+   })
517
+}
518
+

+ 232 - 56
src/scrm_pages/site/components/add-contact.vue View File

35
                 </li>
35
                 </li>
36
             </ul>
36
             </ul>
37
          </div>
37
          </div>
38
-
39
-<!-- 轮播图 -->
40
-<el-dialog
38
+  <!-- 新增轮播图 -->
39
+   <el-dialog
41
     title="新增轮播图"
40
     title="新增轮播图"
42
     :visible.sync="slideshow"
41
     :visible.sync="slideshow"
43
     width="550px"
42
     width="550px"
44
-    >
45
-    <el-form ref="rotationform" :model="rotationform" label-width="90px" :rules="rules" :label-position="labelPosition">
46
-      <el-form-item label="模块标题:" required prop="title">      
47
-        <el-input v-model="rotationform.title" ></el-input>
43
+     center>
44
+    <el-form ref="rotationform" :model="rotationform" label-width="90px" :rules="rules" >
45
+      <el-form-item label="模块标题:" required prop="title">
46
+        <el-input v-model="rotationform.title"></el-input>
48
       </el-form-item>
47
       </el-form-item>
49
       <el-form-item label="排序值:" required prop="sort">
48
       <el-form-item label="排序值:" required prop="sort">
50
         <el-input v-model="rotationform.sort"></el-input>
49
         <el-input v-model="rotationform.sort"></el-input>
51
         <p class="tips">请输入1-99的整数,数值越小,模块排序越靠前</p>
50
         <p class="tips">请输入1-99的整数,数值越小,模块排序越靠前</p>
52
       </el-form-item>
51
       </el-form-item>
53
-      <el-form-item label="添加图片:" v-model="rotationform.rotationImages" required prop="rotationImages">
54
-         <el-upload
55
-          :data="rotationData"
56
-          action="https://upload.qiniup.com"
57
-          list-type="picture-card"
58
-          :on-success="RotationchartSuccess"
59
-         :before-upload="beforeRotationUpload"
60
-         >
61
-        <i slot="default" class="el-icon-plus"></i>
62
-        <div slot="file" slot-scope="{file}">
63
-          <img
64
-           class="el-upload-list__item-thumbnail"
65
-           :src="file.url"
66
-          >
67
-        <span class="el-upload-list__item-actions"> 
68
-         <span
69
-           v-if="!disabled"
70
-           class="el-upload-list__item-delete"
71
-         >
72
-         <i class="el-icon-edit-outline" @click="rotationEditImages('rotationform')"></i>
73
-          </span> 
74
-         <span
75
-           v-if="!disabled"
76
-           class="el-upload-list__item-delete"
77
-         >
78
-          <i class="el-icon-delete"></i>
79
-          </span> 
80
-         </span> 
81
-        </div> 
82
-     </el-upload>
52
+     <el-form-item label="添加图片:" v-model="rotationform.rotationImages">
53
+         <div class="flex-img">
54
+              <div class="el-upload-list el-upload-list--picture-card" >            
55
+                  <div class="el-upload-list__item is-success" v-for="(item,index) in this.rotationdata" :key="item.id">             
56
+                    <img class="flex-img__image" :src="item.images">              
57
+                    <label class="el-upload-list__item-status-label">
58
+                     <i class="el-icon-upload-success el-icon-check"></i>
59
+                    </label>
60
+                     <span class="el-upload-list__item-actions">
61
+                    <span class="el-upload-list__item-delete">
62
+                    <i class="el-icon-edit-outline" @click="editImages(item.id);editcenterDialogVisible = true"></i>
63
+                    <i class="el-icon-delete" @click="deleteDoctor(item.id,index)"></i>
64
+                    </span>
65
+                    </span>
66
+                   </div>         
67
+                </div>     
68
+                <img src="static/images/u679.png" @click="addVisible = true">   
69
+             </div>
70
+              <!-- <div class="addrot">
71
+
72
+              </div> -->
83
       </el-form-item>
73
       </el-form-item>
84
     </el-form>
74
     </el-form>
85
     <span slot="footer" class="dialog-footer">
75
     <span slot="footer" class="dialog-footer">
86
       <el-button @click="slideshow = false">取 消</el-button>
76
       <el-button @click="slideshow = false">取 消</el-button>
87
-      <el-button type="primary" @click="addRotationUpload('rotationform');">确 定</el-button>
77
+      <el-button type="primary" @click="addrotationImage('rotationform')">确 定</el-button>
88
     </span>
78
     </span>
89
   </el-dialog>
79
   </el-dialog>
90
 
80
 
81
+
91
   <!-- 医院地址 -->
82
   <!-- 医院地址 -->
92
   <el-dialog
83
   <el-dialog
93
     title="新增医院地址"
84
     title="新增医院地址"
289
       <el-button type="primary" @click="addRideWay('rideform');">确 定</el-button>
280
       <el-button type="primary" @click="addRideWay('rideform');">确 定</el-button>
290
     </span>
281
     </span>
291
    </el-dialog>
282
    </el-dialog>
283
+
284
+ <!-- 编辑图片 -->
285
+ <el-dialog
286
+     class="avatar-uploader"
287
+     title="编辑图片"
288
+     :visible.sync="addVisible"
289
+     width="35%"
290
+     center>
291
+  <el-form ref="picform" :model="picform" label-width="90px" :rules="rules">
292
+    <el-form-item label="图片编辑:" required prop="Images">
293
+      <el-col :span="5">       
294
+       <el-upload
295
+          :data="Data"        
296
+          action="https://upload.qiniup.com"
297
+          :show-file-list="false"
298
+          :on-success="RotationSuccess"
299
+          :before-upload="RotationUpload">
300
+          <img v-if="picform.Images" :src="picform.Images" class="avatar">
301
+          <i v-else class="el-icon-plus avatar-uploader-icon"></i>
302
+      </el-upload>
303
+      </el-col>
304
+      <el-col :span="19">
305
+          <div class="tpic" v-show="showpic"> 
306
+            <img :src="picform.Images" style="width:200px;height:100px">
307
+          </div>
308
+      </el-col>
309
+    </el-form-item>
310
+    <el-form-item label="排序值:" required prop="sort">
311
+       <el-col :span="24">
312
+         <el-input v-model="picform.sort"></el-input>
313
+       </el-col>   
314
+    </el-form-item>
315
+    <el-form-item label="图片链接:" required prop="piclink">
316
+        <el-radio-group v-model="picform.piclink">
317
+           <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in genderOptions" :key="index" @change="selectGender(gender.id)">{{gender.name}}</el-radio>
318
+        </el-radio-group>
319
+    </el-form-item>
320
+    <el-form-item label="链接地址:" required prop="linkaddress">
321
+      <el-col :span="20">
322
+      <el-input v-model="picform.linkaddress"></el-input>
323
+      </el-col>
324
+      <el-col :span="4">
325
+       <el-button size="medium" @click="addlink()">设置链接</el-button>
326
+      </el-col>
327
+    </el-form-item>
328
+  </el-form>
329
+  <span slot="footer" class="dialog-footer">
330
+    <el-button @click="addVisible = false">取 消</el-button>
331
+    <el-button type="primary" @click="addrotationpic('picform');addVisible = false">确 定</el-button>
332
+  </span>
333
+</el-dialog>
334
+
292
   </div>
335
   </div>
293
 </template>
336
 </template>
294
 
337
 
296
 <script>
339
 <script>
297
  import { getToken } from '@/api/qiniu'
340
  import { getToken } from '@/api/qiniu'
298
  import { getFileExtension} from '@/utils/tools'
341
  import { getFileExtension} from '@/utils/tools'
299
- import { addRotationUpload,addRideWay,addWorkTime,addconnection,queryConnetion,deleteConnecWay,editConnecWay,saveConnecform,addContract} from '@/api/site/site'  
342
+ import { addRotationUpload,addRideWay,addWorkTime,addconnection,queryConnetion,deleteConnecWay,editConnecWay,
343
+ saveConnecform,addContract,addrotationpic,GetRotationImages,addrotationImage} from '@/api/site/site'  
300
 import { truncateSync } from 'fs';
344
 import { truncateSync } from 'fs';
301
 export default {
345
 export default {
302
   name: "addcontact",
346
   name: "addcontact",
303
   data() {
347
   data() {
304
     return {
348
     return {
349
+      show:false,
350
+      imageUrl:false,
305
       dialogshow:false,
351
       dialogshow:false,
306
       slideshow:false,
352
       slideshow:false,
307
       address:false,
353
       address:false,
315
       dialogFormVisibleAdd:true,
361
       dialogFormVisibleAdd:true,
316
       labelPosition: 'left',
362
       labelPosition: 'left',
317
       qiniuDomain: 'https://images.shengws.com/',
363
       qiniuDomain: 'https://images.shengws.com/',
364
+      Data: { token:'',key: '' },
318
       rotationData: { token:'',key: '' },
365
       rotationData: { token:'',key: '' },
319
       new1: require("../../../assets/preview/u481.png"),
366
       new1: require("../../../assets/preview/u481.png"),
320
       new2: require("../../../assets/preview/u493.png"),
367
       new2: require("../../../assets/preview/u493.png"),
332
         sort:"",
379
         sort:"",
333
         rotationImages:[],
380
         rotationImages:[],
334
       },
381
       },
382
+      rotationdata:[],
335
       rideform:{
383
       rideform:{
336
         title:"",
384
         title:"",
337
         sort:"",
385
         sort:"",
373
         rotationImages:[{required:true,message:"请填写添加图片"}],
421
         rotationImages:[{required:true,message:"请填写添加图片"}],
374
         content:[{required:true,message:"请填写乘车方式"}],
422
         content:[{required:true,message:"请填写乘车方式"}],
375
         worktime:[{required:true,message:"请填写工作时间"}],
423
         worktime:[{required:true,message:"请填写工作时间"}],
376
-        connecway:[{required:true,message:"请选择联系方式"}]
424
+        connecway:[{required:true,message:"请选择联系方式"}],
425
+        linkaddress:[{required:true,message:"请填写链接地址"}]
377
       },
426
       },
378
-
427
+     addVisible:false,  
428
+       picform:{
429
+         sort:"",
430
+         Images:"",
431
+         piclink:"",
432
+         linkaddress:"",
433
+      },
434
+      showpic:false,
435
+      genderOptions:[
436
+        {id:1, name:'无'},
437
+        {id:2, name:'自定义'},
438
+       ],
379
     };
439
     };
380
   },
440
   },
381
   methods:{
441
   methods:{
442
+    
382
        //轮播图
443
        //轮播图
383
       RotationchartSuccess(res,file,filelist){         
444
       RotationchartSuccess(res,file,filelist){         
384
          this.rotationform.rotationImages.push(this.qiniuDomain + res.url);  
445
          this.rotationform.rotationImages.push(this.qiniuDomain + res.url);  
414
             })
475
             })
415
           return isJPG && isLt2M;
476
           return isJPG && isLt2M;
416
       },
477
       },
478
+
479
+       RotationSuccess(res,file,filelist){         
480
+         this.picform.Images =this.qiniuDomain + res.url;
481
+         this.showpic = true;
482
+      },
483
+         RotationUpload(file){
484
+             var fileType = file.type
485
+            const isJPG = fileType.indexOf("image") > -1;
486
+            const isLt2M = file.size / 1024 / 1024 < 2;
487
+            if (!isJPG) {
488
+                this.$message.error("只能上传图片");
489
+                return false;
490
+            }
491
+            if (!isLt2M) {
492
+                this.$message.error("图片大小不能超过 2MB!");
493
+                return false;
494
+         }
495
+      
496
+         var date = new Date()
497
+            var ext = getFileExtension(file.name)
498
+            var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
499
+            const _self = this
500
+            return new Promise((resolve, reject) => {
501
+                getToken().then(response => {
502
+                    const token= response.data.data.uptoken
503
+                    console.log("联系我们轮播图token是什么?",token)
504
+                    _self._data.Data.token = token;
505
+                    _self._data.Data.key = key;
506
+                    resolve(true)
507
+                }).catch(err => {
508
+                    reject(false)
509
+                })
510
+            })
511
+          return isJPG && isLt2M;
512
+      },
417
       //添加轮播图
513
       //添加轮播图
418
       addRotationUpload(formName){
514
       addRotationUpload(formName){
419
         this.$refs[formName].validate((valid)=>{
515
         this.$refs[formName].validate((valid)=>{
440
             addconnection(this.connecform).then(response=>{
536
             addconnection(this.connecform).then(response=>{
441
               if(response.data.state==1){
537
               if(response.data.state==1){
442
                  var cooection =  response.data.data.connection;
538
                  var cooection =  response.data.data.connection;
443
-                 console.log("返回数据",cooection);
539
+                //  console.log("返回数据",cooection);
444
                  this.queryConnetion();
540
                  this.queryConnetion();
445
                  this.connecform.title = "";
541
                  this.connecform.title = "";
446
                  this.connecform.content = "";
542
                  this.connecform.content = "";
455
         queryConnetion().then(response=>{
551
         queryConnetion().then(response=>{
456
            if(response.data.state ==1){
552
            if(response.data.state ==1){
457
              this.connectionway = response.data.data.conection;
553
              this.connectionway = response.data.data.conection;
458
-             console.log("联系方式返回数据",this.connectionway);
554
+            //  console.log("联系方式返回数据",this.connectionway);
459
            }
555
            }
460
         })
556
         })
461
       },
557
       },
482
         editConnecWay(id).then(response=>{
578
         editConnecWay(id).then(response=>{
483
             if(response.data.state == 1){
579
             if(response.data.state == 1){
484
               this.editconnecform = response.data.data.connection;
580
               this.editconnecform = response.data.data.connection;
485
-              console.log("返回数据",this.connecform);
581
+              // console.log("返回数据",this.connecform);
486
             }
582
             }
487
         })      
583
         })      
488
       },
584
       },
494
               saveConnecform(this.editconnecform.id,this.editconnecform).then(response=>{
590
               saveConnecform(this.editconnecform.id,this.editconnecform).then(response=>{
495
                   if(response.data.state == 1){
591
                   if(response.data.state == 1){
496
                      var connection =  response.data.data.connection;
592
                      var connection =  response.data.data.connection;
497
-                     console.log("返回数据",connection);
593
+                    //  console.log("返回数据",connection);
498
                       this.editLink =false;
594
                       this.editLink =false;
499
                       this.queryConnetion();
595
                       this.queryConnetion();
500
                   }    
596
                   }    
520
                   if(response.data.state == 1){
616
                   if(response.data.state == 1){
521
                    var connectway = response.data.data.connectway;
617
                    var connectway = response.data.data.connectway;
522
                    var ordmodel = response.data.data.ordmodel;
618
                    var ordmodel = response.data.data.ordmodel;
523
-                   console.log("返回数据",connectway);
524
-                   console.log("返回数据",ordmodel)    
619
+                  //  console.log("返回数据",connectway);
620
+                  //  console.log("返回数据",ordmodel)    
525
                   }
621
                   }
526
               })           
622
               })           
527
             }
623
             }
539
                   if(response.data.state==1){
635
                   if(response.data.state==1){
540
                     var ordmodel = response.data.data.ordmodel;
636
                     var ordmodel = response.data.data.ordmodel;
541
                     var patientWorktime = response.data.data.patientWorktime
637
                     var patientWorktime = response.data.data.patientWorktime
542
-                    console.log("返回数据",ordmodel);
543
-                    console.log("返回数据",patientWorktime)
638
+                    // console.log("返回数据",ordmodel);
639
+                    // console.log("返回数据",patientWorktime)
544
                     this.time = false;
640
                     this.time = false;
545
                 }
641
                 }
546
             })
642
             })
558
             addRideWay(this.rideform).then(response=>{
654
             addRideWay(this.rideform).then(response=>{
559
               if(response.data.state==1){
655
               if(response.data.state==1){
560
                  var rideway = response.data.data.rideway;
656
                  var rideway = response.data.data.rideway;
561
-                 console.log("返回数据",rideway);
657
+                //  console.log("返回数据",rideway);
562
                  var ordemodel = response.data.data.ordemodel;
658
                  var ordemodel = response.data.data.ordemodel;
563
-                 console.log("返回数据",ordemodel)
659
+                //  console.log("返回数据",ordemodel)
564
                  this.type = false;
660
                  this.type = false;
565
               }
661
               }
566
             })
662
             })
569
       },
665
       },
570
       hospitaAddress(){
666
       hospitaAddress(){
571
         this.hostaddress = true;
667
         this.hostaddress = true;
668
+      },
669
+      addrotationpic(formName){
670
+         var sorts = this.picform.sort
671
+         var sort = parseInt(sorts)
672
+         this.picform.sort = sort
673
+       this.$refs[formName].validate((valid)=>{
674
+         if(valid){
675
+            addrotationpic(this.picform).then(response=>{
676
+               if(response.data.state ==1){
677
+                 var conrotation  = response.data.data.conrotation;
678
+                //  console.log("返回数据",conrotation)
679
+               }
680
+            })
681
+         }
682
+       })  
683
+      },
684
+      GetRotationImages(){
685
+        GetRotationImages(this.picform.id).then(response=>{
686
+           if(response.data.state == 1){
687
+             var conrotations =   response.data.data.conrotations
688
+             this.rotationdata =   response.data.data.conrotations
689
+            
690
+           }
691
+        })
692
+      },
693
+      addrotationImage(formName){
694
+        var sorts =  this.rotationform.sort;
695
+        var sort = parseInt(sorts);
696
+        this.rotationform.sort = sort;
697
+        for (let index = 0; index < this.rotationdata.length; index++) {
698
+          this.rotationform.rotationImages.push(this.rotationdata[index].images);       
699
+        }
700
+        this.$refs[formName].validate((valid)=>{
701
+          if(valid){
702
+            addrotationImage(this.rotationform).then(response=>{
703
+                 if(response.data.state == 1){
704
+                   var oldrotation  = response.data.data.oldrotation;
705
+                   this.slideshow = false;
706
+                 
707
+                 } 
708
+            })
709
+          }
710
+        })
572
       }
711
       }
573
   },
712
   },
574
        mounted(){
713
        mounted(){
622
         
761
         
623
         created(){
762
         created(){
624
           this.queryConnetion();
763
           this.queryConnetion();
764
+          this.GetRotationImages();
625
         },
765
         },
626
 
766
 
627
-          updated(){
767
+       updated(){
628
           this.$nextTick(function () {
768
           this.$nextTick(function () {
629
                 var th = this
769
                 var th = this
630
                 // 创建Map实例
770
                 // 创建Map实例
685
         margin-top: 20px;
825
         margin-top: 20px;
686
       //  border:1px solid green;
826
       //  border:1px solid green;
687
     }
827
     }
688
-.tips {
689
-  font-size: 12px;
690
-  line-height: 18px;
691
-}
828
+  .tips {
829
+    font-size: 12px;
830
+    line-height: 18px;
831
+   }
692
 .used {
832
 .used {
693
   ul {
833
   ul {
694
     li {
834
     li {
710
       }
850
       }
711
     }
851
     }
712
   }
852
   }
853
+  
854
+   .avatar-uploader{
855
+      border: 1px dashed #d9d9d9;
856
+      border-radius: 6px;
857
+      cursor: pointer;
858
+      position: relative;
859
+      overflow: hidden;
860
+      width: 100px;
861
+      height: 100px;
862
+     }
863
+  .avatar-uploader{
864
+    border-color: #409EFF;
865
+  }
866
+  .avatar-uploader-icon {
867
+    font-size: 14px;
868
+    color: #8c939d;
869
+    width: 50px;
870
+    height: 50px;
871
+    line-height: 50px;
872
+    margin-left: 25px;
873
+    margin-top: 25px;
874
+    text-align: center;
875
+  }
876
+
877
+   .tpic{
878
+     width:200px;
879
+     height:200px;
880
+     border:solid 1px red;
881
+   }
882
+
883
+  //  .addrot{
884
+  //    width: 146px;
885
+  //    height: 146px;
886
+  //    border: dashed 1px red;
887
+  //  }
888
+  
713
 }
889
 }
714
 </style>
890
 </style>

+ 19 - 31
src/scrm_pages/site/components/contact-us.vue View File

1
 <template>
1
 <template>
2
     <div>
2
     <div>
3
-        <!-- <div class="us">
4
-          <img src="static/images/d.jpg">
5
-        </div>
6
-        <div class="hosname">
7
-           <span>北京大学深圳医院</span>
8
-        </div>
9
-        <div class="hosaddress">
10
-            地址:广东省深圳市福田莲花路1120号北京大学深圳医院三楼
11
-        </div>
12
-        <div class="hosphone">
13
-           总部电话:0755-83923333
14
-        </div>
15
-        <div class="hosphone">
16
-            预约电话:0755-83923333
17
-        </div>
18
-        <div class="hosphone">
19
-            微信号:13318464642
20
-        </div>
21
-        <div class="hosphone">
22
-            办公时间:周一至周五,上午8:00-12:00,下午2:00-5:00.其他时间请联系医院值班电话
23
-        </div>
24
-        <div class="hostake">
25
-            乘车指南:11路空调; 12路空调; 14路; 59路空调; 71路空调; 79路; 104路空调; 209路空调; 213路空调; 323路空调; 365路空调;m358路空调;n13路空调;n6路空调; 购物线
26
-        </div> -->
27
-        <!-- :class="sstt[index]" -->
28
         <div  v-for="item in this.ordmodel" :key="item.id">
3
         <div  v-for="item in this.ordmodel" :key="item.id">
29
            <div>
4
            <div>
30
               <div v-if="item.mode_type == 1">
5
               <div v-if="item.mode_type == 1">
31
-                 <div class="rotation">
32
-
6
+                 <div class="modefive">
7
+                     <img src="static/images/a.jpg" style="width:315px;height:200px">
33
                  </div>
8
                  </div>
34
               </div>
9
               </div>
35
                 <div class="modelone" v-if="item.mode_type == 2">
10
                 <div class="modelone" v-if="item.mode_type == 2">
36
                  <div>
11
                  <div>
37
-
12
+                    
38
                  </div>
13
                  </div>
39
               </div>
14
               </div>
40
               <div  v-if="item.mode_type == 3">
15
               <div  v-if="item.mode_type == 3">
41
                  <div class="modeone">
16
                  <div class="modeone">
42
-                   <span>{{item.title}}:13318464642</span><br>
43
-                   <span>{{item.title}}:13318464642</span><br>
44
-                   <span>{{item.title}}:13318464642</span><br>
17
+                   <span>{{item.title}}:&nbsp;&nbsp;13318464642</span><br>
18
+                   <span>{{item.title}}:&nbsp;&nbsp;13318464642</span><br>
19
+                   <span>{{item.title}}:&nbsp;&nbsp;13318464642</span><br>
45
                   </div>
20
                   </div>
46
               </div>
21
               </div>
47
                <div class="modetwo" v-if="item.mode_type == 4">
22
                <div class="modetwo" v-if="item.mode_type == 4">
77
                  if(response.data.state == 1){
52
                  if(response.data.state == 1){
78
                   var ordmodel = response.data.data.ordmodel;
53
                   var ordmodel = response.data.data.ordmodel;
79
                   this.ordmodel = response.data.data.ordmodel;
54
                   this.ordmodel = response.data.data.ordmodel;
55
+        
56
+                  for (let index = 0; index < this.ordmodel.length; index++) {
57
+                    var images = this.ordmodel[index].Oldration.rotation_images;     
58
+                    console.log("images是什么?",images)              
59
+                  }
60
+                  console.log(images)
80
                   console.log("马文强",ordmodel)
61
                   console.log("马文强",ordmodel)
81
                  }
62
                  }
82
              })
63
              })
178
     margin-bottom: 10px;
159
     margin-bottom: 10px;
179
   }
160
   }
180
 
161
 
162
+  .modefive{
163
+    width:315px;
164
+    height: 200px;
165
+    /* border: solid 1px red; */
166
+    margin-bottom: 5px;
167
+  }
168
+
181
   .rotation{
169
   .rotation{
182
     width: 320px;
170
     width: 320px;
183
     height: 220px;
171
     height: 220px;

+ 0 - 109
src/scrm_pages/site/components/doctor-introduction.vue View File

1
-<template>
2
-    <div class="wq5">                         
3
-       <img src="static\images\u.png" style="width:5px;height:20px;">                           
4
-        <div class="kefont"><span >名医介绍</span></div>
5
-        <div class="more" @click="more()">查看更多</div>
6
-        <div class="logo"><img src="static\images\u216.png"></div>
7
-        <div class="famdoc" v-for="item in doctorInfos" :key="item.id">
8
-        <div class="dochead">
9
-        <img :src="item.dochead" style="width:100px;height:100px">
10
-        </div>
11
-        <div class="docname">
12
-        <span  class="zzcontent">{{item.docname}}</span>
13
-         </div>
14
-        <div class="docintroduction"><span  class="zzcontent" v-html="item.docintroduction"></span></div>
15
-       </div>
16
-    </div>  
17
-</template>
18
-
19
-<script>
20
-    export default {
21
-        name: "doctor-introduction",
22
-        data(){
23
-           return{
24
-              doctorInfos:[],  
25
-           } 
26
-        },
27
-        methods:{}
28
-    }
29
-</script>
30
-
31
-<style scoped>
32
-    .wq5{
33
-        width: 320px;
34
-        height: 290px;
35
-        /* background-color: rgba(242, 242, 242, 1); */
36
-        color: #ffffff;
37
-        /* border: solid 1px black; */
38
-     }
39
-    
40
-     .kefont{
41
-       font-size: 14px;
42
-       color: red;
43
-       margin-left: 8px;
44
-       margin-top: -20px;
45
-    }
46
-
47
-    .more{
48
-       position: absolute;
49
-       font-size: 14px;
50
-       color:black;
51
-       margin-left: 220px;
52
-       margin-top: -22px;
53
-     }
54
-
55
-    .logo{
56
-       position: absolute;
57
-       margin-left: 280px;
58
-       margin-top: -22px;
59
-     }
60
-     .content{
61
-       position: absolute;
62
-       font-size: 14px;
63
-       color: black;
64
-     }
65
-
66
-     
67
-     .famdoc{
68
-       position: relative;
69
-       width: 320px;
70
-       height: 130px;
71
-       background-color: rgba(242, 242, 242, 1);
72
-     }
73
-
74
-     .dochead{
75
-       width:100px;
76
-       height: 100px;
77
-     /* //  border:solid 1px green; */
78
-       margin-top: 10px;
79
-       margin-left: 10px;
80
-     }
81
-
82
-     .docname{
83
-       position: absolute;
84
-       width:50px;
85
-       height: 20px;
86
-      /* // border: solid 1px green; */
87
-       margin-left: 130px;
88
-       margin-top: -90px;
89
-       font-size: 14px;
90
-       color:black;
91
-     }
92
-    .zzcontent{
93
-     overflow: hidden;
94
-     text-overflow: ellipsis;
95
-     display: -webkit-box;
96
-     -webkit-line-clamp: 3;
97
-     -webkit-box-orient: vertical   
98
-   }   
99
-     .docintroduction{
100
-       position: absolute;
101
-       width: 150px;
102
-       height: 50px;
103
-      /* // border: solid 1px green; */
104
-       margin-left: 130px;
105
-       margin-top: -60px;
106
-       font-size: 14px;
107
-       color: black;
108
-     }
109
-</style>

+ 0 - 99
src/scrm_pages/site/components/hospital-introduction.vue View File

1
-<template>
2
-    <div class="wq3">                         
3
-      <img src="static\images\u.png" style="width:5px;height:20px;">                           
4
-      <div class="kefont"><span >医院介绍</span></div>
5
-      <div class="more" @click="more()">查看更多</div>
6
-      <div class="logo"><img src="static\images\u216.png"></div>
7
-      <div class="content">
8
-        <span v-html="hispitalform.introduction" id="content" class="yycontent"></span>
9
-       </div>    
10
-    </div>
11
-</template>
12
-
13
-<script>
14
-     import { GetHospitalInfo } from '@/api/site/site'
15
-    export default {
16
-        name: "hospital-introduction",
17
-        data(){
18
-          return{
19
-            hispitalform:{
20
-             title:"",
21
-             sort:"",
22
-             introduction:"",
23
-            },
24
-          }
25
-        },
26
-        methods:{
27
-             //获取医院介绍
28
-            GetHospitalInfo(){
29
-              GetHospitalInfo().then(response=>{
30
-               if(response.data.state == 1){
31
-                var hospital =  response.data.data.hospital;
32
-               this.hispitalform =  response.data.data.hospital;
33
-             // console.log("获取医院介绍数据",hospital);
34
-             }
35
-           })
36
-          },
37
-        },
38
-        created(){
39
-           this.GetHospitalInfo(); 
40
-        },
41
-         updated(){
42
-            let obj = document.getElementById('content');
43
-            console.log("obj是什么",obj)
44
-            let imgs =  obj.getElementsByTagName('img');
45
-            console.log("imgs",imgs)
46
-            for(let i=0;i<imgs.length;i++){
47
-            imgs[i].style.width = '332px';
48
-            imgs[i].style.height = '100px';
49
-         }
50
-       }
51
-    }
52
-</script>
53
-
54
-<style scoped>
55
-   
56
-     .wq3{
57
-        width: 320px;
58
-        height: 230px;
59
-        background-color: white;
60
-        color: #ffffff;
61
-      /* border: solid 1px black; */
62
-        margin-bottom: 0px;
63
-     }
64
-
65
-    .kefont{
66
-       font-size: 14px;
67
-       color: red;
68
-       margin-left: 8px;
69
-       margin-top: -20px;
70
-     }
71
-
72
-     .more{
73
-       position: absolute;
74
-       font-size: 14px;
75
-       color:black;
76
-       margin-left: 220px;
77
-       margin-top: -22px;
78
-     }
79
-
80
-    .logo{
81
-       position: absolute;
82
-       margin-left: 280px;
83
-       margin-top: -22px;
84
-     }
85
-
86
-      .content{
87
-       position: absolute;
88
-       font-size: 14px;
89
-       color: black;
90
-     }
91
-
92
-     .yycontent{
93
-     overflow: hidden;
94
-     text-overflow: ellipsis;
95
-     display: -webkit-box;
96
-     -webkit-line-clamp: 6;
97
-     -webkit-box-orient: vertical   
98
-   }
99
-</style>

+ 342 - 212
src/scrm_pages/site/components/new-feature.vue View File

57
   <el-dialog
57
   <el-dialog
58
     title="新增轮播图"
58
     title="新增轮播图"
59
     :visible.sync="dialogVisible"
59
     :visible.sync="dialogVisible"
60
-    width="550px"
61
-    :before-close="handleClose">
60
+    width="35%"
61
+    :before-close="handleClose"
62
+    center>
62
     <el-form ref="rotationform" :model="rotationform" label-width="90px" :rules="rules" >
63
     <el-form ref="rotationform" :model="rotationform" label-width="90px" :rules="rules" >
63
       <el-form-item label="模块标题:" required prop="title">
64
       <el-form-item label="模块标题:" required prop="title">
64
         <el-input v-model="rotationform.title"></el-input>
65
         <el-input v-model="rotationform.title"></el-input>
67
         <el-input v-model="rotationform.sort"></el-input>
68
         <el-input v-model="rotationform.sort"></el-input>
68
         <p class="tips">请输入1-99的整数,数值越小,模块排序越靠前</p>
69
         <p class="tips">请输入1-99的整数,数值越小,模块排序越靠前</p>
69
       </el-form-item>
70
       </el-form-item>
70
-      <el-form-item label="添加图片:" v-model="rotationform.rotationImages" required prop="rotationImages">
71
-        <div>
72
-        </div>
73
-         <el-upload
74
-          :data="rotationData"
75
-          action="https://upload.qiniup.com"
76
-          list-type="picture-card"
77
-         :on-success="RotationchartSuccess"
78
-         :before-upload="beforeRotationUpload"
79
-         v-show="show">
80
-        <i slot="default" class="el-icon-plus"></i>
81
-        <div slot="file" slot-scope="{file}">
82
-          <img
83
-           class="el-upload-list__item-thumbnail"
84
-           :src="file.url"
85
-          >
86
-        <span class="el-upload-list__item-actions"> 
87
-         <span
88
-           v-if="!disabled"
89
-           class="el-upload-list__item-delete"
90
-         >
91
-         <i class="el-icon-edit-outline" @click="rotationEditImages()"></i>
92
-          </span> 
93
-         <span
94
-           v-if="!disabled"
95
-           class="el-upload-list__item-delete"
96
-         >
97
-          <i class="el-icon-delete"></i>
98
-          </span> 
99
-         </span> 
100
-        </div> 
101
-     </el-upload>
102
-      <img  src="static/images/u679.png" @click="addpic()">
71
+        <el-form-item label="添加图片:" v-model="rotationform.rotationImages">
72
+         <div class="flex-img">
73
+              <div class="el-upload-list el-upload-list--picture-card" >            
74
+                  <div class="el-upload-list__item is-success" v-for="(item,index) in this.rotationdata" :key="item.id">             
75
+                    <img class="flex-img__image" :src="item.images">              
76
+                    <label class="el-upload-list__item-status-label">
77
+                     <i class="el-icon-upload-success el-icon-check"></i>
78
+                    </label>
79
+                     <span class="el-upload-list__item-actions">
80
+                    <span class="el-upload-list__item-delete">
81
+                    <i class="el-icon-edit-outline" @click="editImages(item.id);editcenterDialogVisible = true"></i>
82
+                    <i class="el-icon-delete" @click="deleteDoctor(item.id,index)"></i>
83
+                    </span>
84
+                    </span>
85
+                   </div>         
86
+                </div>     
87
+                <div class="addrot" @click="addpicVisible = true">
88
+                   <div class="addrotone">
89
+                     <i class="el-icon-plus"></i>
90
+                   </div>  
91
+                   <div class="addrotwo">
92
+                     <span>新增图片</span>
93
+                   </div>
94
+                </div>
95
+             </div>
103
       </el-form-item>
96
       </el-form-item>
104
-       
105
-       <span class="uploadfont">图片已上传0张,最多上传9张图片</span>
97
+       <!-- <span class="uploadfont">图片已上传0张,最多上传9张图片</span> -->
106
     </el-form>
98
     </el-form>
107
     <span slot="footer" class="dialog-footer">
99
     <span slot="footer" class="dialog-footer">
108
       <el-button @click="dialogVisible = false">取 消</el-button>
100
       <el-button @click="dialogVisible = false">取 消</el-button>
114
    <el-dialog
106
    <el-dialog
115
      title="编辑图片"
107
      title="编辑图片"
116
      :visible.sync="addpicVisible"
108
      :visible.sync="addpicVisible"
117
-     width="30%"
118
-    >
119
-  <el-form ref="picform" :model="picform" label-width="90px">
120
-    <el-form-item label="图片编辑:">
109
+     width="35%"
110
+     center>
111
+  <el-form ref="picform" :model="picform" label-width="90px" :rules="rules">
112
+    <el-form-item label="图片编辑:" required prop="imageUrl">
121
       <el-col :span="5">
113
       <el-col :span="5">
122
        <el-upload
114
        <el-upload
123
-         :data="rotationData"
115
+         :data="imageData"
124
          class="avatar-uploader"
116
          class="avatar-uploader"
125
          action="https://upload.qiniup.com"
117
          action="https://upload.qiniup.com"
126
         :show-file-list="false"
118
         :show-file-list="false"
127
-         :on-success="RotationchartSuccess"
128
-        :before-upload="beforeRotationUpload">
129
-        <img v-if="imageUrl" :src="imageUrl" class="avatar">
119
+         :on-success="rotationSuccess"
120
+        :before-upload="rotationUpload">
121
+        <img v-if="picform.imageUrl" :src="picform.imageUrl" class="avatar">
130
        <i v-else class="el-icon-plus avatar-uploader-icon"></i>
122
        <i v-else class="el-icon-plus avatar-uploader-icon"></i>
131
       </el-upload>
123
       </el-upload>
132
       </el-col>
124
       </el-col>
133
-      <el-col :span="19">
125
+      <!-- <el-col :span="19">
134
           <div class="tpic"> 
126
           <div class="tpic"> 
135
-            <img src="static/images/a.jpg">
127
+            <img src="static/images/a.jpg" style="width:250px;height:150px">
136
           </div>
128
           </div>
137
-      </el-col>
129
+      </el-col> -->
138
     </el-form-item>
130
     </el-form-item>
139
-    <el-form-item label="排序值:">
131
+    <el-form-item label="排序值:" required prop="sort">
140
        <el-col :span="24">
132
        <el-col :span="24">
141
-         <el-input></el-input>
133
+         <el-input v-model="picform.sort" style="width:410px"></el-input>
142
        </el-col>   
134
        </el-col>   
143
     </el-form-item>
135
     </el-form-item>
144
-    <el-form-item label="图片链接:">
145
-      <el-radio v-model="radio" label="1">无</el-radio>
146
-      <el-radio v-model="radio" label="2">自定义</el-radio> 
136
+    <el-form-item label="图片链接:" required prop="imagelink">
137
+        <el-radio-group v-model="picform.imagelink">
138
+          <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in genderOptions" :key="index" @change="select(gender.id)">{{gender.name}}</el-radio>
139
+        </el-radio-group>
147
     </el-form-item>
140
     </el-form-item>
148
-    <el-form-item label="链接地址:">
149
-      <el-col :span="20">
150
-      <el-input></el-input>
141
+    <el-form-item label="链接地址:" required prop="linkaddress">
142
+      <el-col :span="15">
143
+      <el-input v-model="picform.linkaddress" v-show="selectone" style="width:300px"></el-input>
151
       </el-col>
144
       </el-col>
152
       <el-col :span="4">
145
       <el-col :span="4">
153
-       <el-button size="medium" @click="addlink()">设置链接</el-button>
146
+       <el-button size="medium" @click="addlink()" v-show="selectone">设置链接</el-button>
154
       </el-col>
147
       </el-col>
155
     </el-form-item>
148
     </el-form-item>
156
   </el-form>
149
   </el-form>
157
   <span slot="footer" class="dialog-footer">
150
   <span slot="footer" class="dialog-footer">
158
     <el-button @click="addpicVisible = false">取 消</el-button>
151
     <el-button @click="addpicVisible = false">取 消</el-button>
159
-    <el-button type="primary" @click="addpicVisible = false">确 定</el-button>
152
+    <el-button type="primary" @click="AddImageslink('picform');addpicVisible = false">确 定</el-button>
160
   </span>
153
   </span>
161
 </el-dialog>
154
 </el-dialog>
162
   
155
   
192
          </el-select>
185
          </el-select>
193
        </el-form-item>
186
        </el-form-item>
194
        <el-form-item >
187
        <el-form-item >
195
-        <el-input style="width: 300px"  placeholder="请输入您需要搜索的内容"></el-input>
196
-          <el-button type="primary"  icon="el-icon-search">搜索</el-button>
197
        </el-form-item>
188
        </el-form-item>
198
        <el-form-item label="自定义地址:">
189
        <el-form-item label="自定义地址:">
199
-          <el-input></el-input>
190
+          <el-input style="width:350px"></el-input>
200
        </el-form-item>
191
        </el-form-item>
201
      </el-form>
192
      </el-form>
202
     <span slot="footer" class="dialog-footer">
193
     <span slot="footer" class="dialog-footer">
296
             </div>         
287
             </div>         
297
         </div>        
288
         </div>        
298
     </div>
289
     </div>
299
-      <img src="static/images/u646.png" @click="centerDialogVisible = true">
290
+      <!-- <img src="static/images/u646.png" @click="centerDialogVisible = true"> -->
291
+      <div class="doc" @click="centerDialogVisible = true">
292
+         <div class="docone">
293
+         <li class="el-icon-plus"></li>  
294
+         </div>
295
+         <div class="doctwo">
296
+            <span>新增名医</span>
297
+         </div>
298
+      </div>
300
       </el-form-item>
299
       </el-form-item>
301
     </el-form>
300
     </el-form>
302
     <span slot="footer" class="dialog-footer">
301
     <span slot="footer" class="dialog-footer">
548
     </span>
547
     </span>
549
   </el-dialog>
548
   </el-dialog>
550
   <!-- 新增魔方导航 -->
549
   <!-- 新增魔方导航 -->
551
-
552
     <el-dialog
550
     <el-dialog
553
     title="新增魔方导航"
551
     title="新增魔方导航"
554
     :visible.sync="eight"
552
     :visible.sync="eight"
555
-    width="550px">
553
+    width="550px"
554
+    center>
556
     <el-form ref="marginform" :model="marginform" label-width="90px" :rules="rules" >
555
     <el-form ref="marginform" :model="marginform" label-width="90px" :rules="rules" >
557
       <el-form-item label="模块标题:" required prop="title">
556
       <el-form-item label="模块标题:" required prop="title">
558
         <el-input v-model="marginform.title"></el-input>
557
         <el-input v-model="marginform.title"></el-input>
561
         <el-input v-model="marginform.sort"></el-input>
560
         <el-input v-model="marginform.sort"></el-input>
562
         <p class="tips">请输入1-99的整数,数值越小,模块排序越靠前</p>
561
         <p class="tips">请输入1-99的整数,数值越小,模块排序越靠前</p>
563
       </el-form-item>
562
       </el-form-item>
564
-      <el-form-item label="添加图片:" v-model="marginform.marginImages" required prop="marginImages">
565
-        <div>
566
-        </div>
567
-         <el-upload
568
-          :data="rotationData"
569
-          action="https://upload.qiniup.com"
570
-          list-type="picture-card"
571
-         :on-success="RotationchartSuccess"
572
-         :before-upload="beforeRotationUpload"
573
-         v-show="show">
574
-        <i slot="default" class="el-icon-plus"></i>
575
-        <div slot="file" slot-scope="{file}">
576
-          <img
577
-           class="el-upload-list__item-thumbnail"
578
-           :src="file.url"
579
-          >
580
-        <span class="el-upload-list__item-actions"> 
581
-         <span
582
-           v-if="!disabled"
583
-           class="el-upload-list__item-delete"
584
-         >
585
-         <i class="el-icon-edit-outline" @click="rotationEditImages()"></i>
586
-          </span> 
587
-         <span
588
-           v-if="!disabled"
589
-           class="el-upload-list__item-delete"
590
-         >
591
-          <i class="el-icon-delete"></i>
592
-          </span> 
593
-         </span> 
594
-        </div> 
595
-     </el-upload>
596
-      <img  src="static/images/u999.png" @click="addmagin()">
563
+       <el-form-item label="添加图片:" v-model="marginform.marginImages" required prop="marginImages">
564
+         <div class="flex-img">
565
+              <div class="el-upload-list el-upload-list--picture-card" v-for="item in margindata" :key="item.id">            
566
+                  <div class="el-upload-list__item is-success">             
567
+                    <img class="flex-img__image" :src="item.margimage">              
568
+                    <label class="el-upload-list__item-status-label">
569
+                     <i class="el-icon-upload-success el-icon-check"></i>
570
+                    </label>
571
+                     <span class="el-upload-list__item-actions">
572
+                    <span class="el-upload-list__item-delete">
573
+                    <i class="el-icon-edit-outline" @click="editImages(item.id);editcenterDialogVisible = true"></i>
574
+                    <i class="el-icon-delete" @click="deleteDoctor(item.id,index)"></i>
575
+                    </span>
576
+                    </span>
577
+                   </div>         
578
+                </div>     
579
+                <div class="upic" @click="MagicNavigation = true">
580
+                  <div class="icon">
581
+                     <i class="el-icon-plus"></i>
582
+                  </div>
583
+                  <div class="ufont">
584
+                      <span>新增导航</span>
585
+                  </div>
586
+                </div>
587
+         </div>
597
       </el-form-item>
588
       </el-form-item>
598
     </el-form>
589
     </el-form>
599
     <span slot="footer" class="dialog-footer">
590
     <span slot="footer" class="dialog-footer">
600
       <el-button @click="eight = false">取 消</el-button>
591
       <el-button @click="eight = false">取 消</el-button>
601
-      <el-button type="primary" @click="AddRotationChart('rotationform')">确 定</el-button>
592
+      <el-button type="primary" @click="AddMarginChart('marginform');">确 定</el-button>
602
     </span>
593
     </span>
603
   </el-dialog>
594
   </el-dialog>
604
  
595
  
606
    <el-dialog
597
    <el-dialog
607
      title="编辑魔法导航"
598
      title="编辑魔法导航"
608
      :visible.sync="MagicNavigation"
599
      :visible.sync="MagicNavigation"
609
-     width="40%"
600
+     width="35%"
610
      center>
601
      center>
611
      <el-form  label-width="90px"  ref="editmarginform" :model="editmarginform" :rules="rules">
602
      <el-form  label-width="90px"  ref="editmarginform" :model="editmarginform" :rules="rules">
612
-       <el-form-item label="导航标题:" prop="title">
603
+       <el-form-item label="导航标题:" required prop="margtitle">
613
          <el-input style="width:400px" v-model="editmarginform.margtitle"></el-input>
604
          <el-input style="width:400px" v-model="editmarginform.margtitle"></el-input>
614
        </el-form-item>
605
        </el-form-item>
615
-       <el-form-item label="导航图标:" prop="margimage">
606
+       <el-form-item label="导航图标:" required prop="margImage" >
616
        <el-upload
607
        <el-upload
617
          class="avatar-uploader"
608
          class="avatar-uploader"
618
           :data="magicData"
609
           :data="magicData"
624
          <i v-else class="el-icon-plus avatar-uploader-icon"></i>
615
          <i v-else class="el-icon-plus avatar-uploader-icon"></i>
625
        </el-upload>
616
        </el-upload>
626
        </el-form-item>
617
        </el-form-item>
627
-       <el-form-item label="跳转设置">
628
-         <el-radio-group v-model="form.gender">
618
+       <el-form-item label="跳转设置" required prop="jumpset">
619
+         <el-radio-group v-model="editmarginform.jumpset">
629
             <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in genderOptions" :key="index" @change="selectGender(gender.id)">{{gender.name}}</el-radio>
620
             <el-radio :label="gender.id" :value="gender.id" v-for="(gender, index) in genderOptions" :key="index" @change="selectGender(gender.id)">{{gender.name}}</el-radio>
630
           </el-radio-group>
621
           </el-radio-group>
631
        </el-form-item>
622
        </el-form-item>
632
        <el-form-item>
623
        <el-form-item>
633
-         <el-col :span="12" v-mode="editmarginform.marginaddress">
634
-          <el-input style="width:300px" v-show="define"></el-input>
624
+         <el-col :span="15">
625
+           <el-input style="width:300px" v-model="editmarginform.marginaddress" v-show="define"></el-input>
635
         </el-col>
626
         </el-col>
636
         <el-col :span="4">
627
         <el-col :span="4">
637
          <el-button size="medium" @click="setlink()" v-show="define">设置链接</el-button>
628
          <el-button size="medium" @click="setlink()" v-show="define">设置链接</el-button>
640
      </el-form>
631
      </el-form>
641
     <span slot="footer" class="dialog-footer">
632
     <span slot="footer" class="dialog-footer">
642
     <el-button @click="MagicNavigation = false">取 消</el-button>
633
     <el-button @click="MagicNavigation = false">取 消</el-button>
643
-    <el-button type="primary" @click="MagicNavigation = false">确 定</el-button>
634
+    <el-button type="primary" @click="AddMagicNavi('editmarginform');MagicNavigation = false">确 定</el-button>
644
   </span>
635
   </span>
645
 </el-dialog> 
636
 </el-dialog> 
646
 
637
 
693
 </template>
684
 </template>
694
 
685
 
695
 <script>
686
 <script>
696
-   import { AddRotationChart, saveHispital,addOffices,AddDoctor,AddDoctorInfo,AddOfficeEnvironment,getQueryDocInfo,change,getQueryDoCHead,editDoctor,saveDocInfo,deleteDoctor } from '@/api/site/site'  
687
+   import { AddRotationChart, saveHispital,addOffices,AddDoctor,AddDoctorInfo,AddOfficeEnvironment,getQueryDocInfo,change,
688
+   getQueryDoCHead,editDoctor,saveDocInfo,deleteDoctor,AddImageslink,getEditImages,AddMagicNavi,getMagicImages,AddMarginChart} from '@/api/site/site'  
697
    import { getToken } from '@/api/qiniu'
689
    import { getToken } from '@/api/qiniu'
698
    import { getFileExtension} from '@/utils/tools'
690
    import { getFileExtension} from '@/utils/tools'
699
    import { isIP } from 'net';
691
    import { isIP } from 'net';
704
    import 'quill/dist/quill.bubble.css'
696
    import 'quill/dist/quill.bubble.css'
705
    import { constants } from 'crypto';
697
    import { constants } from 'crypto';
706
 import { fail } from 'assert';
698
 import { fail } from 'assert';
699
+import { get } from 'http';
707
 export default {
700
 export default {
708
   name: "newfeature",
701
   name: "newfeature",
709
   components:{
702
   components:{
741
        definetwo:false,
734
        definetwo:false,
742
        definethree:false,
735
        definethree:false,
743
        definefour:false,
736
        definefour:false,
737
+       selectone:true,
744
        docnames:[],
738
        docnames:[],
745
        radio: '1',
739
        radio: '1',
746
        radiotwo:'2',
740
        radiotwo:'2',
795
       rotationData: { token:'',key: '' },
789
       rotationData: { token:'',key: '' },
796
       magicData:{ token:'',key:''},
790
       magicData:{ token:'',key:''},
797
       keData: { token: '' ,key: ''},
791
       keData: { token: '' ,key: ''},
792
+      imageData: { token:'',key: ''},
798
       file: this.image ? this.image : '',
793
       file: this.image ? this.image : '',
799
       hideShow:false,
794
       hideShow:false,
800
       show:false,
795
       show:false,
801
       centerDialogVisible:false,
796
       centerDialogVisible:false,
797
+      rotationdata:[],
798
+      margindata:[],
802
       filelist:[],
799
       filelist:[],
803
       radio:3,
800
       radio:3,
804
       form: {
801
       form: {
855
         margtitle:"",
852
         margtitle:"",
856
         margImage:"",
853
         margImage:"",
857
         marginaddress:"",
854
         marginaddress:"",
855
+        jumpset:"",
858
       },
856
       },
859
       keform:{
857
       keform:{
860
         title:"",
858
         title:"",
862
         keImages:[],
860
         keImages:[],
863
       },
861
       },
864
       picform:{
862
       picform:{
865
-
863
+        imageUrl:"",
864
+        sort:"",
865
+        imagelink:"",
866
+        linkaddress:"",
866
       },
867
       },
867
 
868
 
868
        rules: {
869
        rules: {
881
          rotationImages:[{required:true,message:"请填写添加图片"}],
882
          rotationImages:[{required:true,message:"请填写添加图片"}],
882
          keimages:[{required:true,message:"请填写新增科室环境"}],
883
          keimages:[{required:true,message:"请填写新增科室环境"}],
883
          user_title:[{required:true,message:"请填写医生职称"}],
884
          user_title:[{required:true,message:"请填写医生职称"}],
884
-         docimages:[{required:true,message:"请填写新增名医"}]
885
+         docimages:[{required:true,message:"请填写新增名医"}],
886
+         linkaddress:[{required:true,message:"请填写链接地址"}],
887
+         imageUrl:[{required:true,message:"请填写图片编辑"}],
888
+         margtitle:[{required:true,message:"请填写导航标题"}]
885
       },
889
       },
886
     };
890
     };
887
   },
891
   },
888
   // 医院介绍模块
892
   // 医院介绍模块
889
   methods:{  
893
   methods:{  
890
-    
891
-      addpic(){
892
-       this.addpicVisible = true;
893
-      },
894
-      addmagin(){
895
-        this.MagicNavigation = true
896
-      },
897
       addlink(){
894
       addlink(){
898
         this.linkVisible = true;
895
         this.linkVisible = true;
899
       },
896
       },
916
         this.doctorform.docimages.push(this.qiniuDomain + res.url)
913
         this.doctorform.docimages.push(this.qiniuDomain + res.url)
917
       },
914
       },
918
       beforeUpload(file) {   
915
       beforeUpload(file) {   
919
-        const isJPG = file.type === 'image/jpeg';
916
+        var fileType = file.type
917
+        const isJPG = fileType.indexOf("image") > -1;
920
         const isLt2M = file.size / 1024 / 1024 < 2;
918
         const isLt2M = file.size / 1024 / 1024 < 2;
921
         if (!isJPG) {
919
         if (!isJPG) {
922
-          this.$message.error('上传头像图片只能是 JPG 格式!');
920
+          this.$message.error("只能上传图片");
921
+           return false;
922
+          }
923
+         if (!isLt2M) {
924
+           this.$message.error("图片大小不能超过 2MB!");
925
+           return false;
923
          }
926
          }
924
-        if (!isLt2M) {
925
-          this.$message.error('上传头像图片大小不能超过 2MB!');
926
-        }
927
            var date = new Date()
927
            var date = new Date()
928
             var ext = getFileExtension(file.name)
928
             var ext = getFileExtension(file.name)
929
             var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
929
             var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
945
             })
945
             })
946
 
946
 
947
         },
947
         },
948
+
949
+        rotationSuccess(res,file){
950
+          this.picform.imageUrl = this.qiniuDomain + res.url;
951
+        },
952
+
953
+        rotationUpload(file){
954
+            var fileType = file.type
955
+            const isJPG = fileType.indexOf("image") > -1;
956
+            const isLt2M = file.size / 1024 / 1024 < 2;
957
+            if (!isJPG) {
958
+                this.$message.error("只能上传图片");
959
+                return false;
960
+            }
961
+            if (!isLt2M) {
962
+                this.$message.error("图片大小不能超过 2MB!");
963
+                return false;
964
+         }
965
+           var date = new Date()
966
+            var ext = getFileExtension(file.name)
967
+            var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
968
+            this.uploading = true;
969
+            this.loadingText = '封面图片上传中'
970
+
971
+            const _self = this
972
+            return new Promise((resolve, reject) => {
973
+                getToken().then(response => {
974
+                    const tokentree = response.data.data.uptoken
975
+                    console.log("token是什么?",tokentree)
976
+                    _self._data.imageData.token = tokentree;
977
+                    _self._data.imageData.key = key;
978
+                    resolve(true)
979
+                }).catch(err => {
980
+                    reject(false)
981
+                    this.uploading = false;
982
+                })
983
+            })   
984
+        },
948
         handleRemove() {
985
         handleRemove() {
949
             this.file = '';
986
             this.file = '';
950
       },
987
       },
1036
          console.log("轮播图地址",this.rotationform.rotationImages); 
1073
          console.log("轮播图地址",this.rotationform.rotationImages); 
1037
       },
1074
       },
1038
       beforeRotationUpload(file){
1075
       beforeRotationUpload(file){
1039
-           console.log("尺寸",file.size)
1040
-        const isJPG = file.type === 'image/jpeg';
1041
-        const isLt2M = file.size / 1024 / 1024 < 2;
1042
-       
1043
-        if (!isJPG) {
1044
-          this.$message.error('上传头像图片只能是 JPG 格式!');
1045
-        }
1046
-        if (!isLt2M) {
1047
-          this.$message.error('上传头像图片大小不能超过 2MB!');
1048
-        }
1049
-      
1076
+          var fileType = file.type
1077
+          const isJPG = fileType.indexOf("image") > -1;
1078
+          const isLt2M = file.size / 1024 / 1024 < 2;
1079
+          if (!isJPG) {
1080
+             this.$message.error("只能上传图片");
1081
+            return false;
1082
+          }
1083
+          if (!isLt2M) {
1084
+            this.$message.error("图片大小不能超过 2MB!");
1085
+             return false;
1086
+         }
1087
+
1050
          var date = new Date()
1088
          var date = new Date()
1051
             var ext = getFileExtension(file.name)
1089
             var ext = getFileExtension(file.name)
1052
             var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
1090
             var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
1074
       },
1112
       },
1075
 
1113
 
1076
       MagicUpload(file){
1114
       MagicUpload(file){
1077
-         const isJPG = file.type === 'image/jpeg';
1078
-        const isLt2M = file.size / 1024 / 1024 < 2;
1079
-       
1080
-        if (!isJPG) {
1081
-          this.$message.error('上传头像图片只能是 JPG 格式!');
1082
-        }
1083
-        if (!isLt2M) {
1084
-          this.$message.error('上传头像图片大小不能超过 2MB!');
1085
-        }
1115
+            var fileType = file.type
1116
+            const isJPG = fileType.indexOf("image") > -1;
1117
+            const isLt2M = file.size / 1024 / 1024 < 2;
1118
+            if (!isJPG) {
1119
+                this.$message.error("只能上传图片");
1120
+                return false;
1121
+            }
1122
+            if (!isLt2M) {
1123
+                this.$message.error("图片大小不能超过 2MB!");
1124
+                return false;
1125
+         }
1086
       
1126
       
1087
          var date = new Date()
1127
          var date = new Date()
1088
             var ext = getFileExtension(file.name)
1128
             var ext = getFileExtension(file.name)
1105
 
1145
 
1106
       //新增轮播图
1146
       //新增轮播图
1107
       AddRotationChart(formName){
1147
       AddRotationChart(formName){
1148
+            var sorts =  this.rotationform.sort;
1149
+            var sort = parseInt(sorts);
1150
+            this.rotationform.sort = sort;
1151
+            for (let index = 0; index < this.rotationdata.length; index++) {
1152
+            this.rotationform.rotationImages.push(this.rotationdata[index].images);       
1153
+          }
1108
           this.$refs[formName].validate((valid)=>{
1154
           this.$refs[formName].validate((valid)=>{
1109
             if(valid){
1155
             if(valid){
1110
               AddRotationChart(this.rotationform).then(response=>{
1156
               AddRotationChart(this.rotationform).then(response=>{
1276
          console.log("图片数组",this.keform.keImages)
1322
          console.log("图片数组",this.keform.keImages)
1277
       },
1323
       },
1278
       beforekeUpload(file){
1324
       beforekeUpload(file){
1279
-        const isJPG = file.type === 'image/jpeg';
1280
-        const isLt2M = file.size / 1024 / 1024 < 2;
1281
-        console.log("图片尺寸",file.size)
1282
-        if (!isJPG) {
1283
-          this.$message.error('上传头像图片只能是 JPG 格式!');
1284
-         }
1285
-        if (!isLt2M) {
1286
-          this.$message.error('上传头像图片大小不能超过 2MB!');
1287
-        }
1325
+            var fileType = file.type
1326
+            const isJPG = fileType.indexOf("image") > -1;
1327
+            const isLt2M = file.size / 1024 / 1024 < 2;
1328
+            if (!isJPG) {
1329
+                this.$message.error("只能上传图片");
1330
+                return false;
1331
+            }
1332
+            if (!isLt2M) {
1333
+                this.$message.error("图片大小不能超过 2MB!");
1334
+                return false;
1335
+            }
1336
+
1288
            var date = new Date()
1337
            var date = new Date()
1289
             var ext = getFileExtension(file.name)
1338
             var ext = getFileExtension(file.name)
1290
             var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
1339
             var key = date.getFullYear() + (date.getMonth() + 1) + date.getDate() + date.getHours()  + date.getMinutes()  + date.getSeconds()  +'_o_' + file.uid + '.' + ext;
1319
            }
1368
            }
1320
          })
1369
          })
1321
       },
1370
       },
1322
-      add(){
1323
-     
1324
-      },
1325
      selectGender(id){
1371
      selectGender(id){
1326
         if(id == 1){
1372
         if(id == 1){
1327
           this.define = true;
1373
           this.define = true;
1354
          this.definetwo = false;
1400
          this.definetwo = false;
1355
          this.definethree = false;
1401
          this.definethree = false;
1356
        }
1402
        }
1357
-     }
1403
+     },
1404
+     select(id){
1405
+        if(id == 1){
1406
+          this.selectone = true;
1407
+        }
1408
+
1409
+        if(id == 2){
1410
+          this.selectone = false;
1411
+        }
1412
+     },
1413
+
1414
+     AddImageslink(formName){
1415
+          var sorts = this.picform.sort
1416
+          var sort = parseInt(sorts)
1417
+          this.picform.sort = sort
1418
+          console.log("hhhe",this.picform.sort)
1419
+        this.$refs[formName].validate((valid)=>{
1420
+          if(valid){
1421
+             AddImageslink(this.picform).then(response=>{
1422
+                if(response.data.state ==1){
1423
+                  var editpiclink = response.data.data.editpiclink;
1424
+                  console.log("数据返回",editpiclink)
1425
+                }
1426
+             })
1427
+          }
1428
+        })
1429
+     },
1430
+     getEditImages(){
1431
+       getEditImages().then(response=>{
1432
+         if(response.data.state == 1){
1433
+          var editpiclinks = response.data.data.editpiclinks;
1434
+          this.rotationdata = response.data.data.editpiclinks;
1435
+          console.log("好嗨哦",editpiclinks)
1436
+         }
1437
+       })
1438
+     },
1439
+
1440
+     AddMagicNavi(formName){
1441
+        this.$refs[formName].validate((valid)=>{
1442
+          if(valid){
1443
+            AddMagicNavi(this.editmarginform).then(response=>{
1444
+              if(response.data.state == 1){
1445
+               var editmargin  = response.data.data.editmargin;
1446
+               
1447
+              }
1448
+            })
1449
+          }
1450
+        }) 
1451
+     },
1452
+
1453
+     getMagicImages(){
1454
+       getMagicImages().then(response=>{
1455
+           if(response.data.state == 1){
1456
+             var editmargins = response.data.data.editmargins;
1457
+             this.margindata = response.data.data.editmargins;
1458
+             
1459
+             console.log("这个是什么",editmargins);
1460
+           }
1461
+       })
1462
+     },
1463
+       AddMarginChart(formName){
1464
+         var sorts = this.marginform.sort
1465
+          var sort = parseInt(sorts)
1466
+          this.marginform.sort = sort
1467
+          for (let index = 0; index < this.margindata.length; index++) {
1468
+            this.marginform.marginImages.push(this.margindata[index].margimage);          
1469
+          }
1470
+      this.$refs[formName].validate((valid)=>{
1471
+        if(valid){
1472
+          AddMarginChart(this.marginform).then(response=>{
1473
+             if(response.data.state ==1){
1474
+              var macnavigation = response.data.data.macnavigation;
1475
+              this.eight = false;
1476
+              console.log("数据",macnavigation)
1477
+             }
1478
+          })
1479
+        }
1480
+      })
1481
+  },
1358
   },  
1482
   },  
1359
    created(){
1483
    created(){
1360
      this.getQueryDocInfo();
1484
      this.getQueryDocInfo();
1361
      this.getQueryDoCHead();  
1485
      this.getQueryDoCHead();  
1486
+     this.getEditImages();
1487
+     this.getMagicImages();
1362
    },
1488
    },
1363
  };
1489
  };
1364
 </script>
1490
 </script>
1437
     margin-left: 25px;
1563
     margin-left: 25px;
1438
     margin-top: 25px;
1564
     margin-top: 25px;
1439
     text-align: center;
1565
     text-align: center;
1440
-  }
1441
-  
1442
-</style>
1443
-<style  /deep/scoped>
1444
-     .disabled {
1445
-        display: none;
1446
-    }
1566
+  }  
1447
 
1567
 
1448
-    .el-upload--picture-card {
1449
-        height: auto
1450
-    }
1451
-
1452
-    .el-upload-list--picture-card .el-upload-list__item {
1453
-        height: auto;
1454
-    }
1455
-
1456
-    .el-upload-list--picture-card .el-upload-list__item {
1457
-        overflow: hidden;
1458
-        background-color: #fff;
1459
-        border: 1px solid #c0ccda;
1460
-        border-radius: 6px;
1461
-        -webkit-box-sizing: border-box;
1462
-        box-sizing: border-box;
1463
-        width: 148px;
1464
-        height: auto;
1465
-        margin: 0 8px 8px 0;
1466
-        display: inline-block;
1467
-    }
1468
-
1469
-    .el-upload-list__item.is-success .el-upload-list__item-status-label {
1470
-        display: block;
1471
-        position: absolute;
1472
-        right: -15px;
1473
-        top: -6px;
1474
-        width: 40px;
1475
-        height: 24px;
1476
-        background: #13ce66;
1477
-        text-align: center;
1478
-        -webkit-transform: rotate(45deg);
1479
-        transform: rotate(45deg);
1480
-        -webkit-box-shadow: 0 0 1pc 1px rgba(0, 0, 0, 0.2);
1481
-        box-shadow: 0 0 1pc 1px rgba(0, 0, 0, 0.2);
1482
-    }
1483
-
1484
-    .el-upload-list--picture-card .el-upload-list__item-actions {
1485
-        position: absolute;
1486
-        width: 100%;
1487
-        height: 100%;
1488
-        left: 0;
1489
-        top: 0;
1490
-        cursor: default;
1491
-        text-align: center;
1492
-        color: #fff;
1493
-        opacity: 0;
1494
-        font-size: 20px;
1495
-        background-color: rgba(0, 0, 0, 0.5);
1496
-        -webkit-transition: opacity .3s;
1497
-        transition: opacity .3s;
1498
-    }
1568
+  .upic{
1569
+    width: 146px;
1570
+    height:146px;
1571
+    border: dashed 1px #409EFF;
1572
+    background-color: white;
1573
+    font-size: 40px;
1574
+  }
1575
+  .icon{
1576
+    width: 40px;
1577
+    height: 40px;
1578
+    // border: solid 1px red;
1579
+    margin-left: 60px;
1580
+    margin-top: 50px;
1581
+  }
1582
+  .ufont{
1583
+    width:80px;
1584
+    height: 28px;
1585
+    // border:solid 1px red;
1586
+    margin-left: 55px;
1587
+    font-size: 14px;
1588
+  }
1499
 
1589
 
1590
+  .addrot{
1591
+    width:146px;
1592
+    height: 146px;
1593
+    border: dashed 1px #409EFF;
1594
+    margin-left: 10px;
1595
+    background-color: white;
1596
+  }
1597
+  .addrotone{
1598
+    font-size: 50px;
1599
+    width:50px;
1600
+    height: 50px;
1601
+    // border: solid 1px red;
1602
+    margin-left: 50px;
1603
+    margin-top: 50px;
1604
+  }
1605
+  .addrotwo{
1606
+    width:60px;
1607
+    height: 30px;
1608
+    // border: dashed 1px #409EFF;
1609
+    margin-left: 50px;
1610
+  }
1500
 
1611
 
1612
+  .doc{
1613
+    width: 146px;
1614
+    height:146px;
1615
+    border: dashed 1px #409EFF;
1616
+  }
1501
 
1617
 
1618
+  .docone{
1619
+    width: 50px;
1620
+    height: 50px;
1621
+    // border: solid 1px red;
1622
+    margin-top: 50px;
1623
+    margin-left: 50px;
1624
+    font-size: 50px;
1625
+  }
1626
+  .doctwo{
1627
+    width: 60px;
1628
+    height: 30px;
1629
+    margin-left: 50px;
1630
+    // border: solid 1px red;
1631
+  }
1502
 </style>
1632
 </style>
1503
 
1633
 

+ 0 - 98
src/scrm_pages/site/components/office-environment.vue View File

1
-<template>
2
-     <div class="wq6">
3
-        <img src="static\images\u.png" style="width:5px;height;20px;">
4
-        <div class="kefont"><span >科室环境</span></div>
5
-        <div class="more" @click="more()">查看更多</div>
6
-        <div class="logo"><img src="static\images\u216.png"></div>                                
7
-        <div class="swiper-container" id="swiper2">
8
-         <div class="swiper-wrapper" id="wrapper2">
9
-          <div class="swiper-slide" v-for="item in keEnvironmentImages" :key="item.id">
10
-           <img :src="item" style="width:150px;height:125px;border-radius:5px;"/>
11
-          </div>
12
-         </div>
13
-        </div>
14
-    </div>
15
-</template>
16
-
17
-<script>
18
-    import { GetOffEnvironment } from '@/api/site/site'
19
-    export default {
20
-        name: "office-environment",
21
-        data(){
22
-           return{
23
-             keEnvironmentImages:[],
24
-           }
25
-        },
26
-        methods:{
27
-         //获取科室环境
28
-          GetOffEnvironment(){
29
-             GetOffEnvironment().then(response=>{
30
-             if(response.data.state == 1){
31
-              var offenvironment = response.data.data.offenvironment;
32
-              console.log("获取科室环境",offenvironment);
33
-              console.log("获取轮播图片",offenvironment.keimages);
34
-              var str = offenvironment.keimages;
35
-              var Images = [];
36
-              Images = str.split(",");
37
-              console.log("数组",Images);
38
-             this.keEnvironmentImages =  Images;
39
-            }
40
-          });
41
-         },
42
-        },
43
-        created(){
44
-           this.GetOffEnvironment();
45
-        },
46
-        mounted(){
47
-            var mySwiper = new Swiper('#swiper2', {
48
-                direction:"horizontal",
49
-                loop: true, // 循环播放,
50
-                spaceBetween:1,
51
-                loopAdditionalSlides:10,
52
-                slidesPerView: 'auto', // 设置slider容器能够同时显示的slides数量
53
-                centeredSlides: true, // active slide 居中
54
-                observer:true,//动态加载图片
55
-                observeParents:true,
56
-                pagination: {
57
-                    el: '.swiper-pagination',
58
-                },
59
-            });
60
-        },
61
-        
62
-    }
63
-</script>
64
-
65
-<style scoped>
66
-   .wq6{
67
-    width: 320px;
68
-    height: 165px;
69
- /* // background-color: red; */
70
-    color: #ffffff;
71
- /* // border: solid 1px black; */
72
-    margin-bottom: 0px;
73
-  }
74
-   #wrapper2{
75
-     width: 50%;
76
-   }
77
-   .kefont{
78
-      font-size: 14px;
79
-       color: red;
80
-       margin-left: 8px;
81
-       margin-top: -20px;
82
-    }
83
-
84
-     .more{
85
-       position: absolute;
86
-       font-size: 14px;
87
-       color:black;
88
-       margin-left: 220px;
89
-       margin-top: -22px;
90
-     }
91
-
92
-     
93
-    .logo{
94
-       position: absolute;
95
-       margin-left: 280px;
96
-       margin-top: -22px;
97
-     }
98
-</style>

+ 0 - 97
src/scrm_pages/site/components/office-introduction.vue View File

1
-<template>
2
-     <div class="wq4">                         
3
-        <img src="static\images\u.png" style="width:5px;height:20px;">                           
4
-        <div class="kefont"><span >{{officeform.title}}</span></div>
5
-         <div class="more" @click="kemore()">查看更多</div>
6
-        <div class="logo"><img src="static\images\u216.png"></div>
7
-        <div class="content">
8
-         <span v-html="officeform.introduction" id="officecontent" class="xxcontent"></span>
9
-        </div>
10
-     </div>
11
-</template>
12
-
13
-<script>
14
-    import { GetOfficeInfo } from '@/api/site/site'
15
-    export default {
16
-        name: "office-introduction",
17
-        data(){
18
-          return{
19
-            officeform:{
20
-              title:"",
21
-              sort:"",
22
-              introduction:"", 
23
-           },
24
-          }
25
-        },
26
-        methods:{      
27
-     //获取科室介绍
28
-       GetOfficeInfo(){
29
-         GetOfficeInfo().then(response=>{
30
-           if(response.data.state == 1){
31
-             var offices =   response.data.data.offices;
32
-             this.officeform =  response.data.data.offices;
33
-            // console.log("获取科室介绍数据",offices);
34
-           }
35
-          })
36
-         },
37
-        },
38
-        created(){
39
-          this.GetOfficeInfo();
40
-        },
41
-        updated(){
42
-            let officObj =  document.getElementById('officecontent');
43
-            console.log("officeObj是什么",officObj)
44
-            let officeImages =  officObj.getElementsByTagName('img');
45
-            console.log("officeImages",officeImages)
46
-           for(let i=0;i<officeImages.length;i++){
47
-             officeImages[i].style.width = '332px';
48
-             officeImages[i].style.height = '100px';
49
-           }  
50
-        }
51
-    }
52
-</script>
53
-
54
-<style scoped>
55
-   .wq4{
56
-        width: 320px;
57
-        height: 230px;
58
-        background-color: white;
59
-        color: #ffffff;
60
-       /* border: solid 1px black; */
61
-        margin-bottom: 0px;
62
-     }
63
-
64
-      .kefont{
65
-       font-size: 14px;
66
-       color: red;
67
-       margin-left: 8px;
68
-       margin-top: -20px;
69
-     }
70
-
71
-     .more{
72
-       position: absolute;
73
-       font-size: 14px;
74
-       color:black;
75
-       margin-left: 220px;
76
-     }
77
-
78
-    .logo{
79
-       position: absolute;
80
-       margin-left: 280px;
81
-     }
82
-
83
-      .content{
84
-       position: absolute;
85
-       font-size: 14px;
86
-       color: black;
87
-     }
88
-
89
-    .xxcontent{
90
-     overflow: hidden;
91
-     text-overflow: ellipsis;
92
-     display: -webkit-box;
93
-     -webkit-line-clamp: 6;
94
-     -webkit-box-orient: vertical   
95
-   }
96
-
97
-</style>

+ 0 - 338
src/scrm_pages/site/components/parent-component.vue View File

1
-<template>
2
-   <div>
3
-    <div v-for="item in this.patientModels" :key="item.id">
4
-     <div class="parent">  
5
-       <!--医院介绍-->
6
-       <div v-if="item.mode_type == 2" class="modetwo"> 
7
-           <img src="static\images\u.png" style="width:5px;height:20px;">
8
-           <div class="kefont"><span >{{item.title}}</span></div>   
9
-           <div class="more" @click="more()">查看更多</div>
10
-           <div class="logo"><img src="static\images\u216.png"></div>  
11
-           <div class="content">
12
-             <span v-html="item.Hospitals.introduction" id="content" class="yycontent"></span>
13
-          </div>
14
-        </div>
15
-       <!-- 科室介绍 -->
16
-       <div v-if="item.mode_type == 3" class="modethree">
17
-           <img src="static\images\u.png" style="width:5px;height:20px;">
18
-           <div class="kefont"><span >{{item.title}}</span></div>   
19
-           <div class="more" @click="more()">查看更多</div>
20
-           <div class="logo"><img src="static\images\u216.png"></div>  
21
-           <div class="xcontent">
22
-             <span v-html="item.Offices.introduction" id="ycontent" class="zzcontent"></span>
23
-           </div>
24
-        </div>
25
-
26
-        <!-- 名医介绍 -->
27
-        <div v-if="item.mode_type == 4" class="modefour">
28
-          <img src="static\images\u.png" style="width:5px;height:20px;">
29
-           <div class="kefont"><span >{{item.title}}</span></div> 
30
-           <div class="more" @click="more()">查看更多</div>
31
-           <div class="logo"><img src="static\images\u216.png"></div>
32
-           <div class="docborde">
33
-            <div class="docheart" v-for="doc in item.Editdoctor" :key="doc.id">
34
-              <div class="docimage">
35
-                <img :src="doc.dochead" style="height:80px;width:80px">
36
-              </div>
37
-              <div class="doctitle"><span class="docnamefont">{{doc.doc_name}}</span></div>
38
-              <div class="doccontent"><span class="xxcontent" v-html="doc.docintroduction"></span></div>
39
-            </div>
40
-           </div>
41
-        </div>
42
-
43
-         <!-- 科室环境 -->
44
-        <div v-if="item.mode_type == 5" class="modefive">
45
-          <img src="static\images\u.png" style="width:5px;height:20px;"> 
46
-          <div class="kefont"><span >{{item.title}}</span></div> 
47
-           <div class="more" @click="more()">查看更多</div>
48
-           <div class="logo"><img src="static\images\u216.png"></div>
49
-           <div class="swiperimages">
50
-           <div class="swiper-container" id="swipertwo">
51
-           <div class="swiper-wrapper" id="wrapper2">
52
-           <div class="swiper-slide"  v-for="it in item.OfficeEnviroment" :key="it.id">
53
-           <img :src="it.keimages" style="width:150px;height:140px;border-radius:5px;"/>
54
-          </div>
55
-          </div>
56
-         </div>
57
-        </div>
58
-        </div>
59
-     </div>
60
-     <div class="box"></div>
61
-   </div>  
62
-   </div> 
63
-</template>
64
-
65
-<script>
66
-  import { getQueryNewModel,getHospital,getHospitaldata } from '@/api/site/site' 
67
-  import Swiper from "swiper"; 
68
-  import { truncateSync } from 'fs';
69
-    export default {
70
-        name: "parent-component",
71
-        data(){
72
-          return{
73
-            modeltitle:[],
74
-            hospitalform:[],
75
-            patientModels:[],  
76
-            keEnvironmentImages:[],     
77
-            doctors:[],
78
-            
79
-          }  
80
-        },
81
-        methods:{
82
-         more(){
83
-           alert("aaaa")
84
-         },
85
-         getHospital(){
86
-            getHospital().then(response=>{
87
-                if(response.data.state == 1){
88
-                  this.hospitalform = response.data.data.hostital;
89
-                  // console.log("中国第一人",this.hospitalform);
90
-                }
91
-            }) 
92
-         },
93
-          getHospitaldata(){
94
-           getHospitaldata(this.patientModels).then(response=>{
95
-                if(response.data.state == 1){
96
-                  var str = "";
97
-                 this.patientModels = response.data.data.patientModels;
98
-                  console.log("获取的数据",this.patientModels);
99
-                 for (let index = 0; index < this.patientModels.length; index++) {
100
-                   const element = this.patientModels[index].OfficeEnviroment;
101
-                   console.log("element",element)
102
-                 }
103
-                //   var strs = str.split(",");
104
-                //   console.log("strs",strs)             
105
-                //  this.keEnvironmentImages = strs;
106
-                }
107
-           })
108
-         },
109
-        },
110
-        created(){
111
-            this.getHospital();
112
-            this.getHospitaldata();
113
-        },
114
-         updated(){
115
-            let obj = document.getElementById('content');
116
-          
117
-            let imgs =  obj.getElementsByTagName('img');
118
-          
119
-            for(let i=0;i<imgs.length;i++){
120
-            imgs[i].style.width = '332px';
121
-            imgs[i].style.height = '100px';            
122
-         }
123
-          let ycontent = document.getElementById('ycontent');
124
-         
125
-          let ximgs = ycontent.getElementsByTagName('img');
126
-         
127
-          for(let j=0;j<ximgs.length;j++){
128
-             ximgs[j].style.width = '332px';
129
-             ximgs[j].style.height = '100px';
130
-          }
131
-        },
132
-
133
-          mounted(){
134
-            var mySwiper = new Swiper('#swipertwo', {
135
-                direction:"horizontal",
136
-                loop: true, // 循环播放,
137
-                spaceBetween:10,
138
-                autoplay:true,
139
-                loopAdditionalSlides:10,
140
-                slidesPerView: 'auto', // 设置slider容器能够同时显示的slides数量
141
-                centeredSlides: true, // active slide 居中
142
-                observer:true,//动态加载图片
143
-                observeParents:false,
144
-                pagination: {
145
-                    el: '.swiper-pagination',
146
-                },
147
-            });
148
-        },
149
-    }
150
-</script>
151
-
152
-<style scoped>
153
-
154
-    .clickmore{
155
-      width: 200px;
156
-      height: 200px;
157
-      border: solid 1px red;
158
-    }
159
-
160
-    .parent{
161
-      width: 320px;
162
-      height: 230px;
163
-      /* background-color:  rgba(204, 204, 204, 1); */
164
-    }
165
-
166
-    .box{
167
-      width: 320px;
168
-      height: 8px;
169
-      background-color: rgba(204, 204, 204, 1);  
170
-    }
171
-
172
-    .modetwo{
173
-      width: 320px;
174
-      height: 220px;
175
-      /* border: solid 1px red;   */
176
-      /* background-color: red; */
177
-    }
178
-    .modethree{
179
-       width: 320px;
180
-      height: 220px;
181
-      /* border: solid 1px blue;   */
182
-      /* background-color: blue; */
183
-    }
184
-
185
-    .modefour{
186
-      width:320px;
187
-      height: 230px;
188
-    }
189
-
190
-    .modefive{
191
-      width:320px;
192
-      height: 220px;
193
-    }
194
-
195
-     .logo{
196
-       position: absolute;
197
-       margin-left: 280px;
198
-       margin-top: -16px;
199
-     }
200
-     .kefont{
201
-       font-size: 14px;
202
-       color: red;
203
-       margin-left: 8px;
204
-       margin-top: -20px;
205
-     }
206
-
207
-     .more{
208
-       position: absolute;
209
-       font-size: 14px;
210
-       color:black;
211
-       margin-left: 220px;
212
-       margin-top: -15px;
213
-     }
214
-
215
-    .content{
216
-       position: absolute;
217
-       font-size: 14px;
218
-       color: black;
219
-       margin-top: 6px;
220
-     }
221
-
222
-     .xcontent{
223
-       position: absolute;
224
-       font-size: 14px;
225
-       color: black;
226
-       margin-top: 6px;
227
-     }
228
-
229
-    .yycontent{
230
-     overflow: hidden;
231
-     text-overflow: ellipsis;
232
-     display: -webkit-box;
233
-     -webkit-line-clamp: 6;
234
-     -webkit-box-orient: vertical   
235
-   }
236
-
237
-    .zzcontent{
238
-     overflow: hidden;
239
-     text-overflow: ellipsis;
240
-     display: -webkit-box;
241
-     -webkit-line-clamp: 6;
242
-     -webkit-box-orient: vertical   
243
-   }
244
-
245
-   .docborde{
246
-     width: 320px;
247
-     height: 200px;
248
-     /* border: solid 1px red; */
249
-     overflow: hidden;
250
-   }
251
-
252
-   .docborder{
253
-     width: 320px;
254
-     height: 100px;
255
-     /* border: solid 1px red; */
256
-     background-color:  rgba(242, 242, 242, 1);
257
-     margin-top: 8px;
258
-   }
259
-   .docheart{
260
-     width: 300px;
261
-     height: 92px;
262
-     /* border: solid 1px blue; */
263
-     margin-top: 5px;
264
-     margin-left: 3px;
265
-   }
266
-   .docimage{
267
-     width: 80px;
268
-     height: 80px;
269
-     /* border:solid 1px red; */
270
-     margin-top: 10px;
271
-     margin-left: 10px;
272
-   }
273
-   .doctitle{
274
-     width: 50px;
275
-     height: 20px;
276
-     /* border: solid 1px blue; */
277
-     float: right;
278
-     margin-right: 140px;
279
-     margin-top: -75px;
280
-   }
281
-
282
-   .doccontent{
283
-     width: 150px;
284
-     height: 50px;
285
-     /* border: solid 1px red; */
286
-     margin-top: -50px;
287
-     margin-left: 108px;
288
-     font-size: 14px;
289
-   }
290
-   .docnamefont{
291
-     font-size: 14px;
292
-
293
-   }
294
-
295
-   .dochead{
296
-       position:absolute;
297
-       width:80px;
298
-       height: 80px;
299
-       /* border:solid 1px green; */
300
-       margin-top: 10px;
301
-       margin-left: 10px;
302
-   }
303
-
304
-    .docname{
305
-       position: absolute;
306
-       width:50px;
307
-       height: 20px;
308
-       /* border: solid 1px green; */
309
-       margin-left: 130px;
310
-       margin-top: 20px;
311
-       font-size: 14px;
312
-       color:black;
313
-     }
314
-
315
-     .docintroduction{
316
-       font-size: 14px;
317
-       color: black;
318
-     }
319
-
320
-    .xxcontent{
321
-      overflow: hidden;
322
-      text-overflow: ellipsis;
323
-      display: -webkit-box;
324
-      -webkit-line-clamp: 3;
325
-      -webkit-box-orient: vertical   
326
-   }   
327
-
328
-     #wrapper2{
329
-     width: 50%;
330
-   }
331
-
332
-   .swiperimages{
333
-     width: 320px;
334
-     height: 150;
335
-     /* border: solid 1px red; */
336
-     margin-top: 40px;
337
-   }
338
-</style>

+ 0 - 61
src/scrm_pages/site/components/rotation-image.vue View File

1
-<template>
2
-  <div>
3
-     <div class="wq">
4
-        <div class="swiper-slide">
5
-            <mt-swipe :auto="4000">
6
-              <mt-swipe-item v-for="item in rotationImages" :key="item.id">
7
-                  <img :src="item" style="width:480px;height:250px">
8
-              </mt-swipe-item>
9
-            </mt-swipe>
10
-        </div>
11
-     </div>
12
- </div>
13
-</template>
14
-
15
-<script>
16
-    import { GetRationImages } from '@/api/site/site'
17
-    export default {
18
-        name: "rotation-image",
19
-        data(){
20
-           return{
21
-             rotationImages:[],  
22
-             rotationform:[],            
23
-           } 
24
-        },
25
-
26
-        methods:{
27
-        //获取轮播图
28
-         GetRationImages(){
29
-          GetRationImages().then(response=>{
30
-            if(response.data.state ==1){
31
-                var rotation =  response.data.data.rotationImages;    
32
-                this.rotationform =  response.data.data.rotationImages;    
33
-               console.log("获取轮播图数据",rotation)        
34
-              //  console.log("获取轮播图",rotation.rotation_images); 
35
-              //  var str = rotation.rotation_images;
36
-              //  var Images = [];
37
-              //  Images = str.split(",");
38
-              //  console.log("数组",Images)
39
-              //  this.rotationImages = Images;
40
-            }
41
-          })
42
-         },
43
-       },
44
-       created(){
45
-           this.GetRationImages();
46
-       }
47
-    }
48
-</script>
49
-
50
-
51
-<style rel="stylesheet/scss" lang="scss" scoped>
52
-     .wq{
53
-        width: 320px;
54
-        height: 185px;
55
-        background-color: rgba(204, 204, 204, 1);
56
-        color: #ffffff;
57
-      //  border: solid 1px red;
58
-        margin-bottom: 0px;
59
-    }
60
-
61
-</style>

+ 23 - 1
src/scrm_pages/site/index.vue View File

9
               <div class="success">
9
               <div class="success">
10
                 <h1 class="name">欢迎来到微官网主页</h1>
10
                 <h1 class="name">欢迎来到微官网主页</h1>
11
                 <div class="tips">您可以手机扫码访问或在右侧预览</div>
11
                 <div class="tips">您可以手机扫码访问或在右侧预览</div>
12
-                <div class="site-code"><img :src="codeImg" alt=""></div>
12
+                <div id="qrcode" class="qrcode"></div>
13
                 <router-link to="/site/preview">
13
                 <router-link to="/site/preview">
14
                   <el-button type="primary">进入微官网后台</el-button>
14
                   <el-button type="primary">进入微官网后台</el-button>
15
                 </router-link>
15
                 </router-link>
25
 
25
 
26
 <script>
26
 <script>
27
 import BreadCrumb from "../components/bread-crumb";
27
 import BreadCrumb from "../components/bread-crumb";
28
+import QRCode from 'qrcodejs2';
28
 export default {
29
 export default {
29
   name: "site",
30
   name: "site",
30
   components: {
31
   components: {
35
       crumbs: [{ path: false, name: "微网站" }],
36
       crumbs: [{ path: false, name: "微网站" }],
36
       codeImg: require("../../assets/home/wei.jpg")
37
       codeImg: require("../../assets/home/wei.jpg")
37
     };
38
     };
39
+  },
40
+  methods:{
41
+      qrcode () {
42
+      let qrcode = new QRCode('qrcode', {
43
+        width: 100,
44
+        height: 100, // 高度
45
+        text: '56663159' // 二维码内容
46
+        // render: 'canvas' // 设置渲染方式(有两种方式 table和canvas,默认是canvas)
47
+        // background: '#f0f'
48
+        // foreground: '#ff0'
49
+      })
50
+      console.log(qrcode)
51
+    },
52
+  },
53
+  mounted(){
54
+    this.qrcode();
38
   }
55
   }
39
 };
56
 };
40
 </script>
57
 </script>
63
       width: 100%;
80
       width: 100%;
64
     }
81
     }
65
   }
82
   }
83
+  .qrcode{
84
+    margin-bottom: 10px;
85
+    width: 100px;
86
+    height: 100px;
87
+  }
66
 }
88
 }
67
 </style>
89
 </style>

+ 201 - 41
src/scrm_pages/site/preview.vue View File

12
                         <span slot="label"  @click="myindex()">首页</span>
12
                         <span slot="label"  @click="myindex()">首页</span>
13
                         <el-tabs v-model="activeName">
13
                         <el-tabs v-model="activeName">
14
                             <el-tab-pane label="新增模块" name="first">
14
                             <el-tab-pane label="新增模块" name="first">
15
-                                 <new-feature> </new-feature>                    
15
+                                 <new-feature></new-feature>                    
16
                             </el-tab-pane>
16
                             </el-tab-pane>
17
-                            <el-tab-pane label="已使用" name="second">
17
+                            <el-tab-pane>
18
+                                <span slot="label" name="second" @click="clickAddmodel()">已使用</span>
18
                                 <div class="used" v-for="(item,index) in this.modelform" :key="item.id">
19
                                 <div class="used" v-for="(item,index) in this.modelform" :key="item.id">
19
                                   <ul>
20
                                   <ul>
20
                                    <li>
21
                                    <li>
471
                     </el-form-item>
472
                     </el-form-item>
472
                     <el-form-item>
473
                     <el-form-item>
473
                       <el-col :span="18" >
474
                       <el-col :span="18" >
474
-                        <!-- <el-input :disabled="true"  v-show="define" v-model="navigationform.navigationaddress"></el-input> -->
475
                         <el-input   v-show="define" v-model="navigationform.navigationaddress"></el-input> 
475
                         <el-input   v-show="define" v-model="navigationform.navigationaddress"></el-input> 
476
                      </el-col>
476
                      </el-col>
477
                     <el-col :span="4">
477
                     <el-col :span="4">
540
                      <div class="swiper-container swiper-no-swiping" id="swiper1">
540
                      <div class="swiper-container swiper-no-swiping" id="swiper1">
541
                       <div class="swiper-wrapper" id="wrapper1">   
541
                       <div class="swiper-wrapper" id="wrapper1">   
542
                          <div v-for="item in this.patientModels" :key="item.id" v-show="modelshowtwo">
542
                          <div v-for="item in this.patientModels" :key="item.id" v-show="modelshowtwo">
543
-                            <div class="parent">  
543
+                           <!-- 轮播图 -->
544
+                             <div v-if="item.mode_type == 1" class="modeone">                                                                 
545
+                                 <mt-swipe :auto="4000" class="swipertwo">
546
+                                 <mt-swipe-item v-for="it in rotatationImages" :key="it.id">
547
+                                   <img :src="it" style="width:318px;height:230px" >
548
+                                 </mt-swipe-item>
549
+                                 </mt-swipe>                                                                             
550
+                             </div>
544
                               <!--医院介绍-->
551
                               <!--医院介绍-->
545
                             <div v-if="item.mode_type == 2" class="modetwo"> 
552
                             <div v-if="item.mode_type == 2" class="modetwo"> 
546
                                <img src="static\images\u.png" style="width:5px;height:20px;">
553
                                <img src="static\images\u.png" style="width:5px;height:20px;">
570
                                 <div class="logo"><img src="static\images\u216.png"></div>
577
                                 <div class="logo"><img src="static\images\u216.png"></div>
571
                                 <div class="docborde">
578
                                 <div class="docborde">
572
                                  <div class="docheart" v-for="doc in item.Editdoctor" :key="doc.id">
579
                                  <div class="docheart" v-for="doc in item.Editdoctor" :key="doc.id">
573
-                                 <div class="docimage">
574
-                                  <img :src="doc.dochead" style="height:80px;width:80px">
575
-                                  </div>
576
-                             <div class="doctitle"><span class="docnamefont">{{doc.doc_name}}</span></div>
577
-                              <div class="doccontent"><span class="xxcontent" v-html="doc.docintroduction"></span></div>
578
-                              </div>
580
+                                   <div class="docimage">
581
+                                    <img :src="doc.dochead" style="height:80px;width:80px">
582
+                                   </div>
583
+                                 <div class="doctitle"><span class="docnamefont">{{doc.doc_name}}</span></div>
584
+                                 <div class="doccontent"><span class="xxcontent" v-html="doc.docintroduction"></span></div>
585
+                               </div>
579
                               </div>
586
                               </div>
580
-                             </div>
587
+                          </div>
581
 
588
 
582
                             <!-- 科室环境 -->
589
                             <!-- 科室环境 -->
583
                            <div v-if="item.mode_type == 5" class="modefive">
590
                            <div v-if="item.mode_type == 5" class="modefive">
588
                             <div class="swiperimages">
595
                             <div class="swiperimages">
589
                             <div class="swiper-container" id="swipertwo">
596
                             <div class="swiper-container" id="swipertwo">
590
                             <div class="swiper-wrapper" id="wrapper2">
597
                             <div class="swiper-wrapper" id="wrapper2">
591
-                            <div class="swiper-slide"  v-for="it in item.OfficeEnviroment" :key="it.id">
592
-                             <img :src="it.keimages" style="width:150px;height:140px;border-radius:5px;"/>
598
+                            <div class="swiper-slide"  v-for="it in keEnvironmentImages" :key="it.id">
599
+                             <img :src="it" style="width:150px;height:140px;border-radius:5px;"/>
593
                            </div>
600
                            </div>
594
                            </div>
601
                            </div>
595
                            </div>
602
                            </div>
596
                             </div>
603
                             </div>
597
                            </div>
604
                            </div>
598
-                          </div>
605
+
606
+                           <!-- 魔方导航 -->
607
+                           <div v-if="item.mode_type== 8" class="modeeight">
608
+                              {{item.title}}     
609
+                           </div>
610
+                          
599
                           <div class="box"></div>
611
                           <div class="box"></div>
600
                          </div>  
612
                          </div>  
601
                           <contact-us  v-show="modelshow"></contact-us>                              
613
                           <contact-us  v-show="modelshow"></contact-us>                              
602
                       </div>         
614
                       </div>         
603
                      </div>
615
                      </div>
604
                    </div>  
616
                    </div>  
605
-                      
606
-                     
607
                       <!-- 医院介绍详情页-->                
617
                       <!-- 医院介绍详情页-->                
608
                       <div class="xiangqing"  v-show="shows" v-html="hospitalform.introduction"></div> 
618
                       <div class="xiangqing"  v-show="shows" v-html="hospitalform.introduction"></div> 
609
                       <!-- 科室介绍详情页 -->                        
619
                       <!-- 科室介绍详情页 -->                        
622
                              </div>
632
                              </div>
623
                           </div>
633
                           </div>
624
                         </div>
634
                         </div>
625
-            
635
+                         
636
+                       <!--返回首页-->
637
+                     <div class="reback" v-show="showback">
638
+                       <div class="rebackone">
639
+                         <img src="static/images/u373.png">
640
+                       </div>
641
+                       <div class="rebacktwo">
642
+                         <span @click="returnIndex()">首页</span>
643
+                      </div>
644
+                     </div>
645
+                     <!-- 回到顶部 -->
646
+                     <div class="reindex" v-show="showindex">
647
+                        <div class="reindexone">
648
+                           <img src="static/images/u378.png">
649
+                        </div>
650
+                        <div class="reindextwo">
651
+                            <span>顶部</span>
652
+                        </div>
653
+                     </div>
626
                       
654
                       
627
                       <div id="qrcode" class="qrcode"></div>
655
                       <div id="qrcode" class="qrcode"></div>
628
 
656
 
762
 import { rejects, fail } from 'assert';
790
 import { rejects, fail } from 'assert';
763
 import { copyFile } from 'fs'; 
791
 import { copyFile } from 'fs'; 
764
 import { truncateSync } from 'fs';
792
 import { truncateSync } from 'fs';
793
+import { isAbsolute } from 'path';
765
 export default {
794
 export default {
766
   name: "preview",
795
   name: "preview",
767
   components: {
796
   components: {
788
        patientModels:[],  
817
        patientModels:[],  
789
        keEnvironmentImages:[],     
818
        keEnvironmentImages:[],     
790
        doctors:[],
819
        doctors:[],
820
+       rotatationImages:[],
791
       crumbs: [{ path: false, name: "预览" }],
821
       crumbs: [{ path: false, name: "预览" }],
792
       activeName: 'first',
822
       activeName: 'first',
793
       name: "car",
823
       name: "car",
819
        definethree:false,
849
        definethree:false,
820
        definefour:false,
850
        definefour:false,
821
        disabled:true,
851
        disabled:true,
852
+       showback:false,
853
+       showindex:false,
822
       ellipsis:'',
854
       ellipsis:'',
823
       docnames:[],
855
       docnames:[],
824
        options: [{
856
        options: [{
868
           worktime:[{required:true,message:"请填写工作时间"}],
900
           worktime:[{required:true,message:"请填写工作时间"}],
869
           rideway:[{required:true,message:"请填写乘车方式"}]   
901
           rideway:[{required:true,message:"请填写乘车方式"}]   
870
       },
902
       },
871
-        rotationImages:[],
872
         keEnvironmentImages:[],
903
         keEnvironmentImages:[],
873
         qiniuDomain: 'https://images.shengws.com/',
904
         qiniuDomain: 'https://images.shengws.com/',
874
         rotationData: { token:'',key: '' },
905
         rotationData: { token:'',key: '' },
1025
           getHospitaldata(){
1056
           getHospitaldata(){
1026
            getHospitaldata(this.patientModels).then(response=>{
1057
            getHospitaldata(this.patientModels).then(response=>{
1027
                 if(response.data.state == 1){
1058
                 if(response.data.state == 1){
1028
-                  var str = "";
1059
+                  var str = [];
1060
+                  var images = [];
1029
                  this.patientModels = response.data.data.patientModels;
1061
                  this.patientModels = response.data.data.patientModels;
1030
-                  console.log("获取的数据",this.patientModels);
1031
-                 for (let index = 0; index < this.patientModels.length; index++) {
1032
-                   const element = this.patientModels[index].OfficeEnviroment;
1033
-                   console.log("element",element)
1034
-                 }
1035
-                //   var strs = str.split(",");
1036
-                //   console.log("strs",strs)             
1037
-                //  this.keEnvironmentImages = strs;
1062
+                 for (let index = 0; index < this.patientModels.length; index++) {   
1063
+                   if(this.patientModels[index].Rotation.rotation_images!=""){
1064
+                     str.push(this.patientModels[index].Rotation.rotation_images);
1065
+                   }                                               
1066
+                }   
1067
+                var  strs =  str.join(",")
1068
+                var ss = strs.split(",")
1069
+                this.rotatationImages = ss;
1070
+                for(let i = 0; i<this.patientModels.length;i++){
1071
+                  if(this.patientModels[i].OfficeEnviroment.keimages !=""){
1072
+                     images.push(this.patientModels[i].OfficeEnviroment.keimages);
1073
+                  }       
1074
+                }
1075
+                var imgs =  str.join(",")
1076
+                var imgss = imgs.split(",")
1077
+                this.keEnvironmentImages = imgss;
1078
+                console.log("keimages是什么",imgss);
1079
+                console.log("获取的各模块数据",this.patientModels);   
1038
                 }
1080
                 }
1039
            })
1081
            })
1040
          },
1082
          },
1172
       },
1214
       },
1173
 
1215
 
1174
       shareAvatarUpload(file){
1216
       shareAvatarUpload(file){
1175
-           var fileType = file.type
1217
+            var fileType = file.type
1176
             const isJPG = fileType.indexOf("image") > -1;
1218
             const isJPG = fileType.indexOf("image") > -1;
1177
             const isLt2M = file.size / 1024 / 1024 < 2;
1219
             const isLt2M = file.size / 1024 / 1024 < 2;
1178
             if (!isJPG) {
1220
             if (!isJPG) {
1229
             console.log("医院详情数据",hospital)
1271
             console.log("医院详情数据",hospital)
1230
             console.log("医院详情数据是",this.hospitalform)
1272
             console.log("医院详情数据是",this.hospitalform)
1231
             this.show = false;
1273
             this.show = false;
1232
-           this.shows = true;
1274
+            this.shows = true;
1275
+            this.showback = true;
1276
+            this.showindex = true;
1233
          }
1277
          }
1234
       })
1278
       })
1235
     },
1279
     },
1280
+    returnIndex(){
1281
+      this.show = true;
1282
+      this.shows = false;
1283
+      this.showback = false;
1284
+      this.showindex = false;
1285
+      this.docshow = false;
1286
+      this.shows = false;
1287
+      this.keshow = false;
1288
+    },
1236
 
1289
 
1237
     //查看科室详情
1290
     //查看科室详情
1238
     officemore(id){
1291
     officemore(id){
1243
            console.log("科室详情数据",offices)
1296
            console.log("科室详情数据",offices)
1244
            this.show = false;
1297
            this.show = false;
1245
            this.keshow = true;
1298
            this.keshow = true;
1299
+           this.showback = true;
1300
+           this.showindex = true;
1246
          }
1301
          }
1247
       })   
1302
       })   
1248
     },
1303
     },
1255
            this.editdocfrom  =  response.data.data.editdoctor;
1310
            this.editdocfrom  =  response.data.data.editdoctor;
1256
             this.show = false;
1311
             this.show = false;
1257
             this.docshow = true;
1312
             this.docshow = true;
1313
+            this.showback = true;
1314
+            this.showindex = true;
1258
            console.log("编辑医生返回数据",editdoctor)
1315
            console.log("编辑医生返回数据",editdoctor)
1259
          }
1316
          }
1260
        })
1317
        })
1279
      clickmodel(){
1336
      clickmodel(){
1280
         this.GetUserdModel();
1337
         this.GetUserdModel();
1281
      },
1338
      },
1339
+     clickAddmodel(){
1340
+       this.getQueryNewModel();
1341
+     },
1282
      //查询首页已使用的模块
1342
      //查询首页已使用的模块
1283
       getQueryNewModel(){
1343
       getQueryNewModel(){
1284
            getQueryNewModel(this.modelform).then(response=>{
1344
            getQueryNewModel(this.modelform).then(response=>{
1285
             if(response.data.state ==1){
1345
             if(response.data.state ==1){
1286
              var model  = response.data.data.model;
1346
              var model  = response.data.data.model;
1287
-             this.modelform  = response.data.data.model;
1288
-             console.log("返回新的数据",model);
1347
+             this.modelform  = response.data.data.model;           
1289
             }
1348
             }
1290
           });
1349
           });
1291
          },
1350
          },
1754
        let obj = document.getElementById('content');
1813
        let obj = document.getElementById('content');
1755
           
1814
           
1756
        let imgs =  obj.getElementsByTagName('img');
1815
        let imgs =  obj.getElementsByTagName('img');
1757
-          
1816
+  
1758
         for(let i=0;i<imgs.length;i++){
1817
         for(let i=0;i<imgs.length;i++){
1759
           imgs[i].style.width = '332px';
1818
           imgs[i].style.width = '332px';
1760
           imgs[i].style.height = '100px';            
1819
           imgs[i].style.height = '100px';            
1761
         }
1820
         }
1821
+
1762
         let ycontent = document.getElementById('ycontent');
1822
         let ycontent = document.getElementById('ycontent');
1763
          
1823
          
1764
         let ximgs = ycontent.getElementsByTagName('img');
1824
         let ximgs = ycontent.getElementsByTagName('img');
2030
      font-size: 14px;
2090
      font-size: 14px;
2031
      overflow-y: auto;
2091
      overflow-y: auto;
2032
      color: black;
2092
      color: black;
2093
+     overflow: hidden;
2033
    }
2094
    }
2034
    officexiangqing{
2095
    officexiangqing{
2035
       position: relative;
2096
       position: relative;
2123
       background-color: rgba(204, 204, 204, 1);  
2184
       background-color: rgba(204, 204, 204, 1);  
2124
     }
2185
     }
2125
 
2186
 
2187
+    .modeone{      
2188
+        width: 318px;
2189
+        height: 210px;
2190
+        // border: solid 1px red;
2191
+    }
2192
+    .swipertwo{
2193
+      width:318px;
2194
+      height: 230px;
2195
+      margin-top: 25px;
2196
+      // border:solid 1px red;
2197
+    }
2198
+
2126
     .modetwo{
2199
     .modetwo{
2127
       width: 320px;
2200
       width: 320px;
2128
       height: 220px;
2201
       height: 220px;
2139
     .modefour{
2212
     .modefour{
2140
       width:320px;
2213
       width:320px;
2141
       height: 230px;
2214
       height: 230px;
2215
+      
2142
     }
2216
     }
2143
 
2217
 
2144
     .modefive{
2218
     .modefive{
2145
       width:320px;
2219
       width:320px;
2146
-      height: 220px;
2220
+      height: 200px;
2221
+      // border: solid 1px red;
2222
+    }
2223
+
2224
+    .modeeight{
2225
+      width: 320px;
2226
+      height: 200px;
2227
+      // border: solid 1px red;
2228
+    }
2229
+
2230
+     .mac{
2231
+       position: absolute;
2232
+       width: 300px;
2233
+       height: 100px;
2234
+       border:solid 1px red;
2235
+       margin-left: 5px;
2236
+       margin-top: 5px;
2237
+    }   
2238
+    #mactwo{
2239
+
2240
+    }
2241
+
2242
+    .macone{
2243
+      position: absolute;
2244
+      width: 50px;
2245
+      height: 90px;
2246
+      border: solid 1px red;
2247
+      top: 5px;
2248
+      left: 5px;
2147
     }
2249
     }
2148
 
2250
 
2149
      .logo{
2251
      .logo{
2199
    .docborde{
2301
    .docborde{
2200
      width: 320px;
2302
      width: 320px;
2201
      height: 200px;
2303
      height: 200px;
2202
-     /* border: solid 1px red; */
2304
+    //  border: solid 1px red; 
2203
      overflow: hidden;
2305
      overflow: hidden;
2204
    }
2306
    }
2205
 
2307
 
2211
      margin-top: 8px;
2313
      margin-top: 8px;
2212
    }
2314
    }
2213
    .docheart{
2315
    .docheart{
2214
-     width: 300px;
2316
+     width: 310px;
2215
      height: 92px;
2317
      height: 92px;
2216
-     /* border: solid 1px blue; */
2318
+    //  border: solid 1px blue; 
2319
+     background-color: rgba(242, 242, 242, 1);
2217
      margin-top: 5px;
2320
      margin-top: 5px;
2218
      margin-left: 3px;
2321
      margin-left: 3px;
2219
    }
2322
    }
2220
    .docimage{
2323
    .docimage{
2221
      width: 80px;
2324
      width: 80px;
2222
      height: 80px;
2325
      height: 80px;
2223
-     /* border:solid 1px red; */
2224
-     margin-top: 10px;
2225
      margin-left: 10px;
2326
      margin-left: 10px;
2327
+     padding-top: 5px;
2226
    }
2328
    }
2227
    .doctitle{
2329
    .doctitle{
2228
      width: 50px;
2330
      width: 50px;
2229
      height: 20px;
2331
      height: 20px;
2230
      /* border: solid 1px blue; */
2332
      /* border: solid 1px blue; */
2231
      float: right;
2333
      float: right;
2232
-     margin-right: 140px;
2334
+     margin-right: 152px;
2233
      margin-top: -75px;
2335
      margin-top: -75px;
2234
    }
2336
    }
2235
 
2337
 
2276
        height:100px;
2378
        height:100px;
2277
       //  border: solid red 1px;
2379
       //  border: solid red 1px;
2278
        margin-left: 5px;
2380
        margin-left: 5px;
2279
-
2381
+      overflow: hidden;
2280
      }
2382
      }
2281
 
2383
 
2282
      .doctwo{
2384
      .doctwo{
2331
      width: 320px;
2433
      width: 320px;
2332
      height: 150;
2434
      height: 150;
2333
      /* border: solid 1px red; */
2435
      /* border: solid 1px red; */
2334
-     margin-top: 40px;
2436
+     margin-top: 20px;
2335
    }
2437
    }
2336
 
2438
 
2337
    .navigationone{
2439
    .navigationone{
2544
     margin-top: 50px;
2646
     margin-top: 50px;
2545
     margin-left: 10px;
2647
     margin-left: 10px;
2546
   }
2648
   }
2649
+
2650
+  .reback{
2651
+    position: absolute;
2652
+    width:50px;
2653
+    height: 50px;
2654
+    border:solid 1px rgba(255, 255, 255, 1);
2655
+    margin-left: 298px;
2656
+    margin-top: -390px;
2657
+    background-color: rgba(255, 255, 255, 1);
2658
+  }
2659
+  .rebackone{
2660
+    position: absolute;
2661
+    width:20px;
2662
+    height: 20px;
2663
+    // border: solid 1px red;
2664
+    left: 13px;
2665
+    top:5px;
2666
+  }
2667
+  .reindexone{
2668
+    position: absolute;
2669
+    width:20px;
2670
+    height: 20px;
2671
+    // border: solid 1px red;
2672
+    left:13px;
2673
+    top:5px;
2674
+  }
2675
+
2676
+  .rebacktwo{
2677
+    position: absolute;
2678
+    width: 30px;
2679
+    height: 20px;
2680
+    // border:solid 1px red;
2681
+    left: 10px;
2682
+    top: 28px;
2683
+    font-size: 14px;
2684
+    color: #FF6600;
2685
+  }
2686
+  
2687
+  .reindextwo{
2688
+    position: absolute;
2689
+    width: 30px;
2690
+    height: 20px;
2691
+    left: 10px;
2692
+    top:28px;
2693
+    font-size: 14px;
2694
+    color: #FF6600;
2695
+    
2696
+  }
2697
+  .reindex{
2698
+    position: absolute;
2699
+    width: 50px;
2700
+    height: 50px;
2701
+    border: solid 1px rgba(255, 255, 255, 1);
2702
+    margin-left: 298px;
2703
+    margin-top: -335px;
2704
+  }
2705
+
2706
+ 
2547
 </style>
2707
 </style>
2548
 
2708
 
2549
 
2709
 

+ 12 - 10
src/scrm_pages/systemsetting/components/CreateStaffForm.vue View File

197
               console.log("上传轮机",this.form.dochead)
197
               console.log("上传轮机",this.form.dochead)
198
               },
198
               },
199
              beforeAvatarUpload(file) {
199
              beforeAvatarUpload(file) {
200
-              const isJPG = file.type === 'image/jpeg';
201
-              console.log("是什么呢",isJPG)
200
+               var fileType = file.type
201
+               const isJPG = fileType.indexOf("image") > -1;
202
               const isLt2M = file.size / 1024 / 1024 < 2;
202
               const isLt2M = file.size / 1024 / 1024 < 2;
203
-             if (!isJPG) {
204
-              this.$message.error('上传头像图片只能是JPG或者png格式!');
205
-            }
206
-            if (!isLt2M) {
207
-              this.$message.error('上传头像图片大小不能超过 2MB!');
208
-            }
203
+              if (!isJPG) {
204
+                this.$message.error("只能上传图片");
205
+                return false;
206
+             }
207
+             if (!isLt2M) {
208
+                this.$message.error("图片大小不能超过 2MB!");
209
+                return false;
210
+             }
209
 
211
 
210
              var date = new Date()
212
              var date = new Date()
211
              var ext = getFileExtension(file.name)
213
              var ext = getFileExtension(file.name)
274
     .avatar-uploader-icon {
276
     .avatar-uploader-icon {
275
       font-size: 20px;
277
       font-size: 20px;
276
       color: #8c939d;
278
       color: #8c939d;
277
-      width: 44px;
279
+      width: 50px;
278
       height: 50px;
280
       height: 50px;
279
       line-height: 50px;
281
       line-height: 50px;
280
       text-align: center;
282
       text-align: center;
281
     }
283
     }
282
     .avatar {
284
     .avatar {
283
       width: 68px;
285
       width: 68px;
284
-      height: 50px;
286
+      height: 40px;
285
       display: block;
287
       display: block;
286
     }
288
     }
287
 </style>
289
 </style>

BIN
static/images/u373.png View File


BIN
static/images/u378.png View File