| | |
| | | package com.stylefeng.guns.modular.system.controller.general; |
| | | |
| | | import com.alibaba.fastjson.JSONArray; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.modular.system.controller.util.LabelReplaceUtil; |
| | |
| | | } |
| | | |
| | | /** |
| | | * 跳转到加盟基本要求 |
| | | */ |
| | | @RequestMapping("/requirementsJoinExplain") |
| | | public String requirementsJoinExplain(Model model) { |
| | | THtml tHtml = queryHtmlByType(HtmlTypeEnum.BASIC_REQUIREMENTS_JOINING.getCode()); |
| | | JSONObject jsonObject = JSONObject.parseObject(tHtml.getHtml()); |
| | | JSONArray rules = jsonObject.getJSONArray("rules"); |
| | | JSONArray objects = new JSONArray(); |
| | | for (int i = 0; i < rules.size(); i++) { |
| | | JSONObject jsonObject1 = JSONObject.parseObject(JSONObject.toJSONString(rules.get(i))); |
| | | if(i == 0){ |
| | | jsonObject1.put("key",0); |
| | | }else { |
| | | jsonObject1.put("key",1); |
| | | } |
| | | objects.add(jsonObject1); |
| | | } |
| | | model.addAttribute("array",objects); |
| | | model.addAttribute("id",tHtml.getId()); |
| | | return PREFIX + "requirementsJoinExplain.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到代驾服务协议与隐私政策保护,法律条款,个人信息处理规则 |
| | | */ |
| | | @RequestMapping("/agreement") |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.controller.general; |
| | | |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | | import org.springframework.ui.Model; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import com.stylefeng.guns.core.log.LogObjectHolder; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import com.stylefeng.guns.modular.system.model.TImg; |
| | | import com.stylefeng.guns.modular.system.service.ITImgService; |
| | | |
| | | /** |
| | | * 控制器 |
| | | * |
| | | * @author fengshuonan |
| | | * @Date 2023-03-28 10:01:31 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tImg") |
| | | public class TImgController extends BaseController { |
| | | |
| | | private String PREFIX = "/system/tImg/"; |
| | | |
| | | @Autowired |
| | | private ITImgService tImgService; |
| | | |
| | | /** |
| | | * 跳转到首页 |
| | | */ |
| | | @RequestMapping("") |
| | | public String index() { |
| | | return PREFIX + "tImg.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到添加 |
| | | */ |
| | | @RequestMapping("/tImg_add") |
| | | public String tImgAdd() { |
| | | return PREFIX + "tImg_add.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到修改 |
| | | */ |
| | | @RequestMapping("/tImg_update/{tImgId}") |
| | | public String tImgUpdate(@PathVariable Integer tImgId, Model model) { |
| | | TImg tImg = tImgService.selectById(tImgId); |
| | | model.addAttribute("item",tImg); |
| | | LogObjectHolder.me().set(tImg); |
| | | return PREFIX + "tImg_edit.html"; |
| | | } |
| | | |
| | | /** |
| | | * 获取列表 |
| | | */ |
| | | @RequestMapping(value = "/list") |
| | | @ResponseBody |
| | | public Object list(String condition) { |
| | | return tImgService.selectList(null); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @RequestMapping(value = "/add") |
| | | @ResponseBody |
| | | public Object add(TImg tImg) { |
| | | tImgService.insert(tImg); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | @RequestMapping(value = "/delete") |
| | | @ResponseBody |
| | | public Object delete(@RequestParam Integer tImgId) { |
| | | tImgService.deleteById(tImgId); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | */ |
| | | @RequestMapping(value = "/update") |
| | | @ResponseBody |
| | | public Object update(TImg tImg) { |
| | | tImgService.updateById(tImg); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 详情 |
| | | */ |
| | | @RequestMapping(value = "/detail/{tImgId}") |
| | | @ResponseBody |
| | | public Object detail(@PathVariable("tImgId") Integer tImgId) { |
| | | return tImgService.selectById(tImgId); |
| | | } |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.controller.general; |
| | | |
| | | import com.alibaba.fastjson.JSONArray; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.modular.system.enums.HtmlTypeEnum; |
| | | import com.stylefeng.guns.modular.system.enums.MainContentTypeEnum; |
| | | import com.stylefeng.guns.modular.system.enums.StatusEnum; |
| | | import com.stylefeng.guns.modular.system.model.THtml; |
| | | import com.stylefeng.guns.modular.system.service.ITHtmlService; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.ui.Model; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import com.stylefeng.guns.core.log.LogObjectHolder; |
| | | import com.stylefeng.guns.modular.system.model.TMainContent; |
| | | import com.stylefeng.guns.modular.system.service.ITMainContentService; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * 控制器 |
| | | * |
| | | * @author fengshuonan |
| | | * @Date 2023-03-28 10:09:47 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tMainContent") |
| | | public class TMainContentController extends BaseController { |
| | | |
| | | private String PREFIX = "/system/tMainContent/"; |
| | | |
| | | @Autowired |
| | | private ITMainContentService tMainContentService; |
| | | @Autowired |
| | | private ITHtmlService tHtmlService; |
| | | |
| | | /** |
| | | * 跳转到首页 |
| | | */ |
| | | @RequestMapping("") |
| | | public String index() { |
| | | return PREFIX + "tMainContent.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到添加 |
| | | */ |
| | | @RequestMapping("/tMainContent_add") |
| | | public String tMainContentAdd() { |
| | | return PREFIX + "tMainContent_add.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到转单添加 |
| | | */ |
| | | @RequestMapping("/transferOrder/add") |
| | | public String transferOrderAdd(Model model) { |
| | | model.addAttribute("key",0); |
| | | return PREFIX + "transferOrderAdd.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到转单修改 |
| | | */ |
| | | @RequestMapping("/transferOrder/update") |
| | | public String transferOrderUpdate(Model model) { |
| | | List<TMainContent> list = tMainContentService.selectList(new EntityWrapper<TMainContent>() |
| | | .eq("type", MainContentTypeEnum.TRANSFER_ORDER.getCode())); |
| | | model.addAttribute("list",list); |
| | | return PREFIX + "transferOrderUpdate.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到消单添加 |
| | | */ |
| | | @RequestMapping("/driverCancelOrder/add") |
| | | public String driverCancelOrderAdd(Model model) { |
| | | model.addAttribute("key",0); |
| | | return PREFIX + "driverCancelOrderAdd.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到消单修改 |
| | | */ |
| | | @RequestMapping("/driverCancelOrder/update") |
| | | public String driverCancelOrderUpdate(Model model) { |
| | | List<TMainContent> list = tMainContentService.selectList(new EntityWrapper<TMainContent>() |
| | | .eq("type", MainContentTypeEnum.DRIVER_CANCEL_ORDER.getCode())); |
| | | model.addAttribute("list",list); |
| | | return PREFIX + "driverCancelOrderUpdate.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到转单添加 |
| | | */ |
| | | @RequestMapping("/userCancelOrder/add") |
| | | public String userCancelOrderAdd(Model model) { |
| | | model.addAttribute("key",0); |
| | | return PREFIX + "userCancelOrderAdd.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到转单修改 |
| | | */ |
| | | @RequestMapping("/userCancelOrder/update") |
| | | public String userCancelOrderUpdate(Model model) { |
| | | List<TMainContent> list = tMainContentService.selectList(new EntityWrapper<TMainContent>() |
| | | .eq("type", MainContentTypeEnum.USER_CANCEL_ORDER.getCode())); |
| | | model.addAttribute("list",list); |
| | | return PREFIX + "userCancelOrderUpdate.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到修改 |
| | | */ |
| | | @RequestMapping("/tMainContent_update/{tMainContentId}") |
| | | public String tMainContentUpdate(@PathVariable Integer tMainContentId, Model model) { |
| | | TMainContent tMainContent = tMainContentService.selectById(tMainContentId); |
| | | model.addAttribute("item",tMainContent); |
| | | LogObjectHolder.me().set(tMainContent); |
| | | return PREFIX + "tMainContent_edit.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到转单 |
| | | */ |
| | | @RequestMapping("/transferOrder") |
| | | public String transferOrder(Model model) { |
| | | List<TMainContent> list = tMainContentService.selectList(new EntityWrapper<TMainContent>() |
| | | .eq("type", MainContentTypeEnum.TRANSFER_ORDER.getCode())); |
| | | model.addAttribute("list",list); |
| | | return PREFIX + "transferOrder.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到司机消单 |
| | | */ |
| | | @RequestMapping("/driverCancelOrder") |
| | | public String driverCancelOrder(Model model) { |
| | | List<TMainContent> list = tMainContentService.selectList(new EntityWrapper<TMainContent>() |
| | | .eq("type", MainContentTypeEnum.DRIVER_CANCEL_ORDER.getCode())); |
| | | model.addAttribute("list",list); |
| | | THtml html = tHtmlService.selectOne(new EntityWrapper<THtml>().eq("type", HtmlTypeEnum.DRIVER_EXPLAIN_CANCELLATION.getCode()).last("LIMIT 1")); |
| | | model.addAttribute("html",html); |
| | | return PREFIX + "driverCancelOrder.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到用户取消订单 |
| | | */ |
| | | @RequestMapping("/userCancelOrder") |
| | | public String userCancelOrder(Model model) { |
| | | List<TMainContent> list = tMainContentService.selectList(new EntityWrapper<TMainContent>() |
| | | .eq("type", MainContentTypeEnum.USER_CANCEL_ORDER.getCode())); |
| | | model.addAttribute("list",list); |
| | | return PREFIX + "userCancelOrder.html"; |
| | | } |
| | | |
| | | /** |
| | | * 获取列表 |
| | | */ |
| | | @RequestMapping(value = "/list") |
| | | @ResponseBody |
| | | public Object list(String condition) { |
| | | return tMainContentService.selectList(null); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @RequestMapping(value = "/add") |
| | | @ResponseBody |
| | | public Object add( String tMainContents,Integer type) { |
| | | String[] split = tMainContents.split(","); |
| | | List<TMainContent> tMainContents1 = new ArrayList<>(split.length); |
| | | for (String s : split) { |
| | | TMainContent tMainContent = new TMainContent(); |
| | | tMainContent.setContent(s); |
| | | tMainContent.setType(type); |
| | | tMainContent.setStatus(StatusEnum.NORMAL.getCode()); |
| | | tMainContent.setCreateTime(new Date()); |
| | | tMainContents1.add(tMainContent); |
| | | } |
| | | tMainContentService.insertBatch(tMainContents1); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @RequestMapping(value = "/add-back") |
| | | @ResponseBody |
| | | public Object addBack(TMainContent tMainContent) { |
| | | tMainContentService.insert(tMainContent); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | @RequestMapping(value = "/delete") |
| | | @ResponseBody |
| | | public Object delete(@RequestParam Integer tMainContentId) { |
| | | tMainContentService.deleteById(tMainContentId); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | */ |
| | | @RequestMapping(value = "/update") |
| | | @ResponseBody |
| | | public Object update(String tMainContents,Integer type) { |
| | | |
| | | tMainContentService.delete(new EntityWrapper<TMainContent>() |
| | | .eq("type",type)); |
| | | |
| | | String[] split = tMainContents.split(","); |
| | | List<TMainContent> tMainContents1 = new ArrayList<>(split.length); |
| | | for (String s : split) { |
| | | TMainContent tMainContent = new TMainContent(); |
| | | tMainContent.setContent(s); |
| | | tMainContent.setType(type); |
| | | tMainContent.setStatus(StatusEnum.NORMAL.getCode()); |
| | | tMainContent.setCreateTime(new Date()); |
| | | tMainContents1.add(tMainContent); |
| | | } |
| | | tMainContentService.insertBatch(tMainContents1); |
| | | return SUCCESS_TIP; |
| | | } |
| | | /** |
| | | * 修改 |
| | | */ |
| | | @RequestMapping(value = "/update-back") |
| | | @ResponseBody |
| | | public Object updateBack(TMainContent tMainContent) { |
| | | tMainContentService.updateById(tMainContent); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 详情 |
| | | */ |
| | | @RequestMapping(value = "/detail/{tMainContentId}") |
| | | @ResponseBody |
| | | public Object detail(@PathVariable("tMainContentId") Integer tMainContentId) { |
| | | return tMainContentService.selectById(tMainContentId); |
| | | } |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.dao; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TImg; |
| | | import com.baomidou.mybatisplus.mapper.BaseMapper; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统图片 Mapper 接口 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | public interface TImgMapper extends BaseMapper<TImg> { |
| | | |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.dao; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TMainContent; |
| | | import com.baomidou.mybatisplus.mapper.BaseMapper; |
| | | |
| | | /** |
| | | * <p> |
| | | * 事由管理 Mapper 接口 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | public interface TMainContentMapper extends BaseMapper<TMainContent> { |
| | | |
| | | } |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.stylefeng.guns.modular.system.dao.TImgMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.stylefeng.guns.modular.system.model.TImg"> |
| | | <id column="id" property="id" /> |
| | | <result column="type" property="type" /> |
| | | <result column="img" property="img" /> |
| | | <result column="createTime" property="createTime" /> |
| | | </resultMap> |
| | | |
| | | <!-- 通用查询结果列 --> |
| | | <sql id="Base_Column_List"> |
| | | id, type, img, createTime |
| | | </sql> |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.stylefeng.guns.modular.system.dao.TMainContentMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.stylefeng.guns.modular.system.model.TMainContent"> |
| | | <id column="id" property="id" /> |
| | | <result column="type" property="type" /> |
| | | <result column="content" property="content" /> |
| | | <result column="status" property="status" /> |
| | | <result column="createTime" property="createTime" /> |
| | | </resultMap> |
| | | |
| | | <!-- 通用查询结果列 --> |
| | | <sql id="Base_Column_List"> |
| | | id, type, content, status, createTime |
| | | </sql> |
| | | |
| | | </mapper> |
| | |
| | | COMMISSION_RULE_EXPLAIN(5, "佣金规则说明"), |
| | | TRIP_RECORDING_EXPLAIN(6, "行程录音说明"), |
| | | ESTIMATED_PRICE_EXPLAIN(7,"预估价格说明"), |
| | | basic_requirements_joining(8, "加盟基本要求"), |
| | | BASIC_REQUIREMENTS_JOINING(8, "加盟基本要求"), |
| | | JOINING_PROCESS(9, "加盟流程"), |
| | | SPECIFICATION_STARTING_PRICE(10, "起步价说明"), |
| | | CANCELLATION_AGREEMENT(11,"注销协议"), |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.enums; |
| | | |
| | | |
| | | |
| | | /** |
| | | * @Description 事由管理类型枚举 |
| | | * @Author xiaochen |
| | | * @Date 2023/02/15 9:42 |
| | | */ |
| | | public enum MainContentTypeEnum { |
| | | |
| | | |
| | | TRANSFER_ORDER(1, "转单"), |
| | | DRIVER_CANCEL_ORDER(2, "司机消单"), |
| | | USER_CANCEL_ORDER(3, "用户取消订单"); |
| | | |
| | | private String desc; |
| | | |
| | | |
| | | private int code; |
| | | |
| | | |
| | | MainContentTypeEnum(int code, String desc) { |
| | | this.code = code; |
| | | this.desc = desc; |
| | | } |
| | | |
| | | public String getDesc() { |
| | | return desc; |
| | | } |
| | | |
| | | public int getCode() { |
| | | return code; |
| | | } |
| | | |
| | | /** |
| | | * 通过code获取枚举 |
| | | * |
| | | * @param code |
| | | * @return |
| | | */ |
| | | public static MainContentTypeEnum fromCode(Integer code) { |
| | | MainContentTypeEnum[] resultTypes = MainContentTypeEnum.values(); |
| | | for (MainContentTypeEnum resultType : resultTypes) { |
| | | if (code.equals(resultType.getCode())) { |
| | | return resultType; |
| | | } |
| | | } |
| | | return null; |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.model; |
| | | |
| | | import com.baomidou.mybatisplus.enums.IdType; |
| | | import java.util.Date; |
| | | import com.baomidou.mybatisplus.annotations.TableId; |
| | | import com.baomidou.mybatisplus.activerecord.Model; |
| | | import com.baomidou.mybatisplus.annotations.TableName; |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统图片 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | @TableName("t_img") |
| | | public class TImg extends Model<TImg> { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | | */ |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | /** |
| | | * 数据类型(1=启动页) |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * 图片地址 |
| | | */ |
| | | private String img; |
| | | /** |
| | | * 添加时间 |
| | | */ |
| | | private Date createTime; |
| | | |
| | | |
| | | public Integer getId() { |
| | | return id; |
| | | } |
| | | |
| | | public void setId(Integer id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public Integer getType() { |
| | | return type; |
| | | } |
| | | |
| | | public void setType(Integer type) { |
| | | this.type = type; |
| | | } |
| | | |
| | | public String getImg() { |
| | | return img; |
| | | } |
| | | |
| | | public void setImg(String img) { |
| | | this.img = img; |
| | | } |
| | | |
| | | public Date getCreateTime() { |
| | | return createTime; |
| | | } |
| | | |
| | | public void setCreateTime(Date createTime) { |
| | | this.createTime = createTime; |
| | | } |
| | | |
| | | @Override |
| | | protected Serializable pkVal() { |
| | | return this.id; |
| | | } |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return "TImg{" + |
| | | "id=" + id + |
| | | ", type=" + type + |
| | | ", img=" + img + |
| | | ", createTime=" + createTime + |
| | | "}"; |
| | | } |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.model; |
| | | |
| | | import com.baomidou.mybatisplus.enums.IdType; |
| | | import java.util.Date; |
| | | import com.baomidou.mybatisplus.annotations.TableId; |
| | | import com.baomidou.mybatisplus.activerecord.Model; |
| | | import com.baomidou.mybatisplus.annotations.TableName; |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * 事由管理 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | @TableName("t_main_content") |
| | | public class TMainContent extends Model<TMainContent> { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | | */ |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | /** |
| | | * 数据类型(1=转单,2=司机消单,3=用户取消订单) |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * 内容 |
| | | */ |
| | | private String content; |
| | | /** |
| | | * 状态(1=正常,2=冻结,3=删除) |
| | | */ |
| | | private Integer status; |
| | | /** |
| | | * 添加时间 |
| | | */ |
| | | private Date createTime; |
| | | |
| | | |
| | | public Integer getId() { |
| | | return id; |
| | | } |
| | | |
| | | public void setId(Integer id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public Integer getType() { |
| | | return type; |
| | | } |
| | | |
| | | public void setType(Integer type) { |
| | | this.type = type; |
| | | } |
| | | |
| | | public String getContent() { |
| | | return content; |
| | | } |
| | | |
| | | public void setContent(String content) { |
| | | this.content = content; |
| | | } |
| | | |
| | | public Integer getStatus() { |
| | | return status; |
| | | } |
| | | |
| | | public void setStatus(Integer status) { |
| | | this.status = status; |
| | | } |
| | | |
| | | public Date getCreateTime() { |
| | | return createTime; |
| | | } |
| | | |
| | | public void setCreateTime(Date createTime) { |
| | | this.createTime = createTime; |
| | | } |
| | | |
| | | @Override |
| | | protected Serializable pkVal() { |
| | | return this.id; |
| | | } |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return "TMainContent{" + |
| | | "id=" + id + |
| | | ", type=" + type + |
| | | ", content=" + content + |
| | | ", status=" + status + |
| | | ", createTime=" + createTime + |
| | | "}"; |
| | | } |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.service; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TImg; |
| | | import com.baomidou.mybatisplus.service.IService; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统图片 服务类 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | public interface ITImgService extends IService<TImg> { |
| | | |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.service; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TMainContent; |
| | | import com.baomidou.mybatisplus.service.IService; |
| | | |
| | | /** |
| | | * <p> |
| | | * 事由管理 服务类 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | public interface ITMainContentService extends IService<TMainContent> { |
| | | |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.service.impl; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TImg; |
| | | import com.stylefeng.guns.modular.system.dao.TImgMapper; |
| | | import com.stylefeng.guns.modular.system.service.ITImgService; |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统图片 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | @Service |
| | | public class TImgServiceImpl extends ServiceImpl<TImgMapper, TImg> implements ITImgService { |
| | | |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.service.impl; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TMainContent; |
| | | import com.stylefeng.guns.modular.system.dao.TMainContentMapper; |
| | | import com.stylefeng.guns.modular.system.service.ITMainContentService; |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * 事由管理 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-28 |
| | | */ |
| | | @Service |
| | | public class TMainContentServiceImpl extends ServiceImpl<TMainContentMapper, TMainContent> implements ITMainContentService { |
| | | |
| | | } |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>加盟基本要求设置</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label style="color: #0C0C0C">加盟基本要求</label> |
| | | </div> |
| | | |
| | | <input hidden id="id" value="${id}"> |
| | | <input hidden id="array" value="${array}"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: left" > |
| | | @for(ChargeStandard in array){ |
| | | <div name="rulesForm"> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <span class="control-label" >要求1</span> |
| | | <input class="control-label" id="num1" name="num1" value="${ChargeStandard.num1}" type="text" placeholder="单行输入" style="height: 30px;width: 180px"> |
| | | @if(ChargeStandard.key == 0){ |
| | | <span class="fa fa-plus" onclick="THtml.addBox()"></span> |
| | | @} |
| | | @if(ChargeStandard.key == 1){ |
| | | <span class="fa fa-remove" onclick="THtml.delBox(this)"></span> |
| | | @} |
| | | </div> |
| | | </div> |
| | | @} |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10" style="text-align: center"> |
| | | <#button btnCss="info" name="保存" id="ensure" icon="fa-check" clickFun="THtml.priceRulesSubmit()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tHtml/tHtml_info.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tHtml/tHtml.js"></script> |
| | | <style type="text/css"> |
| | | .agentDriver{ |
| | | height: 30px; |
| | | width: 200px; |
| | | background-color: white; |
| | | border-radius: 6px; |
| | | } |
| | | .clause{ |
| | | height: 30px; |
| | | width: 80px; |
| | | background-color: white; |
| | | border-radius: 6px; |
| | | } |
| | | .personalRules{ |
| | | height: 30px; |
| | | width: 180px; |
| | | background-color: white; |
| | | border-radius: 6px; |
| | | } |
| | | </style> |
| | | <script type="text/javascript"> |
| | | </script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>启动页管理</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12" style="text-align: left" > |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label>状态</label> |
| | | <input type="radio" class="control-label" name="content" style="width: 2%" checked>开启 |
| | | <input type="radio" class="control-label" name="content" style="width: 2%">关闭 |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >图片:</label> |
| | | <#uploadImg id="img" fileImg=""/> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-12" style="text-align: center"> |
| | | <#button btnCss="info" name="保存" id="ensure" icon="fa-check" clickFun="TImgInfoDlg.editSubmit()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tImg/tImg.js"></script> |
| | | <script type="text/javascript"> |
| | | $(function () { |
| | | var idCardPositive = new $WebUpload("img"); |
| | | idCardPositive.setUploadBarId("progressBar"); |
| | | idCardPositive.init(); |
| | | }); |
| | | </script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal"> |
| | | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" underline="true"/> |
| | | <#input id="type" name="数据类型(1=启动页)"/> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="img" name="图片地址" underline="true"/> |
| | | <#input id="createTime" name="添加时间" underline="true"/> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TImgInfoDlg.addSubmit()"/> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TImgInfoDlg.close()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tImg/tImg_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal"> |
| | | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" value="${item.id}" underline="true"/> |
| | | <#input id="type" name="数据类型(1=启动页)" value="${item.type}" /> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="img" name="图片地址" value="${item.img}" underline="true"/> |
| | | <#input id="createTime" name="添加时间" value="${item.createTime}" /> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TImgInfoDlg.editSubmit()"/> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TImgInfoDlg.close()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tImg/tImg_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>消单设置</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label style="color: #0C0C0C">消单原因</label> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-2" style="text-align: center"> |
| | | @if(shiro.hasPermission("/tMainContent/driverCancelOrder/add")){ |
| | | <#button btnCss="info" name="新增" id="ensure" icon="fa-check" clickFun="TMainContent.driverCancelOrderAdd()"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tMainContent/driverCancelOrder/update")){ |
| | | <#button btnCss="info" name="编辑" id="ensure" icon="fa-check" clickFun="TMainContent.driverCancelOrderUpdate()"/> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | <input hidden id="list" value="${list}"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: left" > |
| | | @for(driverCancelOrder in list){ |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input type="checkbox" class="control-label" id="content" name="content" style="width: 4%" checked>${driverCancelOrder.content}</input> |
| | | </div> |
| | | @} |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label style="color: #0C0C0C">取单说明</label> |
| | | </div> |
| | | |
| | | <input hidden id="id" value="${html.id}"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <textarea type="text/plain" id="html" name="html" style="width:100%;height:350px;">${html.html}</textarea> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10" style="text-align: center"> |
| | | <#button btnCss="info" name="保存" id="ensure" icon="fa-check" clickFun="THtmlInfoDlg.editSubmit()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tHtml/tHtml_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: center" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input class="control-label" id="content" name="content" placeholder="请输入" style="width: 180px;height: 30px"> |
| | | @if(key == 0){ |
| | | <span class="fa fa-plus" onclick="TMainContent.addBox()"></span> |
| | | @}else { |
| | | <span class="fa fa-remove" onclick="TMainContent.delBox(this)"></span> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-12" style="text-align: center"> |
| | | <#button btnCss="info" name="取消" id="cancel" icon="fa-check" clickFun="TMainContentInfoDlg.close()"/> |
| | | <#button btnCss="info" name="保存" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.driverCancelOrderAddSubmit()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: center" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | @for(transferOrder in list){ |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input class="control-label" id="content" name="content" value="${transferOrder.content}" style="width: 180px;height: 30px"> |
| | | <span class="fa fa-remove" onclick="TMainContent.delBox(this)"></span> |
| | | </div> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-12" style="text-align: center"> |
| | | <#button btnCss="info" name="取消" id="cancel" icon="fa-check" clickFun="TMainContentInfoDlg.close()"/> |
| | | <#button btnCss="info" name="确定" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.driverCancelOrderUpdateSubmit()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>管理</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | <div class="row"> |
| | | <div class="col-sm-3"> |
| | | <#NameCon id="condition" name="名称" /> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <#button name="搜索" icon="fa-search" clickFun="TMainContent.search()"/> |
| | | </div> |
| | | </div> |
| | | <div class="hidden-xs" id="TMainContentTableToolbar" role="group"> |
| | | @if(shiro.hasPermission("/tMainContent/add")){ |
| | | <#button name="添加" icon="fa-plus" clickFun="TMainContent.openAddTMainContent()"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tMainContent/update")){ |
| | | <#button name="修改" icon="fa-edit" clickFun="TMainContent.openTMainContentDetail()" space="true"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tMainContent/delete")){ |
| | | <#button name="删除" icon="fa-remove" clickFun="TMainContent.delete()" space="true"/> |
| | | @} |
| | | </div> |
| | | <#table id="TMainContentTable"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal"> |
| | | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" underline="true"/> |
| | | <#input id="type" name="数据类型(1=转单,2=司机消单,3=用户取消订单)" underline="true"/> |
| | | <#input id="content" name="内容"/> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="status" name="状态(1=正常,2=冻结,3=删除)" underline="true"/> |
| | | <#input id="createTime" name="添加时间" underline="true"/> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.addSubmit()"/> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TMainContentInfoDlg.close()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal"> |
| | | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" value="${item.id}" underline="true"/> |
| | | <#input id="type" name="数据类型(1=转单,2=司机消单,3=用户取消订单)" value="${item.type}" underline="true"/> |
| | | <#input id="content" name="内容" value="${item.content}" /> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="status" name="状态(1=正常,2=冻结,3=删除)" value="${item.status}" underline="true"/> |
| | | <#input id="createTime" name="添加时间" value="${item.createTime}" /> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.editSubmit()"/> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TMainContentInfoDlg.close()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>转单设置</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label style="color: #0C0C0C">转单原因</label> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-2" style="text-align: center"> |
| | | @if(shiro.hasPermission("/tMainContent/transferOrder/add")){ |
| | | <#button btnCss="info" name="新增" id="ensure" icon="fa-check" clickFun="TMainContent.transferOrderAdd()"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tMainContent/transferOrder/update")){ |
| | | <#button btnCss="info" name="编辑" id="ensure" icon="fa-check" clickFun="TMainContent.transferOrderUpdate()"/> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | <input hidden id="list" value="${list}"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: left" > |
| | | @for(transferOrder in list){ |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input type="checkbox" class="control-label" id="content" name="content" style="width: 4%" checked>${transferOrder.content}</input> |
| | | </div> |
| | | @} |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: center" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input class="control-label" id="content" name="content" placeholder="请输入" style="width: 180px;height: 30px"> |
| | | @if(key == 0){ |
| | | <span class="fa fa-plus" onclick="TMainContent.addBox()"></span> |
| | | @}else { |
| | | <span class="fa fa-remove" onclick="TMainContent.delBox(this)"></span> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-12" style="text-align: center"> |
| | | <#button btnCss="info" name="取消" id="cancel" icon="fa-check" clickFun="TMainContentInfoDlg.close()"/> |
| | | <#button btnCss="info" name="保存" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.transferOrderAddSubmit()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: center" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | @for(transferOrder in list){ |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input class="control-label" id="content" name="content" value="${transferOrder.content}" style="width: 180px;height: 30px"> |
| | | <span class="fa fa-remove" onclick="TMainContent.delBox(this)"></span> |
| | | </div> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-12" style="text-align: center"> |
| | | <#button btnCss="info" name="取消" id="cancel" icon="fa-check" clickFun="TMainContentInfoDlg.close()"/> |
| | | <#button btnCss="info" name="确定" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.transferOrderUpdateSubmit()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>取消订单设置</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label style="color: #0C0C0C">取消订单原因</label> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-2" style="text-align: center"> |
| | | @if(shiro.hasPermission("/tMainContent/userCancelOrder/add")){ |
| | | <#button btnCss="info" name="新增" id="ensure" icon="fa-check" clickFun="TMainContent.userCancelOrderAdd()"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tMainContent/userCancelOrder/update")){ |
| | | <#button btnCss="info" name="编辑" id="ensure" icon="fa-check" clickFun="TMainContent.userCancelOrderUpdate()"/> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | <input hidden id="list" value="${list}"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: left" > |
| | | @for(userCancelOrder in list){ |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input type="checkbox" class="control-label" id="content" name="content" style="width: 4%" checked>${userCancelOrder.content}</input> |
| | | </div> |
| | | @} |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: center" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input class="control-label" id="content" name="content" placeholder="请输入" style="width: 180px;height: 30px"> |
| | | @if(key == 0){ |
| | | <span class="fa fa-plus" onclick="TMainContent.addBox()"></span> |
| | | @}else { |
| | | <span class="fa fa-remove" onclick="TMainContent.delBox(this)"></span> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-12" style="text-align: center"> |
| | | <#button btnCss="info" name="取消" id="cancel" icon="fa-check" clickFun="TMainContentInfoDlg.close()"/> |
| | | <#button btnCss="info" name="保存" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.userCancelOrderAddSubmit()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="rules" style="text-align: center" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | @for(transferOrder in list){ |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <input class="control-label" id="content" name="content" value="${transferOrder.content}" style="width: 180px;height: 30px"> |
| | | <span class="fa fa-remove" onclick="TMainContent.delBox(this)"></span> |
| | | </div> |
| | | @} |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-12" style="text-align: center"> |
| | | <#button btnCss="info" name="取消" id="cancel" icon="fa-check" clickFun="TMainContentInfoDlg.close()"/> |
| | | <#button btnCss="info" name="确定" id="ensure" icon="fa-check" clickFun="TMainContentInfoDlg.userCancelOrderUpdateSubmit()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tMainContent/tMainContent_info.js"></script> |
| | | @} |
| | |
| | | }; |
| | | |
| | | /** |
| | | * 加盟基本要求 |
| | | */ |
| | | THtml.priceRulesSubmit = function () { |
| | | var ajax = new $ax(Feng.ctxPath + "/tHtml/update", function (data) { |
| | | Feng.success("保存成功!"); |
| | | THtml.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("保存失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | |
| | | var json1=[]; |
| | | for (let i = 0; i < $('input[name="num1"]').length; i++) { |
| | | var arr = {} |
| | | arr['num1'] = $($('input[name="num1"]')[i]).val(); |
| | | json1.push(arr) |
| | | } |
| | | var reqData = {}; |
| | | reqData['rules'] = json1; |
| | | ajax.set("html",JSON.stringify(reqData)); |
| | | ajax.set("id",$('#id').val()); |
| | | ajax.start(); |
| | | }; |
| | | |
| | | THtml.addBox = function (){ |
| | | var i = $('input[name="num1"]').length + 1; |
| | | var a ="<div name=\"rulesForm\">\n" + |
| | | " <div class=\"initialLevel col-sm-12 control-label form-group\" >\n" + |
| | | " <span class=\"control-label\" >要求"+i+"</span>\n" + |
| | | " <input class=\"control-label\" id=\"num1-"+i+"\" name=\"num1\" type=\"text\" placeholder=\"单行输入\" style=\"height: 30px;width: 180px\">\n" + |
| | | " <span class=\"fa fa-remove\" onclick=\"THtml.delBox(this)\"></span>\n" + |
| | | " </div>\n" + |
| | | " </div>" |
| | | |
| | | $("#rules").append($(a)) |
| | | } |
| | | |
| | | THtml.delBox = function (o) { |
| | | $(o).parent("div").parent("div").remove() |
| | | }; |
| | | |
| | | |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | THtml.delete = function () { |
New file |
| | |
| | | /** |
| | | * 管理初始化 |
| | | */ |
| | | var TImg = { |
| | | id: "TImgTable", //表格id |
| | | seItem: null, //选中的条目 |
| | | table: null, |
| | | layerIndex: -1 |
| | | }; |
| | | |
| | | /** |
| | | * 初始化表格的列 |
| | | */ |
| | | TImg.initColumn = function () { |
| | | return [ |
| | | {field: 'selectItem', radio: true}, |
| | | {title: '主键', field: 'id', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '数据类型(1=启动页)', field: 'type', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '图片地址', field: 'img', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '添加时间', field: 'createTime', visible: true, align: 'center', valign: 'middle'} |
| | | ]; |
| | | }; |
| | | |
| | | /** |
| | | * 检查是否选中 |
| | | */ |
| | | TImg.check = function () { |
| | | var selected = $('#' + this.id).bootstrapTable('getSelections'); |
| | | if(selected.length == 0){ |
| | | Feng.info("请先选中表格中的某一记录!"); |
| | | return false; |
| | | }else{ |
| | | TImg.seItem = selected[0]; |
| | | return true; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 点击添加 |
| | | */ |
| | | TImg.openAddTImg = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '添加', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tImg/tImg_add' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 打开查看详情 |
| | | */ |
| | | TImg.openTImgDetail = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '详情', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tImg/tImg_update/' + TImg.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | TImg.delete = function () { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tImg/delete", function (data) { |
| | | Feng.success("删除成功!"); |
| | | TImg.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("删除失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("tImgId",this.seItem.id); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 查询列表 |
| | | */ |
| | | TImg.search = function () { |
| | | var queryData = {}; |
| | | queryData['condition'] = $("#condition").val(); |
| | | TImg.table.refresh({query: queryData}); |
| | | }; |
| | | |
| | | $(function () { |
| | | var defaultColunms = TImg.initColumn(); |
| | | var table = new BSTable(TImg.id, "/tImg/list", defaultColunms); |
| | | table.setPaginationType("client"); |
| | | TImg.table = table.init(); |
| | | }); |
New file |
| | |
| | | /** |
| | | * 初始化详情对话框 |
| | | */ |
| | | var TImgInfoDlg = { |
| | | tImgInfoData : {} |
| | | }; |
| | | |
| | | /** |
| | | * 清除数据 |
| | | */ |
| | | TImgInfoDlg.clearData = function() { |
| | | this.tImgInfoData = {}; |
| | | } |
| | | |
| | | /** |
| | | * 设置对话框中的数据 |
| | | * |
| | | * @param key 数据的名称 |
| | | * @param val 数据的具体值 |
| | | */ |
| | | TImgInfoDlg.set = function(key, val) { |
| | | this.tImgInfoData[key] = (typeof val == "undefined") ? $("#" + key).val() : val; |
| | | return this; |
| | | } |
| | | |
| | | /** |
| | | * 设置对话框中的数据 |
| | | * |
| | | * @param key 数据的名称 |
| | | * @param val 数据的具体值 |
| | | */ |
| | | TImgInfoDlg.get = function(key) { |
| | | return $("#" + key).val(); |
| | | } |
| | | |
| | | /** |
| | | * 关闭此对话框 |
| | | */ |
| | | TImgInfoDlg.close = function() { |
| | | parent.layer.close(window.parent.TImg.layerIndex); |
| | | } |
| | | |
| | | /** |
| | | * 收集数据 |
| | | */ |
| | | TImgInfoDlg.collectData = function() { |
| | | this |
| | | .set('id') |
| | | .set('type') |
| | | .set('img') |
| | | .set('createTime'); |
| | | } |
| | | |
| | | /** |
| | | * 提交添加 |
| | | */ |
| | | TImgInfoDlg.addSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tImg/add", function(data){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TImg.table.refresh(); |
| | | TImgInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set(this.tImgInfoData); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 提交修改 |
| | | */ |
| | | TImgInfoDlg.editSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tImg/update", function(data){ |
| | | Feng.success("修改成功!"); |
| | | window.parent.TImg.table.refresh(); |
| | | TImgInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("修改失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set(this.tImgInfoData); |
| | | ajax.start(); |
| | | } |
| | | |
| | | $(function() { |
| | | |
| | | }); |
New file |
| | |
| | | /** |
| | | * 管理初始化 |
| | | */ |
| | | var TMainContent = { |
| | | id: "TMainContentTable", //表格id |
| | | seItem: null, //选中的条目 |
| | | table: null, |
| | | layerIndex: -1 |
| | | }; |
| | | |
| | | /** |
| | | * 初始化表格的列 |
| | | */ |
| | | TMainContent.initColumn = function () { |
| | | return [ |
| | | {field: 'selectItem', radio: true}, |
| | | {title: '主键', field: 'id', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '数据类型(1=转单,2=司机消单,3=用户取消订单)', field: 'type', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '内容', field: 'content', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '状态(1=正常,2=冻结,3=删除)', field: 'status', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '添加时间', field: 'createTime', visible: true, align: 'center', valign: 'middle'} |
| | | ]; |
| | | }; |
| | | |
| | | /** |
| | | * 检查是否选中 |
| | | */ |
| | | TMainContent.check = function () { |
| | | var selected = $('#' + this.id).bootstrapTable('getSelections'); |
| | | if(selected.length == 0){ |
| | | Feng.info("请先选中表格中的某一记录!"); |
| | | return false; |
| | | }else{ |
| | | TMainContent.seItem = selected[0]; |
| | | return true; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 点击添加 |
| | | */ |
| | | TMainContent.openAddTMainContent = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '添加', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/tMainContent_add' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 转单添加 |
| | | */ |
| | | TMainContent.transferOrderAdd = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '新增原因', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/transferOrder/add' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 转单修改 |
| | | */ |
| | | TMainContent.transferOrderUpdate = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '编辑原因', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/transferOrder/update' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 消单添加 |
| | | */ |
| | | TMainContent.driverCancelOrderAdd = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '新增原因', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/driverCancelOrder/add' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 消单修改 |
| | | */ |
| | | TMainContent.driverCancelOrderUpdate = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '编辑原因', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/driverCancelOrder/update' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 用户取消订单添加 |
| | | */ |
| | | TMainContent.userCancelOrderAdd = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '新增原因', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/userCancelOrder/add' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 用户取消订单修改 |
| | | */ |
| | | TMainContent.userCancelOrderUpdate = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '编辑原因', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/userCancelOrder/update' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | TMainContent.addBox = function (){ |
| | | var i = $('input[name="num1"]').length + 1; |
| | | var a ="<div class=\"initialLevel col-sm-12 control-label form-group\" >\n" + |
| | | " <input class=\"control-label\" id=\"content-"+i+"\" name=\"content\" placeholder=\"请输入\" style=\"width: 180px;height: 30px\">\n" + |
| | | " <span class=\"fa fa-remove\" onclick=\"TMainContent.delBox(this)\"></span>\n" + |
| | | " </div>" |
| | | |
| | | $("#rules").append($(a)) |
| | | } |
| | | |
| | | TMainContent.delBox = function (o) { |
| | | $(o).parent("div").remove() |
| | | }; |
| | | |
| | | |
| | | /** |
| | | * 打开查看详情 |
| | | */ |
| | | TMainContent.openTMainContentDetail = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '详情', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tMainContent/tMainContent_update/' + TMainContent.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | TMainContent.delete = function () { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/delete", function (data) { |
| | | Feng.success("删除成功!"); |
| | | TMainContent.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("删除失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("tMainContentId",this.seItem.id); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 查询列表 |
| | | */ |
| | | TMainContent.search = function () { |
| | | var queryData = {}; |
| | | queryData['condition'] = $("#condition").val(); |
| | | TMainContent.table.refresh({query: queryData}); |
| | | }; |
| | | |
| | | $(function () { |
| | | var defaultColunms = TMainContent.initColumn(); |
| | | var table = new BSTable(TMainContent.id, "/tMainContent/list", defaultColunms); |
| | | table.setPaginationType("client"); |
| | | TMainContent.table = table.init(); |
| | | }); |
New file |
| | |
| | | /** |
| | | * 初始化详情对话框 |
| | | */ |
| | | var TMainContentInfoDlg = { |
| | | tMainContentInfoData : {} |
| | | }; |
| | | |
| | | /** |
| | | * 清除数据 |
| | | */ |
| | | TMainContentInfoDlg.clearData = function() { |
| | | this.tMainContentInfoData = {}; |
| | | } |
| | | |
| | | /** |
| | | * 设置对话框中的数据 |
| | | * |
| | | * @param key 数据的名称 |
| | | * @param val 数据的具体值 |
| | | */ |
| | | TMainContentInfoDlg.set = function(key, val) { |
| | | this.tMainContentInfoData[key] = (typeof val == "undefined") ? $("#" + key).val() : val; |
| | | return this; |
| | | } |
| | | |
| | | /** |
| | | * 设置对话框中的数据 |
| | | * |
| | | * @param key 数据的名称 |
| | | * @param val 数据的具体值 |
| | | */ |
| | | TMainContentInfoDlg.get = function(key) { |
| | | return $("#" + key).val(); |
| | | } |
| | | |
| | | /** |
| | | * 关闭此对话框 |
| | | */ |
| | | TMainContentInfoDlg.close = function() { |
| | | parent.layer.close(window.parent.TMainContent.layerIndex); |
| | | } |
| | | |
| | | /** |
| | | * 收集数据 |
| | | */ |
| | | TMainContentInfoDlg.collectData = function() { |
| | | this |
| | | .set('id') |
| | | .set('type') |
| | | .set('content') |
| | | .set('status') |
| | | .set('createTime'); |
| | | } |
| | | |
| | | /** |
| | | * 提交添加 |
| | | */ |
| | | TMainContentInfoDlg.addSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/add", function(data){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set(this.tMainContentInfoData); |
| | | ajax.start(); |
| | | } |
| | | /** |
| | | * 转单添加提交 |
| | | */ |
| | | TMainContentInfoDlg.transferOrderAddSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/add", function(data){ |
| | | Feng.success("添加成功!"); |
| | | parent.location.reload() |
| | | TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | |
| | | var reqData = ""; |
| | | var n = $('input[name="content"]').length; |
| | | for (let i = 0; i < n; i++) { |
| | | if(i == (n-1)){ |
| | | reqData += $($('input[name="content"]')[i]).val() |
| | | }else { |
| | | reqData += $($('input[name="content"]')[i]).val() + ","; |
| | | } |
| | | } |
| | | ajax.set("tMainContents",reqData); |
| | | ajax.set("type",1); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 转单修改提交 |
| | | */ |
| | | TMainContentInfoDlg.transferOrderUpdateSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/update", function(data){ |
| | | Feng.success("添加成功!"); |
| | | parent.location.reload() |
| | | TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | |
| | | var reqData = ""; |
| | | var n = $('input[name="content"]').length; |
| | | for (let i = 0; i < n; i++) { |
| | | if(i == (n-1)){ |
| | | reqData += $($('input[name="content"]')[i]).val() |
| | | }else { |
| | | reqData += $($('input[name="content"]')[i]).val() + ","; |
| | | } |
| | | } |
| | | ajax.set("tMainContents",reqData); |
| | | ajax.set("type",1); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 消单添加提交 |
| | | */ |
| | | TMainContentInfoDlg.driverCancelOrderAddSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/add", function(data){ |
| | | Feng.success("添加成功!"); |
| | | parent.location.reload() |
| | | TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | |
| | | var reqData = ""; |
| | | var n = $('input[name="content"]').length; |
| | | for (let i = 0; i < n; i++) { |
| | | if(i == (n-1)){ |
| | | reqData += $($('input[name="content"]')[i]).val() |
| | | }else { |
| | | reqData += $($('input[name="content"]')[i]).val() + ","; |
| | | } |
| | | } |
| | | ajax.set("tMainContents",reqData); |
| | | ajax.set("type",2); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 消单修改提交 |
| | | */ |
| | | TMainContentInfoDlg.driverCancelOrderUpdateSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/update", function(data){ |
| | | Feng.success("添加成功!"); |
| | | parent.location.reload() |
| | | TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | |
| | | var reqData = ""; |
| | | var n = $('input[name="content"]').length; |
| | | for (let i = 0; i < n; i++) { |
| | | if(i == (n-1)){ |
| | | reqData += $($('input[name="content"]')[i]).val() |
| | | }else { |
| | | reqData += $($('input[name="content"]')[i]).val() + ","; |
| | | } |
| | | } |
| | | ajax.set("tMainContents",reqData); |
| | | ajax.set("type",2); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 取消订单添加提交 |
| | | */ |
| | | TMainContentInfoDlg.userCancelOrderAddSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/add", function(data){ |
| | | Feng.success("添加成功!"); |
| | | parent.location.reload() |
| | | TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | |
| | | var reqData = ""; |
| | | var n = $('input[name="content"]').length; |
| | | for (let i = 0; i < n; i++) { |
| | | if(i == (n-1)){ |
| | | reqData += $($('input[name="content"]')[i]).val() |
| | | }else { |
| | | reqData += $($('input[name="content"]')[i]).val() + ","; |
| | | } |
| | | } |
| | | ajax.set("tMainContents",reqData); |
| | | ajax.set("type",3); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 取消订单修改提交 |
| | | */ |
| | | TMainContentInfoDlg.userCancelOrderUpdateSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/update", function(data){ |
| | | Feng.success("添加成功!"); |
| | | parent.location.reload() |
| | | TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | |
| | | var reqData = ""; |
| | | var n = $('input[name="content"]').length; |
| | | for (let i = 0; i < n; i++) { |
| | | if(i == (n-1)){ |
| | | reqData += $($('input[name="content"]')[i]).val() |
| | | }else { |
| | | reqData += $($('input[name="content"]')[i]).val() + ","; |
| | | } |
| | | } |
| | | ajax.set("tMainContents",reqData); |
| | | ajax.set("type",3); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 提交修改 |
| | | */ |
| | | TMainContentInfoDlg.editSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tMainContent/update", function(data){ |
| | | Feng.success("修改成功!"); |
| | | window.parent.TMainContent.table.refresh(); |
| | | TMainContentInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("修改失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set(this.tMainContentInfoData); |
| | | ajax.start(); |
| | | } |
| | | |
| | | $(function() { |
| | | |
| | | }); |