igds-core/src/main/java/com/ld/igds/models/GrainOilShop.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
igds-core/src/main/java/com/ld/igds/view/GrainOilShop.view.xml | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
igds-core/src/main/java/com/ld/igds/view/GrainOilShopPR.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
igds-core/src/main/java/com/ld/igds/view/service/HGrainOilShopService.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
igds-web/src/main/java/com/ld/igds/web/WebController.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
igds-web/src/main/resources/templates/index/index-5327.html | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
igds-core/src/main/java/com/ld/igds/models/GrainOilShop.java
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,86 @@ package com.ld.igds.models; import com.bstek.dorado.annotation.PropertyDef; import lombok.Data; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.Id; import javax.persistence.Table; import java.io.Serializable; import java.util.Date; /** * @Desc: åºç¡ä¿¡æ¯-æ¾å¿ç²®æ²¹åº * @author: czt * @update-time: 2023/09/14 */ @Data @Entity @Table(name = "D_GRAIN_OIL_SHOP") public class GrainOilShop implements Serializable { private static final long serialVersionUID = 9157617424050247565L; @Id @PropertyDef(label = "粮油åºç¼ç ") @Column(name = "lydbh", length = 28) private String lydbh; @Column(name = "COMPANY_ID_", length = 10) @PropertyDef(label = "ç»ç»ç¼ç ") private String companyId; @Column(name = "DEPT_ID_", length = 40) @PropertyDef(label = "æå±ååº") private String deptId; @PropertyDef(label = "粮油åºåç§°") @Column(name = "lydmc", length = 100) private String lydmc; @PropertyDef(label = "è¡æ¿åºåç¼ç ") @Column(name = "xzqhbm", length = 25) private String xzqhbm; @PropertyDef(label = "è¡æ¿åºååç§°") @Column(name = "xzqhmc", length = 50) private String xzqhmc; @PropertyDef(label = "è系人") @Column(name = "lxr", length = 50) private String lxr; @PropertyDef(label = "è系人çµè¯") @Column(name = "lxrdh", length = 50) private String lxrdh; @PropertyDef(label = "è¦çèå´") @Column(name = "fgfw") private Double fgfw; @Column(name = "LON_", precision = 16, scale = 4) @PropertyDef(label = "ç»åº¦") private Double lon; @Column(name = "LAT_", precision = 16, scale = 4) @PropertyDef(label = "纬度") private Double lat; @Column(name = "sjcr") @PropertyDef(label = "å®é ä»å®¹", description = "åä½ï¼å¨") private Double sjcr; @PropertyDef(label = "å°å") @Column(name = "dz", length = 200) private String dz; @PropertyDef(label = "夿³¨") @Column(name = "bz", length = 200) private String bz; @Column(name = "UPDATE_TIME_") @PropertyDef(label = "æ´æ°æ¶é´") private Date updateTime; } igds-core/src/main/java/com/ld/igds/view/GrainOilShop.view.xml
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,305 @@ <?xml version="1.0" encoding="UTF-8"?> <ViewConfig> <Arguments/> <Context/> <Model> <DataType name="dtMain"> <Property name="creationType">com.ld.igds.models.GrainOilShop</Property> <PropertyDef name="lydbh"> <Property></Property> <Property name="label">粮油åºç¼ç </Property> </PropertyDef> <PropertyDef name="companyId"> <Property></Property> <Property name="label">ç»ç»ç¼ç </Property> </PropertyDef> <PropertyDef name="deptId"> <Property></Property> <Property name="label">æå±ååº</Property> </PropertyDef> <PropertyDef name="lydmc"> <Property></Property> <Property name="label">åç§°</Property> </PropertyDef> <PropertyDef name="xzqhbm"> <Property name="label">è¡æ¿åºåç¼ç </Property> </PropertyDef> <PropertyDef name="xzqhmc"> <Property name="label">è¡æ¿åºååç§°</Property> </PropertyDef> <PropertyDef name="lxr"> <Property name="label">è系人</Property> </PropertyDef> <PropertyDef name="lxrdh"> <Property></Property> <Property name="label">è系人çµè¯</Property> </PropertyDef> <PropertyDef name="fgfw"> <Property name="dataType">Double</Property> <Property name="label">è¦çèå´</Property> <Property name="displayFormat">#0.00å ¬é</Property> </PropertyDef> <PropertyDef name="sjcr"> <Property name="dataType">Double</Property> <Property name="label">å®é ä»å®¹</Property> <Property name="displayFormat">#0.00å¨</Property> </PropertyDef> <PropertyDef name="ajqyrq"> <Property name="dataType">Date</Property> <Property name="label">å»é´å¯ç¨æ¥æ</Property> </PropertyDef> <PropertyDef name="dz"> <Property></Property> <Property name="label">å°å</Property> </PropertyDef> <PropertyDef name="lon"> <Property></Property> <Property name="label">ç»åº¦</Property> </PropertyDef> <PropertyDef name="lat"> <Property></Property> <Property name="label">纬度</Property> </PropertyDef> <PropertyDef name="bz"> <Property></Property> <Property name="label">夿³¨</Property> </PropertyDef> <PropertyDef name="updateTime"> <Property name="dataType">Date</Property> <Property name="label">æ°æ®æ´æ°æ¶é´</Property> </PropertyDef> </DataType> <DataType name="dtParam"> <PropertyDef name="lydmc"> <Property name="label">粮油åºåç§°</Property> </PropertyDef> </DataType> </Model> <View layout="regionPadding:10"> <ClientEvent name="onReady">view.get("#dsParam").insert({});</ClientEvent> <Property name="packages">font-awesome,css-common</Property> <DataSet id="dsMain"> <Property name="dataProvider">grainOilShopPR#pageData</Property> <Property name="dataType">[dtMain]</Property> <Property name="pageSize">15</Property> </DataSet> <DataSet id="dsParam"> <Property name="dataType">dtParam</Property> </DataSet> <Container layout="regionPadding:10" layoutConstraint="top"> <Property name="exClassName">bg-color</Property> <Property name="height">55</Property> <Property name="contentOverflow">hidden</Property> <Label layoutConstraint="left"> <Property name="text">èåæ ï¼</Property> </Label> <Button layoutConstraint="left"> <ClientEvent name="onClick">view.get("#dsMain").insert();
 view.get("#dialogMain").show();</ClientEvent> <Property name="caption">æ°å¢</Property> <Property name="exClassName">btn-normal</Property> <Property name="iconClass">fa fa-plus</Property> </Button> <Button layoutConstraint="left"> <ClientEvent name="onClick">var dialog= view.get("#dialogMain");
 dialog.show();</ClientEvent> <Property name="caption">ç¼è¾</Property> <Property name="exClassName">btn-warm</Property> <Property name="iconClass">fa fa-pencil</Property> </Button> <Button layoutConstraint="left"> <ClientEvent name="onClick">var cur = view.get("#dsMain.data:#");
 if(!cur) return;
 view.get("#ajaxDel").set("parameter",cur).execute(function(result){
 if(result){
 $alert(result);
 return;
 }else{
 cur.remove();
 }
 });</ClientEvent> <Property name="caption">å é¤</Property> <Property name="exClassName">btn-warn</Property> <Property name="iconClass">fa fa-trash-o</Property> </Button> </Container> <Container layout="regionPadding:10" layoutConstraint="center"> <Property name="exClassName">bg-color</Property> <AutoForm> <Property name="dataSet">dsParam</Property> <Property name="cols">*,*,*,*</Property> <AutoFormElement> <Property name="name">lydmc</Property> <Property name="property">lydmc</Property> <Editor/> </AutoFormElement> <Container layout="regionPadding:10"> <Button layoutConstraint="left"> <ClientEvent name="onClick">var param = view.get("#dsParam.data");
 view.get("#dsMain").set("parameter",param).flushAsync();</ClientEvent> <Property name="caption">æ¥è¯¢</Property> <Property name="exClassName">btn-normal</Property> <Property name="iconClass">fa fa-search</Property> </Button> <Button layoutConstraint="left"> <ClientEvent name="onClick">view.get("#dsParam").flushAsync();</ClientEvent> <Property name="caption">éç½®</Property> <Property name="iconClass">fa fa-refresh</Property> <Property name="exClassName">btn-default</Property> </Button> </Container> </AutoForm> <DataGrid id="dgMain"> <ClientEvent name="onDataRowDoubleClick">var dialog= view.get("#dialogMain");
 dialog.show();</ClientEvent> <Property name="dataSet">dsMain</Property> <Property name="readOnly">true</Property> <RowNumColumn/> <DataColumn name="lydmc"> <Property name="property">lydmc</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="xzqhmc"> <Property name="property">xzqhmc</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="lxr"> <Property name="property">lxr</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="lxrdh"> <Property name="property">lxrdh</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="fgfw"> <Property name="property">fgfw</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="sjcr"> <Property name="property">sjcr</Property> <Property name="align">center</Property> </DataColumn> <DataColumn name="updateTime"> <Property name="property">updateTime</Property> <Property name="align">center</Property> </DataColumn> </DataGrid> </Container> <Container layoutConstraint="bottom"> <Property name="exClassName">bg-color</Property> <DataPilot layoutConstraint="right"> <Property name="dataSet">dsMain</Property> <Property name="itemCodes">pageSize,pages</Property> </DataPilot> </Container> <Dialog id="dialogMain"> <Property name="closeable">false</Property> <Property name="caption">粮油åºä¿¡æ¯</Property> <Property name="width">60%</Property> <Property name="iconClass">fa fa-tasks</Property> <Buttons> <Button id="btnOk"> <ClientEvent name="onClick">view.get("#uaSave").execute(function(result){
 if(result){
 $alert(result);
 }else{
 $notify("ä¿åæåï¼ï¼");
 view.get("#dialogMain").hide();
 }
 });</ClientEvent> <Property name="caption">ç¡®å®</Property> <Property name="iconClass">fa fa-check</Property> </Button> <Button> <ClientEvent name="onClick">view.get("#dsMain.data:#").cancel();
 self.get("parent").hide();</ClientEvent> <Property name="caption">åæ¶</Property> <Property name="iconClass">fa fa-times</Property> </Button> </Buttons> <Children> <AutoForm> <Property name="dataSet">dsMain</Property> <Property name="cols">*,*</Property> <Property name="labelAlign">right</Property> <Property name="labelSeparator">ï¼</Property> <Property name="labelWidth">150</Property> <AutoFormElement> <Property name="name">lydbh</Property> <Property name="property">lydbh</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">deptId</Property> <Property name="property">deptId</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lydmc</Property> <Property name="property">lydmc</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">xzqhbm</Property> <Property name="property">xzqhbm</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lxr</Property> <Property name="property">lxr</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lxrdh</Property> <Property name="property">lxrdh</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">fgfw</Property> <Property name="property">fgfw</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lon</Property> <Property name="property">lon</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">lat</Property> <Property name="property">lat</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">sjcr</Property> <Property name="property">sjcr</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">dz</Property> <Property name="property">dz</Property> <Editor/> </AutoFormElement> <AutoFormElement> <Property name="name">bz</Property> <Property name="property">bz</Property> <Editor/> </AutoFormElement> </AutoForm> </Children> <Tools/> </Dialog> <UpdateAction id="uaSave"> <Property name="dataResolver">grainOilShopPR#saveData</Property> <Property name="successMessage">æ°æ®ä¿å宿ï¼</Property> <UpdateItem> <Property name="dataSet">dsMain</Property> <Property name="dataPath">[#current]</Property> <Property name="validateData">false</Property> </UpdateItem> </UpdateAction> <AjaxAction id="ajaxDel"> <Property name="service">grainOilShopPR#delData</Property> <Property name="confirmMessage">ç¡®å®è¦æ§è¡å é¤ä¹ï¼</Property> </AjaxAction> </View> </ViewConfig> igds-core/src/main/java/com/ld/igds/view/GrainOilShopPR.java
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,59 @@ package com.ld.igds.view; import com.bstek.dorado.annotation.DataProvider; import com.bstek.dorado.annotation.DataResolver; import com.bstek.dorado.annotation.Expose; import com.bstek.dorado.data.provider.Page; import com.ld.igds.models.GrainOilShop; import com.ld.igds.view.service.HGrainOilShopService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import java.util.Map; /** * å»é´ä¿¡æ¯ * * @Author:YAN */ @Component public class GrainOilShopPR { @Autowired private HGrainOilShopService grainOilShopService; /** * grainOilShopPR#pageData * * @param page * @param param * @throws Exception */ @DataProvider public void pageData(Page<GrainOilShop> page, Map<String, Object> param) throws Exception { grainOilShopService.pageData(page, param); } /** * grainOilShopPR#delData * * @param data * @throws Exception */ @Expose public String delData(GrainOilShop data) throws Exception { return grainOilShopService.delData(data); } /** * grainOilShopPR#saveData æ°å¢æè ä¿®æ¹ * * @param data * @throws Exception */ @DataResolver public String saveData(GrainOilShop data) throws Exception { grainOilShopService.saveOrUpdate(data); return ""; } } igds-core/src/main/java/com/ld/igds/view/service/HGrainOilShopService.java
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,77 @@ package com.ld.igds.view.service; import com.bstek.bdf2.core.orm.hibernate.HibernateDao; import com.bstek.dorado.data.provider.Page; import com.ld.igds.models.GrainOilShop; import com.ld.igds.models.Granary; import com.ld.igds.util.ContextUtil; import org.apache.commons.lang3.StringUtils; import org.hibernate.Session; import org.springframework.stereotype.Component; import java.util.HashMap; import java.util.Map; /** * åºç¡ä¿¡æ¯-å»é´ä¿¡æ¯ * * @Author:YAN */ @Component public class HGrainOilShopService extends HibernateDao { public void pageData(Page<GrainOilShop> page, Map<String, Object> param) throws Exception { String hql = " from " + Granary.class.getName() + " where companyId=:companyId"; Map<String, Object> args = new HashMap<String, Object>(); args.put("companyId", ContextUtil.getCompanyId()); if (null != param) { String str = (String) param.get("name"); if (StringUtils.isNotEmpty(str)) { hql += " and lydmc like:name"; args.put("name", "%" + str + "%"); } } String count = "select count(*) " + hql; hql += " order by updateTime desc"; this.pagingQuery(page, hql, count, args); } public String saveOrUpdate(GrainOilShop data) { Session session = this.getSessionFactory().openSession(); try { if (null == data.getDeptId()) { data.setDeptId(ContextUtil.subDeptId(null)); } data.setCompanyId(ContextUtil.getCompanyId()); session.saveOrUpdate(data); } finally { session.flush(); session.close(); } return null; } public String delData(GrainOilShop data) { Session session = this.getSessionFactory().openSession(); try { session.delete(data); } finally { session.flush(); session.close(); } return null; } } igds-web/src/main/java/com/ld/igds/web/WebController.java
@@ -108,10 +108,14 @@ if ("5303".equals(companyId)) { view.setViewName("index/index-5303"); } //é西å®åº· if ("5318".equals(companyId)) { view.setViewName("index/index-5318"); } //æ¦æ±åç²® if ("5327".equals(companyId)) { view.setViewName("index/index-5327"); } return view; } igds-web/src/main/resources/templates/index/index-5327.html
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,221 @@ <!DOCTYPE html> <html lang="zh-cn" xmlns:th=http://www.thymeleaf.org> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> <meta name="renderer" content="webkit"> <title>æºæ §ä»åºç®¡çç³»ç» -é¦é¡µ</title> <meta name="description" content="æºæ §ä»åºç®¡çç³»ç»"> <link rel="shortcut icon" th:href="@{/static/favicon.ico}"/> <link th:href="@{/static/plugins/layui/css/layui.css}" rel="stylesheet" type="text/css"> <link th:href="@{/static/index/index.css}" rel="stylesheet" type="text/css"> </head> <style> .i-footer p { line-height: 24px; /* color: #8a99a6; */ color: #FFF; font-size: 16px; } .i-tit img { height: 96px; } .dis-none{ display: none !important; } </style> <body> <div class="i-bodyBg"> <img th:src="@{/static/images/i-body2.png}"/> </div> <div class="i-container "> <div class="i-top layui-row"> <div class="layui-col-lg6"> <h1 class="i-logo"> <img th:src="${logoTitle}"/> </h1> </div> <div class="i-top-r"> <a id="menu-group" href="./home-group" target="_self" class="i-top-btn dis-none"> <i class="i-icon"> <img th:src="@{/static/images/i-icon-sy.png}" style="height: 28px;width: 28px;"/> </i> é¦é¡µ </a> <a href="./basic/common/help-center" target="_blank" class="i-top-btn"> <i class="i-icon"> <img th:src="@{/static/images/i-icon-help.png}"/> </i> å¸®å© </a> <a href="./basic/databoard/index-gateway" target="_blank" class="i-top-btn"> <i class="i-icon"> <img th:src="@{/static/images/i-icon-dpm.png}"/> </i> 综åå¤§å± </a> <a href="./basic/databoard/inout" target="_blank" class="i-top-btn"> <i class="i-icon"> <img th:src="@{/static/images/i-icon-dpm.png}"/> </i> åºå ¥åºå¤§å± </a> <a href="./log-out" class="i-top-btn"> <i class="i-icon"> <img th:src="@{/static/images/i-icon-tc.png}"/> </i> éåºç»å½ </a> </div> </div> </div> <!--i-top end--> <h2 class="i-tit"> <img th:src="@{/static/images/login-titimg2.png}"/> </h2> <div class="i-main layui-row"> <div class="layui-col-lg6"> <div class="i-menuBox"> <span class="i-menu-item i-menu-tit"> <img th:src="@{/static/images/i-bg-tit1.png}"/> </span> <span class="i-menu-item i-menu1 i-navBg1"> <a href="javascript:;" onclick="openByTag('grain')"> <i><img th:src="@{/static/images/i-icon-lq.png}"/></i> <P>ç²®æ æµæ§</P> </a> </span> <span class="i-menu-item i-menu2 i-navBg2"> <a href="javascript:;" onclick="openByTag('verb')"> <i><img th:src="@{/static/images/i-icon-zntf.png}"/></i> <P>æºè½éé£</P> </a> </span> <span class="i-menu-item i-menu3 i-navBg3"> <a href="javascript:;" onclick="openByTag('es')"> <i><img th:src="@{/static/images/i-icon-nhgl.png}"/></i> <P>è½èçæµ</P> </a> </span> <span class="i-menu-item i-menu4 i-navBg4"> <a href="javascript:;" onclick="openByTag('warn')"> <i><img th:src="@{/static/images/i-icon-ai.png}"/></i> <P>é éè·è¸ª</P> </a> </span> <span class="i-menu-item i-menu5 i-navBg5"> <a href="javascript:;" onclick="openQuantity()"> <i><img th:src="@{/static/images/i-icon-sljc.png}"/></i> <P>çå¹³å°å¯¹æ¥</P> </a> </span> <span class="i-menu-item i-menu6 i-navBg6"> <a href="javascript:;" onclick="openByTag('temp')"> <i><img th:src="@{/static/images/i-icon-wkgl.png}"/></i> <P>æºè½æ¸©æ§</P> </a> </span> </div> <!--i-menuBox end--> </div> <div class="layui-col-lg6"> <div class="i-menuBox"> <span class="i-menu-item i-menu-tit"> <img th:src="@{/static/images/i-bg-tit2.png}"/> </span> <span class="i-menu-item i-menu1 i-navBg6"> <a href="javascript:;" onclick="openByTag('inout')"> <i><img th:src="@{/static/images/i-icon-crkgl.png}"/></i> <P>åºå ¥åºç©æµç®¡ç</P> </a> </span> <span class="i-menu-item i-menu2 i-navBg3"> <a href="javascript:;" onclick="openByTag('manager')"> <i><img th:src="@{/static/images/i-icon-zhyw.png}"/></i> <P>ä¸å¡ç®¡ç</P> </a> </span> <span class="i-menu-item i-menu3 i-navBg4"> <a href="javascript:;" onClick="open3d()"> <i><img th:src="@{/static/images/i-icon-swzs.png}"/></i> <P>ä¸ç»´å±ç¤º</P> </a> </span> <span class="i-menu-item i-menu4 i-navBg5"> <a href="javascript:;" onclick="openByTag('sys')"> <i><img th:src="@{/static/images/i-icon-xtgl.png}"/></i> <P>ç³»ç»ç®¡ç</P> </a> </span> <span class="i-menu-item i-menu5 i-navBg2"> <a href="javascript:;" onclick="openByTag('n2')"> <i><img th:src="@{/static/images/i-icon-znqd.png}"/></i> <P>ç°åºç®¡æ§</P> </a> </span> <span class="i-menu-item i-menu6 i-navBg1"> <a href="javascript:;" onclick="openByTag('security')"> <i><img th:src="@{/static/images/i-icon-afgl.png}"/></i> <P>æºè½å®é²</P> </a> </span> </div> <!--i-menuBox end--> </div> </div> <!--i-main end--> <div class="i-footer"> <p th:text=${support}>ææ¯æ¯æ: 飿£è´è¿ä¿¡æ¯ææ¯è¡ä»½æéå ¬å¸</p> </div> <script th:src="@{/static/js/jquery.min.js}"></script> <script th:inline="javascript"> //å®ä¹åé var companyId = [[${loginUser.companyId}]]; //userId var userId = [[${loginUser.username}]]; //æ°éæ£æµè®¿é®å°å var quantityPath = [[${quantityPath}]]; //ä¸ç»´è·¯å¾ var threePath = [[${threePath}]]; var groupTag = [[${groupTag}]];//æ¯å¦é墿è å ¬å¸ç¨æ·è¿å ¥ window.onload = function () { //表示éå¢/å ¬å¸ç¨æ·è¿å ¥ if(1 == groupTag){ $("#menu-group").removeClass("dis-none"); } }; function openByTag(tag) { window.open("./home?t="+tag+"&g="+groupTag, "_self"); }; //æå¼è´¨éæ£ function openQuantity() { if ("#" == quantityPath) { openByTag("quantity") } else { window.open(quantityPath, "_blank"); } }; //æå¼è´¨éæ£æµ function open3d() { if ("#" == threePath) { window.open("#", "_self"); } else { window.open(threePath, "_blank"); } }; </script> </body> </html>