机房和机柜先提交一下
This commit is contained in:
parent
2302a1f447
commit
5ebd161995
|
|
@ -0,0 +1,124 @@
|
||||||
|
package com.ruoyi.web.controller.assets;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsCabinet;
|
||||||
|
import com.ruoyi.assets.service.IAssetsCabinetService;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.ui.ModelMap;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机柜类型 信息操作处理
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/assets/assetsCabinet")
|
||||||
|
public class AssetsCabinetController extends BaseController
|
||||||
|
{
|
||||||
|
private String prefix = "assets/assetsCabinet";
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IAssetsCabinetService assetsCabinetService;
|
||||||
|
|
||||||
|
@RequiresPermissions("assets:assetsCabinet:view")
|
||||||
|
@GetMapping()
|
||||||
|
public String assetsCabinet()
|
||||||
|
{
|
||||||
|
return prefix + "/assetsCabinet";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机柜类型列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsCabinet:list")
|
||||||
|
@PostMapping("/list")
|
||||||
|
@ResponseBody
|
||||||
|
public TableDataInfo list(AssetsCabinet assetsCabinet)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<AssetsCabinet> list = assetsCabinetService.selectAssetsCabinetList(assetsCabinet);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出机柜类型列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsCabinet:export")
|
||||||
|
@PostMapping("/export")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult export(AssetsCabinet assetsCabinet)
|
||||||
|
{
|
||||||
|
List<AssetsCabinet> list = assetsCabinetService.selectAssetsCabinetList(assetsCabinet);
|
||||||
|
ExcelUtil<AssetsCabinet> util = new ExcelUtil<AssetsCabinet>(AssetsCabinet.class);
|
||||||
|
return util.exportExcel(list, "assetsCabinet");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机柜类型
|
||||||
|
*/
|
||||||
|
@GetMapping("/add")
|
||||||
|
public String add()
|
||||||
|
{
|
||||||
|
return prefix + "/add";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增保存机柜类型
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsCabinet:add")
|
||||||
|
@Log(title = "机柜类型", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping("/add")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult addSave(AssetsCabinet assetsCabinet)
|
||||||
|
{
|
||||||
|
return toAjax(assetsCabinetService.insertAssetsCabinet(assetsCabinet));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机柜类型
|
||||||
|
*/
|
||||||
|
@GetMapping("/edit/{cabinetId}")
|
||||||
|
public String edit(@PathVariable("cabinetId") Integer cabinetId, ModelMap mmap)
|
||||||
|
{
|
||||||
|
AssetsCabinet assetsCabinet = assetsCabinetService.selectAssetsCabinetById(cabinetId);
|
||||||
|
mmap.put("assetsCabinet", assetsCabinet);
|
||||||
|
return prefix + "/edit";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改保存机柜类型
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsCabinet:edit")
|
||||||
|
@Log(title = "机柜类型", businessType = BusinessType.UPDATE)
|
||||||
|
@PostMapping("/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult editSave(AssetsCabinet assetsCabinet)
|
||||||
|
{
|
||||||
|
return toAjax(assetsCabinetService.updateAssetsCabinet(assetsCabinet));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机柜类型
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsCabinet:remove")
|
||||||
|
@Log(title = "机柜类型", businessType = BusinessType.DELETE)
|
||||||
|
@PostMapping( "/remove")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult remove(String ids)
|
||||||
|
{
|
||||||
|
return toAjax(assetsCabinetService.deleteAssetsCabinetByIds(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,124 @@
|
||||||
|
package com.ruoyi.web.controller.assets;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsMachineRoom;
|
||||||
|
import com.ruoyi.assets.service.IAssetsMachineRoomService;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.ui.ModelMap;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机房 信息操作处理
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/assets/assetsMachineRoom")
|
||||||
|
public class AssetsMachineRoomController extends BaseController
|
||||||
|
{
|
||||||
|
private String prefix = "assets/assetsMachineRoom";
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IAssetsMachineRoomService assetsMachineRoomService;
|
||||||
|
|
||||||
|
@RequiresPermissions("assets:assetsMachineRoom:view")
|
||||||
|
@GetMapping()
|
||||||
|
public String assetsMachineRoom()
|
||||||
|
{
|
||||||
|
return prefix + "/assetsMachineRoom";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机房列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsMachineRoom:list")
|
||||||
|
@PostMapping("/list")
|
||||||
|
@ResponseBody
|
||||||
|
public TableDataInfo list(AssetsMachineRoom assetsMachineRoom)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<AssetsMachineRoom> list = assetsMachineRoomService.selectAssetsMachineRoomList(assetsMachineRoom);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出机房列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsMachineRoom:export")
|
||||||
|
@PostMapping("/export")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult export(AssetsMachineRoom assetsMachineRoom)
|
||||||
|
{
|
||||||
|
List<AssetsMachineRoom> list = assetsMachineRoomService.selectAssetsMachineRoomList(assetsMachineRoom);
|
||||||
|
ExcelUtil<AssetsMachineRoom> util = new ExcelUtil<AssetsMachineRoom>(AssetsMachineRoom.class);
|
||||||
|
return util.exportExcel(list, "assetsMachineRoom");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机房
|
||||||
|
*/
|
||||||
|
@GetMapping("/add")
|
||||||
|
public String add()
|
||||||
|
{
|
||||||
|
return prefix + "/add";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增保存机房
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsMachineRoom:add")
|
||||||
|
@Log(title = "机房", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping("/add")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult addSave(AssetsMachineRoom assetsMachineRoom)
|
||||||
|
{
|
||||||
|
return toAjax(assetsMachineRoomService.insertAssetsMachineRoom(assetsMachineRoom));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机房
|
||||||
|
*/
|
||||||
|
@GetMapping("/edit/{machineRoomId}")
|
||||||
|
public String edit(@PathVariable("machineRoomId") Integer machineRoomId, ModelMap mmap)
|
||||||
|
{
|
||||||
|
AssetsMachineRoom assetsMachineRoom = assetsMachineRoomService.selectAssetsMachineRoomById(machineRoomId);
|
||||||
|
mmap.put("assetsMachineRoom", assetsMachineRoom);
|
||||||
|
return prefix + "/edit";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改保存机房
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsMachineRoom:edit")
|
||||||
|
@Log(title = "机房", businessType = BusinessType.UPDATE)
|
||||||
|
@PostMapping("/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult editSave(AssetsMachineRoom assetsMachineRoom)
|
||||||
|
{
|
||||||
|
return toAjax(assetsMachineRoomService.updateAssetsMachineRoom(assetsMachineRoom));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机房
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("assets:assetsMachineRoom:remove")
|
||||||
|
@Log(title = "机房", businessType = BusinessType.DELETE)
|
||||||
|
@PostMapping( "/remove")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult remove(String ids)
|
||||||
|
{
|
||||||
|
return toAjax(assetsMachineRoomService.deleteAssetsMachineRoomByIds(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -48,7 +48,6 @@ public class TmplServerController extends BaseController {
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出服务器模板列表
|
* 导出服务器模板列表
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -2495,7 +2495,7 @@
|
||||||
// Trigger select 'change'
|
// Trigger select 'change'
|
||||||
if (triggerChange) {
|
if (triggerChange) {
|
||||||
if (that.multiple || prevIndex !== element.selectedIndex) {
|
if (that.multiple || prevIndex !== element.selectedIndex) {
|
||||||
// $option.prop('selected') is current option state (selected/unselected). prevValue is the value of the select prior to being changed.
|
// $option.assets('selected') is current option state (selected/unselected). prevValue is the value of the select prior to being changed.
|
||||||
changedArguments = [option.index, $option.prop('selected'), prevValue];
|
changedArguments = [option.index, $option.prop('selected'), prevValue];
|
||||||
that.$element
|
that.$element
|
||||||
.triggerNative('change');
|
.triggerNative('change');
|
||||||
|
|
|
||||||
|
|
@ -2019,7 +2019,7 @@
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
// get computed style property
|
// get computed style assets
|
||||||
function getStyle (target, prop) {
|
function getStyle (target, prop) {
|
||||||
try {
|
try {
|
||||||
if ( window.getComputedStyle ) { // gecko and webkit
|
if ( window.getComputedStyle ) { // gecko and webkit
|
||||||
|
|
|
||||||
|
|
@ -232,7 +232,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
|
||||||
if (elements.index(this.$element) !== -1) {
|
if (elements.index(this.$element) !== -1) {
|
||||||
$(this.$element).data('offcanvas-style', $(this.$element).attr('style') || '')
|
$(this.$element).data('offcanvas-style', $(this.$element).attr('style') || '')
|
||||||
this.$element.css(placement, -1 * offset)
|
this.$element.css(placement, -1 * offset)
|
||||||
this.$element.css(placement); // Workaround: Need to get the CSS property for it to be applied before the next line of code
|
this.$element.css(placement); // Workaround: Need to get the CSS assets for it to be applied before the next line of code
|
||||||
}
|
}
|
||||||
|
|
||||||
elements.addClass('canvas-sliding').each(function() {
|
elements.addClass('canvas-sliding').each(function() {
|
||||||
|
|
|
||||||
|
|
@ -104,7 +104,7 @@
|
||||||
for (prop in object) {
|
for (prop in object) {
|
||||||
value = object[prop];
|
value = object[prop];
|
||||||
hasContents = true;
|
hasContents = true;
|
||||||
output += "<li><span class=\"prop\"><span class=\"q\">\"</span>" + (this.jsString(prop)) + "<span class=\"q\">\"</span></span>: " + (this.valueToHTML(value, level + 1));
|
output += "<li><span class=\"assets\"><span class=\"q\">\"</span>" + (this.jsString(prop)) + "<span class=\"q\">\"</span></span>: " + (this.valueToHTML(value, level + 1));
|
||||||
if (numProps > 1) {
|
if (numProps > 1) {
|
||||||
output += ',';
|
output += ',';
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -281,7 +281,7 @@ var requirejs, require, define;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//Using ridiculous property names for space reasons
|
//Using ridiculous assets names for space reasons
|
||||||
return {
|
return {
|
||||||
f: prefix ? prefix + '!' + name : name, //fullName
|
f: prefix ? prefix + '!' + name : name, //fullName
|
||||||
n: name,
|
n: name,
|
||||||
|
|
@ -2024,10 +2024,10 @@ S2.define('select2/selection/search',[
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// Try to detect the IE version should the `documentMode` property that
|
// Try to detect the IE version should the `documentMode` assets that
|
||||||
// is stored on the document. This is only implemented in IE and is
|
// is stored on the document. This is only implemented in IE and is
|
||||||
// slightly cleaner than doing a user agent check.
|
// slightly cleaner than doing a user agent check.
|
||||||
// This property is not available in Edge, but Edge also doesn't have
|
// This assets is not available in Edge, but Edge also doesn't have
|
||||||
// this bug.
|
// this bug.
|
||||||
var msie = document.documentMode;
|
var msie = document.documentMode;
|
||||||
var disableInputEvents = msie && msie <= 11;
|
var disableInputEvents = msie && msie <= 11;
|
||||||
|
|
@ -3588,7 +3588,7 @@ S2.define('select2/data/ajax',[
|
||||||
callback(results);
|
callback(results);
|
||||||
}, function () {
|
}, function () {
|
||||||
// Attempt to detect if a request was aborted
|
// Attempt to detect if a request was aborted
|
||||||
// Only works if the transport exposes a status property
|
// Only works if the transport exposes a status assets
|
||||||
if ('status' in $request &&
|
if ('status' in $request &&
|
||||||
($request.status === 0 || $request.status === '0')) {
|
($request.status === 0 || $request.status === '0')) {
|
||||||
return;
|
return;
|
||||||
|
|
@ -5679,7 +5679,7 @@ S2.define('select2/core',[
|
||||||
if (this.options.get('debug') && window.console && console.warn) {
|
if (this.options.get('debug') && window.console && console.warn) {
|
||||||
console.warn(
|
console.warn(
|
||||||
'Select2: The `select2("enable")` method has been deprecated and will' +
|
'Select2: The `select2("enable")` method has been deprecated and will' +
|
||||||
' be removed in later Select2 versions. Use $element.prop("disabled")' +
|
' be removed in later Select2 versions. Use $element.assets("disabled")' +
|
||||||
' instead.'
|
' instead.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -63,7 +63,7 @@ if (!String.prototype.format)
|
||||||
*
|
*
|
||||||
* @static
|
* @static
|
||||||
* @private
|
* @private
|
||||||
* @property _uniqueId
|
* @assets _uniqueId
|
||||||
* @type Integer
|
* @type Integer
|
||||||
**/
|
**/
|
||||||
var _uniqueId = 0;
|
var _uniqueId = 0;
|
||||||
|
|
@ -73,7 +73,7 @@ var _uniqueId = 0;
|
||||||
*
|
*
|
||||||
* @final
|
* @final
|
||||||
* @private
|
* @private
|
||||||
* @property _cookiePrefix
|
* @assets _cookiePrefix
|
||||||
* @type String
|
* @type String
|
||||||
**/
|
**/
|
||||||
var _cookiePrefix = "jQu3ry_5teps_St@te_";
|
var _cookiePrefix = "jQu3ry_5teps_St@te_";
|
||||||
|
|
@ -83,7 +83,7 @@ var _cookiePrefix = "jQu3ry_5teps_St@te_";
|
||||||
*
|
*
|
||||||
* @final
|
* @final
|
||||||
* @private
|
* @private
|
||||||
* @property _tabSuffix
|
* @assets _tabSuffix
|
||||||
* @type String
|
* @type String
|
||||||
* @since 0.9.7
|
* @since 0.9.7
|
||||||
**/
|
**/
|
||||||
|
|
@ -94,7 +94,7 @@ var _tabSuffix = "-t-";
|
||||||
*
|
*
|
||||||
* @final
|
* @final
|
||||||
* @private
|
* @private
|
||||||
* @property _tabpanelSuffix
|
* @assets _tabpanelSuffix
|
||||||
* @type String
|
* @type String
|
||||||
* @since 0.9.7
|
* @since 0.9.7
|
||||||
**/
|
**/
|
||||||
|
|
@ -105,7 +105,7 @@ var _tabpanelSuffix = "-p-";
|
||||||
*
|
*
|
||||||
* @final
|
* @final
|
||||||
* @private
|
* @private
|
||||||
* @property _titleSuffix
|
* @assets _titleSuffix
|
||||||
* @type String
|
* @type String
|
||||||
* @since 0.9.7
|
* @since 0.9.7
|
||||||
**/
|
**/
|
||||||
|
|
@ -116,7 +116,7 @@ var _titleSuffix = "-h-";
|
||||||
*
|
*
|
||||||
* @final
|
* @final
|
||||||
* @private
|
* @private
|
||||||
* @property _indexOutOfRangeErrorMessage
|
* @assets _indexOutOfRangeErrorMessage
|
||||||
* @type String
|
* @type String
|
||||||
**/
|
**/
|
||||||
var _indexOutOfRangeErrorMessage = "Index out of range.";
|
var _indexOutOfRangeErrorMessage = "Index out of range.";
|
||||||
|
|
@ -126,7 +126,7 @@ var _indexOutOfRangeErrorMessage = "Index out of range.";
|
||||||
*
|
*
|
||||||
* @final
|
* @final
|
||||||
* @private
|
* @private
|
||||||
* @property _missingCorrespondingElementErrorMessage
|
* @assets _missingCorrespondingElementErrorMessage
|
||||||
* @type String
|
* @type String
|
||||||
**/
|
**/
|
||||||
var _missingCorrespondingElementErrorMessage = "One or more corresponding step {0} are missing.";
|
var _missingCorrespondingElementErrorMessage = "One or more corresponding step {0} are missing.";
|
||||||
|
|
@ -1485,7 +1485,7 @@ var contentMode = $.fn.steps.contentMode = {
|
||||||
* HTML embedded content
|
* HTML embedded content
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property html
|
* @assets html
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for contentMode
|
* @for contentMode
|
||||||
**/
|
**/
|
||||||
|
|
@ -1495,7 +1495,7 @@ var contentMode = $.fn.steps.contentMode = {
|
||||||
* IFrame embedded content
|
* IFrame embedded content
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property iframe
|
* @assets iframe
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for contentMode
|
* @for contentMode
|
||||||
**/
|
**/
|
||||||
|
|
@ -1505,7 +1505,7 @@ var contentMode = $.fn.steps.contentMode = {
|
||||||
* Async embedded content
|
* Async embedded content
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property async
|
* @assets async
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for contentMode
|
* @for contentMode
|
||||||
**/
|
**/
|
||||||
|
|
@ -1523,7 +1523,7 @@ var stepsOrientation = $.fn.steps.stepsOrientation = {
|
||||||
* Horizontal orientation
|
* Horizontal orientation
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property horizontal
|
* @assets horizontal
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for stepsOrientation
|
* @for stepsOrientation
|
||||||
**/
|
**/
|
||||||
|
|
@ -1533,7 +1533,7 @@ var stepsOrientation = $.fn.steps.stepsOrientation = {
|
||||||
* Vertical orientation
|
* Vertical orientation
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property vertical
|
* @assets vertical
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for stepsOrientation
|
* @for stepsOrientation
|
||||||
**/
|
**/
|
||||||
|
|
@ -1551,7 +1551,7 @@ var transitionEffect = $.fn.steps.transitionEffect = {
|
||||||
* No transition animation
|
* No transition animation
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property none
|
* @assets none
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for transitionEffect
|
* @for transitionEffect
|
||||||
**/
|
**/
|
||||||
|
|
@ -1561,7 +1561,7 @@ var transitionEffect = $.fn.steps.transitionEffect = {
|
||||||
* Fade in transition
|
* Fade in transition
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property fade
|
* @assets fade
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for transitionEffect
|
* @for transitionEffect
|
||||||
**/
|
**/
|
||||||
|
|
@ -1571,7 +1571,7 @@ var transitionEffect = $.fn.steps.transitionEffect = {
|
||||||
* Slide up transition
|
* Slide up transition
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property slide
|
* @assets slide
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for transitionEffect
|
* @for transitionEffect
|
||||||
**/
|
**/
|
||||||
|
|
@ -1581,7 +1581,7 @@ var transitionEffect = $.fn.steps.transitionEffect = {
|
||||||
* Slide left transition
|
* Slide left transition
|
||||||
*
|
*
|
||||||
* @readOnly
|
* @readOnly
|
||||||
* @property slideLeft
|
* @assets slideLeft
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @for transitionEffect
|
* @for transitionEffect
|
||||||
**/
|
**/
|
||||||
|
|
@ -1615,7 +1615,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The header tag is used to find the step button text within the declared wizard area.
|
* The header tag is used to find the step button text within the declared wizard area.
|
||||||
*
|
*
|
||||||
* @property headerTag
|
* @assets headerTag
|
||||||
* @type String
|
* @type String
|
||||||
* @default "h1"
|
* @default "h1"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1625,7 +1625,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The body tag is used to find the step content within the declared wizard area.
|
* The body tag is used to find the step content within the declared wizard area.
|
||||||
*
|
*
|
||||||
* @property bodyTag
|
* @assets bodyTag
|
||||||
* @type String
|
* @type String
|
||||||
* @default "div"
|
* @default "div"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1635,7 +1635,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The content container tag which will be used to wrap all step contents.
|
* The content container tag which will be used to wrap all step contents.
|
||||||
*
|
*
|
||||||
* @property contentContainerTag
|
* @assets contentContainerTag
|
||||||
* @type String
|
* @type String
|
||||||
* @default "div"
|
* @default "div"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1645,7 +1645,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The action container tag which will be used to wrap the pagination navigation.
|
* The action container tag which will be used to wrap the pagination navigation.
|
||||||
*
|
*
|
||||||
* @property actionContainerTag
|
* @assets actionContainerTag
|
||||||
* @type String
|
* @type String
|
||||||
* @default "div"
|
* @default "div"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1655,7 +1655,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The steps container tag which will be used to wrap the steps navigation.
|
* The steps container tag which will be used to wrap the steps navigation.
|
||||||
*
|
*
|
||||||
* @property stepsContainerTag
|
* @assets stepsContainerTag
|
||||||
* @type String
|
* @type String
|
||||||
* @default "div"
|
* @default "div"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1665,7 +1665,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The css class which will be added to the outer component wrapper.
|
* The css class which will be added to the outer component wrapper.
|
||||||
*
|
*
|
||||||
* @property cssClass
|
* @assets cssClass
|
||||||
* @type String
|
* @type String
|
||||||
* @default "wizard"
|
* @default "wizard"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1679,7 +1679,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The css class which will be used for floating scenarios.
|
* The css class which will be used for floating scenarios.
|
||||||
*
|
*
|
||||||
* @property clearFixCssClass
|
* @assets clearFixCssClass
|
||||||
* @type String
|
* @type String
|
||||||
* @default "clearfix"
|
* @default "clearfix"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1689,7 +1689,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Determines whether the steps are vertically or horizontally oriented.
|
* Determines whether the steps are vertically or horizontally oriented.
|
||||||
*
|
*
|
||||||
* @property stepsOrientation
|
* @assets stepsOrientation
|
||||||
* @type stepsOrientation
|
* @type stepsOrientation
|
||||||
* @default horizontal
|
* @default horizontal
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1704,7 +1704,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The title template which will be used to create a step button.
|
* The title template which will be used to create a step button.
|
||||||
*
|
*
|
||||||
* @property titleTemplate
|
* @assets titleTemplate
|
||||||
* @type String
|
* @type String
|
||||||
* @default "<span class=\"number\">#index#.</span> #title#"
|
* @default "<span class=\"number\">#index#.</span> #title#"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1714,7 +1714,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The loading template which will be used to create the loading animation.
|
* The loading template which will be used to create the loading animation.
|
||||||
*
|
*
|
||||||
* @property loadingTemplate
|
* @assets loadingTemplate
|
||||||
* @type String
|
* @type String
|
||||||
* @default "<span class=\"spinner\"></span> #text#"
|
* @default "<span class=\"spinner\"></span> #text#"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1728,7 +1728,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Sets the focus to the first wizard instance in order to enable the key navigation from the begining if `true`.
|
* Sets the focus to the first wizard instance in order to enable the key navigation from the begining if `true`.
|
||||||
*
|
*
|
||||||
* @property autoFocus
|
* @assets autoFocus
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default false
|
* @default false
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1739,7 +1739,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Enables all steps from the begining if `true` (all steps are clickable).
|
* Enables all steps from the begining if `true` (all steps are clickable).
|
||||||
*
|
*
|
||||||
* @property enableAllSteps
|
* @assets enableAllSteps
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default false
|
* @default false
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1749,7 +1749,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Enables keyboard navigation if `true` (arrow left and arrow right).
|
* Enables keyboard navigation if `true` (arrow left and arrow right).
|
||||||
*
|
*
|
||||||
* @property enableKeyNavigation
|
* @assets enableKeyNavigation
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default true
|
* @default true
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1759,7 +1759,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Enables pagination if `true`.
|
* Enables pagination if `true`.
|
||||||
*
|
*
|
||||||
* @property enablePagination
|
* @assets enablePagination
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default true
|
* @default true
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1769,7 +1769,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Suppresses pagination if a form field is focused.
|
* Suppresses pagination if a form field is focused.
|
||||||
*
|
*
|
||||||
* @property suppressPaginationOnFocus
|
* @assets suppressPaginationOnFocus
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default true
|
* @default true
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1779,7 +1779,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Enables cache for async loaded or iframe embedded content.
|
* Enables cache for async loaded or iframe embedded content.
|
||||||
*
|
*
|
||||||
* @property enableContentCache
|
* @assets enableContentCache
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default true
|
* @default true
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1789,7 +1789,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Shows the cancel button if enabled.
|
* Shows the cancel button if enabled.
|
||||||
*
|
*
|
||||||
* @property enableCancelButton
|
* @assets enableCancelButton
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default false
|
* @default false
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1799,7 +1799,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Shows the finish button if enabled.
|
* Shows the finish button if enabled.
|
||||||
*
|
*
|
||||||
* @property enableFinishButton
|
* @assets enableFinishButton
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default true
|
* @default true
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1809,7 +1809,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Not yet implemented.
|
* Not yet implemented.
|
||||||
*
|
*
|
||||||
* @property preloadContent
|
* @assets preloadContent
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default false
|
* @default false
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1820,7 +1820,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
* Shows the finish button always (on each step; right beside the next button) if `true`.
|
* Shows the finish button always (on each step; right beside the next button) if `true`.
|
||||||
* Otherwise the next button will be replaced by the finish button if the last step becomes active.
|
* Otherwise the next button will be replaced by the finish button if the last step becomes active.
|
||||||
*
|
*
|
||||||
* @property showFinishButtonAlways
|
* @assets showFinishButtonAlways
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default false
|
* @default false
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1830,7 +1830,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Prevents jumping to a previous step.
|
* Prevents jumping to a previous step.
|
||||||
*
|
*
|
||||||
* @property forceMoveForward
|
* @assets forceMoveForward
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default false
|
* @default false
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1841,7 +1841,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
* Saves the current state (step position) to a cookie.
|
* Saves the current state (step position) to a cookie.
|
||||||
* By coming next time the last active step becomes activated.
|
* By coming next time the last active step becomes activated.
|
||||||
*
|
*
|
||||||
* @property saveState
|
* @assets saveState
|
||||||
* @type Boolean
|
* @type Boolean
|
||||||
* @default false
|
* @default false
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1851,7 +1851,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The position to start on (zero-based).
|
* The position to start on (zero-based).
|
||||||
*
|
*
|
||||||
* @property startIndex
|
* @assets startIndex
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @default 0
|
* @default 0
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1865,7 +1865,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* The animation effect which will be used for step transitions.
|
* The animation effect which will be used for step transitions.
|
||||||
*
|
*
|
||||||
* @property transitionEffect
|
* @assets transitionEffect
|
||||||
* @type transitionEffect
|
* @type transitionEffect
|
||||||
* @default none
|
* @default none
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1875,7 +1875,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Animation speed for step transitions (in milliseconds).
|
* Animation speed for step transitions (in milliseconds).
|
||||||
*
|
*
|
||||||
* @property transitionEffectSpeed
|
* @assets transitionEffectSpeed
|
||||||
* @type Integer
|
* @type Integer
|
||||||
* @default 200
|
* @default 200
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1890,7 +1890,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
* Fires before the step changes and can be used to prevent step changing by returning `false`.
|
* Fires before the step changes and can be used to prevent step changing by returning `false`.
|
||||||
* Very useful for form validation.
|
* Very useful for form validation.
|
||||||
*
|
*
|
||||||
* @property onStepChanging
|
* @assets onStepChanging
|
||||||
* @type Event
|
* @type Event
|
||||||
* @default function (event, currentIndex, newIndex) { return true; }
|
* @default function (event, currentIndex, newIndex) { return true; }
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1900,7 +1900,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Fires after the step has change.
|
* Fires after the step has change.
|
||||||
*
|
*
|
||||||
* @property onStepChanged
|
* @assets onStepChanged
|
||||||
* @type Event
|
* @type Event
|
||||||
* @default function (event, currentIndex, priorIndex) { }
|
* @default function (event, currentIndex, priorIndex) { }
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1910,7 +1910,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Fires after cancelation.
|
* Fires after cancelation.
|
||||||
*
|
*
|
||||||
* @property onCanceled
|
* @assets onCanceled
|
||||||
* @type Event
|
* @type Event
|
||||||
* @default function (event) { }
|
* @default function (event) { }
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1921,7 +1921,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
* Fires before finishing and can be used to prevent completion by returning `false`.
|
* Fires before finishing and can be used to prevent completion by returning `false`.
|
||||||
* Very useful for form validation.
|
* Very useful for form validation.
|
||||||
*
|
*
|
||||||
* @property onFinishing
|
* @assets onFinishing
|
||||||
* @type Event
|
* @type Event
|
||||||
* @default function (event, currentIndex) { return true; }
|
* @default function (event, currentIndex) { return true; }
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1931,7 +1931,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Fires after completion.
|
* Fires after completion.
|
||||||
*
|
*
|
||||||
* @property onFinished
|
* @assets onFinished
|
||||||
* @type Event
|
* @type Event
|
||||||
* @default function (event, currentIndex) { }
|
* @default function (event, currentIndex) { }
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1941,7 +1941,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Fires after async content is loaded.
|
* Fires after async content is loaded.
|
||||||
*
|
*
|
||||||
* @property onContentLoaded
|
* @assets onContentLoaded
|
||||||
* @type Event
|
* @type Event
|
||||||
* @default function (event, index) { }
|
* @default function (event, index) { }
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1951,7 +1951,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Fires when the wizard is initialized.
|
* Fires when the wizard is initialized.
|
||||||
*
|
*
|
||||||
* @property onInit
|
* @assets onInit
|
||||||
* @type Event
|
* @type Event
|
||||||
* @default function (event) { }
|
* @default function (event) { }
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1961,7 +1961,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Contains all labels.
|
* Contains all labels.
|
||||||
*
|
*
|
||||||
* @property labels
|
* @assets labels
|
||||||
* @type Object
|
* @type Object
|
||||||
* @for defaults
|
* @for defaults
|
||||||
**/
|
**/
|
||||||
|
|
@ -1969,7 +1969,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Label for the cancel button.
|
* Label for the cancel button.
|
||||||
*
|
*
|
||||||
* @property cancel
|
* @assets cancel
|
||||||
* @type String
|
* @type String
|
||||||
* @default "Cancel"
|
* @default "Cancel"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1980,7 +1980,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
* This label is important for accessability reasons.
|
* This label is important for accessability reasons.
|
||||||
* Indicates which step is activated.
|
* Indicates which step is activated.
|
||||||
*
|
*
|
||||||
* @property current
|
* @assets current
|
||||||
* @type String
|
* @type String
|
||||||
* @default "current step:"
|
* @default "current step:"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -1990,7 +1990,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* This label is important for accessability reasons and describes the kind of navigation.
|
* This label is important for accessability reasons and describes the kind of navigation.
|
||||||
*
|
*
|
||||||
* @property pagination
|
* @assets pagination
|
||||||
* @type String
|
* @type String
|
||||||
* @default "Pagination"
|
* @default "Pagination"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -2001,7 +2001,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Label for the finish button.
|
* Label for the finish button.
|
||||||
*
|
*
|
||||||
* @property finish
|
* @assets finish
|
||||||
* @type String
|
* @type String
|
||||||
* @default "Finish"
|
* @default "Finish"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -2011,7 +2011,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Label for the next button.
|
* Label for the next button.
|
||||||
*
|
*
|
||||||
* @property next
|
* @assets next
|
||||||
* @type String
|
* @type String
|
||||||
* @default "Next"
|
* @default "Next"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -2021,7 +2021,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Label for the previous button.
|
* Label for the previous button.
|
||||||
*
|
*
|
||||||
* @property previous
|
* @assets previous
|
||||||
* @type String
|
* @type String
|
||||||
* @default "Previous"
|
* @default "Previous"
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
@ -2031,7 +2031,7 @@ var defaults = $.fn.steps.defaults = {
|
||||||
/**
|
/**
|
||||||
* Label for the loading animation.
|
* Label for the loading animation.
|
||||||
*
|
*
|
||||||
* @property loading
|
* @assets loading
|
||||||
* @type String
|
* @type String
|
||||||
* @default "Loading ..."
|
* @default "Loading ..."
|
||||||
* @for defaults
|
* @for defaults
|
||||||
|
|
|
||||||
|
|
@ -1797,13 +1797,13 @@
|
||||||
return node && !isText(node) && lists.contains(node.classList, 'note-styletag');
|
return node && !isText(node) && lists.contains(node.classList, 'note-styletag');
|
||||||
}
|
}
|
||||||
var dom = {
|
var dom = {
|
||||||
/** @property {String} NBSP_CHAR */
|
/** @assets {String} NBSP_CHAR */
|
||||||
NBSP_CHAR: NBSP_CHAR,
|
NBSP_CHAR: NBSP_CHAR,
|
||||||
/** @property {String} ZERO_WIDTH_NBSP_CHAR */
|
/** @assets {String} ZERO_WIDTH_NBSP_CHAR */
|
||||||
ZERO_WIDTH_NBSP_CHAR: ZERO_WIDTH_NBSP_CHAR,
|
ZERO_WIDTH_NBSP_CHAR: ZERO_WIDTH_NBSP_CHAR,
|
||||||
/** @property {String} blank */
|
/** @assets {String} blank */
|
||||||
blank: blankHTML,
|
blank: blankHTML,
|
||||||
/** @property {String} emptyPara */
|
/** @assets {String} emptyPara */
|
||||||
emptyPara: "<p>" + blankHTML + "</p>",
|
emptyPara: "<p>" + blankHTML + "</p>",
|
||||||
makePredByNodeName: makePredByNodeName,
|
makePredByNodeName: makePredByNodeName,
|
||||||
isEditable: isEditable,
|
isEditable: isEditable,
|
||||||
|
|
@ -2885,8 +2885,8 @@
|
||||||
], keyCode);
|
], keyCode);
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* @property {Object} nameFromCode
|
* @assets {Object} nameFromCode
|
||||||
* @property {String} nameFromCode.8 "BACKSPACE"
|
* @assets {String} nameFromCode.8 "BACKSPACE"
|
||||||
*/
|
*/
|
||||||
nameFromCode: func.invertObject(KEY_MAP),
|
nameFromCode: func.invertObject(KEY_MAP),
|
||||||
code: KEY_MAP
|
code: KEY_MAP
|
||||||
|
|
@ -3045,7 +3045,7 @@
|
||||||
*
|
*
|
||||||
* [workaround] for old jQuery
|
* [workaround] for old jQuery
|
||||||
* passing an array of style properties to .css()
|
* passing an array of style properties to .css()
|
||||||
* will result in an object of property-value pairs.
|
* will result in an object of assets-value pairs.
|
||||||
* (compability with version < 1.9)
|
* (compability with version < 1.9)
|
||||||
*
|
*
|
||||||
* @private
|
* @private
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,77 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('新增机柜类型')"/>
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-assetsCabinet-add">
|
||||||
|
<!-- <div class="form-group">-->
|
||||||
|
<!-- <label class="col-sm-3 control-label">所属机房:</label>-->
|
||||||
|
<!-- <div class="col-sm-8">-->
|
||||||
|
<!-- <input id="machineRoomId" name="machineRoomId" class="form-control" type="text">-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所属机房:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<select name="memoryType" th:with="type=${@dict.getType('dict_memory_type')}">
|
||||||
|
<option value="">请选择单根内存大小</option>
|
||||||
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}"
|
||||||
|
th:value="${dict.dictCode}">
|
||||||
|
</option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜名称:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetName" name="cabinetName" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜所在区域:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetArea" name="cabinetArea" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜可用U数:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetAvailU" name="cabinetAvailU" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜可用电力:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetAvailElec" name="cabinetAvailElec" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜备注:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="remark" name="remark" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<div th:include="include::footer"></div>
|
||||||
|
<script type="text/javascript">
|
||||||
|
var prefix = ctx + "assets/assetsCabinet"
|
||||||
|
$("#form-assetsCabinet-add").validate({
|
||||||
|
rules: {
|
||||||
|
xxxx: {
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/add", $('#form-assetsCabinet-add').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
145
ruoyi-admin/src/main/resources/templates/assets/assetsCabinet/assetsCabinet.html
Executable file
145
ruoyi-admin/src/main/resources/templates/assets/assetsCabinet/assetsCabinet.html
Executable file
|
|
@ -0,0 +1,145 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('机柜类型列表')"/>
|
||||||
|
</head>
|
||||||
|
<body class="gray-bg">
|
||||||
|
<div class="container-div">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12 search-collapse">
|
||||||
|
<form id="formId">
|
||||||
|
<div class="select-list">
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
机房:<input type="text" name="machineRoomId"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
机柜名称:<input type="text" name="cabinetName"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
机柜所在区域:<input type="text" name="cabinetArea"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
机柜可用U数:<input type="text" name="cabinetAvailU"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
机柜可用电力:<input type="text" name="cabinetAvailElec"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
机柜备注:<input type="text" name="remark"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
|
||||||
|
class="fa fa-search"></i> 搜索</a>
|
||||||
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
|
||||||
|
class="fa fa-refresh"></i> 重置</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="btn-group-sm" id="toolbar" role="group">
|
||||||
|
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="assets:assetsCabinet:add">
|
||||||
|
<i class="fa fa-plus"></i> 添加
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary btn-edit disabled" onclick="$.operate.edit()"
|
||||||
|
shiro:hasPermission="assets:assetsCabinet:edit">
|
||||||
|
<i class="fa fa-edit"></i> 修改
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-danger btn-del btn-del disabled" onclick="$.operate.removeAll()"
|
||||||
|
shiro:hasPermission="assets:assetsCabinet:remove">
|
||||||
|
<i class="fa fa-remove"></i> 删除
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-warning" onclick="$.table.exportExcel()"
|
||||||
|
shiro:hasPermission="assets:assetsCabinet:export">
|
||||||
|
<i class="fa fa-download"></i> 导出
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-12 select-table table-striped">
|
||||||
|
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div th:include="include :: footer"></div>
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var editFlag = [[${@permission.hasPermi('assets:assetsCabinet:edit')}]];
|
||||||
|
var removeFlag = [[${@permission.hasPermi('assets:assetsCabinet:remove')}]];
|
||||||
|
var prefix = ctx + "assets/assetsCabinet";
|
||||||
|
|
||||||
|
$(function () {
|
||||||
|
var options = {
|
||||||
|
url: prefix + "/list",
|
||||||
|
createUrl: prefix + "/add",
|
||||||
|
updateUrl: prefix + "/edit/{id}",
|
||||||
|
removeUrl: prefix + "/remove",
|
||||||
|
exportUrl: prefix + "/export",
|
||||||
|
modalName: "机柜类型",
|
||||||
|
showExport: true,
|
||||||
|
columns: [{
|
||||||
|
checkbox: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'cabinetId',
|
||||||
|
title: '机柜编号',
|
||||||
|
visible: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'machineRoomId',
|
||||||
|
title: '所属机房',
|
||||||
|
sortable: true,
|
||||||
|
formatter: function (value, row, index) {
|
||||||
|
if (row.machineRoom != null) {
|
||||||
|
var machineRoomName = row.machineRoom.machineRoomName;
|
||||||
|
value = machineRoomName;
|
||||||
|
}
|
||||||
|
return value;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'cabinetName',
|
||||||
|
title: '机柜名称',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'cabinetArea',
|
||||||
|
title: '机柜所在区域',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'cabinetAvailU',
|
||||||
|
title: '机柜可用U数',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'cabinetAvailElec',
|
||||||
|
title: '机柜可用电力',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'remark',
|
||||||
|
title: '机柜备注',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '操作',
|
||||||
|
align: 'center',
|
||||||
|
formatter: function (value, row, index) {
|
||||||
|
var actions = [];
|
||||||
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.cabinetId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||||
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.cabinetId + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||||
|
return actions.join('');
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
};
|
||||||
|
$.table.init(options);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,71 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('修改机柜类型')"/>
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-assetsCabinet-edit" th:object="${assetsCabinet}">
|
||||||
|
<input id="cabinetId" name="cabinetId" th:field="*{cabinetId}" type="hidden">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所属机房:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="machineRoomId" name="machineRoomId" th:field="*{machineRoom.machineRoomId}"
|
||||||
|
class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜名称:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetName" name="cabinetName" th:field="*{cabinetName}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜所在区域:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetArea" name="cabinetArea" th:field="*{cabinetArea}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜可用U数:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetAvailU" name="cabinetAvailU" th:field="*{cabinetAvailU}" class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜可用电力:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="cabinetAvailElec" name="cabinetAvailElec" th:field="*{cabinetAvailElec}" class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机柜备注:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="remark" name="remark" th:field="*{remark}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<div th:include="include::footer"></div>
|
||||||
|
<script type="text/javascript" th:inline="javascript">
|
||||||
|
var prefix = ctx + "assets/assetsCabinet";
|
||||||
|
$("#form-assetsCabinet-edit").validate({
|
||||||
|
rules: {
|
||||||
|
xxxx: {
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/edit", $('#form-assetsCabinet-edit').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,96 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('新增机房')" />
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-assetsMachineRoom-add">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机房名称:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="machineRoomName" name="machineRoomName" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">带宽类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="bandwidthType" name="bandwidthType" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">带宽大小:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="bandwidthSize" name="bandwidthSize" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在国家:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="country" name="country" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在省:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="province" name="province" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在市:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="city" name="city" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在区:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="area" name="area" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">地址:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="location" name="location" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系人:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="contactPerson" name="contactPerson" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系电话:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="contactPhone" name="contactPhone" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">邮箱:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="email" name="email" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<div th:include="include::footer"></div>
|
||||||
|
<script type="text/javascript">
|
||||||
|
var prefix = ctx + "assets/assetsMachineRoom"
|
||||||
|
$("#form-assetsMachineRoom-add").validate({
|
||||||
|
rules:{
|
||||||
|
xxxx:{
|
||||||
|
required:true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/add", $('#form-assetsMachineRoom-add').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,183 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('机房列表')"/>
|
||||||
|
</head>
|
||||||
|
<body class="gray-bg">
|
||||||
|
<div class="container-div">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12 search-collapse">
|
||||||
|
<form id="formId">
|
||||||
|
<div class="select-list">
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
机房名称:<input type="text" name="machineRoomName"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
带宽类型:<input type="text" name="bandwidthType"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
带宽大小:<input type="text" name="bandwidthSize"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
所在国家:<input type="text" name="country"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
所在省:<input type="text" name="province"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
所在市:<input type="text" name="city"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
所在区:<input type="text" name="area"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
地址:<input type="text" name="location"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
联系人:<input type="text" name="contactPerson"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
联系电话:<input type="text" name="contactPhone"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
邮箱:<input type="text" name="email"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
|
||||||
|
class="fa fa-search"></i> 搜索</a>
|
||||||
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
|
||||||
|
class="fa fa-refresh"></i> 重置</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="btn-group-sm" id="toolbar" role="group">
|
||||||
|
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="assets:assetsMachineRoom:add">
|
||||||
|
<i class="fa fa-plus"></i> 添加
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary btn-edit disabled" onclick="$.operate.edit()"
|
||||||
|
shiro:hasPermission="assets:assetsMachineRoom:edit">
|
||||||
|
<i class="fa fa-edit"></i> 修改
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-danger btn-del btn-del disabled" onclick="$.operate.removeAll()"
|
||||||
|
shiro:hasPermission="assets:assetsMachineRoom:remove">
|
||||||
|
<i class="fa fa-remove"></i> 删除
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-warning" onclick="$.table.exportExcel()"
|
||||||
|
shiro:hasPermission="assets:assetsMachineRoom:export">
|
||||||
|
<i class="fa fa-download"></i> 导出
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-12 select-table table-striped">
|
||||||
|
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div th:include="include :: footer"></div>
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var editFlag = [[${@permission.hasPermi('assets:assetsMachineRoom:edit')}]];
|
||||||
|
var removeFlag = [[${@permission.hasPermi('assets:assetsMachineRoom:remove')}]];
|
||||||
|
var prefix = ctx + "assets/assetsMachineRoom";
|
||||||
|
|
||||||
|
$(function () {
|
||||||
|
var options = {
|
||||||
|
url: prefix + "/list",
|
||||||
|
createUrl: prefix + "/add",
|
||||||
|
updateUrl: prefix + "/edit/{id}",
|
||||||
|
removeUrl: prefix + "/remove",
|
||||||
|
exportUrl: prefix + "/export",
|
||||||
|
modalName: "机房",
|
||||||
|
showExport: true,
|
||||||
|
columns: [{
|
||||||
|
checkbox: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'machineRoomId',
|
||||||
|
title: '机房编号',
|
||||||
|
visible: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'machineRoomName',
|
||||||
|
title: '机房名称',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'bandwidthType',
|
||||||
|
title: '带宽类型',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'bandwidthSize',
|
||||||
|
title: '带宽大小',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'country',
|
||||||
|
title: '所在国家',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'province',
|
||||||
|
title: '所在省',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'city',
|
||||||
|
title: '所在市',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'area',
|
||||||
|
title: '所在区',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'location',
|
||||||
|
title: '地址',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'contactPerson',
|
||||||
|
title: '联系人',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'contactPhone',
|
||||||
|
title: '联系电话',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'email',
|
||||||
|
title: '邮箱',
|
||||||
|
sortable: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '操作',
|
||||||
|
align: 'center',
|
||||||
|
formatter: function (value, row, index) {
|
||||||
|
var actions = [];
|
||||||
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.machineRoomId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||||
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.machineRoomId + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||||
|
return actions.join('');
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
};
|
||||||
|
$.table.init(options);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,102 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('修改机房')"/>
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-assetsMachineRoom-edit" th:object="${assetsMachineRoom}">
|
||||||
|
<input id="machineRoomId" name="machineRoomId" th:field="*{machineRoomId}" type="hidden">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">机房名称:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="machineRoomName" name="machineRoomName" th:field="*{machineRoomName}" class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">带宽类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="bandwidthType" name="bandwidthType" th:field="*{bandwidthType}" class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">带宽大小:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="bandwidthSize" name="bandwidthSize" th:field="*{bandwidthSize}" class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在国家:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="country" name="country" th:field="*{country}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在省:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="province" name="province" th:field="*{province}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在市:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="city" name="city" th:field="*{city}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">所在区:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="area" name="area" th:field="*{area}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">地址:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="location" name="location" th:field="*{location}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系人:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="contactPerson" name="contactPerson" th:field="*{contactPerson}" class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">联系电话:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="contactPhone" name="contactPhone" th:field="*{contactPhone}" class="form-control"
|
||||||
|
type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">邮箱:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="email" name="email" th:field="*{email}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<div th:include="include::footer"></div>
|
||||||
|
<script type="text/javascript" th:inline="javascript">
|
||||||
|
var prefix = ctx + "assets/assetsMachineRoom";
|
||||||
|
$("#form-assetsMachineRoom-edit").validate({
|
||||||
|
rules: {
|
||||||
|
xxxx: {
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/edit", $('#form-assetsMachineRoom-edit').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -1,13 +1,13 @@
|
||||||
package com.ruoyi.common.core.domain;
|
package com.ruoyi.common.core.domain;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
|
||||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Entity基类
|
* Entity基类
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -109,7 +109,7 @@ public class PermissionUtils
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
{
|
{
|
||||||
log.error("Error reading property [{}] from principal of type [{}]", property,
|
log.error("Error reading assets [{}] from principal of type [{}]", property,
|
||||||
principal.getClass().getName());
|
principal.getClass().getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ gen:
|
||||||
# 作者
|
# 作者
|
||||||
author: TP
|
author: TP
|
||||||
# 默认生成包路径 system 需改成自己的模块名称 如 system monitor tool
|
# 默认生成包路径 system 需改成自己的模块名称 如 system monitor tool
|
||||||
packageName: com.ruoyi.template
|
packageName: com.ruoyi.assets
|
||||||
# 自动去除表前缀,默认是true
|
# 自动去除表前缀,默认是true
|
||||||
autoRemovePre: fasle
|
autoRemovePre: fasle
|
||||||
# 表前缀(类名不会包含表前缀)
|
# 表前缀(类名不会包含表前缀)
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,7 @@ public class ScheduleConfig
|
||||||
prop.put("org.quartz.jobStore.txIsolationLevelSerializable", "true");
|
prop.put("org.quartz.jobStore.txIsolationLevelSerializable", "true");
|
||||||
|
|
||||||
// sqlserver 启用
|
// sqlserver 启用
|
||||||
// prop.put("org.quartz.jobStore.selectWithLockSQL", "SELECT * FROM {0}LOCKS UPDLOCK WHERE LOCK_NAME = ?");
|
// assets.put("org.quartz.jobStore.selectWithLockSQL", "SELECT * FROM {0}LOCKS UPDLOCK WHERE LOCK_NAME = ?");
|
||||||
prop.put("org.quartz.jobStore.misfireThreshold", "12000");
|
prop.put("org.quartz.jobStore.misfireThreshold", "12000");
|
||||||
prop.put("org.quartz.jobStore.tablePrefix", "QRTZ_");
|
prop.put("org.quartz.jobStore.tablePrefix", "QRTZ_");
|
||||||
factory.setQuartzProperties(prop);
|
factory.setQuartzProperties(prop);
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,101 @@
|
||||||
|
package com.ruoyi.assets.domain;
|
||||||
|
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机柜类型表 assets_cabinet
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
public class AssetsCabinet extends BaseEntity {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机柜编号
|
||||||
|
*/
|
||||||
|
private Integer cabinetId;
|
||||||
|
/**
|
||||||
|
* 机房编号
|
||||||
|
*/
|
||||||
|
private AssetsMachineRoom machineRoom;
|
||||||
|
/**
|
||||||
|
* 机柜名称
|
||||||
|
*/
|
||||||
|
private String cabinetName;
|
||||||
|
/**
|
||||||
|
* 机柜所在区域
|
||||||
|
*/
|
||||||
|
private Long cabinetArea;
|
||||||
|
/**
|
||||||
|
* 机柜可用U数
|
||||||
|
*/
|
||||||
|
private Integer cabinetAvailU;
|
||||||
|
/**
|
||||||
|
* 机柜可用电力
|
||||||
|
*/
|
||||||
|
private Integer cabinetAvailElec;
|
||||||
|
|
||||||
|
public Integer getCabinetId() {
|
||||||
|
return cabinetId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCabinetId(Integer cabinetId) {
|
||||||
|
this.cabinetId = cabinetId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public AssetsMachineRoom getMachineRoom() {
|
||||||
|
return machineRoom;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMachineRoom(AssetsMachineRoom machineRoom) {
|
||||||
|
this.machineRoom = machineRoom;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCabinetName() {
|
||||||
|
return cabinetName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCabinetName(String cabinetName) {
|
||||||
|
this.cabinetName = cabinetName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getCabinetArea() {
|
||||||
|
return cabinetArea;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCabinetArea(Long cabinetArea) {
|
||||||
|
this.cabinetArea = cabinetArea;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getCabinetAvailU() {
|
||||||
|
return cabinetAvailU;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCabinetAvailU(Integer cabinetAvailU) {
|
||||||
|
this.cabinetAvailU = cabinetAvailU;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getCabinetAvailElec() {
|
||||||
|
return cabinetAvailElec;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCabinetAvailElec(Integer cabinetAvailElec) {
|
||||||
|
this.cabinetAvailElec = cabinetAvailElec;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("cabinetId", getCabinetId())
|
||||||
|
.append("machineRoomId", getMachineRoom())
|
||||||
|
.append("cabinetName", getCabinetName())
|
||||||
|
.append("cabinetArea", getCabinetArea())
|
||||||
|
.append("cabinetAvailU", getCabinetAvailU())
|
||||||
|
.append("cabinetAvailElec", getCabinetAvailElec())
|
||||||
|
.append("remark", getRemark())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,178 @@
|
||||||
|
package com.ruoyi.assets.domain;
|
||||||
|
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机房表 assets_machine_room
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
public class AssetsMachineRoom extends BaseEntity {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机房编号
|
||||||
|
*/
|
||||||
|
private Integer machineRoomId;
|
||||||
|
/**
|
||||||
|
* 机房名称
|
||||||
|
*/
|
||||||
|
private String machineRoomName;
|
||||||
|
/**
|
||||||
|
* 带宽类型
|
||||||
|
*/
|
||||||
|
private Long bandwidthType;
|
||||||
|
/**
|
||||||
|
* 带宽大小
|
||||||
|
*/
|
||||||
|
private Integer bandwidthSize;
|
||||||
|
/**
|
||||||
|
* 所在国家
|
||||||
|
*/
|
||||||
|
private String country;
|
||||||
|
/**
|
||||||
|
* 所在省
|
||||||
|
*/
|
||||||
|
private String province;
|
||||||
|
/**
|
||||||
|
* 所在市
|
||||||
|
*/
|
||||||
|
private String city;
|
||||||
|
/**
|
||||||
|
* 所在区
|
||||||
|
*/
|
||||||
|
private String area;
|
||||||
|
/**
|
||||||
|
* 地址
|
||||||
|
*/
|
||||||
|
private String location;
|
||||||
|
/**
|
||||||
|
* 联系人
|
||||||
|
*/
|
||||||
|
private String contactPerson;
|
||||||
|
/**
|
||||||
|
* 联系电话
|
||||||
|
*/
|
||||||
|
private String contactPhone;
|
||||||
|
/**
|
||||||
|
* 邮箱
|
||||||
|
*/
|
||||||
|
private String email;
|
||||||
|
|
||||||
|
public Integer getMachineRoomId() {
|
||||||
|
return machineRoomId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMachineRoomId(Integer machineRoomId) {
|
||||||
|
this.machineRoomId = machineRoomId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMachineRoomName() {
|
||||||
|
return machineRoomName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMachineRoomName(String machineRoomName) {
|
||||||
|
this.machineRoomName = machineRoomName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getBandwidthType() {
|
||||||
|
return bandwidthType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBandwidthType(Long bandwidthType) {
|
||||||
|
this.bandwidthType = bandwidthType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getBandwidthSize() {
|
||||||
|
return bandwidthSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBandwidthSize(Integer bandwidthSize) {
|
||||||
|
this.bandwidthSize = bandwidthSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCountry() {
|
||||||
|
return country;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCountry(String country) {
|
||||||
|
this.country = country;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getProvince() {
|
||||||
|
return province;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setProvince(String province) {
|
||||||
|
this.province = province;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCity() {
|
||||||
|
return city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCity(String city) {
|
||||||
|
this.city = city;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getArea() {
|
||||||
|
return area;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setArea(String area) {
|
||||||
|
this.area = area;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLocation() {
|
||||||
|
return location;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLocation(String location) {
|
||||||
|
this.location = location;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getContactPerson() {
|
||||||
|
return contactPerson;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setContactPerson(String contactPerson) {
|
||||||
|
this.contactPerson = contactPerson;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getContactPhone() {
|
||||||
|
return contactPhone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setContactPhone(String contactPhone) {
|
||||||
|
this.contactPhone = contactPhone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getEmail() {
|
||||||
|
return email;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setEmail(String email) {
|
||||||
|
this.email = email;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("machineRoomId", getMachineRoomId())
|
||||||
|
.append("machineRoomName", getMachineRoomName())
|
||||||
|
.append("bandwidthType", getBandwidthType())
|
||||||
|
.append("bandwidthSize", getBandwidthSize())
|
||||||
|
.append("country", getCountry())
|
||||||
|
.append("province", getProvince())
|
||||||
|
.append("city", getCity())
|
||||||
|
.append("area", getArea())
|
||||||
|
.append("location", getLocation())
|
||||||
|
.append("contactPerson", getContactPerson())
|
||||||
|
.append("contactPhone", getContactPhone())
|
||||||
|
.append("email", getEmail())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,62 @@
|
||||||
|
package com.ruoyi.assets.mapper;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsCabinet;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机柜类型 数据层
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
public interface AssetsCabinetMapper {
|
||||||
|
/**
|
||||||
|
* 查询机柜类型信息
|
||||||
|
*
|
||||||
|
* @param cabinetId 机柜类型ID
|
||||||
|
* @return 机柜类型信息
|
||||||
|
*/
|
||||||
|
public AssetsCabinet selectAssetsCabinetById(Integer cabinetId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机柜类型列表
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 机柜类型集合
|
||||||
|
*/
|
||||||
|
public List<AssetsCabinet> selectAssetsCabinetList(AssetsCabinet assetsCabinet);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机柜类型
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertAssetsCabinet(AssetsCabinet assetsCabinet);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机柜类型
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateAssetsCabinet(AssetsCabinet assetsCabinet);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机柜类型
|
||||||
|
*
|
||||||
|
* @param cabinetId 机柜类型ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAssetsCabinetById(Integer cabinetId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除机柜类型
|
||||||
|
*
|
||||||
|
* @param cabinetIds 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAssetsCabinetByIds(String[] cabinetIds);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,62 @@
|
||||||
|
package com.ruoyi.assets.mapper;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsMachineRoom;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机房 数据层
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
public interface AssetsMachineRoomMapper {
|
||||||
|
/**
|
||||||
|
* 查询机房信息
|
||||||
|
*
|
||||||
|
* @param machineRoomId 机房ID
|
||||||
|
* @return 机房信息
|
||||||
|
*/
|
||||||
|
public AssetsMachineRoom selectAssetsMachineRoomById(Integer machineRoomId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机房列表
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 机房集合
|
||||||
|
*/
|
||||||
|
public List<AssetsMachineRoom> selectAssetsMachineRoomList(AssetsMachineRoom assetsMachineRoom);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机房
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertAssetsMachineRoom(AssetsMachineRoom assetsMachineRoom);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机房
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateAssetsMachineRoom(AssetsMachineRoom assetsMachineRoom);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机房
|
||||||
|
*
|
||||||
|
* @param machineRoomId 机房ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAssetsMachineRoomById(Integer machineRoomId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除机房
|
||||||
|
*
|
||||||
|
* @param machineRoomIds 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAssetsMachineRoomByIds(String[] machineRoomIds);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,54 @@
|
||||||
|
package com.ruoyi.assets.service;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsCabinet;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机柜类型 服务层
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
public interface IAssetsCabinetService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询机柜类型信息
|
||||||
|
*
|
||||||
|
* @param cabinetId 机柜类型ID
|
||||||
|
* @return 机柜类型信息
|
||||||
|
*/
|
||||||
|
public AssetsCabinet selectAssetsCabinetById(Integer cabinetId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机柜类型列表
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 机柜类型集合
|
||||||
|
*/
|
||||||
|
public List<AssetsCabinet> selectAssetsCabinetList(AssetsCabinet assetsCabinet);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机柜类型
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertAssetsCabinet(AssetsCabinet assetsCabinet);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机柜类型
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateAssetsCabinet(AssetsCabinet assetsCabinet);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机柜类型信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAssetsCabinetByIds(String ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,54 @@
|
||||||
|
package com.ruoyi.assets.service;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsMachineRoom;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机房 服务层
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
public interface IAssetsMachineRoomService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询机房信息
|
||||||
|
*
|
||||||
|
* @param machineRoomId 机房ID
|
||||||
|
* @return 机房信息
|
||||||
|
*/
|
||||||
|
public AssetsMachineRoom selectAssetsMachineRoomById(Integer machineRoomId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机房列表
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 机房集合
|
||||||
|
*/
|
||||||
|
public List<AssetsMachineRoom> selectAssetsMachineRoomList(AssetsMachineRoom assetsMachineRoom);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机房
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertAssetsMachineRoom(AssetsMachineRoom assetsMachineRoom);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机房
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateAssetsMachineRoom(AssetsMachineRoom assetsMachineRoom);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机房信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAssetsMachineRoomByIds(String ids);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,78 @@
|
||||||
|
package com.ruoyi.assets.service.impl;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsCabinet;
|
||||||
|
import com.ruoyi.assets.mapper.AssetsCabinetMapper;
|
||||||
|
import com.ruoyi.assets.service.IAssetsCabinetService;
|
||||||
|
import com.ruoyi.common.core.text.Convert;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机柜类型 服务层实现
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class AssetsCabinetServiceImpl implements IAssetsCabinetService {
|
||||||
|
@Autowired
|
||||||
|
private AssetsCabinetMapper assetsCabinetMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机柜类型信息
|
||||||
|
*
|
||||||
|
* @param cabinetId 机柜类型ID
|
||||||
|
* @return 机柜类型信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public AssetsCabinet selectAssetsCabinetById(Integer cabinetId) {
|
||||||
|
return assetsCabinetMapper.selectAssetsCabinetById(cabinetId);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机柜类型列表
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 机柜类型集合
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<AssetsCabinet> selectAssetsCabinetList(AssetsCabinet assetsCabinet) {
|
||||||
|
return assetsCabinetMapper.selectAssetsCabinetList(assetsCabinet);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机柜类型
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertAssetsCabinet(AssetsCabinet assetsCabinet) {
|
||||||
|
return assetsCabinetMapper.insertAssetsCabinet(assetsCabinet);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机柜类型
|
||||||
|
*
|
||||||
|
* @param assetsCabinet 机柜类型信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateAssetsCabinet(AssetsCabinet assetsCabinet) {
|
||||||
|
return assetsCabinetMapper.updateAssetsCabinet(assetsCabinet);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机柜类型对象
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteAssetsCabinetByIds(String ids) {
|
||||||
|
return assetsCabinetMapper.deleteAssetsCabinetByIds(Convert.toStrArray(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,78 @@
|
||||||
|
package com.ruoyi.assets.service.impl;
|
||||||
|
|
||||||
|
import com.ruoyi.assets.domain.AssetsMachineRoom;
|
||||||
|
import com.ruoyi.assets.mapper.AssetsMachineRoomMapper;
|
||||||
|
import com.ruoyi.assets.service.IAssetsMachineRoomService;
|
||||||
|
import com.ruoyi.common.core.text.Convert;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 机房 服务层实现
|
||||||
|
*
|
||||||
|
* @author TP
|
||||||
|
* @date 2019-06-17
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class AssetsMachineRoomServiceImpl implements IAssetsMachineRoomService {
|
||||||
|
@Autowired
|
||||||
|
private AssetsMachineRoomMapper assetsMachineRoomMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机房信息
|
||||||
|
*
|
||||||
|
* @param machineRoomId 机房ID
|
||||||
|
* @return 机房信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public AssetsMachineRoom selectAssetsMachineRoomById(Integer machineRoomId) {
|
||||||
|
return assetsMachineRoomMapper.selectAssetsMachineRoomById(machineRoomId);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询机房列表
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 机房集合
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<AssetsMachineRoom> selectAssetsMachineRoomList(AssetsMachineRoom assetsMachineRoom) {
|
||||||
|
return assetsMachineRoomMapper.selectAssetsMachineRoomList(assetsMachineRoom);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增机房
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertAssetsMachineRoom(AssetsMachineRoom assetsMachineRoom) {
|
||||||
|
return assetsMachineRoomMapper.insertAssetsMachineRoom(assetsMachineRoom);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改机房
|
||||||
|
*
|
||||||
|
* @param assetsMachineRoom 机房信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateAssetsMachineRoom(AssetsMachineRoom assetsMachineRoom) {
|
||||||
|
return assetsMachineRoomMapper.updateAssetsMachineRoom(assetsMachineRoom);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除机房对象
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteAssetsMachineRoomByIds(String ids) {
|
||||||
|
return assetsMachineRoomMapper.deleteAssetsMachineRoomByIds(Convert.toStrArray(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,86 @@
|
||||||
|
<?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.ruoyi.assets.mapper.AssetsCabinetMapper">
|
||||||
|
|
||||||
|
<resultMap type="AssetsCabinet" id="AssetsCabinetResult">
|
||||||
|
<result property="cabinetId" column="cabinet_id"/>
|
||||||
|
<!-- <result property="machineRoom" column="machine_room_id"/>-->
|
||||||
|
<result property="cabinetName" column="cabinet_name"/>
|
||||||
|
<result property="cabinetArea" column="cabinet_area"/>
|
||||||
|
<result property="cabinetAvailU" column="cabinet_avail_u"/>
|
||||||
|
<result property="cabinetAvailElec" column="cabinet_avail_elec"/>
|
||||||
|
<result property="remark" column="remark"/>
|
||||||
|
<association property="machineRoom" column="machine_room_id"
|
||||||
|
select="com.ruoyi.assets.mapper.AssetsMachineRoomMapper.selectAssetsMachineRoomById">
|
||||||
|
</association>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAssetsCabinetVo">
|
||||||
|
select cabinet_id, machine_room_id, cabinet_name, cabinet_area, cabinet_avail_u, cabinet_avail_elec, remark from assets_cabinet
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAssetsCabinetList" parameterType="AssetsCabinet" resultMap="AssetsCabinetResult">
|
||||||
|
<include refid="selectAssetsCabinetVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="cabinetId != null ">and cabinet_id = #{cabinetId}</if>
|
||||||
|
<if test="machineRoom != null ">and machine_room_id = #{machineRoom.machineRoomId}</if>
|
||||||
|
<if test="cabinetName != null and cabinetName != '' ">and cabinet_name = #{cabinetName}</if>
|
||||||
|
<if test="cabinetArea != null ">and cabinet_area = #{cabinetArea}</if>
|
||||||
|
<if test="cabinetAvailU != null ">and cabinet_avail_u = #{cabinetAvailU}</if>
|
||||||
|
<if test="cabinetAvailElec != null ">and cabinet_avail_elec = #{cabinetAvailElec}</if>
|
||||||
|
<if test="remark != null and remark != '' ">and remark = #{remark}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAssetsCabinetById" parameterType="Integer" resultMap="AssetsCabinetResult">
|
||||||
|
<include refid="selectAssetsCabinetVo"/>
|
||||||
|
where cabinet_id = #{cabinetId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAssetsCabinet" parameterType="AssetsCabinet" useGeneratedKeys="true" keyProperty="cabinetId">
|
||||||
|
insert into assets_cabinet
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="machineRoom != null ">machine_room_id,</if>
|
||||||
|
<if test="cabinetName != null and cabinetName != '' ">cabinet_name,</if>
|
||||||
|
<if test="cabinetArea != null ">cabinet_area,</if>
|
||||||
|
<if test="cabinetAvailU != null ">cabinet_avail_u,</if>
|
||||||
|
<if test="cabinetAvailElec != null ">cabinet_avail_elec,</if>
|
||||||
|
<if test="remark != null and remark != '' ">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="machineRoom != null ">#{machineRoom.machineRoomId},</if>
|
||||||
|
<if test="cabinetName != null and cabinetName != '' ">#{cabinetName},</if>
|
||||||
|
<if test="cabinetArea != null ">#{cabinetArea},</if>
|
||||||
|
<if test="cabinetAvailU != null ">#{cabinetAvailU},</if>
|
||||||
|
<if test="cabinetAvailElec != null ">#{cabinetAvailElec},</if>
|
||||||
|
<if test="remark != null and remark != '' ">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAssetsCabinet" parameterType="AssetsCabinet">
|
||||||
|
update assets_cabinet
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="machineRoom != null ">machine_room_id = #{machineRoom.machineRoomId},</if>
|
||||||
|
<if test="cabinetName != null and cabinetName != '' ">cabinet_name = #{cabinetName},</if>
|
||||||
|
<if test="cabinetArea != null ">cabinet_area = #{cabinetArea},</if>
|
||||||
|
<if test="cabinetAvailU != null ">cabinet_avail_u = #{cabinetAvailU},</if>
|
||||||
|
<if test="cabinetAvailElec != null ">cabinet_avail_elec = #{cabinetAvailElec},</if>
|
||||||
|
<if test="remark != null and remark != '' ">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where cabinet_id = #{cabinetId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAssetsCabinetById" parameterType="Integer">
|
||||||
|
delete from assets_cabinet where cabinet_id = #{cabinetId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAssetsCabinetByIds" parameterType="String">
|
||||||
|
delete from assets_cabinet where cabinet_id in
|
||||||
|
<foreach item="cabinetId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{cabinetId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,108 @@
|
||||||
|
<?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.ruoyi.assets.mapper.AssetsMachineRoomMapper">
|
||||||
|
|
||||||
|
<resultMap type="AssetsMachineRoom" id="AssetsMachineRoomResult">
|
||||||
|
<result property="machineRoomId" column="machine_room_id" />
|
||||||
|
<result property="machineRoomName" column="machine_room_name" />
|
||||||
|
<result property="bandwidthType" column="bandwidth_type" />
|
||||||
|
<result property="bandwidthSize" column="bandwidth_size" />
|
||||||
|
<result property="country" column="country" />
|
||||||
|
<result property="province" column="province" />
|
||||||
|
<result property="city" column="city" />
|
||||||
|
<result property="area" column="area" />
|
||||||
|
<result property="location" column="location" />
|
||||||
|
<result property="contactPerson" column="contact_person" />
|
||||||
|
<result property="contactPhone" column="contact_phone" />
|
||||||
|
<result property="email" column="email" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAssetsMachineRoomVo">
|
||||||
|
select machine_room_id, machine_room_name, bandwidth_type, bandwidth_size, country, province, city, area, location, contact_person, contact_phone, email from assets_machine_room
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAssetsMachineRoomList" parameterType="AssetsMachineRoom" resultMap="AssetsMachineRoomResult">
|
||||||
|
<include refid="selectAssetsMachineRoomVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="machineRoomId != null "> and machine_room_id = #{machineRoomId}</if>
|
||||||
|
<if test="machineRoomName != null and machineRoomName != '' "> and machine_room_name = #{machineRoomName}</if>
|
||||||
|
<if test="bandwidthType != null "> and bandwidth_type = #{bandwidthType}</if>
|
||||||
|
<if test="bandwidthSize != null "> and bandwidth_size = #{bandwidthSize}</if>
|
||||||
|
<if test="country != null and country != '' "> and country = #{country}</if>
|
||||||
|
<if test="province != null and province != '' "> and province = #{province}</if>
|
||||||
|
<if test="city != null and city != '' "> and city = #{city}</if>
|
||||||
|
<if test="area != null and area != '' "> and area = #{area}</if>
|
||||||
|
<if test="location != null and location != '' "> and location = #{location}</if>
|
||||||
|
<if test="contactPerson != null and contactPerson != '' "> and contact_person = #{contactPerson}</if>
|
||||||
|
<if test="contactPhone != null and contactPhone != '' "> and contact_phone = #{contactPhone}</if>
|
||||||
|
<if test="email != null and email != '' "> and email = #{email}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAssetsMachineRoomById" parameterType="Integer" resultMap="AssetsMachineRoomResult">
|
||||||
|
<include refid="selectAssetsMachineRoomVo"/>
|
||||||
|
where machine_room_id = #{machineRoomId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAssetsMachineRoom" parameterType="AssetsMachineRoom" useGeneratedKeys="true" keyProperty="machineRoomId">
|
||||||
|
insert into assets_machine_room
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="machineRoomName != null and machineRoomName != '' ">machine_room_name,</if>
|
||||||
|
<if test="bandwidthType != null ">bandwidth_type,</if>
|
||||||
|
<if test="bandwidthSize != null ">bandwidth_size,</if>
|
||||||
|
<if test="country != null and country != '' ">country,</if>
|
||||||
|
<if test="province != null and province != '' ">province,</if>
|
||||||
|
<if test="city != null and city != '' ">city,</if>
|
||||||
|
<if test="area != null and area != '' ">area,</if>
|
||||||
|
<if test="location != null and location != '' ">location,</if>
|
||||||
|
<if test="contactPerson != null and contactPerson != '' ">contact_person,</if>
|
||||||
|
<if test="contactPhone != null and contactPhone != '' ">contact_phone,</if>
|
||||||
|
<if test="email != null and email != '' ">email,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="machineRoomName != null and machineRoomName != '' ">#{machineRoomName},</if>
|
||||||
|
<if test="bandwidthType != null ">#{bandwidthType},</if>
|
||||||
|
<if test="bandwidthSize != null ">#{bandwidthSize},</if>
|
||||||
|
<if test="country != null and country != '' ">#{country},</if>
|
||||||
|
<if test="province != null and province != '' ">#{province},</if>
|
||||||
|
<if test="city != null and city != '' ">#{city},</if>
|
||||||
|
<if test="area != null and area != '' ">#{area},</if>
|
||||||
|
<if test="location != null and location != '' ">#{location},</if>
|
||||||
|
<if test="contactPerson != null and contactPerson != '' ">#{contactPerson},</if>
|
||||||
|
<if test="contactPhone != null and contactPhone != '' ">#{contactPhone},</if>
|
||||||
|
<if test="email != null and email != '' ">#{email},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAssetsMachineRoom" parameterType="AssetsMachineRoom">
|
||||||
|
update assets_machine_room
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="machineRoomName != null and machineRoomName != '' ">machine_room_name = #{machineRoomName},</if>
|
||||||
|
<if test="bandwidthType != null ">bandwidth_type = #{bandwidthType},</if>
|
||||||
|
<if test="bandwidthSize != null ">bandwidth_size = #{bandwidthSize},</if>
|
||||||
|
<if test="country != null and country != '' ">country = #{country},</if>
|
||||||
|
<if test="province != null and province != '' ">province = #{province},</if>
|
||||||
|
<if test="city != null and city != '' ">city = #{city},</if>
|
||||||
|
<if test="area != null and area != '' ">area = #{area},</if>
|
||||||
|
<if test="location != null and location != '' ">location = #{location},</if>
|
||||||
|
<if test="contactPerson != null and contactPerson != '' ">contact_person = #{contactPerson},</if>
|
||||||
|
<if test="contactPhone != null and contactPhone != '' ">contact_phone = #{contactPhone},</if>
|
||||||
|
<if test="email != null and email != '' ">email = #{email},</if>
|
||||||
|
</trim>
|
||||||
|
where machine_room_id = #{machineRoomId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAssetsMachineRoomById" parameterType="Integer">
|
||||||
|
delete from assets_machine_room where machine_room_id = #{machineRoomId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAssetsMachineRoomByIds" parameterType="String">
|
||||||
|
delete from assets_machine_room where machine_room_id in
|
||||||
|
<foreach item="machineRoomId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{machineRoomId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
Loading…
Reference in New Issue