Browse Source

Merge branch '2.0.0' of http://git.ycjcjy.com/fuxingfan/smartCommunity into 2.0.0

傅行帆 6 years ago
parent
commit
f5abbe0082
23 changed files with 318 additions and 219 deletions
  1. 3
    1
      CODE/smart-community/app-api/src/main/java/com/community/huiju/common/code/ICode.java
  2. 1
    1
      CODE/smart-community/app-api/src/main/java/com/community/huiju/controller/SocialController.java
  3. 2
    0
      CODE/smart-community/app-api/src/main/java/com/community/huiju/dao/TpActivityMapper.java
  4. 1
    0
      CODE/smart-community/app-api/src/main/java/com/community/huiju/dao/TpActivitySignInMapper.java
  5. 1
    0
      CODE/smart-community/app-api/src/main/java/com/community/huiju/dao/TpActivitySignupMapper.java
  6. 11
    1
      CODE/smart-community/app-api/src/main/java/com/community/huiju/model/TpActivity.java
  7. 27
    1
      CODE/smart-community/app-api/src/main/java/com/community/huiju/service/impl/SocialServiceImpl.java
  8. 19
    4
      CODE/smart-community/app-api/src/main/resources/mapper/TpActivityMapper.xml
  9. 10
    0
      CODE/smart-community/app-api/src/main/resources/mapper/TpActivitySignInMapper.xml
  10. 1
    1
      CODE/smart-community/property-api/src/main/java/com/community/huiju/service/impl/IndexCountServiceImpl.java
  11. 2
    2
      VUECODE/smart-operate-manage/src/views/login/index.vue
  12. 7
    4
      VUECODE/smart-property-manage/src/views/grogshop/configindex.vue
  13. 47
    40
      VUECODE/smart-property-manage/src/views/grogshop/grogshopRoomAdd.vue
  14. 55
    49
      VUECODE/smart-property-manage/src/views/grogshop/grogshopRoomEdit.vue
  15. 6
    5
      VUECODE/smart-property-manage/src/views/login/index.vue
  16. 4
    3
      VUECODE/smart-property-manage/src/views/social/activity/add/index.vue
  17. 4
    3
      VUECODE/smart-property-manage/src/views/social/activity/edi/index.vue
  18. 100
    84
      VUECODE/smart-property-manage/src/views/social/activity/info/index.vue
  19. 1
    1
      VUECODE/smart-property-manage/src/views/social/announcement/add.vue
  20. 10
    13
      VUECODE/smart-property-manage/src/views/social/announcement/details.vue
  21. 1
    1
      VUECODE/smart-property-manage/src/views/social/announcement/edit.vue
  22. 4
    4
      VUECODE/smart-property-manage/src/views/ticket/details.vue
  23. 1
    1
      VUECODE/smart-property-manage/src/views/ticket/index.vue

+ 3
- 1
CODE/smart-community/app-api/src/main/java/com/community/huiju/common/code/ICode.java View File

32
         String phoneCode = (String) AppkeyCache.getCache(phone);
32
         String phoneCode = (String) AppkeyCache.getCache(phone);
33
         if ("1234".equals(code)) {
33
         if ("1234".equals(code)) {
34
 
34
 
35
-        }else if (StringUtils.isBlank(phoneCode) || !phoneCode.equals(code)) {
35
+        }else if (StringUtils.isBlank(phoneCode)) {
36
             throw new WisdomException("请输入验证码!");
36
             throw new WisdomException("请输入验证码!");
37
+        } else if (!phoneCode.equals(code)) {
38
+            throw new WisdomException("验证码错误!");
37
         }
39
         }
38
         // 设置验证码为null字符
40
         // 设置验证码为null字符
39
         // AppkeyCache.setCache(phone,"null");
41
         // AppkeyCache.setCache(phone,"null");

+ 1
- 1
CODE/smart-community/app-api/src/main/java/com/community/huiju/controller/SocialController.java View File

129
                                            @RequestParam("activityId") Integer activityId,
129
                                            @RequestParam("activityId") Integer activityId,
130
                                            HttpSession session) {
130
                                            HttpSession session) {
131
         UserElement userElement = (UserElement) session.getAttribute(Constant.APP_USER_SESSION);
131
         UserElement userElement = (UserElement) session.getAttribute(Constant.APP_USER_SESSION);
132
-        Integer userId = userElement.getId();
132
+        Integer userId = userElement.getUserVerifyId();
133
 
133
 
134
         ResponseBean responseBean = new ResponseBean();
134
         ResponseBean responseBean = new ResponseBean();
135
         if (!check(communityId)) {
135
         if (!check(communityId)) {

+ 2
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/dao/TpActivityMapper.java View File

38
      * @return
38
      * @return
39
      */
39
      */
40
     List<TpActivity> selecttpActivity(@Param("id") Integer id, @Param("communityId") Integer communityId);
40
     List<TpActivity> selecttpActivity(@Param("id") Integer id, @Param("communityId") Integer communityId);
41
+
42
+    TpActivity selectActivity(@Param("activityId") Integer activityId);
41
 }
43
 }

+ 1
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/dao/TpActivitySignInMapper.java View File

24
      *
24
      *
25
      */
25
      */
26
     TpActivitySignIn selectSing(@Param("activityId") Integer activityId,@Param("userID") Integer userID);
26
     TpActivitySignIn selectSing(@Param("activityId") Integer activityId,@Param("userID") Integer userID);
27
+
27
 }
28
 }

+ 1
- 0
CODE/smart-community/app-api/src/main/java/com/community/huiju/dao/TpActivitySignupMapper.java View File

1
 package com.community.huiju.dao;
1
 package com.community.huiju.dao;
2
 
2
 
3
 
3
 
4
+import com.community.huiju.model.TpActivitySignIn;
4
 import com.community.huiju.model.TpActivitySignup;
5
 import com.community.huiju.model.TpActivitySignup;
5
 import org.apache.ibatis.annotations.Mapper;
6
 import org.apache.ibatis.annotations.Mapper;
6
 import org.apache.ibatis.annotations.Param;
7
 import org.apache.ibatis.annotations.Param;

+ 11
- 1
CODE/smart-community/app-api/src/main/java/com/community/huiju/model/TpActivity.java View File

42
     private Date updateDate;
42
     private Date updateDate;
43
     
43
     
44
     private String userName;
44
     private String userName;
45
-    
45
+
46
+    private String signInCode;
47
+
48
+    public String getSignInCode() {
49
+        return signInCode;
50
+    }
51
+
52
+    public void setSignInCode(String signInCode) {
53
+        this.signInCode = signInCode;
54
+    }
55
+
46
     /**
56
     /**
47
      * 报名状态
57
      * 报名状态
48
      */
58
      */

+ 27
- 1
CODE/smart-community/app-api/src/main/java/com/community/huiju/service/impl/SocialServiceImpl.java View File

