我和群众站一队-alpha冲刺第1日

我和群众站一队 2024-11-02 22:49:09

冲刺日记一:

这个作业属于哪个课程https://bbs.csdn.net/forums/2401_CS_SE_FZU
这个作业要求在哪里https://bbs.csdn.net/topics/619397949
这个作业的目标CodeArt团队实战总结
其他参考文献CSDN,博客园

目录

  • 冲刺日记一:
  • 一、项目进展
  • 二、存在的问题/遇到的困难及接下来的安排
  • 三、站立式会议照片
  • 四、今日完成度相关照片
  • 五、心得体会

一、项目进展

222200315张俊腾
进展一:完成了RescueInfo实体类的创建,并同步更新了数据库设计。

img

222200309孙阳

  • 完成项目的后端接口分工安排,安排每日会议时间

img

  • 更新数据库建表数据

img

  • 安排每日博客内容

img

  • 撰写团队代码规范、随笔

img

222200304卢君豪
进展一:HelpRequest(求助模块)entity的创建

package com.bafang.entity.entity_help;

        import jakarta.persistence.*;

        import java.time.LocalDateTime;

        @Entity
        @Table(name = "help_request")
        public class HelpRequest {
            @Id
            @GeneratedValue(strategy = GenerationType.IDENTITY)
            private Long id;

            @Column(nullable = false)
            private Long uid;

            @Column(nullable = false)
            private String location;

            @Column(nullable = false)
            private Integer type;

            @Column(name = "phone_number", nullable = false, length = 20)
            private String phoneNumber;

            @Column(name = "detailed_address")
            private String detailedAddress;

            @Column(name = "road_condition")
            private String roadCondition;

            @Column(name = "weather_condition")
            private String weatherCondition;

            @Column(name = "utilities_info")
            private String utilitiesInfo;

            @Column(name = "assistance_type", nullable = false)
            private Integer assistanceType;

            @Column(name = "supplies_needed")
            private String suppliesNeeded;

            @Column(nullable = false)
            private Integer status = 1;

            @Column(nullable = false)
            private String introduction;

            @Column(name = "audit_status", nullable = false)
            private Integer auditStatus = 0;

            @Column(name = "audited_by")
            private Long auditedBy;

            @Column(name = "audit_comment")
            private String auditComment;

            @Column(name = "created_at")
            private LocalDateTime createdAt;

            @Column(name = "updated_at")
            private LocalDateTime updatedAt;

            @Column(name = "audited_at")
            private LocalDateTime auditedAt;

            @Column(name = "deleted_at")
            private LocalDateTime deletedAt;

            @PrePersist
            protected void onCreate() {
                setCreatedAt(LocalDateTime.now());
                setUpdatedAt(LocalDateTime.now());
            }

            @PreUpdate
            protected void onUpdate() {
                setUpdatedAt(LocalDateTime.now());
            }

            public Long getId() {
                return id;
            }

            public void setId(Long id) {
                this.id = id;
            }

            public Long getUid() {
                return uid;
            }

            public void setUid(Long uid) {
                this.uid = uid;
            }

            public String getLocation() {
                return location;
            }

            public void setLocation(String location) {
                this.location = location;
            }

            public Integer getType() {
                return type;
            }

            public void setType(Integer type) {
                this.type = type;
            }

            public String getPhoneNumber() {
                return phoneNumber;
            }

            public void setPhoneNumber(String phoneNumber) {
                this.phoneNumber = phoneNumber;
            }

            public String getDetailedAddress() {
                return detailedAddress;
            }

            public void setDetailedAddress(String detailedAddress) {
                this.detailedAddress = detailedAddress;
            }

            public String getRoadCondition() {
                return roadCondition;
            }

            public void setRoadCondition(String roadCondition) {
                this.roadCondition = roadCondition;
            }

            public String getWeatherCondition() {
                return weatherCondition;
            }

            public void setWeatherCondition(String weatherCondition) {
                this.weatherCondition = weatherCondition;
            }

            public String getUtilitiesInfo() {
                return utilitiesInfo;
            }

            public void setUtilitiesInfo(String utilitiesInfo) {
                this.utilitiesInfo = utilitiesInfo;
            }

            public Integer getAssistanceType() {
                return assistanceType;
            }

            public void setAssistanceType(Integer assistanceType) {
                this.assistanceType = assistanceType;
            }

            public String getSuppliesNeeded() {
                return suppliesNeeded;
            }

            public void setSuppliesNeeded(String suppliesNeeded) {
                this.suppliesNeeded = suppliesNeeded;
            }

            public Integer getStatus() {
                return status;
            }

            public void setStatus(Integer status) {
                this.status = status;
            }

            public String getIntroduction() {
                return introduction;
            }

            public void setIntroduction(String introduction) {
                this.introduction = introduction;
            }

            public Integer getAuditStatus() {
                return auditStatus;
            }

            public void setAuditStatus(Integer auditStatus) {
                this.auditStatus = auditStatus;
            }

            public Long getAuditedBy() {
                return auditedBy;
            }

            public void setAuditedBy(Long auditedBy) {
                this.auditedBy = auditedBy;
            }

            public String getAuditComment() {
                return auditComment;
            }

            public void setAuditComment(String auditComment) {
                this.auditComment = auditComment;
            }

            public LocalDateTime getCreatedAt() {
                return createdAt;
            }

            public void setCreatedAt(LocalDateTime createdAt) {
                this.createdAt = createdAt;
            }

            public LocalDateTime getUpdatedAt() {
                return updatedAt;
            }

            public void setUpdatedAt(LocalDateTime updatedAt) {
                this.updatedAt = updatedAt;
            }

            public LocalDateTime getAuditedAt() {
                return auditedAt;
            }

            public void setAuditedAt(LocalDateTime auditedAt) {
                this.auditedAt = auditedAt;
            }

            public LocalDateTime getDeletedAt() {
                return deletedAt;
            }

            public void setDeletedAt(LocalDateTime deletedAt) {
                this.deletedAt = deletedAt;
            }
        }

