陈士柏 %!s(int64=2) %!d(string=hai) anos
pai
achega
aa13078966

+ 50 - 0
mhotel/src/com/happy/service/AppBookService.java

@@ -0,0 +1,50 @@
+package com.happy.service;
+
+import com.happy.Model.Booking;
+import com.happy.dto.IPage;
+
+import java.text.ParseException;
+import java.util.List;
+
+public interface AppBookService {
+
+
+    /**
+     * 创建订单信息
+     * @param houseId
+     * @param startTime
+     * @param endTime
+     * @param houseOrderNumber
+     * @param userName
+     * @param userPhone
+     * @param userId
+     * @return
+     */
+    public String createOrder(String bookingId, String houseId,String startTime,String endTime,String houseOrderNumber,String userName,String userPhone, String userId,String complaintId,String useId) throws ParseException;
+
+
+//    /**
+//     * 再次预订订单信息
+//     * @param houseId
+//     * @param startTime
+//     * @param endTime
+//     * @param houseOrderNumber
+//     * @param userName
+//     * @param userPhone
+//     * @param userId
+//     * @return
+//     */
+//    public String reCreateOrder(String houseId,String startTime,String endTime,String houseOrderNumber,String userName,String userPhone, String userId);
+
+    /**
+     * 验证单个房间是否
+     * @param houseId
+     * @param startTime
+     * @param endTime
+
+     * @return
+     */
+    public String varificationHouse(String houseId, String startTime, String endTime, String houseOrderNumber) ;
+
+
+}

+ 97 - 0
mhotel/src/com/happy/service/AppService.java

@@ -0,0 +1,97 @@
+package com.happy.service;
+
+import com.happy.Model.Admin;
+import com.happy.Model.AdminManager;
+import com.happy.Model.app.Around_product;
+import com.happy.Model.app.Arounds;
+import com.happy.Model.app.News;
+import com.happy.Model.weixin.CodeEntity;
+import com.alibaba.fastjson.JSONObject;
+import com.happy.common.model.airticle.Item_content;
+
+import java.util.List;
+
+public interface AppService {
+
+    public CodeEntity getCodeInfo(String code);
+
+    public JSONObject getGCodeInfo(String code);
+
+    // 登录
+    public Admin login(String admin_name, String password);
+
+    public Admin queryByOpenid(String openid);
+
+    public Admin queryByNameAndOpenid(String admin_name,String openid);
+
+    public int updateOpenid(String openid,String admin_name);
+
+    public int updateOpenidNull(String openid);
+
+    /**********************
+     * ********商户绑定**********
+     * ********************/
+    public AdminManager login_ma(String admin_name, String password);
+
+    public AdminManager queryMaByOpenid(String openid);
+
+    public AdminManager queryMaByNameAndOpenid(String admin_name,String openid);
+
+    public int updateMaOpenid(String openid,String admin_name);
+
+    public int updateMaOpenidNull(String openid);
+
+    /** ================================资讯============================= **/
+    public int insertNews(News news);
+
+    public int delNews(int id);
+
+    public int updateNews(News news);
+
+    public int updateTop(News news);
+
+    public News queryByTit(String title);
+
+    public News queryById(int id);
+
+    public List<Item_content> getNews(int page, int rows) throws Exception;
+
+    public List<News> queryNewPage(int page, int rows, String sqlx);
+
+    public int queryNewTotal(String sqlx);
+
+    /** ==============================周边=================================== **/
+    public int insertRound(Arounds arounds);
+
+    public int updateRoundById(Arounds arounds);
+
+    public int updateRoundCountById(Arounds arounds);
+
+    public int delAround(int id);
+
+    public Arounds queryAroundById(int id);
+
+    public Arounds queryAroundByName(String rname);
+
+    public List<Arounds> queryAroundPage(String sqlx, int page, int rows);
+
+    public int queryAroundTotal(String sqlx);
+
+    /** =========================产品============================== **/
+    public int insertProduct(Around_product around_product);
+
+    public int updateProductById(Around_product around_product);
+
+    public int delAroundProduct(int id);
+
+    public Around_product queryAPById(int id);
+
+    public Around_product queryAPByName(int aid,String product_name);
+
+    public List<Around_product> queryAPPage(int aid,String sqlx, int page, int rows);
+
+    public int queryAPTotal(int aid,String sqlx);
+
+    public List<Around_product> queryAP(int aid,String sqlx);
+
+}

+ 120 - 0
mhotel/src/com/happy/service/BookService.java

@@ -0,0 +1,120 @@
+package com.happy.service;
+
+import com.happy.Model.Booking;
+import com.happy.Model.Booking;
+import com.happy.Model.app.Tongji;
+import com.happy.dto.BookTypeEto;
+import com.happy.dto.IPage;
+
+import java.util.List;
+
+public interface BookService {
+
+    /**
+     * 描述:新增
+     * @param book
+     * @return
+     */
+    int insertBooking(Booking book);
+
+    /**
+     * 描述:修改
+     * @param book
+     * @return
+     */
+    int updateBooking(Booking book);
+
+    /**
+     * 描述:删除
+     * @param id
+     * @return
+     */
+    int delBooking(int id);
+
+    /**
+     * 描述:根据Id查询详细
+     * @param id
+     * @return
+     */
+    Booking getById(int id);
+
+    /**
+     * 描述:分页查询
+     * @param sqlx
+     * @param page
+     * @param rows
+     * @return
+     */
+    IPage<Booking> queryPage(String sqlx, int page, int rows, String orderDesc);
+
+    // 订单金额统计
+    public Tongji queryOrderT(String sqlx);
+
+    // 支付金额统计
+    public Tongji queryPayT(String sqlx);
+
+    // 退款金额统计
+    public Tongji queryRefundT(String sqlx);
+
+    // 入账金额统计
+    public Tongji queryInT(String sqlx);
+
+    // 清账操作
+    public int updateSaccount(Booking booking);
+
+    /**
+     * 描述:查询列表
+     * @param sqlx
+     * @return
+     */
+    List<Booking> queryList(String sqlx);
+
+    /**
+     * 描述:查询一条数据
+     * @param sqlx
+     * @return
+     */
+    Booking getOen(String sqlx);
+
+    /**
+     * 描述:汇总查询金额
+     * @param sqlx
+     * @return
+     */
+    Double sumAccount(String sqlx);
+
+    /**
+     * 描述:查询订单类型汇总
+     * @param sqlx
+     * @return
+     */
+    BookTypeEto getBookStatusSum(String sqlx);
+
+//    /**
+//     * 取消订单功能
+//     * @param bookingId
+//     * @return
+//     */
+//    String cancelBooking(String bookingId) throws Exception;
+
+    /**
+     * 删除订单(假删除)
+     * @param bookingId
+     * @return
+     */
+    String delBooking(String bookingId);
+
+    /**
+     * 描述:根据订单号获取订单
+     * @param orderNum
+     * @return
+     */
+    Booking queryByOrder(String orderNum);
+
+    /**
+     *  定时任务:根据管理端修改的响应时间修改订单状态
+     * @return
+     */
+    int updateBookStatus();
+
+}