648
     public ResponseBean tpActivitySignInAdd(String paramets, UserElement userElement) {
648
     public ResponseBean tpActivitySignInAdd(String paramets, UserElement userElement) {
649
         ResponseBean responseBean = new ResponseBean();
649
         ResponseBean responseBean = new ResponseBean();
650
         Integer activityId = JSONObject.parseObject(paramets).getInteger("activityId");
650
         Integer activityId = JSONObject.parseObject(paramets).getInteger("activityId");
651
+        // 校验扫码签到
652
+        TpActivity tpActivity = tpActivityMapper.selectByPrimaryKey(activityId,userElement.getCommunityId());
653
+        /*当前用户扫的是否是本小区的码*/
654
+        TpActivity activity = tpActivityMapper.selectActivity(activityId);
655
+        if (null!=activity && (!userElement.getCommunityId().equals(activity.getCommunityId()))){
656
+            responseBean.addError("活动不属于当前登录小区,请在个人中心切换小区");
657
+            return responseBean;
658
+        }
659
+        /*查看当前用户是否报名*/
660
+         TpActivitySignup signIn= tpActivitySignupMapper.selectTpActivetitySignByUserId(activityId,userElement.getCommunityId(),userElement.getUserVerifyId());
661
+        if (signIn == null){
662
+            responseBean.addError("请先报名");
663
+            return responseBean;
664
+        }
665
+        /*活动不需要签到*/
666
+
667
+        if (null!=tpActivity && "2".equals(tpActivity.getSignInCode())){
668
+            responseBean.addError("活动已不能签到");
669
+            return responseBean;
670
+        }
671
+        /*活动作废*/
672
+        if (null!=tpActivity && "0".equals(tpActivity.getStatus())){
673
+            responseBean.addError("活动已被作废");
674
+            return responseBean;
675
+        }
676
+
651
         TpActivitySignIn tpActivitySignIn = new TpActivitySignIn();
677
         TpActivitySignIn tpActivitySignIn = new TpActivitySignIn();
652
         tpActivitySignIn.setActivityId(activityId);
678
         tpActivitySignIn.setActivityId(activityId);
653
         tpActivitySignIn.setCommunityId(userElement.getCommunityId());
679
         tpActivitySignIn.setCommunityId(userElement.getCommunityId());
790
         TpActivitySignup tpActivitySignup = new TpActivitySignup();
816
         TpActivitySignup tpActivitySignup = new TpActivitySignup();
791
         tpActivitySignup.setActivityId(tpActivity.getId());
817
         tpActivitySignup.setActivityId(tpActivity.getId());
792
         tpActivitySignup.setCommunityId(communityId);
818
         tpActivitySignup.setCommunityId(communityId);
793
-        tpActivitySignup.setTaUserId(userElement.getId());
819
+        tpActivitySignup.setTaUserId(userElement.getUserVerifyId());
794
         tpActivitySignup.setSignUpTime(new Date());
820
         tpActivitySignup.setSignUpTime(new Date());
795
         tpActivitySignup.setRemark(remark);
821
         tpActivitySignup.setRemark(remark);
796
 
822
 

+ 19
- 4
CODE/smart-community/app-api/src/main/resources/mapper/TpActivityMapper.xml View File

21
     <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
21
     <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
22
     <result column="update_user" property="updateUser" jdbcType="INTEGER" />
22
     <result column="update_user" property="updateUser" jdbcType="INTEGER" />
23
     <result column="update_date" property="updateDate" jdbcType="TIMESTAMP" />
23
     <result column="update_date" property="updateDate" jdbcType="TIMESTAMP" />
24
+    <result column="sign_in_code" property="signInCode" jdbcType="VARCHAR" />
25
+
24
   </resultMap>
26
   </resultMap>
25
   <sql id="Base_Column_List" >
27
   <sql id="Base_Column_List" >
26
     id, community_id, activity_title, activity_carousel_img, activity_content, sort, 
28
     id, community_id, activity_title, activity_carousel_img, activity_content, sort, 
27
     sign_up_count, sign_up_max, view_count, registration_start_time, registration_end_time, 
29
     sign_up_count, sign_up_max, view_count, registration_start_time, registration_end_time, 
28
     activity_start_time, activity_end_time, status, create_user, create_date, update_user, 
30
     activity_start_time, activity_end_time, status, create_user, create_date, update_user, 
29
-    update_date
31
+    update_date,sign_in_code
30
   </sql>
32
   </sql>
31
   <select id="selectByPrimaryKey" resultMap="BaseResultMap">
33
   <select id="selectByPrimaryKey" resultMap="BaseResultMap">
32
     select
34
     select
45
       registration_start_time, registration_end_time, 
47
       registration_start_time, registration_end_time, 
46
       activity_start_time, activity_end_time, 
48
       activity_start_time, activity_end_time, 
47
       status, create_user, create_date, 
49
       status, create_user, create_date, 
48
-      update_user, update_date)
50
+      update_user, update_date,sign_in_code,sign_in_code,sign_in_code)
49
     values (#{id,jdbcType=INTEGER}, #{communityId,jdbcType=INTEGER}, #{activityTitle,jdbcType=VARCHAR}, 
51
     values (#{id,jdbcType=INTEGER}, #{communityId,jdbcType=INTEGER}, #{activityTitle,jdbcType=VARCHAR}, 
50
       #{activityCarouselImg,jdbcType=VARCHAR}, #{activityContent,jdbcType=LONGVARCHAR}, #{sort,jdbcType=INTEGER},
52
       #{activityCarouselImg,jdbcType=VARCHAR}, #{activityContent,jdbcType=LONGVARCHAR}, #{sort,jdbcType=INTEGER},
51
       #{signUpCount,jdbcType=INTEGER}, #{signUpMax,jdbcType=INTEGER}, #{viewCount,jdbcType=INTEGER}, 
53
       #{signUpCount,jdbcType=INTEGER}, #{signUpMax,jdbcType=INTEGER}, #{viewCount,jdbcType=INTEGER}, 
52
       #{registrationStartTime,jdbcType=TIMESTAMP}, #{registrationEndTime,jdbcType=TIMESTAMP}, 
54
       #{registrationStartTime,jdbcType=TIMESTAMP}, #{registrationEndTime,jdbcType=TIMESTAMP}, 
53
       #{activityStartTime,jdbcType=TIMESTAMP}, #{activityEndTime,jdbcType=TIMESTAMP}, 
55
       #{activityStartTime,jdbcType=TIMESTAMP}, #{activityEndTime,jdbcType=TIMESTAMP}, 
54
       #{status,jdbcType=CHAR}, #{createUser,jdbcType=INTEGER}, #{createDate,jdbcType=TIMESTAMP}, 
56
       #{status,jdbcType=CHAR}, #{createUser,jdbcType=INTEGER}, #{createDate,jdbcType=TIMESTAMP}, 
55
-      #{updateUser,jdbcType=INTEGER}, #{updateDate,jdbcType=TIMESTAMP})
57
+      #{updateUser,jdbcType=INTEGER}, #{updateDate,jdbcType=TIMESTAMP},#{signInCode,jdbcType=TIMESTAMP})
56
   </insert>
58
   </insert>
57
   <insert id="insertSelective" parameterType="com.community.huiju.model.TpActivity" >
59
   <insert id="insertSelective" parameterType="com.community.huiju.model.TpActivity" >
58
     insert into tp_activity
60
     insert into tp_activity
111
       <if test="updateDate != null" >
113
       <if test="updateDate != null" >
112
         update_date,
114
         update_date,
113
       </if>
115
       </if>
116
+      <if test="signInCode != null" >
117
+        sign_in_code
118
+      </if>
114
     </trim>
119
     </trim>
115
     <trim prefix="values (" suffix=")" suffixOverrides="," >
120
     <trim prefix="values (" suffix=")" suffixOverrides="," >
116
       <if test="id != null" >
121
       <if test="id != null" >
167
       <if test="updateDate != null" >
172
       <if test="updateDate != null" >
168
         #{updateDate,jdbcType=TIMESTAMP},
173
         #{updateDate,jdbcType=TIMESTAMP},
169
       </if>
174
       </if>
175
+      <if test="signInCode != null" >
176
+        #{signInCode,jdbcType=VARCHAR},
177
+      </if>
170
     </trim>
178
     </trim>
171
   </insert>
179
   </insert>
172
   <update id="updateByPrimaryKeySelective" parameterType="com.community.huiju.model.TpActivity" >
180
   <update id="updateByPrimaryKeySelective" parameterType="com.community.huiju.model.TpActivity" >
223
       <if test="updateDate != null" >
231
       <if test="updateDate != null" >
224
         update_date = #{updateDate,jdbcType=TIMESTAMP},
232
         update_date = #{updateDate,jdbcType=TIMESTAMP},
225
       </if>
233
       </if>
234
+      <if test="signInCode != null" >
235
+        sign_in_code = #{signInCode,jdbcType=VARCHAR}
236
+      </if>
226
     </set>
237
     </set>
227
     where id = #{id,jdbcType=INTEGER}
238
     where id = #{id,jdbcType=INTEGER}
228
   </update>
239
   </update>
244
       create_user = #{createUser,jdbcType=INTEGER},
255
       create_user = #{createUser,jdbcType=INTEGER},
245
       create_date = #{createDate,jdbcType=TIMESTAMP},
256
       create_date = #{createDate,jdbcType=TIMESTAMP},
246
       update_user = #{updateUser,jdbcType=INTEGER},
257
       update_user = #{updateUser,jdbcType=INTEGER},
247
-      update_date = #{updateDate,jdbcType=TIMESTAMP}
258
+      update_date = #{updateDate,jdbcType=TIMESTAMP},
259
+      sign_in_code = #{signInCode,jdbcType=VARCHAR}
248
     where id = #{id,jdbcType=INTEGER}
260
     where id = #{id,jdbcType=INTEGER}
249
   </update>
261
   </update>
250
 
262
 
290
     AND tr.community_id =#{communityId}
302
     AND tr.community_id =#{communityId}
291
     order by a.create_date desc
303
     order by a.create_date desc
292
   </select>
304
   </select>
305
+  <select id="selectActivity" resultMap="BaseResultMap">
306
+    select * from tp_activity where id = #{activityId}
307
+  </select>
293
 </mapper>
308
 </mapper>

+ 10
- 0
CODE/smart-community/app-api/src/main/resources/mapper/TpActivitySignInMapper.xml View File

149
     and ta_user_id = #{userID,jdbcType=INTEGER}
149
     and ta_user_id = #{userID,jdbcType=INTEGER}
150
   </select>
150
   </select>
151
 
151
 
152
+  <select id="toSignUp" resultMap="BaseResultMap">
153
+    select
154
+    <include refid="Base_Column_List" />
155
+    from
156
+    tp_activity_sign_in
157
+    where
158
+    activity_id = #{activityId,jdbcType=INTEGER}
159
+    and ta_user_id = #{userVerifyId,jdbcType=INTEGER}
160
+    and community_id = #{communityId,jdbcType=INTEGER}
161
+  </select>
152
 </mapper>
162
 </mapper>

+ 1
- 1
CODE/smart-community/property-api/src/main/java/com/community/huiju/service/impl/IndexCountServiceImpl.java View File

61
 		//获取收费组总缴费统计
61
 		//获取收费组总缴费统计
62
 		List<TpBillInvoiceCount> billInvoiceCountList = indexCountMapper.getBillInvoiceCountList(communityId);
62
 		List<TpBillInvoiceCount> billInvoiceCountList = indexCountMapper.getBillInvoiceCountList(communityId);
63
 		
63
 		
64
-		//获取月租车总续费统计
64
+			//获取月租车总续费统计
65
 		List<TaUserLicenseCount> taUserLicenseCountList = indexCountMapper.getUserLicenseCountList(communityId);
65
 		List<TaUserLicenseCount> taUserLicenseCountList = indexCountMapper.getUserLicenseCountList(communityId);
66
 		
66
 		
67
 		//获取临时车总缴费统计
67
 		//获取临时车总缴费统计

+ 2
- 2
VUECODE/smart-operate-manage/src/views/login/index.vue View File

6
         :model="loginForm"
6
         :model="loginForm"
7
         :rules="loginRules"
7
         :rules="loginRules"
8
         class="login-form"
8
         class="login-form"
9
-        auto-complete="on"
9
+        auto-complete="off"
10
         label-position="left"
10
         label-position="left"
11
       >
11
       >
12
         <div class="logo">
12
         <div class="logo">
23
             v-model="loginForm.username"
23
             v-model="loginForm.username"
24
             name="username"
24
             name="username"
25
             type="text"
25
             type="text"
26
-            auto-complete="on"
26
+            auto-complete="off"
27
             placeholder="请输入手机号"
27
             placeholder="请输入手机号"
28
           />
28
           />
29
         </el-form-item>
29
         </el-form-item>

+ 7
- 4
VUECODE/smart-property-manage/src/views/grogshop/configindex.vue View File

48
       <el-form-item label="酒店地址" prop="hotelAddress">
48
       <el-form-item label="酒店地址" prop="hotelAddress">
49
         <el-input v-model="listData.hotelAddress"/>
49
         <el-input v-model="listData.hotelAddress"/>
50
       </el-form-item>
50
       </el-form-item>
51
-      <el-form-item label="地图定位">
51
+      <el-form-item label="地图定位" prop="hotelLatitude">
52
         <span  style="font-size:14px;color:#C0C0C0">在地图上搜索选择酒店位置确定坐标值,供APP端用户导航</span>
52
         <span  style="font-size:14px;color:#C0C0C0">在地图上搜索选择酒店位置确定坐标值,供APP端用户导航</span>
53
         <span>高德坐标</span>
53
         <span>高德坐标</span>
54
         <el-input placeholder="经度" v-model="listData.hotelLongitude" style="width: 100px;" />
54
         <el-input placeholder="经度" v-model="listData.hotelLongitude" style="width: 100px;" />
124
           { required: true, message: '请输入联系电话', trigger: 'blur' }
124
           { required: true, message: '请输入联系电话', trigger: 'blur' }
125
         ],
125
         ],