进展二:HelpRequest(求助模块)repository的创建

package com.bafang.repository;

        import com.bafang.entity.entity_help.HelpRequest;
        import org.springframework.data.jpa.repository.JpaRepository;
        import org.springframework.stereotype.Repository;

        @Repository
        public interface HelpRequestRepository extends JpaRepository<HelpRequest, Long> {
        }

222200310李怡涵
进展一:entity的定义

package com.bafang.entity.entity_live;

import jakarta.persistence.*;

import java.time.LocalDateTime;

@Entity
@Table(name = "live_info")
public class Live {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @Column(nullable = false, unique = true)
    private Long uid;

    @Column(nullable = false, length = 255)
    private String location;

    @Column(name = "weather_condition", length = 255)
    private String weatherCondition;

    @Column(name = "road_condition", length = 255)
    private String roadCondition;

    @Column(name = "utilities_info", length = 255)
    private String utilitiesInfo;

    @Column
    private Integer level;

    @Column(nullable = false, length = 255)
    private String introduction;

    @Column(name = "audit_status", nullable = false)
    private Integer auditStatus = 0;

    @Column(name = "audited_by")
    private String auditedBy;

    @Column(name = "audit_comment")
    private String auditComment;

    @Column(name = "created_at")
    private LocalDateTime createdAt;

    @Column(name = "updated_at")
    private LocalDateTime updatedAt;

    @Column(name = "deleted_at")
    private LocalDateTime deletedAt;

    @Column(name = "audited_at")
    private LocalDateTime auditedAt;

    @PrePersist
    protected void onCreate() {
        setCreatedAt(LocalDateTime.now());
        setUpdatedAt(LocalDateTime.now());
    }

    @PreUpdate
    protected void onUpdate() {
        setUpdatedAt(LocalDateTime.now());
    }

    public Long getUid() {
        return uid;
    }

    public void setUid(Long uid) {
        this.uid = uid;
    }

    public String getLocation() {
        return location;
    }

    public void setLocation(String location) {
        this.location = location;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getWeatherCondition() {
        return weatherCondition;
    }

    public void setWeatherCondition(String weatherCondition) {
        this.weatherCondition = weatherCondition;
    }

    public String getUtilitiesInfo() {
        return utilitiesInfo;
    }

    public void setUtilitiesInfo(String utilitiesInfo) {
        this.utilitiesInfo = utilitiesInfo;
    }

    public String getRoadCondition() {
        return roadCondition;
    }

    public void setRoadCondition(String roadCondition) {
        this.roadCondition = roadCondition;
    }

    public Integer getLevel() {
        return level;
    }

    public void setLevel(Integer level) {
        this.level = level;
    }

    public String getIntroduction() {
        return introduction;
    }

    public void setIntroduction(String introduction) {
        this.introduction = introduction;
    }

    public Integer getAuditStatus() {
        return auditStatus;
    }

    public void setAuditStatus(Integer auditStatus) {
        this.auditStatus = auditStatus;
    }

    public String getAuditedBy() {
        return auditedBy;
    }

    public void setAuditedBy(String auditedBy) {
        this.auditedBy = auditedBy;
    }

    public LocalDateTime getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(LocalDateTime createdAt) {
        this.createdAt = createdAt;
    }

    public LocalDateTime getUpdatedAt() {
        return updatedAt;
    }

    public void setUpdatedAt(LocalDateTime updatedAt) {
        this.updatedAt = updatedAt;
    }

    public LocalDateTime getDeletedAt() {
        return deletedAt;
    }

    public void setDeletedAt(LocalDateTime deletedAt) {
        this.deletedAt = deletedAt;
    }

    public LocalDateTime getAuditedAt() {
        return auditedAt;
    }

    public void setAuditedAt(LocalDateTime auditedAt) {
        this.auditedAt = auditedAt;
    }

    public String getAuditComment() {
        return auditComment;
    }

    public void setAuditComment(String auditComment) {
        this.auditComment = auditComment;
    }

}

进展二:Controller内容框架

@GetMapping("/user")
    public ResultResponse<List<UserLiveRequst>> getUserLive(@RequestParam("uid") Long uid){
        return liveService.getUserLive(uid);
    }

