MyFlag Step10:后台代码解耦与客户端具体功能设计
来源:互联网 发布:东北电力大学 知乎 编辑:程序博客网 时间:2024/06/05 00:41
引言
本周恰巧是开发周期的中期,我们按部就班有条不紊的按照原计划进行开发,这一阶段我们主要的任务有以下几个方面:
- DAO层的代码重写与解耦
- 评论功能+我的消息
我的主要功能工作就是与客户端的开发人员及时进行沟通并且进行页面调整,详细状况如下:
评论功能+我的消息
1、评价界面可以让监督flag的好友们对flag进行评价,包括是否完成以及评语,
xml文件如下:
<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"android:layout_width="match_parent"android:layout_height="match_parent"android:orientation="vertical"><RelativeLayout android:layout_width="match_parent" android:layout_height="?attr/actionBarSize" android:background="@color/white" android:padding="0dp"> <ImageButton android:layout_width="?attr/actionBarSize" android:layout_height="?attr/actionBarSize" android:layout_alignParentLeft="true" android:background="@drawable/toolbar_back_bg" android:onClick="CommentBack" android:src="?attr/homeAsUpIndicator" /> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerInParent="true" android:text="评论" android:textColor="@color/black" android:textSize="19sp" /></RelativeLayout><ListView android:id="@+id/comment_lv" android:layout_width="match_parent" android:layout_height="match_parent" /></LinearLayout>
视图:
我的好友消息的Activity为SuperViseJudgeActivity
这段代码是从服务器获取数据后的回掉函数,根据服务器返回的参数不同,进行不同的操作,如返回1,即评论成功,返回2即为已经评论过。
2、@我的消息界面:
@我的消息界面显示的是邀请我作为flag监督人的好友请求。
Xml代码如下:
<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"android:layout_width="match_parent"android:layout_height="match_parent"android:background="@color/activity_bg_gray"android:orientation="vertical"><RelativeLayout android:layout_width="match_parent" android:layout_height="?attr/actionBarSize" android:background="@color/white" android:padding="0dp"> <ImageButton android:layout_width="?attr/actionBarSize" android:layout_height="?attr/actionBarSize" android:layout_alignParentLeft="true" android:background="@drawable/toolbar_back_bg" android:onClick="myMessageSuperviseBack" android:src="?attr/homeAsUpIndicator" /> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerInParent="true" android:text="\@我的消息" android:textColor="@color/black" android:textSize="19sp" /></RelativeLayout><android.support.v4.widget.SwipeRefreshLayout android:id="@+id/supervise_swipe_layout" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_marginTop="20dp"> <ListView android:id="@+id/myMessageSuperViseListView" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_marginTop="20dp" android:background="@color/white" /></android.support.v4.widget.SwipeRefreshLayout></LinearLayout>
代码中包含一个SwipeRefreshLayout,用于刷新ListView,ListView中显示具体的消息,主视图与具体的item如下:
@我的消息界面Activity为SuperViseDetailActivity,功能:
在请求成功后,会取得服务器返回的每条数据信息,然后将每一条数据包装在bean中,传到listview的adapter中,从而可以创建每一个item视图,然后显示出来。
代码编写完后,我们进行了代码互测,针对不同的输入信息,设计了多组测试数据,然后在真机上对每一组数据进行实际测试,检查后台返回数据是否,直到这两个功能的测试都运行无误。
同时,我也进行着MenuPath的移植工作,但是还没筛选出具体选用的步骤。
总结
本周的工作中,与客户端设计人员沟通交流的状况进展不叫顺利,但是在我MenuPath的移植过程中出现了一些兼容性的问题,比较头疼,希望下一周能够解决。
阅读全文
0 0
- MyFlag Step10:后台代码解耦与客户端具体功能设计
- MyFlag Step10:后台代码解耦与客户端具体功能设计
- MyFlag Step10:后台代码解耦与客户端具体功能实现
- 第五周(2) 后台代码解耦与客户端具体功能设计
- MyFlag Step11:后台代码编写与客户端具体功能实现以及界面优化
- MyFlag Step11:后台代码编写、客户端具体功能实现与界面优化
- MyFlag Step12:后台代码编写、客户端具体功能实现与界面优化
- myflag step 13:后台代码编写、客户端具体功能实现与界面优化
- MyFlag Step12:后台代码编写、客户端具体功能实现以及界面优化
- MyFlag Step13:后台代码编写、客户端具体功能实现以及界面优化
- MyFlag Step14:后台代码编写、客户端具体功能实现以及界面优化
- myflag step10:flagdao的编写
- 第六周(1) 后台代码编写与客户端具体功能实现以及界面优化
- 第六周(2) 后台代码编写、客户端具体功能实现与界面优化
- 第七周(1) 后台代码编写、客户端具体功能实现与界面优化
- MyFlag Step 9:Flag相关的功能设计
- MyFlag Step5:app页面初步设计与代码编写
- MyFlag Step5:app页面初步设计与代码编写
- 什么是P问题、NP问题和NPC问题
- book_effective Python_59个有效办法(三)
- OSI模型和TCP模型
- 两个例子,搞懂原码,反码,补码
- 在Linux中创建静态库和动态库范例 (hello.c)
- MyFlag Step10:后台代码解耦与客户端具体功能设计
- Add to List 474. Ones and Zeroes(第十五周)
- Hibernate对象状态及方法详解
- Studio中运行报错Error:Execution failed for task ':app:transformClassesWithDexForDebug'原因和解决
- Php编程中最容易出现的错误有哪些?
- 深入理解AJAX系列第一篇--XMLHttpRequest对象
- 创建复选框按钮
- windows ——————SVN搭建
- 条件运算符和条件表达式