126
         appIndexImg: [
126
         appIndexImg: [
127
-          { required: true, message: 'app列表展示图', trigger: 'blur' }
127
+          { required: true, message: '请上传app列表展示图', trigger: 'blur' }
128
         ],
128
         ],
129
         hotelName: [
129
         hotelName: [
130
-          { required: true, message: '酒店名称', trigger: 'blur' }
130
+          { required: true, message: '请输入酒店名称', trigger: 'blur' }
131
         ],
131
         ],
132
         hotelLatitude: [
132
         hotelLatitude: [
133
           { required: true, message: '请输入坐标', trigger: 'blur' }
133
           { required: true, message: '请输入坐标', trigger: 'blur' }
134
         ],
134
         ],
135
         hotelIntroduction: [
135
         hotelIntroduction: [
136
-          { required: true, message: '酒店介绍不能为空', trigger: 'change' }
136
+          { required: true, message: '请输入酒店介绍', trigger: 'change' }
137
         ],
137
         ],
138
+        appCarouselImg: [
139
+          { required: true, message: '请上传酒店banner图', trigger: 'blur' }
140
+        ]
138
       }
141
       }
139
     }
142
     }
140
   },
143
   },

+ 47
- 40
VUECODE/smart-property-manage/src/views/grogshop/grogshopRoomAdd.vue View File

1
 <template>
1
 <template>
2
   <div id="root">
2
   <div id="root">
3
-    <el-form ref="ruleForm" :model="ruleForm"  :rules="rules" label-width="100px" class="demo-ruleForm">
3
+    <el-form ref="ruleForm" :model="ruleForm" :rules="rules" label-width="100px" class="demo-ruleForm">
4
       <el-form-item label="房型名称" prop="roomName">
4
       <el-form-item label="房型名称" prop="roomName">
5
         <el-input v-model="ruleForm.roomName" placeholder="房型名称"/>
5
         <el-input v-model="ruleForm.roomName" placeholder="房型名称"/>
6
       </el-form-item>
6
       </el-form-item>
7
-       <!-- <el-form-item label="房型号" prop="roomNo">
7
+      <!-- <el-form-item label="房型号" prop="roomNo">
8
         <el-input v-model="ruleForm.roomNo" placeholder="房型号"/>
8
         <el-input v-model="ruleForm.roomNo" placeholder="房型号"/>
9
       </el-form-item> -->
9
       </el-form-item> -->
10
-     <el-form-item class="filter-item" label="房型短描述" prop="remark" >
10
+      <el-form-item class="filter-item" label="房型短描述" prop="remark" >
11
         <el-input v-model.trim="ruleForm.remark" placeholder="房型推荐语等"/>
11
         <el-input v-model.trim="ruleForm.remark" placeholder="房型推荐语等"/>
12
       </el-form-item>
12
       </el-form-item>
13
       <el-form-item label="房型价格" prop="price">
13
       <el-form-item label="房型价格" prop="price">
