This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<require from="./boxes-vm"></require> | |
<h1>${message}</h1> | |
<form role="form"> | |
<boxes boxes.bind="shipment.boxes"></boxes> | |
</form> | |
<button click.delegate="clearBoxes()">Clear All</button> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<require from="./boxes-vm"></require> | |
<h1>${message}</h1> | |
<form role="form"> | |
<boxes boxes.bind="shipment.boxes"></boxes> | |
</form> | |
<button click.delegate="clearBoxes()">Clear All</button> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<h1>${message}</h1> | |
</template> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {inject, customAttribute, bindable, bindingMode} from 'aurelia-framework'; | |
@customAttribute('input-mask') | |
@inject(Element) | |
export class InputMaskCustomAttribute { | |
@bindable({ defaultBindingMode: bindingMode.twoWay, changeHandler: 'onUnmaskedValueChanged' }) | |
unmaskedValue: any; | |
onUnmaskedValueChanged(newValue, oldValue) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USE pubs | |
GO | |
EXEC sp_configure 'allow update', '1' | |
RECONFIGURE WITH OVERRIDE | |
GO | |
DECLARE @col varchar(128), @table varchar(128) | |
-- for find identity column (if colstat =1 then identity is on) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE SCHEMA Customer | |
GO | |
CREATE SCHEMA detail | |
go | |
CREATE TABLE Customer.Customer | |
( | |
CustomerId BIGINT IDENTITY(1,1) PRIMARY KEY, | |
CurrentCustomerIdentifierId BIGINT NULL |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void Main() | |
{ | |
Mapper.CreateMap<SourceTest, DestTest>() | |
.ForMember(x=>x.CommonIgnoredValue, opt=>opt.Ignore()) | |
.IgnoreAllNonExisting(); | |
var source = new SourceTest{ CommonValue = "FromSource", CommonIgnoredValue = "Ignored Value from Source"}; | |
var dest = new DestTest { CommonValue = "FromDest", CommonIgnoredValue = "Ignored Value from Dest", DestOnlyValue = "Value Only In Dest" }; | |
Mapper.Map(source, dest); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
xmlns:Chromes="clr-namespace:Xceed.Wpf.Toolkit.Chromes;assembly=WPFToolkit.Extended" | |
xmlns:Controls="clr-namespace:OMStudio.Wpf.Controls" | |
xmlns:utils="clr-namespace:Arup.Wpf.Utils.Converters;assembly=Arup.Wpf.Utils" | |
xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit" | |
> | |
<xctk:InverseBoolConverter x:Key="InverseBoolConverter" /> | |
<xctk:VisibilityToBoolConverter x:Key="VisibilityToBoolConverter" Inverted="True" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class DebugConverter : IValueConverter | |
{ | |
public static DebugConverter Instance = new DebugConverter(); | |
private DebugConverter() {} | |
#region IValueConverter Members | |
public object Convert(object value, Type targetType, object parameter, CultureInfo culture) | |
{ | |
Debugger.Break(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
xmlns:Styles="clr-namespace:MyProject.Wpf.Controls.Styles"> | |
<!--Setup the look of the tool tips--> | |
<Style TargetType="{x:Type ToolTip}"> | |
<Setter Property="Foreground" Value="#2E2E2E"/> | |
<Setter Property="Background"> | |
<Setter.Value> | |
<LinearGradientBrush StartPoint="0.5,0" EndPoint="0.5,1"> |