Merge branch 'master' of https://gitea.mjm-staging.developers-homelab.net/BIMS/BIMS
This commit is contained in:
commit
16e07b3df3
@ -29,7 +29,7 @@ namespace Backend.Controllers
|
||||
|
||||
try
|
||||
{
|
||||
var sqlString = @$"select building_guid as Value, full_name as Name from building a where a.deleted = 0 and a.status = 0 ORDER BY A.priority ASC, A.created_at DESC";
|
||||
var sqlString = @$"select building_guid as Value, full_name as Name from building a where a.deleted = 0 and a.status = 0 ORDER BY a.priority ASC, a.created_at DESC";
|
||||
KeyValue = await backendRepository.GetAllAsync<KeyValue>(sqlString);
|
||||
|
||||
apiResult.Code = "0000";
|
||||
|
@ -179,7 +179,7 @@ namespace Backend.Controllers
|
||||
dk.device_close_flashing,
|
||||
dk.device_error_flashing,
|
||||
(SELECT
|
||||
STRING_AGG( ISNULL(system_key, ' '), ',')
|
||||
GROUP_CONCAT( IFNULL(system_key, ' '), ',')
|
||||
FROM device_disaster dd
|
||||
JOIN variable v ON v.deleted = 0 AND v.system_type = 'disaster' AND v.system_value = dd.device_system_value
|
||||
WHERE dd.device_guid = d.device_guid
|
||||
@ -805,7 +805,7 @@ namespace Backend.Controllers
|
||||
|
||||
try
|
||||
{
|
||||
var rawDatas = await backendRepository.GetAllAsync<DeviceImportCheckTempRawData>("device_import_ckeck_temp", "is_correct = 1 ORDER BY device_building_tag, device_system_tag, device_floor_tag, device_name_tag");
|
||||
var rawDatas = await backendRepository.GetAllAsync<DeviceImportCheckTempRawData>("import_niagara_tag", null, null, "device_building_tag, device_system_tag, device_floor_tag, device_name_tag");
|
||||
|
||||
var rawDatas_Group_Building_tag = rawDatas.GroupBy(x => x.Device_building_tag).ToList();
|
||||
List<DeviceImportCheckTempFilter> tempFilters = new List<DeviceImportCheckTempFilter>();
|
||||
@ -871,37 +871,34 @@ namespace Backend.Controllers
|
||||
|
||||
try
|
||||
{
|
||||
string sql = @"SELECT
|
||||
di.device_building_tag,
|
||||
di.device_system_tag,
|
||||
di.device_floor_tag,
|
||||
di.device_name_tag,
|
||||
di.device_serial_tag,
|
||||
di.device_number,
|
||||
di.device_system_category_layer3,
|
||||
STRING_AGG( ISNULL(v.system_value, ' '), ',') AS Device_disasters,
|
||||
STRING_AGG( ISNULL(v.system_key, ' '), ',') AS Device_disaster_type_text
|
||||
FROM
|
||||
(SELECT
|
||||
*
|
||||
FROM device_import_ckeck_temp di
|
||||
WHERE device_building_tag = @Device_building_tag
|
||||
AND device_system_tag = @Device_system_tag
|
||||
AND device_floor_tag = @Device_floor_tag
|
||||
AND device_name_tag = @Device_name_tag
|
||||
AND is_correct = 1
|
||||
AND device_number NOT IN (SELECT d.device_number FROM device d WHERE d.deleted = 0)
|
||||
) di
|
||||
CROSS APPLY STRING_SPLIT(di.device_disaster, ',') dd
|
||||
LEFT JOIN variable v ON v.system_type = 'disaster' AND v.system_value = dd.value
|
||||
GROUP BY di.device_building_tag,
|
||||
di.device_system_tag,
|
||||
di.device_floor_tag,
|
||||
di.device_name_tag,
|
||||
di.device_serial_tag,
|
||||
di.device_number,
|
||||
di.device_system_category_layer3";
|
||||
|
||||
string sql = @"SELECT
|
||||
di.device_building_tag,
|
||||
di.device_system_tag,
|
||||
di.device_floor_tag,
|
||||
di.device_last_name_tag as device_name_tag,
|
||||
di.device_serial_tag,
|
||||
0 as device_disaster,
|
||||
di.niagara_tags as device_number
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
import_niagara_tag intag
|
||||
WHERE
|
||||
device_building_tag = @Device_building_tag
|
||||
AND device_system_tag = @Device_system_tag
|
||||
AND device_floor_tag = @Device_floor_tag
|
||||
AND device_name_tag = @Device_name_tag
|
||||
AND convert(intag.niagara_tags, nchar) NOT IN ( SELECT convert(d.device_number, nchar) FROM device d WHERE d.deleted = 0 )
|
||||
) di
|
||||
GROUP BY
|
||||
di.device_building_tag,
|
||||
di.device_system_tag,
|
||||
di.device_floor_tag,
|
||||
di.device_last_name_tag,
|
||||
di.device_serial_tag,
|
||||
di.niagara_tags";
|
||||
|
||||
var deviceImports = await backendRepository.GetAllAsync<DeviceImportCheckTemp>(sql, post);
|
||||
|
||||
|
@ -131,103 +131,246 @@
|
||||
<select class="form-control" id="build_menu_sub_modal">
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-group col-12">
|
||||
<label class="form-label"><span class="text-danger">*</span>預設頁面</label>
|
||||
<div class="row" id="build_menu_drawing_modal">
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing" id="drawing_4" value="4" checked>
|
||||
<label for="drawing_4">
|
||||
昇位圖
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing" id="drawing_2" value="2">
|
||||
<label for="drawing_2">
|
||||
系統圖
|
||||
</label>
|
||||
</div>
|
||||
<div class="col" id="drawing_1_div" style="display: none;">
|
||||
<input type="radio" name="drawing" id="drawing_1" value="1">
|
||||
<label for="drawing_1">
|
||||
樓層平面圖
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="" name="drawing_extend">
|
||||
<div class="col-12 mb-2 custom-control custom-checkbox align-content-center">
|
||||
<input type="checkbox" class="custom-control-input" name="planimetric_click" id="planimetric_click" value="1" />
|
||||
<label class="custom-control-label" for="planimetric_click">是否顯示平面圖</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_systemurl_modal_div" name="drawing_extend">
|
||||
<label class="form-label" for="build_menu_systemurl_modal"><span class="text-danger">*</span>系統圖URL</label>
|
||||
<input type="text" id="build_menu_systemurl_modal" class="form-control" name="build_menu_systemurl_modal">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_onoff_modal_div" name="drawing_extend">
|
||||
<label class="form-label">昇位圖 - 詳細資料設定</label>
|
||||
@*<div class="row">
|
||||
|
||||
<div class="col-12" id="build_menu_position_l_div">
|
||||
<label class="mb-0 t-gray">左邊區塊</label>
|
||||
<hr class="mt-1" />
|
||||
|
||||
<div class="form-group col-12">
|
||||
<label class="form-label"><span class="text-danger">*</span>預設頁面</label>
|
||||
<div class="row" id="build_menu_drawing_modal">
|
||||
<div class="col">
|
||||
<input type="radio" name="icon_click_onoff" id="icon_click_on" value="1">
|
||||
<label for="icon_click_on">
|
||||
點擊開關
|
||||
<input type="radio" name="drawing" id="drawing_4" value="4" checked>
|
||||
<label for="drawing_4">
|
||||
昇位圖
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="icon_click_onoff" id="icon_click_off" value="0" checked>
|
||||
<label for="icon_click_off">
|
||||
彈出視窗
|
||||
<input type="radio" name="drawing" id="drawing_2" value="2">
|
||||
<label for="drawing_2">
|
||||
系統圖
|
||||
</label>
|
||||
</div>
|
||||
<div class="col" id="drawing_1_div" style="display: none;">
|
||||
<input type="radio" name="drawing" id="drawing_1" value="1">
|
||||
<label for="drawing_1">
|
||||
2D
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing" id="drawing_3" value="3">
|
||||
<label for="drawing_3">
|
||||
3D
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing" id="drawing_5" value="5">
|
||||
<label for="drawing_5">
|
||||
彈出URL
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="" name="drawing_extend">
|
||||
<div class="col-12 mb-2 custom-control custom-checkbox align-content-center">
|
||||
<input type="checkbox" class="custom-control-input" name="planimetric_click" id="planimetric_click" value="1" />
|
||||
<label class="custom-control-label" for="planimetric_click">是否顯示平面圖</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_systemurl_modal_div" name="drawing_extend">
|
||||
<label class="form-label" for="build_menu_systemurl_modal"><span class="text-danger">*</span>系統圖URL</label>
|
||||
<input type="text" id="build_menu_systemurl_modal" class="form-control" name="build_menu_systemurl_modal">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_blankurl_modal_div" name="drawing_extend">
|
||||
<label class="form-label" for="build_menu_blankurl_modal"><span class="text-danger">*</span>彈出URL</label>
|
||||
<input type="text" id="build_menu_blankurl_modal" class="form-control" name="build_menu_blankurl_modal">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_onoff_modal_div" name="drawing_extend">
|
||||
<label class="form-label">昇位圖 - 詳細資料設定</label>
|
||||
@*<div class="row">
|
||||
<div class="col">
|
||||
<input type="radio" name="icon_click_onoff" id="icon_click_on" value="1">
|
||||
<label for="icon_click_on">
|
||||
點擊開關
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="icon_click_onoff" id="icon_click_off" value="0" checked>
|
||||
<label for="icon_click_off">
|
||||
彈出視窗
|
||||
</label>
|
||||
</div>
|
||||
</div>*@
|
||||
<div class="row">
|
||||
<div class="col" style="display:none">
|
||||
<div class="custom-control custom-checkbox">
|
||||
<input type="checkbox" class="custom-control-input" name="icon_click[]" id="icon_click_switch" value="2">
|
||||
<label class="custom-control-label" for="icon_click_switch">點擊開關</label>
|
||||
<div class="row">
|
||||
<div class="col" style="display:none">
|
||||
<div class="custom-control custom-checkbox">
|
||||
<input type="checkbox" class="custom-control-input" name="icon_click[]" id="icon_click_switch" value="2">
|
||||
<label class="custom-control-label" for="icon_click_switch">點擊開關</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="custom-control custom-checkbox">
|
||||
<input type="checkbox" class="custom-control-input" name="icon_click[]" id="icon_click_url" value="1">
|
||||
<label class="custom-control-label" for="icon_click_url">顯示詳細資料</label>
|
||||
<div class="col">
|
||||
<div class="custom-control custom-checkbox">
|
||||
<input type="checkbox" class="custom-control-input" name="icon_click[]" id="icon_click_url" value="1">
|
||||
<label class="custom-control-label" for="icon_click_url">顯示詳細資料</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_url_modal_div" name="drawing_extend">
|
||||
<label class="form-label" for="build_menu_icon_click_url_modal">詳細資料 URL</label><br>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_building_tag')">+/[device_building_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_system_tag')">+/[device_system_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_floor_tag')">+/[device_floor_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_name_tag')">+/[device_name_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_serial_tag')">+/[device_serial_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('tag_name')">+/[tag_name]</button>
|
||||
<input type="text" id="build_menu_icon_click_url_modal" class="form-control">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_url_width_height_modal_div">
|
||||
<label class="form-label">詳細資料 顯示視窗設定</label><br>
|
||||
<div class="row">
|
||||
<div class="col-6 form-group">
|
||||
<label class="form-label" for="build_menu_icon_click_url_width_modal">寬(單位:px)</label>
|
||||
<input type="number" step="1" id="build_menu_icon_click_url_width_modal" class="form-control">
|
||||
</div>
|
||||
<div class="col-6 form-group">
|
||||
<label class="form-label" for="build_menu_icon_click_url_height_modal">高(單位:px)</label>
|
||||
<input type="number" step="1" id="build_menu_icon_click_url_height_modal" class="form-control">
|
||||
<div class="form-group col-12" id="build_menu_icon_click_url_modal_div" name="drawing_extend">
|
||||
<label class="form-label" for="build_menu_icon_click_url_modal">詳細資料 URL</label><br>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_building_tag')">+/[device_building_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_system_tag')">+/[device_system_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_floor_tag')">+/[device_floor_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_name_tag')">+/[device_name_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_serial_tag')">+/[device_serial_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('tag_name')">+/[tag_name]</button>
|
||||
<input type="text" id="build_menu_icon_click_url_modal" class="form-control">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_url_width_height_modal_div">
|
||||
<label class="form-label">詳細資料 顯示視窗設定</label><br>
|
||||
<div class="row">
|
||||
<div class="col-6 form-group">
|
||||
<label class="form-label" for="build_menu_icon_click_url_width_modal">寬(單位:px)</label>
|
||||
<input type="number" step="1" id="build_menu_icon_click_url_width_modal" class="form-control">
|
||||
</div>
|
||||
<div class="col-6 form-group">
|
||||
<label class="form-label" for="build_menu_icon_click_url_height_modal">高(單位:px)</label>
|
||||
<input type="number" step="1" id="build_menu_icon_click_url_height_modal" class="form-control">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_riser_diagram_url_modal_div" style="display: none">
|
||||
<label class="form-label" for="build_menu_riser_diagram_url_modal">昇位圖 URL</label><br>
|
||||
<input type="text" id="build_menu_riser_diagram_url_modal" class="form-control">
|
||||
<div class="form-group col-12" id="build_menu_riser_diagram_url_modal_div" style="display: none">
|
||||
<label class="form-label" for="build_menu_riser_diagram_url_modal">昇位圖 URL</label><br>
|
||||
<input type="text" id="build_menu_riser_diagram_url_modal" class="form-control">
|
||||
</div>
|
||||
<div class="form-group col-6" id="build_menu_planimetric_floor_modal_div">
|
||||
<label class="form-label" for="build_menu_planimetric_floor_modal"><span class="text-danger">*</span>平面圖預設樓層</label>
|
||||
<select class="form-control" id="build_menu_planimetric_floor_modal">
|
||||
</select>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="form-group col-6" id="build_menu_planimetric_floor_modal_div">
|
||||
<label class="form-label" for="build_menu_planimetric_floor_modal"><span class="text-danger">*</span>平面圖預設樓層</label>
|
||||
<select class="form-control" id="build_menu_planimetric_floor_modal">
|
||||
</select>
|
||||
<div class="col-12 mt-3" id="build_menu_position_r_div">
|
||||
<label class="mb-0 t-gray">右邊區塊</label>
|
||||
<hr class="mt-1" />
|
||||
|
||||
<div class="form-group col-12">
|
||||
<label class="form-label"><span class="text-danger">*</span>預設頁面</label>
|
||||
<div class="row" id="build_menu_drawing_modal_r">
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing_r" id="drawing_4_r" value="4" checked>
|
||||
<label for="drawing_4_r">
|
||||
昇位圖
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing_r" id="drawing_2_r" value="2">
|
||||
<label for="drawing_2_r">
|
||||
系統圖
|
||||
</label>
|
||||
</div>
|
||||
<div class="col" id="drawing_1_div_r" style="display: none;">
|
||||
<input type="radio" name="drawing_r" id="drawing_1_r" value="1">
|
||||
<label for="drawing_1_r">
|
||||
2D
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing_r" id="drawing_3_r" value="3">
|
||||
<label for="drawing_3_r">
|
||||
3D
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="drawing_r" id="drawing_5_r" value="5">
|
||||
<label for="drawing_5_r">
|
||||
彈出URL
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="" name="drawing_extend_r">
|
||||
<div class="col-12 mb-2 custom-control custom-checkbox align-content-center">
|
||||
<input type="checkbox" class="custom-control-input" name="planimetric_click_r" id="planimetric_click_r" value="1" />
|
||||
<label class="custom-control-label" for="planimetric_click_r">是否顯示平面圖</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_systemurl_modal_div_r" name="drawing_extend">
|
||||
<label class="form-label" for="build_menu_systemurl_modal_r"><span class="text-danger">*</span>系統圖URL</label>
|
||||
<input type="text" id="build_menu_systemurl_modal_r" class="form-control" name="build_menu_systemurl_modal_r">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_blankurl_modal_div_r" name="drawing_extend_r">
|
||||
<label class="form-label" for="build_menu_blankurl_modal_r"><span class="text-danger">*</span>彈出URL</label>
|
||||
<input type="text" id="build_menu_blankurl_modal_r" class="form-control" name="build_menu_blankurl_modal_r">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_onoff_modal_div_r" name="drawing_extend_r">
|
||||
<label class="form-label">昇位圖 - 詳細資料設定</label>
|
||||
@*<div class="row">
|
||||
<div class="col">
|
||||
<input type="radio" name="icon_click_onoff" id="icon_click_on" value="1">
|
||||
<label for="icon_click_on">
|
||||
點擊開關
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<input type="radio" name="icon_click_onoff" id="icon_click_off" value="0" checked>
|
||||
<label for="icon_click_off">
|
||||
彈出視窗
|
||||
</label>
|
||||
</div>
|
||||
</div>*@
|
||||
<div class="row">
|
||||
<div class="col" style="display:none">
|
||||
<div class="custom-control custom-checkbox">
|
||||
<input type="checkbox" class="custom-control-input" name="icon_click[]_r" id="icon_click_switch_r" value="2">
|
||||
<label class="custom-control-label" for="icon_click_switch_r">點擊開關</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="custom-control custom-checkbox">
|
||||
<input type="checkbox" class="custom-control-input" name="icon_click[]_r" id="icon_click_url_r" value="1">
|
||||
<label class="custom-control-label" for="icon_click_url_r">顯示詳細資料</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_url_modal_div_r" name="drawing_extend_r">
|
||||
<label class="form-label" for="build_menu_icon_click_url_modal_r">詳細資料 URL</label><br>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_building_tag')">+/[device_building_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_system_tag')">+/[device_system_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_floor_tag')">+/[device_floor_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_name_tag')">+/[device_name_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('device_serial_tag')">+/[device_serial_tag]</button>
|
||||
<button type="button" class="btn btn-secondary waves-effect waves-themed mb-2" onclick="AddTagIntoClickUrl('tag_name')">+/[tag_name]</button>
|
||||
<input type="text" id="build_menu_icon_click_url_modal_r" class="form-control">
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_icon_click_url_width_height_modal_div_r">
|
||||
<label class="form-label">詳細資料 顯示視窗設定</label><br>
|
||||
<div class="row">
|
||||
<div class="col-6 form-group">
|
||||
<label class="form-label" for="build_menu_icon_click_url_width_modal_r">寬(單位:px)</label>
|
||||
<input type="number" step="1" id="build_menu_icon_click_url_width_modal_r" class="form-control">
|
||||
</div>
|
||||
<div class="col-6 form-group">
|
||||
<label class="form-label" for="build_menu_icon_click_url_height_modal_r">高(單位:px)</label>
|
||||
<input type="number" step="1" id="build_menu_icon_click_url_height_modal_r" class="form-control">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group col-12" id="build_menu_riser_diagram_url_modal_div_r" style="display: none">
|
||||
<label class="form-label" for="build_menu_riser_diagram_url_modal_r">昇位圖 URL</label><br>
|
||||
<input type="text" id="build_menu_riser_diagram_url_modal_r" class="form-control">
|
||||
</div>
|
||||
|
||||
<div class="form-group col-6" id="build_menu_planimetric_floor_modal_div_r">
|
||||
<label class="form-label" for="build_menu_planimetric_floor_modal_r"><span class="text-danger">*</span>平面圖預設樓層</label>
|
||||
<select class="form-control" id="build_menu_planimetric_floor_modal_r">
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
@ -258,14 +401,14 @@
|
||||
<br>
|
||||
<span id="menu_floor_main_modal" class="fw-900"></span>
|
||||
@*<select class="form-control" id="menu_floor_main_modal" disabled>
|
||||
</select>*@
|
||||
</select>*@
|
||||
</div>
|
||||
<div class="form-group col-6">
|
||||
<label class="form-label" for="menu_floor_sub_modal"><span class="text-danger">*</span>小類</label>
|
||||
<br>
|
||||
<span id="menu_floor_sub_modal" class="fw-900"></span>
|
||||
@*<select class="form-control" id="menu_floor_sub_modal" disabled>
|
||||
</select>*@
|
||||
</select>*@
|
||||
</div>
|
||||
<div class="form-group col-12">
|
||||
<label class="form-label"><span class="text-danger">*</span>可新增樓層</label>
|
||||
@ -363,9 +506,9 @@
|
||||
this.data = [];
|
||||
} else {
|
||||
$.each(this.data, function (k, rel) {
|
||||
rel.sub_system_guid_name = "<font color='#7c91df'>" + rel.sub_system_guid_name +"</font>"
|
||||
rel.sub_system_guid_name = "<font color='#7c91df'>" + rel.sub_system_guid_name + "</font>"
|
||||
if (rel.drawing == 2) {
|
||||
rel.drawing_name = rel.drawing_name + "<br>" + '<a href = "' + rel.system_url +'" target="_blank" >點擊連結</a >'
|
||||
rel.drawing_name = rel.drawing_name + "<br>" + '<a href = "' + rel.system_url + '" target="_blank" >點擊連結</a >'
|
||||
}
|
||||
if (rel.drawing == 1) {
|
||||
rel.drawing_name = rel.drawing_name + "<br>" + '[' + rel.floor_guid_name + ']'
|
||||
@ -589,16 +732,17 @@
|
||||
$.each($("input[name='icon_click[]']"), function (index, item) {
|
||||
$(this).prop("checked", false);
|
||||
});
|
||||
$('#drawing_4').trigger('change');
|
||||
changebuild_menu_drawing_modal();
|
||||
|
||||
GetSubList($('#build_menu_main_modal').val());
|
||||
GetFloorInSubSystem();
|
||||
$('#planimetric_click').attr("disabled", false);
|
||||
$('#build-menu-modal').modal();
|
||||
}
|
||||
//#endregion
|
||||
//#endregionplanimetric_click
|
||||
//#region 修改選擇顯示頁面總類
|
||||
$('#build_menu_drawing_modal').on("change", $("input[name='drawing']"), function () {
|
||||
changebuild_menu_drawing_modal();
|
||||
$('#build-menu-form').on("change", "input[name^=drawing]", function () {
|
||||
changebuild_menu_drawing_modal(this);
|
||||
});
|
||||
//#endregion
|
||||
$('#build_menu_icon_click_onoff_modal_div').on("click", "input[type=checkbox]", function () {
|
||||
@ -709,8 +853,8 @@
|
||||
}
|
||||
});
|
||||
|
||||
@*$("input[name*='icon_click_onoff'][value='" + rel.data.icon_click + "']").prop("checked", true);*@
|
||||
$('#build_menu_icon_click_url_modal').val(rel.data.icon_click_url);
|
||||
@*$("input[name*='icon_click_onoff'][value='" + rel.data.icon_click + "']").prop("checked", true);*@
|
||||
$('#build_menu_icon_click_url_modal').val(rel.data.icon_click_url);
|
||||
if (rel.data.icon_click_url_width != undefined && rel.data.icon_click_url_width != null && rel.data.icon_click_url_width > 0) {
|
||||
$('#build_menu_icon_click_url_width_modal').val(rel.data.icon_click_url_width);
|
||||
} else {
|
||||
@ -730,39 +874,40 @@
|
||||
}, 'json');
|
||||
});
|
||||
//#endregion
|
||||
function changebuild_menu_drawing_modal() {
|
||||
if ($('input[name="drawing"]:checked').val() == 2) {
|
||||
$('#planimetric_click').attr("disabled", false);
|
||||
$('#build_menu_icon_click_onoff_modal_div').hide();
|
||||
$('#build_menu_icon_click_url_modal_div').hide();
|
||||
$('#build_menu_systemurl_modal_div').show();
|
||||
@*$('#build_menu_riser_diagram_url_modal_div').hide();*@
|
||||
$('#build_menu_icon_click_url_width_height_modal_div').hide();
|
||||
$('#build_menu_planimetric_floor_modal_div').hide();
|
||||
} else if ($('input[name="drawing"]:checked').val() == 4) {
|
||||
$('#planimetric_click').attr("disabled", false);
|
||||
$('#build_menu_systemurl_modal_div').hide();
|
||||
$('#build_menu_icon_click_onoff_modal_div').show();
|
||||
if ($("#icon_click_url").prop('checked')) {
|
||||
$('#build_menu_icon_click_url_modal_div').show();
|
||||
$('#build_menu_icon_click_url_width_height_modal_div').show();
|
||||
function changebuild_menu_drawing_modal(selector = "input[name^='drawing']:checked") {
|
||||
|
||||
$(selector).each(function (index, value) {
|
||||
let drawingParent = $(value).parents("[id^=build_menu_position]")
|
||||
$(drawingParent).find('[id^=build_menu_icon_click_onoff_modal_div]').hide();
|
||||
$(drawingParent).find('[id^=build_menu_blankurl_modal_div]').hide();
|
||||
$(drawingParent).find('[id^=build_menu_icon_click_url_modal_div]').hide();
|
||||
$(drawingParent).find('[id^=build_menu_icon_click_url_width_height_modal_div]').hide();
|
||||
$(drawingParent).find('[id^=build_menu_planimetric_floor_modal_div]').hide();
|
||||
$(drawingParent).find('[id^=build_menu_systemurl_modal_div]').hide();
|
||||
|
||||
if ($(value).val() == 2) {
|
||||
$(drawingParent).find('[id^=planimetric_click]').attr("disabled", false);
|
||||
$(drawingParent).find('[id^=build_menu_systemurl_modal_div]').show();
|
||||
} else if ($(value).val() == 4) {
|
||||
$(drawingParent).find('[id^="planimetric_click"]').attr("disabled", false);
|
||||
$(drawingParent).find('[id^=build_menu_icon_click_onoff_modal_div]').show();
|
||||
if ($(drawingParent).find("[id^=icon_click_url]").prop('checked')) {
|
||||
$(drawingParent).find('[id^=build_menu_icon_click_url_modal_div]').show();
|
||||
$(drawingParent).find('[id^=build_menu_icon_click_url_width_height_modal_div]').show();
|
||||
}
|
||||
} else if ($(value).val() == 1) {
|
||||
$(drawingParent).find('[id^=planimetric_click]').prop("checked", true).attr("disabled", true);
|
||||
$(drawingParent).find('[id^=build_menu_planimetric_floor_modal_div]').show();
|
||||
} else if ($(value).val() == 5) {
|
||||
$(drawingParent).find('[id^=planimetric_click]').prop("checked", false);
|
||||
$(drawingParent).find('[id^=build_menu_blankurl_modal_div]').show();
|
||||
} else if ($(value).val() == 3) {
|
||||
$(drawingParent).find('[id^=planimetric_click]').prop("checked", false).attr("disabled", true);
|
||||
}
|
||||
else {
|
||||
$('#build_menu_icon_click_url_modal_div').hide();
|
||||
$('#build_menu_icon_click_url_width_height_modal_div').hide();
|
||||
}
|
||||
@*$('#build_menu_riser_diagram_url_modal_div').show();*@
|
||||
|
||||
$('#build_menu_planimetric_floor_modal_div').hide();
|
||||
} else if ($('input[name="drawing"]:checked').val() == 1) {
|
||||
$('#planimetric_click').prop("checked", true).attr("disabled", true);
|
||||
$('#build_menu_systemurl_modal_div').hide();
|
||||
$('#build_menu_icon_click_onoff_modal_div').hide();
|
||||
$('#build_menu_icon_click_url_modal_div').hide();
|
||||
@*$('#build_menu_riser_diagram_url_modal_div').hide();*@
|
||||
$('#build_menu_icon_click_url_width_height_modal_div').hide();
|
||||
$('#build_menu_planimetric_floor_modal_div').show();
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
|
||||
}
|
||||
$('#buildMenu_table').on("click", "button.del-btn", function () {
|
||||
var send_data = {
|
||||
@ -811,9 +956,9 @@
|
||||
SelectBuild = $(this).attr('bg-guid');
|
||||
SelectMainSys = $(this).attr('ms-guid');
|
||||
SelectSubSys = $(this).attr('ss-guid');
|
||||
@*$('#menu_floor_main_modal').append($("<option />").val($(this).attr('ms-guid')).text($(this).attr('ms-name')));
|
||||
@*$('#menu_floor_main_modal').append($("<option />").val($(this).attr('ms-guid')).text($(this).attr('ms-name')));
|
||||
$('#menu_floor_sub_modal').append($("<option />").val($(this).attr('ss-guid')).text($(this).attr('ss-name')));*@
|
||||
$('#menu_floor_main_modal').html($(this).attr('ms-name'))
|
||||
$('#menu_floor_main_modal').html($(this).attr('ms-name'))
|
||||
$('#menu_floor_sub_modal').html($(this).attr('ss-name'))
|
||||
$('#floorcard').show();
|
||||
$('#floorcard').find('.card-title').html($(this).attr('ms-name') + "-" + $(this).attr('ss-name') + "-樓層設定");
|
||||
@ -969,19 +1114,21 @@
|
||||
}
|
||||
else {
|
||||
if (rel.data.length == 0) {
|
||||
$('#drawing_1_div').hide();
|
||||
$('#build_menu_planimetric_floor_modal_div').hide();
|
||||
$('[id^=drawing_1_div]').hide();
|
||||
$('[id^=build_menu_planimetric_floor_modal_div]').hide();
|
||||
}
|
||||
else {
|
||||
$('#build_menu_planimetric_floor_modal').empty();
|
||||
$('#build_menu_planimetric_floor_modal,#build_menu_planimetric_floor_modal_r').empty();
|
||||
$.each(rel.data, function (index, val) {
|
||||
$('#build_menu_planimetric_floor_modal').append($("<option />").val(val.value).text(val.name));
|
||||
$('#build_menu_planimetric_floor_modal_r').append($("<option />").val(val.value).text(val.name));
|
||||
});
|
||||
if (floor != null) {
|
||||
$('#build_menu_planimetric_floor_modal').val(floor);
|
||||
$('#build_menu_planimetric_floor_modal_r').val(floor);
|
||||
}
|
||||
$('#drawing_1_div').show();
|
||||
$('#build_menu_planimetric_floor_modal_div').show();
|
||||
$('[id^=drawing_1_div]').show();
|
||||
$('[id^=build_menu_planimetric_floor_modal_div]').show();
|
||||
changebuild_menu_drawing_modal();
|
||||
|
||||
}
|
||||
|
@ -3,6 +3,11 @@ for details on configuring this project to bundle and minify static web assets.
|
||||
|
||||
/* Sticky footer styles
|
||||
-------------------------------------------------- */
|
||||
|
||||
:root {
|
||||
--bims-gray:#c3c3c3;
|
||||
}
|
||||
|
||||
html {
|
||||
font-size: 16px;
|
||||
}
|
||||
@ -38,3 +43,7 @@ label.error {
|
||||
.highcharts-credits {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.t-gray {
|
||||
color:var(--bims-gray) !important;
|
||||
}
|
Loading…
Reference in New Issue
Block a user