该项目的部分截图如下:

 

1.基于学校大四毕业生,以及学校二手物品的利用的平台,学生可以发布自己的闲置物品。

2.该项目数据存储使用SQlite,进行数据的增删改查


3,该项目的功能:主页(最新发布商品的信息展示,第一时间知道发布什么新商品,搜索物品)、添加页面:发布自己的物品(主要描述一下商品的情况,价格,种类,联系方式)、种类页面:分为九大类物品(点击看每一类下面的物品)、个人:个人信息的预留,注册,登录,个人信息修改

4,项目代码(比较多贴了部分)

sqlite物品存储表:
public class TableGoods extends ATable { @Override String getTableName() {
return Contants.TB_TABLE_GOODS; } @Override String createTableSql() { return
"create table " + Contants.TB_TABLE_GOODS + "(" + Contants.TABLE_ID + " integer
primary key autoincrement," + Contants.USER_NAME + " text not null," +
Contants.GOODS_NAME + " text not null," + Contants.GOODS_PRICE + " text," +
Contants.GOODS_STYLE + " text," + Contants.GOODS_DESC + " text," +
Contants.GOODS_PHONE + " text," + Contants.GOODS_LEFT + " text," +
Contants.GOODS_RIGHT + " text," + ")"; } private GoodsBean
creatRowResult(Cursor cursor) { GoodsBean result = new GoodsBean();
result.setUsername(cursor.getString(cursor.getColumnIndex(Contants.USER_NAME)));
result.setGoodsname(cursor.getString(cursor.getColumnIndex(Contants.GOODS_NAME)));
result.setGoodsprice(cursor.getString(cursor.getColumnIndex(Contants.GOODS_PRICE)));
result.setGoodsstyle(cursor.getString(cursor.getColumnIndex(Contants.GOODS_STYLE)));
result.setGoodsdesc(cursor.getString(cursor.getColumnIndex(Contants.GOODS_DESC)));
result.setGoodsphoen(cursor.getString(cursor.getColumnIndex(Contants.GOODS_PHONE)));
result.setGoodsphoneleft(cursor.getString(cursor.getColumnIndex(Contants.GOODS_LEFT)));
result.setGoodsphoneright(cursor.getString(cursor.getColumnIndex(Contants.GOODS_RIGHT)));
return result; } public void add(GoodsBean bean) { ContentValues values = new
ContentValues(); values.put(Contants.USER_NAME, bean.getUsername());
values.put(Contants.GOODS_NAME, bean.getGoodsname());
values.put(Contants.GOODS_PRICE, bean.getGoodsprice());
values.put(Contants.GOODS_STYLE, bean.getGoodsstyle());
values.put(Contants.GOODS_DESC, bean.getGoodsdesc());
values.put(Contants.GOODS_PHONE, bean.getGoodsphoen());
values.put(Contants.GOODS_LEFT, bean.getGoodsphoneleft());
values.put(Contants.GOODS_RIGHT, bean.getGoodsphoneright());
this.writeDb.insert(Contants.TB_TABLE_GOODS, "", values); } public
List<GoodsBean> findAll(String orderBy) { //查询 List<GoodsBean> list = new
ArrayList<GoodsBean>(); Cursor cursor = this.readDb.query(
Contants.TB_TABLE_GOODS, null, null, null, null, null, orderBy); GoodsBean bn =
null; while (cursor.moveToNext()) { bn = creatRowResult(cursor); list.add(bn);
} cursor.close(); return list; } public void update(Map<String, Object> param)
{ ContentValues values = new ContentValues(); Iterator<String> keys =
param.keySet().iterator(); while (keys.hasNext()) { String key = keys.next();
if (param.get(key) instanceof Integer) { values.put(key,
Integer.valueOf(param.get(key).toString())); } else { values.put(key,
param.get(key).toString()); } } this.writeDb.update( Contants.TB_TABLE_GOODS,
values, Contants.USER_NAME + " = '" + param.get(Contants.USER_NAME) + "'",
null); } public void delete(String[] arg) { // 删除 String selection =
Contants.GOODS_NAME + " = ?"; this.writeDb.delete(Contants.TB_TABLE_GOODS,
selection, arg); } public GoodsBean findOne(String[] args) { GoodsBean devBean
= null; String selection = Contants.USER_NAME + " = ? AND " +
Contants.GOODS_NAME + " = ? "; Cursor cursor = this.readDb.query(
Contants.TB_TABLE_GOODS, null, selection, args, null, null, null); if
(cursor.moveToNext()) { devBean = creatRowResult(cursor); } cursor.close();
return devBean; } public List<GoodsBean> findData(String[] args) {
List<GoodsBean> list = new ArrayList<GoodsBean>(); Cursor cursor =
this.readDb.query( Contants.TB_TABLE_GOODS, null, null, args, null, null,
null); GoodsBean devBean=null; if (cursor.moveToNext()) { devBean =
creatRowResult(cursor); list.add(devBean); } cursor.close(); return list; }
public List<GoodsBean> findsearchData(String selection, String[] args) {
List<GoodsBean> list = new ArrayList<GoodsBean>(); Cursor cursor =
this.readDb.query( Contants.TB_TABLE_GOODS, null, selection, args, null, null,
null); GoodsBean bn = null; while (cursor.moveToNext()) { bn =
creatRowResult(cursor); list.add(bn); } cursor.close(); return list; } public
void deleteAll() { //删除全部 this.writeDb.delete(Contants.TB_TABLE_GOODS, null,
null); } }
用户信息存储表:
public class TableUser extends ATable { @Override String getTableName() {
return Contants.TB_TABLE_USER; } @Override String createTableSql() { return
"create table " + Contants.TB_TABLE_USER + "(" + Contants.TABLE_ID + " integer
primary key autoincrement," + Contants.USER_NAME + " text not null," +
Contants.USER_PASSWORD + " text," + Contants.USER_PHONE + " text," +
Contants.USER_SCHOOL + " text," + Contants.USER_SEX + " text," +
Contants.USER_IMAGE + " text," + ")"; } private UserBean creatRowResult(Cursor
cursor) { UserBean result = new UserBean();
result.setUsername(cursor.getString(cursor.getColumnIndex(Contants.USER_NAME)));
result.setPassword(cursor.getString(cursor.getColumnIndex(Contants.USER_PASSWORD)));
result.setUserphone(cursor.getString(cursor.getColumnIndex(Contants.USER_PHONE)));
result.setUserschool(cursor.getString(cursor.getColumnIndex(Contants.USER_SCHOOL)));
result.setUsersex(cursor.getString(cursor.getColumnIndex(Contants.USER_SEX)));
result.setUserphoto(cursor.getString(cursor.getColumnIndex(Contants.USER_IMAGE)));
return result; } public void add(UserBean bean) { ContentValues values = new
ContentValues(); values.put(Contants.USER_NAME, bean.getUsername());
values.put(Contants.USER_PASSWORD, bean.getPassword());
values.put(Contants.USER_PHONE, bean.getUserphone());
values.put(Contants.USER_SCHOOL, bean.getUserschool());
values.put(Contants.USER_SEX, bean.getUsersex());
values.put(Contants.USER_IMAGE, bean.getUserphoto());
this.writeDb.insert(Contants.TB_TABLE_USER, "", values); } public
List<UserBean> findAll(String orderBy) { //查询 List<UserBean> list = new
ArrayList<UserBean>(); Cursor cursor = this.readDb.query(
Contants.TB_TABLE_USER, null, null, null, null, null, orderBy); UserBean bn =
null; while (cursor.moveToNext()) { bn = creatRowResult(cursor); list.add(bn);
} cursor.close(); return list; } public void update(Map<String, Object> param)
{ ContentValues values = new ContentValues(); Iterator<String> keys =
param.keySet().iterator(); while (keys.hasNext()) { String key = keys.next();
if (param.get(key) instanceof Integer) { values.put(key,
Integer.valueOf(param.get(key).toString())); } else { values.put(key,
param.get(key).toString()); } } this.writeDb.update( Contants.TB_TABLE_USER,
values, Contants.USER_NAME + " = '" + param.get(Contants.USER_NAME) + "'",
null); } public void delete(String[] arg) { // 删除 String selection =
Contants.USER_NAME + " = ?"; this.writeDb.delete(Contants.TB_TABLE_USER,
selection, arg); } public UserBean findOne(String[] args) { UserBean devBean =
null; String selection = Contants.USER_NAME + " = ? "; Cursor cursor =
this.readDb.query( Contants.TB_TABLE_USER, null, selection, args, null, null,
null); if (cursor.moveToNext()) { devBean = creatRowResult(cursor); }
cursor.close(); return devBean; } public UserBean findData(String[] args) {
UserBean devBean = null; Cursor cursor = this.readDb.query(
Contants.TB_TABLE_USER, null, null, args, null, null, null); if
(cursor.moveToNext()) { devBean = creatRowResult(cursor); } cursor.close();
return devBean; } public void deleteAll() { //删除全部
this.writeDb.delete(Contants.TB_TABLE_USER, null, null); } }
本项目当毕业设计,如果需要定制开发可加QQ:1362290690

体验APK链接:链接:https://pan.baidu.com/s/1o0qNI04n7diqh9K1ZmREqw
                         提取码:in0n

成品源码   链接:https://m.tb.cn/h.3i6yhV2?sm=78a5f7
<https://m.tb.cn/h.3i6yhV2?sm=78a5f7>