14
         <el-input v-model="ruleForm.price" placeholder="单位元" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
14
         <el-input v-model="ruleForm.price" placeholder="单位元" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
15
       </el-form-item>
15
       </el-form-item>
16
-      <el-form-item class="filter-item"  label="上架状态" prop="roomStatus">
16
+      <el-form-item class="filter-item" label="上架状态" prop="roomStatus">
17
         <el-select v-model="ruleForm.roomStatus" placeholder="上架">
17
         <el-select v-model="ruleForm.roomStatus" placeholder="上架">
18
-         <el-option label="上架" value="1"/>
19
-         <el-option label="下架" value="2"/>
18
+          <el-option label="上架" value="1"/>
19
+          <el-option label="下架" value="2"/>
20
         </el-select>
20
         </el-select>
21
       </el-form-item>
21
       </el-form-item>
22
       <el-form-item label="权重" prop="sort">
22
       <el-form-item label="权重" prop="sort">
23
         <el-input v-model="ruleForm.sort" placeholder="不小于0的整数" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
23
         <el-input v-model="ruleForm.sort" placeholder="不小于0的整数" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
24
-      </el-form-item>  
24
+      </el-form-item>
25
       <el-form-item>
25
       <el-form-item>
26
-        <el-button type="primary" @click="submitForm()">保存</el-button>
26
+        <el-button type="primary" @click="submitForm('ruleForm')">保存</el-button>
27
       </el-form-item>
27
       </el-form-item>
28
     </el-form>
28
     </el-form>
29
   </div>
29
   </div>
34
   data() {
34
   data() {
35
     return {
35
     return {
36
       ruleForm: {
36
       ruleForm: {
37
-            price: '',
38
-           remark: '',
39
-         roomName: '',
40
-       roomStatus: '',
41
-             sort: '1',
42
-           roomNo: ''
37
+        price: '',
38
+        remark: '',
39
+        roomName: '',
40
+        roomStatus: '1',
41
+        sort: '1',
42
+        roomNo: ''
43
       },
43
       },
44
       rules: {
44
       rules: {
45
         roomName: [
45
         roomName: [
53
         ],
53
         ],
54
         roomStatus: [
54
         roomStatus: [
55
           { required: true, message: '请选择状态', trigger: 'blur' }
55
           { required: true, message: '请选择状态', trigger: 'blur' }
56
-        ],         
56
+        ]
57
       }
57
       }
58
     }
58
     }
59
   },
59
   },
60
   mounted() {
60
   mounted() {
61
   },
61
   },
62
   methods: {
62
   methods: {
63
-    submitForm(){
64
-      if(this.ruleForm.roomName ===''){
65
-        this.$message.error('请输入房型名称');
66
-        return
67
-      }
68
-      if(this.ruleForm.price ===''){
69
-        this.$message.error('请输入房型价格');
70
-        return
71
-      }
72
-      if(this.ruleForm.roomStatus === ''){
73
-        this.ruleForm.roomStatus = '1'
74
-      }
75
-    
76
-      this.$store.dispatch('HotelRoomAdd', this.ruleForm).then((res) => {
77
-        if(res.code === '1'){
78
-          this.$message.error(res.message);
79
-        }else{
80
-        this.$router.push({ name: 'grogshop-grogshopRoom' })
81
-         this.$message({
82
-          message: '新增房型成功',
83
-          type: 'success'
84
-         })
63
+    submitForm(ruleForm) {
64
+      this.$refs[ruleForm].validate((valid) => {
65
+        if (valid) {
66
+          if (this.ruleForm.roomName === '') {
67
+            this.$message.error('请输入房型名称')
68
+            return
69
+          }
70
+          if (this.ruleForm.price === '') {
71
+            this.$message.error('请输入房型价格')
72
+            return
73
+          }
74
+          if (this.ruleForm.roomStatus === '') {
75
+            this.ruleForm.roomStatus = '1'
76
+          }
77
+
78
+          this.$store.dispatch('HotelRoomAdd', this.ruleForm).then((res) => {
79
+            if (res.code === '1') {
80
+              this.$message.error(res.message)
81
+            } else {
82
+              this.$router.push({ name: 'grogshop-grogshopRoom' })
83
+              this.$message({
84
+                message: '新增房型成功',
85
+                type: 'success'
86
+              })
87
+            }
88
+          }).catch(() => {
89
+            console.log('error HotelRoom')
90
+          })
91
+        } else {
92
+          console.log('error submit!!')
93
+          return false
85
         }
94
         }
86
-      }).catch(() => {
87
-        console.log('error HotelRoom')
88
       })
95
       })
89
     }
96
     }
90
-   }
91
   }
97
   }
98
+}
92
 </script>
99
 </script>
93
 
100
 
94
 <style scoped>
101
 <style scoped>

+ 55
- 49
VUECODE/smart-property-manage/src/views/grogshop/grogshopRoomEdit.vue View File

7
       <!-- <el-form-item label="房型号" >
7
       <!-- <el-form-item label="房型号" >
8
         <el-input v-model="ruleForm.roomNo" placeholder="房型号"/>
8
         <el-input v-model="ruleForm.roomNo" placeholder="房型号"/>
9
       </el-form-item> -->
9
       </el-form-item> -->
10
-     <el-form-item class="filter-item" label="房型短描述" prop="remark" >
10
+      <el-form-item class="filter-item" label="房型短描述" prop="remark" >
11
         <el-input v-model.trim="ruleForm.remark" placeholder="房型推荐语等"/>
11
         <el-input v-model.trim="ruleForm.remark" placeholder="房型推荐语等"/>
12
       </el-form-item>
12
       </el-form-item>
13
       <el-form-item label="房型价格" prop="price">
13
       <el-form-item label="房型价格" prop="price">
14
         <el-input v-model="ruleForm.price" placeholder="单位元" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
14
         <el-input v-model="ruleForm.price" placeholder="单位元" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
15
       </el-form-item>
15
       </el-form-item>
16
-      <el-form-item class="filter-item"  label="上架状态" prop="roomStatus">
16
+      <el-form-item class="filter-item" label="上架状态" prop="roomStatus">
17
         <el-select v-model="ruleForm.roomStatus" placeholder="上架">
17
         <el-select v-model="ruleForm.roomStatus" placeholder="上架">
18
-         <el-option label="上架" value="1"/>
19
-         <el-option label="下架" value="2"/>
18
+          <el-option label="上架" value="1"/>
19
+          <el-option label="下架" value="2"/>
20
         </el-select>
20
         </el-select>
21
       </el-form-item>
21
       </el-form-item>
22
       <el-form-item label="权重" prop="sort">
22
       <el-form-item label="权重" prop="sort">
23
         <el-input v-model="ruleForm.sort" placeholder="不小于0的整数" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
23
         <el-input v-model="ruleForm.sort" placeholder="不小于0的整数" onkeyup="this.value=this.value.replace(/\D/g,'')"/>
24
-      </el-form-item>  
24
+      </el-form-item>
25
       <el-form-item>
25
       <el-form-item>
26
-        <el-button type="primary" @click="submitForm()">保存</el-button>
26
+        <el-button type="primary" @click="submitForm('ruleForm')">保存</el-button>
27
       </el-form-item>
27
       </el-form-item>
28
     </el-form>
28
     </el-form>
29
   </div>
29
   </div>
34
   data() {
34
   data() {
35
     return {
35
     return {
36
       ruleForm: {
36
       ruleForm: {
37
-            id:'',
38
-            price: '',
39
-           remark: '',
40
-         roomName: '',
41
-       roomStatus: '',
42
-             sort: '',
43
-           roomNo: ''
37
+        id: '',
38
+        price: '',
39
+        remark: '',
40
+        roomName: '',
41
+        roomStatus: '1',
42
+        sort: '',
43
+        roomNo: ''
44
       },
44
       },
45
       rules: {
45
       rules: {
46
         roomName: [
46
         roomName: [
54
         ],
54
         ],
55
         roomStatus: [
55
         roomStatus: [
56
           { required: true, message: '请选择状态', trigger: 'blur' }
56
           { required: true, message: '请选择状态', trigger: 'blur' }
57
-        ],         
57
+        ]
58
       }
58
       }
59
     }
59
     }
60
   },
60
   },
