summaryrefslogtreecommitdiffstats
path: root/ecomp-sdk/epsdk-app-overlay/src/main/webapp/app/fusion/scripts/DS2-view-models/ds2-reports/modal/report-wizard-formfield-edit.html
blob: 3c17ff7b5b24a243fa1f73d0bab4bf2c7256dac0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
<style>
#columnEditTable table tbody td {
	border: none;
}

#columnEditTable table tbody tr {
	border: none;
}

.colTableLeftColumn {
	width: 45%;
	text-align: right;
	vertical-align: middle;
}

.colTableInput {
	width: 220px;
}

#columnEditTable .selectWrap {
	width: 220px;
}
table {
     border-bottom: none;
}
</style>

<div class="b2b-modal-header">
	<h2 id="myModalLabel" modal-title="">Report Form Field - Edit</h2>
	<div class="corner-button in">
		<button type="button" class="close" aria-label="Close"
			ng-click="$dismiss('cancel')"></button>
	</div>
</div>
<div class="b2b-modal-body">
	<div ng-show="dataProcessing" class="span loader-container">
		<i class="icon-primary-spinner" role="img"
			aria-label="Please wait while we load your content"></i>
	</div>
	<div id="columnEditTable" ng-hide="dataProcessing">
		<table class="striped">
			<tbody>
				<tr>
					<td class="colTableLeftColumn">Field Name:</td>
					<td><input type="text" name="displayName"
						ng-model="formFieldEditData.fieldName" class="colTableInput"></td>
				</tr>

				<tr>
					<td class="colTableLeftColumn">Field Type:</td>
					<td><select name="fieldType" b2b-dropdown
						ng-model="formFieldEditData.fieldType" placeholder-text="Select">
							<option b2b-dropdown-list option-repeat="d in fieldTypeOptions"
								value="{{d.value}}">{{d.text}}</option>
					</select></td>
				</tr>
				<tr>
					<td class="colTableLeftColumn">Visible:</td>
					<td>
						<select name="visible" b2b-dropdown	ng-model="formFieldEditData.visible">
							<option b2b-dropdown-list option-repeat="d in ynOptions" value="{{d.value}}">{{d.text}}</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="colTableLeftColumn">Is used in Group By Clause?</td>
					<td>
						<label for="checkboxGrp" class="checkbox"> 
						<input	id="checkboxGrp" type="checkbox" ng-model="formFieldEditData.groupFormField" /><i class="skin"></i><span></span>
						</label>	
					</td>
				</tr>
			 	<tr>
					<td class="colTableLeftColumn">SQL as Default Value:</td>
					<td>
						<label for="cehckboxSql" class="checkbox"> <input
							id="cehckboxSql" type="checkbox"
							ng-model="sqlAsDefaultValue.value" /><i class="skin"></i><span></span>
						</label>
					</td>
				</tr> 
				<tr ng-show="sqlAsDefaultValue.value">
					<td class="colTableLeftColumn">Default SQL:</td>
					<td>
						<textarea b2b-reset b2b-dragon-input b2b-reset-textarea
							ng-model="formFieldEditData.fieldDefaultSQL" style="height: 80px">
                		</textarea>
                	</td>
					<td>
						<p>
							<button ng-click="formFieldVerifySQL(formFieldEditData.fieldDefaultSQL)"
								class="btn btn-alt btn-small">Verify</button>
						</p>
					</td>
				</tr>
				<tr ng-hide="formFieldEditData.fieldDefaultSQL">
					<td class="colTableLeftColumn">Default Value:</td>
					<td><input type="text" name="defaultValue"
						ng-model="formFieldEditData.defaultValue" class="colTableInput"></td>
				</tr>


				<tr>
					<td class="colTableLeftColumn">Verify Field Value As:</td>
					<td><select name="visible" b2b-dropdown
						ng-model="formFieldEditData.validationType" placeholder-text="Select">
							<option b2b-dropdown-list option-repeat="d in verifyFieldValueOptions"
								value="{{d.value}}">{{d.text}}</option>
					</select></td>
				</tr>
				<tr>
					<td class="colTableLeftColumn">SQL Generating Custom List of
						Values:</td>
					<td><textarea b2b-reset b2b-dragon-input b2b-reset-textarea
							ng-model="formFieldEditData.fieldSQL" style="height: 80px">
                </textarea></td>
					<td>
						<p>
							<button ng-click="formFieldVerifySQL(formFieldEditData.fieldSQL)"
								class="btn btn-alt btn-small">Verify</button>
						</p>
					</td>
				</tr>
				<tr>
					<td class="colTableLeftColumn">Provide Predefined List of Values:	Do not use Predefined list - Generate list from database :</td>
					<td>
                		<input type="text" name="defaultValue" 	ng-model="predefinedValues.value" class="colTableInput">
                	</td>
					<td>
						<p>
							<button ng-click="addPredefinedValueList();"	class="btn btn-alt btn-small">Add to List</button>
						</p>
					</td>
				</tr>
				<tr>
					<td class="colTableLeftColumn"></td>
					<td>
                		<div ng-repeat = "rowData in formFieldEditData.predefinedValueList">
                			<span>{{rowData.id}}</span>
                			<a ng-click="removePredefinedValueList(rowData.id)" class="icon-misc-trash"></a>
                		</div>
                	</td>
				</tr>
			</tbody>
		</table>
	</div>
</div>
<div class="b2b-modal-footer">
	<div class="cta-button-group in">
		<button class="btn btn-alt btn-small" type="button" ng-click="save()" ng-show="type=='edit'">Save</button>
		<button class="btn btn-alt btn-small" type="button" ng-click="add()" ng-show="type=='add'">Add</button>
		<button class="btn btn-alt btn-small" type="button" ng-click="cancel()">Cancel</button>
	</div>
</div>