    @GetMapping
    public ResultResponse<List<UserLiveRequst>> getNearbyLive(@RequestParam("location") String location){
        return liveService.getNearbyLive(location);
    }

进展三:Service内容框架

public ResultResponse<List<UserLiveRequst>> getUserLive(Long uid){
        List<UserLiveRequst> liveList = new ArrayList<UserLiveRequst>();
        /*
        ...
         */
        return new ResultResponse<>(200, "success", liveList);
    }

    public ResultResponse<List<UserLiveRequst>> getNearbyLive(String location){
        List<UserLiveRequst> liveList = new ArrayList<UserLiveRequst>();
        /*
        ...
         */
        return new ResultResponse<>(200, "success", liveList);
    }

222200311李梓玄
进展一:学习地图控件,初步设计定位流程

img

img

进展二:优化权限请求,使用 Accompanist 库优雅获取权限

img

222200328夏振
进展一:设计了管理模块功能之一:授予管理员权限
222200401丁昌彪
进展一: 完成了客户端注册、登录和登出功能
222200312杨年申
进展一:完成整个User模块框架的搭建

img

进展二:建立entity_User的表

 @Id // 代表这个变量是主键
            @GeneratedValue(strategy = GenerationType.IDENTITY)// 设置数据库自增主键
            private Long id;

            @Column(nullable = false, unique = true, length = 255)
            private String username;

            @Column(nullable = false, length = 255)
            private String password;

            @Column(name = "real_name", length = 255)
            private String realName;

            @Column(name = "id_number", length = 255)
            private String idNumber;

            @Column(name = "is_real_name_authentication", nullable = false)
            private Boolean isRealNameAuthentication = false;

            @Column(name = "phone_number", length = 20)
            private String phoneNumber;

            @Column(nullable = false)
            private Integer role = 1; // 1: 普通用户, 2: 管理员

            @Column(name = "created_at")
            private LocalDateTime createdAt;

            @Column(name = "updated_at")
            private LocalDateTime updatedAt;

            @Column(name = "deleted_at")
            private LocalDateTime deletedAt;

            @PrePersist
            protected void onCreate() {
                setCreatedAt(LocalDateTime.now());
                setUpdatedAt(LocalDateTime.now());
            }

            @PreUpdate
            protected void onUpdate() {
                setUpdatedAt(LocalDateTime.now());
            }

222200230梁蕴潆
进展一:编写冲刺博客
进展二:学习Vue框架

<!DOCTYPE html>
<html>
<head>
    <title>Vue.js 初学示例</title>
    <!-- 引入Vue.js -->
    <script src="https://cdn.jsdelivr.net/npm/vue@2.6.14/dist/vue.min.js"></script>
</head>
<body>
    <div id="app">
        <!-- 模板:显示数据和事件绑定 -->
        <h1>{{ message }}</h1>
        <button @click="reverseMessage">反转消息</button>
    </div>