62
     this.getRoom(this.$route.query.id)
62
     this.getRoom(this.$route.query.id)
63
   },
63
   },
64
   methods: {
64
   methods: {
65
-    submitForm(){
66
-      // if(this.ruleForm.roomNo ===''){
67
-      //   this.$message.error('请输入房型号');
68
-      //   return
69
-      // }
70
-      // if(this.ruleForm.roomName ===''){
71
-      //   this.$message.error('请输入房型名称');
72
-      //   return
73
-      // }
74
-      // if(this.ruleForm.price ===''){
75
-      //   this.$message.error('房型价格');
76
-      //   return
77
-      // }
78
-    
79
-      this.$store.dispatch('HotelRoomEdit', this.ruleForm).then((res) => {
80
-        if(res.code === '1'){
81
-          this.$message.error(res.message);
82
-        }else{
83
-        this.$router.push({ name: 'grogshop-grogshopRoom' })
84
-         this.$message({
85
-          message: '修改房型成功',
86
-          type: 'success'
87
-         })
65
+    submitForm(ruleForm) {
66
+      this.$refs[ruleForm].validate((valid) => {
67
+        if (valid) {
68
+          this.$store.dispatch('HotelRoomEdit', this.ruleForm).then((res) => {
69
+            // if (this.ruleForm.roomNo === '') {
70
+            //   this.$message.error('请输入房型号')
71
+            //   return
72
+            // }
73
+            // if (this.ruleForm.roomName === '') {
74
+            //   this.$message.error('请输入房型名称')
75
+            //   return
76
+            // }
77
+            // if (this.ruleForm.price === '') {
78
+            //   this.$message.error('房型价格')
79
+            //   return
80
+            // }
81
+            if (res.code === '1') {
82
+              this.$message.error(res.message)
83
+            } else {
84
+              this.$router.push({ name: 'grogshop-grogshopRoom' })
85
+              this.$message({
86
+                message: '修改房型成功',
87
+                type: 'success'
88
+              })
89
+            }
90
+          }).catch(() => {
91
+            console.log('error HotelRoom')
92
+          })
93
+        } else {
94
+          console.log('error submit!!')
95
+          return false
88
         }
96
         }
89
-      }).catch(() => {
90
-        console.log('error HotelRoom')
91
       })
97
       })
92
     },
98
     },
93
-    getRoom(id){
94
-      console.log('id',id)
99
+    getRoom(id) {
100
+      console.log('id', id)
95
       this.ruleForm.id = id
101
       this.ruleForm.id = id
96
-      console.log('this.ruleForm.id',this.ruleForm.id)
102
+      console.log('this.ruleForm.id', this.ruleForm.id)
97
       this.$store.dispatch('GetRoomId', this.ruleForm).then((res) => {
103
       this.$store.dispatch('GetRoomId', this.ruleForm).then((res) => {
98
-      this.ruleForm.roomName = res.data.roomName
99
-      this.ruleForm.roomNo = res.data.roomNo
100
-      this.ruleForm.roomStatus = res.data.roomStatus
101
-      this.ruleForm.sort = res.data.sort
102
-      this.ruleForm.remark = res.data.remark
103
-      this.ruleForm.price = res.data.price
104
+        this.ruleForm.roomName = res.data.roomName
105
+        this.ruleForm.roomNo = res.data.roomNo
106
+        this.ruleForm.roomStatus = res.data.roomStatus
107
+        this.ruleForm.sort = res.data.sort
108
+        this.ruleForm.remark = res.data.remark
109
+        this.ruleForm.price = res.data.price
104
       }).catch(() => {
110
       }).catch(() => {
105
         console.log('error GetRoomId')
111
         console.log('error GetRoomId')
106
       })
112
       })
107
     }
113
     }
108
-   }
109
   }
114
   }
115
+}
110
 </script>
116
 </script>
111
 
117
 
112
 <style scoped>
118
 <style scoped>

+ 6
- 5
VUECODE/smart-property-manage/src/views/login/index.vue View File

6
         :model="loginForm"
6
         :model="loginForm"
7
         :rules="loginRules"
7
         :rules="loginRules"
8
         class="login-form"
8
         class="login-form"
9
-        auto-complete="on"
9
+        auto-complete="off"
10
         label-position="left"
10
         label-position="left"
11
       >
11
       >
12
         <div class="logo">
12
         <div class="logo">
23
             v-model="loginForm.username"
23
             v-model="loginForm.username"
24
             name="username"
24
             name="username"
25
             type="text"
25
             type="text"
26
-            auto-complete="on"
26
+            auto-complete="off"
27
             placeholder="请输入手机号"
27
             placeholder="请输入手机号"
28
           />
28
           />
29
         </el-form-item>
29
         </el-form-item>
295
       color: $light_gray;
295
       color: $light_gray;
296
       height: 47px;
296
       height: 47px;
297
       &:-webkit-autofill {
297
       &:-webkit-autofill {
298
-        -webkit-box-shadow: 0 0 0px 1000px $bg inset !important;
299
-        -webkit-text-fill-color: #fff !important;
300
-      }
298
+         // -webkit-box-shadow: 0 0 0px 1000px $bg inset !important;
299
+         -webkit-box-shadow: 0 0 0px 1000px #1C223A inset !important;
300
+         -webkit-text-fill-color: #fff !important;
301
+       }
301
     }
302
     }
302
   }
303
   }
303
   .el-form-item {
304
   .el-form-item {

+ 4
- 3
VUECODE/smart-property-manage/src/views/social/activity/add/index.vue View File

5
         <el-input v-model="ruleForm.activityTitle" placeholder="20字以内" style="width: 620px;"/>
5
         <el-input v-model="ruleForm.activityTitle" placeholder="20字以内" style="width: 620px;"/>
6
       </el-form-item>
6
       </el-form-item>
7
       <el-form-item label="活动轮播图" prop="activityCarouselImg">
7
       <el-form-item label="活动轮播图" prop="activityCarouselImg">
8
+        <span style="color: darkgray;">轮播图为横幅位展示图片,不会显示在活动详情页</span>
8
         <div >
9
         <div >
9
           <el-upload
10
           <el-upload
10
             :show-file-list="false"
11
             :show-file-list="false"
42
       </el-form-item> -->
43
       </el-form-item> -->
43
       <el-form-item label="报名人数上限" prop="signUpMax">
44
       <el-form-item label="报名人数上限" prop="signUpMax">
44
         <div style="display: flex; width: 620px; justify-content: flex-end;">
45
         <div style="display: flex; width: 620px; justify-content: flex-end;">
45
-          <el-input v-model="ruleForm.signUpMax" style="width: 220px;" placeholder="填写0则不限制报名人数"/>
46
+          <el-input v-model="ruleForm.signUpMax" style="width: 220px;" placeholder="填写0则不限制报名人数" oninput="value=value.replace(/[^\d]/g,'')"/>
46
         </div>
47
         </div>
47
       </el-form-item>
48
       </el-form-item>
48
       <el-form-item label="报名截止时间" prop="registrationEndTime">
49
       <el-form-item label="报名截止时间" prop="registrationEndTime">
106
           { min: 1, max: 20, message: '长度在 20 个字符以内', trigger: 'blur' }
107
           { min: 1, max: 20, message: '长度在 20 个字符以内', trigger: 'blur' }
107
         ],
108
         ],
108
         activityContent: [
109
         activityContent: [
109
-          { required: true, message: '活动详细描述', trigger: 'blur' }
110
+          { required: true, message: '请输入活动详细描述', trigger: 'blur' }
110
         ],
111
         ],
111
         signUpMax: [
112
         signUpMax: [
112
           { required: true, message: '请输入报名人数上限', trigger: 'blur' }
113
           { required: true, message: '请输入报名人数上限', trigger: 'blur' }
113
         ],
114
         ],
