Compare commits
22 Commits
Author | SHA1 | Date |
---|---|---|
|
cebb4f0a43 | |
|
ed29a40b09 | |
|
acf7f64c0d | |
|
1666bd67d7 | |
|
c87159a7e2 | |
|
e3b8b8b72d | |
|
d0594a792c | |
|
97126daa59 | |
|
60cd1a9b7f | |
|
8750acc25f | |
|
aba8b92f52 | |
|
79d575add9 | |
|
aa74b372a7 | |
|
66bbee592a | |
|
d20cb27a00 | |
|
4263795fde | |
|
42f898156e | |
|
a8f538e508 | |
|
ee4e317f33 | |
|
5e13ff2fca | |
|
76028d6529 | |
|
310dc03e40 |
22
bower.json
22
bower.json
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"name": "strolch-wc-plc",
|
"name": "strolch-wc-plc",
|
||||||
"description": "Strolch PLC WebComponents",
|
"description": "Strolch PLC WebComponents",
|
||||||
"version": "0.2.1",
|
"version": "0.3.22",
|
||||||
"authors": ["Robert von Burg"],
|
"authors": ["Robert von Burg"],
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"strolch",
|
"strolch",
|
||||||
|
@ -11,20 +11,19 @@
|
||||||
"private": true,
|
"private": true,
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git@github.com:4treesCH/strolch-wc-plc.git"
|
"url": "git@github.com:strolch-li/strolch-wc-plc.git"
|
||||||
},
|
},
|
||||||
"license": "https://github.com/4treesCH/strolch-wc-plc/blob/master/LICENSE",
|
"license": "https://github.com/strolch-li/strolch-wc-plc/blob/master/LICENSE",
|
||||||
"homepage": "https://github.com/4treesCH/strolch-wc-plc",
|
"homepage": "https://github.com/strolch-li/strolch-wc-plc",
|
||||||
"ignore": [],
|
"ignore": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"strolchjs": "4treesCH/strolchjs#^0.2.7",
|
"strolchjs": "strolch-li/strolchjs#^0.5.3",
|
||||||
"strolch-wc-styles": "4treesCH/strolch-wc-styles#^0.3.0",
|
"strolch-wc-styles": "strolch-li/strolch-wc-styles#^0.4.7",
|
||||||
"strolch-wc-debounced-input": "4treesCH/strolch-wc-debounced-input#^0.1.0",
|
"strolch-wc-debounced-input": "strolch-li/strolch-wc-debounced-input#^0.1.6",
|
||||||
"strolch-wc-tree": "4treesCH/strolch-wc-tree#^0.1.5",
|
"strolch-wc-ws-observer": "strolch-li/strolch-wc-ws-observer#^0.2.11",
|
||||||
"strolch-wc-ws-observer": "4treesCH/strolch-wc-ws-observer#^0.1.5",
|
"strolch-wc-localize-behavior": "strolch-li/strolch-wc-localize-behavior#^1.1.17",
|
||||||
"strolch-wc-localize-behavior": "4treesCH/strolch-wc-localize-behavior#^1.1.4",
|
|
||||||
|
|
||||||
"polymer": "Polymer/polymer#^1.11.3",
|
"polymer": "Polymer/polymer#^1.12.0",
|
||||||
|
|
||||||
"iron-ajax": "PolymerElements/iron-ajax#^1.4.4",
|
"iron-ajax": "PolymerElements/iron-ajax#^1.4.4",
|
||||||
"iron-pages": "PolymerElements/iron-pages#^1.0.9",
|
"iron-pages": "PolymerElements/iron-pages#^1.0.9",
|
||||||
|
@ -40,6 +39,7 @@
|
||||||
"paper-badge": "PolymerElements/paper-badge#^1.1.4",
|
"paper-badge": "PolymerElements/paper-badge#^1.1.4",
|
||||||
"paper-dialog": "PolymerElements/paper-dialog#^1.1.0",
|
"paper-dialog": "PolymerElements/paper-dialog#^1.1.0",
|
||||||
"paper-button": "PolymerElements/paper-button#^1.0.15",
|
"paper-button": "PolymerElements/paper-button#^1.0.15",
|
||||||
|
"paper-toggle-button": "PolymerElements/paper-toggle-button#^1.3.0",
|
||||||
"paper-toolbar": "PolymerElements/paper-toolbar#^1.1.7",
|
"paper-toolbar": "PolymerElements/paper-toolbar#^1.1.7",
|
||||||
"paper-icon-button": "PolymerElements/paper-icon-button#^1.1.6",
|
"paper-icon-button": "PolymerElements/paper-icon-button#^1.1.6",
|
||||||
"paper-tabs": "PolymerElements/paper-tabs#^1.8.0",
|
"paper-tabs": "PolymerElements/paper-tabs#^1.8.0",
|
||||||
|
|
|
@ -85,24 +85,18 @@
|
||||||
|
|
||||||
confirmActionWarning: function (callback) {
|
confirmActionWarning: function (callback) {
|
||||||
var bound = callback.bind(this);
|
var bound = callback.bind(this);
|
||||||
|
|
||||||
if (this.warningConfirmed) {
|
if (this.warningConfirmed) {
|
||||||
bound();
|
bound();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var confirmedCallback = function (confirmed) {
|
this.fire("strolch-show-info", {
|
||||||
if (confirmed) {
|
title: this.localize('confirmActionWarning'),
|
||||||
|
line1: this.localize('confirmActionWarningMsg'),
|
||||||
|
callback: function () {
|
||||||
this.warningConfirmed = true;
|
this.warningConfirmed = true;
|
||||||
bound();
|
bound();
|
||||||
}
|
}.bind(this)
|
||||||
}.bind(this);
|
|
||||||
|
|
||||||
this.fire("cx-show-confirmation", {
|
|
||||||
title: this.localize('confirmActionWarning'),
|
|
||||||
text: this.localize('confirmActionWarningMsg'),
|
|
||||||
callback: confirmedCallback,
|
|
||||||
bind: this
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,6 +27,16 @@
|
||||||
<template>
|
<template>
|
||||||
|
|
||||||
<style is="custom-style" include="strolch-wc-plc-style">
|
<style is="custom-style" include="strolch-wc-plc-style">
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
paper-card {
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
.label {
|
.label {
|
||||||
min-width: 300px;
|
min-width: 300px;
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
|
|
|
@ -50,11 +50,11 @@
|
||||||
<div class="g-flex-table-cell address-field no-grow">
|
<div class="g-flex-table-cell address-field no-grow">
|
||||||
<template is="dom-if" if="[[isBoolean(address.valueType)]]">
|
<template is="dom-if" if="[[isBoolean(address.valueType)]]">
|
||||||
<template is="dom-if" if="[[address.value]]">
|
<template is="dom-if" if="[[address.value]]">
|
||||||
<iron-icon style="color:#0b8043"
|
<iron-icon class="active-icon"
|
||||||
icon="icons:radio-button-checked"></iron-icon>
|
icon="icons:radio-button-checked"></iron-icon>
|
||||||
</template>
|
</template>
|
||||||
<template is="dom-if" if="[[!address.value]]">
|
<template is="dom-if" if="[[!address.value]]">
|
||||||
<iron-icon style="color:cornflowerblue"
|
<iron-icon class="inactive-icon"
|
||||||
icon="icons:radio-button-unchecked"></iron-icon>
|
icon="icons:radio-button-unchecked"></iron-icon>
|
||||||
</template>
|
</template>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -31,8 +31,14 @@
|
||||||
<template>
|
<template>
|
||||||
|
|
||||||
<style is="custom-style" include="strolch-wc-plc-style">
|
<style is="custom-style" include="strolch-wc-plc-style">
|
||||||
h2 {
|
:host {
|
||||||
margin-bottom: 10px;
|
display: block;
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
h2:not(:first-of-type) {
|
||||||
|
margin-top: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.actions {
|
.actions {
|
||||||
|
@ -67,7 +73,7 @@
|
||||||
on-response="onGetDevicesResponse"
|
on-response="onGetDevicesResponse"
|
||||||
on-error="onRequestError"></iron-ajax>
|
on-error="onRequestError"></iron-ajax>
|
||||||
|
|
||||||
<strolch-wc-ws-observer id="observerHandler" ws-path="[[wsObserverPath]]"></strolch-wc-ws-observer>
|
<strolch-wc-ws-observer id="observerHandler" ws-path="[[baseWsPath]]/plc/observer"></strolch-wc-ws-observer>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -99,12 +105,6 @@
|
||||||
devicesByGroup: {
|
devicesByGroup: {
|
||||||
type: Array,
|
type: Array,
|
||||||
value: []
|
value: []
|
||||||
},
|
|
||||||
wsObserverPath: {
|
|
||||||
type: String,
|
|
||||||
value: function () {
|
|
||||||
return CustomWeb.baseWsPath + "/plc/observer";
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -118,7 +118,7 @@
|
||||||
this.$.ajaxGetDevices.generateRequest();
|
this.$.ajaxGetDevices.generateRequest();
|
||||||
|
|
||||||
if (!this.registeredForUpdates) {
|
if (!this.registeredForUpdates) {
|
||||||
this.$.observerHandler.register("Resource", "PlcAddress", "strolch-wc-plc-logical-devices", true, this.handleUpdate.bind(this));
|
this.$.observerHandler.register("Resource", "PlcAddress", "strolch-wc-plc-logical-devices", {flat: true}, this.handleUpdate.bind(this));
|
||||||
this.registeredForUpdates = true;
|
this.registeredForUpdates = true;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,19 +1,22 @@
|
||||||
<link rel="import" href="../polymer/polymer.html">
|
<link rel="import" href="../polymer/polymer.html">
|
||||||
<link rel="import" href="../paper-styles/color.html">
|
<link rel="import" href="../paper-styles/color.html">
|
||||||
|
<link rel="import" href="../paper-styles/paper-styles.html">
|
||||||
|
|
||||||
<link rel="import" href="../strolch-wc-styles/strolch-wc-styles.html">
|
<link rel="import" href="../strolch-wc-styles/strolch-wc-app-style.html">
|
||||||
|
|
||||||
<dom-module id="strolch-wc-plc-style">
|
<dom-module id="strolch-wc-plc-style">
|
||||||
<template>
|
<template>
|
||||||
<style is="strolch-wc-plc-style" include="strolch-wc-styles">
|
<style is="strolch-wc-plc-style" include="strolch-wc-app-style">
|
||||||
:host {
|
:root {
|
||||||
display: block;
|
--app-primary-color: #9965F4;
|
||||||
|
--app-secondary-color: #616161;
|
||||||
|
--primary-text-color: #212121;
|
||||||
|
--secondary-text-color: #737373;
|
||||||
}
|
}
|
||||||
|
|
||||||
paper-card {
|
paper-card {
|
||||||
margin-bottom: 10px;
|
display: block;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
width: calc(100% - 20px);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
paper-icon-button, iron-icon {
|
paper-icon-button, iron-icon {
|
||||||
|
@ -22,6 +25,21 @@
|
||||||
|
|
||||||
paper-toggle-button {
|
paper-toggle-button {
|
||||||
height: 35px;
|
height: 35px;
|
||||||
|
margin-left: 10px;
|
||||||
|
margin-right: 5px;
|
||||||
|
--paper-toggle-button-checked-button-color: var(--app-primary-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
paper-radio-button {
|
||||||
|
--paper-radio-button-checked-color: var(--app-primary-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
.active-icon {
|
||||||
|
color: var(--app-primary-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
.inactive-icon {
|
||||||
|
color: var(--secondary-text-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
h2, h3 {
|
h2, h3 {
|
||||||
|
|
Loading…
Reference in New Issue