fixed marks

This commit is contained in:
Anton Dyudin 2015-08-20 12:20:14 -07:00
parent b754203040
commit 3e7fdba162
6 changed files with 64 additions and 32 deletions

View File

@ -17,22 +17,50 @@
|* a=fist
%- cu :_ (ar a)
~(gas in *(set ,_(need *a)))
++ ot
|* a=(pole ,[@tas fist])
|= b=json
%. ((^ot a) b)
%+ slog 0
?+ b ~
[%o *]
%+ murn `(list ,[@tas fist])`a
|= [c=term d=fist] ^- (unit tank)
=+ (~(get by p.b) c)
?~ - (some >[c (turn (~(tap by p.b)) head)]<)
=+ (d u)
?~ - (some >[c u]<)
~
==
++ of
|* a=(pole ,[@tas fist])
|= b=json
%. ((of:jo a) b)
%+ slog 0
?+ b ~
[%o *]
%+ murn `(list ,[@tas fist])`a
|= [c=term d=fist] ^- (unit tank)
=+ (~(get by p.b) c)
?~ - ~
=+ (d u)
?~ - (some >[c u]<)
~
==
++ id (ci (slat %uv) so)
++ ship (su fed:ag)
++ coma (of new/task old/(ot id/id dif/uppd ~) sort/(ar id) ~)
++ coma (of new/new old/(ot id/id dif/uppd ~) sort/(ar id) ~)
++ new (ot task/task audience/audi ~)
++ task
%^ ot
:- %task
%- ot :~
id/id date-created/di
version/ni date-modified/di
owner/ship status/(ci (soft status) so)
tags/(as so) date-due/(mu di)
done/(mu di) title/so
description/so discussion/(ar (ot date/di ship/ship body/so ~))
==
audience/(as (ot ship/ship span/so ~))
~
%- ot :~
id/id date-created/di
version/ni date-modified/di
owner/ship status/(ci (soft status) so)
tags/(as so) date-due/(mu di)
done/(mu di) title/so
description/so discussion/(ar (ot date/di ship/ship body/so ~))
==
++ audi (as (ot ship/ship span/so ~))
++ uppd
%- of :~
own/(of announce/ul claim/ul ~)
@ -44,7 +72,7 @@
description/so
tags/(as so)
done/bo
audience/(as (ot ship/ship span/so ~))
audience/audi
==
==
--
@ -63,7 +91,7 @@
:: status:'gave',
:: tags:['tag'],
:: date-due:null,
:: done:XX
:: done:false,
:: title:'Test task',
:: description:'The converter owrks right?',
:: discussion:[{date:1440011611215,ship:'sondel',body:'hi'}]

View File

@ -49,15 +49,15 @@
|= a=wain ^+ taz
=+ ~[id=%uv "_" date-created=%da " " version=%ud date-modified=%da]
=^ b a (advance a ;~(plug (parse -) (punt (parse " " %da ~))))
=+ [-.b `due-date=(unit ,@da)`+.b]
=+ [-.b `date-due=(unit ,@da)`+.b]
=^ tags a (undent a ~(gas in *(set cord)))
=^ title a ?~(a !! a)
=^ b a (advance a (parse owner=%p "." status=%tas ~))
?> ?=(status.task status.b)
=+ b
=^ description a (undent a role)
:* id date-created version date-modified
owner status tags due-date title description
:* id date-created version date-modified owner
status tags date-due ~ title description :: XX done
|- ^- (list comment)
?: =(~ a) ~
=^ b a (advance a (parse ship=%p " " date=%da ~))
@ -72,7 +72,7 @@
++ mime [/text/x-task (taco (role txt))]
++ txt
=+ taz
=+ due=?~(due-date ~ ~[' ' da/u.due-date])
=+ due=?~(date-due ~ ~[' ' da/u.date-due])
:- (rend uv/id '_' da/date-created ' ' ud/version da/date-modified due)
%+ welp (indent (sort (~(tap in tags)) aor))
:- title
@ -95,12 +95,13 @@
description/[%s description]
=< discussion/[%a (turn discussion .)]
|=(comment (jobe date/(jode date) ship/(jape <ship>) body/[%s body] ~))
due-date/?~(due-date ~ (jode u.due-date))
date-due/?~(date-due ~ (jode u.date-due))
done/?~(done ~ (jode u.done))
==
--
++ grad %txt
--
:: {id}_{date-created} {version}{date-modified}{|(" {due-date}" ~)}
:: {id}_{date-created} {version}{date-modified}{|(" {date-due}" ~)}
:: {tag1}
:: {tag2}
:: ...

View File

@ -9,14 +9,15 @@ module.exports =
version:0
"date-created":Date.now()
"date-modified":Date.now()
"due-date":null
"date-due":null
done:null
owner:window.urb.ship
status:'gave'
status:'announced'
tags:[]
title:''
description:''
discussion:[]
Persistence.put "new":item
Persistence.put "new": task:item, audience:[]
Dispatcher.handleViewAction {type:'newItem', index, item}
setFilter: (key,val) ->
@ -29,7 +30,7 @@ module.exports =
Dispatcher.handleViewAction
type:'setSort'
key:key
val:val
val:val
swapItems: (to,from) ->
Dispatcher.handleViewAction

View File

@ -15,16 +15,20 @@ module.exports = {
version: 0,
"date-created": Date.now(),
"date-modified": Date.now(),
"due-date": null,
"date-due": null,
done: null,
owner: window.urb.ship,
status: 'gave',
status: 'announced',
tags: [],
title: '',
description: '',
discussion: []
};
Persistence.put({
"new": item
"new": {
task: item,
audience: []
}
});
return Dispatcher.handleViewAction({
type: 'newItem',
@ -982,7 +986,7 @@ module.exports = Object.assign || function (target, source) {
};
},{}],14:[function(require,module,exports){
urb.appl = 'hood';
urb.appl = 'work';
module.exports = {
put: function(update, cb) {
@ -1132,7 +1136,6 @@ WorkStore = assign({}, EventEmitter.prototype, {
}, item);
_item["date-created"] = new Date(item["date-created"]);
_item["date-modified"] = new Date(item["date-modified"]);
_item["date-due"] = item["due-date"];
return _list.splice(index, 0, _item);
},
swapItem: function(arg) {

View File

@ -1,4 +1,4 @@
urb.appl = 'hood' # XX
urb.appl = 'work'
module.exports =
put: (update,cb) -> urb.send(update,{mark:'work-command'},cb)
get: (id,cb) ->

View File

@ -90,7 +90,6 @@ WorkStore = assign {},EventEmitter.prototype,{
_item = _.extend {sort:index,audience:[]}, item
_item["date-created"]=new Date item["date-created"]
_item["date-modified"]=new Date item["date-modified"]
_item["date-due"]=item["due-date"]
_list.splice index,0,_item
swapItem: ({to,from}) ->