114
         registrationEndTime: [
115
         registrationEndTime: [
115
-          { type: 'date', required: true, message: '报名截止时间', trigger: 'change' }
116
+          { type: 'date', required: true, message: '请选择报名截止时间', trigger: 'change' }
116
         ],
117
         ],
117
         sort: [
118
         sort: [
118
           { required: true, message: '请输入权重值', trigger: 'change' }
119
           { required: true, message: '请输入权重值', trigger: 'change' }

+ 4
- 3
VUECODE/smart-property-manage/src/views/social/activity/edi/index.vue View File

5
         <el-input v-model="ruleForm.activityTitle" placeholder="15字以内"/>
5
         <el-input v-model="ruleForm.activityTitle" placeholder="15字以内"/>
6
       </el-form-item>
6
       </el-form-item>
7
       <el-form-item label="活动轮播图" prop="activityCarouselImg">
7
       <el-form-item label="活动轮播图" prop="activityCarouselImg">
8
+        <span style="color: darkgray;">轮播图为横幅位展示图片,不会显示在活动详情页</span>
8
         <div >
9
         <div >
9
           <div style="width: 500px;">
10
           <div style="width: 500px;">
10
             <el-upload
11
             <el-upload
45
       </el-form-item> -->
46
       </el-form-item> -->
46
       <el-form-item label="报名人数上限" prop="signUpMax">
47
       <el-form-item label="报名人数上限" prop="signUpMax">
47
         <div style="display: flex; width: 620px; justify-content: flex-end;">
48
         <div style="display: flex; width: 620px; justify-content: flex-end;">
48
-          <el-input v-model="ruleForm.signUpMax" style="width: 220px;" placeholder="填写0则不限制报名人数"/>
49
+          <el-input v-model="ruleForm.signUpMax" style="width: 220px;" placeholder="填写0则不限制报名人数" oninput="value=value.replace(/[^\d]/g,'')"/>
49
         </div>
50
         </div>
50
       </el-form-item>
51
       </el-form-item>
51
       <el-form-item label="报名截止时间" prop="registrationEndTime">
52
       <el-form-item label="报名截止时间" prop="registrationEndTime">
111
           { min: 1, max: 15, message: '长度在 15 个字符以内', trigger: 'blur' }
112
           { min: 1, max: 15, message: '长度在 15 个字符以内', trigger: 'blur' }
112
         ],
113
         ],
113
         activityContent: [
114
         activityContent: [
114
-          { required: true, message: '活动详细描述', trigger: 'blur' }
115
+          { required: true, message: '请输入活动详细描述', trigger: 'blur' }
115
         ],
116
         ],
116
         signUpMax: [
117
         signUpMax: [
117
           { required: true, message: '请输入报名人数上限', trigger: 'blur' }
118
           { required: true, message: '请输入报名人数上限', trigger: 'blur' }
118
         ],
119
         ],
119
         registrationEndTime: [
120
         registrationEndTime: [
120
-          { type: 'date', required: true, message: '报名截止时间', trigger: 'change' }
121
+          { type: 'date', required: true, message: '请选择报名截止时间', trigger: 'change' }
121
         ],
122
         ],
122
         sort: [
123
         sort: [
123
           { required: true, message: '请输入权重值', trigger: 'change' }
124
           { required: true, message: '请输入权重值', trigger: 'change' }

+ 100
- 84
VUECODE/smart-property-manage/src/views/social/activity/info/index.vue View File

1
 <template>
1
 <template>
2
   <div id="root">
2
   <div id="root">
3
-    <div>活动标题&nbsp;&nbsp;<span style="padding-left:4%">{{ ruleForm.activityTitle }}</span></div>
4
-    <div >
5
-        <div class="activityTile" style="transform:translateY(250%);">活动轮播图</div>
6
-        <div  style="width: 500px;padding-left:14.3%;">
7
-    <img :src="ruleForm.activityCarouselImg" width="150" height="150">
8
-    </div>
9
-    </div>
10
-    <span style="transform:translateY(200%)">活动详情描述&nbsp;&nbsp;</span>
11
-    <div style="padding-left:14.3%" v-html="ruleForm.activityContent"></div>
3
+    <el-form ref="ruleForm" :model="ruleForm" :rules="rules" label-position="left" label-width="180px" class="ruleForm">
4
+      <el-form-item label="活动标题">
5
+        <span>{{ ruleForm.activityTitle }}</span>
6
+      </el-form-item>
7
+      <el-form-item label="活动轮播图">
8
+        <span style="color: darkgray;">轮播图为横幅位展示图片,不会显示在活动详情页</span>
9
+        <div>
10
+          <div style="width: 500px;">
11
+            <img :src="ruleForm.activityCarouselImg" width="150" height="150">
12
+          </div>
13
+        </div>
14
+      </el-form-item>
15
+      <el-form-item label="活动详情描述">
16
+        <div v-html="ruleForm.activityContent"/>
17
+      </el-form-item>
18
+      <el-form-item label="是否需要报名人扫码签到">
19
+        <el-radio v-model="ruleForm.signInCode" disabled label="1" style="font-weight:bold;font-size:12px;">需要</el-radio>
20
+        <el-radio v-model="ruleForm.signInCode" disabled label="2" style="font-weight:bold;font-size:12px;">不需要</el-radio>
21
+        <span style="padding-left:20%"><el-button type="primary" @click="singn">查看签到名单</el-button></span>
22
+      </el-form-item>
23
+      <span>
24
+        <div style="width: 500px; margin-top: 20px;">
25
+          <span style="color: darkgray;">选择扫码签到,活动发布后点击活动详情可以下载二维码图片,打印图片放置到活动现场,参加活动的用户即可扫码签到,方便统计活动实际参与人数。</span>
26
+        </div>
27
+        <div v-if="ruleForm.activityCode !=null" style="padding-left:30%;">
28
+          <div><img :src="qrcode" width="200" height="200" ></div>
29
+          <a :href="qrcode" download="qrcode.jpg" style="color:#00BFFF;padding-left:15%">点击下载</a>
30
+        </div>
31
+      </span>
32
+      <el-form-item label="报名截止时间">
33
+        <span class="activityTile">{{ formatDate(ruleForm.registrationEndTime) }}</span>
34
+      </el-form-item>
35
+      <div class="progress">
36
+        <div class="text-progress">
37
+          <span class="people-number">已报名人数 {{ ruleForm.signUpCount }}</span>
38
+          <div class="outer-layer"/>
39
+          <div ref="innerDiv" :style="{ backgroundColor: 'aquamarine', height: '6px', width: innerW + 'px', position: 'relative', marginTop: '-4px' }"/> <!-- class="inner-layer" -->
40
+        </div>
41
+        <div class="circular"/>
42
+        <div class="people-limit">限制{{ ruleForm.signUpMax }}人</div>
43
+        <el-button type="primary" style="float: left;" @click="lockSignUp">查看报名名单</el-button>
44
+      </div>
45
+      <el-form-item label="权重值">
46
+        <span>{{ ruleForm.sort }}</span>
47
+      </el-form-item>
48
+      <div style="width: 500px;">
49
+        <span style="color: darkgray;">权重值越大,在活动列表中排序越靠前,权重相同时按发布时间排序</span>
50
+      </div>
51
+    </el-form>
12
     <!-- <div>
52
     <!-- <div>
13
         <div>
53
         <div>
14
         <div style="transform:translateY(20%);">活动配图</div>
54
         <div style="transform:translateY(20%);">活动配图</div>
17
         </div>
57
         </div>
18
         </div>
58
         </div>
19
     </div> -->
59
     </div> -->
20
-    <span>
21
-    <div style="display: flex;">
22
-          <span class="activityTile" style="width: 200px;transform:translateY(70%);">是否需要报名人扫码签到</span>
23
-          <el-radio v-model="ruleForm.signInCode" disabled label="1" style="padding-left:4%;font-weight:bold;font-size:12px;transform:translateY(70%);">需要</el-radio>
24
-          <el-radio v-model="ruleForm.signInCode" disabled label="2" style="padding-left:8%;font-weight:bold;font-size:12px;transform:translateY(70%);">不需要</el-radio> 
25
-          <span style="padding-left:20%"><el-button type="primary" style="float:left;transform:translateY(30%)" @click="singn">查看签到名单</el-button></span> 
26
-    </div>
27
-    <div style="padding-left:30%;" v-if="ruleForm.activityCode !=null">
28
-        <div><img :src="qrcode" width="200" height="200" ></div>
29
-        <a :href="qrcode" download="qrcode.jpg"  style="color:#00BFFF;padding-left:15%">点击下载</a>
30
-    </div>
31
-    </span>
32
-    <div class="progress">
33
-      <div class="text-progress">
34
-        <span class="people-number">已报名人数 {{ ruleForm.signUpCount }}</span>
35
-        <div class="outer-layer"/>
36
-        <div ref="innerDiv" :style="{ backgroundColor: 'aquamarine', height: '6px', width: innerW + 'px', position: 'relative', marginTop: '-4px' }"/> <!-- class="inner-layer" -->
37
-      </div>
38
-      <div class="circular"/>
39
-      <div class="people-limit">限制{{ ruleForm.signUpMax }}人</div>
40
-      <el-button type="primary" style="float: left;" @click="lockSignUp">查看报名名单</el-button>
41
-    </div>
42
-    <span class="activityTile">报名截止时间:{{ formatDate(ruleForm.registrationEndTime) }}</span>
43
-    <span class="activityTile" style="transform:translateY(150%);">权重值&emsp;&emsp;&emsp;&emsp;{{ ruleForm.sort }}</span>
60
+
44
     <div class="bom-button">
61
     <div class="bom-button">
45
       <el-button v-if="isEdi" type="primary" style="width: 100px;" @click="ediActivity">修改</el-button>
62
       <el-button v-if="isEdi" type="primary" style="width: 100px;" @click="ediActivity">修改</el-button>
46
     </div>
63
     </div>
48
 </template>
65
 </template>
49
 
66
 
50
 <script>
67
 <script>
51
-import html2canvas from 'html2canvas';
52
-import QRCode from 'qrcode';
53
-import Wangeditor from '@/components/Wangeditor';
68
+import html2canvas from 'html2canvas'
69
+import QRCode from 'qrcode'
70
+import Wangeditor from '@/components/Wangeditor'
54
 export default {
71
 export default {
55
   name: 'Index',
72
   name: 'Index',
56
   components: { Wangeditor },
73
   components: { Wangeditor },
75
       ownerDocument: '',
92
       ownerDocument: '',
76
       isEdi: true, // 显示修改按钮
93
       isEdi: true, // 显示修改按钮
77
       innerW: 0, // 进度条
94
       innerW: 0, // 进度条
78
-      qrcode: '',
95
+      qrcode: ''
79
     }
96
     }
80
   },
97
   },