    <script>
        // 创建一个新的Vue实例
        var app = new Vue({
            el: '#app', // 绑定到页面中的元素
            data: {
                message: 'Hello Vue!' // 数据模型
            },
            methods: {
                reverseMessage: function() {
                    this.message = this.message.split('').reverse().join('');
                }
            }
        });
    </script>
</body>
</html>

二、存在的问题/遇到的困难及接下来的安排

成员存在的问题/遇到的困难接下来的安排
222200315张俊腾遇到的问题:在映射实体类时,遇到字段注释不匹配问题。解答:重新审查了数据库字段与实体类字段的对应关系。

img

完成RescueInfoRepository接口的开发。
222200309孙阳问题、困难1:SQL表中对大小写不予区分,原本的驼峰式式命名失效。解答:全部更换为下划线式命名。问题、困难2 :后端返回给前端的数据中,类的属性中不能有下划线,前端序列化器报错。解答:返回数据中属性名全部改为驼峰式命名。问题、困难3:LocalDateTime的时间格式,在日期和具体时间之间默认加“T”进行分隔,影响界面显示。解答:使用formatter方法进行定义,对所有时间类的返回加以规范。补充汇总entity里的实体,规范所有上交的代码命名
222200304卢君豪学习token令牌相关知识,规划之后工作的安排
222200310李怡涵继续完善后端代码,实现获取用户实况接口
222200311李梓玄问题、困难1:高德地图控件使用。高德地图的SDK文档已经年久失修,甚至示例代码还是Java办法的,难以与 jetpack compose 结合- 解答:在寻找教程时找到一个与 jetpack compose 兼容的第三方库https://github.com/TheMelody/OmniMap-Compose - 问题、困难2 :按Android 官方要求,地图、定位等功能需要权限,但获取权限的API和activity密切相关,与 jetpack compose结合起来代码不优雅- 解答:使用 Accompanist 库优雅获取权限。文档:https://google.github.io/accompanist/permissions/完成「发布实况」「发起求助」的按钮及页面跳转,实现地图拖拽选点获取位置
222200328夏振华为云发电,用华为云账号+密码登录失败推送失败- 暂时先用SSH密钥接下来例如审核功能的设计和实现,并总结今天完成的内容
222200401丁昌彪-问题:没有注入viewMoel导致客户端闪退 -解决办法:开启调试模式,寻找闪退原因,找到后注入相应的viewModel1. 完成用户实名认证功能 2. 完成用户基本资料功能 3. 完成求助历史功能
222200312杨年申问题、困难1- - 无法连接到数据库,可能是由于数据库 URL、用户名或密码错误。- 解答- - 检查 application.properties 或 application.yml 中的数据库连接配置,确保 URL、用户名和密码正确无误。- 问题、困难2 - - 在创建 User 实体类时,映射到数据库表可能出现错误,例如字段名称不匹配。- 解答- - 使用 @Column 注解指定列名,确保映射正确安排实现一个接口logi
222200230梁蕴潆刚刚开始学习很多新概念不完全理解,询问组员后得以解决。继续学习Vue框架

三、站立式会议照片

img

四、今日完成度相关照片

成员相关图片
222200315张俊腾

img

222200309孙阳

img

222200304卢君豪

img

222200310李怡涵

img

222200311李梓玄

img

222200328夏振

img

222200401丁昌彪

img

222200312杨年申

img

222200230梁蕴潆

img

五、心得体会

成员心得体会
222200315张俊腾- 学会了如何处理复杂表结构,并处理字段不匹配问题。
222200309孙阳项目合理分工、规范实体命名是一个优秀项目良好的开端,统一好必要的内容虽然花费时间精力,但获益无穷,磨刀不误砍柴工
222200304卢君豪非常好的学习,使我合理安排
222200310李怡涵更加了解后端代码的运行逻辑,学习了关于JWT和一些命名规则的知识,提高了团队合作开发能力。
222200311李梓玄Android相对于别的技术,国内的教程偏少,质量也较低,而且Android技术更新很快,国内的中午教程大部分都以过失,所幸Android官方提供了较为详细的文档(当然,纯英文的)- Android确实把kotlin这一现代化的语言玩出花了,各种高级特性充斥着各个角落,对初学者不是很友好,需要花费大量时间理解。
222200328夏振感谢项目使我获得提升,谢谢
222200401丁昌彪编程是一个需要耐心的过程。遇到复杂的问题时,要冷静分析,分步解决,而不是急于求成。
222200312杨年申细节决定成败:数据库 URL、用户名和密码的拼写错误或格式不正确,往往会导致连接失败。保持对这些细节的高度关注,可以避免不必要的挫折。- 保持一致性:实体类的设计应与数据库表结构保持一致,避免日后因不一致而引发的复杂问题。在数据库设计阶段,考虑到未来的实体映射,可以提高开发效率。
222200230梁蕴潆多跟组员沟通,多问问题,能够减少不必要的麻烦。
...全文
156 回复 打赏 收藏 转发到动态 举报
写回复
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复

113

社区成员

发帖
与我相关
我的任务
社区描述
202401_CS_SE_FZU
软件工程 高校
社区管理员
  • FZU_SE_TeacherL
  • 助教_林日臻
  • 防震水泥
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