- Store and StoreMap add DeletedAt.

This commit is contained in:
gazebo
2018-09-20 10:07:58 +08:00
parent f874c37d14
commit 9d88344ddb
14 changed files with 206 additions and 172 deletions

View File

@@ -44,17 +44,26 @@ func TestGetPlaceByName(t *testing.T) {
func TestUpdateKV(t *testing.T) {
dummy := &model.Store{}
kvs := map[string]interface{}{
"status": 100,
"Tel1": "tel1",
"tEl2": "tel2",
"deliverY_Range_type": 15,
"status": 100,
"Tel1": "tel1",
"tEl2": "tel2",
"deliveryRangeType": 15,
}
cond := map[string]interface{}{
"id": 100002,
}
num, err := UpdateEntityByKV(nil, dummy, kvs, cond)
num, err := UpdateEntityLogically(nil, dummy, kvs, "autotest", cond)
if err != nil {
t.Fatal(err)
}
t.Log(num)
}
func TestWrapAddIDCULEntity(t *testing.T) {
dummy := &model.Store{}
WrapAddIDCULEntity(dummy, "autotest")
if dummy.LastOperator != "autotest" {
t.Fatal("last operator is not same")
}
t.Log(dummy)
}