81
   mounted() {
98
   mounted() {
87
       this.$store.dispatch('ActivityById', this.ruleForm.id).then((res) => {
104
       this.$store.dispatch('ActivityById', this.ruleForm.id).then((res) => {
88
         const resData = res.data
105
         const resData = res.data
89
         this.ruleForm = resData.info
106
         this.ruleForm = resData.info
90
-        this.codeIMG =resData.info.activityCode
107
+        this.codeIMG = resData.info.activityCode
91
         this.ruleForm.contentImg = resData.contentImg
108
         this.ruleForm.contentImg = resData.contentImg
92
 
109
 
93
-        QRCode.toDataURL(this.codeIMG, (err, url)=> {
110
+        QRCode.toDataURL(this.codeIMG, (err, url) => {
94
           this.qrcode = url
111
           this.qrcode = url
95
         })
112
         })
96
         if (this.ruleForm.status === '0') {
113
         if (this.ruleForm.status === '0') {
115
     lockSignUp() { // 查看活动报名
132
     lockSignUp() { // 查看活动报名
116
       this.$router.push({ name: 'signUp-info', query: { id: this.ruleForm.id }})
133
       this.$router.push({ name: 'signUp-info', query: { id: this.ruleForm.id }})
117
     },
134
     },
118
-    //跳转签到页面
119
-    singn(){
135
+    // 跳转签到页面
136
+    singn() {
120
       this.$router.push({ name: 'activity-signIn-index', query: { id: this.ruleForm.id }})
137
       this.$router.push({ name: 'activity-signIn-index', query: { id: this.ruleForm.id }})
121
     },
138
     },
122
     // 下载图片
139
     // 下载图片
123
-//      downloadCodeImg(){
124
-//       var a = document.createElement('a')
125
-//       a.download = this.ruleForm.activityCode
126
-//        // 设置图片地址
127
-//       a.href = this.ruleForm.activityCode
128
-//       a.click();
129
-//     }
130
-   downloadCodeImg(){
131
-  var alink = document.createElement("a");
132
-  alink.href = this.ruleForm.activityCode;
133
-  alink.download = "pic"; //图片名
134
-  alink.click();
135
-  },
140
+    //      downloadCodeImg(){
141
+    //       var a = document.createElement('a')
142
+    //       a.download = this.ruleForm.activityCode
143
+    //        // 设置图片地址
144
+    //       a.href = this.ruleForm.activityCode
145
+    //       a.click();
146
+    //     }
147
+    downloadCodeImg() {
148
+      var alink = document.createElement('a')
149
+      alink.href = this.ruleForm.activityCode
150
+      alink.download = 'pic' // 图片名
151
+      alink.click()
152
+    },
136
 
153
 
137
-   dataURLToBlob(dataurl) {//ie 图片转格式
138
-          var arr = dataurl.split(','), mime = arr[0].match(/:(.*?);/)[1],
139
-            bstr = atob(arr[1]), n = bstr.length, u8arr = new Uint8Array(n);
154
+    dataURLToBlob(dataurl) { // ie 图片转格式
155
+      var arr = dataurl.split(','), mime = arr[0].match(/:(.*?);/)[1],
156
+        bstr = atob(arr[1]), n = bstr.length, u8arr = new Uint8Array(n)
157
+      while (n--) {
158
+        u8arr[n] = bstr.charCodeAt(n)
159
+      }
160
+      return new Blob([u8arr], { type: mime })
161
+    },
162
+
163
+    downloadResult() {
164
+      html2canvas(document.getElementById('mymap')).then(canvas => {
165
+        this.imgmap = canvas.toDataURL()
166
+        console.log(999, this.imgmap)
167
+        if (window.navigator.msSaveOrOpenBlob) {
168
+          var bstr = atob(this.imgmap.split(',')[1])
169
+          var n = bstr.length
170
+          var u8arr = new Uint8Array(n)
140
           while (n--) {
171
           while (n--) {
141
-            u8arr[n] = bstr.charCodeAt(n);
172
+            u8arr[n] = bstr.charCodeAt(n)
142
           }
173
           }
143
-          return new Blob([u8arr], {type: mime})
144
-        },
145
-        
146
-        downloadResult() {
147
-          html2canvas(document.getElementById('mymap')).then(canvas => {
148
-				this.imgmap = canvas.toDataURL()
149
-				console.log(999, this.imgmap)
150
-				if (window.navigator.msSaveOrOpenBlob) {
151
-					var bstr = atob(this.imgmap.split(',')[1])
152
-					var n = bstr.length
153
-					var u8arr = new Uint8Array(n)
154
-					while (n--) {
155
-						u8arr[n] = bstr.charCodeAt(n)
156
-					}
157
-					var blob = new Blob([u8arr])
158
-					window.navigator.msSaveOrOpenBlob(blob, 'chart-download' + '.' + 'png')
159
-				} else {
160
-					// 这里就按照chrome等新版浏览器来处理
161
-					const a = document.createElement('a')
162
-					a.href = this.imgmap
163
-					a.setAttribute('download', 'chart-download')
164
-					a.click()
165
-				}
166
- 
167
-			});
174
+          var blob = new Blob([u8arr])
175
+          window.navigator.msSaveOrOpenBlob(blob, 'chart-download' + '.' + 'png')
176
+        } else {
177
+          // 这里就按照chrome等新版浏览器来处理
178
+          const a = document.createElement('a')
179
+          a.href = this.imgmap
180
+          a.setAttribute('download', 'chart-download')
181
+          a.click()
168
         }
182
         }
169
-}
183
+      })
184
+    }
170
   }
185
   }
186
+}
171
 </script>
187
 </script>
172
 
188
 
173
 <style scoped>
189
 <style scoped>

+ 1
- 1
VUECODE/smart-property-manage/src/views/social/announcement/add.vue View File

83
           { min: 1, max: 20, message: '长度在 20 个字符以内', trigger: 'blur' }
83
           { min: 1, max: 20, message: '长度在 20 个字符以内', trigger: 'blur' }
84
         ],
84
         ],
85
         announcementContent: [
85
         announcementContent: [
86
-          { required: true, message: '公告内容描述', trigger: 'blur' }
86
+          { required: true, message: '请输入公告内容描述', trigger: 'blur' }
87
         ],
87
         ],
88
         sort: [
88
         sort: [
89
           { required: true, message: '请输入权重值', trigger: 'change' }
89
           { required: true, message: '请输入权重值', trigger: 'change' }

+ 10
- 13
VUECODE/smart-property-manage/src/views/social/announcement/details.vue View File

1
 <template>
1
 <template>
2
   <div id="root">
2
   <div id="root">
3
     <el-form ref="form" label-width="100px" label-position="left">
3
     <el-form ref="form" label-width="100px" label-position="left">
4
-      <el-form-item>
5
-        <div>公告标题&nbsp;&nbsp;<span style="width: 80%;padding-left:3.5%;">{{ ruleForm.announcementTitle }} </span></div>
4
+      <el-form-item label="公告标题">
5
+        <span style="width: 80%;">{{ ruleForm.announcementTitle }} </span>
6
         <!-- <span class="activityTile">{{ ruleForm.announcementTitle }}</span> -->
6
         <!-- <span class="activityTile">{{ ruleForm.announcementTitle }}</span> -->
7
       </el-form-item>
7
       </el-form-item>
8
-      <el-form-item>
9
-        <div style="transform:translateY(90%);">公告轮播图&nbsp;&nbsp;&nbsp;&nbsp;<span style="color: #99a9bf;">轮播图为横幅位展示图片,不会显示在公告详情页</span></div>
10
-        
8
+      <el-form-item label="公告轮播图">
9
+        <span style="color: #99a9bf;">轮播图为横幅位展示图片,不会显示在公告详情页</span>
11
         <br>
10
         <br>
12
-        <img :src="ruleForm.announcementCarouselImg"  width="320" height="150" style="padding-left:18%;transform:translateY(20%)">
11
+        <img :src="ruleForm.announcementCarouselImg" width="320" height="150">
13
       </el-form-item>
12
       </el-form-item>
14
-      <el-form-item>
15
-         <div>
16
-        <div style="transform:translateY(135%)">公告内容&nbsp;&nbsp;</div>
17
-        <div style="padding-left:18.3%" v-html=" ruleForm.announcementContent"></div>
18
-         </div>
19
-       
13
+      <el-form-item label="公告内容">
14
+        <div v-html=" ruleForm.announcementContent"/>
15
+      </el-form-item>
16
+      <el-form-item label="权重值">
17
+        <span>{{ ruleForm.sort }}</span>
20
       </el-form-item>
18
       </el-form-item>
21
-        <div style="padding-left:17%;transform:translateY(-20%)">权重值&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<el-input-number v-model="ruleForm.sort"/></div>
22
     </el-form>
19
     </el-form>
23
     <div class="bom-button">
20
     <div class="bom-button">
24
       <el-button v-if="isEdi" type="primary" style="width: 150px;" @click="edi">修改</el-button>
21
       <el-button v-if="isEdi" type="primary" style="width: 150px;" @click="edi">修改</el-button>

+ 1
- 1
VUECODE/smart-property-manage/src/views/social/announcement/edit.vue View File

81
           { min: 1, max: 20, message: '长度在 20 个字符以内', trigger: 'blur' }
81
           { min: 1, max: 20, message: '长度在 20 个字符以内', trigger: 'blur' }
82
         ],
82
         ],
83
         announcementContent: [
83
         announcementContent: [
84
-          { required: true, message: '公告内容描述', trigger: 'blur' }
84
+          { required: true, message: '请输入公告内容描述', trigger: 'blur' }
85
         ],
85
         ],
86
         sort: [
86
         sort: [
87
           { required: true, message: '请输入权重值', trigger: 'change' }
87
           { required: true, message: '请输入权重值', trigger: 'change' }

+ 4
- 4
VUECODE/smart-property-manage/src/views/ticket/details.vue View File

73
       </table>  -->
73
       </table>  -->
74
       </div>
74
       </div>
75
 
75
 
76
-      <div style="padding-left:200px;">
76
+      <div style="padding-left:82px;">
77
         <template >
77
         <template >
78
           <img v-for="sr in listQuery.contentImageUrl" :src="sr" preview width="200" height="200" style="margin:5px;">
78
           <img v-for="sr in listQuery.contentImageUrl" :src="sr" preview width="200" height="200" style="margin:5px;">
79
           <!-- <img v-for="sr in listQuery.contentImageUrl" :src="sr" preview="ss" preview-text="ss" width="200" height="200"> -->
79
           <!-- <img v-for="sr in listQuery.contentImageUrl" :src="sr" preview="ss" preview-text="ss" width="200" height="200"> -->
154
             <el-button type="primary" style="margin-left: 90%;transform:translateY(-340%);" @click="submitContent">提交</el-button>
154
             <el-button type="primary" style="margin-left: 90%;transform:translateY(-340%);" @click="submitContent">提交</el-button>
155
           </div>
155
           </div>
156
         </div>
156
         </div>
157
-        <div v-if="listQuery.status==='3'" style="margin-left: -5px;">
157
+        <div v-if="listQuery.status==='3' || listQuery.status==='0'" style="margin-left: -5px;">
158
           <div>
158
           <div>
159
             <span style="font-size: 16px;color: rgb(96, 98, 102);font-weight: bold;">流程操作</span>
159
             <span style="font-size: 16px;color: rgb(96, 98, 102);font-weight: bold;">流程操作</span>
160
           </div>
160
           </div>
161
           <br>
161
           <br>
162
-          <div>
162
+          <div v-if="listQuery.status==='3'">
163
             <textarea id="message_textarea" v-model="listQuery.relationContent" placeholder="处理完了?在此填写处理结果,发送给户主让TA给好评~" class="textarea-inherit" rows="4"/>
163
             <textarea id="message_textarea" v-model="listQuery.relationContent" placeholder="处理完了?在此填写处理结果,发送给户主让TA给好评~" class="textarea-inherit" rows="4"/>
164
           </div>
164
           </div>
165
-          <div style="margin-top: 10px;">
165
+          <div  v-if="listQuery.status==='3'" style="margin-top: 10px;">
166
             <el-form-item label="图片附件">
166
             <el-form-item label="图片附件">
167
               <el-upload
167
               <el-upload
168
                 :limit="8"
168
                 :limit="8"

+ 1
- 1
VUECODE/smart-property-manage/src/views/ticket/index.vue View File

43
       :data="listData"
43
       :data="listData"
44
       border
44
       border
45
       tooltip-effect="dark"
45
       tooltip-effect="dark"
46
-      style="width: 100%; margin-top: 20px;"
46
+      style="width: 100%; margin-top: 30px;"
47
       @selection-change="handleSelectionChange">
47
       @selection-change="handleSelectionChange">
48
       <el-table-column prop="id" label="编号" align="center"/>
48
       <el-table-column prop="id" label="编号" align="center"/>
49
       <el-table-column prop="type" label="类型" align="center">
49
       <el-table-column prop="type" label="类型" align="center">